diff --git a/crates/effects/src/pixel/sketch.rs b/crates/effects/src/pixel/sketch.rs index 588d1ca80..476363db3 100644 --- a/crates/effects/src/pixel/sketch.rs +++ b/crates/effects/src/pixel/sketch.rs @@ -232,7 +232,11 @@ pub(super) fn plaster_reach(smoothness: f64) -> f64 { /// light areas recessed; `imageBalance` (1..50) shifts more of the image lower at higher values; /// `smoothness` (1..15) softens the relief. Coverage is kept. pub(super) fn plaster(px: &mut [[u8; 4]], w: usize, h: usize, space: &PixelSpace, image_balance: f64, smoothness: f64, light: Light) { - if !(image_balance.is_finite() && smoothness.is_finite() && space.px.is_finite() && space.px > 0.0) || w == 0 || h == 0 || w.checked_mul(h) != Some(px.len()) { + if !(image_balance.is_finite() && smoothness.is_finite() && space.px.is_finite() && space.px > 0.0) + || w == 0 + || h == 0 + || w.checked_mul(h) != Some(px.len()) + { return; } let image_balance = image_balance.clamp(1.0, 50.0); diff --git a/crates/effects/src/pixel/tests.rs b/crates/effects/src/pixel/tests.rs index 87d9e420a..bcbdfac17 100644 --- a/crates/effects/src/pixel/tests.rs +++ b/crates/effects/src/pixel/tests.rs @@ -2160,10 +2160,7 @@ fn plaster(p: serde_json::Value, src: &[u8], w: usize, h: usize, s: &PixelSpace) #[test] fn plaster_params_take_defaults_and_stay_in_range() { use super::texture::Light; - assert_eq!( - fx("sketch.plaster", json!({})), - PixelFx::Plaster { image_balance: 20.0, smoothness: 8.0, light: Light::Top } - ); + assert_eq!(fx("sketch.plaster", json!({})), PixelFx::Plaster { image_balance: 20.0, smoothness: 8.0, light: Light::Top }); assert_eq!( fx("sketch.plaster", json!({"imageBalance": 0, "smoothness": 1e9, "lightDirection": "bottomRight"})), PixelFx::Plaster { image_balance: 1.0, smoothness: 15.0, light: Light::BottomRight } diff --git a/crates/ui-egui/src/i18n/bg.tsv b/crates/ui-egui/src/i18n/bg.tsv index b01016844..a84c10959 100644 --- a/crates/ui-egui/src/i18n/bg.tsv +++ b/crates/ui-egui/src/i18n/bg.tsv @@ -5203,3 +5203,5 @@ theme Appearance Външен вид Plastic Wrap Найлоново фолио Chrome… Хром… Chrome Хром + Plaster… Гипс… + Plaster Гипс diff --git a/crates/ui-egui/src/i18n/cs.tsv b/crates/ui-egui/src/i18n/cs.tsv index 8f0ad0aba..9745ed8cf 100644 --- a/crates/ui-egui/src/i18n/cs.tsv +++ b/crates/ui-egui/src/i18n/cs.tsv @@ -5242,3 +5242,5 @@ mark-style Japanese Japonské Plastic Wrap Plastová fólie Chrome… Chrom… Chrome Chrom + Plaster… Sádra… + Plaster Sádra diff --git a/crates/ui-egui/src/i18n/da.tsv b/crates/ui-egui/src/i18n/da.tsv index beab97f81..c0c68c2c1 100644 --- a/crates/ui-egui/src/i18n/da.tsv +++ b/crates/ui-egui/src/i18n/da.tsv @@ -5221,3 +5221,5 @@ swatch Bright Violet Kraftig violet Plastic Wrap Plastfolie Chrome… Krom… Chrome Krom + Plaster… Gips… + Plaster Gips diff --git a/crates/ui-egui/src/i18n/de.tsv b/crates/ui-egui/src/i18n/de.tsv index 4d29a40f8..a8011cba1 100644 --- a/crates/ui-egui/src/i18n/de.tsv +++ b/crates/ui-egui/src/i18n/de.tsv @@ -4822,3 +4822,5 @@ effect Soft Weich Plastic Wrap Kunststofffolie Chrome… Chrom… Chrome Chrom + Plaster… Gipsabdruck… + Plaster Gipsabdruck diff --git a/crates/ui-egui/src/i18n/el.tsv b/crates/ui-egui/src/i18n/el.tsv index 2ecfe8411..6ec6d92c2 100644 --- a/crates/ui-egui/src/i18n/el.tsv +++ b/crates/ui-egui/src/i18n/el.tsv @@ -5194,3 +5194,5 @@ effect Points Σημεία Plastic Wrap Πλαστική μεμβράνη Chrome… Χρώμιο… Chrome Χρώμιο + Plaster… Γύψος… + Plaster Γύψος diff --git a/crates/ui-egui/src/i18n/es.tsv b/crates/ui-egui/src/i18n/es.tsv index ea647ebf5..c85eeae22 100644 --- a/crates/ui-egui/src/i18n/es.tsv +++ b/crates/ui-egui/src/i18n/es.tsv @@ -5184,3 +5184,5 @@ mark-style Japanese Japonesas Plastic Wrap Envoltura plástica Chrome… Cromo… Chrome Cromo + Plaster… Yeso… + Plaster Yeso diff --git a/crates/ui-egui/src/i18n/fi.tsv b/crates/ui-egui/src/i18n/fi.tsv index 30e8fe84b..4720ba121 100644 --- a/crates/ui-egui/src/i18n/fi.tsv +++ b/crates/ui-egui/src/i18n/fi.tsv @@ -5273,3 +5273,5 @@ swatch Bright Violet Kirkas violetti Plastic Wrap Muovikalvo Chrome… Kromi… Chrome Kromi + Plaster… Kipsi… + Plaster Kipsi diff --git a/crates/ui-egui/src/i18n/fr.tsv b/crates/ui-egui/src/i18n/fr.tsv index eaedd3546..2364e13f8 100644 --- a/crates/ui-egui/src/i18n/fr.tsv +++ b/crates/ui-egui/src/i18n/fr.tsv @@ -5241,3 +5241,5 @@ theme Appearance Apparence Plastic Wrap Emballage plastique Chrome… Chrome… Chrome Chrome + Plaster… Plâtre… + Plaster Plâtre diff --git a/crates/ui-egui/src/i18n/hu.tsv b/crates/ui-egui/src/i18n/hu.tsv index e00e91a33..972d0e299 100644 --- a/crates/ui-egui/src/i18n/hu.tsv +++ b/crates/ui-egui/src/i18n/hu.tsv @@ -5228,3 +5228,5 @@ imageTrace Outline Körvonal Plastic Wrap Fóliázás Chrome… Króm… Chrome Króm + Plaster… Gipsz… + Plaster Gipsz diff --git a/crates/ui-egui/src/i18n/id.tsv b/crates/ui-egui/src/i18n/id.tsv index 360b2b5bf..2fa8c821a 100644 --- a/crates/ui-egui/src/i18n/id.tsv +++ b/crates/ui-egui/src/i18n/id.tsv @@ -5221,3 +5221,5 @@ swatch Bright Violet Violet cerah Plastic Wrap Pembungkus plastik Chrome… Krom… Chrome Krom + Plaster… Plester… + Plaster Plester diff --git a/crates/ui-egui/src/i18n/it.tsv b/crates/ui-egui/src/i18n/it.tsv index 08041f38e..51578219c 100644 --- a/crates/ui-egui/src/i18n/it.tsv +++ b/crates/ui-egui/src/i18n/it.tsv @@ -4856,3 +4856,5 @@ lighting Light Luce Plastic Wrap Pellicola plastica Chrome… Cromo… Chrome Cromo + Plaster… Gesso… + Plaster Gesso diff --git a/crates/ui-egui/src/i18n/ja.tsv b/crates/ui-egui/src/i18n/ja.tsv index 069493316..03587316c 100644 --- a/crates/ui-egui/src/i18n/ja.tsv +++ b/crates/ui-egui/src/i18n/ja.tsv @@ -4896,3 +4896,5 @@ lighting Light ライト Plastic Wrap ラップ Chrome… クロム… Chrome クロム + Plaster… 石膏… + Plaster 石膏 diff --git a/crates/ui-egui/src/i18n/ka.tsv b/crates/ui-egui/src/i18n/ka.tsv index 0771630b6..46271dd56 100644 --- a/crates/ui-egui/src/i18n/ka.tsv +++ b/crates/ui-egui/src/i18n/ka.tsv @@ -5149,3 +5149,5 @@ imageTrace Outline კონტური Plastic Wrap პლასტიკური აფსკი Chrome… ქრომი… Chrome ქრომი + Plaster… თაბაშირი… + Plaster თაბაშირი diff --git a/crates/ui-egui/src/i18n/ko.tsv b/crates/ui-egui/src/i18n/ko.tsv index 7bf157511..8dfe464a8 100644 --- a/crates/ui-egui/src/i18n/ko.tsv +++ b/crates/ui-egui/src/i18n/ko.tsv @@ -4819,3 +4819,5 @@ lighting Light 광원 Plastic Wrap 비닐 랩 Chrome… 크롬… Chrome 크롬 + Plaster… 석고… + Plaster 석고 diff --git a/crates/ui-egui/src/i18n/nl.tsv b/crates/ui-egui/src/i18n/nl.tsv index dfb0f3f7c..fa7b0c324 100644 --- a/crates/ui-egui/src/i18n/nl.tsv +++ b/crates/ui-egui/src/i18n/nl.tsv @@ -5263,3 +5263,5 @@ swatch Bright Violet Felviolet Plastic Wrap Plasticfolie Chrome… Chroom… Chrome Chroom + Plaster… Gips… + Plaster Gips diff --git a/crates/ui-egui/src/i18n/pl.tsv b/crates/ui-egui/src/i18n/pl.tsv index 42c4f7030..925ce2a44 100644 --- a/crates/ui-egui/src/i18n/pl.tsv +++ b/crates/ui-egui/src/i18n/pl.tsv @@ -5094,3 +5094,5 @@ mark-style Japanese Japońskie Plastic Wrap Folia plastikowa Chrome… Chrom… Chrome Chrom + Plaster… Gips… + Plaster Gips diff --git a/crates/ui-egui/src/i18n/pt-br.tsv b/crates/ui-egui/src/i18n/pt-br.tsv index 1292d1b83..e20f5f939 100644 --- a/crates/ui-egui/src/i18n/pt-br.tsv +++ b/crates/ui-egui/src/i18n/pt-br.tsv @@ -5159,3 +5159,5 @@ mark-style Japanese Japonesas Plastic Wrap Envoltório plástico Chrome… Cromo… Chrome Cromo + Plaster… Gesso… + Plaster Gesso diff --git a/crates/ui-egui/src/i18n/ru.tsv b/crates/ui-egui/src/i18n/ru.tsv index c48ad912c..da2e97929 100644 --- a/crates/ui-egui/src/i18n/ru.tsv +++ b/crates/ui-egui/src/i18n/ru.tsv @@ -4852,3 +4852,5 @@ lighting Light Свет Plastic Wrap Целлофановая упаковка Chrome… Хром… Chrome Хром + Plaster… Гипс… + Plaster Гипс diff --git a/crates/ui-egui/src/i18n/sv.tsv b/crates/ui-egui/src/i18n/sv.tsv index e83f7408e..2b21ab374 100644 --- a/crates/ui-egui/src/i18n/sv.tsv +++ b/crates/ui-egui/src/i18n/sv.tsv @@ -5198,3 +5198,5 @@ theme Appearance Utseende Plastic Wrap Plastfolie Chrome… Krom… Chrome Krom + Plaster… Gips… + Plaster Gips diff --git a/crates/ui-egui/src/i18n/uk.tsv b/crates/ui-egui/src/i18n/uk.tsv index bbb49c152..8f2e6324e 100644 --- a/crates/ui-egui/src/i18n/uk.tsv +++ b/crates/ui-egui/src/i18n/uk.tsv @@ -4836,3 +4836,5 @@ lighting Light Світло Plastic Wrap Целофанова плівка Chrome… Хром… Chrome Хром + Plaster… Гіпс… + Plaster Гіпс diff --git a/crates/ui-egui/src/i18n/vi.tsv b/crates/ui-egui/src/i18n/vi.tsv index ee5c78ffd..d9c14a01b 100644 --- a/crates/ui-egui/src/i18n/vi.tsv +++ b/crates/ui-egui/src/i18n/vi.tsv @@ -4836,3 +4836,5 @@ theme Appearance Giao diện Plastic Wrap Màng bọc nhựa Chrome… Crôm… Chrome Crôm + Plaster… Thạch cao… + Plaster Thạch cao diff --git a/crates/ui-egui/src/i18n/zh-hans.tsv b/crates/ui-egui/src/i18n/zh-hans.tsv index 4bd7b84e3..25e05d8c7 100644 --- a/crates/ui-egui/src/i18n/zh-hans.tsv +++ b/crates/ui-egui/src/i18n/zh-hans.tsv @@ -5079,3 +5079,5 @@ lighting Light 光源 Plastic Wrap 塑料包装 Chrome… 铬黄… Chrome 铬黄 + Plaster… 塑料效果… + Plaster 塑料效果 diff --git a/crates/ui-egui/src/i18n/zh-hant.tsv b/crates/ui-egui/src/i18n/zh-hant.tsv index f83912b47..b982b9c39 100644 --- a/crates/ui-egui/src/i18n/zh-hant.tsv +++ b/crates/ui-egui/src/i18n/zh-hant.tsv @@ -4874,3 +4874,5 @@ lighting Light 光源 Plastic Wrap 塑膠包裝 Chrome… 鉻黃… Chrome 鉻黃 + Plaster… 塑膠效果… + Plaster 塑膠效果