Skip to content
Merged
Show file tree
Hide file tree
Changes from 22 commits
Commits
Show all changes
25 commits
Select commit Hold shift + click to select a range
742c487
LR-COLOR-MIXER-HSL: the Color Mixer's HSL mode, laid out as in Lightr…
OneSlips Oct 16, 2026
88b92cd
LR-EDIT-COLOR-MIXER-HSL: review fixes (hidden targeted adjustment, fu…
OneSlips Oct 25, 2026
57da3cf
LR-EDIT-COLOR-MIXER-HSL: a B&W photo keeps its Luminance targeted adj…
OneSlips Oct 25, 2026
03f32a4
Merge remote-tracking branch 'origin/main' into pr/color-mixer-hsl
OneSlips Oct 25, 2026
41d90a0
LR-EDIT-COLOR-MIXER-HSL: widgets::register takes the Ui on egui 0.37
OneSlips Oct 26, 2026
af0ec22
LR-EDIT-COLOR-MIXER-HSL: Point Color's picker is put down when its ta…
OneSlips Oct 26, 2026
db66f1e
Merge remote-tracking branch 'origin/main' into pr/color-mixer-hsl
OneSlips Oct 26, 2026
9a58ece
LR-EDIT-COLOR-MIXER-HSL: Color Mixer ends a slideshow and a drag prop…
OneSlips Oct 26, 2026
c116215
Merge remote-tracking branch 'origin/main' into pr/color-mixer-hsl
OneSlips Oct 26, 2026
ba9b126
LR-EDIT-COLOR-MIXER-HSL: the targeted adjustment samples a B&W profil…
OneSlips Oct 26, 2026
965135f
LR-EDIT-COLOR-MIXER-HSL: merge main (upstream file split)
OneSlips Oct 27, 2026
e870afd
LR-EDIT-COLOR-MIXER-HSL: merge main (integration batch 45)
OneSlips Oct 30, 2026
3e0efdf
LR-EDIT-COLOR-MIXER-HSL: the HSL group sliders name their imports aft…
OneSlips Oct 31, 2026
bcd31c2
LR-EDIT-COLOR-MIXER-HSL: merge main (#3430 integration round 3, #3390)
OneSlips Oct 31, 2026
3c9a695
LR-EDIT-COLOR-MIXER-HSL: B&W targeting sees the mixer's shifts; hidde…
OneSlips Oct 31, 2026
2361757
LR-EDIT-COLOR-MIXER-HSL: B&W probe keeps its profile's adjustments; o…
OneSlips Nov 1, 2026
9ec420b
LR-EDIT-COLOR-MIXER-HSL: in Solo Mode the Color Mixer puts down the C…
OneSlips Nov 1, 2026
70efdfc
LR-EDIT-COLOR-MIXER-HSL: the Solo Mode test covers a Curve on screen …
OneSlips Nov 1, 2026
a365e06
Merge main (3c6a9f2c47) into pr/color-mixer-hsl
FredApps Nov 26, 2026
37c950a
docking: the Color Mixer command brings Tools forward like the other …
FredApps Nov 26, 2026
bf8b73b
Merge main (fc10a3faa6) into pr/color-mixer-hsl
FredApps Nov 26, 2026
46532b6
Format import/job.rs as main's gate requires (rustfmt)
FredApps Nov 26, 2026
32b5e46
Merge main (b084f79e28) into pr/color-mixer-hsl
FredApps Nov 26, 2026
07a3f90
Merge main (85c38c487b) into pr/color-mixer-hsl
FredApps Nov 26, 2026
1e11dc3
Merge main (5ef158833b) into pr/color-mixer-hsl
FredApps Nov 26, 2026
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
16 changes: 13 additions & 3 deletions crates/engine/src/cmd/color.rs
Original file line number Diff line number Diff line change
Expand Up @@ -129,16 +129,26 @@ fn targeted(s: &mut Session, p: &Value) -> Result<Value> {
}
}
"hue" | "sat" | "lum" => {
// the hue the colour mixer sees there (the mixer and everything after it neutralized)
// (a B&W profile, as the Color Mixer panel shows it: its B&W mix)
let bw = d.treatment == Treatment::Bw || d.profile.id == "lc.mono" || d.profile.id.starts_with("lc.bw.");
// the hue the colour mixer sees there (the mixer and everything after it neutralized); the B&W mix
// comes after the mixer, so for it the mixer's own adjustments stay
let e = probe(s, c, x, y, |d| {
d.mixer = Default::default();
if !bw {
d.mixer = Default::default();
}
// (a B&W profile turns the render grey again: sample the source colour, with the profile's own
// adjustments before the mixer, its contrast say, and its other options kept)
if d.profile.id == "lc.mono" || d.profile.id.starts_with("lc.bw.") {
*d = lightcraft_pipeline::profiles::effective(d).into_owned();
d.profile.id = "lc.color".into();
}
d.bw_mix = Default::default();
after_mixer_neutral(d);
})?;
let [_, _, h] = encoded_to_oklch(e);
let w = lightcraft_pipeline::colorops::band_weights(h);
let top = w.iter().cloned().fold(0.0f32, f32::max).max(1e-6);
let bw = d.treatment == Treatment::Bw || d.profile.id == "lc.mono";
label = if bw { "B&W Mix" } else { "Color Mixer" };
for (i, band) in MIXER_BANDS.iter().enumerate() {
let k = (w[i] / top) as f64;
Expand Down
16 changes: 7 additions & 9 deletions crates/engine/src/import/job.rs
Original file line number Diff line number Diff line change
Expand Up @@ -398,15 +398,13 @@ impl ImportJob {
let external_sidecar = if skip_sidecar {
None
} else {
found_sidecar
.and_then(|f| std::fs::read_to_string(f).ok())
.and_then(|x| match crate::sidecar::parse_sidecar(&x, target) {
Ok(sc) => Some(sc),
Err(e) => {
log::warn!("import {path}: XMP: {e}");
None
}
})
found_sidecar.and_then(|f| std::fs::read_to_string(f).ok()).and_then(|x| match crate::sidecar::parse_sidecar(&x, target) {
Ok(sc) => Some(sc),
Err(e) => {
log::warn!("import {path}: XMP: {e}");
None
}
})
};
let sidecar = match (embedded_sidecar, external_sidecar) {
(Some(mut embedded), Some(external)) => {
Expand Down
24 changes: 24 additions & 0 deletions crates/engine/src/tests/color.rs
Original file line number Diff line number Diff line change
Expand Up @@ -125,7 +125,31 @@ fn targeted_adjustment_on_curve_and_mixer() {
assert!(!o.is_empty() && o.keys().all(|k| k.starts_with("mixer.") && k.ends_with(".sat")), "{r}");
assert!(o.values().any(|v| v.as_f64() == Some(-30.0)), "{r}");
assert!(o.values().all(|v| v.as_f64().unwrap() < 0.0));
let top_band = |o: &serde_json::Map<String, serde_json::Value>| {
let (k, _) = o.iter().max_by(|a, b| a.1.as_f64().unwrap().abs().total_cmp(&b.1.as_f64().unwrap().abs())).unwrap();
k.split('.').nth(1).unwrap().to_string()
};
let sky_band = top_band(o);
assert!(s.execute("develop.targeted", &json!({"target": "nope", "x": 0.5, "y": 0.5, "delta": 1})).is_err());
// a B&W profile's photo: the Luminance targeted adjustment moves its B&W mix, as the panel shows
s.execute("develop.profile", &json!({"id": "lc.bw.mono-rich"})).unwrap();
let r = s.execute("develop.targeted", &json!({"target": "lum", "x": 0.5, "y": 0.1, "delta": 10})).unwrap();
let o = r.as_object().unwrap();
assert!(!o.is_empty() && o.keys().all(|k| k.starts_with("bw.")), "{r}");
// ... the band of the sky's own colour, not of the grey the profile renders
assert_eq!(top_band(o), sky_band, "{r}");
// the B&W mix comes after the colour mixer: a mixer hue shift moves the colour the B&W mix sees there, so the
// same drag shares itself out over the bands differently
let neutral = o.clone();
let zero: serde_json::Map<String, serde_json::Value> = neutral.keys().map(|k| (k.clone(), json!(0))).collect();
s.execute("develop.set", &json!({ "values": zero })).unwrap();
let shift: serde_json::Map<String, serde_json::Value> =
lightcraft_develop::MIXER_BANDS.iter().map(|b| (format!("mixer.{b}.hue"), json!(100))).collect();
s.execute("develop.set", &json!({ "values": shift })).unwrap();
let r = s.execute("develop.targeted", &json!({"target": "lum", "x": 0.5, "y": 0.1, "delta": 10})).unwrap();
let shifted = r.as_object().unwrap();
assert!(shifted.keys().all(|k| k.starts_with("bw.")), "{r}");
assert_ne!(shifted, &neutral, "the mixer's hue shift is part of what the B&W mix sees");
}

/// Issue #730: on a raw whose camera has measured colour matrices the white-balance commands write Kelvin, mark
Expand Down
2 changes: 1 addition & 1 deletion crates/engine/src/tests/folders.rs
Original file line number Diff line number Diff line change
Expand Up @@ -728,7 +728,7 @@ fn a_date_folder_inside_the_library_can_be_renamed_but_the_librarys_own_folders_
assert_eq!(r["relinked"], 1, "the photo inside is relinked");
assert!(lib.join("Originals/Beach").is_dir(), "the imported date folder is renamed");
assert!(!Path::new(&day).exists());
let moved = lib.join("Originals/Beach/a.jpg");
let moved = lib.join("Originals").join("Beach").join("a.jpg");
assert_eq!(paths(&s), [moved.to_string_lossy().to_string()], "the catalog follows the photo");
assert!(moved.is_file());
s.execute("edit.undo", &json!({})).unwrap();
Expand Down
4 changes: 4 additions & 0 deletions crates/ui-egui/locales/cs.json
Original file line number Diff line number Diff line change
Expand Up @@ -2452,6 +2452,10 @@
"The photos are imported once it ends": "Fotky se naimportují potom",
"An import is running. Drop photos when it has finished": "Import už běží. Fotky přetáhněte, až skončí",
"Finish Lightroom catalog import before adding photos": "Dokončete import katalogu Lightroom, než přidáte fotky",
"Mixer": "Směšovač",
"HSL": "HSL",
"Adjust": "Upravit",
"Color Mixer Layout": "Rozvržení směšovače barev",
"Profile: from the file (the camera's own correction)": "Profil: ze souboru (vlastní korekce fotoaparátu)",
"Downloading the lens database…": "Stahuje se databáze objektivů…",
"This file names no lens.": "Tento soubor neuvádí žádný objektiv.",
Expand Down
4 changes: 4 additions & 0 deletions crates/ui-egui/locales/de.json
Original file line number Diff line number Diff line change
Expand Up @@ -3508,6 +3508,10 @@
"The photos are imported once it ends": "Die Fotos werden danach importiert",
"An import is running. Drop photos when it has finished": "Ein Import läuft. Lege die Fotos ab, wenn er fertig ist",
"Finish Lightroom catalog import before adding photos": "Schließe den Import des Lightroom-Katalogs ab, bevor du Fotos hinzufügst",
"Mixer": "Mischer",
"HSL": "HSL",
"Adjust": "Anpassen",
"Color Mixer Layout": "Farbmischer-Ansicht",
"Camera preview": "Kameravorschau",
"The camera's own JPEG, shown until LightCraft has rendered the raw. Judge colour and tone on the rendered photo.": "Das eigene JPEG der Kamera, angezeigt, bis LightCraft die Raw-Datei gerendert hat. Farbe und Tonwerte am gerenderten Foto beurteilen.",
"Profile: from the file (the camera's own correction)": "Profil: aus der Datei (Korrektur der Kamera)",
Expand Down
4 changes: 4 additions & 0 deletions crates/ui-egui/locales/es.json
Original file line number Diff line number Diff line change
Expand Up @@ -2403,6 +2403,10 @@
"The photos are imported once it ends": "Las fotos se importarán después",
"An import is running. Drop photos when it has finished": "Hay una importación en curso. Suelta las fotos cuando termine",
"Finish Lightroom catalog import before adding photos": "Termina la importación del catálogo de Lightroom antes de añadir fotos",
"Mixer": "Mezclador",
"HSL": "HSL",
"Adjust": "Ajustar",
"Color Mixer Layout": "Disposición del mezclador de color",
"Camera preview": "Vista previa de la cámara",
"The camera's own JPEG, shown until LightCraft has rendered the raw. Judge colour and tone on the rendered photo.": "El JPEG propio de la cámara, mostrado hasta que LightCraft haya renderizado el RAW. Juzga el color y el tono en la foto renderizada.",
"Profile: from the file (the camera's own correction)": "Perfil: del archivo (corrección de la propia cámara)",
Expand Down
4 changes: 4 additions & 0 deletions crates/ui-egui/locales/fr.json
Original file line number Diff line number Diff line change
Expand Up @@ -2434,6 +2434,10 @@
"The photos are imported once a library is open": "Les photos seront importées dès qu'une bibliothèque sera ouverte",
"Open a library first, then drop the presets again": "Ouvrez d'abord une bibliothèque, puis déposez à nouveau les préréglages",
"This library couldn't be checked:": "Impossible de vérifier cette bibliothèque :",
"Mixer": "Mélangeur",
"HSL": "TSL",
"Adjust": "Régler",
"Color Mixer Layout": "Disposition du mélangeur de couleurs",
"Camera preview": "Aperçu de l'appareil",
"The camera's own JPEG, shown until LightCraft has rendered the raw. Judge colour and tone on the rendered photo.": "Le JPEG de l'appareil photo, affiché jusqu'à ce que LightCraft ait rendu le fichier RAW. Jugez la couleur et les tons sur la photo rendue.",
"Profile: from the file (the camera's own correction)": "Profil : du fichier (correction de l'appareil)",
Expand Down
4 changes: 4 additions & 0 deletions crates/ui-egui/locales/it.json
Original file line number Diff line number Diff line change
Expand Up @@ -2446,6 +2446,10 @@
"The photos are imported once it ends": "Le foto verranno importate dopo",
"An import is running. Drop photos when it has finished": "Un'importazione è in corso. Trascina le foto quando è finita",
"Finish Lightroom catalog import before adding photos": "Termina l'importazione del catalogo Lightroom prima di aggiungere foto",
"Mixer": "Miscelatore",
"HSL": "HSL",
"Adjust": "Regola",
"Color Mixer Layout": "Disposizione del miscelatore colore",
"Profile: from the file (the camera's own correction)": "Profilo: dal file (correzione della fotocamera)",
"Downloading the lens database…": "Download del database degli obiettivi…",
"This file names no lens.": "Questo file non indica alcun obiettivo.",
Expand Down
4 changes: 4 additions & 0 deletions crates/ui-egui/locales/ja.json
Original file line number Diff line number Diff line change
Expand Up @@ -2401,6 +2401,10 @@
"The photos are imported once it ends": "終わりしだい写真を読み込みます",
"An import is running. Drop photos when it has finished": "読み込み中です。完了してから写真をドロップしてください",
"Finish Lightroom catalog import before adding photos": "写真を追加する前に Lightroom カタログの読み込みを完了してください",
"Mixer": "ミキサー",
"HSL": "HSL",
"Adjust": "調整",
"Color Mixer Layout": "カラーミキサーの表示",
"Camera preview": "カメラのプレビュー",
"The camera's own JPEG, shown until LightCraft has rendered the raw. Judge colour and tone on the rendered photo.": "LightCraft が RAW を現像するまで表示される、カメラ自身の JPEG です。色とトーンは現像後の写真で判断してください。",
"Profile: from the file (the camera's own correction)": "プロファイル: ファイル内(カメラ自身の補正)",
Expand Down
4 changes: 4 additions & 0 deletions crates/ui-egui/locales/pl.json
Original file line number Diff line number Diff line change
Expand Up @@ -2327,6 +2327,10 @@
"The photos are imported once it ends": "Zdjęcia zostaną zaimportowane potem",
"An import is running. Drop photos when it has finished": "Import jest w toku. Upuść zdjęcia, gdy się zakończy",
"Finish Lightroom catalog import before adding photos": "Zakończ import katalogu Lightrooma, zanim dodasz zdjęcia",
"Mixer": "Mikser",
"HSL": "HSL",
"Adjust": "Dostosuj",
"Color Mixer Layout": "Układ miksera kolorów",
"Profile: from the file (the camera's own correction)": "Profil: z pliku (korekcja aparatu)",
"Downloading the lens database…": "Pobieranie bazy obiektywów…",
"This file names no lens.": "Ten plik nie podaje obiektywu.",
Expand Down
4 changes: 4 additions & 0 deletions crates/ui-egui/locales/pt-br.json
Original file line number Diff line number Diff line change
Expand Up @@ -2247,6 +2247,10 @@
"The photos are imported once it ends": "As fotos serão importadas depois",
"An import is running. Drop photos when it has finished": "Uma importação está em andamento. Solte as fotos quando ela terminar",
"Finish Lightroom catalog import before adding photos": "Conclua a importação do catálogo do Lightroom antes de adicionar fotos",
"Mixer": "Misturador",
"HSL": "HSL",
"Adjust": "Ajustar",
"Color Mixer Layout": "Disposição do misturador de cores",
"Camera preview": "Prévia da câmera",
"The camera's own JPEG, shown until LightCraft has rendered the raw. Judge colour and tone on the rendered photo.": "O JPEG da própria câmera, mostrado até o LightCraft renderizar o RAW. Avalie cor e tom na foto renderizada.",
"Profile: from the file (the camera's own correction)": "Perfil: do arquivo (correção da própria câmera)",
Expand Down
4 changes: 4 additions & 0 deletions crates/ui-egui/locales/ru.json
Original file line number Diff line number Diff line change
Expand Up @@ -2609,6 +2609,10 @@
"The photos are imported once it ends": "Фото будут импортированы после этого",
"An import is running. Drop photos when it has finished": "Импорт уже выполняется. Перетащите фото, когда он закончится",
"Finish Lightroom catalog import before adding photos": "Завершите импорт каталога Lightroom, прежде чем добавлять фото",
"Mixer": "Микшер",
"HSL": "HSL",
"Adjust": "Настройка",
"Color Mixer Layout": "Вид цветового микшера",
"Camera preview": "Превью камеры",
"The camera's own JPEG, shown until LightCraft has rendered the raw. Judge colour and tone on the rendered photo.": "Собственный JPEG камеры, показанный, пока LightCraft не обработает RAW. Оценивайте цвет и тон по обработанному фото.",
"Profile: from the file (the camera's own correction)": "Профиль: из файла (коррекция самой камеры)",
Expand Down
4 changes: 4 additions & 0 deletions crates/ui-egui/locales/uk.json
Original file line number Diff line number Diff line change
Expand Up @@ -2399,6 +2399,10 @@
"The photos are imported once it ends": "Фото буде імпортовано після цього",
"An import is running. Drop photos when it has finished": "Імпорт уже виконується. Перетягніть фото, коли він завершиться",
"Finish Lightroom catalog import before adding photos": "Завершіть імпорт каталогу Lightroom, перш ніж додавати фото",
"Mixer": "Змішувач",
"HSL": "HSL",
"Adjust": "Налаштування",
"Color Mixer Layout": "Вигляд змішувача кольорів",
"Camera preview": "Прев'ю камери",
"The camera's own JPEG, shown until LightCraft has rendered the raw. Judge colour and tone on the rendered photo.": "Власний JPEG камери, показаний, доки LightCraft не обробить RAW. Оцінюйте колір і тон за обробленим фото.",
"Profile: from the file (the camera's own correction)": "Профіль: з файлу (корекція самої камери)",
Expand Down
4 changes: 4 additions & 0 deletions crates/ui-egui/locales/zh-hans.json
Original file line number Diff line number Diff line change
Expand Up @@ -2246,6 +2246,10 @@
"The photos are imported once it ends": "结束后即导入这些照片",
"An import is running. Drop photos when it has finished": "正在导入。导入完成后再拖放照片",
"Finish Lightroom catalog import before adding photos": "添加照片前,请先完成 Lightroom 目录的导入",
"Mixer": "混合器",
"HSL": "HSL",
"Adjust": "调整",
"Color Mixer Layout": "颜色混合器布局",
"Camera preview": "相机预览",
"The camera's own JPEG, shown until LightCraft has rendered the raw. Judge colour and tone on the rendered photo.": "相机自己的 JPEG,在 LightCraft 渲染出原始文件之前显示。请在渲染后的照片上判断颜色和影调。",
"Profile: from the file (the camera's own correction)": "配置文件:来自文件(相机自身的校正)",
Expand Down
4 changes: 4 additions & 0 deletions crates/ui-egui/locales/zh-hant.json
Original file line number Diff line number Diff line change
Expand Up @@ -2203,6 +2203,10 @@
"The photos are imported once it ends": "結束後即匯入這些照片",
"An import is running. Drop photos when it has finished": "正在匯入。匯入完成後再拖放照片",
"Finish Lightroom catalog import before adding photos": "新增照片前,請先完成 Lightroom 目錄的匯入",
"Mixer": "混合器",
"HSL": "HSL",
"Adjust": "調整",
"Color Mixer Layout": "混色器版面",
"Camera preview": "相機預覽",
"The camera's own JPEG, shown until LightCraft has rendered the raw. Judge colour and tone on the rendered photo.": "相機自己的 JPEG,在 LightCraft 算繪出原始檔之前顯示。請在算繪後的照片上判斷色彩與色調。",
"Profile: from the file (the camera's own correction)": "設定檔:來自檔案(相機本身的校正)",
Expand Down
1 change: 1 addition & 0 deletions crates/ui-egui/src/docking.rs
Original file line number Diff line number Diff line change
Expand Up @@ -280,6 +280,7 @@ pub(crate) fn reveal_command(app: &mut crate::LightcraftApp, id: &str) -> Result
Some(Panel::Library)
} else if (id.starts_with("panel.") && id != "panel.close" && id != "panel.presets"
|| id == "view.rightPanel"
|| id == "view.colorMixer"
|| id.starts_with("section.")
|| id.starts_with("tool.") && id != "tool.none")
&& app.ui.right != crate::state::RightPanel::None
Expand Down
Loading
Loading