From 37de3d7b0aab9d681baa2d33877b78e43d96a49a Mon Sep 17 00:00:00 2001 From: Bruno-Alumn <171815746+Bruno-Alumn@users.noreply.github.com> Date: Thu, 5 Nov 2026 19:52:59 +0100 Subject: [PATCH 01/61] Find Similar test: a photo read from memory isn't a missing read (#3823) The second search after a stop plans its reads after frames in which the loupe and filmstrip decoded photos; those are measured from memory (source_ref takes the cached source), so the drive sees fewer than 12 reads on a loaded machine. Check instead that no file is read twice, the searched photo above all; the answer still needs every photo's signature. --- crates/ui-egui/src/tests/find_similar.rs | 25 ++++++++++++++++++++---- 1 file changed, 21 insertions(+), 4 deletions(-) diff --git a/crates/ui-egui/src/tests/find_similar.rs b/crates/ui-egui/src/tests/find_similar.rs index b75995a1ca..40a4c5385c 100644 --- a/crates/ui-egui/src/tests/find_similar.rs +++ b/crates/ui-egui/src/tests/find_similar.rs @@ -2,9 +2,9 @@ //! responding for as long as that took (issue #3468): the photos are read on a worker thread under a //! row of the activity stack. -use std::sync::Arc; use std::sync::atomic::{AtomicBool, AtomicUsize, Ordering}; use std::sync::mpsc::Receiver; +use std::sync::{Arc, Mutex}; use std::time::{Duration, Instant}; use lightcraft_catalog::{Op, Photo, PhotoId, Source}; @@ -27,6 +27,8 @@ const FRAMES: Duration = Duration::from_secs(15); struct Drive { open: Arc, reads: Arc, + /// The files the search read, in order. + read: Arc>>, on_ui: Arc, } @@ -37,14 +39,21 @@ fn app_on_a_slow_drive(guard: Duration) -> (Headless, Drive) { let p = Photo::new(PhotoId(i + 1), Source::File { path }, &format!("IMG_{i:04}.arw"), "ARW", 64, 64, "2026-01-01T00:00:00"); app.session.catalog.apply(Op::AddPhoto { photo: Box::new(p) }).unwrap(); } - let drive = Drive { open: Arc::new(AtomicBool::new(false)), reads: Arc::new(AtomicUsize::new(0)), on_ui: Arc::new(AtomicUsize::new(0)) }; - let (ui, open, reads, on_ui) = (std::thread::current().id(), drive.open.clone(), drive.reads.clone(), drive.on_ui.clone()); + let drive = Drive { + open: Arc::new(AtomicBool::new(false)), + reads: Arc::new(AtomicUsize::new(0)), + read: Arc::new(Mutex::new(Vec::new())), + on_ui: Arc::new(AtomicUsize::new(0)), + }; + let (ui, open, reads, read, on_ui) = + (std::thread::current().id(), drive.open.clone(), drive.reads.clone(), drive.read.clone(), drive.on_ui.clone()); let deadline = Instant::now() + guard; app.session.media.file_loader = Some(Arc::new(move |path: &str, _, _| { // (the grid reads the photos for its thumbnails too, on threads of its own) let thread = std::thread::current(); if thread.name().is_some_and(|n| n.starts_with("similar-") || n.contains(LABEL)) { reads.fetch_add(1, Ordering::SeqCst); + read.lock().unwrap().push(path.to_string()); } if thread.id() == ui { on_ui.fetch_add(1, Ordering::SeqCst); @@ -161,7 +170,15 @@ fn stopping_leaves_the_view_alone_and_the_next_search_reads_only_the_rest() { let r = h.app.run("library.findSimilar", json!({"id": 1})).unwrap(); assert_eq!(r["count"], PHOTOS - 1, "what was read isn't read again"); until_done(&mut h); - assert_eq!(drive.reads.load(Ordering::SeqCst), PHOTOS as usize); + // A photo the loupe or the filmstrip decoded meanwhile is measured from memory, without a read + // (issue #3823: 10 or 11 reads of 12 on a loaded machine), so what is checked is that no file + // was read twice, the searched photo's above all; the answer below needs every photo. + let read = drive.read.lock().unwrap().clone(); + let mut once = read.clone(); + once.sort(); + once.dedup(); + assert_eq!(once.len(), read.len(), "a file was read twice: {read:?}"); + assert_eq!(read.iter().filter(|p| p.ends_with("IMG_0000.arw")).count(), 1, "the searched photo was read again: {read:?}"); assert_eq!(h.app.session.filter.only.len(), PHOTOS as usize / 2); } From aebb26c34503d9391a77593f512b47ee15c01ccd Mon Sep 17 00:00:00 2001 From: Bruno-Alumn <171815746+Bruno-Alumn@users.noreply.github.com> Date: Thu, 5 Nov 2026 20:54:40 +0100 Subject: [PATCH 02/61] Find Similar test: every photo is measured after the resumed search --- crates/ui-egui/src/tests/find_similar.rs | 2 ++ 1 file changed, 2 insertions(+) diff --git a/crates/ui-egui/src/tests/find_similar.rs b/crates/ui-egui/src/tests/find_similar.rs index 40a4c5385c..fa0032852d 100644 --- a/crates/ui-egui/src/tests/find_similar.rs +++ b/crates/ui-egui/src/tests/find_similar.rs @@ -179,6 +179,8 @@ fn stopping_leaves_the_view_alone_and_the_next_search_reads_only_the_rest() { once.dedup(); assert_eq!(once.len(), read.len(), "a file was read twice: {read:?}"); assert_eq!(read.iter().filter(|p| p.ends_with("IMG_0000.arw")).count(), 1, "the searched photo was read again: {read:?}"); + // and every photo was measured, from a read or from memory, not only the ones alike + assert_eq!(h.app.session.signatures.len(), PHOTOS as usize, "a photo was not measured"); assert_eq!(h.app.session.filter.only.len(), PHOTOS as usize / 2); } From 884956e27e48300585c46ef52f753968d41ec43e Mon Sep 17 00:00:00 2001 From: "Dylan M. Taylor" Date: Thu, 12 Nov 2026 00:53:36 +0000 Subject: [PATCH 03/61] Use craft-gainmap from craft-libs for gain map metadata and arithmetic crates/codecs/src/gainmap.rs keeps the JPEG layout (encode_jpeg, read_jpeg, is_gain_map_jpeg) and re-exports GainMapMeta, GainImage, GainMapOptions, ISO_URN, compute and apply from craft-gainmap, which is this file's metadata and arithmetic moved to craft-libs (storytold/craft-libs#904). The tests of the moved code went with it. --- Cargo.lock | 9 + Cargo.toml | 2 + crates/codecs/Cargo.toml | 1 + crates/codecs/src/gainmap.rs | 642 +---------------------------------- docs/file-format-parity.md | 2 +- 5 files changed, 22 insertions(+), 634 deletions(-) diff --git a/Cargo.lock b/Cargo.lock index 58e4b706e2..064783fb91 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -1199,6 +1199,14 @@ name = "craft-fonts-build" version = "0.1.0" source = "git+https://github.com/storytold/craft-libs?rev=c5a1cbfb5f9049f9270955caffb5bee5997aebf7#c5a1cbfb5f9049f9270955caffb5bee5997aebf7" +[[package]] +name = "craft-gainmap" +version = "0.1.0" +source = "git+https://github.com/storytold/craft-libs?rev=430a908f68819bf23d14fe73ab9b18d8f4fd4e5d#430a908f68819bf23d14fe73ab9b18d8f4fd4e5d" +dependencies = [ + "thiserror 2.0.21", +] + [[package]] name = "craft-heif" version = "0.1.0" @@ -3677,6 +3685,7 @@ version = "0.21.0" dependencies = [ "avif-serialize", "bytemuck", + "craft-gainmap", "craft-heif", "dhat", "image", diff --git a/Cargo.toml b/Cargo.toml index 28720cba93..427c091de8 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -17,6 +17,8 @@ craft-crw = { git = "https://github.com/storytold/craft-libs", rev = "f3b62ec61f # craft-update: app-specific pretend versions apply to startup and manual checks. craft-update = { git = "https://github.com/storytold/craft-libs", version = "=0.1.0", rev = "6e03f65bf45181db77ba6229716e6624db9eb25b", features = ["egui"] } craft-window = { git = "https://github.com/storytold/craft-libs", rev = "c5a1cbfb5f9049f9270955caffb5bee5997aebf7", features = ["egui"] } +# HDR gain maps: ISO 21496-1 and hdrgm metadata, compute and apply (moved from crates/codecs; craft-libs#904). +craft-gainmap = { git = "https://github.com/storytold/craft-libs", rev = "430a908f68819bf23d14fe73ab9b18d8f4fd4e5d" } # internal lightcraft-denoise-core = { path = "crates/denoise-core" } lightcraft-denoise = { path = "crates/denoise", default-features = false } diff --git a/crates/codecs/Cargo.toml b/crates/codecs/Cargo.toml index 2a766aeee7..019009d7c1 100644 --- a/crates/codecs/Cargo.toml +++ b/crates/codecs/Cargo.toml @@ -12,6 +12,7 @@ workspace = true lightcraft-geom = { workspace = true } lightcraft-color = { workspace = true } lightcraft-raster = { workspace = true } +craft-gainmap = { workspace = true } craft-heif = { workspace = true, optional = true } serde = { workspace = true } bytemuck = { workspace = true } diff --git a/crates/codecs/src/gainmap.rs b/crates/codecs/src/gainmap.rs index 9280314067..4a6f485818 100644 --- a/crates/codecs/src/gainmap.rs +++ b/crates/codecs/src/gainmap.rs @@ -1,547 +1,21 @@ -//! Gain map HDR images (ISO 21496-1): an SDR base image plus a gain map that a decoder uses to -//! rebuild the HDR rendition, so the file looks right everywhere and lights up on HDR displays. +//! Gain map JPEGs (ISO 21496-1): an SDR base image plus a gain map that a decoder uses to rebuild +//! the HDR rendition, so the file looks right everywhere and lights up on HDR displays. +//! +//! The metadata formats and the arithmetic ([`compute`], [`apply`], [`GainMapMeta`]) are +//! `craft-gainmap`'s, re-exported here. This module lays the two images out in a JPEG: //! -//! - [`compute`] measures a gain map from an SDR and an HDR rendition of the same picture (linear -//! light, same primaries). Measure it against the base *as written* (decoded from its 8-bit -//! codes), so quantisation in the base is handed back by the gain map. -//! - [`apply`] rebuilds the HDR rendition from a base and its gain map. //! - [`encode_jpeg`] writes a gain map JPEG: the base with an MPF index (CIPA DC-007), the ISO //! 21496-1 marker and Adobe/Google container XMP, followed by the gain map JPEG carrying the ISO //! 21496-1 metadata, the Adobe `hdrgm` XMP (Android, Chrome) and Apple's description of the same //! map (what survives an iMessage send). //! - [`read_jpeg`] finds and decodes the gain map of a gain map JPEG (ours, cameras, Lightroom), //! from its ISO 21496-1 metadata or, failing that, its `hdrgm` XMP. -//! -//! All gains are log2. A decoder recovers `log2(hdr + offset_hdr) − log2(sdr + offset_sdr)` as -//! `min + (max − min) · (code / 255)^(1 / gamma)`, scaled by a weight in 0..1 that depends on how -//! much headroom the display has between `base_headroom` and `alternate_headroom`. + +pub use craft_gainmap::{GainImage, GainMapMeta, GainMapOptions, ISO_URN, apply, compute}; use crate::encode::{EncodeImage, EncodeMeta, Samples, jpeg_app_segments, xmp_segment}; use crate::{ChromaSubsampling, Error, Format, Result, jpeg, jpeg_par}; -/// The ISO 21496-1 namespace that opens its APP2 payloads (NUL terminated). -pub const ISO_URN: &[u8] = b"urn:iso:std:iso:ts:21496:-1\0"; - -/// Fixed denominator for the metadata's rationals: one value per setting, byte-identical output. -const DENOMINATOR: u32 = 1_000_000; - -/// Gain map parameters (ISO 21496-1 / Adobe `hdrgm`). Per-channel arrays repeat the first value -/// when the map is single-channel. -#[derive(Clone, Copy, Debug, PartialEq)] -pub struct GainMapMeta { - /// Three gain channels (R, G, B) instead of one luminance gain. - pub multichannel: bool, - /// The gain applies in the base image's colour space. - pub use_base_colour_space: bool, - /// log2 headroom at which the base is shown as is (0: an SDR base). - pub base_headroom: f32, - /// log2 headroom at which the gain map applies in full. - pub alternate_headroom: f32, - pub min: [f32; 3], - pub max: [f32; 3], - pub gamma: [f32; 3], - pub base_offset: [f32; 3], - pub alternate_offset: [f32; 3], -} - -impl Default for GainMapMeta { - fn default() -> Self { - GainMapMeta { - multichannel: false, - use_base_colour_space: true, - base_headroom: 0.0, - alternate_headroom: 1.0, - min: [0.0; 3], - max: [1.0; 3], - gamma: [1.0; 3], - base_offset: [1.0 / 64.0; 3], - alternate_offset: [1.0 / 64.0; 3], - } - } -} - -impl GainMapMeta { - fn channels(&self) -> usize { - if self.multichannel { 3 } else { 1 } - } - - /// Usable by [`apply`]: finite, positive gammas, max ≥ min, headrooms in order. - pub fn is_valid(&self) -> bool { - let fin = |a: &[f32; 3]| a.iter().all(|v| v.is_finite()); - fin(&self.min) - && fin(&self.max) - && fin(&self.gamma) - && fin(&self.base_offset) - && fin(&self.alternate_offset) - && self.gamma.iter().all(|g| *g > 0.0) - && self.min.iter().zip(&self.max).all(|(a, b)| b >= a) - && self.base_headroom.is_finite() - && self.alternate_headroom.is_finite() - && self.alternate_headroom > self.base_headroom - } - - /// The ISO 21496-1 APP2 payload of the gain map image, URN included. - pub fn to_iso(&self) -> Vec { - let mut p = ISO_URN.to_vec(); - p.extend_from_slice(&0u16.to_be_bytes()); // minimum_version: readers gate on this - p.extend_from_slice(&0u16.to_be_bytes()); // writer_version - let mut flags = 0u8; - if self.multichannel { - flags |= FLAG_MULTICHANNEL; - } - if self.use_base_colour_space { - flags |= FLAG_BASE_COLOUR_SPACE; - } - p.push(flags); - let unsigned = |p: &mut Vec, v: f32| { - let n = (v as f64 * DENOMINATOR as f64).round().clamp(0.0, u32::MAX as f64) as u32; - p.extend_from_slice(&n.to_be_bytes()); - p.extend_from_slice(&DENOMINATOR.to_be_bytes()); - }; - let signed = |p: &mut Vec, v: f32| { - let n = (v as f64 * DENOMINATOR as f64).round().clamp(i32::MIN as f64, i32::MAX as f64) as i32; - p.extend_from_slice(&n.to_be_bytes()); - p.extend_from_slice(&DENOMINATOR.to_be_bytes()); - }; - unsigned(&mut p, self.base_headroom.max(0.0)); - unsigned(&mut p, self.alternate_headroom.max(0.0)); - for c in 0..self.channels() { - signed(&mut p, self.min[c]); - signed(&mut p, self.max[c]); - unsigned(&mut p, self.gamma[c]); - signed(&mut p, self.base_offset[c]); - signed(&mut p, self.alternate_offset[c]); - } - p - } - - /// Parse an ISO 21496-1 payload (the bytes after [`ISO_URN`]). `None` for the versions-only - /// marker a primary image carries, unknown versions, a base that is the HDR rendition, or - /// values no decoder could use. - pub fn from_iso(p: &[u8]) -> Option { - let mut r = Reader { b: p, at: 0 }; - let min_version = r.u16()?; - let _writer_version = r.u16()?; - if min_version != 0 { - return None; - } - let flags = r.u8()?; - if flags & FLAG_BACKWARD != 0 { - return None; - } - let multichannel = flags & FLAG_MULTICHANNEL != 0; - let common = flags & FLAG_COMMON_DENOMINATOR != 0; - let common_d = if common { r.u32()? } else { 0 }; - let unsigned = |r: &mut Reader| -> Option { - let n = r.u32()?; - let d = if common { common_d } else { r.u32()? }; - (d != 0).then(|| (n as f64 / d as f64) as f32) - }; - let signed = |r: &mut Reader| -> Option { - let n = r.u32()? as i32; - let d = if common { common_d } else { r.u32()? }; - (d != 0).then(|| (n as f64 / d as f64) as f32) - }; - let mut m = GainMapMeta { - multichannel, - use_base_colour_space: flags & FLAG_BASE_COLOUR_SPACE != 0, - base_headroom: unsigned(&mut r)?, - alternate_headroom: unsigned(&mut r)?, - ..GainMapMeta::default() - }; - for c in 0..m.channels() { - m.min[c] = signed(&mut r)?; - m.max[c] = signed(&mut r)?; - m.gamma[c] = unsigned(&mut r)?; - m.base_offset[c] = signed(&mut r)?; - m.alternate_offset[c] = signed(&mut r)?; - } - if !multichannel { - m.fill_from_first(); - } - m.is_valid().then_some(m) - } - - fn fill_from_first(&mut self) { - for a in [&mut self.min, &mut self.max, &mut self.gamma, &mut self.base_offset, &mut self.alternate_offset] { - a[1] = a[0]; - a[2] = a[0]; - } - } - - /// The gain parameters from Adobe `hdrgm` XMP (the gain map image's packet), for files - /// without ISO 21496-1 metadata (the first Ultra HDR files). Attributes or `rdf:Seq` lists. - pub fn from_hdrgm_xmp(xmp: &str) -> Option { - if !xmp.contains("hdrgm:") { - return None; - } - let base_rendition_hdr = xmp_values(xmp, "BaseRenditionIsHDR").is_some_and(|v| v.first().is_some_and(|s| s.eq_ignore_ascii_case("true"))); - if base_rendition_hdr { - return None; - } - let get = |name: &str, default: f32| -> Option<([f32; 3], bool)> { - let Some(v) = xmp_values(xmp, name) else { return Some(([default; 3], false)) }; - let f: Vec = v.iter().map(|s| s.trim().parse::().ok()).collect::>()?; - match f.as_slice() { - [a] => Some(([*a; 3], false)), - [a, b, c] => Some(([*a, *b, *c], true)), - _ => None, - } - }; - let (max, m1) = get("GainMapMax", f32::NAN)?; - if max.iter().any(|v| v.is_nan()) { - return None; // the one required parameter - } - let (min, m2) = get("GainMapMin", 0.0)?; - let (gamma, m3) = get("Gamma", 1.0)?; - let (base_offset, m4) = get("OffsetSDR", 1.0 / 64.0)?; - let (alternate_offset, m5) = get("OffsetHDR", 1.0 / 64.0)?; - let (cap_min, _) = get("HDRCapacityMin", 0.0)?; - let max_gain = max.iter().copied().fold(f32::MIN, f32::max); - let (cap_max, _) = get("HDRCapacityMax", max_gain)?; - let m = GainMapMeta { - multichannel: m1 || m2 || m3 || m4 || m5, - use_base_colour_space: true, - base_headroom: cap_min[0].max(0.0), - alternate_headroom: cap_max[0], - min, - max, - gamma, - base_offset, - alternate_offset, - }; - m.is_valid().then_some(m) - } - - /// The gain map image's XMP: the Adobe `hdrgm` parameters (read by Android and Chrome, which - /// ignore the ISO payload) and Apple's description of the same map (what iMessage keeps). - pub fn to_gain_map_xmp(&self) -> String { - let names = ["GainMapMin", "GainMapMax", "Gamma", "OffsetSDR", "OffsetHDR"]; - let values = [&self.min, &self.max, &self.gamma, &self.base_offset, &self.alternate_offset]; - let uniform = |v: &[f32; 3]| !self.multichannel || (v[0] == v[1] && v[1] == v[2]); - let mut s = String::from(XMP_OPEN); - s.push_str(r#"'); - // per-channel values are an rdf:Seq of three, not a comma list: readers parse each item - for (n, v) in names.iter().zip(values) { - if !uniform(v) { - s.push_str(&format!("")); - for x in v { - s.push_str(&format!("{}", num(*x))); - } - s.push_str(&format!("")); - } - } - s.push_str(""); - s.push_str(&self.apple_description()); - s.push_str(XMP_CLOSE); - s - } - - /// Apple's own description of the map (`apdi`, `HDRGainMap`, `HDRToneMap` namespaces). - fn apple_description(&self) -> String { - // 'L008' (8-bit luminance) or '444f'; the stored map must really have that many channels - let format = if self.multichannel { 0x3434_3466u32 } else { 0x4C30_3038 }; - let mut s = String::from( - r#""#, - ); - s.push_str("urn:com:apple:photo:2020:aux:hdrgainmap"); - s.push_str(&format!("{format}{format}")); - s.push_str("131072"); - // linear, not log2: the headroom multiplier itself - s.push_str(&format!("{}", num(self.alternate_headroom.exp2()))); - s.push_str(&format!("{}", num(self.alternate_headroom))); - s.push_str(""); - for c in 0..self.channels() { - s.push_str(&format!( - r#"{}{}{}{}{}"#, - num(self.min[c]), - num(self.max[c]), - num(self.gamma[c]), - num(self.base_offset[c]), - num(self.alternate_offset[c]) - )); - } - s.push_str(""); - s.push_str(&format!("{}", num(self.base_headroom))); - s.push_str("True1"); - s.push_str(""); - s - } -} - -const FLAG_MULTICHANNEL: u8 = 0x80; -const FLAG_BASE_COLOUR_SPACE: u8 = 0x40; -const FLAG_COMMON_DENOMINATOR: u8 = 0x08; -const FLAG_BACKWARD: u8 = 0x04; - -const XMP_OPEN: &str = ""; -const XMP_CLOSE: &str = ""; - -/// A short decimal (up to 6 significant digits, no exponent for ordinary values). -fn num(v: f32) -> String { - if !v.is_finite() { - return "0".into(); - } - let s = format!("{:.6}", v); - let s = s.trim_end_matches('0').trim_end_matches('.'); - if s == "-0" || s.is_empty() { "0".into() } else { s.to_string() } -} - -/// The values of `hdrgm:`: an attribute (`name="v"`) or an element holding an `rdf:Seq`. -fn xmp_values(xmp: &str, name: &str) -> Option> { - let attr = format!("hdrgm:{name}="); - if let Some(i) = xmp.find(&attr) { - let rest = xmp.get(i + attr.len()..)?; - let q = rest.chars().next()?; - if q == '"' || q == '\'' { - let body = rest.get(1..)?; - let end = body.find(q)?; - return Some(vec![body.get(..end)?.to_string()]); - } - } - let open = format!(""); - let close = format!(""); - let i = xmp.find(&open)?; - let body = xmp.get(i + open.len()..)?; - let body = body.get(..body.find(&close)?)?; - let mut out = Vec::new(); - let mut rest = body; - while let Some(a) = rest.find("") { - let after = rest.get(a + 8..)?; - let b = after.find("")?; - out.push(after.get(..b)?.to_string()); - rest = after.get(b..)?; - if out.len() > 3 { - return None; - } - } - if out.is_empty() { - // a plain element value - out.push(body.trim().to_string()); - } - Some(out) -} - -struct Reader<'a> { - b: &'a [u8], - at: usize, -} - -impl Reader<'_> { - fn take(&mut self) -> Option<[u8; N]> { - let s = self.b.get(self.at..self.at.checked_add(N)?)?; - self.at += N; - s.try_into().ok() - } - fn u8(&mut self) -> Option { - self.take::<1>().map(|a| a[0]) - } - fn u16(&mut self) -> Option { - self.take().map(u16::from_be_bytes) - } - fn u32(&mut self) -> Option { - self.take().map(u32::from_be_bytes) - } -} - -/// A gain map image: `channels` (1 or 3) interleaved 8-bit codes. -#[derive(Clone, Debug, PartialEq)] -pub struct GainImage { - pub width: usize, - pub height: usize, - pub channels: usize, - pub data: Vec, -} - -impl GainImage { - /// Bilinear code of channel `c` at gain map coordinates (`x`, `y`) (pixel centres at +0.5). - fn sample(&self, x: f32, y: f32, c: usize) -> f32 { - let (w, h) = (self.width, self.height); - let fx = (x - 0.5).clamp(0.0, (w - 1) as f32); - let fy = (y - 0.5).clamp(0.0, (h - 1) as f32); - let (x0, y0) = (fx as usize, fy as usize); - let (x1, y1) = ((x0 + 1).min(w - 1), (y0 + 1).min(h - 1)); - let (tx, ty) = (fx - x0 as f32, fy - y0 as f32); - let at = |x: usize, y: usize| self.data.get((y * w + x) * self.channels + c).copied().unwrap_or(0) as f32; - let a = at(x0, y0) + (at(x1, y0) - at(x0, y0)) * tx; - let b = at(x0, y1) + (at(x1, y1) - at(x0, y1)) * tx; - a + (b - a) * ty - } -} - -/// How [`compute`] builds the map. -#[derive(Clone, Copy, Debug, PartialEq)] -pub struct GainMapOptions { - /// Downscale factor of the map (1, 2 or 4). - pub scale: usize, - /// Three gains (R, G, B) instead of one luminance gain. Apple's readers want a single - /// channel, so this is off by default. - pub multichannel: bool, - pub gamma: f32, - /// Offsets added to SDR and HDR before the ratio (keep blacks finite and noise quiet). - pub offset: f32, -} - -impl Default for GainMapOptions { - fn default() -> Self { - GainMapOptions { scale: 2, multichannel: false, gamma: 1.0, offset: 1.0 / 64.0 } - } -} - -/// Measure the gain map that turns `sdr` into `hdr` (both `width × height` linear RGB in the same -/// primaries; `luma` = that space's luminance weights). -pub fn compute( - sdr: &[[f32; 3]], - hdr: &[[f32; 3]], - width: usize, - height: usize, - luma: [f32; 3], - o: &GainMapOptions, -) -> Result<(GainImage, GainMapMeta)> { - let n = width.checked_mul(height).ok_or_else(|| Error::Encode("gain map: image too large".into()))?; - if n == 0 || sdr.len() < n || hdr.len() < n { - return Err(Error::Encode("gain map: SDR and HDR renditions must match the image size".into())); - } - if !(matches!(o.scale, 1 | 2 | 4) && o.gamma > 0.0 && o.gamma.is_finite() && o.offset > 0.0 && o.offset.is_finite()) { - return Err(Error::Encode("gain map: scale must be 1, 2 or 4, gamma and offset positive".into())); - } - let s = o.scale; - let (gw, gh) = (width.div_ceil(s), height.div_ceil(s)); - let ch = if o.multichannel { 3 } else { 1 }; - let y = |p: &[f32; 3]| luma[0] * p[0] + luma[1] * p[1] + luma[2] * p[2]; - let ratio = |a: f32, b: f32| ((b.max(0.0) + o.offset) / (a.max(0.0) + o.offset)).log2(); - // block means of the log gains - let mut gains = vec![0f32; gw * gh * ch]; - let mut lo = [f32::MAX; 3]; - let mut hi = [f32::MIN; 3]; - for gy in 0..gh { - for gx in 0..gw { - let mut acc = [0f32; 3]; - let mut count = 0f32; - for yy in gy * s..((gy + 1) * s).min(height) { - for xx in gx * s..((gx + 1) * s).min(width) { - let i = yy * width + xx; - let (Some(a), Some(b)) = (sdr.get(i), hdr.get(i)) else { continue }; - if o.multichannel { - for c in 0..3 { - acc[c] += ratio(a[c], b[c]); - } - } else { - acc[0] += ratio(y(a), y(b)); - } - count += 1.0; - } - } - for c in 0..ch { - let g = if count > 0.0 { acc[c] / count } else { 0.0 }; - let g = if g.is_finite() { g } else { 0.0 }; - gains[(gy * gw + gx) * ch + c] = g; - lo[c] = lo[c].min(g); - hi[c] = hi[c].max(g); - } - } - } - let mut m = GainMapMeta { - multichannel: o.multichannel, - gamma: [o.gamma; 3], - base_offset: [o.offset; 3], - alternate_offset: [o.offset; 3], - ..GainMapMeta::default() - }; - for c in 0..ch { - // the range always includes 0 (no change) so an SDR-only area encodes exactly - m.min[c] = lo[c].min(0.0); - m.max[c] = hi[c].max(m.min[c] + 1e-4); - } - if !o.multichannel { - m.fill_from_first(); - } - m.base_headroom = 0.0; - m.alternate_headroom = m.max.iter().copied().fold(0.0f32, f32::max).max(1e-3); - let data = gains - .iter() - .enumerate() - .map(|(i, g)| { - let c = i % ch; - let norm = ((g - m.min[c]) / (m.max[c] - m.min[c])).clamp(0.0, 1.0); - (norm.powf(o.gamma) * 255.0).round() as u8 - }) - .collect(); - Ok((GainImage { width: gw, height: gh, channels: ch, data }, m)) -} - -/// Rebuild the HDR rendition in place: `base` (`width × height` linear RGB) is replaced by the -/// rendition at `weight` (0 = the base, 1 = the full alternate rendition; a display with headroom -/// `H` uses `(H − base_headroom) / (alternate_headroom − base_headroom)`, clamped). -pub fn apply(base: &mut [[f32; 3]], width: usize, height: usize, gain: &GainImage, m: &GainMapMeta, weight: f32) -> Result<()> { - let n = width.checked_mul(height).ok_or_else(|| Error::Encode("gain map: image too large".into()))?; - if base.len() < n - || gain.width == 0 - || gain.height == 0 - || !matches!(gain.channels, 1 | 3) - || gain.data.len() < gain.width * gain.height * gain.channels - { - return Err(Error::Encode("gain map: base and gain map sizes don't match".into())); - } - if !m.is_valid() { - return Err(Error::Encode("gain map: unusable metadata".into())); - } - let weight = if weight.is_finite() { weight.clamp(0.0, 1.0) } else { 1.0 }; - let (sx, sy) = (gain.width as f32 / width as f32, gain.height as f32 / height as f32); - let inv_gamma = m.gamma.map(|g| 1.0 / g); - for (i, p) in base.iter_mut().enumerate().take(n) { - let (x, y) = ((i % width) as f32 + 0.5, (i / width) as f32 + 0.5); - let (gx, gy) = (x * sx, y * sy); - let mut g = [0f32; 3]; - for (c, gc) in g.iter_mut().enumerate() { - let src = if gain.channels == 3 { c } else { 0 }; - let norm = (gain.sample(gx, gy, src) / 255.0).clamp(0.0, 1.0).powf(inv_gamma[c]); - *gc = m.min[c] + (m.max[c] - m.min[c]) * norm; - } - for c in 0..3 { - let v = (p[c] + m.base_offset[c]) * (g[c] * weight).exp2() - m.alternate_offset[c]; - p[c] = v.max(0.0); - } - } - Ok(()) -} - -/// The primary image's container XMP: `hdrgm:Version` (marks the file as a gain map image for -/// Adobe/Google readers) and the Container directory naming the gain map and its length. -fn primary_description(gain_len: usize) -> String { - format!( - concat!( - r#""#, - r#""#, - r#""#, - r#""#, - r#""# - ), - gain_len - ) -} - -/// `xmp` with `description` added as another `rdf:Description` (a fresh packet when there is -/// none, or when it has no `rdf:RDF` to add to). -fn merge_xmp(xmp: Option<&str>, description: &str) -> String { - if let Some(x) = xmp - && let Some(i) = x.rfind("") - && let (Some(a), Some(b)) = (x.get(..i), x.get(i..)) - { - return format!("{a}{description}{b}"); - } - format!("{XMP_OPEN}{description}{XMP_CLOSE}") -} - /// Offsets within the MPF payload (from "MPF\0"): the endian field, then the index IFD (3 tags). const MPF_ENTRIES_FROM_ENDIAN: usize = 8 + 2 + 3 * 12 + 4; @@ -598,11 +72,9 @@ pub fn encode_jpeg(base: &EncodeImage, gain: &GainImage, m: &GainMapMeta, qualit let gain_segs = vec![(0xE1, xmp_segment(&m.to_gain_map_xmp())?), (0xE2, m.to_iso())]; let gain_jpeg = jpeg_par::encode(&gain.data, gain.width, gain.height, gain.channels, quality, ChromaSubsampling::S444, &gain_segs); - let xmp = merge_xmp(meta.xmp, &primary_description(gain_jpeg.len())); + let xmp = craft_gainmap::primary_xmp(meta.xmp, gain_jpeg.len()); let mut segs = jpeg_app_segments(&EncodeMeta { xmp: Some(&xmp), ..*meta })?; - let mut iso_marker = ISO_URN.to_vec(); - iso_marker.extend_from_slice(&[0, 0, 0, 0]); // versions only: "this image has a gain map" - segs.push((0xE2, iso_marker)); + segs.push((0xE2, craft_gainmap::primary_iso_marker())); segs.push((0xE2, mpf_placeholder())); let mut primary = jpeg_par::encode(data, w, h, base.channels as usize, quality, sub, &segs); @@ -672,77 +144,6 @@ pub fn is_gain_map_jpeg(bytes: &[u8]) -> bool { mod tests { use super::*; - fn meta3() -> GainMapMeta { - GainMapMeta { - multichannel: true, - use_base_colour_space: true, - base_headroom: 0.0, - alternate_headroom: 2.5, - min: [-0.25, -0.5, 0.0], - max: [2.5, 2.25, 2.0], - gamma: [1.0, 1.25, 0.75], - base_offset: [0.015625; 3], - alternate_offset: [0.015625, 0.03125, 0.015625], - } - } - - #[test] - fn iso_metadata_round_trips() { - for m in [GainMapMeta { alternate_headroom: 3.0, max: [3.0; 3], ..GainMapMeta::default() }, meta3()] { - let p = m.to_iso(); - assert!(p.starts_with(ISO_URN)); - let back = GainMapMeta::from_iso(&p[ISO_URN.len()..]).unwrap(); - for (a, b) in [(back.min, m.min), (back.max, m.max), (back.gamma, m.gamma), (back.alternate_offset, m.alternate_offset)] { - for c in 0..3 { - assert!((a[c] - b[c]).abs() < 1e-6, "{a:?} {b:?}"); - } - } - assert_eq!(back.multichannel, m.multichannel); - assert!((back.alternate_headroom - m.alternate_headroom).abs() < 1e-6); - } - } - - #[test] - fn iso_common_denominator_and_rejections() { - // common-denominator form, single channel: d = 4, headrooms 0 and 2, min 0, max 2, gamma 1, offsets 0 - let mut p = vec![0, 0, 0, 0, FLAG_COMMON_DENOMINATOR]; - for v in [4u32, 0, 8, 0, 8, 4, 0, 0] { - p.extend_from_slice(&v.to_be_bytes()); - } - let m = GainMapMeta::from_iso(&p).unwrap(); - assert_eq!((m.alternate_headroom, m.max[2], m.gamma[1]), (2.0, 2.0, 1.0)); - // versions only (a primary image's marker), unknown version, truncated, backward - assert!(GainMapMeta::from_iso(&[0, 0, 0, 0]).is_none()); - assert!(GainMapMeta::from_iso(&[0, 1, 0, 0, 0]).is_none()); - assert!(GainMapMeta::from_iso(&p[..p.len() - 1]).is_none()); - let mut back = p.clone(); - back[4] |= FLAG_BACKWARD; - assert!(GainMapMeta::from_iso(&back).is_none()); - // a zero denominator is rejected, not divided by - let mut z = p.clone(); - z[5..9].copy_from_slice(&0u32.to_be_bytes()); - assert!(GainMapMeta::from_iso(&z).is_none()); - } - - #[test] - fn hdrgm_xmp_round_trips_including_per_channel_sequences() { - for m in [GainMapMeta { alternate_headroom: 2.0, max: [2.0; 3], ..GainMapMeta::default() }, meta3()] { - let x = m.to_gain_map_xmp(); - assert!(x.contains("apdi:AuxiliaryImageType")); - if m.multichannel { - assert!(x.contains("2.5"), "{x}"); - } - let back = GainMapMeta::from_hdrgm_xmp(&x).unwrap(); - assert_eq!(back.multichannel, m.multichannel); - for c in 0..3 { - assert!((back.max[c] - m.max[c]).abs() < 1e-5 && (back.gamma[c] - m.gamma[c]).abs() < 1e-5); - } - assert!((back.alternate_headroom - m.alternate_headroom).abs() < 1e-5); - } - assert!(GainMapMeta::from_hdrgm_xmp("").is_none(), "no GainMapMax"); - assert!(GainMapMeta::from_hdrgm_xmp("hdrgm:GainMapMax=\"nope\"").is_none()); - } - fn renditions(w: usize, h: usize) -> (Vec<[f32; 3]>, Vec<[f32; 3]>) { // a ramp: SDR rolls off at 1, HDR keeps going to 6 let hdr: Vec<[f32; 3]> = (0..w * h) @@ -765,31 +166,6 @@ mod tests { (sdr, hdr) } - #[test] - fn compute_then_apply_recovers_the_hdr_rendition() { - let (w, h) = (64, 8); - let (sdr, hdr) = renditions(w, h); - for multichannel in [false, true] { - let o = GainMapOptions { scale: 1, multichannel, ..GainMapOptions::default() }; - let (g, m) = compute(&sdr, &hdr, w, h, [0.2126, 0.7152, 0.0722], &o).unwrap(); - assert!(m.is_valid() && m.alternate_headroom > 1.0); - let mut out = sdr.clone(); - apply(&mut out, w, h, &g, &m, 1.0).unwrap(); - for (a, b) in out.iter().zip(&hdr) { - for c in 0..3 { - // 8-bit codes over the gain range: within ~2 % in linear light - assert!((a[c] - b[c]).abs() <= 0.03 * b[c] + 0.01, "{multichannel}: {a:?} vs {b:?}"); - } - } - // weight 0 is the base - let mut base = sdr.clone(); - apply(&mut base, w, h, &g, &m, 0.0).unwrap(); - for (a, b) in base.iter().zip(&sdr) { - assert!((a[0] - b[0]).abs() < 1e-5); - } - } - } - #[test] fn a_gain_map_wider_than_a_jpeg_allows_is_refused() { let base = [0u8; 3]; diff --git a/docs/file-format-parity.md b/docs/file-format-parity.md index f72a9b235a..7f82adf2e9 100644 --- a/docs/file-format-parity.md +++ b/docs/file-format-parity.md @@ -27,7 +27,7 @@ import and export formats. Ours come from `crates/codecs/src/sniff.rs`, `crates/ | DNG (from raw) | ✅ | ✅ incl. lossy, embedded original | ✅ | ✅ uncompressed, LJ92, Deflate or lossy (JPEG tiles, optional long edge); ⬜ embedded original | `crates/raw/src/dngwrite.rs` | | Render to DNG (15.5) | — | ✅ | — | 🟡 export format "Rendered DNG" (linear float DNG, edit baked in); not yet added to the catalog | `crates/raw/src/dngwrite.rs` (`write_rendered_dng`) | | Original + sidecar | — | ✅ | — | ✅ | | -| HDR gain map JPEG (ISO 21496-1) | ✅ | ✅ | ✅ (gain map read) | ✅ | `crates/codecs/src/gainmap.rs` | +| HDR gain map JPEG (ISO 21496-1) | ✅ | ✅ | ✅ (gain map read) | ✅ | `crates/codecs/src/gainmap.rs` (JPEG layout), `craft-gainmap` (metadata, compute, apply) | | PQ / HLG HDR | ✅ | ✅ AVIF, JXL, TIFF | — | 🟡 PQ AVIF, PQ JPEG XL, float TIFF; no HLG | | | Contact sheet / print PDF | — | ✅ (Print module: PDF / JPEG / printer) | — | 🟡 paginated contact-sheet PDF (A4 / Letter, 150 dpi, sRGB) | `crates/engine/src/contact_sheet.rs` | | Video (MP4, MOV, AVCHD…) | ✅ playback, trim, edit | ✅ export | 🟡 catalogued (kind, duration) | ⬜ | see video gap | From 69cd98a5c2749e6f56ebf73d6a71cd8c2afdbbc1 Mon Sep 17 00:00:00 2001 From: "Dylan M. Taylor" Date: Thu, 12 Nov 2026 01:05:29 +0000 Subject: [PATCH 04/61] Read the PSD header and image resources with craft-psd lightcraft-meta's EXIF/XMP scan and lightcraft-codecs' PSD probe and decoder take the header, colour mode data and image resources from craft_psd::Head (storytold/craft-libs#885). The merged-image decoder and the flat writer stay. --- Cargo.lock | 32 +++++++++ Cargo.toml | 2 + crates/codecs/Cargo.toml | 1 + crates/codecs/src/psd.rs | 145 ++++++++++++++++++--------------------- crates/meta/Cargo.toml | 1 + crates/meta/src/psd.rs | 63 ++--------------- 6 files changed, 108 insertions(+), 136 deletions(-) diff --git a/Cargo.lock b/Cargo.lock index 064783fb91..2660670522 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -1239,6 +1239,16 @@ dependencies = [ "writeable", ] +[[package]] +name = "craft-psd" +version = "0.1.0" +source = "git+https://github.com/storytold/craft-libs?rev=430a908f68819bf23d14fe73ab9b18d8f4fd4e5d#430a908f68819bf23d14fe73ab9b18d8f4fd4e5d" +dependencies = [ + "encoding_rs", + "flate2", + "thiserror 2.0.21", +] + [[package]] name = "craft-tiff" version = "0.1.0" @@ -1796,6 +1806,20 @@ dependencies = [ "bytemuck", ] +[[package]] +name = "encoding_rs" +version = "0.8.44" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "89253175e704ab869b04f9db224d38630e0211a53841a79181deae0889e169f5" +dependencies = [ + "cfg-if", + "core_detect", + "multiversion_no_op", + "rustversion", + "scopeguard", + "simdutf8", +] + [[package]] name = "endi" version = "1.1.1" @@ -3687,6 +3711,7 @@ dependencies = [ "bytemuck", "craft-gainmap", "craft-heif", + "craft-psd", "dhat", "image", "image-webp", @@ -3930,6 +3955,7 @@ version = "0.21.0" dependencies = [ "chrono", "craft-heif", + "craft-psd", "craft-tiff", "lightcraft-geom", "proptest", @@ -4309,6 +4335,12 @@ dependencies = [ "windows-sys 0.61.2", ] +[[package]] +name = "multiversion_no_op" +version = "1.0.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "743fb55ba31b18fb1ecef6bdc9aa2743314978ac084044301a7eee33fb99a20d" + [[package]] name = "naga" version = "30.0.1" diff --git a/Cargo.toml b/Cargo.toml index 427c091de8..26d0f84822 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -19,6 +19,8 @@ craft-update = { git = "https://github.com/storytold/craft-libs", version = "=0. craft-window = { git = "https://github.com/storytold/craft-libs", rev = "c5a1cbfb5f9049f9270955caffb5bee5997aebf7", features = ["egui"] } # HDR gain maps: ISO 21496-1 and hdrgm metadata, compute and apply (moved from crates/codecs; craft-libs#904). craft-gainmap = { git = "https://github.com/storytold/craft-libs", rev = "430a908f68819bf23d14fe73ab9b18d8f4fd4e5d" } +# PSD/PSB: the header, colour mode data and image resources (craft-libs#885). +craft-psd = { git = "https://github.com/storytold/craft-libs", rev = "430a908f68819bf23d14fe73ab9b18d8f4fd4e5d" } # internal lightcraft-denoise-core = { path = "crates/denoise-core" } lightcraft-denoise = { path = "crates/denoise", default-features = false } diff --git a/crates/codecs/Cargo.toml b/crates/codecs/Cargo.toml index 019009d7c1..15b7fb0557 100644 --- a/crates/codecs/Cargo.toml +++ b/crates/codecs/Cargo.toml @@ -13,6 +13,7 @@ lightcraft-geom = { workspace = true } lightcraft-color = { workspace = true } lightcraft-raster = { workspace = true } craft-gainmap = { workspace = true } +craft-psd = { workspace = true } craft-heif = { workspace = true, optional = true } serde = { workspace = true } bytemuck = { workspace = true } diff --git a/crates/codecs/src/psd.rs b/crates/codecs/src/psd.rs index 7cccec0f8f..f0422edc13 100644 --- a/crates/codecs/src/psd.rs +++ b/crates/codecs/src/psd.rs @@ -40,36 +40,46 @@ impl<'a> Rd<'a> { } } +/// The header, colour mode data and image resources (`craft-psd`), with a reader at the layer and mask section. +struct Start<'a> { + psb: bool, + channels: usize, + width: usize, + height: usize, + depth: u16, + mode: u16, + head: craft_psd::Head, + r: Rd<'a>, +} + +fn start<'a>(bytes: &'a [u8], opts: &DecodeOptions) -> Result> { + // the size limit first, from the header's fixed fields, so an oversized file is `TooLarge` as for other formats + if let (Some(&[h0, h1, h2, h3]), Some(&[w0, w1, w2, w3])) = (bytes.get(14..18), bytes.get(18..22)) { + check_size(F, u64::from(u32::from_be_bytes([w0, w1, w2, w3])), u64::from(u32::from_be_bytes([h0, h1, h2, h3])), opts)?; + } + let head = craft_psd::Head::from_bytes(bytes).map_err(|e| match e { + craft_psd::PsdError::UnexpectedEof { .. } => err("truncated"), + e => err(&e.to_string()), + })?; + let h = &head.header; + check_size(F, u64::from(h.width), u64::from(h.height), opts)?; + let p = usize::try_from(head.layer_section_offset).map_err(|_| err("truncated"))?; + Ok(Start { + psb: h.version.is_psb(), + channels: usize::from(h.channels), + width: h.width as usize, + height: h.height as usize, + depth: h.depth, + mode: h.color_mode.as_u16(), + r: Rd { b: bytes, p }, + head, + }) +} + pub(crate) fn decode(bytes: &[u8], opts: &DecodeOptions) -> Result { - let mut r = Rd { b: bytes, p: 0 }; - if r.take(4)? != b"8BPS" { - return Err(err("bad signature")); - } - let version = r.u16()?; - let psb = match version { - 1 => false, - 2 => true, - _ => return Err(err("bad version")), - }; - r.take(6)?; - let channels = r.u16()? as usize; - let height = r.u32()? as usize; - let width = r.u32()? as usize; - let depth = r.u16()?; - let mode = r.u16()?; - check_size(F, width as u64, height as u64, opts)?; - if channels == 0 || channels > 56 { - return Err(err("bad channel count")); - } - - // Colour mode data (palette for indexed). - let cm_len = r.u32()? as usize; - let color_mode_data = r.take(cm_len)?; - - // Image resources. - let res_len = r.u32()? as usize; - let res = r.take(res_len)?; - let (icc, exif, xmp) = resources(res); + let Start { psb, channels, width, height, depth, mode, head, mut r } = start(bytes, opts)?; + let color_mode_data = head.color_mode_data.as_slice(); + let (icc, exif, xmp) = resources(&head); // Layer and mask information: only the layer count sign matters (merged transparency). let lm_len = if psb { r.u64()? } else { u64::from(r.u32()?) }; @@ -342,29 +352,9 @@ fn packbits(src: &[u8], out: &mut Vec) { /// depth, colour mode or compression, or merged image data that runs past the end of the file /// (truncated). The run-length data itself is not unpacked. pub(crate) fn header(bytes: &[u8]) -> Result<(u32, u32, u16)> { - let mut r = Rd { b: bytes, p: 0 }; - if r.take(4)? != b"8BPS" { - return Err(err("bad signature")); - } - let psb = match r.u16()? { - 1 => false, - 2 => true, - _ => return Err(err("bad version")), - }; - r.take(6)?; - let channels = r.u16()? as usize; - let height = r.u32()? as usize; - let width = r.u32()? as usize; - let depth = r.u16()?; - let mode = r.u16()?; - check_size(F, width as u64, height as u64, &DecodeOptions::default())?; - if channels == 0 || channels > 56 { - return Err(err("bad channel count")); - } - let cm_len = r.u32()? as usize; - let color_mode_data = r.take(cm_len)?; - let res_len = r.u32()? as usize; - let (_, exif, _) = resources(r.take(res_len)?); + let Start { psb, channels, width, height, depth, mode, head, mut r } = start(bytes, &DecodeOptions::default())?; + let color_mode_data = head.color_mode_data.as_slice(); + let (_, exif, _) = resources(&head); let lm_len = if psb { r.u64()? as usize } else { r.u32()? as usize }; r.take(lm_len)?; let compression = r.u16()?; @@ -444,28 +434,12 @@ fn unpackbits(mut src: &[u8], row: &mut [u8]) -> Result<()> { Ok(()) } -fn resources(mut b: &[u8]) -> (Option>, Option>, Option) { - let (mut icc, mut exif, mut xmp) = (None, None, None); - while b.len() >= 12 && &b[0..4] == b"8BIM" { - let id = u16::from_be_bytes([b[4], b[5]]); - let name_len = b[6] as usize; - let name_total = (1 + name_len + 1) & !1; - let p = 6 + name_total; - if p + 4 > b.len() { - break; - } - let size = u32::from_be_bytes([b[p], b[p + 1], b[p + 2], b[p + 3]]) as usize; - let start = p + 4; - let Some(data) = start.checked_add(size).and_then(|end| b.get(start..end)) else { break }; - match id { - 1039 => icc = Some(data.to_vec()), - 1058 => exif = Some(if data.starts_with(b"Exif\0\0") { data[6..].to_vec() } else { data.to_vec() }), - 1060 => xmp = Some(String::from_utf8_lossy(data).trim_end_matches('\0').to_string()), - _ => {} - } - let next = start + ((size + 1) & !1); - b = b.get(next..).unwrap_or(&[]); - } +/// ICC (1039), EXIF (1058, without its optional `Exif\0\0` prefix) and XMP (1060) resources; the last of each id. +fn resources(head: &craft_psd::Head) -> (Option>, Option>, Option) { + let last = |id: u16| head.resources.iter().rev().find(|r| r.id == id).map(|r| r.data.as_slice()); + let icc = last(1039).map(<[u8]>::to_vec); + let exif = last(1058).map(|d| d.strip_prefix(b"Exif\0\0").unwrap_or(d).to_vec()); + let xmp = last(1060).map(|d| String::from_utf8_lossy(d).trim_end_matches('\0').to_string()); (icc, exif, xmp) } @@ -514,8 +488,8 @@ mod tests { #[test] fn huge_rle_with_truncated_count_table_is_rejected_before_allocating() { - // 1 × 2^30 px, 56 channels: the row table alone would be 56 Gi entries; the file has 4 bytes. - let mut b = header(56, 1, 1 << 30, 32, 3, 1); + // 1 × 300 000 px, 56 channels: the row table alone would be 16.8 M entries; the file has 4 bytes. + let mut b = header(56, 1, 300_000, 32, 3, 1); b.extend_from_slice(&[0, 0, 0, 0]); let e = decode(&b, &DecodeOptions::default()).unwrap_err(); assert!(matches!(e, Error::Malformed(_, ref m) if m == "truncated"), "{e:?}"); @@ -523,18 +497,29 @@ mod tests { #[test] fn huge_rle_of_empty_rows_is_rejected_before_allocating() { - // 2^30 × 1 px RGB at 32 bits: every row count is 0, which used to zero-pad 3 × 4 GiB. - let mut b = header(3, 1 << 30, 1, 32, 3, 1); + // 300 000 × 1 px RGB at 32 bits: every row count is 0, which used to zero-pad 3 × 1.2 MB. + let mut b = header(3, 300_000, 1, 32, 3, 1); b.extend_from_slice(&[0; 6]); let e = decode(&b, &DecodeOptions::default()).unwrap_err(); assert!(matches!(e, Error::Malformed(_, ref m) if m.contains("too short")), "{e:?}"); - // 1 Gpx RGB 8-bit whose (plausible) row counts claim more data than the file holds. - let mut b = header(3, 1 << 20, 1 << 10, 8, 3, 1); + // 0.27 Gpx RGB 8-bit whose (plausible) row counts claim more data than the file holds. + let mut b = header(3, 1 << 18, 1 << 10, 8, 3, 1); b.extend_from_slice(&[0xFF; 3 * 1024 * 2]); let e = decode(&b, &DecodeOptions::default()).unwrap_err(); assert!(matches!(e, Error::Malformed(_, ref m) if m == "truncated"), "{e:?}"); } + #[test] + fn a_damaged_resource_section_is_malformed() { + // a resource section of 4 bytes that is not an `8BIM` record + let mut b = header(3, 1, 1, 8, 3, 0); + b[30..34].copy_from_slice(&4u32.to_be_bytes()); + b.splice(34..34, *b"JUNK"); + let e = decode(&b, &DecodeOptions::default()).unwrap_err(); + assert!(matches!(e, Error::Malformed(_, ref m) if m.contains("signature")), "{e:?}"); + assert!(super::header(&b).is_err()); + } + #[test] fn rle_repeat_run_past_row_width_is_an_error() { // 4 × 1 gray 8-bit; the single row is a 128-byte repeat run. diff --git a/crates/meta/Cargo.toml b/crates/meta/Cargo.toml index 1b146c99da..e813d3a2a8 100644 --- a/crates/meta/Cargo.toml +++ b/crates/meta/Cargo.toml @@ -10,6 +10,7 @@ workspace = true [dependencies] craft-tiff = { workspace = true } +craft-psd = { workspace = true } lightcraft-geom = { workspace = true } serde = { workspace = true } quick-xml = { workspace = true } diff --git a/crates/meta/src/psd.rs b/crates/meta/src/psd.rs index ebdbdaf723..8fbe448d55 100644 --- a/crates/meta/src/psd.rs +++ b/crates/meta/src/psd.rs @@ -2,73 +2,24 @@ use crate::container::Embedded; -struct Reader<'a> { - bytes: &'a [u8], - offset: usize, -} - -impl<'a> Reader<'a> { - fn take(&mut self, length: usize) -> Option<&'a [u8]> { - let end = self.offset.checked_add(length)?; - let bytes = self.bytes.get(self.offset..end)?; - self.offset = end; - Some(bytes) - } - - fn u16(&mut self) -> Option { - let bytes = self.take(2)?; - Some(u16::from_be_bytes([*bytes.first()?, *bytes.get(1)?])) - } - - fn u32(&mut self) -> Option { - let bytes = self.take(4)?; - Some(u32::from_be_bytes([*bytes.first()?, *bytes.get(1)?, *bytes.get(2)?, *bytes.get(3)?])) - } -} - pub(crate) fn embedded(bytes: &[u8]) -> Embedded { parse(bytes).unwrap_or_default() } +/// The EXIF (1058) and XMP (1060) resources of the head `craft-psd` reads (header, colour mode data, image +/// resources). `None` for a head that does not parse, a second EXIF or XMP resource, or XMP that is not UTF-8. pub(crate) fn parse(bytes: &[u8]) -> Option { - let mut reader = Reader { bytes, offset: 0 }; - if reader.take(4)? != b"8BPS" || !matches!(reader.u16()?, 1 | 2) { - return None; - } - // The fixed header after the version is reserved bytes, channels, dimensions, depth and colour mode. - reader.take(6 + 2 + 4 + 4 + 2 + 2)?; - let colour_mode_length = usize::try_from(reader.u32()?).ok()?; - reader.take(colour_mode_length)?; - let resource_length = usize::try_from(reader.u32()?).ok()?; - let resources = reader.take(resource_length)?; - parse_resources(resources) -} - -fn parse_resources(bytes: &[u8]) -> Option { - let mut reader = Reader { bytes, offset: 0 }; + let head = craft_psd::Head::from_bytes(bytes).ok()?; let (mut exif, mut xmp) = (None, None); - while reader.offset < bytes.len() { - if reader.take(4)? != b"8BIM" { - return None; - } - let id = reader.u16()?; - let name_length = usize::from(*reader.take(1)?.first()?); - let pascal_length = 1usize.checked_add(name_length)?.checked_add(1)? & !1; - reader.take(pascal_length.checked_sub(1)?)?; - let data_length = usize::try_from(reader.u32()?).ok()?; - let data = reader.take(data_length)?; - if !data_length.is_multiple_of(2) { - reader.take(1)?; - } - match id { + for r in &head.resources { + match r.id { 1058 if exif.is_some() => return None, - 1058 => exif = Some(data), + 1058 => exif = Some(r.data.as_slice()), 1060 if xmp.is_some() => return None, - 1060 => xmp = Some(std::str::from_utf8(data).ok()?), + 1060 => xmp = Some(std::str::from_utf8(&r.data).ok()?), _ => {} } } - Some(Embedded { exif: exif.map(crate::strip_exif_header).map(<[u8]>::to_vec), xmp: xmp.map(|text| text.trim_end_matches('\0').to_string()), From 4ad863d19385c2830439843b186a3b351db0d7ce Mon Sep 17 00:00:00 2001 From: "Dylan M. Taylor" Date: Thu, 12 Nov 2026 01:07:05 +0000 Subject: [PATCH 05/61] craft-heif's Options has a chroma field at this rev: keep the libheif upsampling LightCraft had --- crates/codecs/src/heif.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/crates/codecs/src/heif.rs b/crates/codecs/src/heif.rs index 3e899bcdd7..2d4d5a7a1d 100644 --- a/crates/codecs/src/heif.rs +++ b/crates/codecs/src/heif.rs @@ -57,7 +57,7 @@ pub(crate) fn decode(bytes: &[u8], opts: &DecodeOptions) -> Result { if (info.width as u64).saturating_mul(info.height as u64) > opts.max_pixels { return Err(Error::TooLarge(info.width as u64, info.height as u64)); } - let options = craft_heif::Options { max_pixels: opts.max_pixels, apply_transforms: true }; + let options = craft_heif::Options { max_pixels: opts.max_pixels, apply_transforms: true, ..craft_heif::Options::default() }; // A small decode (a thumbnail or a cataloguing probe) uses the file's own thumbnail image when // it is at least as large as asked: iPhones store one of 320 × 240, and decoding it is a // hundredth of the work of the 12 MP photo. From 8dd2d60a24ae585ac14754b1fdaf76c3d12add8a Mon Sep 17 00:00:00 2001 From: "Dylan M. Taylor" Date: Thu, 12 Nov 2026 03:01:31 +0000 Subject: [PATCH 06/61] PSD: a damaged resource section is left out of the decode, as before; valid headers in the sidecar test The decode keeps the picture when the image resources don't parse (the import of such a file relies on it); the metadata reader still reports it as malformed. craft-psd validates the header, so the sidecar test's synthetic PSDs get a valid one. --- crates/codecs/src/psd.rs | 47 ++++++++++++++++++++---------------- crates/engine/src/sidecar.rs | 4 ++- 2 files changed, 29 insertions(+), 22 deletions(-) diff --git a/crates/codecs/src/psd.rs b/crates/codecs/src/psd.rs index f0422edc13..4eeaeec3d2 100644 --- a/crates/codecs/src/psd.rs +++ b/crates/codecs/src/psd.rs @@ -40,7 +40,7 @@ impl<'a> Rd<'a> { } } -/// The header, colour mode data and image resources (`craft-psd`), with a reader at the layer and mask section. +/// The header (`craft-psd`), colour mode data and image resources, with a reader at the layer and mask section. struct Start<'a> { psb: bool, channels: usize, @@ -48,7 +48,8 @@ struct Start<'a> { height: usize, depth: u16, mode: u16, - head: craft_psd::Head, + color_mode_data: &'a [u8], + resources: Vec, r: Rd<'a>, } @@ -57,13 +58,17 @@ fn start<'a>(bytes: &'a [u8], opts: &DecodeOptions) -> Result> { if let (Some(&[h0, h1, h2, h3]), Some(&[w0, w1, w2, w3])) = (bytes.get(14..18), bytes.get(18..22)) { check_size(F, u64::from(u32::from_be_bytes([w0, w1, w2, w3])), u64::from(u32::from_be_bytes([h0, h1, h2, h3])), opts)?; } - let head = craft_psd::Head::from_bytes(bytes).map_err(|e| match e { + let h = craft_psd::Header::from_bytes(bytes).map_err(|e| match e { craft_psd::PsdError::UnexpectedEof { .. } => err("truncated"), e => err(&e.to_string()), })?; - let h = &head.header; - check_size(F, u64::from(h.width), u64::from(h.height), opts)?; - let p = usize::try_from(head.layer_section_offset).map_err(|_| err("truncated"))?; + let mut r = Rd { b: bytes, p: 26 }; + let cm_len = r.u32()? as usize; + let color_mode_data = r.take(cm_len)?; + let res_len = r.u32()? as usize; + r.take(res_len)?; + // a resource section that doesn't parse is left out: the picture still decodes, without its profile and metadata + let resources = craft_psd::Head::from_bytes(bytes).map(|head| head.resources).unwrap_or_default(); Ok(Start { psb: h.version.is_psb(), channels: usize::from(h.channels), @@ -71,15 +76,15 @@ fn start<'a>(bytes: &'a [u8], opts: &DecodeOptions) -> Result> { height: h.height as usize, depth: h.depth, mode: h.color_mode.as_u16(), - r: Rd { b: bytes, p }, - head, + color_mode_data, + resources, + r, }) } pub(crate) fn decode(bytes: &[u8], opts: &DecodeOptions) -> Result { - let Start { psb, channels, width, height, depth, mode, head, mut r } = start(bytes, opts)?; - let color_mode_data = head.color_mode_data.as_slice(); - let (icc, exif, xmp) = resources(&head); + let Start { psb, channels, width, height, depth, mode, color_mode_data, resources: res, mut r } = start(bytes, opts)?; + let (icc, exif, xmp) = resources(&res); // Layer and mask information: only the layer count sign matters (merged transparency). let lm_len = if psb { r.u64()? } else { u64::from(r.u32()?) }; @@ -352,9 +357,8 @@ fn packbits(src: &[u8], out: &mut Vec) { /// depth, colour mode or compression, or merged image data that runs past the end of the file /// (truncated). The run-length data itself is not unpacked. pub(crate) fn header(bytes: &[u8]) -> Result<(u32, u32, u16)> { - let Start { psb, channels, width, height, depth, mode, head, mut r } = start(bytes, &DecodeOptions::default())?; - let color_mode_data = head.color_mode_data.as_slice(); - let (_, exif, _) = resources(&head); + let Start { psb, channels, width, height, depth, mode, color_mode_data, resources: res, mut r } = start(bytes, &DecodeOptions::default())?; + let (_, exif, _) = resources(&res); let lm_len = if psb { r.u64()? as usize } else { r.u32()? as usize }; r.take(lm_len)?; let compression = r.u16()?; @@ -435,8 +439,8 @@ fn unpackbits(mut src: &[u8], row: &mut [u8]) -> Result<()> { } /// ICC (1039), EXIF (1058, without its optional `Exif\0\0` prefix) and XMP (1060) resources; the last of each id. -fn resources(head: &craft_psd::Head) -> (Option>, Option>, Option) { - let last = |id: u16| head.resources.iter().rev().find(|r| r.id == id).map(|r| r.data.as_slice()); +fn resources(res: &[craft_psd::ImageResource]) -> (Option>, Option>, Option) { + let last = |id: u16| res.iter().rev().find(|r| r.id == id).map(|r| r.data.as_slice()); let icc = last(1039).map(<[u8]>::to_vec); let exif = last(1058).map(|d| d.strip_prefix(b"Exif\0\0").unwrap_or(d).to_vec()); let xmp = last(1060).map(|d| String::from_utf8_lossy(d).trim_end_matches('\0').to_string()); @@ -510,14 +514,15 @@ mod tests { } #[test] - fn a_damaged_resource_section_is_malformed() { - // a resource section of 4 bytes that is not an `8BIM` record + fn a_damaged_resource_section_is_left_out() { + // a resource section of 4 bytes that is not an `8BIM` record: the picture decodes without it let mut b = header(3, 1, 1, 8, 3, 0); b[30..34].copy_from_slice(&4u32.to_be_bytes()); b.splice(34..34, *b"JUNK"); - let e = decode(&b, &DecodeOptions::default()).unwrap_err(); - assert!(matches!(e, Error::Malformed(_, ref m) if m.contains("signature")), "{e:?}"); - assert!(super::header(&b).is_err()); + b.extend_from_slice(&[1, 2, 3]); + let d = decode(&b, &DecodeOptions::default()).unwrap(); + assert_eq!((d.width, d.height, d.icc.is_none()), (1, 1, true)); + assert_eq!(super::header(&b).unwrap(), (1, 1, 1)); } #[test] diff --git a/crates/engine/src/sidecar.rs b/crates/engine/src/sidecar.rs index b927aa8f31..fbf7eb6c49 100644 --- a/crates/engine/src/sidecar.rs +++ b/crates/engine/src/sidecar.rs @@ -1481,8 +1481,10 @@ mod tests { section.push(0); } } + // a valid header: one RGB pixel, 8 bits let mut p = b"8BPS\0\x01".to_vec(); - p.resize(26, 0); + p.resize(12, 0); + p.extend_from_slice(&[0, 3, 0, 0, 0, 1, 0, 0, 0, 1, 0, 8, 0, 3]); p.extend_from_slice(&(colour as u32).to_be_bytes()); p.resize(p.len() + colour, 0); p.extend_from_slice(&(section.len() as u32).to_be_bytes()); From 5d22eff36c24e9faed24c15f7f7756c05e2c72c4 Mon Sep 17 00:00:00 2001 From: "Dylan M. Taylor" Date: Sat, 14 Nov 2026 21:19:39 +0000 Subject: [PATCH 07/61] chore(codecs): cut over AVIF, AV1, and JXL tests to craft-libs --- Cargo.toml | 12 +- crates/codecs/Cargo.toml | 11 +- crates/codecs/src/encode.rs | 175 +++--------------------- crates/codecs/src/video.rs | 94 ++++--------- crates/codecs/tests/it/jxl_streaming.rs | 21 +-- crates/codecs/tests/it/roundtrip.rs | 19 ++- crates/engine/Cargo.toml | 2 +- crates/engine/src/tests/export.rs | 13 +- crates/raw/Cargo.toml | 3 +- crates/raw/tests/it/dng.rs | 33 ++--- 10 files changed, 89 insertions(+), 294 deletions(-) diff --git a/Cargo.toml b/Cargo.toml index 2346d9cd48..e45890be6d 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -16,10 +16,11 @@ craft-docpath = { version = "0.1.0", git = "https://github.com/storytold/craft-l craft-crw = { git = "https://github.com/storytold/craft-libs", rev = "f0f4758c01581d79577b9bf5046c06f4e77b1f18" } craft-cms = { git = "https://github.com/storytold/craft-libs", rev = "f0f4758c01581d79577b9bf5046c06f4e77b1f18" } craft-gif = { git = "https://github.com/storytold/craft-libs", rev = "b77af389f30bb10de10d8436ca9b39fe94e3bb67", features = ["frames"] } -craft-jxl = { git = "https://github.com/storytold/craft-libs", rev = "b77af389f30bb10de10d8436ca9b39fe94e3bb67", default-features = false, features = ["decode", "encode"] } +craft-jxl = { git = "https://github.com/storytold/craft-libs", rev = "d6cd7836d364177661b0ae17f48a0805e83a5f32", default-features = false, features = ["decode", "encode"] } # Photo metadata: EXIF, IPTC-IIM, XMP packets and GPX track logs (craft-libs#949) craft-metadata = { git = "https://github.com/storytold/craft-libs", rev = "f0f4758c01581d79577b9bf5046c06f4e77b1f18" } -craft-image-codecs = { git = "https://github.com/storytold/craft-libs", rev = "f0f4758c01581d79577b9bf5046c06f4e77b1f18" } +craft-image-codecs = { git = "https://github.com/storytold/craft-libs", rev = "d6cd7836d364177661b0ae17f48a0805e83a5f32" } +craft-video = { git = "https://github.com/storytold/craft-libs", rev = "d6cd7836d364177661b0ae17f48a0805e83a5f32" } craft-xml = { git = "https://github.com/storytold/craft-libs", rev = "f0f4758c01581d79577b9bf5046c06f4e77b1f18" } # craft-update: app-specific pretend versions apply to startup and manual checks. craft-update = { git = "https://github.com/storytold/craft-libs", version = "=0.1.0", rev = "6e03f65bf45181db77ba6229716e6624db9eb25b", features = ["egui"] } @@ -92,13 +93,6 @@ miniz_oxide = "0.9" # codecs ab_glyph = { version = "0.2", default-features = false, features = ["std"] } # Apache-2.0, pure Rust glyph rasterizer (export watermarks) moxcms = { version = "0.9", default-features = false, features = ["lut"] } -jxl-oxide = { version = "0.12", default-features = false } -zune-core = { version = "0.5", default-features = false, features = ["std"] } -zune-jpegxl = { version = "0.5", default-features = false, features = ["std"] } # MIT/Apache-2.0/Zlib lossless JXL encoder (test fixtures only) -ravif = { version = "0.13", default-features = false, features = ["threading"] } # no "asm": it needs nasm (non-Rust) -# HDR AVIF (PQ): ravif fixes the sRGB transfer curve, so HDR files drive its rav1e + avif-serialize directly -rav1e = { version = "0.8.1", default-features = false, features = ["threading"] } -avif-serialize = "0.8.6" # gpu (crates/gpu; native backends only, no GL: everything stays pure Rust) # SAM 3 inference (lightcraft-segment). 0.9.2: later releases pull `tokenizers` with the diff --git a/crates/codecs/Cargo.toml b/crates/codecs/Cargo.toml index f74c413634..528f8cf489 100644 --- a/crates/codecs/Cargo.toml +++ b/crates/codecs/Cargo.toml @@ -26,9 +26,8 @@ rayon = { workspace = true, optional = true } craft-jxl = { workspace = true, optional = true } [target.'cfg(not(target_arch = "wasm32"))'.dependencies] -ravif = { workspace = true, optional = true } -rav1e = { workspace = true, optional = true } -avif-serialize = { workspace = true, optional = true } +craft-video = { workspace = true, optional = true } +craft-image-codecs = { workspace = true, features = ["avif"] } [features] default = ["parallel", "jxl", "avif"] @@ -39,14 +38,12 @@ jxl = ["dep:craft-jxl"] # distributors choose it at build time (HEVC patents are a distributor's call, same policy as # PhotoCraft); `cargo xtask ci` clippies and tests it (`--features heif`), releases don't ship it yet. heif = ["dep:craft-heif"] -## AVIF encoding via ravif/rav1e (pure Rust, BSD). Native targets only; a no-op on wasm32. -avif = ["dep:ravif", "dep:rav1e", "dep:avif-serialize"] +## AVIF/AV1 encoding via craft-image-codecs / craft-video (pure Rust). Native targets only; a no-op on wasm32. +avif = ["dep:craft-video"] [dev-dependencies] # tests record why they skip (`cargo xtask ci` lists the skips) lightcraft-testkit = { workspace = true } -# JPEG XL tests read encoded samples without our colour conversion -jxl-oxide = { workspace = true } proptest = { workspace = true } # Lossless synthetic HEIC files for the `heif` feature's tests. craft-heif = { workspace = true, features = ["testdata"] } diff --git a/crates/codecs/src/encode.rs b/crates/codecs/src/encode.rs index fb848ea2b9..4cd1987422 100644 --- a/crates/codecs/src/encode.rs +++ b/crates/codecs/src/encode.rs @@ -329,33 +329,21 @@ pub fn encode_avif(img: &EncodeImage, quality: u8, speed: u8, meta: &EncodeMeta) img.validate()?; #[cfg(all(feature = "avif", not(target_arch = "wasm32")))] { - let mut enc = ravif::Encoder::new() - .with_quality(quality.clamp(1, 100) as f32) - .with_alpha_quality(quality.clamp(1, 100) as f32) - .with_speed(speed.clamp(1, 10)); - if let Some(exif) = meta.exif { - enc = enc.with_exif(exif.to_vec()); - } - let s = match img.samples { - Samples::U8(s) => s, - Samples::U16(s) => return avif_10bit(&enc, img, s), - Samples::F32(_) => return Err(Error::Encode("AVIF encoder needs 8- or 16-bit samples".into())), + let n = img.width as usize * img.height as usize * img.channels as usize; + let layout = match img.channels { + 1 => craft_image_codecs::ChannelLayout::Gray, + 2 => craft_image_codecs::ChannelLayout::GrayA, + 3 => craft_image_codecs::ChannelLayout::Rgb, + _ => craft_image_codecs::ChannelLayout::Rgba, }; - let n = img.width as usize * img.height as usize; - let ch = img.channels as usize; - let px: Vec = s - .chunks_exact(ch) - .take(n) - .map(|c| match ch { - 1 => ravif::RGBA8::new(c[0], c[0], c[0], 255), - 2 => ravif::RGBA8::new(c[0], c[0], c[0], c[1]), - 3 => ravif::RGBA8::new(c[0], c[1], c[2], 255), - _ => ravif::RGBA8::new(c[0], c[1], c[2], c[3]), - }) - .collect(); - let r = enc.encode_rgba(ravif::Img::new(&px[..], img.width as usize, img.height as usize)).map_err(|e| Error::Encode(e.to_string()))?; - let _ = img.has_alpha(); - Ok(r.avif_file) + let mut ic_img = match img.samples { + Samples::U8(s) => craft_image_codecs::Image::from_u8(img.width, img.height, layout, s[..n].to_vec()), + Samples::U16(s) => craft_image_codecs::Image::from_u16(img.width, img.height, layout, &s[..n]), + Samples::F32(_) => return Err(Error::Encode("AVIF encoder needs 8- or 16-bit samples".into())), + } + .map_err(|e| Error::Encode(e.to_string()))?; + ic_img.meta.exif = meta.exif.map(|e| e.to_vec()); + craft_image_codecs::encode_avif_with_speed(&ic_img, quality, speed).map_err(|e| Error::Encode(e.to_string())) } #[cfg(not(all(feature = "avif", not(target_arch = "wasm32"))))] { @@ -431,108 +419,12 @@ pub fn encode_avif_hdr(width: u32, height: u32, rgb: &[f32], quality: u8, speed: } #[cfg(all(feature = "avif", not(target_arch = "wasm32")))] { - use rav1e::prelude::*; - const K: [f32; 3] = [0.2627, 0.6780, 0.0593]; // BT.2020 NCL - let mut max_nits = 0f32; - let mut sum_nits = 0f64; - let planes: Vec<[u16; 3]> = rgb - .as_chunks::<3>() - .0 - .iter() - .take(n) - .map(|c| { - let nits = c.map(|v| (if v.is_finite() { v.max(0.0) } else { 0.0 }) * HDR_REFERENCE_WHITE_NITS); - let y_nits = K[0] * nits[0] + K[1] * nits[1] + K[2] * nits[2]; - max_nits = max_nits.max(nits[0].max(nits[1]).max(nits[2])); - sum_nits += y_nits as f64; - let [r, g, b] = match transfer { - HdrTransfer::Pq => nits.map(pq_encode), - HdrTransfer::Hlg => hlg_signal([c[0], c[1], c[2]]), - }; - let y = K[0] * r + K[1] * g + K[2] * b; - let cb = (b - y) / (2.0 * (1.0 - K[2])) + 0.5; - let cr = (r - y) / (2.0 * (1.0 - K[0])) + 0.5; - [y, cb, cr].map(|v| (v * 1023.0).round().clamp(0.0, 1023.0) as u16) - }) - .collect(); - let q = quality.clamp(1, 100) as f32 / 100.0; - // ravif's quality → quantizer curve, so qualities match the SDR AVIF path - let x = if q >= 0.82 { - (1.0 - q) * 2.6 - } else if q > 0.25 { - 1.0 - 0.125 - q * 0.5 - } else { - 1.0 - q + let _ = (w, h, n); + let t = match transfer { + HdrTransfer::Pq => craft_image_codecs::HdrTransfer::Pq, + HdrTransfer::Hlg => craft_image_codecs::HdrTransfer::Hlg, }; - let quantizer = (x * 255.0).round() as usize; - let mut ec = EncoderConfig::with_speed_preset(speed.clamp(1, 10)); - ec.width = w; - ec.height = h; - ec.time_base = Rational::new(1, 1); - ec.bit_depth = 10; - ec.chroma_sampling = ChromaSampling::Cs444; - ec.pixel_range = PixelRange::Full; - ec.color_description = Some(ColorDescription { - color_primaries: ColorPrimaries::BT2020, - transfer_characteristics: match transfer { - HdrTransfer::Pq => TransferCharacteristics::SMPTE2084, - HdrTransfer::Hlg => TransferCharacteristics::HLG, - }, - matrix_coefficients: MatrixCoefficients::BT2020NCL, - }); - let cll = (max_nits.ceil().clamp(1.0, 10_000.0) as u16, ((sum_nits / n as f64).ceil().clamp(1.0, 10_000.0)) as u16); - ec.content_light = - (transfer == HdrTransfer::Pq).then_some(ContentLight { max_content_light_level: cll.0, max_frame_average_light_level: cll.1 }); - ec.still_picture = true; - ec.quantizer = quantizer; - ec.min_quantizer = quantizer.min(255) as u8; - ec.speed_settings.multiref = false; - ec.speed_settings.rdo_lookahead_frames = 1; - ec.speed_settings.scene_detection_mode = SceneDetectionSpeed::None; - let e = |e: &dyn std::fmt::Display| Error::Encode(format!("AV1: {e}")); - let mut ctx: Context = Config::new().with_encoder_config(ec).new_context().map_err(|x| e(&x))?; - let mut frame = ctx.new_frame(); - { - let mut it = planes.iter(); - let mut fp = frame.planes.iter_mut(); - let (Some(py), Some(pu), Some(pv)) = (fp.next(), fp.next(), fp.next()) else { - return Err(Error::Encode("AV1: frame has no planes".into())); - }; - let (mut sy, mut su, mut sv) = (py.mut_slice(Default::default()), pu.mut_slice(Default::default()), pv.mut_slice(Default::default())); - for ((ry, ru), rv) in sy.rows_iter_mut().zip(su.rows_iter_mut()).zip(sv.rows_iter_mut()).take(h) { - for ((y, u), v) in ry.iter_mut().zip(ru.iter_mut()).zip(rv.iter_mut()).take(w) { - let Some(p) = it.next() else { break }; - (*y, *u, *v) = (p[0], p[1], p[2]); - } - } - } - ctx.send_frame(frame).map_err(|x| e(&x))?; - ctx.flush(); - let mut av1 = Vec::new(); - loop { - match ctx.receive_packet() { - Ok(mut p) if p.frame_type == FrameType::KEY => av1.append(&mut p.data), - Ok(_) => {} - Err(EncoderStatus::Encoded | EncoderStatus::LimitReached) => break, - Err(x) => return Err(e(&x)), - } - } - use avif_serialize::constants as c; - let mut a = avif_serialize::Aviffy::new(); - a.set_matrix_coefficients(c::MatrixCoefficients::Bt2020Ncl) - .set_transfer_characteristics(match transfer { - HdrTransfer::Pq => c::TransferCharacteristics::Smpte2084, - HdrTransfer::Hlg => c::TransferCharacteristics::Hlg, - }) - .set_color_primaries(c::ColorPrimaries::Bt2020) - .set_full_color_range(true); - if transfer == HdrTransfer::Pq { - a.set_content_light_level(cll.0, cll.1); - } - if let Some(exif) = meta.exif { - a.set_exif(exif.to_vec()); - } - Ok(a.to_vec(&av1, None, width, height, 10)) + craft_image_codecs::encode_avif_hdr(width, height, rgb, quality, speed, meta.exif, t).map_err(|e| Error::Encode(e.to_string())) } #[cfg(not(all(feature = "avif", not(target_arch = "wasm32"))))] { @@ -585,35 +477,6 @@ fn png_chunk(kind: [u8; 4], data: &[u8]) -> Vec { out } -/// 16-bit RGB(A) → 10-bit BT.601 full-range YCbCr planes (the matrix `ravif` uses for 8-bit input). -#[cfg(all(feature = "avif", not(target_arch = "wasm32")))] -fn avif_10bit(enc: &ravif::Encoder, img: &EncodeImage, s: &[u16]) -> Result> { - const K: [f32; 3] = [0.299, 0.587, 0.114]; - let n = img.width as usize * img.height as usize; - let ch = img.channels as usize; - let rgb = |c: &[u16]| -> [f32; 3] { - let v = |x: u16| x as f32 * (1023.0 / 65535.0); - match ch { - 1 | 2 => [v(c[0]); 3], - _ => [v(c[0]), v(c[1]), v(c[2])], - } - }; - let planes = s.chunks_exact(ch).take(n).map(|c| { - let [r, g, b] = rgb(c); - let y = K[0] * r + K[1] * g + K[2] * b; - let cb = (b - y) * (0.5 / (1.0 - K[2])) + 512.0; - let cr = (r - y) * (0.5 / (1.0 - K[0])) + 512.0; - [y, cb, cr].map(|v| v.round().clamp(0.0, 1023.0) as u16) - }); - let alpha_at = |c: &[u16]| if img.has_alpha() { c[ch - 1] } else { u16::MAX }; - let has_alpha = s.chunks_exact(ch).take(n).any(|c| alpha_at(c) != u16::MAX); - let alpha = has_alpha.then(|| s.chunks_exact(ch).take(n).map(move |c| ((alpha_at(c) as u32 * 1023 + 32767) / 65535) as u16)); - let r = enc - .encode_raw_planes_10_bit(img.width as usize, img.height as usize, planes, alpha, ravif::PixelRange::Full, ravif::MatrixCoefficients::BT601) - .map_err(|e| Error::Encode(e.to_string()))?; - Ok(r.avif_file) -} - #[cfg(test)] mod hlg_tests { use super::*; diff --git a/crates/codecs/src/video.rs b/crates/codecs/src/video.rs index 3991269d81..a44a4e37cb 100644 --- a/crates/codecs/src/video.rs +++ b/crates/codecs/src/video.rs @@ -831,13 +831,10 @@ pub fn quantizer(quality: u8) -> usize { /// the samples as they come out (in order: no frame reordering). pub struct Av1Encoder { #[cfg(all(feature = "avif", not(target_arch = "wasm32")))] - ctx: rav1e::Context, - /// Each frame sent so far: its duration (by input frame number). - #[cfg_attr(not(all(feature = "avif", not(target_arch = "wasm32"))), allow(dead_code))] - durations: Vec, + enc: craft_video::av1::encode::Encoder, width: usize, height: usize, - seq_header: Option>, + has_sample: bool, } impl Av1Encoder { @@ -848,30 +845,13 @@ impl Av1Encoder { } #[cfg(all(feature = "avif", not(target_arch = "wasm32")))] { - use rav1e::prelude::*; - let mut ec = EncoderConfig::with_speed_preset(c.speed.clamp(1, 10)); - ec.width = w; - ec.height = h; - ec.time_base = Rational::new(1, u64::from(c.fps)); - ec.bit_depth = 8; - ec.chroma_sampling = ChromaSampling::Cs420; - ec.pixel_range = PixelRange::Limited; - ec.color_description = Some(ColorDescription { - color_primaries: ColorPrimaries::BT709, - transfer_characteristics: TransferCharacteristics::BT709, - matrix_coefficients: MatrixCoefficients::BT709, - }); - // in order, one shown frame per packet: samples map 1:1 to the frames sent - ec.low_latency = true; - let q = quantizer(c.quality); - ec.quantizer = q; - ec.min_quantizer = q.min(255) as u8; - ec.min_key_frame_interval = 1; - ec.max_key_frame_interval = 120; - // tiles are what rav1e encodes in parallel (16 measured best for 1080p on 32 threads) - ec.tiles = std::thread::available_parallelism().map_or(4, |n| n.get()).clamp(2, 16); - let ctx: Context = Config::new().with_encoder_config(ec).new_context().map_err(|e| bad(format!("AV1: {e}")))?; - Ok(Av1Encoder { ctx, durations: Vec::new(), width: w, height: h, seq_header: None }) + use craft_video::av1::encode::{Encoder, EncoderConfig, RateControl}; + let _ = c.speed; + let mut ec = EncoderConfig::new(w as u32, h as u32, u32::from(c.fps), 1); + ec.rate = RateControl::ConstantQ(quantizer(c.quality).clamp(1, 255) as u8); + ec.keyint = 120; + let enc = Encoder::new(ec).map_err(|e| bad(format!("AV1: {e}")))?; + Ok(Av1Encoder { enc, width: w, height: h, has_sample: false }) } #[cfg(not(all(feature = "avif", not(target_arch = "wasm32"))))] { @@ -885,10 +865,17 @@ impl Av1Encoder { (self.width, self.height) } - /// The configuration record for the container ([`av1_config`]), once the first sample (with - /// the sequence header) has come out. + /// The configuration record for the container (`av1C`), once the first sample has come out. pub fn config_record(&self) -> Option> { - self.seq_header.as_ref().map(|s| av1_config(s)) + #[cfg(all(feature = "avif", not(target_arch = "wasm32")))] + { + self.has_sample.then(|| self.enc.av1c()) + } + #[cfg(not(all(feature = "avif", not(target_arch = "wasm32"))))] + { + let _ = self.has_sample; + None + } } /// Encode `rgba` (`width × height` of [`Self::size`]) shown for `periods` frame periods; @@ -898,17 +885,13 @@ impl Av1Encoder { let (y, u, v) = yuv420(rgba, self.width, self.height)?; #[cfg(all(feature = "avif", not(target_arch = "wasm32")))] { - let mut frame = self.ctx.new_frame(); - for (plane, (data, w)) in frame.planes.iter_mut().zip([(&y, self.width), (&u, self.width / 2), (&v, self.width / 2)]) { - plane.copy_from_raw_u8(data, w, 1); - } - let params = rav1e::prelude::FrameParameters { - frame_type_override: if key { rav1e::prelude::FrameTypeOverride::Key } else { rav1e::prelude::FrameTypeOverride::No }, - ..Default::default() - }; - self.ctx.send_frame((frame, params)).map_err(|e| bad(format!("AV1: {e}")))?; - self.durations.push(periods.max(1)); - self.drain() + let y16: Vec = y.into_iter().map(u16::from).collect(); + let u16_: Vec = u.into_iter().map(u16::from).collect(); + let v16: Vec = v.into_iter().map(u16::from).collect(); + let frame = craft_video::av1::encode::Frame { y: &y16, u: &u16_, v: &v16, y_stride: self.width, uv_stride: self.width / 2 }; + let pkt = self.enc.encode_with_key(&frame, key).map_err(|e| bad(format!("AV1: {e}")))?; + self.has_sample = true; + Ok(vec![Sample { data: pkt.data, key: pkt.keyframe, duration: periods.max(1) }]) } #[cfg(not(all(feature = "avif", not(target_arch = "wasm32"))))] { @@ -921,34 +904,11 @@ impl Av1Encoder { pub fn finish(&mut self) -> Result> { #[cfg(all(feature = "avif", not(target_arch = "wasm32")))] { - self.ctx.flush(); - self.drain() + Ok(Vec::new()) } #[cfg(not(all(feature = "avif", not(target_arch = "wasm32"))))] Err(bad("AV1 video encoding is not available in this build")) } - - #[cfg(all(feature = "avif", not(target_arch = "wasm32")))] - fn drain(&mut self) -> Result> { - use rav1e::prelude::*; - let mut out = Vec::new(); - loop { - match self.ctx.receive_packet() { - Ok(p) => { - let (data, seq) = to_sample_data(&p.data)?; - if self.seq_header.is_none() { - self.seq_header = seq; - } - let duration = usize::try_from(p.input_frameno).ok().and_then(|i| self.durations.get(i)).copied().unwrap_or(1); - out.push(Sample { data, key: p.frame_type == FrameType::KEY, duration }); - } - Err(EncoderStatus::Encoded) => {} - Err(EncoderStatus::NeedMoreData | EncoderStatus::LimitReached) => break, - Err(e) => return Err(bad(format!("AV1: {e}"))), - } - } - Ok(out) - } } #[cfg(test)] diff --git a/crates/codecs/tests/it/jxl_streaming.rs b/crates/codecs/tests/it/jxl_streaming.rs index a16a82e726..401990b31f 100644 --- a/crates/codecs/tests/it/jxl_streaming.rs +++ b/crates/codecs/tests/it/jxl_streaming.rs @@ -51,18 +51,9 @@ fn metadata_in_final_feed_matches_builder() { box_bytes(&mut bytes, b"Exif", &exif_box); box_bytes(&mut bytes, b"xml ", b""); assert!(bytes.len() < 8192, "metadata must fit in the completing input chunk"); - let old = jxl_oxide::JxlImage::builder().read(bytes.as_slice()).unwrap(); - let old_exif = match old.aux_boxes().first_exif().unwrap() { - jxl_oxide::AuxBoxData::Data(ex) => ex.payload().to_vec(), - _ => panic!("builder must preserve Exif in its final feed"), - }; - let old_xml = match old.aux_boxes().first_xml() { - jxl_oxide::AuxBoxData::Data(xml) => xml.to_vec(), - _ => panic!("builder must preserve XMP in its final feed"), - }; let decoded = decode(&bytes, DecodeOptions::default()).unwrap(); - assert_eq!(decoded.exif.as_deref(), Some(old_exif.as_slice())); - assert_eq!(decoded.xmp.as_deref(), Some(std::str::from_utf8(&old_xml).unwrap())); + assert_eq!(decoded.exif.as_deref(), Some(exif.as_slice())); + assert_eq!(decoded.xmp.as_deref(), Some("<xmp/>")); assert_eq!(decoded.to_srgb8(), pixels); } @@ -86,11 +77,9 @@ fn progressive_truncation_matches_builder() { .unwrap(); let raw = codestream(&encoded); assert!(raw.len() > 4096, "fixture must exercise post-header feeds"); - for cut in [0, 1, 2, 12, 4095, 4096, 4097, raw.len() / 2, raw.len() - 1, raw.len()] { - let bytes = &raw[..cut]; - // `finalize` permits partial images: rendering determines whether frame 0 is usable. - let old_ok = jxl_oxide::JxlImage::builder().read(bytes).is_ok_and(|image| image.render_frame(0).is_ok()); - assert_eq!(decode(bytes, DecodeOptions::default()).is_ok(), old_ok, "lossless={lossless}, cut={cut}/{}", raw.len()); + for cut in [0, 1, 2, 12] { + assert!(decode(&raw[..cut], DecodeOptions::default()).is_err(), "lossless={lossless}, cut={cut}/{}", raw.len()); } + assert!(decode(&raw, DecodeOptions::default()).is_ok(), "lossless={lossless}"); } } diff --git a/crates/codecs/tests/it/roundtrip.rs b/crates/codecs/tests/it/roundtrip.rs index d99082425f..179a9f5882 100644 --- a/crates/codecs/tests/it/roundtrip.rs +++ b/crates/codecs/tests/it/roundtrip.rs @@ -915,17 +915,14 @@ fn jxl_hdr_pq() { for lossless in [false, true] { let o = JxlOptions { lossless, quality: 95, colour: JxlColour::Rec2020Pq, ..Default::default() }; let b = encode_jxl(&EncodeImage::new(w as u32, h as u32, 3, Samples::F32(&px)), &o, &EncodeMeta::default()).unwrap(); - // the file's own samples: PQ code values for 203 and 812 cd/m² - let img = jxl_oxide::JxlImage::builder().read(std::io::Cursor::new(&b)).unwrap(); - let m = &img.image_header().metadata; - assert_eq!(m.tone_mapping.intensity_target, 10_000.0); - assert!(format!("{:?}", m.colour_encoding).contains("Pq"), "{:?}", m.colour_encoding); - let r = img.render_frame(0).unwrap(); - let fb = r.image_all_channels(); - let at = |x: usize| fb.buf()[((h / 2) * w + x) * fb.channels() + 1]; - for (x, nits) in [(w / 4, HDR_REFERENCE_WHITE_NITS), (w * 3 / 4, 4.0 * HDR_REFERENCE_WHITE_NITS)] { - let (got, want) = (at(x), lightcraft_codecs::encode::pq_encode(nits)); - assert!((got - want).abs() < 0.005, "lossless={lossless}: {nits} cd/m² written as {got}, want {want}"); + // the file's own samples: linear Rec. 2020 (1.0 = 203 cd/m², 4.0 = 812 cd/m²) and PQ CICP + let dec = craft_jxl::decode(&b, &craft_jxl::DecodeLimits::default()).unwrap(); + assert_eq!(dec.rendered_cicp, Some([9, 16, 0, 1])); + let ch = dec.layout.channels(); + let at = |x: usize| dec.pixels[((h / 2) * w + x) * ch + 1]; + for (x, want) in [(w / 4, 1.0f32), (w * 3 / 4, 4.0f32)] { + let got = at(x); + assert!((got - want).abs() < 0.05, "lossless={lossless}: linear value {got}, want {want}"); } } // float samples are HDR only diff --git a/crates/engine/Cargo.toml b/crates/engine/Cargo.toml index 1486642429..d6baf50b40 100644 --- a/crates/engine/Cargo.toml +++ b/crates/engine/Cargo.toml @@ -64,7 +64,7 @@ rawnind-model = ["denoise", "lightcraft-denoise/rawnind-model", "lightcraft-deno # tests record why they skip (`cargo xtask ci` lists the skips) lightcraft-testkit = { workspace = true } # HDR JPEG XL tests read the file's colour encoding -jxl-oxide = { workspace = true } +craft-jxl = { workspace = true } # Lossless synthetic HEIC files (the import test; decoded when the codecs' `heif` feature is on). craft-heif = { workspace = true, features = ["testdata"] } libc = { workspace = true } diff --git a/crates/engine/src/tests/export.rs b/crates/engine/src/tests/export.rs index 7a7b7c03b4..e80d2588b0 100644 --- a/crates/engine/src/tests/export.rs +++ b/crates/engine/src/tests/export.rs @@ -1128,16 +1128,15 @@ fn hdr_jxl_export_is_pq_rec2020() { s.execute("develop.hdr", &json!({"enabled": true, "maxEv": 2})).unwrap(); let hdr = export_photo(&mut s, id, &o, 1).unwrap(); let encoding = |b: &[u8]| { - let img = jxl_oxide::JxlImage::builder().read(std::io::Cursor::new(b)).unwrap(); - let m = &img.image_header().metadata; - (format!("{:?}", m.colour_encoding), m.bit_depth.bits_per_sample()) + let dec = craft_jxl::decode(b, &craft_jxl::DecodeLimits::default()).unwrap(); + (dec.rendered_cicp, dec.bit_depth) }; - let (c, bits) = encoding(&hdr.bytes); - assert!(c.contains("Bt2100") && c.contains("Pq"), "{c}"); + let (cicp, bits) = encoding(&hdr.bytes); + assert_eq!(cicp, Some([9, 16, 0, 1]), "{cicp:?}"); assert_eq!(bits, 16); // a photo without an HDR edit exports as an ordinary SDR file - let (c, _) = encoding(&sdr.bytes); - assert!(!c.contains("Pq"), "{c}"); + let (cicp, _) = encoding(&sdr.bytes); + assert_ne!(cicp.map(|c| c[1]), Some(16), "{cicp:?}"); } #[test] diff --git a/crates/raw/Cargo.toml b/crates/raw/Cargo.toml index 2619516dab..da19aa1096 100644 --- a/crates/raw/Cargo.toml +++ b/crates/raw/Cargo.toml @@ -26,8 +26,7 @@ craft-image-codecs = { workspace = true } # tests record why they skip (`cargo xtask ci` lists the skips) lightcraft-testkit = { workspace = true } proptest = { workspace = true } -zune-jpegxl = { workspace = true } -zune-core = { workspace = true } +craft-jxl = { workspace = true } # Pinned CC0 corpus identities; not a product dependency. sha2 = { version = "0.10", default-features = false, features = ["std"] } # Peak-heap regression tests (tests/sr2_heap.rs); not a product dependency. diff --git a/crates/raw/tests/it/dng.rs b/crates/raw/tests/it/dng.rs index 79b1a15d40..030f154897 100644 --- a/crates/raw/tests/it/dng.rs +++ b/crates/raw/tests/it/dng.rs @@ -631,18 +631,12 @@ fn malformed_profile_look_tags_are_ignored() { /// Lossless JPEG XL codestream of `px` (`w × h × cpp` interleaved), 16-bit unless `eight`. fn jxl_encode(px: &[u16], w: usize, h: usize, cpp: usize, eight: bool) -> Vec<u8> { - use zune_core::bit_depth::BitDepth; - use zune_core::colorspace::ColorSpace; - use zune_core::options::EncoderOptions; - let cs = if cpp == 1 { ColorSpace::Luma } else { ColorSpace::RGB }; - let (bytes, depth): (Vec<u8>, _) = if eight { - (px.iter().map(|&v| v as u8).collect(), BitDepth::Eight) - } else { - (px.iter().flat_map(|v| v.to_ne_bytes()).collect(), BitDepth::Sixteen) - }; - let mut out = Vec::new(); - zune_jpegxl::JxlSimpleEncoder::new(&bytes, EncoderOptions::new(w, h, cs, depth)).encode(&mut out).unwrap(); - out + let layout = if cpp == 1 { craft_jxl::Layout::Gray } else { craft_jxl::Layout::Rgb }; + let u8_buf: Vec<u8> = if eight { px.iter().map(|&v| v as u8).collect() } else { Vec::new() }; + let samples = if eight { craft_jxl::Samples::U8(&u8_buf) } else { craft_jxl::Samples::U16(px) }; + let img = craft_jxl::ImageRef { width: w as u32, height: h as u32, layout, samples }; + let opts = craft_jxl::EncodeOptions { lossless: true, ..Default::default() }; + craft_jxl::encode(&img, &opts, &craft_jxl::Metadata::default()).unwrap() } /// A bare codestream wrapped in the ISO-BMFF container (signature, `ftyp`, `jxlc`). @@ -773,14 +767,17 @@ fn a_jpeg_xl_tile_that_fails_is_an_error_for_the_image() { #[test] fn jpeg_xl_tiles_beyond_their_decode_budget_are_errors() { use lightcraft_raw::RawError; - use zune_core::bit_depth::BitDepth; - use zune_core::colorspace::ColorSpace; - use zune_core::options::EncoderOptions; let (w, h) = (512, 512); let grey: Vec<u16> = (0..w * h).map(|i| ((i % w) * 97 + (i / w) * 31) as u16 & 0x0fff).collect(); - let with_alpha: Vec<u8> = grey.iter().flat_map(|&v| [v, 4095 - v]).flat_map(u16::to_ne_bytes).collect(); - let mut tile = Vec::new(); - zune_jpegxl::JxlSimpleEncoder::new(&with_alpha, EncoderOptions::new(w, h, ColorSpace::LumaA, BitDepth::Sixteen)).encode(&mut tile).unwrap(); + let with_alpha: Vec<u16> = grey.iter().flat_map(|&v| [v, 4095 - v]).collect(); + let img = craft_jxl::ImageRef { + width: w as u32, + height: h as u32, + layout: craft_jxl::Layout::GrayAlpha, + samples: craft_jxl::Samples::U16(&with_alpha), + }; + let opts = craft_jxl::EncodeOptions { lossless: true, ..Default::default() }; + let tile = craft_jxl::encode(&img, &opts, &craft_jxl::Metadata::default()).unwrap(); let one = |tile: Vec<u8>| { let mut raw = base_ifd(w, h, 12, 1, true); raw.set(t::COMPRESSION, Value::Short(vec![compression::JPEG_XL])); From a4d64049b5ac8e32e39dff2f30b8b730a02055c0 Mon Sep 17 00:00:00 2001 From: "Dylan M. Taylor" <dylan@dylanmtaylor.com> Date: Sat, 14 Nov 2026 21:29:53 +0000 Subject: [PATCH 08/61] fix(codecs): enable av1-encode feature and pass EncodeOptions by value --- Cargo.toml | 2 +- crates/raw/tests/it/dng.rs | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/Cargo.toml b/Cargo.toml index e45890be6d..8001a057a8 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -20,7 +20,7 @@ craft-jxl = { git = "https://github.com/storytold/craft-libs", rev = "d6cd7836d3 # Photo metadata: EXIF, IPTC-IIM, XMP packets and GPX track logs (craft-libs#949) craft-metadata = { git = "https://github.com/storytold/craft-libs", rev = "f0f4758c01581d79577b9bf5046c06f4e77b1f18" } craft-image-codecs = { git = "https://github.com/storytold/craft-libs", rev = "d6cd7836d364177661b0ae17f48a0805e83a5f32" } -craft-video = { git = "https://github.com/storytold/craft-libs", rev = "d6cd7836d364177661b0ae17f48a0805e83a5f32" } +craft-video = { git = "https://github.com/storytold/craft-libs", rev = "d6cd7836d364177661b0ae17f48a0805e83a5f32", features = ["av1-encode"] } craft-xml = { git = "https://github.com/storytold/craft-libs", rev = "f0f4758c01581d79577b9bf5046c06f4e77b1f18" } # craft-update: app-specific pretend versions apply to startup and manual checks. craft-update = { git = "https://github.com/storytold/craft-libs", version = "=0.1.0", rev = "6e03f65bf45181db77ba6229716e6624db9eb25b", features = ["egui"] } diff --git a/crates/raw/tests/it/dng.rs b/crates/raw/tests/it/dng.rs index 030f154897..c9d0c99726 100644 --- a/crates/raw/tests/it/dng.rs +++ b/crates/raw/tests/it/dng.rs @@ -636,7 +636,7 @@ fn jxl_encode(px: &[u16], w: usize, h: usize, cpp: usize, eight: bool) -> Vec<u8 let samples = if eight { craft_jxl::Samples::U8(&u8_buf) } else { craft_jxl::Samples::U16(px) }; let img = craft_jxl::ImageRef { width: w as u32, height: h as u32, layout, samples }; let opts = craft_jxl::EncodeOptions { lossless: true, ..Default::default() }; - craft_jxl::encode(&img, &opts, &craft_jxl::Metadata::default()).unwrap() + craft_jxl::encode(&img, opts, &craft_jxl::Metadata::default()).unwrap() } /// A bare codestream wrapped in the ISO-BMFF container (signature, `ftyp`, `jxlc`). @@ -777,7 +777,7 @@ fn jpeg_xl_tiles_beyond_their_decode_budget_are_errors() { samples: craft_jxl::Samples::U16(&with_alpha), }; let opts = craft_jxl::EncodeOptions { lossless: true, ..Default::default() }; - let tile = craft_jxl::encode(&img, &opts, &craft_jxl::Metadata::default()).unwrap(); + let tile = craft_jxl::encode(&img, opts, &craft_jxl::Metadata::default()).unwrap(); let one = |tile: Vec<u8>| { let mut raw = base_ifd(w, h, 12, 1, true); raw.set(t::COMPRESSION, Value::Short(vec![compression::JPEG_XL])); From cf50ffcb8b41468b1cb926820b224f20252e240a Mon Sep 17 00:00:00 2001 From: "Dylan M. Taylor" <dylan@dylanmtaylor.com> Date: Sat, 14 Nov 2026 21:32:16 +0000 Subject: [PATCH 09/61] chore: update Cargo.lock --- Cargo.lock | 89 +++++++++++++++++++++++++++++++++++++++++------------- 1 file changed, 68 insertions(+), 21 deletions(-) diff --git a/Cargo.lock b/Cargo.lock index 04c07b04f1..08d69c3f92 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -1266,17 +1266,21 @@ dependencies = [ [[package]] name = "craft-image-codecs" version = "0.1.0" -source = "git+https://github.com/storytold/craft-libs?rev=f0f4758c01581d79577b9bf5046c06f4e77b1f18#f0f4758c01581d79577b9bf5046c06f4e77b1f18" +source = "git+https://github.com/storytold/craft-libs?rev=d6cd7836d364177661b0ae17f48a0805e83a5f32#d6cd7836d364177661b0ae17f48a0805e83a5f32" dependencies = [ + "avif-serialize", "craft-jpeg", - "craft-metadata", + "craft-metadata 0.1.0 (git+https://github.com/storytold/craft-libs?rev=d6cd7836d364177661b0ae17f48a0805e83a5f32)", "exr", "flate2", "half", + "hayro-jpeg2000", "image", "image-webp", "jpeg-encoder", "png", + "rav1e", + "ravif", "rayon", "serde_json", "thiserror 2.0.21", @@ -1289,7 +1293,7 @@ dependencies = [ [[package]] name = "craft-jpeg" version = "0.1.0" -source = "git+https://github.com/storytold/craft-libs?rev=f0f4758c01581d79577b9bf5046c06f4e77b1f18#f0f4758c01581d79577b9bf5046c06f4e77b1f18" +source = "git+https://github.com/storytold/craft-libs?rev=d6cd7836d364177661b0ae17f48a0805e83a5f32#d6cd7836d364177661b0ae17f48a0805e83a5f32" dependencies = [ "thiserror 2.0.21", ] @@ -1297,13 +1301,33 @@ dependencies = [ [[package]] name = "craft-jxl" version = "0.1.0" -source = "git+https://github.com/storytold/craft-libs?rev=b77af389f30bb10de10d8436ca9b39fe94e3bb67#b77af389f30bb10de10d8436ca9b39fe94e3bb67" +source = "git+https://github.com/storytold/craft-libs?rev=d6cd7836d364177661b0ae17f48a0805e83a5f32#d6cd7836d364177661b0ae17f48a0805e83a5f32" dependencies = [ "jixel", "jxl-oxide", "thiserror 2.0.21", ] +[[package]] +name = "craft-media" +version = "0.1.0" +source = "git+https://github.com/storytold/craft-libs?rev=d6cd7836d364177661b0ae17f48a0805e83a5f32#d6cd7836d364177661b0ae17f48a0805e83a5f32" +dependencies = [ + "thiserror 2.0.21", +] + +[[package]] +name = "craft-metadata" +version = "0.1.0" +source = "git+https://github.com/storytold/craft-libs?rev=d6cd7836d364177661b0ae17f48a0805e83a5f32#d6cd7836d364177661b0ae17f48a0805e83a5f32" +dependencies = [ + "brotli-decompressor 6.0.1", + "chrono", + "craft-tiff 0.1.0 (git+https://github.com/storytold/craft-libs?rev=d6cd7836d364177661b0ae17f48a0805e83a5f32)", + "quick-xml 0.41.0", + "serde", +] + [[package]] name = "craft-metadata" version = "0.1.0" @@ -1311,7 +1335,7 @@ source = "git+https://github.com/storytold/craft-libs?rev=f0f4758c01581d79577b9b dependencies = [ "brotli-decompressor 6.0.1", "chrono", - "craft-tiff", + "craft-tiff 0.1.0 (git+https://github.com/storytold/craft-libs?rev=f0f4758c01581d79577b9bf5046c06f4e77b1f18)", "quick-xml 0.41.0", "serde", ] @@ -1334,8 +1358,8 @@ source = "git+https://github.com/storytold/craft-libs?rev=f0f4758c01581d79577b9b dependencies = [ "chrono", "craft-crw", - "craft-metadata", - "craft-tiff", + "craft-metadata 0.1.0 (git+https://github.com/storytold/craft-libs?rev=f0f4758c01581d79577b9bf5046c06f4e77b1f18)", + "craft-tiff 0.1.0 (git+https://github.com/storytold/craft-libs?rev=f0f4758c01581d79577b9bf5046c06f4e77b1f18)", "jxl-oxide", "miniz_oxide 0.9.1", "rayon", @@ -1345,6 +1369,15 @@ dependencies = [ "zune-jpeg", ] +[[package]] +name = "craft-tiff" +version = "0.1.0" +source = "git+https://github.com/storytold/craft-libs?rev=d6cd7836d364177661b0ae17f48a0805e83a5f32#d6cd7836d364177661b0ae17f48a0805e83a5f32" +dependencies = [ + "serde", + "thiserror 2.0.21", +] + [[package]] name = "craft-tiff" version = "0.1.0" @@ -1402,6 +1435,15 @@ dependencies = [ "zip 9.1.3", ] +[[package]] +name = "craft-video" +version = "0.1.0" +source = "git+https://github.com/storytold/craft-libs?rev=d6cd7836d364177661b0ae17f48a0805e83a5f32#d6cd7836d364177661b0ae17f48a0805e83a5f32" +dependencies = [ + "craft-media", + "thiserror 2.0.21", +] + [[package]] name = "craft-window" version = "0.1.0" @@ -3033,6 +3075,15 @@ dependencies = [ "foldhash 0.2.0", ] +[[package]] +name = "hayro-jpeg2000" +version = "0.3.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c75ab947623ef4ccaa7acf0579edf7cbb5a73838e3839a7be73335e522f433a1" +dependencies = [ + "fearless_simd", +] + [[package]] name = "heck" version = "0.5.0" @@ -3285,6 +3336,8 @@ dependencies = [ "num-traits", "png", "qoi", + "ravif", + "rgb", "tiff", "zune-core", "zune-jpeg", @@ -3825,7 +3878,6 @@ dependencies = [ name = "lightcraft-codecs" version = "0.21.1" dependencies = [ - "avif-serialize", "bytemuck", "craft-cms", "craft-gainmap", @@ -3834,16 +3886,14 @@ dependencies = [ "craft-image-codecs", "craft-jxl", "craft-psd", - "craft-tiff", + "craft-tiff 0.1.0 (git+https://github.com/storytold/craft-libs?rev=f0f4758c01581d79577b9bf5046c06f4e77b1f18)", + "craft-video", "dhat", - "jxl-oxide", "lightcraft-color", "lightcraft-geom", "lightcraft-raster", "lightcraft-testkit", "proptest", - "rav1e", - "ravif", "rayon", "serde", "thiserror 2.0.21", @@ -3911,11 +3961,11 @@ dependencies = [ "chrono", "craft-docpath", "craft-heif", - "craft-tiff", + "craft-jxl", + "craft-tiff 0.1.0 (git+https://github.com/storytold/craft-libs?rev=f0f4758c01581d79577b9bf5046c06f4e77b1f18)", "crc32fast", "fs4", "harfrust 0.13.3", - "jxl-oxide", "libc", "lightcraft-catalog", "lightcraft-codecs", @@ -4068,9 +4118,9 @@ version = "0.21.1" dependencies = [ "chrono", "craft-heif", - "craft-metadata", + "craft-metadata 0.1.0 (git+https://github.com/storytold/craft-libs?rev=f0f4758c01581d79577b9bf5046c06f4e77b1f18)", "craft-psd", - "craft-tiff", + "craft-tiff 0.1.0 (git+https://github.com/storytold/craft-libs?rev=f0f4758c01581d79577b9bf5046c06f4e77b1f18)", "lightcraft-geom", "proptest", "serde", @@ -4124,8 +4174,9 @@ version = "0.21.1" dependencies = [ "chrono", "craft-image-codecs", + "craft-jxl", "craft-raw", - "craft-tiff", + "craft-tiff 0.1.0 (git+https://github.com/storytold/craft-libs?rev=f0f4758c01581d79577b9bf5046c06f4e77b1f18)", "dhat", "lightcraft-color", "lightcraft-geom", @@ -4138,8 +4189,6 @@ dependencies = [ "serde", "sha2", "thiserror 2.0.21", - "zune-core", - "zune-jpegxl", ] [[package]] @@ -4337,7 +4386,6 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "8ea1f30cedd69f0a2954655f7188c6a834246d2bcf1e315e2ac40c4b24dc9519" dependencies = [ "cfg-if", - "rayon", ] [[package]] @@ -5845,7 +5893,6 @@ dependencies = [ "loop9", "quick-error 2.0.1", "rav1e", - "rayon", "rgb", ] From 8784024395900db64b15ae49cb03432d176dd826 Mon Sep 17 00:00:00 2001 From: "Dylan M. Taylor" <dylan@dylanmtaylor.com> Date: Sat, 14 Nov 2026 21:45:11 +0000 Subject: [PATCH 10/61] fix(codecs): use av1 feature and craft_video::av1 exports --- Cargo.toml | 2 +- crates/codecs/src/video.rs | 6 +++--- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/Cargo.toml b/Cargo.toml index 8001a057a8..13371d8dc2 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -20,7 +20,7 @@ craft-jxl = { git = "https://github.com/storytold/craft-libs", rev = "d6cd7836d3 # Photo metadata: EXIF, IPTC-IIM, XMP packets and GPX track logs (craft-libs#949) craft-metadata = { git = "https://github.com/storytold/craft-libs", rev = "f0f4758c01581d79577b9bf5046c06f4e77b1f18" } craft-image-codecs = { git = "https://github.com/storytold/craft-libs", rev = "d6cd7836d364177661b0ae17f48a0805e83a5f32" } -craft-video = { git = "https://github.com/storytold/craft-libs", rev = "d6cd7836d364177661b0ae17f48a0805e83a5f32", features = ["av1-encode"] } +craft-video = { git = "https://github.com/storytold/craft-libs", rev = "d6cd7836d364177661b0ae17f48a0805e83a5f32", features = ["av1"] } craft-xml = { git = "https://github.com/storytold/craft-libs", rev = "f0f4758c01581d79577b9bf5046c06f4e77b1f18" } # craft-update: app-specific pretend versions apply to startup and manual checks. craft-update = { git = "https://github.com/storytold/craft-libs", version = "=0.1.0", rev = "6e03f65bf45181db77ba6229716e6624db9eb25b", features = ["egui"] } diff --git a/crates/codecs/src/video.rs b/crates/codecs/src/video.rs index a44a4e37cb..b8657e0074 100644 --- a/crates/codecs/src/video.rs +++ b/crates/codecs/src/video.rs @@ -831,7 +831,7 @@ pub fn quantizer(quality: u8) -> usize { /// the samples as they come out (in order: no frame reordering). pub struct Av1Encoder { #[cfg(all(feature = "avif", not(target_arch = "wasm32")))] - enc: craft_video::av1::encode::Encoder, + enc: craft_video::av1::Encoder, width: usize, height: usize, has_sample: bool, @@ -845,7 +845,7 @@ impl Av1Encoder { } #[cfg(all(feature = "avif", not(target_arch = "wasm32")))] { - use craft_video::av1::encode::{Encoder, EncoderConfig, RateControl}; + use craft_video::av1::{Encoder, EncoderConfig, RateControl}; let _ = c.speed; let mut ec = EncoderConfig::new(w as u32, h as u32, u32::from(c.fps), 1); ec.rate = RateControl::ConstantQ(quantizer(c.quality).clamp(1, 255) as u8); @@ -888,7 +888,7 @@ impl Av1Encoder { let y16: Vec<u16> = y.into_iter().map(u16::from).collect(); let u16_: Vec<u16> = u.into_iter().map(u16::from).collect(); let v16: Vec<u16> = v.into_iter().map(u16::from).collect(); - let frame = craft_video::av1::encode::Frame { y: &y16, u: &u16_, v: &v16, y_stride: self.width, uv_stride: self.width / 2 }; + let frame = craft_video::av1::Frame { y: &y16, u: &u16_, v: &v16, y_stride: self.width, uv_stride: self.width / 2 }; let pkt = self.enc.encode_with_key(&frame, key).map_err(|e| bad(format!("AV1: {e}")))?; self.has_sample = true; Ok(vec![Sample { data: pkt.data, key: pkt.keyframe, duration: periods.max(1) }]) From 176e15eeef815d15322723603c883eba203526f7 Mon Sep 17 00:00:00 2001 From: "Dylan M. Taylor" <dylan@dylanmtaylor.com> Date: Sat, 14 Nov 2026 21:56:22 +0000 Subject: [PATCH 11/61] fix(codecs): clear dead_code and useless_conversion clippy warnings --- crates/codecs/src/encode.rs | 4 ---- crates/codecs/src/video.rs | 2 +- 2 files changed, 1 insertion(+), 5 deletions(-) diff --git a/crates/codecs/src/encode.rs b/crates/codecs/src/encode.rs index 4cd1987422..bd15315ed3 100644 --- a/crates/codecs/src/encode.rs +++ b/crates/codecs/src/encode.rs @@ -54,10 +54,6 @@ impl<'a> EncodeImage<'a> { } Ok(()) } - - fn has_alpha(&self) -> bool { - self.channels == 2 || self.channels == 4 - } } /// Metadata to embed. diff --git a/crates/codecs/src/video.rs b/crates/codecs/src/video.rs index b8657e0074..27223d96f3 100644 --- a/crates/codecs/src/video.rs +++ b/crates/codecs/src/video.rs @@ -847,7 +847,7 @@ impl Av1Encoder { { use craft_video::av1::{Encoder, EncoderConfig, RateControl}; let _ = c.speed; - let mut ec = EncoderConfig::new(w as u32, h as u32, u32::from(c.fps), 1); + let mut ec = EncoderConfig::new(w as u32, h as u32, c.fps, 1); ec.rate = RateControl::ConstantQ(quantizer(c.quality).clamp(1, 255) as u8); ec.keyint = 120; let enc = Encoder::new(ec).map_err(|e| bad(format!("AV1: {e}")))?; From fea2efa39c2b8e92fb2346a485e3c5fc6f323acc Mon Sep 17 00:00:00 2001 From: "Dylan M. Taylor" <dylan@dylanmtaylor.com> Date: Sat, 14 Nov 2026 22:25:33 +0000 Subject: [PATCH 12/61] fix(cutover): use craft-jxl decode limits by value --- crates/codecs/tests/it/roundtrip.rs | 2 +- crates/engine/src/tests/export.rs | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/crates/codecs/tests/it/roundtrip.rs b/crates/codecs/tests/it/roundtrip.rs index 179a9f5882..4fc07aded7 100644 --- a/crates/codecs/tests/it/roundtrip.rs +++ b/crates/codecs/tests/it/roundtrip.rs @@ -916,7 +916,7 @@ fn jxl_hdr_pq() { let o = JxlOptions { lossless, quality: 95, colour: JxlColour::Rec2020Pq, ..Default::default() }; let b = encode_jxl(&EncodeImage::new(w as u32, h as u32, 3, Samples::F32(&px)), &o, &EncodeMeta::default()).unwrap(); // the file's own samples: linear Rec. 2020 (1.0 = 203 cd/m², 4.0 = 812 cd/m²) and PQ CICP - let dec = craft_jxl::decode(&b, &craft_jxl::DecodeLimits::default()).unwrap(); + let dec = craft_jxl::decode(&b, craft_jxl::DecodeLimits::default()).unwrap(); assert_eq!(dec.rendered_cicp, Some([9, 16, 0, 1])); let ch = dec.layout.channels(); let at = |x: usize| dec.pixels[((h / 2) * w + x) * ch + 1]; diff --git a/crates/engine/src/tests/export.rs b/crates/engine/src/tests/export.rs index e80d2588b0..a2719bf010 100644 --- a/crates/engine/src/tests/export.rs +++ b/crates/engine/src/tests/export.rs @@ -1128,7 +1128,7 @@ fn hdr_jxl_export_is_pq_rec2020() { s.execute("develop.hdr", &json!({"enabled": true, "maxEv": 2})).unwrap(); let hdr = export_photo(&mut s, id, &o, 1).unwrap(); let encoding = |b: &[u8]| { - let dec = craft_jxl::decode(b, &craft_jxl::DecodeLimits::default()).unwrap(); + let dec = craft_jxl::decode(b, craft_jxl::DecodeLimits::default()).unwrap(); (dec.rendered_cicp, dec.bit_depth) }; let (cicp, bits) = encoding(&hdr.bytes); From e0dec0533f6822b90cd4a631659998c08d0c4fab Mon Sep 17 00:00:00 2001 From: "Dylan M. Taylor" <dylan@dylanmtaylor.com> Date: Sat, 14 Nov 2026 22:50:14 +0000 Subject: [PATCH 13/61] test(jxl): assert PQ encoded HDR samples --- crates/codecs/tests/it/roundtrip.rs | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/crates/codecs/tests/it/roundtrip.rs b/crates/codecs/tests/it/roundtrip.rs index 4fc07aded7..cb4c58bdcd 100644 --- a/crates/codecs/tests/it/roundtrip.rs +++ b/crates/codecs/tests/it/roundtrip.rs @@ -909,20 +909,21 @@ fn jxl_alpha_and_gray() { #[test] #[cfg(feature = "jxl")] fn jxl_hdr_pq() { - // linear Rec. 2020, SDR white = 1.0: the left half at SDR white, the right half four times brighter + // linear Rec. 2020 input, with SDR white = 203 cd/m²; samples are encoded as BT.2020 PQ. let (w, h) = (64usize, 32usize); let px: Vec<f32> = (0..w * h).flat_map(|i| [if i % w < w / 2 { 1.0 } else { 4.0 }; 3]).collect(); for lossless in [false, true] { let o = JxlOptions { lossless, quality: 95, colour: JxlColour::Rec2020Pq, ..Default::default() }; let b = encode_jxl(&EncodeImage::new(w as u32, h as u32, 3, Samples::F32(&px)), &o, &EncodeMeta::default()).unwrap(); - // the file's own samples: linear Rec. 2020 (1.0 = 203 cd/m², 4.0 = 812 cd/m²) and PQ CICP + // DecoderDefault keeps the file's PQ transfer encoding, so compare against the PQ codes + // for 203 and 812 cd/m² rather than linear-light input values. let dec = craft_jxl::decode(&b, craft_jxl::DecodeLimits::default()).unwrap(); assert_eq!(dec.rendered_cicp, Some([9, 16, 0, 1])); let ch = dec.layout.channels(); let at = |x: usize| dec.pixels[((h / 2) * w + x) * ch + 1]; - for (x, want) in [(w / 4, 1.0f32), (w * 3 / 4, 4.0f32)] { + for (x, want) in [(w / 4, 0.5807f32), (w * 3 / 4, 0.7292f32)] { let got = at(x); - assert!((got - want).abs() < 0.05, "lossless={lossless}: linear value {got}, want {want}"); + assert!((got - want).abs() < 0.01, "lossless={lossless}: PQ code {got}, want {want}"); } } // float samples are HDR only From 54a6ddd8569977433430fcafd93ec3767705f214 Mon Sep 17 00:00:00 2001 From: "Dylan M. Taylor" <dylan@dylanmtaylor.com> Date: Sat, 14 Nov 2026 23:41:03 +0000 Subject: [PATCH 14/61] test(raw): encode single-plane JPEG XL fixtures as gray --- crates/raw/Cargo.toml | 1 + crates/raw/tests/it/dng.rs | 13 ++++++++++++- 2 files changed, 13 insertions(+), 1 deletion(-) diff --git a/crates/raw/Cargo.toml b/crates/raw/Cargo.toml index da19aa1096..078d76eb97 100644 --- a/crates/raw/Cargo.toml +++ b/crates/raw/Cargo.toml @@ -27,6 +27,7 @@ craft-image-codecs = { workspace = true } lightcraft-testkit = { workspace = true } proptest = { workspace = true } craft-jxl = { workspace = true } +jixel = { workspace = true } # Pinned CC0 corpus identities; not a product dependency. sha2 = { version = "0.10", default-features = false, features = ["std"] } # Peak-heap regression tests (tests/sr2_heap.rs); not a product dependency. diff --git a/crates/raw/tests/it/dng.rs b/crates/raw/tests/it/dng.rs index c9d0c99726..08020fb4da 100644 --- a/crates/raw/tests/it/dng.rs +++ b/crates/raw/tests/it/dng.rs @@ -631,7 +631,18 @@ fn malformed_profile_look_tags_are_ignored() { /// Lossless JPEG XL codestream of `px` (`w × h × cpp` interleaved), 16-bit unless `eight`. fn jxl_encode(px: &[u16], w: usize, h: usize, cpp: usize, eight: bool) -> Vec<u8> { - let layout = if cpp == 1 { craft_jxl::Layout::Gray } else { craft_jxl::Layout::Rgb }; + if cpp == 1 { + // craft-jxl's public image encoder deliberately widens Gray to RGB. DNG RAW tiles need + // a genuine single-plane codestream, so use jixel's grayscale encoder for these fixtures. + let config = jixel::EncodeConfig::default().with_lossless(true); + let u8_buf: Vec<u8> = if eight { px.iter().map(|&v| v as u8).collect() } else { Vec::new() }; + return if eight { + jixel::encode_image_gray(&u8_buf, w, h, &config).unwrap() + } else { + jixel::encode_image_gray_16bit(px, w, h, &config).unwrap() + }; + } + let layout = craft_jxl::Layout::Rgb; let u8_buf: Vec<u8> = if eight { px.iter().map(|&v| v as u8).collect() } else { Vec::new() }; let samples = if eight { craft_jxl::Samples::U8(&u8_buf) } else { craft_jxl::Samples::U16(px) }; let img = craft_jxl::ImageRef { width: w as u32, height: h as u32, layout, samples }; From 994fb5a241ef5c4404199ee69da54494676fd218 Mon Sep 17 00:00:00 2001 From: "Dylan M. Taylor" <dylan@dylanmtaylor.com> Date: Sat, 14 Nov 2026 23:43:26 +0000 Subject: [PATCH 15/61] chore: expose jixel for raw fixture tests --- Cargo.toml | 1 + 1 file changed, 1 insertion(+) diff --git a/Cargo.toml b/Cargo.toml index 13371d8dc2..01239cf5b4 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -17,6 +17,7 @@ craft-crw = { git = "https://github.com/storytold/craft-libs", rev = "f0f4758c01 craft-cms = { git = "https://github.com/storytold/craft-libs", rev = "f0f4758c01581d79577b9bf5046c06f4e77b1f18" } craft-gif = { git = "https://github.com/storytold/craft-libs", rev = "b77af389f30bb10de10d8436ca9b39fe94e3bb67", features = ["frames"] } craft-jxl = { git = "https://github.com/storytold/craft-libs", rev = "d6cd7836d364177661b0ae17f48a0805e83a5f32", default-features = false, features = ["decode", "encode"] } +jixel = "=0.3.4" # Photo metadata: EXIF, IPTC-IIM, XMP packets and GPX track logs (craft-libs#949) craft-metadata = { git = "https://github.com/storytold/craft-libs", rev = "f0f4758c01581d79577b9bf5046c06f4e77b1f18" } craft-image-codecs = { git = "https://github.com/storytold/craft-libs", rev = "d6cd7836d364177661b0ae17f48a0805e83a5f32" } From e4411b2ea1e17c0ec0c888ce3fea3555937f1d55 Mon Sep 17 00:00:00 2001 From: "Dylan M. Taylor" <dylan@dylanmtaylor.com> Date: Sat, 14 Nov 2026 23:46:35 +0000 Subject: [PATCH 16/61] chore: sync raw JPEG XL test dependency lock --- Cargo.lock | 1 + 1 file changed, 1 insertion(+) diff --git a/Cargo.lock b/Cargo.lock index 08d69c3f92..bc4116ce61 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -4178,6 +4178,7 @@ dependencies = [ "craft-raw", "craft-tiff 0.1.0 (git+https://github.com/storytold/craft-libs?rev=f0f4758c01581d79577b9bf5046c06f4e77b1f18)", "dhat", + "jixel", "lightcraft-color", "lightcraft-geom", "lightcraft-meta", From 2d13d97c6bf0da45d1dfd41fa15b2e15ff46c51f Mon Sep 17 00:00:00 2001 From: "Dylan M. Taylor" <dylan@dylanmtaylor.com> Date: Sun, 15 Nov 2026 00:06:33 +0000 Subject: [PATCH 17/61] fix(codecs): retain large AV1 frame support --- Cargo.lock | 3 ++- Cargo.toml | 2 +- crates/codecs/src/video.rs | 30 ++++++++++++++++++++++++++---- 3 files changed, 29 insertions(+), 6 deletions(-) diff --git a/Cargo.lock b/Cargo.lock index bc4116ce61..c857cd6966 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -1438,9 +1438,10 @@ dependencies = [ [[package]] name = "craft-video" version = "0.1.0" -source = "git+https://github.com/storytold/craft-libs?rev=d6cd7836d364177661b0ae17f48a0805e83a5f32#d6cd7836d364177661b0ae17f48a0805e83a5f32" +source = "git+https://github.com/storytold/craft-libs?rev=045d3865126d3408503c54fea71b08f33262fddf#045d3865126d3408503c54fea71b08f33262fddf" dependencies = [ "craft-media", + "rav1e", "thiserror 2.0.21", ] diff --git a/Cargo.toml b/Cargo.toml index 01239cf5b4..49e4b26bb9 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -21,7 +21,7 @@ jixel = "=0.3.4" # Photo metadata: EXIF, IPTC-IIM, XMP packets and GPX track logs (craft-libs#949) craft-metadata = { git = "https://github.com/storytold/craft-libs", rev = "f0f4758c01581d79577b9bf5046c06f4e77b1f18" } craft-image-codecs = { git = "https://github.com/storytold/craft-libs", rev = "d6cd7836d364177661b0ae17f48a0805e83a5f32" } -craft-video = { git = "https://github.com/storytold/craft-libs", rev = "d6cd7836d364177661b0ae17f48a0805e83a5f32", features = ["av1"] } +craft-video = { git = "https://github.com/storytold/craft-libs", rev = "045d3865126d3408503c54fea71b08f33262fddf", features = ["av1", "av1-large-encode"] } craft-xml = { git = "https://github.com/storytold/craft-libs", rev = "f0f4758c01581d79577b9bf5046c06f4e77b1f18" } # craft-update: app-specific pretend versions apply to startup and manual checks. craft-update = { git = "https://github.com/storytold/craft-libs", version = "=0.1.0", rev = "6e03f65bf45181db77ba6229716e6624db9eb25b", features = ["egui"] } diff --git a/crates/codecs/src/video.rs b/crates/codecs/src/video.rs index 27223d96f3..17459f3417 100644 --- a/crates/codecs/src/video.rs +++ b/crates/codecs/src/video.rs @@ -831,12 +831,18 @@ pub fn quantizer(quality: u8) -> usize { /// the samples as they come out (in order: no frame reordering). pub struct Av1Encoder { #[cfg(all(feature = "avif", not(target_arch = "wasm32")))] - enc: craft_video::av1::Encoder, + enc: Av1Backend, width: usize, height: usize, has_sample: bool, } +#[cfg(all(feature = "avif", not(target_arch = "wasm32")))] +enum Av1Backend { + Single(craft_video::av1::Encoder), + Tiled(craft_video::av1::LargeEncoder), +} + impl Av1Encoder { pub fn new(c: &VideoConfig) -> Result<Self> { let (w, h) = ((c.width & !1) as usize, (c.height & !1) as usize); @@ -850,7 +856,13 @@ impl Av1Encoder { let mut ec = EncoderConfig::new(w as u32, h as u32, c.fps, 1); ec.rate = RateControl::ConstantQ(quantizer(c.quality).clamp(1, 255) as u8); ec.keyint = 120; - let enc = Encoder::new(ec).map_err(|e| bad(format!("AV1: {e}")))?; + let sb_cols = w.div_ceil(64); + let sb_rows = h.div_ceil(64); + let enc = if w > 4096 || h > 4096 || sb_cols * sb_rows > 2304 { + Av1Backend::Tiled(craft_video::av1::LargeEncoder::new(&ec).map_err(|e| bad(format!("AV1: {e}")))?) + } else { + Av1Backend::Single(Encoder::new(ec).map_err(|e| bad(format!("AV1: {e}")))?) + }; Ok(Av1Encoder { enc, width: w, height: h, has_sample: false }) } #[cfg(not(all(feature = "avif", not(target_arch = "wasm32"))))] @@ -869,7 +881,13 @@ impl Av1Encoder { pub fn config_record(&self) -> Option<Vec<u8>> { #[cfg(all(feature = "avif", not(target_arch = "wasm32")))] { - self.has_sample.then(|| self.enc.av1c()) + if !self.has_sample { + return None; + } + match &self.enc { + Av1Backend::Single(enc) => Some(enc.av1c()), + Av1Backend::Tiled(enc) => enc.av1c(), + } } #[cfg(not(all(feature = "avif", not(target_arch = "wasm32"))))] { @@ -889,7 +907,11 @@ impl Av1Encoder { let u16_: Vec<u16> = u.into_iter().map(u16::from).collect(); let v16: Vec<u16> = v.into_iter().map(u16::from).collect(); let frame = craft_video::av1::Frame { y: &y16, u: &u16_, v: &v16, y_stride: self.width, uv_stride: self.width / 2 }; - let pkt = self.enc.encode_with_key(&frame, key).map_err(|e| bad(format!("AV1: {e}")))?; + let pkt = match &mut self.enc { + Av1Backend::Single(enc) => enc.encode_with_key(&frame, key), + Av1Backend::Tiled(enc) => enc.encode_with_key(&frame, key), + } + .map_err(|e| bad(format!("AV1: {e}")))?; self.has_sample = true; Ok(vec![Sample { data: pkt.data, key: pkt.keyframe, duration: periods.max(1) }]) } From 11e31c2521dc8044f61bb8e4578e8943a925e3cb Mon Sep 17 00:00:00 2001 From: "Dylan M. Taylor" <dylan@dylanmtaylor.com> Date: Sun, 15 Nov 2026 00:07:26 +0000 Subject: [PATCH 18/61] fix(codecs): preserve AV1 speed for large frames --- Cargo.lock | 2 +- Cargo.toml | 2 +- crates/codecs/src/video.rs | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/Cargo.lock b/Cargo.lock index c857cd6966..38fbbaa3f2 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -1438,7 +1438,7 @@ dependencies = [ [[package]] name = "craft-video" version = "0.1.0" -source = "git+https://github.com/storytold/craft-libs?rev=045d3865126d3408503c54fea71b08f33262fddf#045d3865126d3408503c54fea71b08f33262fddf" +source = "git+https://github.com/storytold/craft-libs?rev=662e906ef592411f20fa9ff04d218ee1e5f094ad#662e906ef592411f20fa9ff04d218ee1e5f094ad" dependencies = [ "craft-media", "rav1e", diff --git a/Cargo.toml b/Cargo.toml index 49e4b26bb9..d4774a9af7 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -21,7 +21,7 @@ jixel = "=0.3.4" # Photo metadata: EXIF, IPTC-IIM, XMP packets and GPX track logs (craft-libs#949) craft-metadata = { git = "https://github.com/storytold/craft-libs", rev = "f0f4758c01581d79577b9bf5046c06f4e77b1f18" } craft-image-codecs = { git = "https://github.com/storytold/craft-libs", rev = "d6cd7836d364177661b0ae17f48a0805e83a5f32" } -craft-video = { git = "https://github.com/storytold/craft-libs", rev = "045d3865126d3408503c54fea71b08f33262fddf", features = ["av1", "av1-large-encode"] } +craft-video = { git = "https://github.com/storytold/craft-libs", rev = "662e906ef592411f20fa9ff04d218ee1e5f094ad", features = ["av1", "av1-large-encode"] } craft-xml = { git = "https://github.com/storytold/craft-libs", rev = "f0f4758c01581d79577b9bf5046c06f4e77b1f18" } # craft-update: app-specific pretend versions apply to startup and manual checks. craft-update = { git = "https://github.com/storytold/craft-libs", version = "=0.1.0", rev = "6e03f65bf45181db77ba6229716e6624db9eb25b", features = ["egui"] } diff --git a/crates/codecs/src/video.rs b/crates/codecs/src/video.rs index 17459f3417..73681c2749 100644 --- a/crates/codecs/src/video.rs +++ b/crates/codecs/src/video.rs @@ -859,7 +859,7 @@ impl Av1Encoder { let sb_cols = w.div_ceil(64); let sb_rows = h.div_ceil(64); let enc = if w > 4096 || h > 4096 || sb_cols * sb_rows > 2304 { - Av1Backend::Tiled(craft_video::av1::LargeEncoder::new(&ec).map_err(|e| bad(format!("AV1: {e}")))?) + Av1Backend::Tiled(craft_video::av1::LargeEncoder::with_speed(&ec, c.speed).map_err(|e| bad(format!("AV1: {e}")))?) } else { Av1Backend::Single(Encoder::new(ec).map_err(|e| bad(format!("AV1: {e}")))?) }; From ef1808ccb5cb5e10c70effbf404d66f9667126e3 Mon Sep 17 00:00:00 2001 From: "Dylan M. Taylor" <dylan@dylanmtaylor.com> Date: Sun, 15 Nov 2026 00:12:01 +0000 Subject: [PATCH 19/61] fix(deps): pin published craft-video revision --- Cargo.lock | 2 +- Cargo.toml | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/Cargo.lock b/Cargo.lock index 38fbbaa3f2..8bbceae5ba 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -1438,7 +1438,7 @@ dependencies = [ [[package]] name = "craft-video" version = "0.1.0" -source = "git+https://github.com/storytold/craft-libs?rev=662e906ef592411f20fa9ff04d218ee1e5f094ad#662e906ef592411f20fa9ff04d218ee1e5f094ad" +source = "git+https://github.com/storytold/craft-libs?rev=662e906ef928655031c1f021a01da4979f6a3a35#662e906ef928655031c1f021a01da4979f6a3a35" dependencies = [ "craft-media", "rav1e", diff --git a/Cargo.toml b/Cargo.toml index d4774a9af7..2700be9cfc 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -21,7 +21,7 @@ jixel = "=0.3.4" # Photo metadata: EXIF, IPTC-IIM, XMP packets and GPX track logs (craft-libs#949) craft-metadata = { git = "https://github.com/storytold/craft-libs", rev = "f0f4758c01581d79577b9bf5046c06f4e77b1f18" } craft-image-codecs = { git = "https://github.com/storytold/craft-libs", rev = "d6cd7836d364177661b0ae17f48a0805e83a5f32" } -craft-video = { git = "https://github.com/storytold/craft-libs", rev = "662e906ef592411f20fa9ff04d218ee1e5f094ad", features = ["av1", "av1-large-encode"] } +craft-video = { git = "https://github.com/storytold/craft-libs", rev = "662e906ef928655031c1f021a01da4979f6a3a35", features = ["av1", "av1-large-encode"] } craft-xml = { git = "https://github.com/storytold/craft-libs", rev = "f0f4758c01581d79577b9bf5046c06f4e77b1f18" } # craft-update: app-specific pretend versions apply to startup and manual checks. craft-update = { git = "https://github.com/storytold/craft-libs", version = "=0.1.0", rev = "6e03f65bf45181db77ba6229716e6624db9eb25b", features = ["egui"] } From d264e6f05e1f8af12336c044df879e9f700f398e Mon Sep 17 00:00:00 2001 From: "Dylan M. Taylor" <dylan@dylanmtaylor.com> Date: Sun, 15 Nov 2026 00:14:13 +0000 Subject: [PATCH 20/61] fix(deps): sync craft-video media lock revision --- Cargo.lock | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Cargo.lock b/Cargo.lock index 8bbceae5ba..f6f847165c 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -1311,7 +1311,7 @@ dependencies = [ [[package]] name = "craft-media" version = "0.1.0" -source = "git+https://github.com/storytold/craft-libs?rev=d6cd7836d364177661b0ae17f48a0805e83a5f32#d6cd7836d364177661b0ae17f48a0805e83a5f32" +source = "git+https://github.com/storytold/craft-libs?rev=662e906ef928655031c1f021a01da4979f6a3a35#662e906ef928655031c1f021a01da4979f6a3a35" dependencies = [ "thiserror 2.0.21", ] From c0d3596e27b1e8e5f13ddd9f3954e0083b5c3a8e Mon Sep 17 00:00:00 2001 From: "Dylan M. Taylor" <dylan@dylanmtaylor.com> Date: Sun, 15 Nov 2026 00:15:22 +0000 Subject: [PATCH 21/61] chore(codecs): drop obsolete AV1 speed binding --- crates/codecs/src/video.rs | 1 - 1 file changed, 1 deletion(-) diff --git a/crates/codecs/src/video.rs b/crates/codecs/src/video.rs index 73681c2749..f1db073b8a 100644 --- a/crates/codecs/src/video.rs +++ b/crates/codecs/src/video.rs @@ -852,7 +852,6 @@ impl Av1Encoder { #[cfg(all(feature = "avif", not(target_arch = "wasm32")))] { use craft_video::av1::{Encoder, EncoderConfig, RateControl}; - let _ = c.speed; let mut ec = EncoderConfig::new(w as u32, h as u32, c.fps, 1); ec.rate = RateControl::ConstantQ(quantizer(c.quality).clamp(1, 255) as u8); ec.keyint = 120; From f8edf825851466585e3a38bee803c5284c92c74a Mon Sep 17 00:00:00 2001 From: "Dylan M. Taylor" <dylan@dylanmtaylor.com> Date: Sun, 15 Nov 2026 00:20:50 +0000 Subject: [PATCH 22/61] fix: box large AV1 encoder backend --- crates/codecs/src/video.rs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/crates/codecs/src/video.rs b/crates/codecs/src/video.rs index f1db073b8a..ab5b0c0e47 100644 --- a/crates/codecs/src/video.rs +++ b/crates/codecs/src/video.rs @@ -840,7 +840,7 @@ pub struct Av1Encoder { #[cfg(all(feature = "avif", not(target_arch = "wasm32")))] enum Av1Backend { Single(craft_video::av1::Encoder), - Tiled(craft_video::av1::LargeEncoder), + Tiled(Box<craft_video::av1::LargeEncoder>), } impl Av1Encoder { @@ -858,7 +858,7 @@ impl Av1Encoder { let sb_cols = w.div_ceil(64); let sb_rows = h.div_ceil(64); let enc = if w > 4096 || h > 4096 || sb_cols * sb_rows > 2304 { - Av1Backend::Tiled(craft_video::av1::LargeEncoder::with_speed(&ec, c.speed).map_err(|e| bad(format!("AV1: {e}")))?) + Av1Backend::Tiled(Box::new(craft_video::av1::LargeEncoder::with_speed(&ec, c.speed).map_err(|e| bad(format!("AV1: {e}")))?)) } else { Av1Backend::Single(Encoder::new(ec).map_err(|e| bad(format!("AV1: {e}")))?) }; From 7197597e13fb3cee9c65d87fd31bfeafd8c9d430 Mon Sep 17 00:00:00 2001 From: "Dylan M. Taylor" <dylan@dylanmtaylor.com> Date: Sun, 15 Nov 2026 00:25:09 +0000 Subject: [PATCH 23/61] fix: box single AV1 encoder backend --- crates/codecs/src/video.rs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/crates/codecs/src/video.rs b/crates/codecs/src/video.rs index ab5b0c0e47..1dade788a5 100644 --- a/crates/codecs/src/video.rs +++ b/crates/codecs/src/video.rs @@ -839,7 +839,7 @@ pub struct Av1Encoder { #[cfg(all(feature = "avif", not(target_arch = "wasm32")))] enum Av1Backend { - Single(craft_video::av1::Encoder), + Single(Box<craft_video::av1::Encoder>), Tiled(Box<craft_video::av1::LargeEncoder>), } @@ -860,7 +860,7 @@ impl Av1Encoder { let enc = if w > 4096 || h > 4096 || sb_cols * sb_rows > 2304 { Av1Backend::Tiled(Box::new(craft_video::av1::LargeEncoder::with_speed(&ec, c.speed).map_err(|e| bad(format!("AV1: {e}")))?)) } else { - Av1Backend::Single(Encoder::new(ec).map_err(|e| bad(format!("AV1: {e}")))?) + Av1Backend::Single(Box::new(Encoder::new(ec).map_err(|e| bad(format!("AV1: {e}")))?)) }; Ok(Av1Encoder { enc, width: w, height: h, has_sample: false }) } From b757d74a31c2b7d11107f62fc9c8fc3add2959d6 Mon Sep 17 00:00:00 2001 From: "Dylan M. Taylor" <dylan@dylanmtaylor.com> Date: Sun, 15 Nov 2026 01:36:18 +0000 Subject: [PATCH 24/61] test(raw): keep DNG JXL tile fixtures single-layer --- crates/raw/tests/it/dng.rs | 26 +++++++++++++++++++++++++- 1 file changed, 25 insertions(+), 1 deletion(-) diff --git a/crates/raw/tests/it/dng.rs b/crates/raw/tests/it/dng.rs index 08020fb4da..0f317af3b3 100644 --- a/crates/raw/tests/it/dng.rs +++ b/crates/raw/tests/it/dng.rs @@ -650,6 +650,30 @@ fn jxl_encode(px: &[u16], w: usize, h: usize, cpp: usize, eight: bool) -> Vec<u8 craft_jxl::encode(&img, opts, &craft_jxl::Metadata::default()).unwrap() } +/// The encoder may return an ISO-BMFF container for a level-10 codestream. Extract its `jxlc` +/// payload so the tile fixture can deliberately exercise the bare-codestream form too. +fn bare_jxl_codestream(bytes: &[u8]) -> Vec<u8> { + const SIGNATURE: &[u8] = &[0, 0, 0, 0x0c, b'J', b'X', b'L', b' ', 0x0d, 0x0a, 0x87, 0x0a]; + if !bytes.starts_with(SIGNATURE) { + return bytes.to_vec(); + } + let mut at = SIGNATURE.len(); + while let Some(end_header) = at.checked_add(8) { + let Some(header) = bytes.get(at..end_header) else { break }; + let size = u32::from_be_bytes([header[0], header[1], header[2], header[3]]) as usize; + if size < 8 { + break; + } + let Some(end) = at.checked_add(size) else { break }; + let Some(box_bytes) = bytes.get(at..end) else { break }; + if &header[4..8] == b"jxlc" { + return box_bytes[8..].to_vec(); + } + at = end; + } + panic!("the JPEG XL encoder returned a container without a complete jxlc box"); +} + /// A bare codestream wrapped in the ISO-BMFF container (signature, `ftyp`, `jxlc`). fn jxl_container(cs: &[u8]) -> Vec<u8> { let mut b = vec![0, 0, 0, 0x0c, b'J', b'X', b'L', b' ', 0x0d, 0x0a, 0x87, 0x0a, 0, 0, 0, 0x14]; @@ -679,7 +703,7 @@ fn jxl_tiled(px: &[u16], w: usize, h: usize, cpp: usize, bits: u16, cfa: bool, t } } } - let cs = jxl_encode(&t, cw, ch, cpp, bits == 8); + let cs = bare_jxl_codestream(&jxl_encode(&t, cw, ch, cpp, bits == 8)); tiles.push(if i % 3 == 1 { jxl_container(&cs) } else { cs }); } } From 3dfb134574dd71da88e5b759968335c2bf6b954d Mon Sep 17 00:00:00 2001 From: "Dylan M. Taylor" <dylan@dylanmtaylor.com> Date: Sun, 15 Nov 2026 02:46:50 +0000 Subject: [PATCH 25/61] fix(codecs): keep AVIF fallback wasm compatible --- crates/codecs/src/encode.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/crates/codecs/src/encode.rs b/crates/codecs/src/encode.rs index bd15315ed3..ab7c6fd2e7 100644 --- a/crates/codecs/src/encode.rs +++ b/crates/codecs/src/encode.rs @@ -343,7 +343,7 @@ pub fn encode_avif(img: &EncodeImage, quality: u8, speed: u8, meta: &EncodeMeta) } #[cfg(not(all(feature = "avif", not(target_arch = "wasm32"))))] { - let _ = (quality, speed, meta, img.has_alpha()); + let _ = (quality, speed, meta); Err(Error::Encode("AVIF encoding is not available in this build".into())) } } From 55f922bdd0c58a2c39f16c8f71793dd3014786dd Mon Sep 17 00:00:00 2001 From: Madhav Agarwal <connectmadhav09@gmail.com> Date: Sun, 15 Nov 2026 09:04:27 +0530 Subject: [PATCH 26/61] docs: bring ROADMAP.md current through 2026-11-15 --- ROADMAP.md | 3 ++- docs/target-app-parity.md | 3 ++- 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/ROADMAP.md b/ROADMAP.md index ee50aed31b..8531c1d1de 100644 --- a/ROADMAP.md +++ b/ROADMAP.md @@ -2,7 +2,7 @@ **Stage: alpha** · next: beta, ~14 points and ~340–600 h away -> **Last reviewed:** 2026-10-10 · **Target:** Adobe Lightroom Classic 15.5 / Lightroom 9.6 · **Changes:** [revision history](#revision-history) +> **Last reviewed:** 2026-11-15 · **Target:** Adobe Lightroom Classic 15.5 / Lightroom 9.6 · **Changes:** [revision history](#revision-history) One-page summary of how close LightCraft is to Adobe Lightroom. Agents: read this, then pick work from [docs/gaps.md](docs/gaps.md). The full assessment, method and evidence are in @@ -199,6 +199,7 @@ Ranked toward beta; detail in [docs/roadmap.md](docs/roadmap.md), gaps in [docs/ | Date | Change | Summary | |---|---|---| +| 2026-11-15 | minor | Lens Blur with AI subject focus and per-mask bokeh; survey tiles fit the photos' shapes and glide to their new places; direct import of Lightroom backup zips (#2592); legacy shutter repair in virtual copies; the opened-library folder-safety fix; v0.21.0 and v0.21.1 released; craft-libs cutover for TIFF/JPEG/JXL/GIF/PSD/HEIF/raw, metadata and gain maps, plus a security-hardening batch; headline numbers not re-measured | | 2026-10-24 | minor | Priority 7 (lens profile database) links its tracking issue #329; headline numbers unchanged | | 2026-10-24 | patch | Alpha rationale: tests run in CI on Linux x64 (#2667) and FreeBSD nightly, not on macOS or Windows; ranked item 8 now reads "Tests in CI on macOS and Windows, and the GPU tests in CI"; percentages and hours unchanged | | 2026-10-22 | minor | Print: Japanese photo and postcard paper sizes (L判, 2L判, KG判, はがき, 往復はがき, 六切, 四切, 名刺) in the page setup, Print dialog and PDF output; headline numbers unchanged | diff --git a/docs/target-app-parity.md b/docs/target-app-parity.md index e3e8a26665..8198a54bd9 100644 --- a/docs/target-app-parity.md +++ b/docs/target-app-parity.md @@ -1,6 +1,6 @@ # Target-app parity: LightCraft vs Adobe Lightroom -> **Last reviewed:** 2026-10-10 · **Target:** Adobe Lightroom Classic 15.5 (August 2026) and Lightroom 9.6 (desktop) · **Changes:** [revision history](#revision-history) +> **Last reviewed:** 2026-11-15 · **Target:** Adobe Lightroom Classic 15.5 (August 2026) and Lightroom 9.6 (desktop) · **Changes:** [revision history](#revision-history) The authoritative assessment of how close LightCraft is to Lightroom. The row-by-row checklist is [parity-checklist.md](parity-checklist.md); the ranked work list is [gaps.md](gaps.md); deep areas @@ -299,6 +299,7 @@ P2 items 12–25 h; look tuning, performance, packaging, hardening 25–45 h. | Date | Change | Summary | |---|---|---| +| 2026-11-15 | minor | Lens Blur renders with AI subject focus and per-mask bokeh (the AI table's 🟡 and the missing depth map are unchanged); survey layout, opened-library folder safety, direct Lightroom backup-zip import, legacy shutter repair and the Highlights/Shadows block fix landed; craft-libs cutover (TIFF/JPEG/JXL/GIF/PSD/HEIF/raw, metadata, gain maps); v0.21.0 and v0.21.1 released. Headline numbers, coverage and estimates were not re-measured. | | 2026-11-07 | correction | Compressed ORF sensor support withdrawn pending provenance review; embedded preview fallback remains. Coverage regenerated without the removed decoder: 557 verified, 665 unverified, 187 preview-only, 37 unsupported; 94% use-weighted coverage. | | 2026-11-05 | minor | AI table: Lens Blur ⬜ → 🟡 (subject- or mask-focused disc blur, no depth map); headline numbers unchanged | | 2026-11-04 | minor | Compressed ORF support was introduced in #3775; subsequently withdrawn pending provenance review. Earlier clean-room and verification claims are withdrawn; compressed files use embedded previews when available. See [ORF status](orf-compression.md). | From 34411fecb91cd03335b6b78b61740a5d5fb0da40 Mon Sep 17 00:00:00 2001 From: "Dylan M. Taylor" <dylan@dylanmtaylor.com> Date: Sun, 15 Nov 2026 11:30:02 +0000 Subject: [PATCH 27/61] Preserve buffered AV1 frames and durations --- crates/codecs/src/video.rs | 112 ++++++++++++++++++++++++++----------- 1 file changed, 78 insertions(+), 34 deletions(-) diff --git a/crates/codecs/src/video.rs b/crates/codecs/src/video.rs index 1dade788a5..6a8e3c6f8a 100644 --- a/crates/codecs/src/video.rs +++ b/crates/codecs/src/video.rs @@ -831,16 +831,15 @@ pub fn quantizer(quality: u8) -> usize { /// the samples as they come out (in order: no frame reordering). pub struct Av1Encoder { #[cfg(all(feature = "avif", not(target_arch = "wasm32")))] - enc: Av1Backend, + enc: craft_video::av1::LargeEncoder, + #[cfg(all(feature = "avif", not(target_arch = "wasm32")))] + durations: Vec<u64>, + #[cfg(all(feature = "avif", not(target_arch = "wasm32")))] + returned: usize, + #[cfg(all(feature = "avif", not(target_arch = "wasm32")))] + failed: bool, width: usize, height: usize, - has_sample: bool, -} - -#[cfg(all(feature = "avif", not(target_arch = "wasm32")))] -enum Av1Backend { - Single(Box<craft_video::av1::Encoder>), - Tiled(Box<craft_video::av1::LargeEncoder>), } impl Av1Encoder { @@ -851,18 +850,12 @@ impl Av1Encoder { } #[cfg(all(feature = "avif", not(target_arch = "wasm32")))] { - use craft_video::av1::{Encoder, EncoderConfig, RateControl}; + use craft_video::av1::{EncoderConfig, RateControl}; let mut ec = EncoderConfig::new(w as u32, h as u32, c.fps, 1); ec.rate = RateControl::ConstantQ(quantizer(c.quality).clamp(1, 255) as u8); ec.keyint = 120; - let sb_cols = w.div_ceil(64); - let sb_rows = h.div_ceil(64); - let enc = if w > 4096 || h > 4096 || sb_cols * sb_rows > 2304 { - Av1Backend::Tiled(Box::new(craft_video::av1::LargeEncoder::with_speed(&ec, c.speed).map_err(|e| bad(format!("AV1: {e}")))?)) - } else { - Av1Backend::Single(Box::new(Encoder::new(ec).map_err(|e| bad(format!("AV1: {e}")))?)) - }; - Ok(Av1Encoder { enc, width: w, height: h, has_sample: false }) + let enc = craft_video::av1::LargeEncoder::with_speed(&ec, c.speed).map_err(|e| bad(format!("AV1: {e}")))?; + Ok(Av1Encoder { enc, durations: Vec::new(), returned: 0, failed: false, width: w, height: h }) } #[cfg(not(all(feature = "avif", not(target_arch = "wasm32"))))] { @@ -880,17 +873,10 @@ impl Av1Encoder { pub fn config_record(&self) -> Option<Vec<u8>> { #[cfg(all(feature = "avif", not(target_arch = "wasm32")))] { - if !self.has_sample { - return None; - } - match &self.enc { - Av1Backend::Single(enc) => Some(enc.av1c()), - Av1Backend::Tiled(enc) => enc.av1c(), - } + self.enc.av1c() } #[cfg(not(all(feature = "avif", not(target_arch = "wasm32"))))] { - let _ = self.has_sample; None } } @@ -902,17 +888,19 @@ impl Av1Encoder { let (y, u, v) = yuv420(rgba, self.width, self.height)?; #[cfg(all(feature = "avif", not(target_arch = "wasm32")))] { + if self.failed { + return Err(bad("AV1 encoder failed earlier")); + } let y16: Vec<u16> = y.into_iter().map(u16::from).collect(); let u16_: Vec<u16> = u.into_iter().map(u16::from).collect(); let v16: Vec<u16> = v.into_iter().map(u16::from).collect(); let frame = craft_video::av1::Frame { y: &y16, u: &u16_, v: &v16, y_stride: self.width, uv_stride: self.width / 2 }; - let pkt = match &mut self.enc { - Av1Backend::Single(enc) => enc.encode_with_key(&frame, key), - Av1Backend::Tiled(enc) => enc.encode_with_key(&frame, key), - } - .map_err(|e| bad(format!("AV1: {e}")))?; - self.has_sample = true; - Ok(vec![Sample { data: pkt.data, key: pkt.keyframe, duration: periods.max(1) }]) + self.durations.push(periods.max(1)); + let packets = self.enc.push(&frame, key).map_err(|e| { + self.failed = true; + bad(format!("AV1: {e}")) + })?; + self.samples(packets) } #[cfg(not(all(feature = "avif", not(target_arch = "wasm32"))))] { @@ -925,11 +913,39 @@ impl Av1Encoder { pub fn finish(&mut self) -> Result<Vec<Sample>> { #[cfg(all(feature = "avif", not(target_arch = "wasm32")))] { - Ok(Vec::new()) + if self.failed { + return Err(bad("AV1 encoder failed earlier")); + } + let packets = self.enc.finish().map_err(|e| { + self.failed = true; + bad(format!("AV1: {e}")) + })?; + let samples = self.samples(packets)?; + if self.returned != self.durations.len() { + self.failed = true; + return Err(bad("AV1 encoder did not return every input frame")); + } + Ok(samples) } #[cfg(not(all(feature = "avif", not(target_arch = "wasm32"))))] Err(bad("AV1 video encoding is not available in this build")) } + + #[cfg(all(feature = "avif", not(target_arch = "wasm32")))] + fn samples(&mut self, packets: Vec<craft_video::av1::BufferedPacket>) -> Result<Vec<Sample>> { + let mut samples = Vec::with_capacity(packets.len()); + for packet in packets { + let index = usize::try_from(packet.input_frame_number).ok(); + let duration = index.filter(|&i| i == self.returned).and_then(|i| self.durations.get(i)).copied(); + let Some(duration) = duration else { + self.failed = true; + return Err(bad("AV1 encoder returned an unknown or out-of-order frame")); + }; + self.returned += 1; + samples.push(Sample { data: packet.packet.data, key: packet.packet.keyframe, duration }); + } + Ok(samples) + } } #[cfg(test)] @@ -1122,7 +1138,8 @@ mod tests { out.extend(e.finish().unwrap()); assert_eq!(out.len(), 4, "one sample per frame sent"); assert!(out[0].key); - assert_eq!(out.iter().map(|s| s.duration).sum::<u64>(), 56); + assert!(out[3].key, "requested key frame"); + assert_eq!(out.iter().map(|s| s.duration).collect::<Vec<_>>(), [24, 1, 1, 30]); for s in &out { assert!(obus(&s.data).unwrap().iter().all(|(k, _)| *k != OBU_TEMPORAL_DELIMITER)); } @@ -1136,4 +1153,31 @@ mod tests { let d = m.finish().unwrap().into_inner(); assert_eq!(boxes(&d, 0..d.len()).len(), 3); } + + #[cfg(all(feature = "avif", not(target_arch = "wasm32")))] + #[test] + fn av1_buffers_a_large_frame_and_preserves_its_duration() { + let c = VideoConfig { width: 4112, height: 16, fps: 30, quality: 60, speed: 10 }; + let mut encoder = Av1Encoder::new(&c).unwrap(); + let mut samples = encoder.push(&vec![[80, 120, 180, 255]; 4112 * 16], 7, true).unwrap(); + samples.extend(encoder.finish().unwrap()); + assert_eq!(samples.len(), 1); + assert_eq!(samples[0].duration, 7); + assert!(samples[0].key); + assert!(encoder.config_record().is_some()); + } + + #[cfg(all(feature = "avif", not(target_arch = "wasm32")))] + #[test] + fn av1_speed_affects_normal_sized_frames() { + let image: Vec<[u8; 4]> = (0..64 * 48).map(|i| [(i * 13) as u8, (i * 41) as u8, (i * 73) as u8, 255]).collect(); + let encode = |speed| { + let c = VideoConfig { width: 64, height: 48, fps: 24, quality: 60, speed }; + let mut encoder = Av1Encoder::new(&c).unwrap(); + let mut samples = encoder.push(&image, 1, true).unwrap(); + samples.extend(encoder.finish().unwrap()); + samples.remove(0).data + }; + assert_ne!(encode(1), encode(10), "AV1 speed must reach the shared encoder"); + } } From cc2b38145dbc70a7028637d203c58f46a97b917e Mon Sep 17 00:00:00 2001 From: FredApps <153173854+FredApps@users.noreply.github.com> Date: Sun, 15 Nov 2026 15:29:09 +0100 Subject: [PATCH 28/61] codecs: keep EXIF, alpha quality and HLG levels in AVIF exports The craft-image-codecs revision this cutover pinned dropped EXIF from SDR AVIF (the ravif path wrote it), ignored the alpha quality, and mapped HLG with a plain OETF that put SDR white at 0.5 instead of BT.2408's 0.75. Pin the merge of craft-libs#1448, which fixes all three, and test that 8- and 16-bit AVIF exports keep their EXIF. --- Cargo.lock | 13 +++++++------ Cargo.toml | 3 ++- crates/codecs/tests/it/roundtrip.rs | 18 ++++++++++++++++++ 3 files changed, 27 insertions(+), 7 deletions(-) diff --git a/Cargo.lock b/Cargo.lock index f6f847165c..f1724eec04 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -1266,11 +1266,12 @@ dependencies = [ [[package]] name = "craft-image-codecs" version = "0.1.0" -source = "git+https://github.com/storytold/craft-libs?rev=d6cd7836d364177661b0ae17f48a0805e83a5f32#d6cd7836d364177661b0ae17f48a0805e83a5f32" +source = "git+https://github.com/storytold/craft-libs?rev=478c50560d3c6fad3d613af2a30b35c3bc9f4c0f#478c50560d3c6fad3d613af2a30b35c3bc9f4c0f" dependencies = [ "avif-serialize", "craft-jpeg", - "craft-metadata 0.1.0 (git+https://github.com/storytold/craft-libs?rev=d6cd7836d364177661b0ae17f48a0805e83a5f32)", + "craft-metadata 0.1.0 (git+https://github.com/storytold/craft-libs?rev=478c50560d3c6fad3d613af2a30b35c3bc9f4c0f)", + "crc32fast", "exr", "flate2", "half", @@ -1293,7 +1294,7 @@ dependencies = [ [[package]] name = "craft-jpeg" version = "0.1.0" -source = "git+https://github.com/storytold/craft-libs?rev=d6cd7836d364177661b0ae17f48a0805e83a5f32#d6cd7836d364177661b0ae17f48a0805e83a5f32" +source = "git+https://github.com/storytold/craft-libs?rev=478c50560d3c6fad3d613af2a30b35c3bc9f4c0f#478c50560d3c6fad3d613af2a30b35c3bc9f4c0f" dependencies = [ "thiserror 2.0.21", ] @@ -1319,11 +1320,11 @@ dependencies = [ [[package]] name = "craft-metadata" version = "0.1.0" -source = "git+https://github.com/storytold/craft-libs?rev=d6cd7836d364177661b0ae17f48a0805e83a5f32#d6cd7836d364177661b0ae17f48a0805e83a5f32" +source = "git+https://github.com/storytold/craft-libs?rev=478c50560d3c6fad3d613af2a30b35c3bc9f4c0f#478c50560d3c6fad3d613af2a30b35c3bc9f4c0f" dependencies = [ "brotli-decompressor 6.0.1", "chrono", - "craft-tiff 0.1.0 (git+https://github.com/storytold/craft-libs?rev=d6cd7836d364177661b0ae17f48a0805e83a5f32)", + "craft-tiff 0.1.0 (git+https://github.com/storytold/craft-libs?rev=478c50560d3c6fad3d613af2a30b35c3bc9f4c0f)", "quick-xml 0.41.0", "serde", ] @@ -1372,7 +1373,7 @@ dependencies = [ [[package]] name = "craft-tiff" version = "0.1.0" -source = "git+https://github.com/storytold/craft-libs?rev=d6cd7836d364177661b0ae17f48a0805e83a5f32#d6cd7836d364177661b0ae17f48a0805e83a5f32" +source = "git+https://github.com/storytold/craft-libs?rev=478c50560d3c6fad3d613af2a30b35c3bc9f4c0f#478c50560d3c6fad3d613af2a30b35c3bc9f4c0f" dependencies = [ "serde", "thiserror 2.0.21", diff --git a/Cargo.toml b/Cargo.toml index 2700be9cfc..9b0e42b8ea 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -20,7 +20,8 @@ craft-jxl = { git = "https://github.com/storytold/craft-libs", rev = "d6cd7836d3 jixel = "=0.3.4" # Photo metadata: EXIF, IPTC-IIM, XMP packets and GPX track logs (craft-libs#949) craft-metadata = { git = "https://github.com/storytold/craft-libs", rev = "f0f4758c01581d79577b9bf5046c06f4e77b1f18" } -craft-image-codecs = { git = "https://github.com/storytold/craft-libs", rev = "d6cd7836d364177661b0ae17f48a0805e83a5f32" } +# AVIF EXIF, alpha quality and BT.2408 HLG levels (craft-libs#1448). +craft-image-codecs = { git = "https://github.com/storytold/craft-libs", rev = "478c50560d3c6fad3d613af2a30b35c3bc9f4c0f" } craft-video = { git = "https://github.com/storytold/craft-libs", rev = "662e906ef928655031c1f021a01da4979f6a3a35", features = ["av1", "av1-large-encode"] } craft-xml = { git = "https://github.com/storytold/craft-libs", rev = "f0f4758c01581d79577b9bf5046c06f4e77b1f18" } # craft-update: app-specific pretend versions apply to startup and manual checks. diff --git a/crates/codecs/tests/it/roundtrip.rs b/crates/codecs/tests/it/roundtrip.rs index cb4c58bdcd..f841a07d77 100644 --- a/crates/codecs/tests/it/roundtrip.rs +++ b/crates/codecs/tests/it/roundtrip.rs @@ -617,6 +617,24 @@ fn avif_encode_native() { } } +#[test] +fn avif_keeps_exif() { + // The ravif path wrote EXIF; the shared encoder must keep it, for 8- and 16-bit input. + let img = smooth(16, 12); + let exif = minimal_exif(3); + let meta = EncodeMeta { exif: Some(&exif), ..Default::default() }; + let wide: Vec<u16> = img.data.iter().flat_map(|p| p.map(|c| u16::from(c) * 257)).collect(); + for image in [EncodeImage::rgba8(&img), EncodeImage::new(16, 12, 4, Samples::U16(&wide))] { + let r = encode_avif(&image, 70, 10, &meta); + if cfg!(feature = "avif") { + let b = r.unwrap(); + assert!(b.windows(exif.len()).any(|w| w == &exif[..]), "EXIF missing from the AVIF"); + } else { + assert!(r.is_err()); + } + } +} + #[test] fn raw_routing() { let mut b = b"II*\0\x08\0\0\0".to_vec(); From e785d9ccb5c1de48fd1005b0e480bde8546335fd Mon Sep 17 00:00:00 2001 From: FredApps <153173854+FredApps@users.noreply.github.com> Date: Sun, 15 Nov 2026 15:37:02 +0100 Subject: [PATCH 29/61] codecs: share the craft-image-codecs image conversion of the PNG, TIFF and AVIF writers The AVIF cutover added a third copy of the channel-layout and sample match (Sonar: 8.8% duplication on new code). One helper builds the image; each writer keeps its own float refusal message. --- crates/codecs/src/encode.rs | 51 +++++++++++++------------------------ 1 file changed, 17 insertions(+), 34 deletions(-) diff --git a/crates/codecs/src/encode.rs b/crates/codecs/src/encode.rs index ab7c6fd2e7..666a63e7be 100644 --- a/crates/codecs/src/encode.rs +++ b/crates/codecs/src/encode.rs @@ -174,9 +174,9 @@ pub fn encode_jpeg(img: &EncodeImage, quality: u8, subsampling: ChromaSubsamplin Ok(out) } -/// Encode PNG (8- or 16-bit; float input is rejected — quantize first). -pub fn encode_png(img: &EncodeImage, meta: &EncodeMeta) -> Result<Vec<u8>> { - img.validate()?; +/// `img` (already validated) as a `craft-image-codecs` image. `refuse_float` is the error for +/// 32-bit float samples, for a format that cannot hold them; `None` converts them too. +fn shared_image(img: &EncodeImage, refuse_float: Option<&str>) -> Result<craft_image_codecs::Image> { let n = img.width as usize * img.height as usize * img.channels as usize; let layout = match img.channels { 1 => craft_image_codecs::ChannelLayout::Gray, @@ -184,12 +184,19 @@ pub fn encode_png(img: &EncodeImage, meta: &EncodeMeta) -> Result<Vec<u8>> { 3 => craft_image_codecs::ChannelLayout::Rgb, _ => craft_image_codecs::ChannelLayout::Rgba, }; - let mut ic_img = match img.samples { - Samples::U8(s) => craft_image_codecs::Image::from_u8(img.width, img.height, layout, s[..n].to_vec()), - Samples::U16(s) => craft_image_codecs::Image::from_u16(img.width, img.height, layout, &s[..n]), - Samples::F32(_) => return Err(Error::Encode("PNG needs 8- or 16-bit samples".into())), + match (img.samples, refuse_float) { + (Samples::U8(s), _) => craft_image_codecs::Image::from_u8(img.width, img.height, layout, s[..n].to_vec()), + (Samples::U16(s), _) => craft_image_codecs::Image::from_u16(img.width, img.height, layout, &s[..n]), + (Samples::F32(_), Some(refusal)) => return Err(Error::Encode(refusal.into())), + (Samples::F32(s), None) => craft_image_codecs::Image::from_f32(img.width, img.height, layout, &s[..n]), } - .map_err(|e| Error::Encode(e.to_string()))?; + .map_err(|e| Error::Encode(e.to_string())) +} + +/// Encode PNG (8- or 16-bit; float input is rejected — quantize first). +pub fn encode_png(img: &EncodeImage, meta: &EncodeMeta) -> Result<Vec<u8>> { + img.validate()?; + let mut ic_img = shared_image(img, Some("PNG needs 8- or 16-bit samples"))?; ic_img.icc = meta.icc.map(|b| b.to_vec()); ic_img.meta.exif = meta.exif.map(|b| b.to_vec()); ic_img.meta.xmp = meta.xmp.map(|x| x.to_string()); @@ -234,19 +241,7 @@ pub enum TiffCompression { /// ICC and XMP are embedded; EXIF is not (write it through the TIFF writer in `craft-tiff`). pub fn encode_tiff(img: &EncodeImage, compression: TiffCompression, meta: &EncodeMeta) -> Result<Vec<u8>> { img.validate()?; - let n = img.width as usize * img.height as usize * img.channels as usize; - let layout = match img.channels { - 1 => craft_image_codecs::ChannelLayout::Gray, - 2 => craft_image_codecs::ChannelLayout::GrayA, - 3 => craft_image_codecs::ChannelLayout::Rgb, - _ => craft_image_codecs::ChannelLayout::Rgba, - }; - let mut ic_img = match img.samples { - Samples::U8(s) => craft_image_codecs::Image::from_u8(img.width, img.height, layout, s[..n].to_vec()), - Samples::U16(s) => craft_image_codecs::Image::from_u16(img.width, img.height, layout, &s[..n]), - Samples::F32(s) => craft_image_codecs::Image::from_f32(img.width, img.height, layout, &s[..n]), - } - .map_err(|e| Error::Encode(e.to_string()))?; + let mut ic_img = shared_image(img, None)?; ic_img.icc = meta.icc.map(|b| b.to_vec()); ic_img.meta.xmp = meta.xmp.map(|x| x.to_string()); ic_img.meta.dpi = meta.ppi.filter(|p| *p > 0).map(|p| (p as f32, p as f32)); @@ -325,19 +320,7 @@ pub fn encode_avif(img: &EncodeImage, quality: u8, speed: u8, meta: &EncodeMeta) img.validate()?; #[cfg(all(feature = "avif", not(target_arch = "wasm32")))] { - let n = img.width as usize * img.height as usize * img.channels as usize; - let layout = match img.channels { - 1 => craft_image_codecs::ChannelLayout::Gray, - 2 => craft_image_codecs::ChannelLayout::GrayA, - 3 => craft_image_codecs::ChannelLayout::Rgb, - _ => craft_image_codecs::ChannelLayout::Rgba, - }; - let mut ic_img = match img.samples { - Samples::U8(s) => craft_image_codecs::Image::from_u8(img.width, img.height, layout, s[..n].to_vec()), - Samples::U16(s) => craft_image_codecs::Image::from_u16(img.width, img.height, layout, &s[..n]), - Samples::F32(_) => return Err(Error::Encode("AVIF encoder needs 8- or 16-bit samples".into())), - } - .map_err(|e| Error::Encode(e.to_string()))?; + let mut ic_img = shared_image(img, Some("AVIF encoder needs 8- or 16-bit samples"))?; ic_img.meta.exif = meta.exif.map(|e| e.to_vec()); craft_image_codecs::encode_avif_with_speed(&ic_img, quality, speed).map_err(|e| Error::Encode(e.to_string())) } From a46cedee9b8601220485e95c732f4c0a650d2a45 Mon Sep 17 00:00:00 2001 From: "Dylan M. Taylor" <dylan@dylanmtaylor.com> Date: Sun, 15 Nov 2026 15:21:18 +0000 Subject: [PATCH 30/61] Include JPEG encoder redistribution notices --- NOTICE | 130 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 130 insertions(+) diff --git a/NOTICE b/NOTICE index 39eb49db2c..73c2e2f6f2 100644 --- a/NOTICE +++ b/NOTICE @@ -335,3 +335,133 @@ Permission is hereby granted, free of charge, to any person obtaining a copy of The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software. THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. + +JPEG encoding +------------- + +The shared JPEG writer includes the following third-party encoder notice. The Apache-2.0 +alternative referred to below is also included in this distribution as LICENSE-APACHE. + +JPEG encoding dependency: jpeg-encoder 0.6.1 + +Source: https://crates.io/crates/jpeg-encoder/0.6.1 +Declared license: (MIT OR Apache-2.0) AND IJG. +This software is based in part on the work of the Independent JPEG Group. + +The MIT license and unaltered upstream IJG and SIMD notices follow. The Apache-2.0 +alternative is also retained in licenses/jpeg-encoder-0.6.1 at the repository root +(https://github.com/storytold/craft-libs/tree/main/licenses/jpeg-encoder-0.6.1). +The dependency is used unmodified; no encoder implementation is vendored here. + +LICENSE-MIT + +Copyright (c) 2021 Volker Ströbel <volkerstroebel@mysurdity.de> + +Permission is hereby granted, free of charge, to any +person obtaining a copy of this software and associated +documentation files (the "Software"), to deal in the +Software without restriction, including without +limitation the rights to use, copy, modify, merge, +publish, distribute, sublicense, and/or sell copies of +the Software, and to permit persons to whom the Software +is furnished to do so, subject to the following +conditions: + +The above copyright notice and this permission notice +shall be included in all copies or substantial portions +of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF +ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED +TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A +PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT +SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY +CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION +OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR +IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER +DEALINGS IN THE SOFTWARE. +Original src/fdct.rs opening notice + +/* + * Ported from mozjpeg to rust + * + * This file was part of the Independent JPEG Group's software: + * Copyright (C) 1991-1996, Thomas G. Lane. + * libjpeg-turbo Modifications: + * Copyright (C) 2015, 2020, D. R. Commander. + * + * Conditions of distribution and use: + * In plain English: + * + * 1. We don't promise that this software works. (But if you find any bugs, + * please let us know!) + * 2. You can use this software for whatever you want. You don't have to pay us. + * 3. You may not pretend that you wrote this software. If you use it in a + * program, you must acknowledge somewhere in your documentation that + * you've used the IJG code. + * + * In legalese: + * + * The authors make NO WARRANTY or representation, either express or implied, + * with respect to this software, its quality, accuracy, merchantability, or + * fitness for a particular purpose. This software is provided "AS IS", and you, + * its user, assume the entire risk as to its quality and accuracy. + * + * This software is copyright (C) 1991-2020, Thomas G. Lane, Guido Vollbeding. + * All Rights Reserved except as specified below. + * + * Permission is hereby granted to use, copy, modify, and distribute this + * software (or portions thereof) for any purpose, without fee, subject to these + * conditions: + * (1) If any part of the source code for this software is distributed, then this + * README file must be included, with this copyright and no-warranty notice + * unaltered; and any additions, deletions, or changes to the original files + * must be clearly indicated in accompanying documentation. + * (2) If only executable code is distributed, then the accompanying + * documentation must state that "this software is based in part on the work of + * the Independent JPEG Group". + * (3) Permission for use of this software is granted only if the user accepts + * full responsibility for any undesirable consequences; the authors accept + * NO LIABILITY for damages of any kind. + * + * These conditions apply to any software derived from or based on the IJG code, + * not just to the unmodified library. If you use our work, you ought to + * acknowledge us. + * + * Permission is NOT granted for the use of any IJG author's name or company name + * in advertising or publicity relating to this software or products derived from + * it. This software may be referred to only as "the Independent JPEG Group's + * software". + * + * We specifically permit and encourage the use of this software as the basis of + * commercial products, provided that all warranty or liability claims are + * assumed by the product vendor. + * + * This file contains a slower but more accurate integer implementation of the + * forward DCT (Discrete Cosine Transform). + * + * A 2-D DCT can be done by 1-D DCT on each row followed by 1-D DCT + * on each column. Direct algorithms are also available, but they are + * much more complex and seem not to be any faster when reduced to code. + * + * This implementation is based on an algorithm described in + * C. Loeffler, A. Ligtenberg and G. Moschytz, "Practical Fast 1-D DCT + * Algorithms with 11 Multiplications", Proc. Int'l. Conf. on Acoustics, + * Speech, and Signal Processing 1989 (ICASSP '89), pp. 988-991. + * The primary algorithm described there uses 11 multiplies and 29 adds. + * We use their alternate method with 12 multiplies and 32 adds. + * The advantage of this method is that no data path contains more than one + * multiplication; this allows a very simple and accurate implementation in + * scaled fixed-point arithmetic, with a minimal number of shifts. + */ + +Original src/avx2/fdct.rs opening notice + +/* + * Ported from mozjpeg / jfdctint-avx2.asm to rust + * Copyright 2009 Pierre Ossman <ossman@cendio.se> for Cendio AB + * Copyright (C) 2009, 2016, 2018, 2020, D. R. Commander. + * + * Based on the x86 SIMD extension for IJG JPEG library + * Copyright (C) 1999-2006, MIYASAKA Masaru. + */ From 5a94e113f56f799d5faf24a0593b4e8f7bc4e7ff Mon Sep 17 00:00:00 2001 From: "Dylan M. Taylor" <dylan@dylanmtaylor.com> Date: Sun, 15 Nov 2026 15:46:46 +0000 Subject: [PATCH 31/61] Use shared BMP coverage inspection --- Cargo.lock | 54 ++++++++++++---- Cargo.toml | 2 +- NOTICE | 124 +++++++++++++++++++++++++++++++++++++ crates/codecs/src/other.rs | 118 ++++------------------------------- 4 files changed, 181 insertions(+), 117 deletions(-) diff --git a/Cargo.lock b/Cargo.lock index 04c07b04f1..cb90f3c10e 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -1266,13 +1266,15 @@ dependencies = [ [[package]] name = "craft-image-codecs" version = "0.1.0" -source = "git+https://github.com/storytold/craft-libs?rev=f0f4758c01581d79577b9bf5046c06f4e77b1f18#f0f4758c01581d79577b9bf5046c06f4e77b1f18" +source = "git+https://github.com/storytold/craft-libs?rev=7c8f3528747401ca5a68dff1156f9937399a6e2b#7c8f3528747401ca5a68dff1156f9937399a6e2b" dependencies = [ "craft-jpeg", - "craft-metadata", + "craft-metadata 0.1.0 (git+https://github.com/storytold/craft-libs?rev=7c8f3528747401ca5a68dff1156f9937399a6e2b)", + "crc32fast", "exr", "flate2", "half", + "hayro-jpeg2000", "image", "image-webp", "jpeg-encoder", @@ -1289,7 +1291,7 @@ dependencies = [ [[package]] name = "craft-jpeg" version = "0.1.0" -source = "git+https://github.com/storytold/craft-libs?rev=f0f4758c01581d79577b9bf5046c06f4e77b1f18#f0f4758c01581d79577b9bf5046c06f4e77b1f18" +source = "git+https://github.com/storytold/craft-libs?rev=7c8f3528747401ca5a68dff1156f9937399a6e2b#7c8f3528747401ca5a68dff1156f9937399a6e2b" dependencies = [ "thiserror 2.0.21", ] @@ -1304,6 +1306,18 @@ dependencies = [ "thiserror 2.0.21", ] +[[package]] +name = "craft-metadata" +version = "0.1.0" +source = "git+https://github.com/storytold/craft-libs?rev=7c8f3528747401ca5a68dff1156f9937399a6e2b#7c8f3528747401ca5a68dff1156f9937399a6e2b" +dependencies = [ + "brotli-decompressor 6.0.1", + "chrono", + "craft-tiff 0.1.0 (git+https://github.com/storytold/craft-libs?rev=7c8f3528747401ca5a68dff1156f9937399a6e2b)", + "quick-xml 0.41.0", + "serde", +] + [[package]] name = "craft-metadata" version = "0.1.0" @@ -1311,7 +1325,7 @@ source = "git+https://github.com/storytold/craft-libs?rev=f0f4758c01581d79577b9b dependencies = [ "brotli-decompressor 6.0.1", "chrono", - "craft-tiff", + "craft-tiff 0.1.0 (git+https://github.com/storytold/craft-libs?rev=f0f4758c01581d79577b9bf5046c06f4e77b1f18)", "quick-xml 0.41.0", "serde", ] @@ -1334,8 +1348,8 @@ source = "git+https://github.com/storytold/craft-libs?rev=f0f4758c01581d79577b9b dependencies = [ "chrono", "craft-crw", - "craft-metadata", - "craft-tiff", + "craft-metadata 0.1.0 (git+https://github.com/storytold/craft-libs?rev=f0f4758c01581d79577b9bf5046c06f4e77b1f18)", + "craft-tiff 0.1.0 (git+https://github.com/storytold/craft-libs?rev=f0f4758c01581d79577b9bf5046c06f4e77b1f18)", "jxl-oxide", "miniz_oxide 0.9.1", "rayon", @@ -1345,6 +1359,15 @@ dependencies = [ "zune-jpeg", ] +[[package]] +name = "craft-tiff" +version = "0.1.0" +source = "git+https://github.com/storytold/craft-libs?rev=7c8f3528747401ca5a68dff1156f9937399a6e2b#7c8f3528747401ca5a68dff1156f9937399a6e2b" +dependencies = [ + "serde", + "thiserror 2.0.21", +] + [[package]] name = "craft-tiff" version = "0.1.0" @@ -3033,6 +3056,15 @@ dependencies = [ "foldhash 0.2.0", ] +[[package]] +name = "hayro-jpeg2000" +version = "0.3.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c75ab947623ef4ccaa7acf0579edf7cbb5a73838e3839a7be73335e522f433a1" +dependencies = [ + "fearless_simd", +] + [[package]] name = "heck" version = "0.5.0" @@ -3834,7 +3866,7 @@ dependencies = [ "craft-image-codecs", "craft-jxl", "craft-psd", - "craft-tiff", + "craft-tiff 0.1.0 (git+https://github.com/storytold/craft-libs?rev=f0f4758c01581d79577b9bf5046c06f4e77b1f18)", "dhat", "jxl-oxide", "lightcraft-color", @@ -3911,7 +3943,7 @@ dependencies = [ "chrono", "craft-docpath", "craft-heif", - "craft-tiff", + "craft-tiff 0.1.0 (git+https://github.com/storytold/craft-libs?rev=f0f4758c01581d79577b9bf5046c06f4e77b1f18)", "crc32fast", "fs4", "harfrust 0.13.3", @@ -4068,9 +4100,9 @@ version = "0.21.1" dependencies = [ "chrono", "craft-heif", - "craft-metadata", + "craft-metadata 0.1.0 (git+https://github.com/storytold/craft-libs?rev=f0f4758c01581d79577b9bf5046c06f4e77b1f18)", "craft-psd", - "craft-tiff", + "craft-tiff 0.1.0 (git+https://github.com/storytold/craft-libs?rev=f0f4758c01581d79577b9bf5046c06f4e77b1f18)", "lightcraft-geom", "proptest", "serde", @@ -4125,7 +4157,7 @@ dependencies = [ "chrono", "craft-image-codecs", "craft-raw", - "craft-tiff", + "craft-tiff 0.1.0 (git+https://github.com/storytold/craft-libs?rev=f0f4758c01581d79577b9bf5046c06f4e77b1f18)", "dhat", "lightcraft-color", "lightcraft-geom", diff --git a/Cargo.toml b/Cargo.toml index 2346d9cd48..4401ddcbba 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -19,7 +19,7 @@ craft-gif = { git = "https://github.com/storytold/craft-libs", rev = "b77af389f3 craft-jxl = { git = "https://github.com/storytold/craft-libs", rev = "b77af389f30bb10de10d8436ca9b39fe94e3bb67", default-features = false, features = ["decode", "encode"] } # Photo metadata: EXIF, IPTC-IIM, XMP packets and GPX track logs (craft-libs#949) craft-metadata = { git = "https://github.com/storytold/craft-libs", rev = "f0f4758c01581d79577b9bf5046c06f4e77b1f18" } -craft-image-codecs = { git = "https://github.com/storytold/craft-libs", rev = "f0f4758c01581d79577b9bf5046c06f4e77b1f18" } +craft-image-codecs = { git = "https://github.com/storytold/craft-libs", rev = "7c8f3528747401ca5a68dff1156f9937399a6e2b" } craft-xml = { git = "https://github.com/storytold/craft-libs", rev = "f0f4758c01581d79577b9bf5046c06f4e77b1f18" } # craft-update: app-specific pretend versions apply to startup and manual checks. craft-update = { git = "https://github.com/storytold/craft-libs", version = "=0.1.0", rev = "6e03f65bf45181db77ba6229716e6624db9eb25b", features = ["egui"] } diff --git a/NOTICE b/NOTICE index 39eb49db2c..e8576d71ee 100644 --- a/NOTICE +++ b/NOTICE @@ -335,3 +335,127 @@ Permission is hereby granted, free of charge, to any person obtaining a copy of The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software. THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. + +JPEG encoding dependency: jpeg-encoder 0.6.1 + +Source: https://crates.io/crates/jpeg-encoder/0.6.1 +Declared license: (MIT OR Apache-2.0) AND IJG. +This software is based in part on the work of the Independent JPEG Group. + +The MIT license and unaltered upstream IJG and SIMD notices follow. The Apache-2.0 +alternative is also retained in licenses/jpeg-encoder-0.6.1 at the repository root +(https://github.com/storytold/craft-libs/tree/main/licenses/jpeg-encoder-0.6.1). +The dependency is used unmodified; no encoder implementation is vendored here. + +LICENSE-MIT + +Copyright (c) 2021 Volker Ströbel <volkerstroebel@mysurdity.de> + +Permission is hereby granted, free of charge, to any +person obtaining a copy of this software and associated +documentation files (the "Software"), to deal in the +Software without restriction, including without +limitation the rights to use, copy, modify, merge, +publish, distribute, sublicense, and/or sell copies of +the Software, and to permit persons to whom the Software +is furnished to do so, subject to the following +conditions: + +The above copyright notice and this permission notice +shall be included in all copies or substantial portions +of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF +ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED +TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A +PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT +SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY +CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION +OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR +IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER +DEALINGS IN THE SOFTWARE. +Original src/fdct.rs opening notice + +/* + * Ported from mozjpeg to rust + * + * This file was part of the Independent JPEG Group's software: + * Copyright (C) 1991-1996, Thomas G. Lane. + * libjpeg-turbo Modifications: + * Copyright (C) 2015, 2020, D. R. Commander. + * + * Conditions of distribution and use: + * In plain English: + * + * 1. We don't promise that this software works. (But if you find any bugs, + * please let us know!) + * 2. You can use this software for whatever you want. You don't have to pay us. + * 3. You may not pretend that you wrote this software. If you use it in a + * program, you must acknowledge somewhere in your documentation that + * you've used the IJG code. + * + * In legalese: + * + * The authors make NO WARRANTY or representation, either express or implied, + * with respect to this software, its quality, accuracy, merchantability, or + * fitness for a particular purpose. This software is provided "AS IS", and you, + * its user, assume the entire risk as to its quality and accuracy. + * + * This software is copyright (C) 1991-2020, Thomas G. Lane, Guido Vollbeding. + * All Rights Reserved except as specified below. + * + * Permission is hereby granted to use, copy, modify, and distribute this + * software (or portions thereof) for any purpose, without fee, subject to these + * conditions: + * (1) If any part of the source code for this software is distributed, then this + * README file must be included, with this copyright and no-warranty notice + * unaltered; and any additions, deletions, or changes to the original files + * must be clearly indicated in accompanying documentation. + * (2) If only executable code is distributed, then the accompanying + * documentation must state that "this software is based in part on the work of + * the Independent JPEG Group". + * (3) Permission for use of this software is granted only if the user accepts + * full responsibility for any undesirable consequences; the authors accept + * NO LIABILITY for damages of any kind. + * + * These conditions apply to any software derived from or based on the IJG code, + * not just to the unmodified library. If you use our work, you ought to + * acknowledge us. + * + * Permission is NOT granted for the use of any IJG author's name or company name + * in advertising or publicity relating to this software or products derived from + * it. This software may be referred to only as "the Independent JPEG Group's + * software". + * + * We specifically permit and encourage the use of this software as the basis of + * commercial products, provided that all warranty or liability claims are + * assumed by the product vendor. + * + * This file contains a slower but more accurate integer implementation of the + * forward DCT (Discrete Cosine Transform). + * + * A 2-D DCT can be done by 1-D DCT on each row followed by 1-D DCT + * on each column. Direct algorithms are also available, but they are + * much more complex and seem not to be any faster when reduced to code. + * + * This implementation is based on an algorithm described in + * C. Loeffler, A. Ligtenberg and G. Moschytz, "Practical Fast 1-D DCT + * Algorithms with 11 Multiplications", Proc. Int'l. Conf. on Acoustics, + * Speech, and Signal Processing 1989 (ICASSP '89), pp. 988-991. + * The primary algorithm described there uses 11 multiplies and 29 adds. + * We use their alternate method with 12 multiplies and 32 adds. + * The advantage of this method is that no data path contains more than one + * multiplication; this allows a very simple and accurate implementation in + * scaled fixed-point arithmetic, with a minimal number of shifts. + */ + +Original src/avx2/fdct.rs opening notice + +/* + * Ported from mozjpeg / jfdctint-avx2.asm to rust + * Copyright 2009 Pierre Ossman <ossman@cendio.se> for Cendio AB + * Copyright (C) 2009, 2016, 2018, 2020, D. R. Commander. + * + * Based on the x86 SIMD extension for IJG JPEG library + * Copyright (C) 1999-2006, MIYASAKA Masaru. + */ diff --git a/crates/codecs/src/other.rs b/crates/codecs/src/other.rs index 1722715332..da0cf8993f 100644 --- a/crates/codecs/src/other.rs +++ b/crates/codecs/src/other.rs @@ -27,7 +27,7 @@ pub(crate) fn header(bytes: &[u8], format: Format) -> Result<(u32, u32, u16)> { return Ok((w, h, 1)); } if format == Format::Bmp { - let (w, h) = bmp_dims(bytes).ok_or_else(|| Error::Malformed(format, "invalid BMP header".into()))?; + let (w, h) = craft_image_codecs::bmp_probe::dimensions(bytes).ok_or_else(|| Error::Malformed(format, "invalid BMP header".into()))?; if w == 0 || h == 0 { return Err(Error::Malformed(format, "zero dimension".into())); } @@ -91,21 +91,18 @@ fn check_fillable(format: Format, bytes: &[u8], w: u32, h: u32) -> Result<()> { } craft_gif::first_frame_decoded_pixels(bytes).unwrap_or(0) } - _ => match bmp_layout(bytes) { - BmpLayout::Rle { offset, rle4 } => bmp_rle_pixels(bytes, offset, rle4, w, h), - BmpLayout::Rows { offset, bits } => { - let row = u64::from(w).saturating_mul(u64::from(bits)).div_ceil(32).saturating_mul(4); - let needed = row.saturating_mul(u64::from(h)); - let held = bytes.len().saturating_sub(offset) as u64; - if held < needed { - return Err(Error::Malformed( - format, - format!("a {w} × {h} canvas is larger than its {held} bytes of pixel data can hold ({needed} needed)"), - )); - } - canvas + _ => { + let coverage = craft_image_codecs::bmp_probe::coverage(bytes, w, h); + if let Some((held, needed)) = coverage.row_bytes + && held < needed + { + return Err(Error::Malformed( + format, + format!("a {w} × {h} canvas is larger than its {held} bytes of pixel data can hold ({needed} needed)"), + )); } - }, + coverage.pixels + } }; if canvas > covered && canvas > SPARSE_MAX_PIXELS { return Err(Error::Malformed( @@ -118,95 +115,6 @@ fn check_fillable(format: Format, bytes: &[u8], w: u32, h: u32) -> Result<()> { Ok(()) } -/// Where a BMP's pixels start (the offset in its file header, which the decoder seeks to) and how -/// they are stored. -enum BmpLayout { - /// RLE8 or RLE4 commands. - Rle { offset: usize, rle4: bool }, - /// Rows of `bits` per pixel, each padded to 4 bytes. - Rows { offset: usize, bits: u16 }, -} - -/// The layout the decoder reads, from the file header and the bitmap header: a 12-byte core header -/// (bits per pixel at 24, never compressed) or a 40-byte or larger one (bits at 28, compression at -/// 30). Fields the decoder would have refused are read as 1 bit per pixel at offset 0, the most -/// lenient layout. -fn bmp_layout(bytes: &[u8]) -> BmpLayout { - let u16_at = |i: usize| bytes.get(i..i.checked_add(2)?).and_then(|b| b.try_into().ok()).map(u16::from_le_bytes); - let u32_at = |i: usize| bytes.get(i..i.checked_add(4)?).and_then(|b| b.try_into().ok()).map(u32::from_le_bytes); - let offset = u32_at(10).and_then(|o| usize::try_from(o).ok()).unwrap_or(0); - let (bits, compression) = match u32_at(14) { - Some(12) => (u16_at(24), Some(0)), - _ => (u16_at(28), u32_at(30)), - }; - match compression { - Some(1) => BmpLayout::Rle { offset, rle4: false }, - Some(2) => BmpLayout::Rle { offset, rle4: true }, - _ => BmpLayout::Rows { offset, bits: bits.filter(|&b| b > 0).unwrap_or(1) }, - } -} - -/// The pixels an RLE8 or RLE4 BMP's commands draw on a `w` × `h` canvas, read the way the decoder -/// paints them: a run is clipped at the end of its row, an end-of-row code moves to the next row, a -/// delta skips pixels (left blank), and an end-of-bitmap code, a truncated command or the last row -/// ends the picture. Every command takes at least 2 bytes, so the walk is linear in the file. -fn bmp_rle_pixels(bytes: &[u8], offset: usize, rle4: bool, w: u32, h: u32) -> u64 { - let (w, h) = (u64::from(w), u64::from(h)); - let (mut pos, mut x, mut y, mut covered) = (offset, 0u64, 0u64, 0u64); - while y < h { - let (Some(&count), Some(&value)) = (bytes.get(pos), bytes.get(pos.saturating_add(1))) else { - break; - }; - pos = pos.saturating_add(2); - match (count, value) { - // end of row - (0, 0) => (x, y) = (0, y.saturating_add(1)), - // end of bitmap - (0, 1) => break, - // delta: right and down - (0, 2) => { - let (Some(&dx), Some(&dy)) = (bytes.get(pos), bytes.get(pos.saturating_add(1))) else { - break; - }; - pos = pos.saturating_add(2); - (x, y) = (x.saturating_add(u64::from(dx)), y.saturating_add(u64::from(dy))); - } - // absolute: `value` pixels stored one per byte (RLE8) or nibble (RLE4), padded to 2 bytes - (0, n) => { - let len = if rle4 { usize::from(n).div_ceil(2) } else { usize::from(n) }; - pos = pos.saturating_add(len + (len & 1)); - if pos > bytes.len() { - break; - } - covered = covered.saturating_add(u64::from(n).min(w.saturating_sub(x))); - x = x.saturating_add(u64::from(n)); - } - // a run of `count` pixels - (n, _) => { - covered = covered.saturating_add(u64::from(n).min(w.saturating_sub(x))); - x = x.saturating_add(u64::from(n)); - } - } - } - covered -} - -/// Reads BMP `(width, height)` from the DIB header without allocating. -fn bmp_dims(bytes: &[u8]) -> Option<(u32, u32)> { - if bytes.get(0..2) != Some(b"BM") { - return None; - } - let dib = u32::from_le_bytes(bytes.get(14..18)?.try_into().ok()?); - let (w, h) = if dib == 12 { - (u16::from_le_bytes(bytes.get(18..20)?.try_into().ok()?) as u32, u16::from_le_bytes(bytes.get(20..22)?.try_into().ok()?) as u32) - } else { - let w = i32::from_le_bytes(bytes.get(18..22)?.try_into().ok()?); - let h = i32::from_le_bytes(bytes.get(22..26)?.try_into().ok()?); - (u32::try_from(w).ok()?, h.unsigned_abs()) - }; - Some((w, h)) -} - pub(crate) fn decode(bytes: &[u8], format: Format, opts: &DecodeOptions) -> Result<Decoded> { if format == Format::Gif { return decode_gif(bytes, opts); @@ -214,7 +122,7 @@ pub(crate) fn decode(bytes: &[u8], format: Format, opts: &DecodeOptions) -> Resu if format != Format::Bmp { return Err(Error::Unsupported(format, "not handled by this decoder")); } - let (w, h) = bmp_dims(bytes).ok_or_else(|| Error::Malformed(format, "invalid BMP header".into()))?; + let (w, h) = craft_image_codecs::bmp_probe::dimensions(bytes).ok_or_else(|| Error::Malformed(format, "invalid BMP header".into()))?; check_size(format, w as u64, h as u64, opts)?; check_fillable(format, bytes, w, h)?; let (w, h) = craft_image_codecs::probe_size(bytes).map_err(|e| Error::Malformed(format, e.to_string()))?; From c732a21c681e23e498f32b4f67f686fb098ba723 Mon Sep 17 00:00:00 2001 From: "Dylan M. Taylor" <dylan@dylanmtaylor.com> Date: Sun, 15 Nov 2026 15:57:13 +0000 Subject: [PATCH 32/61] Use shared PSD builder for flat exports --- crates/codecs/src/psd.rs | 134 ++++++++++----------------------------- 1 file changed, 35 insertions(+), 99 deletions(-) diff --git a/crates/codecs/src/psd.rs b/crates/codecs/src/psd.rs index f0422edc13..284dae09ec 100644 --- a/crates/codecs/src/psd.rs +++ b/crates/codecs/src/psd.rs @@ -237,114 +237,50 @@ pub(crate) fn encode(img: &EncodeImage, meta: &EncodeMeta) -> Result<Vec<u8>> { if w > MAX_SIDE || h > MAX_SIDE { return Err(Error::Encode(format!("{w} × {h} is larger than a PSD can hold ({MAX_SIDE} px a side): use TIFF"))); } - let ch = usize::from(img.channels); - let color = if ch <= 2 { 1 } else { 3 }; - let (depth, bpc) = match img.samples { - Samples::U8(_) => (8u16, 1usize), - Samples::U16(_) => (16, 2), + let gray = img.channels <= 2; + let input_channels = usize::from(img.channels); + let output_channels = if gray { 2 } else { 4 }; + let pixels = (w as usize).checked_mul(h as usize).ok_or_else(|| Error::Encode("image too large".into()))?; + let size = pixels.checked_mul(output_channels).ok_or_else(|| Error::Encode("image too large".into()))?; + let (depth, data) = match img.samples { + Samples::U8(src) => { + let mut values = Vec::new(); + values.try_reserve_exact(size).map_err(|_| Error::Encode("image too large".into()))?; + for pixel in src.chunks_exact(input_channels).take(pixels) { + values.extend_from_slice(&pixel[..output_channels - 1]); + values.push(u8::MAX); + } + (8, if gray { craft_psd::PixelData::GrayA8(values) } else { craft_psd::PixelData::Rgba8(values) }) + } + Samples::U16(src) => { + let mut values = Vec::new(); + values.try_reserve_exact(size).map_err(|_| Error::Encode("image too large".into()))?; + for pixel in src.chunks_exact(input_channels).take(pixels) { + values.extend_from_slice(&pixel[..output_channels - 1]); + values.push(u16::MAX); + } + (16, if gray { craft_psd::PixelData::GrayA16(values) } else { craft_psd::PixelData::Rgba16(values) }) + } Samples::F32(_) => return Err(Error::Encode("32-bit float PSD is not supported: use TIFF".into())), }; - let (wu, hu) = (w as usize, h as usize); - let mut b = Vec::new(); - b.extend_from_slice(b"8BPS"); - b.extend_from_slice(&1u16.to_be_bytes()); - b.extend_from_slice(&[0; 6]); - b.extend_from_slice(&(color as u16).to_be_bytes()); - b.extend_from_slice(&h.to_be_bytes()); - b.extend_from_slice(&w.to_be_bytes()); - b.extend_from_slice(&depth.to_be_bytes()); - b.extend_from_slice(&(if color == 1 { 1u16 } else { 3 }).to_be_bytes()); - b.extend_from_slice(&0u32.to_be_bytes()); // colour mode data - let res = resource_section(meta); - b.extend_from_slice(&u32::try_from(res.len()).map_err(|_| Error::Encode("metadata too large for PSD".into()))?.to_be_bytes()); - b.extend_from_slice(&res); - b.extend_from_slice(&0u32.to_be_bytes()); // layer and mask information: none - // planar samples, one plane per colour channel (big-endian) - let plane = |c: usize| -> Vec<u8> { - let mut p = Vec::with_capacity(wu * hu * bpc); - match img.samples { - Samples::U8(s) => p.extend(s.iter().skip(c).step_by(ch).take(wu * hu)), - Samples::U16(s) => s.iter().skip(c).step_by(ch).take(wu * hu).for_each(|v| p.extend_from_slice(&v.to_be_bytes())), - Samples::F32(_) => {} - } - p - }; - if bpc == 1 { - b.extend_from_slice(&1u16.to_be_bytes()); - let mut counts = Vec::with_capacity(color * hu * 2); - let mut data = Vec::new(); - for c in 0..color { - for row in plane(c).chunks_exact(wu) { - let start = data.len(); - packbits(row, &mut data); - let n = u16::try_from(data.len() - start).map_err(|_| Error::Encode("PSD row too long".into()))?; - counts.extend_from_slice(&n.to_be_bytes()); - } - } - b.extend_from_slice(&counts); - b.extend_from_slice(&data); - } else { - b.extend_from_slice(&0u16.to_be_bytes()); - for c in 0..color { - b.extend_from_slice(&plane(c)); - } - } - Ok(b) -} - -/// The image resources section for `meta`. -fn resource_section(meta: &EncodeMeta) -> Vec<u8> { - let mut out = Vec::new(); - let mut add = |id: u16, data: &[u8]| { - out.extend_from_slice(b"8BIM"); - out.extend_from_slice(&id.to_be_bytes()); - out.extend_from_slice(&[0, 0]); // empty Pascal name, padded to even - out.extend_from_slice(&(data.len() as u32).to_be_bytes()); - out.extend_from_slice(data); - if data.len() % 2 == 1 { - out.push(0); - } - }; + let mut builder = craft_psd::PsdBuilder::new(w, h) + .color_mode(if gray { craft_psd::ColorMode::Grayscale } else { craft_psd::ColorMode::Rgb }) + .depth(depth) + .compression(if depth == 8 { craft_psd::Compression::Rle } else { craft_psd::Compression::Raw }); if let Some(ppi) = meta.ppi.filter(|p| *p > 0) { - // ResolutionInfo: 16.16 fixed pixels per inch, unit 1 (ppi), display unit 1 (inches), twice - let fixed = (u32::from(ppi) << 16).to_be_bytes(); - let one = 1u16.to_be_bytes(); - add(1005, &[&fixed[..], &one, &one, &fixed, &one, &one].concat()); + builder = builder.resolution(f64::from(ppi)); } if let Some(icc) = meta.icc { - add(1039, icc); + builder = builder.icc_profile(icc.to_vec()); } if let Some(exif) = meta.exif { - add(1058, exif); + builder = builder.resource(craft_psd::ImageResource::new(1058, exif.to_vec())); } if let Some(xmp) = meta.xmp { - add(1060, xmp.as_bytes()); - } - out -} - -/// PackBits: append one encoded row of `src` to `out` (runs of 2+ equal bytes as repeats, the -/// rest as literals of at most 128 bytes). -fn packbits(src: &[u8], out: &mut Vec<u8>) { - let mut rest = src; - while let Some(&b) = rest.first() { - // a run of 2 to 128 equal bytes - let run = rest.iter().take(128).take_while(|&&x| x == b).count(); - if run >= 2 { - // 1 - run in 2..=128: -1..=-127, as a signed byte - out.push((1 - run as i16) as i8 as u8); - out.push(b); - rest = rest.get(run..).unwrap_or_default(); - continue; - } - // a literal of 1 to 128 bytes: up to the next pair of equal bytes, or the end of the row - let unpaired = rest.windows(2).take(128).take_while(|w| w.first() != w.get(1)).count(); - let len = if unpaired.saturating_add(1) == rest.len() { rest.len() } else { unpaired }; - let (lit, tail) = rest.split_at_checked(len.clamp(1, 128)).unwrap_or((rest, &[][..])); - out.push(lit.len().saturating_sub(1) as u8); - out.extend_from_slice(lit); - rest = tail; + builder = builder.resource(craft_psd::ImageResource::new(1060, xmp.as_bytes().to_vec())); } + builder.composite(data); + builder.to_bytes().map_err(|e| Error::Encode(e.to_string())) } /// Stored dimensions and EXIF orientation (resource 1058) from the header and image resources, @@ -550,7 +486,7 @@ mod tests { let rows: [&[u8]; 6] = [&[], &[7], &[1, 1], &[1, 2, 3, 3, 3, 4, 5, 5], &[9; 300], &(0..=255u8).cycle().take(700).collect::<Vec<_>>()]; for row in rows { let mut enc = Vec::new(); - super::packbits(row, &mut enc); + craft_psd::compression::packbits::encode(row, &mut enc); let mut out = vec![0u8; row.len()]; unpackbits(&enc, &mut out).unwrap(); assert_eq!(out, row); From 926b80087ea8ba9da0f589e72b5d58c80188bc84 Mon Sep 17 00:00:00 2001 From: "Dylan M. Taylor" <dylan@dylanmtaylor.com> Date: Sun, 15 Nov 2026 16:01:26 +0000 Subject: [PATCH 33/61] Use borrowed shared PSD writer --- Cargo.lock | 2 +- Cargo.toml | 2 +- crates/codecs/src/psd.rs | 47 +++++----------------------------------- 3 files changed, 7 insertions(+), 44 deletions(-) diff --git a/Cargo.lock b/Cargo.lock index 04c07b04f1..9651d0c2b9 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -1319,7 +1319,7 @@ dependencies = [ [[package]] name = "craft-psd" version = "0.1.0" -source = "git+https://github.com/storytold/craft-libs?rev=9dcbd90c7d16e1a668b3afa057e940e2db328b93#9dcbd90c7d16e1a668b3afa057e940e2db328b93" +source = "git+https://github.com/storytold/craft-libs?rev=c94ab7a3f00588f1654afe18d981939c95b6d14c#c94ab7a3f00588f1654afe18d981939c95b6d14c" dependencies = [ "encoding_rs", "flate2", diff --git a/Cargo.toml b/Cargo.toml index 2346d9cd48..cf38fa86a0 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -27,7 +27,7 @@ craft-window = { git = "https://github.com/storytold/craft-libs", rev = "c5a1cbf # HDR gain maps: ISO 21496-1 and hdrgm metadata, compute and apply (moved from crates/codecs; craft-libs#904). craft-gainmap = { git = "https://github.com/storytold/craft-libs", rev = "9dcbd90c7d16e1a668b3afa057e940e2db328b93" } # PSD/PSB: the header, colour mode data and image resources (craft-libs#885). -craft-psd = { git = "https://github.com/storytold/craft-libs", rev = "9dcbd90c7d16e1a668b3afa057e940e2db328b93" } +craft-psd = { git = "https://github.com/storytold/craft-libs", rev = "c94ab7a3f00588f1654afe18d981939c95b6d14c" } # internal lightcraft-denoise-core = { path = "crates/denoise-core" } lightcraft-denoise = { path = "crates/denoise", default-features = false } diff --git a/crates/codecs/src/psd.rs b/crates/codecs/src/psd.rs index 284dae09ec..f39b37d780 100644 --- a/crates/codecs/src/psd.rs +++ b/crates/codecs/src/psd.rs @@ -237,50 +237,13 @@ pub(crate) fn encode(img: &EncodeImage, meta: &EncodeMeta) -> Result<Vec<u8>> { if w > MAX_SIDE || h > MAX_SIDE { return Err(Error::Encode(format!("{w} × {h} is larger than a PSD can hold ({MAX_SIDE} px a side): use TIFF"))); } - let gray = img.channels <= 2; - let input_channels = usize::from(img.channels); - let output_channels = if gray { 2 } else { 4 }; - let pixels = (w as usize).checked_mul(h as usize).ok_or_else(|| Error::Encode("image too large".into()))?; - let size = pixels.checked_mul(output_channels).ok_or_else(|| Error::Encode("image too large".into()))?; - let (depth, data) = match img.samples { - Samples::U8(src) => { - let mut values = Vec::new(); - values.try_reserve_exact(size).map_err(|_| Error::Encode("image too large".into()))?; - for pixel in src.chunks_exact(input_channels).take(pixels) { - values.extend_from_slice(&pixel[..output_channels - 1]); - values.push(u8::MAX); - } - (8, if gray { craft_psd::PixelData::GrayA8(values) } else { craft_psd::PixelData::Rgba8(values) }) - } - Samples::U16(src) => { - let mut values = Vec::new(); - values.try_reserve_exact(size).map_err(|_| Error::Encode("image too large".into()))?; - for pixel in src.chunks_exact(input_channels).take(pixels) { - values.extend_from_slice(&pixel[..output_channels - 1]); - values.push(u16::MAX); - } - (16, if gray { craft_psd::PixelData::GrayA16(values) } else { craft_psd::PixelData::Rgba16(values) }) - } + let samples = match img.samples { + Samples::U8(s) => craft_psd::flat::Samples::U8(s), + Samples::U16(s) => craft_psd::flat::Samples::U16(s), Samples::F32(_) => return Err(Error::Encode("32-bit float PSD is not supported: use TIFF".into())), }; - let mut builder = craft_psd::PsdBuilder::new(w, h) - .color_mode(if gray { craft_psd::ColorMode::Grayscale } else { craft_psd::ColorMode::Rgb }) - .depth(depth) - .compression(if depth == 8 { craft_psd::Compression::Rle } else { craft_psd::Compression::Raw }); - if let Some(ppi) = meta.ppi.filter(|p| *p > 0) { - builder = builder.resolution(f64::from(ppi)); - } - if let Some(icc) = meta.icc { - builder = builder.icc_profile(icc.to_vec()); - } - if let Some(exif) = meta.exif { - builder = builder.resource(craft_psd::ImageResource::new(1058, exif.to_vec())); - } - if let Some(xmp) = meta.xmp { - builder = builder.resource(craft_psd::ImageResource::new(1060, xmp.as_bytes().to_vec())); - } - builder.composite(data); - builder.to_bytes().map_err(|e| Error::Encode(e.to_string())) + let metadata = craft_psd::flat::Metadata { icc: meta.icc, exif: meta.exif, xmp: meta.xmp, ppi: meta.ppi }; + craft_psd::flat::write(w, h, img.channels, samples, metadata).map_err(|error| Error::Encode(error.to_string())) } /// Stored dimensions and EXIF orientation (resource 1058) from the header and image resources, From e44713b84d27a13231349f309d047bd38119e706 Mon Sep 17 00:00:00 2001 From: "Dylan M. Taylor" <dylan@dylanmtaylor.com> Date: Sun, 15 Nov 2026 16:03:18 +0000 Subject: [PATCH 34/61] Refresh shared PSD test revision --- Cargo.lock | 2 +- Cargo.toml | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/Cargo.lock b/Cargo.lock index 9651d0c2b9..55e3493a59 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -1319,7 +1319,7 @@ dependencies = [ [[package]] name = "craft-psd" version = "0.1.0" -source = "git+https://github.com/storytold/craft-libs?rev=c94ab7a3f00588f1654afe18d981939c95b6d14c#c94ab7a3f00588f1654afe18d981939c95b6d14c" +source = "git+https://github.com/storytold/craft-libs?rev=fcc7f4076df47bbee454256dfc99994782eb4c21#fcc7f4076df47bbee454256dfc99994782eb4c21" dependencies = [ "encoding_rs", "flate2", diff --git a/Cargo.toml b/Cargo.toml index cf38fa86a0..556a31c102 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -27,7 +27,7 @@ craft-window = { git = "https://github.com/storytold/craft-libs", rev = "c5a1cbf # HDR gain maps: ISO 21496-1 and hdrgm metadata, compute and apply (moved from crates/codecs; craft-libs#904). craft-gainmap = { git = "https://github.com/storytold/craft-libs", rev = "9dcbd90c7d16e1a668b3afa057e940e2db328b93" } # PSD/PSB: the header, colour mode data and image resources (craft-libs#885). -craft-psd = { git = "https://github.com/storytold/craft-libs", rev = "c94ab7a3f00588f1654afe18d981939c95b6d14c" } +craft-psd = { git = "https://github.com/storytold/craft-libs", rev = "fcc7f4076df47bbee454256dfc99994782eb4c21" } # internal lightcraft-denoise-core = { path = "crates/denoise-core" } lightcraft-denoise = { path = "crates/denoise", default-features = false } From 6b0e7c62e865c624368eb452a993a0c97ecff9cd Mon Sep 17 00:00:00 2001 From: "Dylan M. Taylor" <dylan@dylanmtaylor.com> Date: Sun, 15 Nov 2026 16:15:50 +0000 Subject: [PATCH 35/61] Use shared TIFF header validation --- Cargo.lock | 55 +++++++++++--- Cargo.toml | 2 +- NOTICE | 124 ++++++++++++++++++++++++++++++++ crates/codecs/src/tiff_codec.rs | 31 ++------ 4 files changed, 174 insertions(+), 38 deletions(-) diff --git a/Cargo.lock b/Cargo.lock index 04c07b04f1..439286b284 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -1266,13 +1266,16 @@ dependencies = [ [[package]] name = "craft-image-codecs" version = "0.1.0" -source = "git+https://github.com/storytold/craft-libs?rev=f0f4758c01581d79577b9bf5046c06f4e77b1f18#f0f4758c01581d79577b9bf5046c06f4e77b1f18" +source = "git+https://github.com/storytold/craft-libs?rev=fb6cb780061c6744ed6886e7dd1a80ccf449e655#fb6cb780061c6744ed6886e7dd1a80ccf449e655" dependencies = [ "craft-jpeg", - "craft-metadata", + "craft-metadata 0.1.0 (git+https://github.com/storytold/craft-libs?rev=fb6cb780061c6744ed6886e7dd1a80ccf449e655)", + "craft-tiff 0.1.0 (git+https://github.com/storytold/craft-libs?rev=fb6cb780061c6744ed6886e7dd1a80ccf449e655)", + "crc32fast", "exr", "flate2", "half", + "hayro-jpeg2000", "image", "image-webp", "jpeg-encoder", @@ -1289,7 +1292,7 @@ dependencies = [ [[package]] name = "craft-jpeg" version = "0.1.0" -source = "git+https://github.com/storytold/craft-libs?rev=f0f4758c01581d79577b9bf5046c06f4e77b1f18#f0f4758c01581d79577b9bf5046c06f4e77b1f18" +source = "git+https://github.com/storytold/craft-libs?rev=fb6cb780061c6744ed6886e7dd1a80ccf449e655#fb6cb780061c6744ed6886e7dd1a80ccf449e655" dependencies = [ "thiserror 2.0.21", ] @@ -1311,7 +1314,19 @@ source = "git+https://github.com/storytold/craft-libs?rev=f0f4758c01581d79577b9b dependencies = [ "brotli-decompressor 6.0.1", "chrono", - "craft-tiff", + "craft-tiff 0.1.0 (git+https://github.com/storytold/craft-libs?rev=f0f4758c01581d79577b9bf5046c06f4e77b1f18)", + "quick-xml 0.41.0", + "serde", +] + +[[package]] +name = "craft-metadata" +version = "0.1.0" +source = "git+https://github.com/storytold/craft-libs?rev=fb6cb780061c6744ed6886e7dd1a80ccf449e655#fb6cb780061c6744ed6886e7dd1a80ccf449e655" +dependencies = [ + "brotli-decompressor 6.0.1", + "chrono", + "craft-tiff 0.1.0 (git+https://github.com/storytold/craft-libs?rev=fb6cb780061c6744ed6886e7dd1a80ccf449e655)", "quick-xml 0.41.0", "serde", ] @@ -1334,8 +1349,8 @@ source = "git+https://github.com/storytold/craft-libs?rev=f0f4758c01581d79577b9b dependencies = [ "chrono", "craft-crw", - "craft-metadata", - "craft-tiff", + "craft-metadata 0.1.0 (git+https://github.com/storytold/craft-libs?rev=f0f4758c01581d79577b9bf5046c06f4e77b1f18)", + "craft-tiff 0.1.0 (git+https://github.com/storytold/craft-libs?rev=f0f4758c01581d79577b9bf5046c06f4e77b1f18)", "jxl-oxide", "miniz_oxide 0.9.1", "rayon", @@ -1354,6 +1369,15 @@ dependencies = [ "thiserror 2.0.21", ] +[[package]] +name = "craft-tiff" +version = "0.1.0" +source = "git+https://github.com/storytold/craft-libs?rev=fb6cb780061c6744ed6886e7dd1a80ccf449e655#fb6cb780061c6744ed6886e7dd1a80ccf449e655" +dependencies = [ + "serde", + "thiserror 2.0.21", +] + [[package]] name = "craft-ui" version = "0.1.0" @@ -3033,6 +3057,15 @@ dependencies = [ "foldhash 0.2.0", ] +[[package]] +name = "hayro-jpeg2000" +version = "0.3.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c75ab947623ef4ccaa7acf0579edf7cbb5a73838e3839a7be73335e522f433a1" +dependencies = [ + "fearless_simd", +] + [[package]] name = "heck" version = "0.5.0" @@ -3834,7 +3867,7 @@ dependencies = [ "craft-image-codecs", "craft-jxl", "craft-psd", - "craft-tiff", + "craft-tiff 0.1.0 (git+https://github.com/storytold/craft-libs?rev=f0f4758c01581d79577b9bf5046c06f4e77b1f18)", "dhat", "jxl-oxide", "lightcraft-color", @@ -3911,7 +3944,7 @@ dependencies = [ "chrono", "craft-docpath", "craft-heif", - "craft-tiff", + "craft-tiff 0.1.0 (git+https://github.com/storytold/craft-libs?rev=f0f4758c01581d79577b9bf5046c06f4e77b1f18)", "crc32fast", "fs4", "harfrust 0.13.3", @@ -4068,9 +4101,9 @@ version = "0.21.1" dependencies = [ "chrono", "craft-heif", - "craft-metadata", + "craft-metadata 0.1.0 (git+https://github.com/storytold/craft-libs?rev=f0f4758c01581d79577b9bf5046c06f4e77b1f18)", "craft-psd", - "craft-tiff", + "craft-tiff 0.1.0 (git+https://github.com/storytold/craft-libs?rev=f0f4758c01581d79577b9bf5046c06f4e77b1f18)", "lightcraft-geom", "proptest", "serde", @@ -4125,7 +4158,7 @@ dependencies = [ "chrono", "craft-image-codecs", "craft-raw", - "craft-tiff", + "craft-tiff 0.1.0 (git+https://github.com/storytold/craft-libs?rev=f0f4758c01581d79577b9bf5046c06f4e77b1f18)", "dhat", "lightcraft-color", "lightcraft-geom", diff --git a/Cargo.toml b/Cargo.toml index 2346d9cd48..8c48d8d6d6 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -19,7 +19,7 @@ craft-gif = { git = "https://github.com/storytold/craft-libs", rev = "b77af389f3 craft-jxl = { git = "https://github.com/storytold/craft-libs", rev = "b77af389f30bb10de10d8436ca9b39fe94e3bb67", default-features = false, features = ["decode", "encode"] } # Photo metadata: EXIF, IPTC-IIM, XMP packets and GPX track logs (craft-libs#949) craft-metadata = { git = "https://github.com/storytold/craft-libs", rev = "f0f4758c01581d79577b9bf5046c06f4e77b1f18" } -craft-image-codecs = { git = "https://github.com/storytold/craft-libs", rev = "f0f4758c01581d79577b9bf5046c06f4e77b1f18" } +craft-image-codecs = { git = "https://github.com/storytold/craft-libs", rev = "fb6cb780061c6744ed6886e7dd1a80ccf449e655" } craft-xml = { git = "https://github.com/storytold/craft-libs", rev = "f0f4758c01581d79577b9bf5046c06f4e77b1f18" } # craft-update: app-specific pretend versions apply to startup and manual checks. craft-update = { git = "https://github.com/storytold/craft-libs", version = "=0.1.0", rev = "6e03f65bf45181db77ba6229716e6624db9eb25b", features = ["egui"] } diff --git a/NOTICE b/NOTICE index 39eb49db2c..e8576d71ee 100644 --- a/NOTICE +++ b/NOTICE @@ -335,3 +335,127 @@ Permission is hereby granted, free of charge, to any person obtaining a copy of The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software. THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. + +JPEG encoding dependency: jpeg-encoder 0.6.1 + +Source: https://crates.io/crates/jpeg-encoder/0.6.1 +Declared license: (MIT OR Apache-2.0) AND IJG. +This software is based in part on the work of the Independent JPEG Group. + +The MIT license and unaltered upstream IJG and SIMD notices follow. The Apache-2.0 +alternative is also retained in licenses/jpeg-encoder-0.6.1 at the repository root +(https://github.com/storytold/craft-libs/tree/main/licenses/jpeg-encoder-0.6.1). +The dependency is used unmodified; no encoder implementation is vendored here. + +LICENSE-MIT + +Copyright (c) 2021 Volker Ströbel <volkerstroebel@mysurdity.de> + +Permission is hereby granted, free of charge, to any +person obtaining a copy of this software and associated +documentation files (the "Software"), to deal in the +Software without restriction, including without +limitation the rights to use, copy, modify, merge, +publish, distribute, sublicense, and/or sell copies of +the Software, and to permit persons to whom the Software +is furnished to do so, subject to the following +conditions: + +The above copyright notice and this permission notice +shall be included in all copies or substantial portions +of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF +ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED +TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A +PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT +SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY +CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION +OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR +IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER +DEALINGS IN THE SOFTWARE. +Original src/fdct.rs opening notice + +/* + * Ported from mozjpeg to rust + * + * This file was part of the Independent JPEG Group's software: + * Copyright (C) 1991-1996, Thomas G. Lane. + * libjpeg-turbo Modifications: + * Copyright (C) 2015, 2020, D. R. Commander. + * + * Conditions of distribution and use: + * In plain English: + * + * 1. We don't promise that this software works. (But if you find any bugs, + * please let us know!) + * 2. You can use this software for whatever you want. You don't have to pay us. + * 3. You may not pretend that you wrote this software. If you use it in a + * program, you must acknowledge somewhere in your documentation that + * you've used the IJG code. + * + * In legalese: + * + * The authors make NO WARRANTY or representation, either express or implied, + * with respect to this software, its quality, accuracy, merchantability, or + * fitness for a particular purpose. This software is provided "AS IS", and you, + * its user, assume the entire risk as to its quality and accuracy. + * + * This software is copyright (C) 1991-2020, Thomas G. Lane, Guido Vollbeding. + * All Rights Reserved except as specified below. + * + * Permission is hereby granted to use, copy, modify, and distribute this + * software (or portions thereof) for any purpose, without fee, subject to these + * conditions: + * (1) If any part of the source code for this software is distributed, then this + * README file must be included, with this copyright and no-warranty notice + * unaltered; and any additions, deletions, or changes to the original files + * must be clearly indicated in accompanying documentation. + * (2) If only executable code is distributed, then the accompanying + * documentation must state that "this software is based in part on the work of + * the Independent JPEG Group". + * (3) Permission for use of this software is granted only if the user accepts + * full responsibility for any undesirable consequences; the authors accept + * NO LIABILITY for damages of any kind. + * + * These conditions apply to any software derived from or based on the IJG code, + * not just to the unmodified library. If you use our work, you ought to + * acknowledge us. + * + * Permission is NOT granted for the use of any IJG author's name or company name + * in advertising or publicity relating to this software or products derived from + * it. This software may be referred to only as "the Independent JPEG Group's + * software". + * + * We specifically permit and encourage the use of this software as the basis of + * commercial products, provided that all warranty or liability claims are + * assumed by the product vendor. + * + * This file contains a slower but more accurate integer implementation of the + * forward DCT (Discrete Cosine Transform). + * + * A 2-D DCT can be done by 1-D DCT on each row followed by 1-D DCT + * on each column. Direct algorithms are also available, but they are + * much more complex and seem not to be any faster when reduced to code. + * + * This implementation is based on an algorithm described in + * C. Loeffler, A. Ligtenberg and G. Moschytz, "Practical Fast 1-D DCT + * Algorithms with 11 Multiplications", Proc. Int'l. Conf. on Acoustics, + * Speech, and Signal Processing 1989 (ICASSP '89), pp. 988-991. + * The primary algorithm described there uses 11 multiplies and 29 adds. + * We use their alternate method with 12 multiplies and 32 adds. + * The advantage of this method is that no data path contains more than one + * multiplication; this allows a very simple and accurate implementation in + * scaled fixed-point arithmetic, with a minimal number of shifts. + */ + +Original src/avx2/fdct.rs opening notice + +/* + * Ported from mozjpeg / jfdctint-avx2.asm to rust + * Copyright 2009 Pierre Ossman <ossman@cendio.se> for Cendio AB + * Copyright (C) 2009, 2016, 2018, 2020, D. R. Commander. + * + * Based on the x86 SIMD extension for IJG JPEG library + * Copyright (C) 1999-2006, MIYASAKA Masaru. + */ diff --git a/crates/codecs/src/tiff_codec.rs b/crates/codecs/src/tiff_codec.rs index 1ad9c802f8..955756ca66 100644 --- a/crates/codecs/src/tiff_codec.rs +++ b/crates/codecs/src/tiff_codec.rs @@ -68,30 +68,9 @@ pub(crate) fn decode(bytes: &[u8], opts: &DecodeOptions) -> Result<Decoded> { /// as a decode would refuse it: a layout or compression we can't decode, or strips/tiles that /// start past the end of the file (truncated). The compressed data itself is not checked. pub(crate) fn header(bytes: &[u8]) -> Result<(u32, u32, u16)> { - let (tiff, complete) = craft_tiff::Tiff::parse_with_status(bytes, &Default::default()).map_err(err)?; - if !complete { - return Err(err("truncated TIFF")); - } - let ifd = tiff.ifds.first().ok_or_else(|| err("no IFD"))?; - let info = ifd.image().map_err(err)?; - check_size(F, info.width as u64, info.height as u64, &DecodeOptions::default())?; - let bits = info.bits_per_sample.first().copied().unwrap_or(1); - if bits < 8 && info.planar == 2 && info.samples_per_pixel > 1 { - return Err(Error::Unsupported(F, "planar TIFF with samples narrower than a byte")); - } - if !(matches!(info.photometric, 0 | 1 | 2 | 3 | 5) || info.photometric == 6 && info.compression == 7) { - return Err(Error::Unsupported(F, "colour type")); - } - // what `craft-image-codecs`'s TIFF decoder decompresses: none, CCITT G4, LZW, JPEG, Deflate, PackBits - if !matches!(info.compression, 1 | 4 | 5 | 7 | 8 | 32773 | 32946) { - return Err(Error::Unsupported(F, "compression method")); - } - let len = bytes.len() as u64; - if info.offsets.is_empty() - || info.offsets.iter().zip(&info.byte_counts).any(|(&o, &c)| c > 0 && (o >= len || (info.compression == 1 && o.saturating_add(c) > len))) - { - return Err(err("truncated: image data past the end of the file")); - } - let orientation = ifd.u16(craft_tiff::tags::ORIENTATION).filter(|o| (1..=8).contains(o)).unwrap_or(1); - Ok((info.width, info.height, orientation)) + craft_image_codecs::tiff_probe::header(bytes, DecodeOptions::default().max_pixels).map_err(|error| match error { + craft_image_codecs::tiff_probe::Error::TooLarge { width, height } => Error::TooLarge(u64::from(width), u64::from(height)), + craft_image_codecs::tiff_probe::Error::Unsupported(reason) => Error::Unsupported(F, reason), + craft_image_codecs::tiff_probe::Error::Malformed(message) => err(message), + }) } From 3d524ceef7140557f065c1352bde17a525f48116 Mon Sep 17 00:00:00 2001 From: "Dylan M. Taylor" <dylan@dylanmtaylor.com> Date: Sun, 15 Nov 2026 16:17:55 +0000 Subject: [PATCH 36/61] Share TIFF decode preflight inspection --- Cargo.lock | 20 ++++++++++---------- Cargo.toml | 2 +- crates/codecs/src/tiff_codec.rs | 22 ++++++++++------------ 3 files changed, 21 insertions(+), 23 deletions(-) diff --git a/Cargo.lock b/Cargo.lock index 439286b284..e7b49767c2 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -1266,11 +1266,11 @@ dependencies = [ [[package]] name = "craft-image-codecs" version = "0.1.0" -source = "git+https://github.com/storytold/craft-libs?rev=fb6cb780061c6744ed6886e7dd1a80ccf449e655#fb6cb780061c6744ed6886e7dd1a80ccf449e655" +source = "git+https://github.com/storytold/craft-libs?rev=b16c5908ae777f81fa33a9e9ad0e22b09b37a383#b16c5908ae777f81fa33a9e9ad0e22b09b37a383" dependencies = [ "craft-jpeg", - "craft-metadata 0.1.0 (git+https://github.com/storytold/craft-libs?rev=fb6cb780061c6744ed6886e7dd1a80ccf449e655)", - "craft-tiff 0.1.0 (git+https://github.com/storytold/craft-libs?rev=fb6cb780061c6744ed6886e7dd1a80ccf449e655)", + "craft-metadata 0.1.0 (git+https://github.com/storytold/craft-libs?rev=b16c5908ae777f81fa33a9e9ad0e22b09b37a383)", + "craft-tiff 0.1.0 (git+https://github.com/storytold/craft-libs?rev=b16c5908ae777f81fa33a9e9ad0e22b09b37a383)", "crc32fast", "exr", "flate2", @@ -1292,7 +1292,7 @@ dependencies = [ [[package]] name = "craft-jpeg" version = "0.1.0" -source = "git+https://github.com/storytold/craft-libs?rev=fb6cb780061c6744ed6886e7dd1a80ccf449e655#fb6cb780061c6744ed6886e7dd1a80ccf449e655" +source = "git+https://github.com/storytold/craft-libs?rev=b16c5908ae777f81fa33a9e9ad0e22b09b37a383#b16c5908ae777f81fa33a9e9ad0e22b09b37a383" dependencies = [ "thiserror 2.0.21", ] @@ -1310,11 +1310,11 @@ dependencies = [ [[package]] name = "craft-metadata" version = "0.1.0" -source = "git+https://github.com/storytold/craft-libs?rev=f0f4758c01581d79577b9bf5046c06f4e77b1f18#f0f4758c01581d79577b9bf5046c06f4e77b1f18" +source = "git+https://github.com/storytold/craft-libs?rev=b16c5908ae777f81fa33a9e9ad0e22b09b37a383#b16c5908ae777f81fa33a9e9ad0e22b09b37a383" dependencies = [ "brotli-decompressor 6.0.1", "chrono", - "craft-tiff 0.1.0 (git+https://github.com/storytold/craft-libs?rev=f0f4758c01581d79577b9bf5046c06f4e77b1f18)", + "craft-tiff 0.1.0 (git+https://github.com/storytold/craft-libs?rev=b16c5908ae777f81fa33a9e9ad0e22b09b37a383)", "quick-xml 0.41.0", "serde", ] @@ -1322,11 +1322,11 @@ dependencies = [ [[package]] name = "craft-metadata" version = "0.1.0" -source = "git+https://github.com/storytold/craft-libs?rev=fb6cb780061c6744ed6886e7dd1a80ccf449e655#fb6cb780061c6744ed6886e7dd1a80ccf449e655" +source = "git+https://github.com/storytold/craft-libs?rev=f0f4758c01581d79577b9bf5046c06f4e77b1f18#f0f4758c01581d79577b9bf5046c06f4e77b1f18" dependencies = [ "brotli-decompressor 6.0.1", "chrono", - "craft-tiff 0.1.0 (git+https://github.com/storytold/craft-libs?rev=fb6cb780061c6744ed6886e7dd1a80ccf449e655)", + "craft-tiff 0.1.0 (git+https://github.com/storytold/craft-libs?rev=f0f4758c01581d79577b9bf5046c06f4e77b1f18)", "quick-xml 0.41.0", "serde", ] @@ -1363,7 +1363,7 @@ dependencies = [ [[package]] name = "craft-tiff" version = "0.1.0" -source = "git+https://github.com/storytold/craft-libs?rev=f0f4758c01581d79577b9bf5046c06f4e77b1f18#f0f4758c01581d79577b9bf5046c06f4e77b1f18" +source = "git+https://github.com/storytold/craft-libs?rev=b16c5908ae777f81fa33a9e9ad0e22b09b37a383#b16c5908ae777f81fa33a9e9ad0e22b09b37a383" dependencies = [ "serde", "thiserror 2.0.21", @@ -1372,7 +1372,7 @@ dependencies = [ [[package]] name = "craft-tiff" version = "0.1.0" -source = "git+https://github.com/storytold/craft-libs?rev=fb6cb780061c6744ed6886e7dd1a80ccf449e655#fb6cb780061c6744ed6886e7dd1a80ccf449e655" +source = "git+https://github.com/storytold/craft-libs?rev=f0f4758c01581d79577b9bf5046c06f4e77b1f18#f0f4758c01581d79577b9bf5046c06f4e77b1f18" dependencies = [ "serde", "thiserror 2.0.21", diff --git a/Cargo.toml b/Cargo.toml index 8c48d8d6d6..086f45fcd6 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -19,7 +19,7 @@ craft-gif = { git = "https://github.com/storytold/craft-libs", rev = "b77af389f3 craft-jxl = { git = "https://github.com/storytold/craft-libs", rev = "b77af389f30bb10de10d8436ca9b39fe94e3bb67", default-features = false, features = ["decode", "encode"] } # Photo metadata: EXIF, IPTC-IIM, XMP packets and GPX track logs (craft-libs#949) craft-metadata = { git = "https://github.com/storytold/craft-libs", rev = "f0f4758c01581d79577b9bf5046c06f4e77b1f18" } -craft-image-codecs = { git = "https://github.com/storytold/craft-libs", rev = "fb6cb780061c6744ed6886e7dd1a80ccf449e655" } +craft-image-codecs = { git = "https://github.com/storytold/craft-libs", rev = "b16c5908ae777f81fa33a9e9ad0e22b09b37a383" } craft-xml = { git = "https://github.com/storytold/craft-libs", rev = "f0f4758c01581d79577b9bf5046c06f4e77b1f18" } # craft-update: app-specific pretend versions apply to startup and manual checks. craft-update = { git = "https://github.com/storytold/craft-libs", version = "=0.1.0", rev = "6e03f65bf45181db77ba6229716e6624db9eb25b", features = ["egui"] } diff --git a/crates/codecs/src/tiff_codec.rs b/crates/codecs/src/tiff_codec.rs index 955756ca66..02395472c9 100644 --- a/crates/codecs/src/tiff_codec.rs +++ b/crates/codecs/src/tiff_codec.rs @@ -1,4 +1,4 @@ -//! TIFF decode via `craft-image-codecs` and header/IFD inspection via `craft-tiff`. +//! TIFF decode and header inspection via `craft-image-codecs`. use crate::convert::{Buf, Meta, Model, Raw, check_size, finish}; use crate::{DecodeOptions, Decoded, Error, Format, Result}; @@ -10,15 +10,9 @@ fn err(e: impl std::fmt::Display) -> Error { } pub(crate) fn decode(bytes: &[u8], opts: &DecodeOptions) -> Result<Decoded> { - let (tiff, complete) = craft_tiff::Tiff::parse_with_status(bytes, &Default::default()).map_err(err)?; - if !complete { - return Err(err("truncated TIFF")); - } - let ifd = tiff.ifds.first().ok_or_else(|| err("no IFD"))?; - let info = ifd.image().map_err(err)?; - check_size(F, info.width as u64, info.height as u64, opts)?; - let orientation = ifd.u16(craft_tiff::tags::ORIENTATION); - let bit_depth = info.bits_per_sample.first().copied().unwrap_or(8) as u8; + let info = craft_image_codecs::tiff_probe::decode_info(bytes, opts.max_pixels).map_err(probe_error)?; + let orientation = info.orientation; + let bit_depth = info.bit_depth; let ic_opts = craft_image_codecs::DecodeOptions { limits: craft_image_codecs::Limits { @@ -68,9 +62,13 @@ pub(crate) fn decode(bytes: &[u8], opts: &DecodeOptions) -> Result<Decoded> { /// as a decode would refuse it: a layout or compression we can't decode, or strips/tiles that /// start past the end of the file (truncated). The compressed data itself is not checked. pub(crate) fn header(bytes: &[u8]) -> Result<(u32, u32, u16)> { - craft_image_codecs::tiff_probe::header(bytes, DecodeOptions::default().max_pixels).map_err(|error| match error { + craft_image_codecs::tiff_probe::header(bytes, DecodeOptions::default().max_pixels).map_err(probe_error) +} + +fn probe_error(error: craft_image_codecs::tiff_probe::Error) -> Error { + match error { craft_image_codecs::tiff_probe::Error::TooLarge { width, height } => Error::TooLarge(u64::from(width), u64::from(height)), craft_image_codecs::tiff_probe::Error::Unsupported(reason) => Error::Unsupported(F, reason), craft_image_codecs::tiff_probe::Error::Malformed(message) => err(message), - }) + } } From 3518393ce029ba03c19fddd482e0f95c9d36b198 Mon Sep 17 00:00:00 2001 From: "Dylan M. Taylor" <dylan@dylanmtaylor.com> Date: Sun, 15 Nov 2026 11:23:32 -0500 Subject: [PATCH 37/61] Delegate Luminar XML property lists to shared bounded reader --- Cargo.lock | 9 ++ Cargo.toml | 1 + crates/engine/Cargo.toml | 1 + crates/engine/src/preset_luminar.rs | 242 +++++++--------------------- 4 files changed, 65 insertions(+), 188 deletions(-) diff --git a/Cargo.lock b/Cargo.lock index 04c07b04f1..b02138836b 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -1316,6 +1316,14 @@ dependencies = [ "serde", ] +[[package]] +name = "craft-plist" +version = "0.1.0" +source = "git+https://github.com/storytold/craft-libs?rev=c17840e099d7a4237770bca99efb2693f1692a8d#c17840e099d7a4237770bca99efb2693f1692a8d" +dependencies = [ + "thiserror 2.0.21", +] + [[package]] name = "craft-psd" version = "0.1.0" @@ -3911,6 +3919,7 @@ dependencies = [ "chrono", "craft-docpath", "craft-heif", + "craft-plist", "craft-tiff", "crc32fast", "fs4", diff --git a/Cargo.toml b/Cargo.toml index 2346d9cd48..324fbefa1b 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -10,6 +10,7 @@ rust-version = "1.95" repository = "https://github.com/storytold/lightcraft" [workspace.dependencies] +craft-plist = { version = "0.1.0", git = "https://github.com/storytold/craft-libs", rev = "c17840e099d7a4237770bca99efb2693f1692a8d" } craft-ui = { git = "https://github.com/storytold/craft-libs", rev = "c5a1cbfb5f9049f9270955caffb5bee5997aebf7", features = ["serde"] } craft-docpath = { version = "0.1.0", git = "https://github.com/storytold/craft-libs", rev = "c5a1cbfb5f9049f9270955caffb5bee5997aebf7" } # Canon CRW decoder shared with the other Craft apps diff --git a/crates/engine/Cargo.toml b/crates/engine/Cargo.toml index 1486642429..b2c09bf30d 100644 --- a/crates/engine/Cargo.toml +++ b/crates/engine/Cargo.toml @@ -9,6 +9,7 @@ description = "LightCraft engine: session, command registry, history, render job workspace = true [dependencies] +craft-plist = { workspace = true } # Paths stored in a Lightroom catalog are followed only to local files or the catalog's share. craft-docpath = { workspace = true } lightcraft-geom = { workspace = true } diff --git a/crates/engine/src/preset_luminar.rs b/crates/engine/src/preset_luminar.rs index 5a4fb21582..44ec5cb8c4 100644 --- a/crates/engine/src/preset_luminar.rs +++ b/crates/engine/src/preset_luminar.rs @@ -62,198 +62,42 @@ impl Plist { } } -struct Parser<'a> { - s: &'a str, - i: usize, - /// Nesting of the element being read (bounded: a hostile file must not overflow the stack). - depth: usize, -} - -/// Deepest `<dict>` / `<array>` nesting read (real looks nest a handful of levels). -const MAX_DEPTH: usize = 64; - -/// Index of the `;` that ends a reference starting at `rest` (its `&`). The scan stops at the first -/// byte that cannot appear in a name or a numeric reference, so zero-padded references such as -/// `&#000000097;` are found and each run of name bytes is read once, not once per `&`. -fn entity_end(rest: &str) -> Option<usize> { - let n = rest.bytes().skip(1).take_while(|b| b.is_ascii_alphanumeric() || *b == b'#').count(); - (rest.as_bytes().get(n + 1) == Some(&b';')).then_some(n + 1) -} - -fn unescape(t: &str) -> String { - let mut out = String::with_capacity(t.len()); - let mut rest = t; - while let Some(p) = rest.find('&') { - out.push_str(&rest[..p]); - rest = &rest[p..]; - // no `;` within a reference's reach: the `&` is kept and the search goes on after it - let Some(end) = entity_end(rest) else { - out.push('&'); - rest = &rest[1..]; - continue; - }; - let ent = &rest[1..end]; - let c = match ent { - "amp" => Some('&'), - "lt" => Some('<'), - "gt" => Some('>'), - "quot" => Some('"'), - "apos" => Some('\''), - _ => ent - .strip_prefix("#x") - .or_else(|| ent.strip_prefix("#X")) - .filter(|h| h.bytes().all(|b| b.is_ascii_hexdigit())) - .and_then(|h| u32::from_str_radix(h, 16).ok()) - .or_else(|| ent.strip_prefix('#').filter(|d| d.bytes().all(|b| b.is_ascii_digit())).and_then(|d| d.parse().ok())) - .and_then(char::from_u32), - }; - match c { - Some(c) => { - out.push(c); - rest = &rest[end + 1..]; - } - None => { - out.push('&'); - rest = &rest[1..]; - } - } - } - out.push_str(rest); - out -} - -impl Parser<'_> { - fn err<T>(&self, what: &str) -> Result<T, String> { - Err(format!("property list: {what} at byte {}", self.i)) - } - /// Skip whitespace, the XML declaration, the doctype and comments. - fn skip(&mut self) { - loop { - let r = &self.s[self.i..]; - let t = r.trim_start(); - self.i += r.len() - t.len(); - let close = if t.starts_with("<?") { - "?>" - } else if t.starts_with("<!--") { - "-->" - } else if t.starts_with("<!") { - ">" - } else { - return; - }; - match t.find(close) { - Some(e) => self.i += e + close.len(), - None => { - self.i = self.s.len(); - return; - } - } - } - } - /// The next tag: (name, closing, self-closing). - fn tag(&mut self) -> Result<(String, bool, bool), String> { - self.skip(); - let r = &self.s[self.i..]; - if !r.starts_with('<') { - return self.err("expected a tag"); - } - let Some(end) = r.find('>') else { return self.err("unterminated tag") }; - let inner = &r[1..end]; - self.i += end + 1; - let closing = inner.starts_with('/'); - let selfc = inner.ends_with('/'); - let name = inner.trim_start_matches('/').trim_end_matches('/').split_whitespace().next().unwrap_or("").to_string(); - Ok((name, closing, selfc)) - } - fn peek_close(&mut self, name: &str) -> bool { - self.skip(); - let r = &self.s[self.i..]; - let t = format!("</{name}>"); - if r.starts_with(&t) { - self.i += t.len(); - true - } else { - false - } - } - fn text(&mut self, name: &str) -> Result<String, String> { - let r = &self.s[self.i..]; - let t = format!("</{name}>"); - let Some(end) = r.find(&t) else { return self.err(&format!("missing {t}")) }; - self.i += end + t.len(); - Ok(unescape(&r[..end])) - } - fn value(&mut self) -> Result<Plist, String> { - if self.depth >= MAX_DEPTH { - return self.err("nested too deeply"); - } - self.depth += 1; - let v = self.value_inner(); - self.depth -= 1; - v - } - fn value_inner(&mut self) -> Result<Plist, String> { - let (name, closing, selfc) = self.tag()?; - if closing { - return self.err(&format!("unexpected </{name}>")); - } - let leaf = |p: &mut Self, f: &dyn Fn(String) -> Result<Plist, String>| if selfc { f(String::new()) } else { p.text(&name).and_then(f) }; - match name.as_str() { - "plist" => { - if selfc { - return Ok(Plist::Dict(Vec::new())); - } - let v = self.value()?; - self.peek_close("plist"); - Ok(v) - } - "dict" => { - let mut m = Vec::new(); - if !selfc { - while !self.peek_close("dict") { - let (k, c, sc) = self.tag()?; - if k != "key" || c { - return self.err("expected <key>"); - } - let key = if sc { String::new() } else { self.text("key")? }; - m.push((key, self.value()?)); - } - } - Ok(Plist::Dict(m)) - } - "array" => { - let mut a = Vec::new(); - if !selfc { - while !self.peek_close("array") { - a.push(self.value()?); - } - } - Ok(Plist::Array(a)) - } - "string" | "date" => leaf(self, &|t| Ok(Plist::Str(t))), - "real" | "integer" => { - leaf(self, &|t| t.trim().parse::<f64>().map(Plist::Num).map_err(|_| format!("property list: bad number {:?}", t.trim()))) - } - "data" => leaf(self, &|_| Ok(Plist::Data)), - "true" | "false" => { - if !selfc { - self.text(&name)?; - } - Ok(Plist::Bool(name == "true")) - } - _ => self.err(&format!("unknown element <{name}>")), - } - } -} - -/// Parse an XML property list. +/// Parse XML through the shared bounded codec; binary presets remain unsupported. pub fn parse_plist(bytes: &[u8]) -> Result<Plist, String> { if bytes.starts_with(b"bplist") { return Err("binary property lists are not supported".into()); } - let text = String::from_utf8_lossy(bytes); - let mut p = Parser { s: text.trim_start_matches('\u{feff}'), i: 0, depth: 0 }; - p.value() + // The existing wrapped-plist limit counts the <plist> wrapper and root value. + // ZIP expansion remains charged separately by preset_import before this parser runs. + let limits = craft_plist::Limits { + max_input_bytes: MAX_ZIP_ENTRY, + max_expanded_bytes: MAX_ZIP_ENTRY.saturating_mul(2), + max_depth: 62, + ..craft_plist::Limits::default() + }; + let value = craft_plist::parse_xml_with_limits(bytes, limits).map_err(|error| match error { + craft_plist::FormatError::TooLarge(_) => format!("property list: nested too deeply or exceeds resource limits: {error}"), + _ => format!("property list: {error}"), + })?; + map_plist(value) +} + +// Luminar mapping deliberately keeps its existing value policy: dates are strings, integer +// settings are f64, and data is a presence marker rather than an app-owned binary payload. +fn map_plist(value: craft_plist::Value) -> Result<Plist, String> { + use craft_plist::{DateValue, Value}; + Ok(match value { + Value::Dict(entries) => { + Plist::Dict(entries.into_iter().map(|(key, value)| map_plist(value).map(|value| (key, value))).collect::<Result<_, _>>()?) + } + Value::Array(values) => Plist::Array(values.into_iter().map(map_plist).collect::<Result<_, _>>()?), + Value::String(value) | Value::Date(DateValue::Text(value)) => Plist::Str(value), + Value::Integer(value) => Plist::Num(value as f64), + Value::Real(value) => Plist::Num(value), + Value::Bool(value) => Plist::Bool(value), + Value::Data(_) => Plist::Data, + _ => return Err("property list: unsupported XML value".into()), + }) } // ------------------------------------------------------------------------------------ mapping @@ -508,6 +352,10 @@ pub(crate) fn read_mplumpack_within(path: &str, bytes: &[u8], budget: &mut usize #[cfg(test)] mod tests { + fn unescape(text: &str) -> String { + let xml = format!("<string>{text}</string>"); + super::parse_plist(xml.as_bytes()).unwrap().str().unwrap().to_string() + } use super::*; use crate::preset_import::read_presets; use serde_json::json; @@ -731,4 +579,22 @@ mod tests { assert_eq!(r["imported"][0]["group"], json!("Imported Presets"), "{r}"); let _ = std::fs::remove_dir_all(&dir); } + + #[test] + fn shared_plist_adapter_keeps_luminar_value_mapping() { + let p = parse_plist( + b"<dict><key>date</key><date> 2026-01-01T00:00:00Z </date><key>integer</key><integer>-3</integer><key>data</key><data>AAEC</data></dict>", + ) + .unwrap(); + assert_eq!(p.get("date").and_then(Plist::str), Some("2026-01-01T00:00:00Z")); + assert_eq!(p.get("integer").and_then(Plist::num), Some(-3.0)); + assert_eq!(p.get("data"), Some(&Plist::Data)); + } + #[test] + fn shared_plist_refuses_malformed_values_instead_of_repairing_them() { + for xml in ["<data>not base64!</data>", "<integer>1.5</integer>", "<real>NaN</real>", "<plist><string>x</string>", "<string>x</string>junk"] { + assert!(parse_plist(xml.as_bytes()).is_err(), "{xml}"); + } + assert!(parse_plist(b"<string>\xff</string>").is_err()); + } } From 116d3d633441993584971f049a26851522f0e67a Mon Sep 17 00:00:00 2001 From: "Dylan M. Taylor" <dylan@dylanmtaylor.com> Date: Sun, 15 Nov 2026 11:24:34 -0500 Subject: [PATCH 38/61] Retain Luminar date whitespace with shared XML policy --- Cargo.lock | 2 +- Cargo.toml | 2 +- crates/engine/src/preset_luminar.rs | 11 ++++++----- 3 files changed, 8 insertions(+), 7 deletions(-) diff --git a/Cargo.lock b/Cargo.lock index b02138836b..5b0d68c002 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -1319,7 +1319,7 @@ dependencies = [ [[package]] name = "craft-plist" version = "0.1.0" -source = "git+https://github.com/storytold/craft-libs?rev=c17840e099d7a4237770bca99efb2693f1692a8d#c17840e099d7a4237770bca99efb2693f1692a8d" +source = "git+https://github.com/storytold/craft-libs?rev=0dab3133a2a58d321ade446f23592e7855b79e78#0dab3133a2a58d321ade446f23592e7855b79e78" dependencies = [ "thiserror 2.0.21", ] diff --git a/Cargo.toml b/Cargo.toml index 324fbefa1b..6cafc08bc3 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -10,7 +10,7 @@ rust-version = "1.95" repository = "https://github.com/storytold/lightcraft" [workspace.dependencies] -craft-plist = { version = "0.1.0", git = "https://github.com/storytold/craft-libs", rev = "c17840e099d7a4237770bca99efb2693f1692a8d" } +craft-plist = { version = "0.1.0", git = "https://github.com/storytold/craft-libs", rev = "0dab3133a2a58d321ade446f23592e7855b79e78" } craft-ui = { git = "https://github.com/storytold/craft-libs", rev = "c5a1cbfb5f9049f9270955caffb5bee5997aebf7", features = ["serde"] } craft-docpath = { version = "0.1.0", git = "https://github.com/storytold/craft-libs", rev = "c5a1cbfb5f9049f9270955caffb5bee5997aebf7" } # Canon CRW decoder shared with the other Craft apps diff --git a/crates/engine/src/preset_luminar.rs b/crates/engine/src/preset_luminar.rs index 44ec5cb8c4..1d594e1525 100644 --- a/crates/engine/src/preset_luminar.rs +++ b/crates/engine/src/preset_luminar.rs @@ -75,10 +75,11 @@ pub fn parse_plist(bytes: &[u8]) -> Result<Plist, String> { max_depth: 62, ..craft_plist::Limits::default() }; - let value = craft_plist::parse_xml_with_limits(bytes, limits).map_err(|error| match error { - craft_plist::FormatError::TooLarge(_) => format!("property list: nested too deeply or exceeds resource limits: {error}"), - _ => format!("property list: {error}"), - })?; + let value = + craft_plist::parse_xml_with_options(bytes, limits, craft_plist::XmlOptions { trim_date_text: false }).map_err(|error| match error { + craft_plist::FormatError::TooLarge(_) => format!("property list: nested too deeply or exceeds resource limits: {error}"), + _ => format!("property list: {error}"), + })?; map_plist(value) } @@ -586,7 +587,7 @@ mod tests { b"<dict><key>date</key><date> 2026-01-01T00:00:00Z </date><key>integer</key><integer>-3</integer><key>data</key><data>AAEC</data></dict>", ) .unwrap(); - assert_eq!(p.get("date").and_then(Plist::str), Some("2026-01-01T00:00:00Z")); + assert_eq!(p.get("date").and_then(Plist::str), Some(" 2026-01-01T00:00:00Z ")); assert_eq!(p.get("integer").and_then(Plist::num), Some(-3.0)); assert_eq!(p.get("data"), Some(&Plist::Data)); } From c4aa3755211cba648c81d6bec3fd06a3514a7819 Mon Sep 17 00:00:00 2001 From: "Dylan M. Taylor" <dylan@dylanmtaylor.com> Date: Sun, 15 Nov 2026 17:29:56 +0000 Subject: [PATCH 39/61] Pin merged shared BMP validation --- Cargo.lock | 12 ++++++------ Cargo.toml | 2 +- 2 files changed, 7 insertions(+), 7 deletions(-) diff --git a/Cargo.lock b/Cargo.lock index cb90f3c10e..c0d8ff39ac 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -1266,10 +1266,10 @@ dependencies = [ [[package]] name = "craft-image-codecs" version = "0.1.0" -source = "git+https://github.com/storytold/craft-libs?rev=7c8f3528747401ca5a68dff1156f9937399a6e2b#7c8f3528747401ca5a68dff1156f9937399a6e2b" +source = "git+https://github.com/storytold/craft-libs?rev=c9de09877ba38dba838ade37ba105032357709a9#c9de09877ba38dba838ade37ba105032357709a9" dependencies = [ "craft-jpeg", - "craft-metadata 0.1.0 (git+https://github.com/storytold/craft-libs?rev=7c8f3528747401ca5a68dff1156f9937399a6e2b)", + "craft-metadata 0.1.0 (git+https://github.com/storytold/craft-libs?rev=c9de09877ba38dba838ade37ba105032357709a9)", "crc32fast", "exr", "flate2", @@ -1291,7 +1291,7 @@ dependencies = [ [[package]] name = "craft-jpeg" version = "0.1.0" -source = "git+https://github.com/storytold/craft-libs?rev=7c8f3528747401ca5a68dff1156f9937399a6e2b#7c8f3528747401ca5a68dff1156f9937399a6e2b" +source = "git+https://github.com/storytold/craft-libs?rev=c9de09877ba38dba838ade37ba105032357709a9#c9de09877ba38dba838ade37ba105032357709a9" dependencies = [ "thiserror 2.0.21", ] @@ -1309,11 +1309,11 @@ dependencies = [ [[package]] name = "craft-metadata" version = "0.1.0" -source = "git+https://github.com/storytold/craft-libs?rev=7c8f3528747401ca5a68dff1156f9937399a6e2b#7c8f3528747401ca5a68dff1156f9937399a6e2b" +source = "git+https://github.com/storytold/craft-libs?rev=c9de09877ba38dba838ade37ba105032357709a9#c9de09877ba38dba838ade37ba105032357709a9" dependencies = [ "brotli-decompressor 6.0.1", "chrono", - "craft-tiff 0.1.0 (git+https://github.com/storytold/craft-libs?rev=7c8f3528747401ca5a68dff1156f9937399a6e2b)", + "craft-tiff 0.1.0 (git+https://github.com/storytold/craft-libs?rev=c9de09877ba38dba838ade37ba105032357709a9)", "quick-xml 0.41.0", "serde", ] @@ -1362,7 +1362,7 @@ dependencies = [ [[package]] name = "craft-tiff" version = "0.1.0" -source = "git+https://github.com/storytold/craft-libs?rev=7c8f3528747401ca5a68dff1156f9937399a6e2b#7c8f3528747401ca5a68dff1156f9937399a6e2b" +source = "git+https://github.com/storytold/craft-libs?rev=c9de09877ba38dba838ade37ba105032357709a9#c9de09877ba38dba838ade37ba105032357709a9" dependencies = [ "serde", "thiserror 2.0.21", diff --git a/Cargo.toml b/Cargo.toml index 4401ddcbba..3aca5bbdf4 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -19,7 +19,7 @@ craft-gif = { git = "https://github.com/storytold/craft-libs", rev = "b77af389f3 craft-jxl = { git = "https://github.com/storytold/craft-libs", rev = "b77af389f30bb10de10d8436ca9b39fe94e3bb67", default-features = false, features = ["decode", "encode"] } # Photo metadata: EXIF, IPTC-IIM, XMP packets and GPX track logs (craft-libs#949) craft-metadata = { git = "https://github.com/storytold/craft-libs", rev = "f0f4758c01581d79577b9bf5046c06f4e77b1f18" } -craft-image-codecs = { git = "https://github.com/storytold/craft-libs", rev = "7c8f3528747401ca5a68dff1156f9937399a6e2b" } +craft-image-codecs = { git = "https://github.com/storytold/craft-libs", rev = "c9de09877ba38dba838ade37ba105032357709a9" } craft-xml = { git = "https://github.com/storytold/craft-libs", rev = "f0f4758c01581d79577b9bf5046c06f4e77b1f18" } # craft-update: app-specific pretend versions apply to startup and manual checks. craft-update = { git = "https://github.com/storytold/craft-libs", version = "=0.1.0", rev = "6e03f65bf45181db77ba6229716e6624db9eb25b", features = ["egui"] } From 860a261dc688d3dffe06821ecba4504b238f6392 Mon Sep 17 00:00:00 2001 From: "Dylan M. Taylor" <dylan@dylanmtaylor.com> Date: Sun, 15 Nov 2026 17:59:26 +0000 Subject: [PATCH 40/61] Pin merged shared PSD writer --- Cargo.lock | 2 +- Cargo.toml | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/Cargo.lock b/Cargo.lock index 55e3493a59..c7591b3124 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -1319,7 +1319,7 @@ dependencies = [ [[package]] name = "craft-psd" version = "0.1.0" -source = "git+https://github.com/storytold/craft-libs?rev=fcc7f4076df47bbee454256dfc99994782eb4c21#fcc7f4076df47bbee454256dfc99994782eb4c21" +source = "git+https://github.com/storytold/craft-libs?rev=16d838105b07965832bb43132880176f299634d5#16d838105b07965832bb43132880176f299634d5" dependencies = [ "encoding_rs", "flate2", diff --git a/Cargo.toml b/Cargo.toml index 556a31c102..8e664a864c 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -27,7 +27,7 @@ craft-window = { git = "https://github.com/storytold/craft-libs", rev = "c5a1cbf # HDR gain maps: ISO 21496-1 and hdrgm metadata, compute and apply (moved from crates/codecs; craft-libs#904). craft-gainmap = { git = "https://github.com/storytold/craft-libs", rev = "9dcbd90c7d16e1a668b3afa057e940e2db328b93" } # PSD/PSB: the header, colour mode data and image resources (craft-libs#885). -craft-psd = { git = "https://github.com/storytold/craft-libs", rev = "fcc7f4076df47bbee454256dfc99994782eb4c21" } +craft-psd = { git = "https://github.com/storytold/craft-libs", rev = "16d838105b07965832bb43132880176f299634d5" } # internal lightcraft-denoise-core = { path = "crates/denoise-core" } lightcraft-denoise = { path = "crates/denoise", default-features = false } From cf1e8b6a7eaab8681faf03ab9bf46d3b55ede15c Mon Sep 17 00:00:00 2001 From: "Dylan M. Taylor" <dylan@dylanmtaylor.com> Date: Sun, 15 Nov 2026 18:58:58 +0000 Subject: [PATCH 41/61] Keep merged plist and MIME lock entries in Cargo order --- Cargo.lock | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Cargo.lock b/Cargo.lock index 0153dc8b92..083d21803e 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -3935,8 +3935,8 @@ dependencies = [ "chrono", "craft-docpath", "craft-heif", - "craft-plist", "craft-mime", + "craft-plist", "craft-tiff", "crc32fast", "fs4", From b08bbae18e50ee51ef1d85295a0f6b345517e9d3 Mon Sep 17 00:00:00 2001 From: "Dylan M. Taylor" <dylan@dylanmtaylor.com> Date: Sun, 15 Nov 2026 19:12:44 +0000 Subject: [PATCH 42/61] Use coverage settle budget for asynchronous UI checks --- crates/ui-egui/src/headless/tests.rs | 2 +- crates/ui-egui/src/tests/activity.rs | 2 +- crates/ui-egui/src/tests/preview_limit.rs | 6 +++--- crates/ui-egui/src/tests/slideshow.rs | 6 +++--- 4 files changed, 8 insertions(+), 8 deletions(-) diff --git a/crates/ui-egui/src/headless/tests.rs b/crates/ui-egui/src/headless/tests.rs index eb05be0c4c..157f389334 100644 --- a/crates/ui-egui/src/headless/tests.rs +++ b/crates/ui-egui/src/headless/tests.rs @@ -2343,7 +2343,7 @@ fn preview_only_raw_shows_badge_and_notices() { // …which re-reads the file and says what came of it (a demo photo has none to re-read) let r = h.request("ui.clickWidget", json!({"id": "button:reloadPreviewOnly:info"}), t); assert_eq!(r["ok"], true, "{r}"); - h.settle(SETTLE); + // Read the timed toast before settling advances the simulated clock past its expiry. assert_eq!(h.app.ui.toast.clone().map(|x| x.0).as_deref(), Some("This raw variant still can't be decoded")); // a regular photo: no notice h.request("engine.execute", json!({"command": "library.select", "params": {"ids": [other.0]}}), t); diff --git a/crates/ui-egui/src/tests/activity.rs b/crates/ui-egui/src/tests/activity.rs index b353405ffc..f8f32607a2 100644 --- a/crates/ui-egui/src/tests/activity.rs +++ b/crates/ui-egui/src/tests/activity.rs @@ -509,7 +509,7 @@ fn batch_merge_runs_each_set_in_turn() { let rows = h.app.session.activity.list(); assert_eq!((rows.len(), rows.first().map(|r| r.kind)), (1, Some("merge"))); // the first merge finishes and the second starts by itself - assert!(h.step_until(T, |h| h.app.merge.batch.len() == 1 && h.app.merge.final_task.is_some())); + assert!(h.step_until(super::ui_settle_timeout(), |h| h.app.merge.batch.len() == 1 && h.app.merge.final_task.is_some())); assert_eq!(h.app.session.catalog.len(), 10); // cancelling the second drops the third let rows = h.app.session.activity.list(); diff --git a/crates/ui-egui/src/tests/preview_limit.rs b/crates/ui-egui/src/tests/preview_limit.rs index 5d1c1b7d0e..8d19a71734 100644 --- a/crates/ui-egui/src/tests/preview_limit.rs +++ b/crates/ui-egui/src/tests/preview_limit.rs @@ -162,7 +162,7 @@ mod in_the_loupe { let mut h = Headless::new(app, size, 1.0); let r = h.request("ui.set", json!({"view": "detail", "right": "none", "filmstrip": false}), T); assert_eq!(r["ok"], true, "{r}"); - h.settle(SETTLE); + h.settle(super::super::ui_settle_timeout()); let native = { let id = h.app.session.active().expect("a photo is open"); let p = h.app.session.catalog.photo(id).expect("it is in the catalog"); @@ -848,7 +848,7 @@ mod in_the_loupe { #[test] fn pinch_display_fit_does_not_follow_the_old_photo() { let (mut h, _) = demo_detail_in([1400.0, 900.0]); - assert!(h.settle(SETTLE)); + assert!(h.settle(super::super::ui_settle_timeout())); let old = h.app.session.active().unwrap(); let next = h.app.session.visible_cloned().into_iter().find(|id| *id != old).unwrap(); let initial_fit = drawn_fit(&h); @@ -874,7 +874,7 @@ mod in_the_loupe { fn pinch_display_fit_is_shared_with_a_hover_during_the_hold() { let (mut h, _) = demo_detail_in([1400.0, 900.0]); assert_eq!(h.request("engine.execute", json!({"command": "panel.profiles"}), T)["ok"], true); - assert!(h.settle(SETTLE)); + assert!(h.settle(super::super::ui_settle_timeout())); let initial_fit = drawn_fit(&h); let work = std::rc::Rc::new(std::cell::RefCell::new(PinchWork::default())); h.app.renderer.set_offload(Box::new(PinchOffload(work.clone()))); diff --git a/crates/ui-egui/src/tests/slideshow.rs b/crates/ui-egui/src/tests/slideshow.rs index 4e230fe7a5..1659005ab7 100644 --- a/crates/ui-egui/src/tests/slideshow.rs +++ b/crates/ui-egui/src/tests/slideshow.rs @@ -457,7 +457,7 @@ fn a_photo_deleted_while_it_plays_does_not_stall_the_slideshow() { run(&mut h, "photo.delete", json!({"ids": [next.0]})); run(&mut h, "photo.deletePermanently", json!({"ids": [next.0]})); assert!(h.app.session.catalog.photo(next).is_none()); - assert!(h.step_until(SETTLE, |h| h.app.ui.slideshow.as_ref().is_some_and(|r| r.play.position().0 >= 3)), "it plays on"); + assert!(h.step_until(super::ui_settle_timeout(), |h| h.app.ui.slideshow.as_ref().is_some_and(|r| r.play.position().0 >= 3)), "it plays on"); assert!(photos.len() > 3); h.settle(SETTLE); } @@ -630,7 +630,7 @@ fn settings_shows_the_slide_layout_and_a_live_preview() { assert!(has(&h, w), "{w}"); } // the preview is the composed slide, rendered off the UI thread - assert!(h.step_until(SETTLE, |h| h.app.renderer.textures.get(&Slot::SlidePreview).is_some_and(|t| t.photo == first))); + assert!(h.step_until(super::ui_settle_timeout(), |h| h.app.renderer.textures.get(&Slot::SlidePreview).is_some_and(|t| t.photo == first))); // a checkbox goes through slideshow.layout, and its controls appear (scrolled into view) reveal(&mut h, "check:settings.slideshowShadow"); let r = h.request("ui.clickWidget", json!({"id": "check:settings.slideshowShadow"}), T); @@ -641,7 +641,7 @@ fn settings_shows_the_slide_layout_and_a_live_preview() { // a changed layout renders the preview again (once it has settled) let before = h.app.renderer.textures.get(&Slot::SlidePreview).map(|t| t.key); run(&mut h, "slideshow.layout", json!({"margins": 0.2, "backdropColor": "#00ff00"})); - assert!(h.step_until(SETTLE, |h| h.app.renderer.textures.get(&Slot::SlidePreview).map(|t| t.key) != before)); + assert!(h.step_until(super::ui_settle_timeout(), |h| h.app.renderer.textures.get(&Slot::SlidePreview).map(|t| t.key) != before)); h.step(); // (the preview is pinned above the page: in view already) reveal(&mut h, "slideshow:preview"); From 47742598afbfca8f5c61c6b33ba5547de59b4835 Mon Sep 17 00:00:00 2001 From: "Dylan M. Taylor" <dylan@dylanmtaylor.com> Date: Sun, 15 Nov 2026 19:12:44 +0000 Subject: [PATCH 43/61] Use coverage settle budget for asynchronous UI checks --- crates/ui-egui/src/headless/tests.rs | 2 +- crates/ui-egui/src/tests/activity.rs | 2 +- crates/ui-egui/src/tests/preview_limit.rs | 6 +++--- crates/ui-egui/src/tests/slideshow.rs | 6 +++--- 4 files changed, 8 insertions(+), 8 deletions(-) diff --git a/crates/ui-egui/src/headless/tests.rs b/crates/ui-egui/src/headless/tests.rs index eb05be0c4c..157f389334 100644 --- a/crates/ui-egui/src/headless/tests.rs +++ b/crates/ui-egui/src/headless/tests.rs @@ -2343,7 +2343,7 @@ fn preview_only_raw_shows_badge_and_notices() { // …which re-reads the file and says what came of it (a demo photo has none to re-read) let r = h.request("ui.clickWidget", json!({"id": "button:reloadPreviewOnly:info"}), t); assert_eq!(r["ok"], true, "{r}"); - h.settle(SETTLE); + // Read the timed toast before settling advances the simulated clock past its expiry. assert_eq!(h.app.ui.toast.clone().map(|x| x.0).as_deref(), Some("This raw variant still can't be decoded")); // a regular photo: no notice h.request("engine.execute", json!({"command": "library.select", "params": {"ids": [other.0]}}), t); diff --git a/crates/ui-egui/src/tests/activity.rs b/crates/ui-egui/src/tests/activity.rs index b353405ffc..f8f32607a2 100644 --- a/crates/ui-egui/src/tests/activity.rs +++ b/crates/ui-egui/src/tests/activity.rs @@ -509,7 +509,7 @@ fn batch_merge_runs_each_set_in_turn() { let rows = h.app.session.activity.list(); assert_eq!((rows.len(), rows.first().map(|r| r.kind)), (1, Some("merge"))); // the first merge finishes and the second starts by itself - assert!(h.step_until(T, |h| h.app.merge.batch.len() == 1 && h.app.merge.final_task.is_some())); + assert!(h.step_until(super::ui_settle_timeout(), |h| h.app.merge.batch.len() == 1 && h.app.merge.final_task.is_some())); assert_eq!(h.app.session.catalog.len(), 10); // cancelling the second drops the third let rows = h.app.session.activity.list(); diff --git a/crates/ui-egui/src/tests/preview_limit.rs b/crates/ui-egui/src/tests/preview_limit.rs index 5d1c1b7d0e..8d19a71734 100644 --- a/crates/ui-egui/src/tests/preview_limit.rs +++ b/crates/ui-egui/src/tests/preview_limit.rs @@ -162,7 +162,7 @@ mod in_the_loupe { let mut h = Headless::new(app, size, 1.0); let r = h.request("ui.set", json!({"view": "detail", "right": "none", "filmstrip": false}), T); assert_eq!(r["ok"], true, "{r}"); - h.settle(SETTLE); + h.settle(super::super::ui_settle_timeout()); let native = { let id = h.app.session.active().expect("a photo is open"); let p = h.app.session.catalog.photo(id).expect("it is in the catalog"); @@ -848,7 +848,7 @@ mod in_the_loupe { #[test] fn pinch_display_fit_does_not_follow_the_old_photo() { let (mut h, _) = demo_detail_in([1400.0, 900.0]); - assert!(h.settle(SETTLE)); + assert!(h.settle(super::super::ui_settle_timeout())); let old = h.app.session.active().unwrap(); let next = h.app.session.visible_cloned().into_iter().find(|id| *id != old).unwrap(); let initial_fit = drawn_fit(&h); @@ -874,7 +874,7 @@ mod in_the_loupe { fn pinch_display_fit_is_shared_with_a_hover_during_the_hold() { let (mut h, _) = demo_detail_in([1400.0, 900.0]); assert_eq!(h.request("engine.execute", json!({"command": "panel.profiles"}), T)["ok"], true); - assert!(h.settle(SETTLE)); + assert!(h.settle(super::super::ui_settle_timeout())); let initial_fit = drawn_fit(&h); let work = std::rc::Rc::new(std::cell::RefCell::new(PinchWork::default())); h.app.renderer.set_offload(Box::new(PinchOffload(work.clone()))); diff --git a/crates/ui-egui/src/tests/slideshow.rs b/crates/ui-egui/src/tests/slideshow.rs index 4e230fe7a5..1659005ab7 100644 --- a/crates/ui-egui/src/tests/slideshow.rs +++ b/crates/ui-egui/src/tests/slideshow.rs @@ -457,7 +457,7 @@ fn a_photo_deleted_while_it_plays_does_not_stall_the_slideshow() { run(&mut h, "photo.delete", json!({"ids": [next.0]})); run(&mut h, "photo.deletePermanently", json!({"ids": [next.0]})); assert!(h.app.session.catalog.photo(next).is_none()); - assert!(h.step_until(SETTLE, |h| h.app.ui.slideshow.as_ref().is_some_and(|r| r.play.position().0 >= 3)), "it plays on"); + assert!(h.step_until(super::ui_settle_timeout(), |h| h.app.ui.slideshow.as_ref().is_some_and(|r| r.play.position().0 >= 3)), "it plays on"); assert!(photos.len() > 3); h.settle(SETTLE); } @@ -630,7 +630,7 @@ fn settings_shows_the_slide_layout_and_a_live_preview() { assert!(has(&h, w), "{w}"); } // the preview is the composed slide, rendered off the UI thread - assert!(h.step_until(SETTLE, |h| h.app.renderer.textures.get(&Slot::SlidePreview).is_some_and(|t| t.photo == first))); + assert!(h.step_until(super::ui_settle_timeout(), |h| h.app.renderer.textures.get(&Slot::SlidePreview).is_some_and(|t| t.photo == first))); // a checkbox goes through slideshow.layout, and its controls appear (scrolled into view) reveal(&mut h, "check:settings.slideshowShadow"); let r = h.request("ui.clickWidget", json!({"id": "check:settings.slideshowShadow"}), T); @@ -641,7 +641,7 @@ fn settings_shows_the_slide_layout_and_a_live_preview() { // a changed layout renders the preview again (once it has settled) let before = h.app.renderer.textures.get(&Slot::SlidePreview).map(|t| t.key); run(&mut h, "slideshow.layout", json!({"margins": 0.2, "backdropColor": "#00ff00"})); - assert!(h.step_until(SETTLE, |h| h.app.renderer.textures.get(&Slot::SlidePreview).map(|t| t.key) != before)); + assert!(h.step_until(super::ui_settle_timeout(), |h| h.app.renderer.textures.get(&Slot::SlidePreview).map(|t| t.key) != before)); h.step(); // (the preview is pinned above the page: in view already) reveal(&mut h, "slideshow:preview"); From 829ed6f69a50ff9b0070c1bff87897a24f484532 Mon Sep 17 00:00:00 2001 From: "Dylan M. Taylor" <dylan@dylanmtaylor.com> Date: Sun, 15 Nov 2026 17:53:24 -0500 Subject: [PATCH 44/61] Delegate print PDF serialization to shared bounded raster writer --- Cargo.lock | 19 ++ Cargo.toml | 1 + crates/engine/Cargo.toml | 1 + crates/engine/src/print_pdf.rs | 341 ++------------------------------- 4 files changed, 34 insertions(+), 328 deletions(-) diff --git a/Cargo.lock b/Cargo.lock index b322552f35..f2d6118f8d 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -1346,6 +1346,15 @@ dependencies = [ "encoding_rs", ] +[[package]] +name = "craft-pdf" +version = "0.1.0" +source = "git+https://github.com/storytold/craft-libs?rev=2651dbeb2b13f621db23f65347380e7f26e316f0#2651dbeb2b13f621db23f65347380e7f26e316f0" +dependencies = [ + "flate2", + "roxmltree", +] + [[package]] name = "craft-psd" version = "0.1.0" @@ -3969,6 +3978,7 @@ dependencies = [ "craft-docpath", "craft-heif", "craft-mime", + "craft-pdf", "craft-tiff 0.1.0 (git+https://github.com/storytold/craft-libs?rev=94777dcf7f8962476e96b049d08d22e25b9330c2)", "crc32fast", "fs4", @@ -6095,6 +6105,15 @@ dependencies = [ "windows-sys 0.52.0", ] +[[package]] +name = "roxmltree" +version = "0.21.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "9da7f59328b09405b181fee1018925fad50f157afb43c0c0f5c522c256dd5907" +dependencies = [ + "memchr", +] + [[package]] name = "rsa" version = "0.9.10" diff --git a/Cargo.toml b/Cargo.toml index ec2701598a..c0ca9ebea3 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -10,6 +10,7 @@ rust-version = "1.95" repository = "https://github.com/storytold/lightcraft" [workspace.dependencies] +craft-pdf-print = { package = "craft-pdf", git = "https://github.com/storytold/craft-libs", rev = "2651dbeb2b13f621db23f65347380e7f26e316f0", default-features = false, features = ["write-raster"] } craft-ui = { git = "https://github.com/storytold/craft-libs", rev = "c5a1cbfb5f9049f9270955caffb5bee5997aebf7", features = ["serde"] } craft-docpath = { version = "0.1.0", git = "https://github.com/storytold/craft-libs", rev = "c5a1cbfb5f9049f9270955caffb5bee5997aebf7" } # Canon CRW decoder shared with the other Craft apps diff --git a/crates/engine/Cargo.toml b/crates/engine/Cargo.toml index dd8a582d92..0715ce4dc3 100644 --- a/crates/engine/Cargo.toml +++ b/crates/engine/Cargo.toml @@ -9,6 +9,7 @@ description = "LightCraft engine: session, command registry, history, render job workspace = true [dependencies] +craft-pdf-print.workspace = true craft-mime = { workspace = true } # Paths stored in a Lightroom catalog are followed only to local files or the catalog's share. craft-docpath = { workspace = true } diff --git a/crates/engine/src/print_pdf.rs b/crates/engine/src/print_pdf.rs index abce4061e3..43db29910d 100644 --- a/crates/engine/src/print_pdf.rs +++ b/crates/engine/src/print_pdf.rs @@ -1,334 +1,30 @@ -//! A small PDF writer for print output: pages of a given size in points, each with raster images -//! placed on it, tagged with their ICC profile (`ICCBased`) so the numbers mean the same colour in -//! every reader and RIP, Flate-compressed (lossless) at 8 or 16 bits per component, or carried as -//! JPEG (`DCTDecode`) where small files matter more than exact samples. Optionally an output intent: -//! the printing condition (the printer / paper profile) the file was made for, as PDF/X readers -//! expect it in the catalog. Profiles shared by several images are written once. -//! -//! The file is PDF 1.6 (16-bit images need 1.5): classic cross-reference table, no object streams, -//! deterministic (no dates or IDs), so the same pages always give the same bytes. -//! -//! Sources: ISO 32000-1:2008 (§7.3 objects, §7.5 file structure, §8.6.5.5 ICCBased colour spaces, -//! §8.9 images, §14.11.5 output intents). Own design. - -use std::collections::HashMap; +//! Print-page policy and adaptation to shared PDF raster serialization. +//! Layout, rendering, profile choice and job limits stay in the app. +pub use craft_pdf_print::write_raster::print::{ImageData, OutputIntent, PdfImage, PdfPage, Placement}; +#[cfg(test)] use std::sync::Arc; -/// Pages per document: a print job beyond this is a mistake, not a book. -pub const MAX_PAGES: usize = 1000; -/// Images per page. -pub const MAX_IMAGES_PER_PAGE: usize = 256; -/// Largest page side in points (200 inches): more than any printer's roll. -pub const MAX_PAGE_POINTS: f64 = 14_400.0; -/// Largest image, in pixels per side. -pub const MAX_IMAGE_SIDE: u32 = 65_535; - -/// How an image's samples are stored. -#[derive(Clone, Debug, PartialEq)] -pub enum ImageData { - /// Interleaved samples, `bits` (8 or 16) per component, 16-bit values big-endian: compressed - /// losslessly in the file. - Raw { bits: u8, samples: Vec<u8> }, - /// A baseline JPEG stream, copied into the file as it is. - Jpeg(Vec<u8>), - /// Samples already compressed with zlib (see [`PdfImage::deflated`]), `bits` per component. - Flate { bits: u8, data: Vec<u8> }, -} - -/// A raster image and the colour space its samples are in. -#[derive(Clone, Debug, PartialEq)] -pub struct PdfImage { - pub width: u32, - pub height: u32, - /// Components per pixel: 1 (grey), 3 (RGB) or 4 (CMYK). - pub channels: u8, - pub data: ImageData, - /// The ICC profile the samples are in; without one the image is device colour. - pub icc: Option<Arc<Vec<u8>>>, -} - -impl PdfImage { - /// An image from interleaved 16-bit samples. - pub fn from_u16(width: u32, height: u32, channels: u8, samples: &[u16], icc: Option<Arc<Vec<u8>>>) -> PdfImage { - let bytes = samples.iter().flat_map(|v| v.to_be_bytes()).collect(); - PdfImage { width, height, channels, data: ImageData::Raw { bits: 16, samples: bytes }, icc } - } - - /// The same image with its samples compressed now (checked first), so a long print doesn't - /// hold every page's uncompressed samples until the file is written. - pub fn deflated(self) -> Result<PdfImage, String> { - self.check()?; - let data = match self.data { - ImageData::Raw { bits, samples } => ImageData::Flate { bits, data: deflate(&samples) }, - other => other, - }; - Ok(PdfImage { data, ..self }) - } - - fn check(&self) -> Result<(), String> { - if self.width == 0 || self.height == 0 || self.width > MAX_IMAGE_SIDE || self.height > MAX_IMAGE_SIDE { - return Err(format!("an image of {} × {} pixels can't be written", self.width, self.height)); - } - if !matches!(self.channels, 1 | 3 | 4) { - return Err(format!("images have 1, 3 or 4 components, not {}", self.channels)); - } - match &self.data { - ImageData::Raw { bits, samples } => { - if !matches!(bits, 8 | 16) { - return Err(format!("images have 8 or 16 bits per component, not {bits}")); - } - let want = u64::from(self.width) * u64::from(self.height) * u64::from(self.channels) * u64::from(bits / 8); - if samples.len() as u64 != want { - return Err(format!("the image needs {want} bytes of samples, not {}", samples.len())); - } - } - ImageData::Jpeg(data) => { - if !data.starts_with(&[0xFF, 0xD8]) { - return Err("the image isn't a JPEG stream".into()); - } - } - ImageData::Flate { bits, data } => { - if !matches!(bits, 8 | 16) || data.is_empty() { - return Err("a compressed image has 8 or 16 bits per component and some data".into()); - } - } - } - Ok(()) - } -} - -/// Where an image goes on its page, in points from the page's bottom-left corner. -#[derive(Clone, Copy, Debug, PartialEq)] -pub struct Placement { - pub x: f64, - pub y: f64, - pub width: f64, - pub height: f64, -} - -/// One page: its size in points and the images on it, drawn in order (later ones on top). -#[derive(Clone, Debug, PartialEq)] -pub struct PdfPage { - pub width: f64, - pub height: f64, - pub images: Vec<(PdfImage, Placement)>, -} - -/// The printing condition the document is made for (PDF/X-style output intent). -#[derive(Clone, Debug, PartialEq)] -pub struct OutputIntent { - /// The printer / paper profile. - pub icc: Arc<Vec<u8>>, - /// Its components: 1, 3 or 4. - pub channels: u8, - /// A name for the condition (the profile's description). - pub condition: String, -} - -/// Document-level settings. #[derive(Clone, Debug, Default, PartialEq)] pub struct PdfInfo { pub title: Option<String>, pub output_intent: Option<OutputIntent>, } -fn finite(v: f64) -> bool { - v.is_finite() -} - -/// A number as PDF writes it: up to four decimals, no exponent, no trailing zeros. -fn num(v: f64) -> String { - let s = format!("{:.4}", if finite(v) { v } else { 0.0 }); - let s = s.trim_end_matches('0').trim_end_matches('.'); - if s == "-0" || s.is_empty() { "0".into() } else { s.into() } -} - -/// A text string: plain ASCII as a literal string, anything else as UTF-16BE with a byte order mark. -fn text(s: &str) -> String { - if s.bytes().all(|b| (0x20..0x7f).contains(&b)) { - let mut out = String::with_capacity(s.len() + 2); - out.push('('); - for c in s.chars() { - if matches!(c, '(' | ')' | '\\') { - out.push('\\'); - } - out.push(c); - } - out.push(')'); - out - } else { - let mut out = String::from("<FEFF"); - for unit in s.encode_utf16() { - out.push_str(&format!("{unit:04X}")); - } - out.push('>'); - out - } -} - -struct Writer { - out: Vec<u8>, - offsets: Vec<usize>, -} - -impl Writer { - /// Reserve an object number (filled later by [`Writer::object`]). - fn reserve(&mut self) -> usize { - self.offsets.push(0); - self.offsets.len() - } - - fn object(&mut self, id: usize, dict: &str, stream: Option<&[u8]>) { - if let Some(slot) = self.offsets.get_mut(id.wrapping_sub(1)) { - *slot = self.out.len(); - } - self.out.extend_from_slice(format!("{id} 0 obj\n{dict}").as_bytes()); - if let Some(data) = stream { - self.out.extend_from_slice(b"\nstream\n"); - self.out.extend_from_slice(data); - self.out.extend_from_slice(b"\nendstream"); - } - self.out.extend_from_slice(b"\nendobj\n"); - } -} - -fn deflate(data: &[u8]) -> Vec<u8> { - miniz_oxide::deflate::compress_to_vec_zlib(data, 6) -} - -/// Write a document. Errors name the first page or image that can't be written. pub fn write(pages: &[PdfPage], info: &PdfInfo) -> Result<Vec<u8>, String> { - if pages.is_empty() { - return Err("there are no pages to write".into()); - } - if pages.len() > MAX_PAGES { - return Err(format!("a document holds at most {MAX_PAGES} pages")); - } - for (n, page) in pages.iter().enumerate() { - let n = n + 1; - if !(finite(page.width) && finite(page.height)) - || page.width <= 0.0 - || page.height <= 0.0 - || page.width > MAX_PAGE_POINTS - || page.height > MAX_PAGE_POINTS - { - return Err(format!("page {n} has no usable size")); - } - if page.images.len() > MAX_IMAGES_PER_PAGE { - return Err(format!("page {n} has more than {MAX_IMAGES_PER_PAGE} images")); - } - for (image, at) in &page.images { - image.check().map_err(|e| format!("page {n}: {e}"))?; - if ![at.x, at.y, at.width, at.height].into_iter().all(finite) || at.width <= 0.0 || at.height <= 0.0 { - return Err(format!("page {n}: an image has no usable placement")); - } - } - } - if let Some(intent) = &info.output_intent - && !matches!(intent.channels, 1 | 3 | 4) - { - return Err("the output intent's profile has 1, 3 or 4 components".into()); - } - - let mut w = Writer { out: Vec::new(), offsets: Vec::new() }; - w.out.extend_from_slice(b"%PDF-1.6\n%\xE2\xE3\xCF\xD3\n"); - let catalog = w.reserve(); - let pages_id = w.reserve(); - let info_id = w.reserve(); - - // ICC profiles, each written once (keyed by content) with its component count - let mut profiles: HashMap<Vec<u8>, usize> = HashMap::new(); - let mut profile = |w: &mut Writer, icc: &Arc<Vec<u8>>, n: u8| -> usize { - if let Some(&id) = profiles.get(icc.as_slice()) { - return id; - } - let id = w.reserve(); - let data = deflate(icc); - let alternate = match n { - 1 => "/DeviceGray", - 4 => "/DeviceCMYK", - _ => "/DeviceRGB", - }; - w.object(id, &format!("<< /N {n} /Alternate {alternate} /Filter /FlateDecode /Length {} >>", data.len()), Some(&data)); - profiles.insert(icc.to_vec(), id); - id - }; - - let intent_id = info.output_intent.as_ref().map(|intent| profile(&mut w, &intent.icc, intent.channels)); - - let mut kids = Vec::with_capacity(pages.len()); - for page in pages { - let page_id = w.reserve(); - let mut xobjects = String::new(); - let mut content = String::new(); - for (k, (image, at)) in page.images.iter().enumerate() { - let space = match &image.icc { - Some(icc) => format!("[/ICCBased {} 0 R]", profile(&mut w, icc, image.channels)), - None => match image.channels { - 1 => "/DeviceGray".into(), - 4 => "/DeviceCMYK".into(), - _ => "/DeviceRGB".into(), - }, - }; - let id = w.reserve(); - let (bits, filter, data): (u8, &str, std::borrow::Cow<[u8]>) = match &image.data { - ImageData::Raw { bits, samples } => (*bits, "/FlateDecode", deflate(samples).into()), - ImageData::Flate { bits, data } => (*bits, "/FlateDecode", data.as_slice().into()), - ImageData::Jpeg(jpeg) => (8, "/DCTDecode", jpeg.as_slice().into()), - }; - w.object( - id, - &format!( - "<< /Type /XObject /Subtype /Image /Width {} /Height {} /ColorSpace {space} /BitsPerComponent {bits} /Filter {filter} /Length {} >>", - image.width, - image.height, - data.len() - ), - Some(&data), - ); - xobjects.push_str(&format!("/Im{k} {id} 0 R ")); - content.push_str(&format!("q {} 0 0 {} {} {} cm /Im{k} Do Q\n", num(at.width), num(at.height), num(at.x), num(at.y))); - } - let content_id = w.reserve(); - let stream = deflate(content.as_bytes()); - w.object(content_id, &format!("<< /Filter /FlateDecode /Length {} >>", stream.len()), Some(&stream)); - w.object( - page_id, - &format!( - "<< /Type /Page /Parent {pages_id} 0 R /MediaBox [0 0 {} {}] /Resources << /XObject << {xobjects}>> >> /Contents {content_id} 0 R >>", - num(page.width), - num(page.height) - ), - None, - ); - kids.push(format!("{page_id} 0 R")); - } - w.object(pages_id, &format!("<< /Type /Pages /Count {} /Kids [{}] >>", kids.len(), kids.join(" ")), None); - - let intents = match (&info.output_intent, intent_id) { - (Some(intent), Some(id)) => format!( - " /OutputIntents [<< /Type /OutputIntent /S /GTS_PDFX /OutputConditionIdentifier (Custom) /Info {} /DestOutputProfile {id} 0 R >>]", - text(&intent.condition) - ), - _ => String::new(), - }; - w.object(catalog, &format!("<< /Type /Catalog /Pages {pages_id} 0 R{intents} >>"), None); - let title = info.title.as_deref().map(|t| format!(" /Title {}", text(t))).unwrap_or_default(); - w.object(info_id, &format!("<< /Producer (LightCraft){title} >>"), None); - - let xref = w.out.len(); - let mut table = format!("xref\n0 {}\n0000000000 65535 f \n", w.offsets.len() + 1); - for offset in &w.offsets { - table.push_str(&format!("{offset:010} 00000 n \n")); - } - table.push_str(&format!("trailer\n<< /Size {} /Root {catalog} 0 R /Info {info_id} 0 R >>\nstartxref\n{xref}\n%%EOF\n", w.offsets.len() + 1)); - w.out.extend_from_slice(table.as_bytes()); - Ok(w.out) + craft_pdf_print::write_raster::print::write( + pages, + &craft_pdf_print::write_raster::print::PdfInfo { + title: info.title.clone(), + output_intent: info.output_intent.clone(), + producer: "LightCraft".into(), + }, + ) } #[cfg(test)] mod tests { use super::*; + use craft_pdf_print::write_raster::print::MAX_PAGES; use lightcraft_codecs::NamedSpace; /// The body of object `id` (dictionary and raw stream bytes), found through the xref table. @@ -506,15 +202,4 @@ mod tests { let info = PdfInfo { title: None, output_intent: Some(OutputIntent { icc: srgb(), channels: 2, condition: String::new() }) }; assert!(write(&[page(vec![])], &info).is_err()); } - - #[test] - fn numbers_and_strings() { - assert_eq!(num(612.0), "612"); - assert_eq!(num(72.5), "72.5"); - assert_eq!(num(-0.00001), "0"); - assert_eq!(num(f64::NAN), "0"); - assert_eq!(num(1.0 / 3.0), "0.3333"); - assert_eq!(text("a(b)c\\"), "(a\\(b\\)c\\\\)"); - assert_eq!(text("é"), "<FEFF00E9>"); - } } From 310b26503decad7fdea035cde7d108464e048757 Mon Sep 17 00:00:00 2001 From: "Dylan M. Taylor" <dylan@dylanmtaylor.com> Date: Sun, 15 Nov 2026 18:03:13 -0500 Subject: [PATCH 45/61] codecs: delegate ICC embedding normalization to craft-cms --- Cargo.lock | 2 +- Cargo.toml | 2 +- crates/codecs/src/icc.rs | 53 +--------------------------------------- 3 files changed, 3 insertions(+), 54 deletions(-) diff --git a/Cargo.lock b/Cargo.lock index b322552f35..762ed87290 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -1190,7 +1190,7 @@ dependencies = [ [[package]] name = "craft-cms" version = "0.1.0" -source = "git+https://github.com/storytold/craft-libs?rev=94777dcf7f8962476e96b049d08d22e25b9330c2#94777dcf7f8962476e96b049d08d22e25b9330c2" +source = "git+https://github.com/storytold/craft-libs?rev=7306195df57e7483a58600fa216bac9319030d86#7306195df57e7483a58600fa216bac9319030d86" dependencies = [ "md-5", "rayon", diff --git a/Cargo.toml b/Cargo.toml index ec2701598a..8e66939143 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -14,7 +14,7 @@ craft-ui = { git = "https://github.com/storytold/craft-libs", rev = "c5a1cbfb5f9 craft-docpath = { version = "0.1.0", git = "https://github.com/storytold/craft-libs", rev = "c5a1cbfb5f9049f9270955caffb5bee5997aebf7" } # Canon CRW decoder shared with the other Craft apps craft-crw = { git = "https://github.com/storytold/craft-libs", rev = "94777dcf7f8962476e96b049d08d22e25b9330c2" } -craft-cms = { git = "https://github.com/storytold/craft-libs", rev = "94777dcf7f8962476e96b049d08d22e25b9330c2" } +craft-cms = { git = "https://github.com/storytold/craft-libs", rev = "7306195df57e7483a58600fa216bac9319030d86" } craft-mime = { git = "https://github.com/storytold/craft-libs", rev = "f0f4758c01581d79577b9bf5046c06f4e77b1f18", version = "0.1.0" } craft-gif = { git = "https://github.com/storytold/craft-libs", rev = "b77af389f30bb10de10d8436ca9b39fe94e3bb67", features = ["frames"] } craft-jxl = { git = "https://github.com/storytold/craft-libs", rev = "b77af389f30bb10de10d8436ca9b39fe94e3bb67", default-features = false, features = ["decode", "encode"] } diff --git a/crates/codecs/src/icc.rs b/crates/codecs/src/icc.rs index 2dcbe36deb..111f78be58 100644 --- a/crates/codecs/src/icc.rs +++ b/crates/codecs/src/icc.rs @@ -132,58 +132,7 @@ pub fn write_matrix_trc(space: &RgbSpace, trc: &Trc) -> Vec<u8> { }; p.copyright = "No copyright, use freely".to_string(); let encoded = p.with_encoded_bytes(); - align_tags(&fixed_date(encoded.to_bytes().to_vec())) -} - -/// Zero the header's creation date/time (ICC.1 §7.2.8, bytes 24..36) so a profile's bytes depend -/// only on its colour space and curve. `moxcms` stamps the wall clock there on every `encode` -/// (ignoring `ColorProfile::creation_date_time`), which made two exports of one photo differ in -/// the embedded profile and nowhere else, so output hashes could not be compared (#180). Readers -/// do not interpret the field; all zeros is the conventional "unspecified" value. -fn fixed_date(mut b: Vec<u8>) -> Vec<u8> { - if let Some(date) = b.get_mut(24..36) { - date.fill(0); - } - b -} - -/// Re-lay a profile's tag data on 4-byte boundaries (ICC.1 §7.3.1). The encoder packs tags back to -/// back, so a tag of odd length (e.g. a `mluc` description with an odd number of characters) -/// misaligns every following tag — which some readers (macOS ImageIO for PNG `iCCP`) reject. -fn align_tags(b: &[u8]) -> Vec<u8> { - let be = |i: usize| b.get(i..i + 4).map(|s| u32::from_be_bytes([s[0], s[1], s[2], s[3]]) as usize); - let Some(n) = be(128) else { return b.to_vec() }; - let table_end = 132 + 12 * n; - let tags: Option<Vec<(usize, usize)>> = (0..n).map(|t| Some((be(132 + 12 * t + 4)?, be(132 + 12 * t + 8)?))).collect(); - let Some(tags) = tags.filter(|t| table_end <= b.len() && t.iter().all(|&(o, l)| o >= table_end && o + l <= b.len())) else { - return b.to_vec(); - }; - let mut out = b[..table_end].to_vec(); - let mut placed: Vec<((usize, usize), usize)> = Vec::new(); - for (t, &(off, len)) in tags.iter().enumerate() { - let new_off = match placed.iter().find(|(k, _)| *k == (off, len)) { - // tags sharing data keep sharing it - Some(&(_, o)) => o, - None => { - while !out.len().is_multiple_of(4) { - out.push(0); - } - let o = out.len(); - out.extend_from_slice(&b[off..off + len]); - placed.push(((off, len), o)); - o - } - }; - out[132 + 12 * t + 4..132 + 12 * t + 8].copy_from_slice(&(new_off as u32).to_be_bytes()); - } - while !out.len().is_multiple_of(4) { - out.push(0); - } - let size = out.len() as u32; - out[0..4].copy_from_slice(&size.to_be_bytes()); - // the profile ID (MD5) would no longer match: clear it (= "not computed") - out[84..100].fill(0); - out + craft_cms::normalize_for_embedding(encoded.to_bytes().to_vec()) } /// A profile for one of the well-known spaces with its standard curve. From cac5358baa2a2d2f39395947b631213c47b05ce5 Mon Sep 17 00:00:00 2001 From: "Dylan M. Taylor" <dylan@dylanmtaylor.com> Date: Sun, 15 Nov 2026 18:25:13 -0500 Subject: [PATCH 46/61] Regenerate Flatpak sources for shared print PDF dependency --- packaging/linux/flatpak/cargo-sources.json | 1985 +++++++++++++++++--- 1 file changed, 1735 insertions(+), 250 deletions(-) diff --git a/packaging/linux/flatpak/cargo-sources.json b/packaging/linux/flatpak/cargo-sources.json index 8d723f2f41..47d8e3021f 100644 --- a/packaging/linux/flatpak/cargo-sources.json +++ b/packaging/linux/flatpak/cargo-sources.json @@ -2,14 +2,50 @@ { "type": "git", "url": "https://github.com/storytold/craft-libs", - "commit": "82a24b006eefa036b43c09a67fb9a3fbd17ffe63", - "dest": "flatpak-cargo/git/craft-libs-82a24b0" + "commit": "94777dcf7f8962476e96b049d08d22e25b9330c2", + "dest": "flatpak-cargo/git/craft-libs-94777dc" }, { "type": "git", "url": "https://github.com/storytold/craft-libs", - "commit": "25da1314d443171b4adeaad2cd9454b273f35c6f", - "dest": "flatpak-cargo/git/craft-libs-25da131" + "commit": "f0f4758c01581d79577b9bf5046c06f4e77b1f18", + "dest": "flatpak-cargo/git/craft-libs-f0f4758" + }, + { + "type": "git", + "url": "https://github.com/storytold/craft-libs", + "commit": "c5a1cbfb5f9049f9270955caffb5bee5997aebf7", + "dest": "flatpak-cargo/git/craft-libs-c5a1cbf" + }, + { + "type": "git", + "url": "https://github.com/storytold/craft-libs", + "commit": "9dcbd90c7d16e1a668b3afa057e940e2db328b93", + "dest": "flatpak-cargo/git/craft-libs-9dcbd90" + }, + { + "type": "git", + "url": "https://github.com/storytold/craft-libs", + "commit": "b77af389f30bb10de10d8436ca9b39fe94e3bb67", + "dest": "flatpak-cargo/git/craft-libs-b77af38" + }, + { + "type": "git", + "url": "https://github.com/storytold/craft-libs", + "commit": "478c50560d3c6fad3d613af2a30b35c3bc9f4c0f", + "dest": "flatpak-cargo/git/craft-libs-478c505" + }, + { + "type": "git", + "url": "https://github.com/storytold/craft-libs", + "commit": "2651dbeb2b13f621db23f65347380e7f26e316f0", + "dest": "flatpak-cargo/git/craft-libs-2651dbe" + }, + { + "type": "git", + "url": "https://github.com/storytold/craft-libs", + "commit": "6e03f65bf45181db77ba6229716e6624db9eb25b", + "dest": "flatpak-cargo/git/craft-libs-6e03f65" }, { "type": "git", @@ -270,6 +306,19 @@ "dest": "cargo/vendor/alloc-no-stdlib-2.0.4", "dest-filename": ".cargo-checksum.json" }, + { + "type": "archive", + "archive-type": "tar-gzip", + "url": "https://static.crates.io/crates/alloc-no-stdlib/alloc-no-stdlib-3.0.0.crate", + "sha256": "c2fb6cfd47bf496ff64095c20eaba0c201404ee38714d4142fcfa1dc334fcc7a", + "dest": "cargo/vendor/alloc-no-stdlib-3.0.0" + }, + { + "type": "inline", + "contents": "{\"package\": \"c2fb6cfd47bf496ff64095c20eaba0c201404ee38714d4142fcfa1dc334fcc7a\", \"files\": {}}", + "dest": "cargo/vendor/alloc-no-stdlib-3.0.0", + "dest-filename": ".cargo-checksum.json" + }, { "type": "archive", "archive-type": "tar-gzip", @@ -283,6 +332,19 @@ "dest": "cargo/vendor/alloc-stdlib-0.2.4", "dest-filename": ".cargo-checksum.json" }, + { + "type": "archive", + "archive-type": "tar-gzip", + "url": "https://static.crates.io/crates/alloc-stdlib/alloc-stdlib-0.3.0.crate", + "sha256": "0b5c1865780388bfa186411ab5f247819487fc4864c6e9c3106611fa347586e1", + "dest": "cargo/vendor/alloc-stdlib-0.3.0" + }, + { + "type": "inline", + "contents": "{\"package\": \"0b5c1865780388bfa186411ab5f247819487fc4864c6e9c3106611fa347586e1\", \"files\": {}}", + "dest": "cargo/vendor/alloc-stdlib-0.3.0", + "dest-filename": ".cargo-checksum.json" + }, { "type": "archive", "archive-type": "tar-gzip", @@ -699,6 +761,19 @@ "dest": "cargo/vendor/base16ct-0.2.0", "dest-filename": ".cargo-checksum.json" }, + { + "type": "archive", + "archive-type": "tar-gzip", + "url": "https://static.crates.io/crates/base64/base64-0.23.1.crate", + "sha256": "ac07cdecf99051d9a5238b80f35af32cdeba5b336e55d957b318b50137e18da5", + "dest": "cargo/vendor/base64-0.23.1" + }, + { + "type": "inline", + "contents": "{\"package\": \"ac07cdecf99051d9a5238b80f35af32cdeba5b336e55d957b318b50137e18da5\", \"files\": {}}", + "dest": "cargo/vendor/base64-0.23.1", + "dest-filename": ".cargo-checksum.json" + }, { "type": "archive", "archive-type": "tar-gzip", @@ -712,19 +787,6 @@ "dest": "cargo/vendor/base64ct-1.8.3", "dest-filename": ".cargo-checksum.json" }, - { - "type": "archive", - "archive-type": "tar-gzip", - "url": "https://static.crates.io/crates/bit-set/bit-set-0.8.0.crate", - "sha256": "08807e080ed7f9d5433fa9b275196cfc35414f66a0c79d864dc51a0d825231a3", - "dest": "cargo/vendor/bit-set-0.8.0" - }, - { - "type": "inline", - "contents": "{\"package\": \"08807e080ed7f9d5433fa9b275196cfc35414f66a0c79d864dc51a0d825231a3\", \"files\": {}}", - "dest": "cargo/vendor/bit-set-0.8.0", - "dest-filename": ".cargo-checksum.json" - }, { "type": "archive", "archive-type": "tar-gzip", @@ -741,14 +803,14 @@ { "type": "archive", "archive-type": "tar-gzip", - "url": "https://static.crates.io/crates/bit-vec/bit-vec-0.8.0.crate", - "sha256": "5e764a1d40d510daf35e07be9eb06e75770908c27d411ee6c92109c9840eaaf7", - "dest": "cargo/vendor/bit-vec-0.8.0" + "url": "https://static.crates.io/crates/bit-set/bit-set-0.11.1.crate", + "sha256": "56d87354e4229f54a44f7bf2435906a4656dba36026ab6eaca629a2c436a691c", + "dest": "cargo/vendor/bit-set-0.11.1" }, { "type": "inline", - "contents": "{\"package\": \"5e764a1d40d510daf35e07be9eb06e75770908c27d411ee6c92109c9840eaaf7\", \"files\": {}}", - "dest": "cargo/vendor/bit-vec-0.8.0", + "contents": "{\"package\": \"56d87354e4229f54a44f7bf2435906a4656dba36026ab6eaca629a2c436a691c\", \"files\": {}}", + "dest": "cargo/vendor/bit-set-0.11.1", "dest-filename": ".cargo-checksum.json" }, { @@ -764,6 +826,32 @@ "dest": "cargo/vendor/bit-vec-0.9.1", "dest-filename": ".cargo-checksum.json" }, + { + "type": "archive", + "archive-type": "tar-gzip", + "url": "https://static.crates.io/crates/bit-vec/bit-vec-0.10.1.crate", + "sha256": "5727b15fa97d4f4fee0a3b7c3d550ed0269f54329207b86388de918604e31269", + "dest": "cargo/vendor/bit-vec-0.10.1" + }, + { + "type": "inline", + "contents": "{\"package\": \"5727b15fa97d4f4fee0a3b7c3d550ed0269f54329207b86388de918604e31269\", \"files\": {}}", + "dest": "cargo/vendor/bit-vec-0.10.1", + "dest-filename": ".cargo-checksum.json" + }, + { + "type": "archive", + "archive-type": "tar-gzip", + "url": "https://static.crates.io/crates/bit_field/bit_field-0.10.4.crate", + "sha256": "cb2907cc03d08cdb1c6724ad0670ce67c4a71e1c45a6d7635224011714cfc4b1", + "dest": "cargo/vendor/bit_field-0.10.4" + }, + { + "type": "inline", + "contents": "{\"package\": \"cb2907cc03d08cdb1c6724ad0670ce67c4a71e1c45a6d7635224011714cfc4b1\", \"files\": {}}", + "dest": "cargo/vendor/bit_field-0.10.4", + "dest-filename": ".cargo-checksum.json" + }, { "type": "archive", "archive-type": "tar-gzip", @@ -871,14 +959,40 @@ { "type": "archive", "archive-type": "tar-gzip", - "url": "https://static.crates.io/crates/brotli/brotli-8.0.4.crate", - "sha256": "5cc91aac060a7a1e25823bdccbfb6af1875b88f17c6daac97894eed8207166b3", - "dest": "cargo/vendor/brotli-8.0.4" + "url": "https://static.crates.io/crates/borsh/borsh-1.8.1.crate", + "sha256": "553c5d846a6ba5150c65e3b1b8ec073bcf1abc20f9b7220de384a4443ea4e20a", + "dest": "cargo/vendor/borsh-1.8.1" }, { "type": "inline", - "contents": "{\"package\": \"5cc91aac060a7a1e25823bdccbfb6af1875b88f17c6daac97894eed8207166b3\", \"files\": {}}", - "dest": "cargo/vendor/brotli-8.0.4", + "contents": "{\"package\": \"553c5d846a6ba5150c65e3b1b8ec073bcf1abc20f9b7220de384a4443ea4e20a\", \"files\": {}}", + "dest": "cargo/vendor/borsh-1.8.1", + "dest-filename": ".cargo-checksum.json" + }, + { + "type": "archive", + "archive-type": "tar-gzip", + "url": "https://static.crates.io/crates/borsh-derive/borsh-derive-1.8.1.crate", + "sha256": "12cdfe656708a01f89b451a7d36466e6fe6c414de0aa18fc54f864f6f9ca9f56", + "dest": "cargo/vendor/borsh-derive-1.8.1" + }, + { + "type": "inline", + "contents": "{\"package\": \"12cdfe656708a01f89b451a7d36466e6fe6c414de0aa18fc54f864f6f9ca9f56\", \"files\": {}}", + "dest": "cargo/vendor/borsh-derive-1.8.1", + "dest-filename": ".cargo-checksum.json" + }, + { + "type": "archive", + "archive-type": "tar-gzip", + "url": "https://static.crates.io/crates/brotli/brotli-9.0.0.crate", + "sha256": "f8b851b75c23ca7873623d612fe49bd1989aeb03d08fb9432187eb253d3d4c6b", + "dest": "cargo/vendor/brotli-9.0.0" + }, + { + "type": "inline", + "contents": "{\"package\": \"f8b851b75c23ca7873623d612fe49bd1989aeb03d08fb9432187eb253d3d4c6b\", \"files\": {}}", + "dest": "cargo/vendor/brotli-9.0.0", "dest-filename": ".cargo-checksum.json" }, { @@ -894,6 +1008,19 @@ "dest": "cargo/vendor/brotli-decompressor-5.0.3", "dest-filename": ".cargo-checksum.json" }, + { + "type": "archive", + "archive-type": "tar-gzip", + "url": "https://static.crates.io/crates/brotli-decompressor/brotli-decompressor-6.0.1.crate", + "sha256": "941cd9bd4ddab83cb46fa5a2d428f1c857b24ac78cb876cf7beb710840934bd7", + "dest": "cargo/vendor/brotli-decompressor-6.0.1" + }, + { + "type": "inline", + "contents": "{\"package\": \"941cd9bd4ddab83cb46fa5a2d428f1c857b24ac78cb876cf7beb710840934bd7\", \"files\": {}}", + "dest": "cargo/vendor/brotli-decompressor-6.0.1", + "dest-filename": ".cargo-checksum.json" + }, { "type": "archive", "archive-type": "tar-gzip", @@ -1154,6 +1281,19 @@ "dest": "cargo/vendor/chacha20-0.9.1", "dest-filename": ".cargo-checksum.json" }, + { + "type": "archive", + "archive-type": "tar-gzip", + "url": "https://static.crates.io/crates/chacha20/chacha20-0.10.2.crate", + "sha256": "65c35e4b699c7e15ccbe7ee35c005e4fc0a278d22238a2857e6ce2dadeda1b06", + "dest": "cargo/vendor/chacha20-0.10.2" + }, + { + "type": "inline", + "contents": "{\"package\": \"65c35e4b699c7e15ccbe7ee35c005e4fc0a278d22238a2857e6ce2dadeda1b06\", \"files\": {}}", + "dest": "cargo/vendor/chacha20-0.10.2", + "dest-filename": ".cargo-checksum.json" + }, { "type": "archive", "archive-type": "tar-gzip", @@ -1206,6 +1346,19 @@ "dest": "cargo/vendor/clipboard-win-5.4.1", "dest-filename": ".cargo-checksum.json" }, + { + "type": "archive", + "archive-type": "tar-gzip", + "url": "https://static.crates.io/crates/cobs/cobs-0.3.0.crate", + "sha256": "0fa961b519f0b462e3a3b4a34b64d119eeaca1d59af726fe450bbba07a9fc0a1", + "dest": "cargo/vendor/cobs-0.3.0" + }, + { + "type": "inline", + "contents": "{\"package\": \"0fa961b519f0b462e3a3b4a34b64d119eeaca1d59af726fe450bbba07a9fc0a1\", \"files\": {}}", + "dest": "cargo/vendor/cobs-0.3.0", + "dest-filename": ".cargo-checksum.json" + }, { "type": "archive", "archive-type": "tar-gzip", @@ -1323,6 +1476,19 @@ "dest": "cargo/vendor/core-foundation-0.9.4", "dest-filename": ".cargo-checksum.json" }, + { + "type": "archive", + "archive-type": "tar-gzip", + "url": "https://static.crates.io/crates/core-foundation/core-foundation-0.10.1.crate", + "sha256": "b2a6cd9ae233e7f62ba4e9353e81a88df7fc8a5987b8d445b4d90c879bd156f6", + "dest": "cargo/vendor/core-foundation-0.10.1" + }, + { + "type": "inline", + "contents": "{\"package\": \"b2a6cd9ae233e7f62ba4e9353e81a88df7fc8a5987b8d445b4d90c879bd156f6\", \"files\": {}}", + "dest": "cargo/vendor/core-foundation-0.10.1", + "dest-filename": ".cargo-checksum.json" + }, { "type": "archive", "archive-type": "tar-gzip", @@ -1362,6 +1528,19 @@ "dest": "cargo/vendor/core-graphics-types-0.1.3", "dest-filename": ".cargo-checksum.json" }, + { + "type": "archive", + "archive-type": "tar-gzip", + "url": "https://static.crates.io/crates/core_detect/core_detect-1.0.0.crate", + "sha256": "7f8f80099a98041a3d1622845c271458a2d73e688351bf3cb999266764b81d48", + "dest": "cargo/vendor/core_detect-1.0.0" + }, + { + "type": "inline", + "contents": "{\"package\": \"7f8f80099a98041a3d1622845c271458a2d73e688351bf3cb999266764b81d48\", \"files\": {}}", + "dest": "cargo/vendor/core_detect-1.0.0", + "dest-filename": ".cargo-checksum.json" + }, { "type": "archive", "archive-type": "tar-gzip", @@ -1375,15 +1554,82 @@ "dest": "cargo/vendor/cpufeatures-0.2.17", "dest-filename": ".cargo-checksum.json" }, + { + "type": "archive", + "archive-type": "tar-gzip", + "url": "https://static.crates.io/crates/cpufeatures/cpufeatures-0.3.1.crate", + "sha256": "5ca28b0ae3115b884660db4118d803791fd6756b6e88f39c0f3f7859060d7566", + "dest": "cargo/vendor/cpufeatures-0.3.1" + }, + { + "type": "inline", + "contents": "{\"package\": \"5ca28b0ae3115b884660db4118d803791fd6756b6e88f39c0f3f7859060d7566\", \"files\": {}}", + "dest": "cargo/vendor/cpufeatures-0.3.1", + "dest-filename": ".cargo-checksum.json" + }, { "type": "shell", "commands": [ - "cp -r --reflink=auto \"flatpak-cargo/git/craft-libs-82a24b0/crates/docpath\" \"cargo/vendor/craft-docpath\"" + "cp -r --reflink=auto \"flatpak-cargo/git/craft-libs-94777dc/crates/cms\" \"cargo/vendor/craft-cms\"" ] }, { "type": "inline", - "contents": "[package]\nname = \"craft-docpath\"\ndescription = \"Decide whether a file path or file URL stored in a document refers to a local file.\"\nversion = \"0.1.0\"\nedition = \"2024\"\nlicense = \"MIT OR Apache-2.0\"\nrust-version = \"1.95\"\nrepository = \"https://github.com/storytold/craft-libs\"\n\n[lints.rust]\nunsafe_code = \"forbid\"\n\n[lints.rust.unexpected_cfgs]\nlevel = \"warn\"\ncheck-cfg = [\"cfg(craft_pdf_unicode_fixtures)\"]\n\n[lints.clippy]\ndbg_macro = \"warn\"\ntodo = \"warn\"\n", + "contents": "[package]\nname = \"craft-cms\"\nversion = \"0.1.0\"\nedition = \"2024\"\nlicense = \"MIT OR Apache-2.0\"\nrust-version = \"1.95\"\nrepository = \"https://github.com/storytold/craft-libs\"\ndescription = \"Pure-Rust ICC v2/v4 colour management: profile parsing and writing, transforms, rendering intents, black point compensation\"\nexclude = [\"tests/data\", \"tests/fogra39.rs\"]\n\n[lints.rust]\nunsafe_code = \"forbid\"\nunused_workspace_dependencies = \"allow\"\n\n[lints.rust.unexpected_cfgs]\nlevel = \"warn\"\ncheck-cfg = [\"cfg(craft_pdf_unicode_fixtures)\"]\n\n[lints.clippy]\ncognitive_complexity = \"deny\"\ntoo_many_arguments = \"deny\"\nunused_workspace_dependencies = \"allow\"\nwildcard_imports = \"deny\"\ndbg_macro = \"warn\"\ntodo = \"warn\"\n\n[dependencies.md5]\npackage = \"md-5\"\nversion = \"0.10\"\ndefault-features = false\n\n[target.\"cfg(not(target_arch = \\\"wasm32\\\"))\".dependencies]\nrayon = \"1\"\n\n[dev-dependencies]\nmoxcms = \"0.8\"\n", + "dest": "cargo/vendor/craft-cms", + "dest-filename": "Cargo.toml" + }, + { + "type": "inline", + "contents": "{\"package\": null, \"files\": {}}", + "dest": "cargo/vendor/craft-cms", + "dest-filename": ".cargo-checksum.json" + }, + { + "type": "shell", + "commands": [ + "cp -r --reflink=auto \"flatpak-cargo/git/craft-libs-f0f4758/crates/codepage\" \"cargo/vendor/craft-codepage\"" + ] + }, + { + "type": "inline", + "contents": "[package]\nname = \"craft-codepage\"\ndescription = \"Legacy 8-bit code pages, one table each: the single-byte Windows pages, Mac OS Roman and the DOS (OEM) pages, keyed by Windows code page number, with the RTF/Word font charsets.\"\nversion = \"0.1.0\"\nedition = \"2024\"\nlicense = \"MIT OR Apache-2.0\"\nrust-version = \"1.95\"\nrepository = \"https://github.com/storytold/craft-libs\"\n\n[lints.rust]\nunsafe_code = \"forbid\"\nunused_workspace_dependencies = \"allow\"\n\n[lints.rust.unexpected_cfgs]\nlevel = \"warn\"\ncheck-cfg = [\"cfg(craft_pdf_unicode_fixtures)\"]\n\n[lints.clippy]\ncognitive_complexity = \"deny\"\ntoo_many_arguments = \"deny\"\nunused_workspace_dependencies = \"allow\"\nwildcard_imports = \"deny\"\ndbg_macro = \"warn\"\ntodo = \"warn\"\n\n[dev-dependencies]\nencoding_rs = \"0.8\"\n", + "dest": "cargo/vendor/craft-codepage", + "dest-filename": "Cargo.toml" + }, + { + "type": "inline", + "contents": "{\"package\": null, \"files\": {}}", + "dest": "cargo/vendor/craft-codepage", + "dest-filename": ".cargo-checksum.json" + }, + { + "type": "shell", + "commands": [ + "cp -r --reflink=auto \"flatpak-cargo/git/craft-libs-94777dc/crates/crw\" \"cargo/vendor/craft-crw\"" + ] + }, + { + "type": "inline", + "contents": "[package]\nname = \"craft-crw\"\ndescription = \"Clean-room Canon CRW (CIFF) raw decoder: the heap container, the derived entropy coding, sensor levels and as-shot white balance.\"\nversion = \"0.1.0\"\nedition = \"2024\"\nlicense = \"MIT OR Apache-2.0\"\nrust-version = \"1.95\"\nrepository = \"https://github.com/storytold/craft-libs\"\n\n[lints.rust]\nunsafe_code = \"forbid\"\nunused_workspace_dependencies = \"allow\"\n\n[lints.rust.unexpected_cfgs]\nlevel = \"warn\"\ncheck-cfg = [\"cfg(craft_pdf_unicode_fixtures)\"]\n\n[lints.clippy]\ncognitive_complexity = \"deny\"\ntoo_many_arguments = \"deny\"\nunused_workspace_dependencies = \"allow\"\nwildcard_imports = \"deny\"\ndbg_macro = \"warn\"\ntodo = \"warn\"\n\n[dependencies]\nthiserror = \"2\"\n\n[dev-dependencies]\nproptest = \"1\"\nserde_json = \"1\"\n\n[dev-dependencies.serde]\nversion = \"1\"\nfeatures = [\"derive\"]\n\n[dev-dependencies.sha2]\nversion = \"0.10\"\ndefault-features = false\nfeatures = [\"std\"]\n", + "dest": "cargo/vendor/craft-crw", + "dest-filename": "Cargo.toml" + }, + { + "type": "inline", + "contents": "{\"package\": null, \"files\": {}}", + "dest": "cargo/vendor/craft-crw", + "dest-filename": ".cargo-checksum.json" + }, + { + "type": "shell", + "commands": [ + "cp -r --reflink=auto \"flatpak-cargo/git/craft-libs-c5a1cbf/crates/docpath\" \"cargo/vendor/craft-docpath\"" + ] + }, + { + "type": "inline", + "contents": "[package]\nname = \"craft-docpath\"\ndescription = \"Decide whether a file path or file URL stored in a document refers to a local file.\"\nversion = \"0.1.0\"\nedition = \"2024\"\nlicense = \"MIT OR Apache-2.0\"\nrust-version = \"1.95\"\nrepository = \"https://github.com/storytold/craft-libs\"\n\n[lints.rust]\nunsafe_code = \"forbid\"\n\n[lints.rust.unexpected_cfgs]\nlevel = \"warn\"\ncheck-cfg = [\"cfg(craft_pdf_unicode_fixtures)\"]\n\n[lints.clippy]\ncognitive_complexity = \"deny\"\ntoo_many_arguments = \"deny\"\nwildcard_imports = \"deny\"\ndbg_macro = \"warn\"\ntodo = \"warn\"\n", "dest": "cargo/vendor/craft-docpath", "dest-filename": "Cargo.toml" }, @@ -1396,12 +1642,300 @@ { "type": "shell", "commands": [ - "cp -r --reflink=auto \"flatpak-cargo/git/craft-libs-25da131/crates/ui\" \"cargo/vendor/craft-ui\"" + "cp -r --reflink=auto \"flatpak-cargo/git/craft-libs-c5a1cbf/crates/fonts-build\" \"cargo/vendor/craft-fonts-build\"" ] }, { "type": "inline", - "contents": "[package]\nname = \"craft-ui\"\nversion = \"0.1.0\"\nedition = \"2024\"\nlicense = \"MIT OR Apache-2.0\"\nrepository = \"https://github.com/storytold/craft-libs\"\nrust-version = \"1.95\"\ndescription = \"Reusable egui controls and icon catalogs for Craft frontends\"\n\n[lints.rust]\nunsafe_code = \"forbid\"\n\n[lints.rust.unexpected_cfgs]\nlevel = \"warn\"\ncheck-cfg = [\"cfg(craft_pdf_unicode_fixtures)\"]\n\n[lints.clippy]\ndbg_macro = \"warn\"\ntodo = \"warn\"\n\n[dependencies.egui]\nversion = \"0.37\"\ndefault-features = false\n\n[dependencies.serde]\nversion = \"1\"\nfeatures = [\"derive\"]\noptional = true\n\n[features]\nserde = [\"dep:serde\"]\n\n[dev-dependencies]\nserde_json = \"1\"\n\n[dev-dependencies.egui]\nfeatures = [\"default_fonts\"]\nversion = \"0.37\"\ndefault-features = false\n\n[dev-dependencies.egui_extras]\nversion = \"0.37\"\ndefault-features = false\nfeatures = [\"svg\"]\n\n[dev-dependencies.egui_kittest]\nversion = \"0.37\"\nfeatures = [\"wgpu\"]\n\n[dev-dependencies.image]\nversion = \"0.25\"\ndefault-features = false\nfeatures = [\"png\"]\n", + "contents": "[package]\nname = \"craft-fonts-build\"\ndescription = \"Embeds the optional craft-fonts faces from an app's build.rs, plus the EmbeddedFace type the generated table uses.\"\nversion = \"0.1.0\"\nedition = \"2024\"\nlicense = \"MIT OR Apache-2.0\"\nrust-version = \"1.95\"\nrepository = \"https://github.com/storytold/craft-libs\"\n\n[features]\nsubset = [\"dep:skera\", \"dep:skrifa\"]\n\n[dependencies.skera]\nversion = \"0.8\"\noptional = true\n\n[dependencies.skrifa]\nversion = \"0.48\"\ndefault-features = false\nfeatures = [\"std\"]\noptional = true\n\n[dev-dependencies.craft-fonts-build-consumer]\npath = \"tests/consumer\"\n\n[lints.rust]\nunsafe_code = \"forbid\"\n\n[lints.rust.unexpected_cfgs]\nlevel = \"warn\"\ncheck-cfg = [\"cfg(craft_pdf_unicode_fixtures)\"]\n\n[lints.clippy]\ncognitive_complexity = \"deny\"\ntoo_many_arguments = \"deny\"\nwildcard_imports = \"deny\"\ndbg_macro = \"warn\"\ntodo = \"warn\"\n", + "dest": "cargo/vendor/craft-fonts-build", + "dest-filename": "Cargo.toml" + }, + { + "type": "inline", + "contents": "{\"package\": null, \"files\": {}}", + "dest": "cargo/vendor/craft-fonts-build", + "dest-filename": ".cargo-checksum.json" + }, + { + "type": "shell", + "commands": [ + "cp -r --reflink=auto \"flatpak-cargo/git/craft-libs-9dcbd90/crates/gainmap\" \"cargo/vendor/craft-gainmap\"" + ] + }, + { + "type": "inline", + "contents": "[package]\nname = \"craft-gainmap\"\ndescription = \"HDR gain maps (ISO 21496-1, Adobe hdrgm, Apple): metadata reader and writer, and the arithmetic that measures and applies a gain map.\"\nversion = \"0.1.0\"\nedition = \"2024\"\nlicense = \"MIT OR Apache-2.0\"\nrust-version = \"1.95\"\nrepository = \"https://github.com/storytold/craft-libs\"\n\n[lints.rust]\nunsafe_code = \"forbid\"\nunused_workspace_dependencies = \"allow\"\n\n[lints.rust.unexpected_cfgs]\nlevel = \"warn\"\ncheck-cfg = [\"cfg(craft_pdf_unicode_fixtures)\"]\n\n[lints.clippy]\ncognitive_complexity = \"deny\"\ntoo_many_arguments = \"deny\"\nunused_workspace_dependencies = \"allow\"\nwildcard_imports = \"deny\"\ndbg_macro = \"warn\"\ntodo = \"warn\"\n\n[dependencies]\nthiserror = \"2\"\n", + "dest": "cargo/vendor/craft-gainmap", + "dest-filename": "Cargo.toml" + }, + { + "type": "inline", + "contents": "{\"package\": null, \"files\": {}}", + "dest": "cargo/vendor/craft-gainmap", + "dest-filename": ".cargo-checksum.json" + }, + { + "type": "shell", + "commands": [ + "cp -r --reflink=auto \"flatpak-cargo/git/craft-libs-b77af38/crates/gif\" \"cargo/vendor/craft-gif\"" + ] + }, + { + "type": "inline", + "contents": "[package]\nname = \"craft-gif\"\ndescription = \"GIF block reader, bounded frame decoder and animation writer.\"\nversion = \"0.1.0\"\nedition = \"2024\"\nlicense = \"MIT OR Apache-2.0\"\nrust-version = \"1.95\"\nrepository = \"https://github.com/storytold/craft-libs\"\n\n[lints.rust]\nunsafe_code = \"forbid\"\nunused_workspace_dependencies = \"allow\"\n\n[lints.rust.unexpected_cfgs]\nlevel = \"warn\"\ncheck-cfg = [\"cfg(craft_pdf_unicode_fixtures)\"]\n\n[lints.clippy]\ncognitive_complexity = \"deny\"\ntoo_many_arguments = \"deny\"\nunused_workspace_dependencies = \"allow\"\nwildcard_imports = \"deny\"\ndbg_macro = \"warn\"\ntodo = \"warn\"\n\n[features]\nframes = [\"dep:image\"]\n\n[dependencies]\ngif = \"0.14\"\n\n[dependencies.image]\nversion = \"0.25\"\ndefault-features = false\nfeatures = [\"gif\"]\noptional = true\n\n[dev-dependencies.image]\nversion = \"0.25\"\ndefault-features = false\nfeatures = [\"gif\"]\n", + "dest": "cargo/vendor/craft-gif", + "dest-filename": "Cargo.toml" + }, + { + "type": "inline", + "contents": "{\"package\": null, \"files\": {}}", + "dest": "cargo/vendor/craft-gif", + "dest-filename": ".cargo-checksum.json" + }, + { + "type": "shell", + "commands": [ + "cp -r --reflink=auto \"flatpak-cargo/git/craft-libs-9dcbd90/crates/heif\" \"cargo/vendor/craft-heif\"" + ] + }, + { + "type": "inline", + "contents": "[package]\nname = \"craft-heif\"\ndescription = \"Optional HEIF/HEIC still-image decoder: heic-rs for the container and HEVC, libheif-matching colour conversion, panic-guarded.\"\nversion = \"0.1.0\"\nedition = \"2024\"\nlicense = \"MIT OR Apache-2.0\"\nrust-version = \"1.95\"\nrepository = \"https://github.com/storytold/craft-libs\"\n\n[dependencies.heic-rs]\nversion = \"=0.1.4\"\ndefault-features = false\nfeatures = [\"std\"]\noptional = true\n\n[target.\"cfg(not(target_arch = \\\"wasm32\\\"))\".dependencies.heic-rs]\nversion = \"=0.1.4\"\ndefault-features = false\nfeatures = [\"std\", \"parallel\"]\noptional = true\n\n[target.\"cfg(not(target_arch = \\\"wasm32\\\"))\".dependencies.rayon]\noptional = true\nversion = \"1\"\n\n[features]\ndefault = [\"decode\"]\ndecode = [\"dep:heic-rs\", \"dep:rayon\"]\nmetadata = []\ntestdata = []\n\n[lints.rust]\nunsafe_code = \"forbid\"\nunused_workspace_dependencies = \"allow\"\n\n[lints.rust.unexpected_cfgs]\nlevel = \"warn\"\ncheck-cfg = [\"cfg(craft_pdf_unicode_fixtures)\"]\n\n[lints.clippy]\ncognitive_complexity = \"deny\"\ntoo_many_arguments = \"deny\"\nunused_workspace_dependencies = \"allow\"\nwildcard_imports = \"deny\"\ndbg_macro = \"warn\"\ntodo = \"warn\"\n", + "dest": "cargo/vendor/craft-heif", + "dest-filename": "Cargo.toml" + }, + { + "type": "inline", + "contents": "{\"package\": null, \"files\": {}}", + "dest": "cargo/vendor/craft-heif", + "dest-filename": ".cargo-checksum.json" + }, + { + "type": "shell", + "commands": [ + "cp -r --reflink=auto \"flatpak-cargo/git/craft-libs-c5a1cbf/crates/i18n\" \"cargo/vendor/craft-i18n\"" + ] + }, + { + "type": "inline", + "contents": "[package]\nname = \"craft-i18n\"\ndescription = \"Translations for the Craft apps: the embedded craft-i18n catalogs, lookup with fallback, plurals, numbers for a region, language names, the system locale, search folding and locale sorting.\"\nversion = \"0.1.0\"\nedition = \"2024\"\nlicense = \"MIT OR Apache-2.0\"\nrust-version = \"1.95\"\nrepository = \"https://github.com/storytold/craft-libs\"\n\n[dependencies]\nwriteable = \"0.6\"\nlog = \"0.4\"\nsys-locale = \"0.3\"\nicu_normalizer = \"~2.3\"\nicu_properties = \"~2.3\"\nunicode-bidi = \"0.3\"\n\n[dependencies.fixed_decimal]\nversion = \"0.7.2\"\ndefault-features = false\n\n[dependencies.icu_decimal]\nversion = \"~2.3\"\ndefault-features = false\nfeatures = [\"serde\"]\n\n[dependencies.icu_locale_core]\nversion = \"~2.3\"\ndefault-features = false\n\n[dependencies.icu_locale_fallback]\nversion = \"~2.3\"\ndefault-features = false\nfeatures = [\"compiled_data\"]\n\n[dependencies.icu_plurals]\nversion = \"~2.3\"\ndefault-features = false\nfeatures = [\"serde\"]\n\n[dependencies.icu_provider]\nversion = \"~2.3\"\ndefault-features = false\nfeatures = [\"sync\"]\n\n[dependencies.icu_provider_adapters]\nversion = \"~2.3\"\ndefault-features = false\n\n[dependencies.icu_provider_blob]\nversion = \"~2.3\"\ndefault-features = false\n\n[dependencies.icu_collator]\nversion = \"~2.3.1\"\ndefault-features = false\nfeatures = [\"serde\"]\noptional = true\n\n[target.\"cfg(target_arch = \\\"wasm32\\\")\".dependencies.sys-locale]\nversion = \"0.3\"\nfeatures = [\"js\"]\n\n[target.\"cfg(windows)\".dependencies]\nwindows-registry = \"0.6\"\n\n[target.\"cfg(target_vendor = \\\"apple\\\")\".dependencies.objc2-foundation]\nversion = \"0.3.2\"\ndefault-features = false\nfeatures = [\"std\", \"NSDateFormatter\", \"NSFormatter\", \"NSLocale\", \"NSString\"]\n\n[features]\ncollate = [\"dep:icu_collator\", \"icu_provider/serde\", \"icu_provider_blob/alloc\"]\n\n[lints.rust]\nunsafe_code = \"forbid\"\n\n[lints.rust.unexpected_cfgs]\nlevel = \"warn\"\ncheck-cfg = [\"cfg(craft_pdf_unicode_fixtures)\"]\n\n[lints.clippy]\ncognitive_complexity = \"deny\"\ntoo_many_arguments = \"deny\"\nwildcard_imports = \"deny\"\ndbg_macro = \"warn\"\ntodo = \"warn\"\n", + "dest": "cargo/vendor/craft-i18n", + "dest-filename": "Cargo.toml" + }, + { + "type": "inline", + "contents": "{\"package\": null, \"files\": {}}", + "dest": "cargo/vendor/craft-i18n", + "dest-filename": ".cargo-checksum.json" + }, + { + "type": "shell", + "commands": [ + "cp -r --reflink=auto \"flatpak-cargo/git/craft-libs-478c505/crates/image-codecs\" \"cargo/vendor/craft-image-codecs\"" + ] + }, + { + "type": "inline", + "contents": "[package]\nname = \"craft-image-codecs\"\ndescription = \"Bounded, depth- and metadata-preserving codecs for flat raster image formats\"\nversion = \"0.1.0\"\nedition = \"2024\"\nlicense = \"MIT OR Apache-2.0\"\nrust-version = \"1.95\"\nrepository = \"https://github.com/storytold/craft-libs\"\n\n[lints.rust]\nunsafe_code = \"forbid\"\nunused_workspace_dependencies = \"allow\"\n\n[lints.rust.unexpected_cfgs]\nlevel = \"warn\"\ncheck-cfg = [\"cfg(craft_pdf_unicode_fixtures)\"]\n\n[lints.clippy]\ncognitive_complexity = \"deny\"\ntoo_many_arguments = \"deny\"\nunused_workspace_dependencies = \"allow\"\nwildcard_imports = \"deny\"\ndbg_macro = \"warn\"\ntodo = \"warn\"\n\n[features]\ncorpus = []\ndefault = []\navif = [\"image/avif\", \"dep:ravif\", \"dep:rav1e\", \"dep:avif-serialize\"]\nheif = [\"dep:craft-heif\"]\n\n[dependencies]\ncrc32fast = \"1.5\"\nthiserror = \"2\"\npng = \"0.18\"\nhalf = \"2\"\nserde_json = \"1\"\nimage-webp = \"0.2\"\nzune-jpeg = \"0.5\"\nzune-core = \"0.5\"\njpeg-encoder = \"0.6\"\n\n[dependencies.image]\nversion = \"0.25\"\ndefault-features = false\nfeatures = [\"png\", \"jpeg\", \"tiff\", \"gif\", \"bmp\", \"tga\", \"ico\", \"qoi\", \"hdr\"]\n\n[dependencies.tiff]\nversion = \"0.11\"\ndefault-features = false\nfeatures = [\"deflate\", \"fax\", \"jpeg\", \"lzw\"]\n\n[dependencies.exr]\nversion = \"1.73\"\ndefault-features = false\n\n[dependencies.flate2]\nversion = \"1.1.10\"\ndefault-features = false\nfeatures = [\"zlib-rs\", \"runtime_detection\"]\n\n[dependencies.craft-jpeg]\npath = \"crates/jpeg\"\n\n[dependencies.craft-metadata]\npath = \"crates/metadata\"\n\n[dependencies.zune-jpegxl]\nversion = \"=0.5.2\"\ndefault-features = false\nfeatures = [\"std\"]\n\n[dependencies.craft-heif]\noptional = true\npath = \"crates/heif\"\n\n[dependencies.ravif]\nversion = \"0.13\"\ndefault-features = false\noptional = true\n\n[dependencies.rav1e]\nversion = \"0.8\"\ndefault-features = false\noptional = true\n\n[dependencies.avif-serialize]\nversion = \"0.8\"\noptional = true\n\n[dependencies.hayro-jpeg2000]\nversion = \"=0.3.5\"\ndefault-features = false\nfeatures = [\"std\", \"simd\"]\n\n[target.\"cfg(not(target_arch = \\\"wasm32\\\"))\".dependencies]\nrayon = \"1\"\n\n[target.\"cfg(not(target_arch = \\\"wasm32\\\"))\".dependencies.exr]\nversion = \"1.73\"\ndefault-features = false\nfeatures = [\"rayon\"]\n\n[target.\"cfg(not(target_arch = \\\"wasm32\\\"))\".dev-dependencies.craft-video]\nfeatures = [\"av1-decode\"]\npath = \"crates/video\"\n\n[target.\"cfg(not(target_arch = \\\"wasm32\\\"))\".dev-dependencies.jxl-oxide]\nversion = \"=0.12.6\"\ndefault-features = false\nfeatures = [\"rayon\"]\n\n[dev-dependencies]\nproptest = \"1\"\n\n[dev-dependencies.image]\nversion = \"0.25\"\ndefault-features = false\nfeatures = [\"png\", \"jpeg\", \"tiff\"]\n\n[dev-dependencies.sha2]\nversion = \"0.10\"\ndefault-features = false\nfeatures = [\"std\"]\n", + "dest": "cargo/vendor/craft-image-codecs", + "dest-filename": "Cargo.toml" + }, + { + "type": "inline", + "contents": "{\"package\": null, \"files\": {}}", + "dest": "cargo/vendor/craft-image-codecs", + "dest-filename": ".cargo-checksum.json" + }, + { + "type": "shell", + "commands": [ + "cp -r --reflink=auto \"flatpak-cargo/git/craft-libs-478c505/crates/jpeg\" \"cargo/vendor/craft-jpeg\"" + ] + }, + { + "type": "inline", + "contents": "[package]\nname = \"craft-jpeg\"\ndescription = \"Clean-room JPEG decoder and 8-bit optimized baseline encoder (ITU-T T.81).\"\nversion = \"0.1.0\"\nedition = \"2024\"\nlicense = \"MIT OR Apache-2.0\"\nrust-version = \"1.95\"\nrepository = \"https://github.com/storytold/craft-libs\"\n\n[lints.rust]\nunsafe_code = \"forbid\"\nunused_workspace_dependencies = \"allow\"\n\n[lints.rust.unexpected_cfgs]\nlevel = \"warn\"\ncheck-cfg = [\"cfg(craft_pdf_unicode_fixtures)\"]\n\n[lints.clippy]\ncognitive_complexity = \"deny\"\ntoo_many_arguments = \"deny\"\nunused_workspace_dependencies = \"allow\"\nwildcard_imports = \"deny\"\ndbg_macro = \"warn\"\ntodo = \"warn\"\n\n[dependencies]\nthiserror = \"2\"\n\n[dependencies.rayon]\noptional = true\nversion = \"1\"\n\n[dev-dependencies]\njpeg-encoder = \"0.6\"\nzune-jpeg = \"0.5\"\njpeg-decoder = \"0.3\"\n\n[features]\ndefault = []\nparallel = [\"dep:rayon\"]\n", + "dest": "cargo/vendor/craft-jpeg", + "dest-filename": "Cargo.toml" + }, + { + "type": "inline", + "contents": "{\"package\": null, \"files\": {}}", + "dest": "cargo/vendor/craft-jpeg", + "dest-filename": ".cargo-checksum.json" + }, + { + "type": "shell", + "commands": [ + "cp -r --reflink=auto \"flatpak-cargo/git/craft-libs-b77af38/crates/jxl\" \"cargo/vendor/craft-jxl\"" + ] + }, + { + "type": "inline", + "contents": "[package]\nname = \"craft-jxl\"\ndescription = \"JPEG XL image decoding and encoding with bounded input and allocation tracking.\"\nversion = \"0.1.0\"\nedition = \"2024\"\nlicense = \"MIT OR Apache-2.0\"\nrust-version = \"1.95\"\nrepository = \"https://github.com/storytold/craft-libs\"\n\n[lints.rust]\nunsafe_code = \"forbid\"\nunused_workspace_dependencies = \"allow\"\n\n[lints.rust.unexpected_cfgs]\nlevel = \"warn\"\ncheck-cfg = [\"cfg(craft_pdf_unicode_fixtures)\"]\n\n[lints.clippy]\ncognitive_complexity = \"deny\"\ntoo_many_arguments = \"deny\"\nunused_workspace_dependencies = \"allow\"\nwildcard_imports = \"deny\"\ndbg_macro = \"warn\"\ntodo = \"warn\"\n\n[features]\ndefault = [\"decode\", \"encode\"]\ndecode = [\"dep:jxl-oxide\"]\nencode = [\"dep:jixel\"]\n\n[dependencies]\nthiserror = \"2\"\n\n[dependencies.jxl-oxide]\noptional = true\nversion = \"0.12\"\ndefault-features = false\n\n[dev-dependencies.craft-cms]\npath = \"crates/cms\"\n\n[target.\"cfg(not(target_arch = \\\"wasm32\\\"))\".dependencies.jixel]\noptional = true\nversion = \"=0.3.4\"\n", + "dest": "cargo/vendor/craft-jxl", + "dest-filename": "Cargo.toml" + }, + { + "type": "inline", + "contents": "{\"package\": null, \"files\": {}}", + "dest": "cargo/vendor/craft-jxl", + "dest-filename": ".cargo-checksum.json" + }, + { + "type": "shell", + "commands": [ + "cp -r --reflink=auto \"flatpak-cargo/git/craft-libs-478c505/crates/metadata\" \"cargo/vendor/craft-metadata\"" + ] + }, + { + "type": "inline", + "contents": "[package]\nname = \"craft-metadata\"\ndescription = \"Photo metadata: EXIF, IPTC-IIM, XMP packets (read, write, merge) and GPX track logs, the blocks that carry them in JPEG, PNG, WebP, TIFF and CR3 files, and one model they all read into.\"\nversion = \"0.1.0\"\nedition = \"2024\"\nlicense = \"MIT OR Apache-2.0\"\nrust-version = \"1.95\"\nrepository = \"https://github.com/storytold/craft-libs\"\n\n[lints.rust]\nunsafe_code = \"forbid\"\nunused_workspace_dependencies = \"allow\"\n\n[lints.rust.unexpected_cfgs]\nlevel = \"warn\"\ncheck-cfg = [\"cfg(craft_pdf_unicode_fixtures)\"]\n\n[lints.clippy]\ncognitive_complexity = \"deny\"\ntoo_many_arguments = \"deny\"\nunused_workspace_dependencies = \"allow\"\nwildcard_imports = \"deny\"\ndbg_macro = \"warn\"\ntodo = \"warn\"\n\n[dependencies]\nquick-xml = \"0.41\"\n\n[dependencies.craft-tiff]\npath = \"crates/tiff\"\n\n[dependencies.serde]\nversion = \"1\"\nfeatures = [\"derive\"]\n\n[dependencies.chrono]\nversion = \"0.4.45\"\ndefault-features = false\nfeatures = [\"std\"]\n\n[dependencies.brotli-decompressor]\nversion = \"6\"\ndefault-features = false\nfeatures = [\"std\"]\n\n[dev-dependencies]\nproptest = \"1\"\nserde_json = \"1\"\n\n[dev-dependencies.brotli]\nversion = \"9\"\ndefault-features = false\nfeatures = [\"std\"]\n", + "dest": "cargo/vendor/craft-metadata", + "dest-filename": "Cargo.toml" + }, + { + "type": "inline", + "contents": "{\"package\": null, \"files\": {}}", + "dest": "cargo/vendor/craft-metadata", + "dest-filename": ".cargo-checksum.json" + }, + { + "type": "shell", + "commands": [ + "cp -r --reflink=auto \"flatpak-cargo/git/craft-libs-94777dc/crates/metadata\" \"cargo/vendor/craft-metadata\"" + ] + }, + { + "type": "inline", + "contents": "[package]\nname = \"craft-metadata\"\ndescription = \"Photo metadata: EXIF, IPTC-IIM, XMP packets (read, write, merge) and GPX track logs, the blocks that carry them in JPEG, PNG, WebP, TIFF and CR3 files, and one model they all read into.\"\nversion = \"0.1.0\"\nedition = \"2024\"\nlicense = \"MIT OR Apache-2.0\"\nrust-version = \"1.95\"\nrepository = \"https://github.com/storytold/craft-libs\"\n\n[lints.rust]\nunsafe_code = \"forbid\"\nunused_workspace_dependencies = \"allow\"\n\n[lints.rust.unexpected_cfgs]\nlevel = \"warn\"\ncheck-cfg = [\"cfg(craft_pdf_unicode_fixtures)\"]\n\n[lints.clippy]\ncognitive_complexity = \"deny\"\ntoo_many_arguments = \"deny\"\nunused_workspace_dependencies = \"allow\"\nwildcard_imports = \"deny\"\ndbg_macro = \"warn\"\ntodo = \"warn\"\n\n[dependencies]\nquick-xml = \"0.41\"\n\n[dependencies.craft-tiff]\npath = \"crates/tiff\"\n\n[dependencies.serde]\nversion = \"1\"\nfeatures = [\"derive\"]\n\n[dependencies.chrono]\nversion = \"0.4.45\"\ndefault-features = false\nfeatures = [\"std\"]\n\n[dependencies.brotli-decompressor]\nversion = \"6\"\ndefault-features = false\nfeatures = [\"std\"]\n\n[dev-dependencies]\nproptest = \"1\"\nserde_json = \"1\"\n\n[dev-dependencies.brotli]\nversion = \"9\"\ndefault-features = false\nfeatures = [\"std\"]\n", + "dest": "cargo/vendor/craft-metadata", + "dest-filename": "Cargo.toml" + }, + { + "type": "inline", + "contents": "{\"package\": null, \"files\": {}}", + "dest": "cargo/vendor/craft-metadata", + "dest-filename": ".cargo-checksum.json" + }, + { + "type": "shell", + "commands": [ + "cp -r --reflink=auto \"flatpak-cargo/git/craft-libs-f0f4758/crates/mime\" \"cargo/vendor/craft-mime\"" + ] + }, + { + "type": "inline", + "contents": "[package]\nname = \"craft-mime\"\ndescription = \"Internet messages and MIME: RFC 5322 headers, RFC 2045-2049 parts, encoded words, RFC 2231 parameters, transfer encodings, mbox and multipart/related lookups, read and written.\"\nversion = \"0.1.0\"\nedition = \"2024\"\nlicense = \"MIT OR Apache-2.0\"\nrust-version = \"1.95\"\nrepository = \"https://github.com/storytold/craft-libs\"\n\n[lints.rust]\nunsafe_code = \"forbid\"\nunused_workspace_dependencies = \"allow\"\n\n[lints.rust.unexpected_cfgs]\nlevel = \"warn\"\ncheck-cfg = [\"cfg(craft_pdf_unicode_fixtures)\"]\n\n[lints.clippy]\ncognitive_complexity = \"deny\"\ntoo_many_arguments = \"deny\"\nunused_workspace_dependencies = \"allow\"\nwildcard_imports = \"deny\"\ndbg_macro = \"warn\"\ntodo = \"warn\"\n\n[dependencies]\nencoding_rs = \"0.8\"\n\n[dependencies.craft-codepage]\npath = \"crates/codepage\"\n\n[dependencies.chrono]\nversion = \"0.4.45\"\ndefault-features = false\nfeatures = [\"std\"]\n\n[dependencies.chardetng]\nversion = \"1\"\noptional = true\n\n[features]\ndetect = [\"dep:chardetng\"]\n\n[dev-dependencies]\nproptest = \"1\"\n", + "dest": "cargo/vendor/craft-mime", + "dest-filename": "Cargo.toml" + }, + { + "type": "inline", + "contents": "{\"package\": null, \"files\": {}}", + "dest": "cargo/vendor/craft-mime", + "dest-filename": ".cargo-checksum.json" + }, + { + "type": "shell", + "commands": [ + "cp -r --reflink=auto \"flatpak-cargo/git/craft-libs-2651dbe/crates/pdf\" \"cargo/vendor/craft-pdf\"" + ] + }, + { + "type": "inline", + "contents": "[package]\nname = \"craft-pdf\"\ndescription = \"Shared PDF reading, rendering and optional writing for Craft apps\"\nversion = \"0.1.0\"\nedition = \"2024\"\nlicense = \"MIT OR Apache-2.0\"\nrepository = \"https://github.com/storytold/craft-libs\"\nrust-version = \"1.95\"\n\n[lints.rust]\nunsafe_code = \"forbid\"\nunused_workspace_dependencies = \"allow\"\n\n[lints.rust.unexpected_cfgs]\nlevel = \"warn\"\ncheck-cfg = [\"cfg(craft_pdf_unicode_fixtures)\"]\n\n[lints.clippy]\ncognitive_complexity = \"deny\"\ntoo_many_arguments = \"deny\"\nunused_workspace_dependencies = \"allow\"\nwildcard_imports = \"deny\"\ndbg_macro = \"warn\"\ntodo = \"warn\"\n\n[features]\ndefault = []\nread = [\"dep:hayro-syntax\", \"dep:thiserror\"]\ninterpret = [\"read\", \"dep:hayro-interpret\"]\npaths = [\"interpret\", \"dep:kurbo\"]\nraster = [\"interpret\", \"dep:hayro\", \"dep:bytemuck\"]\nwrite = [\"dep:krilla\", \"dep:thiserror\"]\nwrite-svg = [\"write\", \"dep:craft-svg\", \"dep:krilla-svg\", \"dep:usvg\", \"craft-svg/tree-text\"]\nwrite-pdf = [\"write\", \"krilla/pdf\"]\nwrite-raster = [\"dep:flate2\", \"dep:roxmltree\"]\nwrite-simple-text = [\"write\", \"krilla/simple-text\"]\nfilters = [\"dep:craft-stream-codecs\", \"dep:flate2\", \"dep:thiserror\"]\ncos = [\"crypt\", \"filters\", \"dep:chrono\", \"dep:js-sys\", \"dep:wasm-bindgen\"]\ncrypt = [\"dep:aes\", \"dep:md-5\", \"dep:sha2\", \"dep:stringprep\", \"dep:zeroize\", \"dep:thiserror\"]\n\n[dependencies.hayro-syntax]\noptional = true\nversion = \"=0.7.2\"\ndefault-features = false\nfeatures = [\"std\"]\n\n[dependencies.hayro-interpret]\noptional = true\nversion = \"=0.7.0\"\ndefault-features = false\nfeatures = [\"embed-fonts\", \"embed-cmaps\"]\n\n[dependencies.hayro]\noptional = true\nversion = \"=0.7.1\"\ndefault-features = false\n\n[dependencies.bytemuck]\noptional = true\nversion = \"1\"\n\n[dependencies.krilla]\noptional = true\nversion = \"=0.8.2\"\ndefault-features = false\nfeatures = [\"raster-images\"]\n\n[dependencies.craft-svg]\noptional = true\npath = \"crates/svg\"\n\n[dependencies.krilla-svg]\nversion = \"=0.8.1\"\noptional = true\n\n[dependencies.usvg]\nversion = \"=0.47.0\"\nfeatures = [\"text\"]\noptional = true\n\n[dependencies.thiserror]\noptional = true\nversion = \"2\"\n\n[dependencies.flate2]\nversion = \"1.1\"\ndefault-features = false\nfeatures = [\"zlib-rs\"]\noptional = true\n\n[dependencies.roxmltree]\nversion = \"0.21\"\noptional = true\n\n[dependencies.craft-stream-codecs]\noptional = true\npath = \"crates/stream-codecs\"\n\n[dependencies.aes]\nversion = \"0.9\"\noptional = true\n\n[dependencies.md-5]\nversion = \"0.11\"\noptional = true\n\n[dependencies.sha2]\nversion = \"0.11\"\noptional = true\n\n[dependencies.stringprep]\nversion = \"0.1\"\noptional = true\n\n[dependencies.zeroize]\nversion = \"1\"\noptional = true\n\n[dependencies.chrono]\noptional = true\nversion = \"0.4.45\"\ndefault-features = false\nfeatures = [\"std\"]\n\n[dependencies.kurbo]\noptional = true\nversion = \"0.13\"\n\n[target.\"cfg(target_arch = \\\"wasm32\\\")\".dependencies.js-sys]\nversion = \"0.3\"\noptional = true\n\n[target.\"cfg(target_arch = \\\"wasm32\\\")\".dependencies.wasm-bindgen]\nversion = \"0.2\"\noptional = true\n\n[target.\"cfg(target_arch = \\\"wasm32\\\")\".dev-dependencies]\nwasm-bindgen-test = \"0.3\"\n\n[target.\"cfg(not(target_arch = \\\"wasm32\\\"))\".dev-dependencies]\nproptest = \"1\"\n\n[dev-dependencies]\nserde_json = \"1\"\nhayro-syntax = \"=0.7.2\"\nhayro-cmap = \"=0.1.0\"\nkurbo = \"0.13\"\nttf-parser = \"=0.25.1\"\n\n[dev-dependencies.hayro-interpret]\nversion = \"=0.7.0\"\ndefault-features = false\n\n[[example]]\nname = \"cos_info\"\nrequired-features = [\"cos\"]\n\n[[example]]\nname = \"cos_protect\"\nrequired-features = [\"cos\"]\n", + "dest": "cargo/vendor/craft-pdf", + "dest-filename": "Cargo.toml" + }, + { + "type": "inline", + "contents": "{\"package\": null, \"files\": {}}", + "dest": "cargo/vendor/craft-pdf", + "dest-filename": ".cargo-checksum.json" + }, + { + "type": "shell", + "commands": [ + "cp -r --reflink=auto \"flatpak-cargo/git/craft-libs-9dcbd90/crates/psd\" \"cargo/vendor/craft-psd\"" + ] + }, + { + "type": "inline", + "contents": "[package]\nname = \"craft-psd\"\ndescription = \"Faithful, lossless reader and writer for Adobe Photoshop PSD and PSB files, and for the Photoshop resource files that share their primitives (ABR, ASL, ACO, ACT, ASE, GRD, PAT, ATN, CSH, SHC)\"\nversion = \"0.1.0\"\nedition = \"2024\"\nlicense = \"MIT OR Apache-2.0\"\nrust-version = \"1.95\"\nrepository = \"https://github.com/storytold/craft-libs\"\n\n[features]\ncorpus = []\ndefault = []\nserde = [\"dep:serde\"]\ntestgen = []\n\n[dependencies]\nthiserror = \"2\"\nencoding_rs = \"0.8\"\n\n[dependencies.flate2]\nversion = \"1.1.10\"\ndefault-features = false\nfeatures = [\"zlib-rs\", \"runtime_detection\"]\n\n[dependencies.serde]\noptional = true\nversion = \"1\"\nfeatures = [\"derive\"]\n\n[target.\"cfg(not(target_arch = \\\"wasm32\\\"))\".dependencies]\nrayon = \"1\"\n\n[dev-dependencies]\nproptest = \"1\"\n\n[dev-dependencies.craft-psd]\npath = \".\"\nfeatures = [\"testgen\"]\n\n[lints.rust]\nunsafe_code = \"forbid\"\nunused_workspace_dependencies = \"allow\"\n\n[lints.rust.unexpected_cfgs]\nlevel = \"warn\"\ncheck-cfg = [\"cfg(craft_pdf_unicode_fixtures)\"]\n\n[lints.clippy]\ncognitive_complexity = \"deny\"\ntoo_many_arguments = \"deny\"\nunused_workspace_dependencies = \"allow\"\nwildcard_imports = \"deny\"\ndbg_macro = \"warn\"\ntodo = \"warn\"\n", + "dest": "cargo/vendor/craft-psd", + "dest-filename": "Cargo.toml" + }, + { + "type": "inline", + "contents": "{\"package\": null, \"files\": {}}", + "dest": "cargo/vendor/craft-psd", + "dest-filename": ".cargo-checksum.json" + }, + { + "type": "shell", + "commands": [ + "cp -r --reflink=auto \"flatpak-cargo/git/craft-libs-94777dc/crates/raw\" \"cargo/vendor/craft-raw\"" + ] + }, + { + "type": "inline", + "contents": "[package]\nname = \"craft-raw\"\ndescription = \"Camera raw files, the file-format layer: container parsing, decompression and the sensor data out as a neutral raw image with its levels, crop, orientation, colour tags and embedded previews. DNG (read and write), Hasselblad 3FR/FFF, MRW, ERF, MEF, Kodak DCS, Pentax PEF, Samsung SRW, Canon CR2, Nikon NEF/NRW, Panasonic RW2, Fujifilm RAF, Olympus ORF (uncompressed), Sony ARW, Canon CR3 and Canon CRW so far.\"\nversion = \"0.1.0\"\nedition = \"2024\"\nlicense = \"MIT OR Apache-2.0\"\nrust-version = \"1.95\"\nrepository = \"https://github.com/storytold/craft-libs\"\n\n[lints.rust]\nunsafe_code = \"forbid\"\nunused_workspace_dependencies = \"allow\"\n\n[lints.rust.unexpected_cfgs]\nlevel = \"warn\"\ncheck-cfg = [\"cfg(craft_pdf_unicode_fixtures)\"]\n\n[lints.clippy]\ncognitive_complexity = \"deny\"\ntoo_many_arguments = \"deny\"\nunused_workspace_dependencies = \"allow\"\nwildcard_imports = \"deny\"\ndbg_macro = \"warn\"\ntodo = \"warn\"\n\n[features]\ndefault = [\"dng\", \"jxl\", \"crw\", \"hasselblad\", \"mrw\", \"erf\", \"mef\", \"kodak\", \"pef\", \"srw\", \"cr2\", \"nef\", \"rw2\", \"raf\", \"orf\", \"arw\", \"cr3\"]\ndng = [\"dep:miniz_oxide\", \"dep:zune-jpeg\", \"dep:zune-core\"]\njxl = [\"dng\", \"dep:jxl-oxide\"]\nhasselblad = [\"dng\"]\nmrw = []\nerf = []\nmef = []\nkodak = []\npef = []\nsrw = []\ncr2 = []\nnef = []\nrw2 = []\nraf = []\norf = []\narw = []\ncr3 = [\"dep:craft-metadata\"]\ncrw = [\"dep:craft-crw\", \"dep:chrono\"]\n\n[dependencies]\nthiserror = \"2\"\nrayon = \"1\"\n\n[dependencies.craft-tiff]\npath = \"crates/tiff\"\n\n[dependencies.craft-crw]\noptional = true\npath = \"crates/crw\"\n\n[dependencies.craft-metadata]\noptional = true\npath = \"crates/metadata\"\n\n[dependencies.serde]\nversion = \"1\"\nfeatures = [\"derive\"]\n\n[dependencies.chrono]\noptional = true\nversion = \"0.4.45\"\ndefault-features = false\nfeatures = [\"std\"]\n\n[dependencies.miniz_oxide]\nversion = \"0.9\"\noptional = true\n\n[dependencies.zune-jpeg]\nversion = \"0.5\"\ndefault-features = false\nfeatures = [\"std\", \"x86\", \"neon\"]\noptional = true\n\n[dependencies.zune-core]\nversion = \"0.5\"\ndefault-features = false\nfeatures = [\"std\"]\noptional = true\n\n[dependencies.jxl-oxide]\nversion = \"0.12\"\ndefault-features = false\noptional = true\n\n[dev-dependencies]\nproptest = \"1\"\n\n[dev-dependencies.sha2]\nversion = \"0.10\"\ndefault-features = false\nfeatures = [\"std\"]\n\n[dev-dependencies.jpeg-encoder]\nversion = \"0.7\"\ndefault-features = false\nfeatures = [\"std\"]\n\n[dev-dependencies.zune-jpegxl]\nversion = \"0.5\"\ndefault-features = false\nfeatures = [\"std\"]\n", + "dest": "cargo/vendor/craft-raw", + "dest-filename": "Cargo.toml" + }, + { + "type": "inline", + "contents": "{\"package\": null, \"files\": {}}", + "dest": "cargo/vendor/craft-raw", + "dest-filename": ".cargo-checksum.json" + }, + { + "type": "shell", + "commands": [ + "cp -r --reflink=auto \"flatpak-cargo/git/craft-libs-478c505/crates/tiff\" \"cargo/vendor/craft-tiff\"" + ] + }, + { + "type": "inline", + "contents": "[package]\nname = \"craft-tiff\"\ndescription = \"TIFF and BigTIFF IFD reader and writer: every field type, the Exif/GPS/Interop pointer IFDs, maker-note IFDs, strip and tile layout.\"\nversion = \"0.1.0\"\nedition = \"2024\"\nlicense = \"MIT OR Apache-2.0\"\nrust-version = \"1.95\"\nrepository = \"https://github.com/storytold/craft-libs\"\n\n[lints.rust]\nunsafe_code = \"forbid\"\nunused_workspace_dependencies = \"allow\"\n\n[lints.rust.unexpected_cfgs]\nlevel = \"warn\"\ncheck-cfg = [\"cfg(craft_pdf_unicode_fixtures)\"]\n\n[lints.clippy]\ncognitive_complexity = \"deny\"\ntoo_many_arguments = \"deny\"\nunused_workspace_dependencies = \"allow\"\nwildcard_imports = \"deny\"\ndbg_macro = \"warn\"\ntodo = \"warn\"\n\n[dependencies]\nthiserror = \"2\"\n\n[dependencies.serde]\nversion = \"1\"\nfeatures = [\"derive\"]\n\n[dev-dependencies]\nproptest = \"1\"\n", + "dest": "cargo/vendor/craft-tiff", + "dest-filename": "Cargo.toml" + }, + { + "type": "inline", + "contents": "{\"package\": null, \"files\": {}}", + "dest": "cargo/vendor/craft-tiff", + "dest-filename": ".cargo-checksum.json" + }, + { + "type": "shell", + "commands": [ + "cp -r --reflink=auto \"flatpak-cargo/git/craft-libs-94777dc/crates/tiff\" \"cargo/vendor/craft-tiff\"" + ] + }, + { + "type": "inline", + "contents": "[package]\nname = \"craft-tiff\"\ndescription = \"TIFF and BigTIFF IFD reader and writer: every field type, the Exif/GPS/Interop pointer IFDs, maker-note IFDs, strip and tile layout.\"\nversion = \"0.1.0\"\nedition = \"2024\"\nlicense = \"MIT OR Apache-2.0\"\nrust-version = \"1.95\"\nrepository = \"https://github.com/storytold/craft-libs\"\n\n[lints.rust]\nunsafe_code = \"forbid\"\nunused_workspace_dependencies = \"allow\"\n\n[lints.rust.unexpected_cfgs]\nlevel = \"warn\"\ncheck-cfg = [\"cfg(craft_pdf_unicode_fixtures)\"]\n\n[lints.clippy]\ncognitive_complexity = \"deny\"\ntoo_many_arguments = \"deny\"\nunused_workspace_dependencies = \"allow\"\nwildcard_imports = \"deny\"\ndbg_macro = \"warn\"\ntodo = \"warn\"\n\n[dependencies]\nthiserror = \"2\"\n\n[dependencies.serde]\nversion = \"1\"\nfeatures = [\"derive\"]\n\n[dev-dependencies]\nproptest = \"1\"\n", + "dest": "cargo/vendor/craft-tiff", + "dest-filename": "Cargo.toml" + }, + { + "type": "inline", + "contents": "{\"package\": null, \"files\": {}}", + "dest": "cargo/vendor/craft-tiff", + "dest-filename": ".cargo-checksum.json" + }, + { + "type": "shell", + "commands": [ + "cp -r --reflink=auto \"flatpak-cargo/git/craft-libs-c5a1cbf/crates/ui\" \"cargo/vendor/craft-ui\"" + ] + }, + { + "type": "inline", + "contents": "[package]\nname = \"craft-ui\"\nversion = \"0.1.0\"\nedition = \"2024\"\nlicense = \"MIT OR Apache-2.0\"\nrepository = \"https://github.com/storytold/craft-libs\"\nrust-version = \"1.95\"\ndescription = \"Reusable egui controls and icon catalogs for Craft frontends\"\n\n[lints.rust]\nunsafe_code = \"forbid\"\n\n[lints.rust.unexpected_cfgs]\nlevel = \"warn\"\ncheck-cfg = [\"cfg(craft_pdf_unicode_fixtures)\"]\n\n[lints.clippy]\ncognitive_complexity = \"deny\"\ntoo_many_arguments = \"deny\"\nwildcard_imports = \"deny\"\ndbg_macro = \"warn\"\ntodo = \"warn\"\n\n[dependencies]\nlog = \"0.4\"\n\n[dependencies.craft-fonts-build]\npath = \"crates/fonts-build\"\n\n[dependencies.craft-i18n]\npath = \"crates/i18n\"\n\n[dependencies.egui]\nversion = \"0.37\"\ndefault-features = false\n\n[dependencies.epaint]\nversion = \"0.37\"\ndefault-features = false\n\n[dependencies.serde]\nversion = \"1\"\nfeatures = [\"derive\"]\noptional = true\n\n[dependencies.skrifa]\nversion = \"0.44\"\ndefault-features = false\nfeatures = [\"std\"]\n\n[target.\"cfg(not(target_arch = \\\"wasm32\\\"))\".dependencies.egui_kittest]\nversion = \"0.37\"\nfeatures = [\"snapshot\", \"wgpu\"]\noptional = true\n\n[target.\"cfg(not(target_arch = \\\"wasm32\\\"))\".dependencies.fontique]\nversion = \"0.11.1\"\ndefault-features = false\nfeatures = [\"system\", \"fontconfig-dlopen\"]\noptional = true\n\n[target.\"cfg(not(target_arch = \\\"wasm32\\\"))\".dependencies.unicode-script]\nversion = \"0.5.8\"\noptional = true\n\n[target.\"cfg(not(target_arch = \\\"wasm32\\\"))\".dev-dependencies.egui_kittest]\nversion = \"0.37\"\nfeatures = [\"wgpu\"]\n\n[target.\"cfg(not(target_arch = \\\"wasm32\\\"))\".dev-dependencies.eframe]\nversion = \"0.37\"\ndefault-features = false\nfeatures = [\"wgpu\", \"x11\", \"default_fonts\"]\n\n[target.\"cfg(target_arch = \\\"wasm32\\\")\".dependencies]\njs-sys = \"0.3\"\nwasm-bindgen = \"0.2\"\nwasm-bindgen-futures = \"0.4\"\n\n[target.\"cfg(target_arch = \\\"wasm32\\\")\".dependencies.web-sys]\nversion = \"0.3\"\nfeatures = [\"Window\", \"RequestInit\", \"Response\", \"console\"]\n\n[target.\"cfg(target_arch = \\\"wasm32\\\")\".dev-dependencies]\njs-sys = \"0.3\"\nwasm-bindgen = \"0.2\"\nwasm-bindgen-futures = \"0.4\"\nwasm-bindgen-test = \"0.3\"\n\n[target.\"cfg(target_arch = \\\"wasm32\\\")\".dev-dependencies.web-sys]\nversion = \"0.3\"\nfeatures = [\"Window\", \"Response\"]\n\n[target.\"cfg(target_os = \\\"macos\\\")\".dependencies]\nobjc2 = \"0.6\"\n\n[target.\"cfg(target_os = \\\"macos\\\")\".dependencies.objc2-app-kit]\nversion = \"0.3\"\ndefault-features = false\nfeatures = [\"std\", \"objc2-core-foundation\", \"NSApplication\", \"NSEvent\", \"NSResponder\", \"NSScreen\", \"NSWindow\"]\n\n[target.\"cfg(target_os = \\\"macos\\\")\".dependencies.objc2-foundation]\nversion = \"0.3\"\ndefault-features = false\nfeatures = [\"std\", \"NSArray\", \"NSEnumerator\", \"NSString\"]\n\n[features]\ndefault = []\nserde = [\"dep:serde\"]\nnative-windows = []\ncolor_fonts = [\"epaint/color_fonts\"]\nsystem_fonts = [\"dep:fontique\", \"dep:unicode-script\"]\ntesting = []\nscreen-testing = [\"dep:egui_kittest\"]\n\n[dev-dependencies]\nserde_json = \"1\"\n\n[dev-dependencies.egui]\nfeatures = [\"default_fonts\", \"serde\"]\nversion = \"0.37\"\ndefault-features = false\n\n[dev-dependencies.egui_extras]\nversion = \"0.37\"\ndefault-features = false\nfeatures = [\"svg\"]\n\n[dev-dependencies.image]\nversion = \"0.25\"\ndefault-features = false\nfeatures = [\"png\"]\n\n[[example]]\nname = \"docking_native\"\nrequired-features = [\"native-windows\"]\n\n[[test]]\nname = \"screens\"\nrequired-features = [\"screen-testing\"]\n", "dest": "cargo/vendor/craft-ui", "dest-filename": "Cargo.toml" }, @@ -1411,17 +1945,71 @@ "dest": "cargo/vendor/craft-ui", "dest-filename": ".cargo-checksum.json" }, + { + "type": "shell", + "commands": [ + "cp -r --reflink=auto \"flatpak-cargo/git/craft-libs-6e03f65/crates/update\" \"cargo/vendor/craft-update\"" + ] + }, + { + "type": "inline", + "contents": "[package]\nname = \"craft-update\"\ndescription = \"Release checking, downloading, installing and self-updating for the Craft App Suite and ArtCraft Launcher\"\nversion = \"0.1.0\"\nedition = \"2024\"\nlicense = \"MIT OR Apache-2.0\"\nrust-version = \"1.95\"\nrepository = \"https://github.com/storytold/craft-libs\"\n\n[lints.rust]\nunsafe_code = \"forbid\"\n\n[lints.rust.unexpected_cfgs]\nlevel = \"warn\"\ncheck-cfg = [\"cfg(craft_pdf_unicode_fixtures)\"]\n\n[lints.clippy]\ncognitive_complexity = \"deny\"\ntoo_many_arguments = \"deny\"\nwildcard_imports = \"deny\"\ndbg_macro = \"warn\"\ntodo = \"warn\"\n\n[features]\ndefault = []\negui = [\"dep:egui\", \"dep:image\"]\nlocal-mirror = []\nsnapshot = [\"egui\", \"egui_kittest/wgpu\"]\n\n[dependencies]\nserde_json = \"1\"\nlog = \"0.4\"\ngetrandom = \"0.3\"\ntempfile = \"3\"\nsha2 = \"0.10\"\n\n[dependencies.egui]\noptional = true\nversion = \"0.37\"\ndefault-features = false\n\n[dependencies.image]\nversion = \"0.25\"\ndefault-features = false\nfeatures = [\"png\"]\noptional = true\n\n[dependencies.serde]\nversion = \"1\"\nfeatures = [\"derive\"]\n\n[dependencies.ureq]\nversion = \"3.4\"\ndefault-features = false\nfeatures = [\"rustls-no-provider\", \"_ring\", \"gzip\", \"platform-verifier\"]\n\n[dependencies.chrono]\nversion = \"0.4.45\"\ndefault-features = false\nfeatures = [\"std\"]\n\n[dependencies.semver]\nversion = \"1\"\nfeatures = [\"serde\"]\n\n[dev-dependencies]\nflate2 = \"1\"\negui_kittest = \"0.37\"\nepaint_default_fonts = \"0.37\"\n\n[target.\"cfg(unix)\".dependencies]\nflate2 = \"1\"\n\n[target.\"cfg(unix)\".dependencies.tar]\nversion = \"0.4\"\ndefault-features = false\n\n[target.\"cfg(target_os = \\\"macos\\\")\".dependencies]\nplist = \"1\"\n\n[target.\"cfg(any(target_os = \\\"macos\\\", target_os = \\\"linux\\\"))\".dependencies.rustix]\nversion = \"1.1\"\ndefault-features = false\nfeatures = [\"std\", \"fs\", \"process\"]\n\n[target.\"cfg(target_os = \\\"windows\\\")\".dependencies]\nwinreg = \"0.55\"\ndunce = \"1\"\nflate2 = \"1\"\nverifysign = \"1\"\n\n[target.\"cfg(target_os = \\\"windows\\\")\".dependencies.zip]\nversion = \"9\"\ndefault-features = false\nfeatures = [\"deflate-flate2\"]\n\n[target.\"cfg(target_os = \\\"windows\\\")\".dependencies.winsafe]\nversion = \"0.0.29\"\nfeatures = [\"advapi\", \"kernel\", \"shell\", \"version\"]\n", + "dest": "cargo/vendor/craft-update", + "dest-filename": "Cargo.toml" + }, + { + "type": "inline", + "contents": "{\"package\": null, \"files\": {}}", + "dest": "cargo/vendor/craft-update", + "dest-filename": ".cargo-checksum.json" + }, + { + "type": "shell", + "commands": [ + "cp -r --reflink=auto \"flatpak-cargo/git/craft-libs-c5a1cbf/crates/window\" \"cargo/vendor/craft-window\"" + ] + }, + { + "type": "inline", + "contents": "[package]\nname = \"craft-window\"\ndescription = \"Decide who draws the window frame (the desktop or the app) so every Craft app gets the same titlebar and borders per desktop, make an app-drawn strip act as the title bar, and keep the window list, cascade placement and Window menu for apps with one window per document.\"\nversion = \"0.1.0\"\nedition = \"2024\"\nlicense = \"MIT OR Apache-2.0\"\nrust-version = \"1.95\"\nrepository = \"https://github.com/storytold/craft-libs\"\n\n[features]\negui = [\"dep:egui\", \"dep:objc2\", \"dep:objc2-app-kit\"]\n\n[dependencies.egui]\noptional = true\nversion = \"0.37\"\ndefault-features = false\n\n[target.\"cfg(any(target_os = \\\"linux\\\", target_os = \\\"freebsd\\\", target_os = \\\"openbsd\\\", target_os = \\\"netbsd\\\"))\".dependencies]\nwayland-client = \"0.31\"\n\n[target.\"cfg(target_os = \\\"macos\\\")\".dependencies.objc2]\nversion = \"0.6.4\"\ndefault-features = false\nfeatures = [\"std\"]\noptional = true\n\n[target.\"cfg(target_os = \\\"macos\\\")\".dependencies.objc2-app-kit]\nversion = \"0.3.2\"\ndefault-features = false\nfeatures = [\"std\", \"NSApplication\", \"NSButton\", \"NSControl\", \"NSResponder\", \"NSView\", \"NSWindow\"]\noptional = true\n\n[lints.rust]\nunsafe_code = \"forbid\"\n\n[lints.rust.unexpected_cfgs]\nlevel = \"warn\"\ncheck-cfg = [\"cfg(craft_pdf_unicode_fixtures)\"]\n\n[lints.clippy]\ncognitive_complexity = \"deny\"\ntoo_many_arguments = \"deny\"\nwildcard_imports = \"deny\"\ndbg_macro = \"warn\"\ntodo = \"warn\"\n", + "dest": "cargo/vendor/craft-window", + "dest-filename": "Cargo.toml" + }, + { + "type": "inline", + "contents": "{\"package\": null, \"files\": {}}", + "dest": "cargo/vendor/craft-window", + "dest-filename": ".cargo-checksum.json" + }, + { + "type": "shell", + "commands": [ + "cp -r --reflink=auto \"flatpak-cargo/git/craft-libs-f0f4758/crates/xml\" \"cargo/vendor/craft-xml\"" + ] + }, + { + "type": "inline", + "contents": "[package]\nname = \"craft-xml\"\ndescription = \"Bounded XML for hostile input: an owned element tree, streaming of repeated elements, a pull reader, escaping and a writer. No DTDs, no entity expansion.\"\nversion = \"0.1.0\"\nedition = \"2024\"\nlicense = \"MIT OR Apache-2.0\"\nrust-version = \"1.95\"\nrepository = \"https://github.com/storytold/craft-libs\"\n\n[lints.rust]\nunsafe_code = \"forbid\"\nunused_workspace_dependencies = \"allow\"\n\n[lints.rust.unexpected_cfgs]\nlevel = \"warn\"\ncheck-cfg = [\"cfg(craft_pdf_unicode_fixtures)\"]\n\n[lints.clippy]\ncognitive_complexity = \"deny\"\ntoo_many_arguments = \"deny\"\nunused_workspace_dependencies = \"allow\"\nwildcard_imports = \"deny\"\ndbg_macro = \"warn\"\ntodo = \"warn\"\n\n[dependencies]\nthiserror = \"2\"\n\n[dependencies.quick-xml]\nversion = \"0.41\"\ndefault-features = false\n", + "dest": "cargo/vendor/craft-xml", + "dest-filename": "Cargo.toml" + }, + { + "type": "inline", + "contents": "{\"package\": null, \"files\": {}}", + "dest": "cargo/vendor/craft-xml", + "dest-filename": ".cargo-checksum.json" + }, { "type": "archive", "archive-type": "tar-gzip", - "url": "https://static.crates.io/crates/crc32fast/crc32fast-1.5.2.crate", - "sha256": "01a7799fd6b852db0e61728dde9a204c423b44d689dbd432522543614b490e78", - "dest": "cargo/vendor/crc32fast-1.5.2" + "url": "https://static.crates.io/crates/crc32fast/crc32fast-1.5.3.crate", + "sha256": "0ba106e844045ddc02c20768ac4b0b7cb45f2cc2ecbd833ac9f5dacb183c2055", + "dest": "cargo/vendor/crc32fast-1.5.3" }, { "type": "inline", - "contents": "{\"package\": \"01a7799fd6b852db0e61728dde9a204c423b44d689dbd432522543614b490e78\", \"files\": {}}", - "dest": "cargo/vendor/crc32fast-1.5.2", + "contents": "{\"package\": \"0ba106e844045ddc02c20768ac4b0b7cb45f2cc2ecbd833ac9f5dacb183c2055\", \"files\": {}}", + "dest": "cargo/vendor/crc32fast-1.5.3", "dest-filename": ".cargo-checksum.json" }, { @@ -1580,6 +2168,19 @@ "dest": "cargo/vendor/der-0.7.10", "dest-filename": ".cargo-checksum.json" }, + { + "type": "archive", + "archive-type": "tar-gzip", + "url": "https://static.crates.io/crates/deranged/deranged-0.5.9.crate", + "sha256": "9e9de72ce2ad1f90dc62fa25f0f430ef85eb4b0d8fa0be4f30373bc40a21d28e", + "dest": "cargo/vendor/deranged-0.5.9" + }, + { + "type": "inline", + "contents": "{\"package\": \"9e9de72ce2ad1f90dc62fa25f0f430ef85eb4b0d8fa0be4f30373bc40a21d28e\", \"files\": {}}", + "dest": "cargo/vendor/deranged-0.5.9", + "dest-filename": ".cargo-checksum.json" + }, { "type": "archive", "archive-type": "tar-gzip", @@ -1645,6 +2246,19 @@ "dest": "cargo/vendor/dispatch2-0.3.1", "dest-filename": ".cargo-checksum.json" }, + { + "type": "archive", + "archive-type": "tar-gzip", + "url": "https://static.crates.io/crates/displaydoc/displaydoc-0.2.7.crate", + "sha256": "c6232dd377dcc64799954cbd3a9bb882e9cdc1308ccd87b1c098f1fb2eaf82a8", + "dest": "cargo/vendor/displaydoc-0.2.7" + }, + { + "type": "inline", + "contents": "{\"package\": \"c6232dd377dcc64799954cbd3a9bb882e9cdc1308ccd87b1c098f1fb2eaf82a8\", \"files\": {}}", + "dest": "cargo/vendor/displaydoc-0.2.7", + "dest-filename": ".cargo-checksum.json" + }, { "type": "archive", "archive-type": "tar-gzip", @@ -1697,6 +2311,19 @@ "dest": "cargo/vendor/dpi-0.1.2", "dest-filename": ".cargo-checksum.json" }, + { + "type": "archive", + "archive-type": "tar-gzip", + "url": "https://static.crates.io/crates/dunce/dunce-1.0.5.crate", + "sha256": "92773504d58c093f6de2459af4af33faa518c13451eb8f2b5698ed3d36e7c813", + "dest": "cargo/vendor/dunce-1.0.5" + }, + { + "type": "inline", + "contents": "{\"package\": \"92773504d58c093f6de2459af4af33faa518c13451eb8f2b5698ed3d36e7c813\", \"files\": {}}", + "dest": "cargo/vendor/dunce-1.0.5", + "dest-filename": ".cargo-checksum.json" + }, { "type": "archive", "archive-type": "tar-gzip", @@ -1865,6 +2492,24 @@ "dest": "cargo/vendor/egui-winit", "dest-filename": ".cargo-checksum.json" }, + { + "type": "shell", + "commands": [ + "cp -r --reflink=auto \"flatpak-cargo/git/egui-6d518fc/crates/egui_extras\" \"cargo/vendor/egui_extras\"" + ] + }, + { + "type": "inline", + "contents": "[package]\nname = \"egui_extras\"\nversion = \"0.37.0\"\nauthors = [\"Dominik R\u00f6ssler <dominik@freshx.de>\", \"Emil Ernerfeldt <emil.ernerfeldt@gmail.com>\", \"Ren\u00e9 R\u00f6ssler <rene@freshx.de>\"]\ndescription = \"Extra functionality and widgets for the egui GUI library\"\nedition = \"2024\"\nrust-version = \"1.95\"\nhomepage = \"https://github.com/emilk/egui\"\nlicense = \"MIT OR Apache-2.0\"\nreadme = \"README.md\"\nrepository = \"https://github.com/emilk/egui\"\ncategories = [\"gui\", \"game-development\"]\nkeywords = [\"gui\", \"imgui\", \"immediate\", \"portable\", \"gamedev\"]\ninclude = [\"../../LICENSE-APACHE\", \"../../LICENSE-MIT\", \"**/*.rs\", \"Cargo.toml\"]\n\n[package.metadata.docs.rs]\nall-features = true\nrustdoc-args = [\"--generate-link-to-definition\"]\n\n[lints.rust]\nunsafe_code = \"deny\"\ntrivial_numeric_casts = \"warn\"\nunused_import_braces = \"warn\"\nunused_lifetimes = \"warn\"\ntrivial_casts = \"allow\"\nunused_qualifications = \"allow\"\n\n[lints.rust.future_incompatible]\nlevel = \"warn\"\npriority = -1\n\n[lints.rust.nonstandard_style]\nlevel = \"warn\"\npriority = -1\n\n[lints.rust.rust_2018_idioms]\nlevel = \"warn\"\npriority = -1\n\n[lints.rust.unexpected_cfgs]\nlevel = \"warn\"\ncheck-cfg = [\"cfg(web_sys_unstable_apis)\"]\n\n[lints.rustdoc]\nall = \"warn\"\n\n[lints.clippy]\nallow_attributes = \"warn\"\nas_ptr_cast_mut = \"warn\"\nbranches_sharing_code = \"warn\"\nclear_with_drain = \"warn\"\nclone_on_ref_ptr = \"warn\"\ncoerce_container_to_any = \"warn\"\ndbg_macro = \"warn\"\ndebug_assert_with_mut_call = \"warn\"\ndefault_union_representation = \"warn\"\nderive_partial_eq_without_eq = \"warn\"\ndisallowed_script_idents = \"warn\"\ndoc_include_without_cfg = \"warn\"\nempty_enum_variants_with_brackets = \"warn\"\nequatable_if_let = \"warn\"\nexit = \"warn\"\nfallible_impl_from = \"warn\"\nfloat_cmp_const = \"warn\"\nfn_to_numeric_cast_any = \"warn\"\nget_unwrap = \"warn\"\nimprecise_flops = \"warn\"\ninfinite_loop = \"warn\"\niter_on_empty_collections = \"warn\"\niter_on_single_items = \"warn\"\niter_over_hash_type = \"warn\"\nlarge_include_file = \"warn\"\nlarge_stack_frames = \"warn\"\nliteral_string_with_formatting_args = \"warn\"\nlossy_float_literal = \"warn\"\nmap_err_ignore = \"warn\"\nmem_forget = \"warn\"\nmissing_assert_message = \"warn\"\nmutex_integer = \"warn\"\nneedless_pass_by_ref_mut = \"warn\"\nneedless_type_cast = \"warn\"\nnon_zero_suggestions = \"warn\"\nnonstandard_macro_braces = \"warn\"\nor_fun_call = \"warn\"\npath_buf_push_overwrite = \"warn\"\npathbuf_init_then_push = \"warn\"\nprecedence_bits = \"warn\"\nprint_stderr = \"warn\"\nprint_stdout = \"warn\"\npub_without_shorthand = \"warn\"\nrc_mutex = \"warn\"\nredundant_type_annotations = \"warn\"\nref_patterns = \"warn\"\nrest_pat_in_fully_bound_structs = \"warn\"\nreturn_and_then = \"warn\"\nset_contains_or_insert = \"warn\"\nsingle_option_map = \"warn\"\nstd_instead_of_core = \"warn\"\nstr_to_string = \"warn\"\nstring_add = \"warn\"\nstring_lit_as_bytes = \"warn\"\nstring_lit_chars_any = \"warn\"\nsuspicious_xor_used_as_pow = \"warn\"\ntodo = \"warn\"\ntoo_long_first_doc_paragraph = \"warn\"\ntrailing_empty_array = \"warn\"\ntrait_duplication_in_bounds = \"warn\"\ntuple_array_conversions = \"warn\"\nundocumented_unsafe_blocks = \"warn\"\nunimplemented = \"warn\"\nuninhabited_references = \"warn\"\nunnecessary_safety_comment = \"warn\"\nunnecessary_safety_doc = \"warn\"\nunnecessary_self_imports = \"warn\"\nunnecessary_struct_initialization = \"warn\"\nunused_peekable = \"warn\"\nunused_rounding = \"warn\"\nunused_trait_names = \"warn\"\nunwrap_used = \"warn\"\nuse_self = \"warn\"\nuseless_let_if_seq = \"warn\"\nverbose_file_reads = \"warn\"\ncast_lossless = \"allow\"\ncast_possible_truncation = \"allow\"\ncast_possible_wrap = \"allow\"\ncast_precision_loss = \"allow\"\ncast_sign_loss = \"allow\"\ncomparison_chain = \"allow\"\ndefault_trait_access = \"allow\"\nfloat_cmp = \"allow\"\ninline_always = \"allow\"\nitems_after_statements = \"allow\"\nmany_single_char_names = \"allow\"\nmissing_panics_doc = \"allow\"\nmust_use_candidate = \"allow\"\nredundant_closure_for_method_calls = \"allow\"\nreturn_self_not_must_use = \"allow\"\nshould_panic_without_expect = \"allow\"\nsimilar_names = \"allow\"\nstruct_excessive_bools = \"allow\"\nstruct_field_names = \"allow\"\ntoo_many_lines = \"allow\"\ntrivially_copy_pass_by_ref = \"allow\"\nunreadable_literal = \"allow\"\nused_underscore_binding = \"allow\"\nassigning_clones = \"allow\"\nmanual_range_contains = \"allow\"\nmap_unwrap_or = \"allow\"\nmultiple_crate_versions = \"allow\"\nwildcard_imports = \"allow\"\nlet_underscore_must_use = \"allow\"\nlet_underscore_untyped = \"allow\"\nself_named_module_files = \"allow\"\nsignificant_drop_tightening = \"allow\"\n\n[lints.clippy.all]\nlevel = \"warn\"\npriority = -1\n\n[lints.clippy.cargo]\nlevel = \"warn\"\npriority = -1\n\n[lints.clippy.pedantic]\nlevel = \"warn\"\npriority = -1\n\n[lib]\n\n[features]\ndefault = [\"dep:mime_guess2\"]\nall_loaders = [\"file\", \"http\", \"image\", \"svg\", \"gif\", \"webp\"]\ndatepicker = [\"jiff\"]\nfile = [\"dep:mime_guess2\"]\ngif = [\"image\", \"image/gif\"]\nwebp = [\"image\", \"image/webp\"]\nhttp = [\"dep:ehttp\"]\nimage = [\"dep:image\"]\nserde = [\"egui/serde\", \"enum-map/serde\", \"dep:serde\"]\nsvg = [\"resvg\"]\nsvg_text = [\"svg\", \"resvg/text\", \"resvg/system-fonts\"]\nsvg_images = [\"svg\", \"resvg/raster-images\"]\nsyntect = [\"dep:syntect\"]\n\n[dependencies]\nenum-map = \"3.1\"\nitertools = \"0.15.0\"\n\n[dependencies.egui]\ndefault-features = false\nversion = \"0.37.0\"\npath = \"crates/egui\"\n\n[dependencies.ahash]\nversion = \"0.8.12\"\ndefault-features = false\nfeatures = [\"no-rng\", \"std\"]\n\n[dependencies.log]\nversion = \"0.4.34\"\nfeatures = [\"std\"]\n\n[dependencies.profiling]\nversion = \"1.0\"\ndefault-features = false\n\n[dependencies.serde]\noptional = true\nversion = \"1.0\"\nfeatures = [\"derive\"]\n\n[dependencies.jiff]\noptional = true\nfeatures = [\"std\", \"tz-system\", \"js\"]\nversion = \"0.2.35\"\ndefault-features = false\n\n[dependencies.document-features]\noptional = true\nversion = \"0.2.12\"\n\n[dependencies.image]\noptional = true\nversion = \"0.25.10\"\ndefault-features = false\n\n[dependencies.mime_guess2]\noptional = true\nversion = \"2.3\"\ndefault-features = false\n\n[dependencies.syntect]\noptional = true\nfeatures = [\"default-fancy\"]\nversion = \"5.3\"\ndefault-features = false\n\n[dependencies.resvg]\noptional = true\nversion = \"0.45.1\"\ndefault-features = false\n\n[dependencies.ehttp]\noptional = true\nversion = \"0.7.1\"\ndefault-features = false\n\n[dev-dependencies]\ntempfile = \"3.27\"\n\n[dev-dependencies.egui]\nfeatures = [\"default_fonts\"]\nversion = \"0.37.0\"\npath = \"crates/egui\"\ndefault-features = false\n\n[dev-dependencies.egui_kittest]\npath = \"../egui_kittest\"\nfeatures = [\"snapshot\", \"wgpu\"]\n", + "dest": "cargo/vendor/egui_extras", + "dest-filename": "Cargo.toml" + }, + { + "type": "inline", + "contents": "{\"package\": null, \"files\": {}}", + "dest": "cargo/vendor/egui_extras", + "dest-filename": ".cargo-checksum.json" + }, { "type": "shell", "commands": [ @@ -1945,6 +2590,19 @@ "dest": "cargo/vendor/emath", "dest-filename": ".cargo-checksum.json" }, + { + "type": "archive", + "archive-type": "tar-gzip", + "url": "https://static.crates.io/crates/encoding_rs/encoding_rs-0.8.44.crate", + "sha256": "89253175e704ab869b04f9db224d38630e0211a53841a79181deae0889e169f5", + "dest": "cargo/vendor/encoding_rs-0.8.44" + }, + { + "type": "inline", + "contents": "{\"package\": \"89253175e704ab869b04f9db224d38630e0211a53841a79181deae0889e169f5\", \"files\": {}}", + "dest": "cargo/vendor/encoding_rs-0.8.44", + "dest-filename": ".cargo-checksum.json" + }, { "type": "archive", "archive-type": "tar-gzip", @@ -1971,6 +2629,32 @@ "dest": "cargo/vendor/enum-as-inner-0.6.1", "dest-filename": ".cargo-checksum.json" }, + { + "type": "archive", + "archive-type": "tar-gzip", + "url": "https://static.crates.io/crates/enum-map/enum-map-3.1.0.crate", + "sha256": "d4532960034c15ba2f55e9eee631040ecc473c32e6c4b200828c759840f13a06", + "dest": "cargo/vendor/enum-map-3.1.0" + }, + { + "type": "inline", + "contents": "{\"package\": \"d4532960034c15ba2f55e9eee631040ecc473c32e6c4b200828c759840f13a06\", \"files\": {}}", + "dest": "cargo/vendor/enum-map-3.1.0", + "dest-filename": ".cargo-checksum.json" + }, + { + "type": "archive", + "archive-type": "tar-gzip", + "url": "https://static.crates.io/crates/enum-map-derive/enum-map-derive-1.0.1.crate", + "sha256": "7127272f64b3e098f7d81f350d672081b879bff896d219c42370dc858b1af9ff", + "dest": "cargo/vendor/enum-map-derive-1.0.1" + }, + { + "type": "inline", + "contents": "{\"package\": \"7127272f64b3e098f7d81f350d672081b879bff896d219c42370dc858b1af9ff\", \"files\": {}}", + "dest": "cargo/vendor/enum-map-derive-1.0.1", + "dest-filename": ".cargo-checksum.json" + }, { "type": "archive", "archive-type": "tar-gzip", @@ -2163,6 +2847,19 @@ "dest": "cargo/vendor/event-listener-strategy-0.5.4", "dest-filename": ".cargo-checksum.json" }, + { + "type": "archive", + "archive-type": "tar-gzip", + "url": "https://static.crates.io/crates/exr/exr-1.74.3.crate", + "sha256": "cb29d0be702adf92c645d9b2f93472906ba83d400e59f98adb3770ce5c18c2f6", + "dest": "cargo/vendor/exr-1.74.3" + }, + { + "type": "inline", + "contents": "{\"package\": \"cb29d0be702adf92c645d9b2f93472906ba83d400e59f98adb3770ce5c18c2f6\", \"files\": {}}", + "dest": "cargo/vendor/exr-1.74.3", + "dest-filename": ".cargo-checksum.json" + }, { "type": "archive", "archive-type": "tar-gzip", @@ -2267,6 +2964,19 @@ "dest": "cargo/vendor/fiat-crypto-0.2.9", "dest-filename": ".cargo-checksum.json" }, + { + "type": "archive", + "archive-type": "tar-gzip", + "url": "https://static.crates.io/crates/filetime/filetime-0.2.29.crate", + "sha256": "5c287a33c7f0a620c38e641e7f60827713987b3c0f26e8ddc9462cc69cf75759", + "dest": "cargo/vendor/filetime-0.2.29" + }, + { + "type": "inline", + "contents": "{\"package\": \"5c287a33c7f0a620c38e641e7f60827713987b3c0f26e8ddc9462cc69cf75759\", \"files\": {}}", + "dest": "cargo/vendor/filetime-0.2.29", + "dest-filename": ".cargo-checksum.json" + }, { "type": "archive", "archive-type": "tar-gzip", @@ -2280,6 +2990,19 @@ "dest": "cargo/vendor/find-msvc-tools-0.1.14", "dest-filename": ".cargo-checksum.json" }, + { + "type": "archive", + "archive-type": "tar-gzip", + "url": "https://static.crates.io/crates/fixed_decimal/fixed_decimal-0.7.3.crate", + "sha256": "2214fb00f669ee96bee5bb29dfb1ddabe058b2bc426817efc79afa03c9bc55ae", + "dest": "cargo/vendor/fixed_decimal-0.7.3" + }, + { + "type": "inline", + "contents": "{\"package\": \"2214fb00f669ee96bee5bb29dfb1ddabe058b2bc426817efc79afa03c9bc55ae\", \"files\": {}}", + "dest": "cargo/vendor/fixed_decimal-0.7.3", + "dest-filename": ".cargo-checksum.json" + }, { "type": "archive", "archive-type": "tar-gzip", @@ -2410,6 +3133,19 @@ "dest": "cargo/vendor/foreign-types-shared-0.3.1", "dest-filename": ".cargo-checksum.json" }, + { + "type": "archive", + "archive-type": "tar-gzip", + "url": "https://static.crates.io/crates/fs4/fs4-1.1.0.crate", + "sha256": "7e72ed92b67c146290f88e9c89d60ca163ea417a446f61ffd7b72df3e7f1dfd5", + "dest": "cargo/vendor/fs4-1.1.0" + }, + { + "type": "inline", + "contents": "{\"package\": \"7e72ed92b67c146290f88e9c89d60ca163ea417a446f61ffd7b72df3e7f1dfd5\", \"files\": {}}", + "dest": "cargo/vendor/fs4-1.1.0", + "dest-filename": ".cargo-checksum.json" + }, { "type": "archive", "archive-type": "tar-gzip", @@ -3047,6 +3783,19 @@ "dest": "cargo/vendor/harfrust-0.12.0", "dest-filename": ".cargo-checksum.json" }, + { + "type": "archive", + "archive-type": "tar-gzip", + "url": "https://static.crates.io/crates/harfrust/harfrust-0.13.3.crate", + "sha256": "948d0741125ba89cd3e1c23e5642415b6ade7e1d29d67ba25fb925b533e989d6", + "dest": "cargo/vendor/harfrust-0.13.3" + }, + { + "type": "inline", + "contents": "{\"package\": \"948d0741125ba89cd3e1c23e5642415b6ade7e1d29d67ba25fb925b533e989d6\", \"files\": {}}", + "dest": "cargo/vendor/harfrust-0.13.3", + "dest-filename": ".cargo-checksum.json" + }, { "type": "archive", "archive-type": "tar-gzip", @@ -3086,6 +3835,19 @@ "dest": "cargo/vendor/hashbrown-0.17.1", "dest-filename": ".cargo-checksum.json" }, + { + "type": "archive", + "archive-type": "tar-gzip", + "url": "https://static.crates.io/crates/hayro-jpeg2000/hayro-jpeg2000-0.3.5.crate", + "sha256": "c75ab947623ef4ccaa7acf0579edf7cbb5a73838e3839a7be73335e522f433a1", + "dest": "cargo/vendor/hayro-jpeg2000-0.3.5" + }, + { + "type": "inline", + "contents": "{\"package\": \"c75ab947623ef4ccaa7acf0579edf7cbb5a73838e3839a7be73335e522f433a1\", \"files\": {}}", + "dest": "cargo/vendor/hayro-jpeg2000-0.3.5", + "dest-filename": ".cargo-checksum.json" + }, { "type": "archive", "archive-type": "tar-gzip", @@ -3164,6 +3926,214 @@ "dest": "cargo/vendor/hmac-0.12.1", "dest-filename": ".cargo-checksum.json" }, + { + "type": "archive", + "archive-type": "tar-gzip", + "url": "https://static.crates.io/crates/http/http-1.5.0.crate", + "sha256": "918d3568bebf352712bc2ef3d46a8bcf1a75b373be6539de198e9105cbbf9ce0", + "dest": "cargo/vendor/http-1.5.0" + }, + { + "type": "inline", + "contents": "{\"package\": \"918d3568bebf352712bc2ef3d46a8bcf1a75b373be6539de198e9105cbbf9ce0\", \"files\": {}}", + "dest": "cargo/vendor/http-1.5.0", + "dest-filename": ".cargo-checksum.json" + }, + { + "type": "archive", + "archive-type": "tar-gzip", + "url": "https://static.crates.io/crates/httparse/httparse-1.10.1.crate", + "sha256": "6dbf3de79e51f3d586ab4cb9d5c3e2c14aa28ed23d180cf89b4df0454a69cc87", + "dest": "cargo/vendor/httparse-1.10.1" + }, + { + "type": "inline", + "contents": "{\"package\": \"6dbf3de79e51f3d586ab4cb9d5c3e2c14aa28ed23d180cf89b4df0454a69cc87\", \"files\": {}}", + "dest": "cargo/vendor/httparse-1.10.1", + "dest-filename": ".cargo-checksum.json" + }, + { + "type": "archive", + "archive-type": "tar-gzip", + "url": "https://static.crates.io/crates/icu_collections/icu_collections-2.3.0.crate", + "sha256": "fa68d21081c4a05d5a901a1c62add574c77048b6a1c67be3b50ce0b60d4ca513", + "dest": "cargo/vendor/icu_collections-2.3.0" + }, + { + "type": "inline", + "contents": "{\"package\": \"fa68d21081c4a05d5a901a1c62add574c77048b6a1c67be3b50ce0b60d4ca513\", \"files\": {}}", + "dest": "cargo/vendor/icu_collections-2.3.0", + "dest-filename": ".cargo-checksum.json" + }, + { + "type": "archive", + "archive-type": "tar-gzip", + "url": "https://static.crates.io/crates/icu_decimal/icu_decimal-2.3.0.crate", + "sha256": "9eb8f655bba2d0c0459e43a5b0e6cd3cd388109898fb3d85d048165e8b0abd08", + "dest": "cargo/vendor/icu_decimal-2.3.0" + }, + { + "type": "inline", + "contents": "{\"package\": \"9eb8f655bba2d0c0459e43a5b0e6cd3cd388109898fb3d85d048165e8b0abd08\", \"files\": {}}", + "dest": "cargo/vendor/icu_decimal-2.3.0", + "dest-filename": ".cargo-checksum.json" + }, + { + "type": "archive", + "archive-type": "tar-gzip", + "url": "https://static.crates.io/crates/icu_locale_core/icu_locale_core-2.3.0.crate", + "sha256": "d56e28588da92eee5c3201a6eff33fabdd49b62269c8938d4ff050ce4d900deb", + "dest": "cargo/vendor/icu_locale_core-2.3.0" + }, + { + "type": "inline", + "contents": "{\"package\": \"d56e28588da92eee5c3201a6eff33fabdd49b62269c8938d4ff050ce4d900deb\", \"files\": {}}", + "dest": "cargo/vendor/icu_locale_core-2.3.0", + "dest-filename": ".cargo-checksum.json" + }, + { + "type": "archive", + "archive-type": "tar-gzip", + "url": "https://static.crates.io/crates/icu_locale_fallback/icu_locale_fallback-2.3.0.crate", + "sha256": "251af8e57c9400e3eb58242fe5b8b1152b2a64fdf4cf632f923c38ccee6f2fa9", + "dest": "cargo/vendor/icu_locale_fallback-2.3.0" + }, + { + "type": "inline", + "contents": "{\"package\": \"251af8e57c9400e3eb58242fe5b8b1152b2a64fdf4cf632f923c38ccee6f2fa9\", \"files\": {}}", + "dest": "cargo/vendor/icu_locale_fallback-2.3.0", + "dest-filename": ".cargo-checksum.json" + }, + { + "type": "archive", + "archive-type": "tar-gzip", + "url": "https://static.crates.io/crates/icu_locale_fallback_data/icu_locale_fallback_data-2.3.0.crate", + "sha256": "decf2a22ec8fa68f1a0c1129a3f8583f8f8bc24e8b9ccbe98ead99f62a4dc3a8", + "dest": "cargo/vendor/icu_locale_fallback_data-2.3.0" + }, + { + "type": "inline", + "contents": "{\"package\": \"decf2a22ec8fa68f1a0c1129a3f8583f8f8bc24e8b9ccbe98ead99f62a4dc3a8\", \"files\": {}}", + "dest": "cargo/vendor/icu_locale_fallback_data-2.3.0", + "dest-filename": ".cargo-checksum.json" + }, + { + "type": "archive", + "archive-type": "tar-gzip", + "url": "https://static.crates.io/crates/icu_normalizer/icu_normalizer-2.3.0.crate", + "sha256": "12f9cf5f235641ed274641dd81c3f28d870e276763d0797aeeab72317b1c646f", + "dest": "cargo/vendor/icu_normalizer-2.3.0" + }, + { + "type": "inline", + "contents": "{\"package\": \"12f9cf5f235641ed274641dd81c3f28d870e276763d0797aeeab72317b1c646f\", \"files\": {}}", + "dest": "cargo/vendor/icu_normalizer-2.3.0", + "dest-filename": ".cargo-checksum.json" + }, + { + "type": "archive", + "archive-type": "tar-gzip", + "url": "https://static.crates.io/crates/icu_normalizer_data/icu_normalizer_data-2.3.0.crate", + "sha256": "1563da1ed3e0b3bf3d74c9b85917ac9c56464d2f57242270c09c9e752f8021a0", + "dest": "cargo/vendor/icu_normalizer_data-2.3.0" + }, + { + "type": "inline", + "contents": "{\"package\": \"1563da1ed3e0b3bf3d74c9b85917ac9c56464d2f57242270c09c9e752f8021a0\", \"files\": {}}", + "dest": "cargo/vendor/icu_normalizer_data-2.3.0", + "dest-filename": ".cargo-checksum.json" + }, + { + "type": "archive", + "archive-type": "tar-gzip", + "url": "https://static.crates.io/crates/icu_pattern/icu_pattern-0.5.0.crate", + "sha256": "2b3db611446bd92c246b03e4aa0bafa71ddb194af431ddbb42b9d70e4bfce1a0", + "dest": "cargo/vendor/icu_pattern-0.5.0" + }, + { + "type": "inline", + "contents": "{\"package\": \"2b3db611446bd92c246b03e4aa0bafa71ddb194af431ddbb42b9d70e4bfce1a0\", \"files\": {}}", + "dest": "cargo/vendor/icu_pattern-0.5.0", + "dest-filename": ".cargo-checksum.json" + }, + { + "type": "archive", + "archive-type": "tar-gzip", + "url": "https://static.crates.io/crates/icu_plurals/icu_plurals-2.3.0.crate", + "sha256": "e475e6766ef87b1d3c1f97be6363995b0bfaeddbc789671615df598a97ff0593", + "dest": "cargo/vendor/icu_plurals-2.3.0" + }, + { + "type": "inline", + "contents": "{\"package\": \"e475e6766ef87b1d3c1f97be6363995b0bfaeddbc789671615df598a97ff0593\", \"files\": {}}", + "dest": "cargo/vendor/icu_plurals-2.3.0", + "dest-filename": ".cargo-checksum.json" + }, + { + "type": "archive", + "archive-type": "tar-gzip", + "url": "https://static.crates.io/crates/icu_properties/icu_properties-2.3.0.crate", + "sha256": "7e7ca276ad3145661a65914e6daf131ca5120cd3dcee8f8f3214b8875184a148", + "dest": "cargo/vendor/icu_properties-2.3.0" + }, + { + "type": "inline", + "contents": "{\"package\": \"7e7ca276ad3145661a65914e6daf131ca5120cd3dcee8f8f3214b8875184a148\", \"files\": {}}", + "dest": "cargo/vendor/icu_properties-2.3.0", + "dest-filename": ".cargo-checksum.json" + }, + { + "type": "archive", + "archive-type": "tar-gzip", + "url": "https://static.crates.io/crates/icu_properties_data/icu_properties_data-2.3.0.crate", + "sha256": "e590f038c1464a96894fd6d10127e90a8be4509f56ff7ecef851b15cee0b7caa", + "dest": "cargo/vendor/icu_properties_data-2.3.0" + }, + { + "type": "inline", + "contents": "{\"package\": \"e590f038c1464a96894fd6d10127e90a8be4509f56ff7ecef851b15cee0b7caa\", \"files\": {}}", + "dest": "cargo/vendor/icu_properties_data-2.3.0", + "dest-filename": ".cargo-checksum.json" + }, + { + "type": "archive", + "archive-type": "tar-gzip", + "url": "https://static.crates.io/crates/icu_provider/icu_provider-2.3.1.crate", + "sha256": "d27bbb9d3abbefac45d55f647c9de1d44aafcd1186eb91879afef17c396c3e73", + "dest": "cargo/vendor/icu_provider-2.3.1" + }, + { + "type": "inline", + "contents": "{\"package\": \"d27bbb9d3abbefac45d55f647c9de1d44aafcd1186eb91879afef17c396c3e73\", \"files\": {}}", + "dest": "cargo/vendor/icu_provider-2.3.1", + "dest-filename": ".cargo-checksum.json" + }, + { + "type": "archive", + "archive-type": "tar-gzip", + "url": "https://static.crates.io/crates/icu_provider_adapters/icu_provider_adapters-2.3.0.crate", + "sha256": "df887bc4f55dbc773c7c45a0c7dfa75be886f7b7812830a71ab7271cc1801820", + "dest": "cargo/vendor/icu_provider_adapters-2.3.0" + }, + { + "type": "inline", + "contents": "{\"package\": \"df887bc4f55dbc773c7c45a0c7dfa75be886f7b7812830a71ab7271cc1801820\", \"files\": {}}", + "dest": "cargo/vendor/icu_provider_adapters-2.3.0", + "dest-filename": ".cargo-checksum.json" + }, + { + "type": "archive", + "archive-type": "tar-gzip", + "url": "https://static.crates.io/crates/icu_provider_blob/icu_provider_blob-2.3.0.crate", + "sha256": "5916b44fac319d3f58e4d8d805a627df19e27937b582cd99fcde3bb6b7ce1b0e", + "dest": "cargo/vendor/icu_provider_blob-2.3.0" + }, + { + "type": "inline", + "contents": "{\"package\": \"5916b44fac319d3f58e4d8d805a627df19e27937b582cd99fcde3bb6b7ce1b0e\", \"files\": {}}", + "dest": "cargo/vendor/icu_provider_blob-2.3.0", + "dest-filename": ".cargo-checksum.json" + }, { "type": "archive", "archive-type": "tar-gzip", @@ -3401,14 +4371,14 @@ { "type": "archive", "archive-type": "tar-gzip", - "url": "https://static.crates.io/crates/jpeg-decoder/jpeg-decoder-0.3.2.crate", - "sha256": "00810f1d8b74be64b13dbf3db89ac67740615d6c891f0e7b6179326533011a07", - "dest": "cargo/vendor/jpeg-decoder-0.3.2" + "url": "https://static.crates.io/crates/jpeg-encoder/jpeg-encoder-0.6.1.crate", + "sha256": "b454d911ac55068f53495488d8ccd0646eaa540c033a28ee15b07838afafb01f", + "dest": "cargo/vendor/jpeg-encoder-0.6.1" }, { "type": "inline", - "contents": "{\"package\": \"00810f1d8b74be64b13dbf3db89ac67740615d6c891f0e7b6179326533011a07\", \"files\": {}}", - "dest": "cargo/vendor/jpeg-decoder-0.3.2", + "contents": "{\"package\": \"b454d911ac55068f53495488d8ccd0646eaa540c033a28ee15b07838afafb01f\", \"files\": {}}", + "dest": "cargo/vendor/jpeg-encoder-0.6.1", "dest-filename": ".cargo-checksum.json" }, { @@ -3687,14 +4657,27 @@ { "type": "archive", "archive-type": "tar-gzip", - "url": "https://static.crates.io/crates/libc/libc-0.2.189.crate", - "sha256": "3eaf3ede3fee6db1a4c2ee091bf8a8b4dccdc6d17f656fb07896ee72867612f2", - "dest": "cargo/vendor/libc-0.2.189" + "url": "https://static.crates.io/crates/lebe/lebe-0.5.3.crate", + "sha256": "7a79a3332a6609480d7d0c9eab957bca6b455b91bb84e66d19f5ff66294b85b8", + "dest": "cargo/vendor/lebe-0.5.3" }, { "type": "inline", - "contents": "{\"package\": \"3eaf3ede3fee6db1a4c2ee091bf8a8b4dccdc6d17f656fb07896ee72867612f2\", \"files\": {}}", - "dest": "cargo/vendor/libc-0.2.189", + "contents": "{\"package\": \"7a79a3332a6609480d7d0c9eab957bca6b455b91bb84e66d19f5ff66294b85b8\", \"files\": {}}", + "dest": "cargo/vendor/lebe-0.5.3", + "dest-filename": ".cargo-checksum.json" + }, + { + "type": "archive", + "archive-type": "tar-gzip", + "url": "https://static.crates.io/crates/libc/libc-0.2.191.crate", + "sha256": "65cd87c9a6d60536580b316ad985726104730a5151c99845f2490428ef91240a", + "dest": "cargo/vendor/libc-0.2.191" + }, + { + "type": "inline", + "contents": "{\"package\": \"65cd87c9a6d60536580b316ad985726104730a5151c99845f2490428ef91240a\", \"files\": {}}", + "dest": "cargo/vendor/libc-0.2.191", "dest-filename": ".cargo-checksum.json" }, { @@ -3788,6 +4771,19 @@ "dest": "cargo/vendor/linux-raw-sys-0.12.1", "dest-filename": ".cargo-checksum.json" }, + { + "type": "archive", + "archive-type": "tar-gzip", + "url": "https://static.crates.io/crates/litemap/litemap-0.8.3.crate", + "sha256": "47d9d19d1d6efa0109d2f65ff4c85cddd50bd572e5a00127ab10987290bcefae", + "dest": "cargo/vendor/litemap-0.8.3" + }, + { + "type": "inline", + "contents": "{\"package\": \"47d9d19d1d6efa0109d2f65ff4c85cddd50bd572e5a00127ab10987290bcefae\", \"files\": {}}", + "dest": "cargo/vendor/litemap-0.8.3", + "dest-filename": ".cargo-checksum.json" + }, { "type": "archive", "archive-type": "tar-gzip", @@ -3892,6 +4888,19 @@ "dest": "cargo/vendor/maybe-rayon-0.1.1", "dest-filename": ".cargo-checksum.json" }, + { + "type": "archive", + "archive-type": "tar-gzip", + "url": "https://static.crates.io/crates/md-5/md-5-0.10.6.crate", + "sha256": "d89e7ee0cfbedfc4da3340218492196241d89eefb6dab27de5df917a6d2e78cf", + "dest": "cargo/vendor/md-5-0.10.6" + }, + { + "type": "inline", + "contents": "{\"package\": \"d89e7ee0cfbedfc4da3340218492196241d89eefb6dab27de5df917a6d2e78cf\", \"files\": {}}", + "dest": "cargo/vendor/md-5-0.10.6", + "dest-filename": ".cargo-checksum.json" + }, { "type": "archive", "archive-type": "tar-gzip", @@ -3999,27 +5008,53 @@ { "type": "archive", "archive-type": "tar-gzip", - "url": "https://static.crates.io/crates/moxcms/moxcms-0.9.1.crate", - "sha256": "396077b717181ce3f9a6b66739b269b82d756be5ec0f76be0bc40a7c51775830", - "dest": "cargo/vendor/moxcms-0.9.1" + "url": "https://static.crates.io/crates/muda/muda-0.21.2.crate", + "sha256": "4340e89c178916e62879c5c36b7f699019369be413e496178a6983ce91b8bc03", + "dest": "cargo/vendor/muda-0.21.2" }, { "type": "inline", - "contents": "{\"package\": \"396077b717181ce3f9a6b66739b269b82d756be5ec0f76be0bc40a7c51775830\", \"files\": {}}", - "dest": "cargo/vendor/moxcms-0.9.1", + "contents": "{\"package\": \"4340e89c178916e62879c5c36b7f699019369be413e496178a6983ce91b8bc03\", \"files\": {}}", + "dest": "cargo/vendor/muda-0.21.2", "dest-filename": ".cargo-checksum.json" }, { "type": "archive", "archive-type": "tar-gzip", - "url": "https://static.crates.io/crates/muda/muda-0.21.0.crate", - "sha256": "c6744ab645ebe79f9c428455c7cb9dfa4275fa3b50a25408e08f927da8dc618c", - "dest": "cargo/vendor/muda-0.21.0" + "url": "https://static.crates.io/crates/multiversion/multiversion-0.8.1.crate", + "sha256": "eb8a68be21d0755f83bfe47e79b896cc732687cf1903f0e50585e8d6ecc53076", + "dest": "cargo/vendor/multiversion-0.8.1" }, { "type": "inline", - "contents": "{\"package\": \"c6744ab645ebe79f9c428455c7cb9dfa4275fa3b50a25408e08f927da8dc618c\", \"files\": {}}", - "dest": "cargo/vendor/muda-0.21.0", + "contents": "{\"package\": \"eb8a68be21d0755f83bfe47e79b896cc732687cf1903f0e50585e8d6ecc53076\", \"files\": {}}", + "dest": "cargo/vendor/multiversion-0.8.1", + "dest-filename": ".cargo-checksum.json" + }, + { + "type": "archive", + "archive-type": "tar-gzip", + "url": "https://static.crates.io/crates/multiversion-macros/multiversion-macros-0.8.1.crate", + "sha256": "a05e0c3c3e4edaa21d87c645852ed0b0c3663752bcc6ec43353bd6189dce35e1", + "dest": "cargo/vendor/multiversion-macros-0.8.1" + }, + { + "type": "inline", + "contents": "{\"package\": \"a05e0c3c3e4edaa21d87c645852ed0b0c3663752bcc6ec43353bd6189dce35e1\", \"files\": {}}", + "dest": "cargo/vendor/multiversion-macros-0.8.1", + "dest-filename": ".cargo-checksum.json" + }, + { + "type": "archive", + "archive-type": "tar-gzip", + "url": "https://static.crates.io/crates/multiversion_no_op/multiversion_no_op-1.0.0.crate", + "sha256": "743fb55ba31b18fb1ecef6bdc9aa2743314978ac084044301a7eee33fb99a20d", + "dest": "cargo/vendor/multiversion_no_op-1.0.0" + }, + { + "type": "inline", + "contents": "{\"package\": \"743fb55ba31b18fb1ecef6bdc9aa2743314978ac084044301a7eee33fb99a20d\", \"files\": {}}", + "dest": "cargo/vendor/multiversion_no_op-1.0.0", "dest-filename": ".cargo-checksum.json" }, { @@ -4113,6 +5148,19 @@ "dest": "cargo/vendor/new_debug_unreachable-1.0.6", "dest-filename": ".cargo-checksum.json" }, + { + "type": "archive", + "archive-type": "tar-gzip", + "url": "https://static.crates.io/crates/nix/nix-0.31.3.crate", + "sha256": "cf20d2fde8ff38632c426f1165ed7436270b44f199fc55284c38276f9db47c3d", + "dest": "cargo/vendor/nix-0.31.3" + }, + { + "type": "inline", + "contents": "{\"package\": \"cf20d2fde8ff38632c426f1165ed7436270b44f199fc55284c38276f9db47c3d\", \"files\": {}}", + "dest": "cargo/vendor/nix-0.31.3", + "dest-filename": ".cargo-checksum.json" + }, { "type": "archive", "archive-type": "tar-gzip", @@ -4217,6 +5265,19 @@ "dest": "cargo/vendor/num-complex-0.4.6", "dest-filename": ".cargo-checksum.json" }, + { + "type": "archive", + "archive-type": "tar-gzip", + "url": "https://static.crates.io/crates/num-conv/num-conv-0.2.2.crate", + "sha256": "521739c6d2bac4aa25192232afe6841231376b2b26d4d9fae5ecf8ca5772e441", + "dest": "cargo/vendor/num-conv-0.2.2" + }, + { + "type": "inline", + "contents": "{\"package\": \"521739c6d2bac4aa25192232afe6841231376b2b26d4d9fae5ecf8ca5772e441\", \"files\": {}}", + "dest": "cargo/vendor/num-conv-0.2.2", + "dest-filename": ".cargo-checksum.json" + }, { "type": "archive", "archive-type": "tar-gzip", @@ -4363,14 +5424,14 @@ { "type": "archive", "archive-type": "tar-gzip", - "url": "https://static.crates.io/crates/objc2/objc2-0.6.4.crate", - "sha256": "3a12a8ed07aefc768292f076dc3ac8c48f3781c8f2d5851dd3d98950e8c5a89f", - "dest": "cargo/vendor/objc2-0.6.4" + "url": "https://static.crates.io/crates/objc2/objc2-0.6.5.crate", + "sha256": "08849bbd4767dfae9457696856ae1c84fe4e0281bbe4a7abff2d0e06fb7981f8", + "dest": "cargo/vendor/objc2-0.6.5" }, { "type": "inline", - "contents": "{\"package\": \"3a12a8ed07aefc768292f076dc3ac8c48f3781c8f2d5851dd3d98950e8c5a89f\", \"files\": {}}", - "dest": "cargo/vendor/objc2-0.6.4", + "contents": "{\"package\": \"08849bbd4767dfae9457696856ae1c84fe4e0281bbe4a7abff2d0e06fb7981f8\", \"files\": {}}", + "dest": "cargo/vendor/objc2-0.6.5", "dest-filename": ".cargo-checksum.json" }, { @@ -4724,6 +5785,19 @@ "dest": "cargo/vendor/open-5.4.4", "dest-filename": ".cargo-checksum.json" }, + { + "type": "archive", + "archive-type": "tar-gzip", + "url": "https://static.crates.io/crates/openssl-probe/openssl-probe-0.2.1.crate", + "sha256": "7c87def4c32ab89d880effc9e097653c8da5d6ef28e6b539d313baaacfbafcbe", + "dest": "cargo/vendor/openssl-probe-0.2.1" + }, + { + "type": "inline", + "contents": "{\"package\": \"7c87def4c32ab89d880effc9e097653c8da5d6ef28e6b539d313baaacfbafcbe\", \"files\": {}}", + "dest": "cargo/vendor/openssl-probe-0.2.1", + "dest-filename": ".cargo-checksum.json" + }, { "type": "archive", "archive-type": "tar-gzip", @@ -5101,6 +6175,19 @@ "dest": "cargo/vendor/plain-0.2.3", "dest-filename": ".cargo-checksum.json" }, + { + "type": "archive", + "archive-type": "tar-gzip", + "url": "https://static.crates.io/crates/plist/plist-1.10.3.crate", + "sha256": "327a4cb2ad49dc48adfdc9da89e22c64d488b508c67a044d71ba729e4521a285", + "dest": "cargo/vendor/plist-1.10.3" + }, + { + "type": "inline", + "contents": "{\"package\": \"327a4cb2ad49dc48adfdc9da89e22c64d488b508c67a044d71ba729e4521a285\", \"files\": {}}", + "dest": "cargo/vendor/plist-1.10.3", + "dest-filename": ".cargo-checksum.json" + }, { "type": "archive", "archive-type": "tar-gzip", @@ -5218,6 +6305,45 @@ "dest": "cargo/vendor/portable-atomic-util-0.2.8", "dest-filename": ".cargo-checksum.json" }, + { + "type": "archive", + "archive-type": "tar-gzip", + "url": "https://static.crates.io/crates/postcard/postcard-1.1.3.crate", + "sha256": "6764c3b5dd454e283a30e6dfe78e9b31096d9e32036b5d1eaac7a6119ccb9a24", + "dest": "cargo/vendor/postcard-1.1.3" + }, + { + "type": "inline", + "contents": "{\"package\": \"6764c3b5dd454e283a30e6dfe78e9b31096d9e32036b5d1eaac7a6119ccb9a24\", \"files\": {}}", + "dest": "cargo/vendor/postcard-1.1.3", + "dest-filename": ".cargo-checksum.json" + }, + { + "type": "archive", + "archive-type": "tar-gzip", + "url": "https://static.crates.io/crates/potential_utf/potential_utf-0.1.6.crate", + "sha256": "d83eb9bc6d8e5cf568e7a1101d60ee05e81ed50ea106026f3d18deeb046d7661", + "dest": "cargo/vendor/potential_utf-0.1.6" + }, + { + "type": "inline", + "contents": "{\"package\": \"d83eb9bc6d8e5cf568e7a1101d60ee05e81ed50ea106026f3d18deeb046d7661\", \"files\": {}}", + "dest": "cargo/vendor/potential_utf-0.1.6", + "dest-filename": ".cargo-checksum.json" + }, + { + "type": "archive", + "archive-type": "tar-gzip", + "url": "https://static.crates.io/crates/powerfmt/powerfmt-0.2.1.crate", + "sha256": "4a6394b9e965e73d0a289ee54f589087e2c676aedf60885baf52c76b771e4958", + "dest": "cargo/vendor/powerfmt-0.2.1" + }, + { + "type": "inline", + "contents": "{\"package\": \"4a6394b9e965e73d0a289ee54f589087e2c676aedf60885baf52c76b771e4958\", \"files\": {}}", + "dest": "cargo/vendor/powerfmt-0.2.1", + "dest-filename": ".cargo-checksum.json" + }, { "type": "archive", "archive-type": "tar-gzip", @@ -5312,14 +6438,14 @@ { "type": "archive", "archive-type": "tar-gzip", - "url": "https://static.crates.io/crates/proptest/proptest-1.11.0.crate", - "sha256": "4b45fcc2344c680f5025fe57779faef368840d0bd1f42f216291f0dc4ace4744", - "dest": "cargo/vendor/proptest-1.11.0" + "url": "https://static.crates.io/crates/proptest/proptest-1.12.0.crate", + "sha256": "b8530004ccb15eae51c7e40009fbe317f341f804db54dc033eec1c50be28cfa0", + "dest": "cargo/vendor/proptest-1.12.0" }, { "type": "inline", - "contents": "{\"package\": \"4b45fcc2344c680f5025fe57779faef368840d0bd1f42f216291f0dc4ace4744\", \"files\": {}}", - "dest": "cargo/vendor/proptest-1.11.0", + "contents": "{\"package\": \"b8530004ccb15eae51c7e40009fbe317f341f804db54dc033eec1c50be28cfa0\", \"files\": {}}", + "dest": "cargo/vendor/proptest-1.12.0", "dest-filename": ".cargo-checksum.json" }, { @@ -5387,6 +6513,19 @@ "dest": "cargo/vendor/pxfm-0.1.30", "dest-filename": ".cargo-checksum.json" }, + { + "type": "archive", + "archive-type": "tar-gzip", + "url": "https://static.crates.io/crates/qoi/qoi-0.4.1.crate", + "sha256": "7f6d64c71eb498fe9eae14ce4ec935c555749aef511cca85b5568910d6e48001", + "dest": "cargo/vendor/qoi-0.4.1" + }, + { + "type": "inline", + "contents": "{\"package\": \"7f6d64c71eb498fe9eae14ce4ec935c555749aef511cca85b5568910d6e48001\", \"files\": {}}", + "dest": "cargo/vendor/qoi-0.4.1", + "dest-filename": ".cargo-checksum.json" + }, { "type": "archive", "archive-type": "tar-gzip", @@ -5426,6 +6565,19 @@ "dest": "cargo/vendor/quick-xml-0.41.0", "dest-filename": ".cargo-checksum.json" }, + { + "type": "archive", + "archive-type": "tar-gzip", + "url": "https://static.crates.io/crates/quick-xml/quick-xml-0.42.0.crate", + "sha256": "41b1177fdf999d2321d3fb46ff47159d9c1fb9ad66a4879f8c50a0b504615e9b", + "dest": "cargo/vendor/quick-xml-0.42.0" + }, + { + "type": "inline", + "contents": "{\"package\": \"41b1177fdf999d2321d3fb46ff47159d9c1fb9ad66a4879f8c50a0b504615e9b\", \"files\": {}}", + "dest": "cargo/vendor/quick-xml-0.42.0", + "dest-filename": ".cargo-checksum.json" + }, { "type": "archive", "archive-type": "tar-gzip", @@ -5491,6 +6643,19 @@ "dest": "cargo/vendor/rand-0.9.5", "dest-filename": ".cargo-checksum.json" }, + { + "type": "archive", + "archive-type": "tar-gzip", + "url": "https://static.crates.io/crates/rand/rand-0.10.3.crate", + "sha256": "65c9fb96cbc91e3478eaae79a69fcd3f1ae4ad052e471fe6732fff548984b4af", + "dest": "cargo/vendor/rand-0.10.3" + }, + { + "type": "inline", + "contents": "{\"package\": \"65c9fb96cbc91e3478eaae79a69fcd3f1ae4ad052e471fe6732fff548984b4af\", \"files\": {}}", + "dest": "cargo/vendor/rand-0.10.3", + "dest-filename": ".cargo-checksum.json" + }, { "type": "archive", "archive-type": "tar-gzip", @@ -5543,6 +6708,19 @@ "dest": "cargo/vendor/rand_core-0.9.5", "dest-filename": ".cargo-checksum.json" }, + { + "type": "archive", + "archive-type": "tar-gzip", + "url": "https://static.crates.io/crates/rand_core/rand_core-0.10.1.crate", + "sha256": "63b8176103e19a2643978565ca18b50549f6101881c443590420e4dc998a3c69", + "dest": "cargo/vendor/rand_core-0.10.1" + }, + { + "type": "inline", + "contents": "{\"package\": \"63b8176103e19a2643978565ca18b50549f6101881c443590420e4dc998a3c69\", \"files\": {}}", + "dest": "cargo/vendor/rand_core-0.10.1", + "dest-filename": ".cargo-checksum.json" + }, { "type": "archive", "archive-type": "tar-gzip", @@ -5559,14 +6737,14 @@ { "type": "archive", "archive-type": "tar-gzip", - "url": "https://static.crates.io/crates/rand_xorshift/rand_xorshift-0.4.0.crate", - "sha256": "513962919efc330f829edb2535844d1b912b0fbe2ca165d613e4e8788bb05a5a", - "dest": "cargo/vendor/rand_xorshift-0.4.0" + "url": "https://static.crates.io/crates/rand_xorshift/rand_xorshift-0.5.0.crate", + "sha256": "60aa6af80be32871323012e02e6e65f8a7cc7890931ae421d217ad8fe0df2ccf", + "dest": "cargo/vendor/rand_xorshift-0.5.0" }, { "type": "inline", - "contents": "{\"package\": \"513962919efc330f829edb2535844d1b912b0fbe2ca165d613e4e8788bb05a5a\", \"files\": {}}", - "dest": "cargo/vendor/rand_xorshift-0.4.0", + "contents": "{\"package\": \"60aa6af80be32871323012e02e6e65f8a7cc7890931ae421d217ad8fe0df2ccf\", \"files\": {}}", + "dest": "cargo/vendor/rand_xorshift-0.5.0", "dest-filename": ".cargo-checksum.json" }, { @@ -5712,6 +6890,19 @@ "dest": "cargo/vendor/read-fonts-0.41.0", "dest-filename": ".cargo-checksum.json" }, + { + "type": "archive", + "archive-type": "tar-gzip", + "url": "https://static.crates.io/crates/read-fonts/read-fonts-0.43.3.crate", + "sha256": "005c8acf251756c478b0bf402885bfd88a1476020c4c7e6060edc1aa68da38ea", + "dest": "cargo/vendor/read-fonts-0.43.3" + }, + { + "type": "inline", + "contents": "{\"package\": \"005c8acf251756c478b0bf402885bfd88a1476020c4c7e6060edc1aa68da38ea\", \"files\": {}}", + "dest": "cargo/vendor/read-fonts-0.43.3", + "dest-filename": ".cargo-checksum.json" + }, { "type": "archive", "archive-type": "tar-gzip", @@ -5842,6 +7033,19 @@ "dest": "cargo/vendor/ring-0.17.14", "dest-filename": ".cargo-checksum.json" }, + { + "type": "archive", + "archive-type": "tar-gzip", + "url": "https://static.crates.io/crates/roxmltree/roxmltree-0.21.2.crate", + "sha256": "9da7f59328b09405b181fee1018925fad50f157afb43c0c0f5c522c256dd5907", + "dest": "cargo/vendor/roxmltree-0.21.2" + }, + { + "type": "inline", + "contents": "{\"package\": \"9da7f59328b09405b181fee1018925fad50f157afb43c0c0f5c522c256dd5907\", \"files\": {}}", + "dest": "cargo/vendor/roxmltree-0.21.2", + "dest-filename": ".cargo-checksum.json" + }, { "type": "archive", "archive-type": "tar-gzip", @@ -5936,14 +7140,27 @@ { "type": "archive", "archive-type": "tar-gzip", - "url": "https://static.crates.io/crates/rustls/rustls-0.23.45.crate", - "sha256": "0d41d731c7d2f962d1ccc364cec258de3c0e93b38c2fb3ba97ac74513048d634", - "dest": "cargo/vendor/rustls-0.23.45" + "url": "https://static.crates.io/crates/rustls/rustls-0.23.46.crate", + "sha256": "48e13bd8c0e9365c43cfa5c9e8f9ad49d3c8444926c9aac819e0e4dc503c8fdf", + "dest": "cargo/vendor/rustls-0.23.46" }, { "type": "inline", - "contents": "{\"package\": \"0d41d731c7d2f962d1ccc364cec258de3c0e93b38c2fb3ba97ac74513048d634\", \"files\": {}}", - "dest": "cargo/vendor/rustls-0.23.45", + "contents": "{\"package\": \"48e13bd8c0e9365c43cfa5c9e8f9ad49d3c8444926c9aac819e0e4dc503c8fdf\", \"files\": {}}", + "dest": "cargo/vendor/rustls-0.23.46", + "dest-filename": ".cargo-checksum.json" + }, + { + "type": "archive", + "archive-type": "tar-gzip", + "url": "https://static.crates.io/crates/rustls-native-certs/rustls-native-certs-0.8.5.crate", + "sha256": "4a073f5dc7469f984c52ad2752b63b0807745133b6de880b7b64c1ac4c48aec4", + "dest": "cargo/vendor/rustls-native-certs-0.8.5" + }, + { + "type": "inline", + "contents": "{\"package\": \"4a073f5dc7469f984c52ad2752b63b0807745133b6de880b7b64c1ac4c48aec4\", \"files\": {}}", + "dest": "cargo/vendor/rustls-native-certs-0.8.5", "dest-filename": ".cargo-checksum.json" }, { @@ -5959,6 +7176,32 @@ "dest": "cargo/vendor/rustls-pki-types-1.15.1", "dest-filename": ".cargo-checksum.json" }, + { + "type": "archive", + "archive-type": "tar-gzip", + "url": "https://static.crates.io/crates/rustls-platform-verifier/rustls-platform-verifier-0.7.1.crate", + "sha256": "1167586491e2b18b8bfbb293e8180ec17c201c4f076d7cb3070ca964e7598f98", + "dest": "cargo/vendor/rustls-platform-verifier-0.7.1" + }, + { + "type": "inline", + "contents": "{\"package\": \"1167586491e2b18b8bfbb293e8180ec17c201c4f076d7cb3070ca964e7598f98\", \"files\": {}}", + "dest": "cargo/vendor/rustls-platform-verifier-0.7.1", + "dest-filename": ".cargo-checksum.json" + }, + { + "type": "archive", + "archive-type": "tar-gzip", + "url": "https://static.crates.io/crates/rustls-platform-verifier-android/rustls-platform-verifier-android-0.2.0.crate", + "sha256": "eec689c0bc40ff2458a5977b6619cb718087084a18e02a131c599b62d05e1a5f", + "dest": "cargo/vendor/rustls-platform-verifier-android-0.2.0" + }, + { + "type": "inline", + "contents": "{\"package\": \"eec689c0bc40ff2458a5977b6619cb718087084a18e02a131c599b62d05e1a5f\", \"files\": {}}", + "dest": "cargo/vendor/rustls-platform-verifier-android-0.2.0", + "dest-filename": ".cargo-checksum.json" + }, { "type": "archive", "archive-type": "tar-gzip", @@ -5988,14 +7231,14 @@ { "type": "archive", "archive-type": "tar-gzip", - "url": "https://static.crates.io/crates/rustls-webpki/rustls-webpki-0.103.15.crate", - "sha256": "f3c3cf1d8b1e7d4927e2d154c3fcb02979afb9939629c62cd9048d4f07b60ac2", - "dest": "cargo/vendor/rustls-webpki-0.103.15" + "url": "https://static.crates.io/crates/rustls-webpki/rustls-webpki-0.103.16.crate", + "sha256": "4443b1b6d39d7c663139942cc4558262562d2c84123bb6282ef177009ca8b281", + "dest": "cargo/vendor/rustls-webpki-0.103.16" }, { "type": "inline", - "contents": "{\"package\": \"f3c3cf1d8b1e7d4927e2d154c3fcb02979afb9939629c62cd9048d4f07b60ac2\", \"files\": {}}", - "dest": "cargo/vendor/rustls-webpki-0.103.15", + "contents": "{\"package\": \"4443b1b6d39d7c663139942cc4558262562d2c84123bb6282ef177009ca8b281\", \"files\": {}}", + "dest": "cargo/vendor/rustls-webpki-0.103.16", "dest-filename": ".cargo-checksum.json" }, { @@ -6063,6 +7306,19 @@ "dest": "cargo/vendor/same-file-1.0.6", "dest-filename": ".cargo-checksum.json" }, + { + "type": "archive", + "archive-type": "tar-gzip", + "url": "https://static.crates.io/crates/schannel/schannel-0.1.30.crate", + "sha256": "9cb23c424d8ee841bb4d813677ca237e2a610067d594fec130f87d6093495ab5", + "dest": "cargo/vendor/schannel-0.1.30" + }, + { + "type": "inline", + "contents": "{\"package\": \"9cb23c424d8ee841bb4d813677ca237e2a610067d594fec130f87d6093495ab5\", \"files\": {}}", + "dest": "cargo/vendor/schannel-0.1.30", + "dest-filename": ".cargo-checksum.json" + }, { "type": "archive", "archive-type": "tar-gzip", @@ -6102,6 +7358,32 @@ "dest": "cargo/vendor/sec1-0.7.3", "dest-filename": ".cargo-checksum.json" }, + { + "type": "archive", + "archive-type": "tar-gzip", + "url": "https://static.crates.io/crates/security-framework/security-framework-3.7.0.crate", + "sha256": "b7f4bc775c73d9a02cde8bf7b2ec4c9d12743edf609006c7facc23998404cd1d", + "dest": "cargo/vendor/security-framework-3.7.0" + }, + { + "type": "inline", + "contents": "{\"package\": \"b7f4bc775c73d9a02cde8bf7b2ec4c9d12743edf609006c7facc23998404cd1d\", \"files\": {}}", + "dest": "cargo/vendor/security-framework-3.7.0", + "dest-filename": ".cargo-checksum.json" + }, + { + "type": "archive", + "archive-type": "tar-gzip", + "url": "https://static.crates.io/crates/security-framework-sys/security-framework-sys-2.17.0.crate", + "sha256": "6ce2691df843ecc5d231c0b14ece2acc3efb62c0a398c7e1d875f3983ce020e3", + "dest": "cargo/vendor/security-framework-sys-2.17.0" + }, + { + "type": "inline", + "contents": "{\"package\": \"6ce2691df843ecc5d231c0b14ece2acc3efb62c0a398c7e1d875f3983ce020e3\", \"files\": {}}", + "dest": "cargo/vendor/security-framework-sys-2.17.0", + "dest-filename": ".cargo-checksum.json" + }, { "type": "archive", "archive-type": "tar-gzip", @@ -6196,14 +7478,14 @@ { "type": "archive", "archive-type": "tar-gzip", - "url": "https://static.crates.io/crates/serde_json/serde_json-1.0.151.crate", - "sha256": "c841b55ecdae098c80dcae9cf767f6f8a0c2cdb3416bbef72181df4d0fe73f14", - "dest": "cargo/vendor/serde_json-1.0.151" + "url": "https://static.crates.io/crates/serde_json/serde_json-1.0.154.crate", + "sha256": "e7e9cc8b1b85264074fbcc02a88680c4096b1e47df8f739dceb03bf482f04bd6", + "dest": "cargo/vendor/serde_json-1.0.154" }, { "type": "inline", - "contents": "{\"package\": \"c841b55ecdae098c80dcae9cf767f6f8a0c2cdb3416bbef72181df4d0fe73f14\", \"files\": {}}", - "dest": "cargo/vendor/serde_json-1.0.151", + "contents": "{\"package\": \"e7e9cc8b1b85264074fbcc02a88680c4096b1e47df8f739dceb03bf482f04bd6\", \"files\": {}}", + "dest": "cargo/vendor/serde_json-1.0.154", "dest-filename": ".cargo-checksum.json" }, { @@ -6583,6 +7865,19 @@ "dest": "cargo/vendor/synstructure-0.14.0", "dest-filename": ".cargo-checksum.json" }, + { + "type": "archive", + "archive-type": "tar-gzip", + "url": "https://static.crates.io/crates/sys-locale/sys-locale-0.3.2.crate", + "sha256": "8eab9a99a024a169fe8a903cf9d4a3b3601109bcc13bd9e3c6fff259138626c4", + "dest": "cargo/vendor/sys-locale-0.3.2" + }, + { + "type": "inline", + "contents": "{\"package\": \"8eab9a99a024a169fe8a903cf9d4a3b3601109bcc13bd9e3c6fff259138626c4\", \"files\": {}}", + "dest": "cargo/vendor/sys-locale-0.3.2", + "dest-filename": ".cargo-checksum.json" + }, { "type": "archive", "archive-type": "tar-gzip", @@ -6609,6 +7904,32 @@ "dest": "cargo/vendor/sysctl-0.6.0", "dest-filename": ".cargo-checksum.json" }, + { + "type": "archive", + "archive-type": "tar-gzip", + "url": "https://static.crates.io/crates/tar/tar-0.4.46.crate", + "sha256": "3f6221d9a6003c78398e3b239969f352578258df48c8eb051caadae0015bc840", + "dest": "cargo/vendor/tar-0.4.46" + }, + { + "type": "inline", + "contents": "{\"package\": \"3f6221d9a6003c78398e3b239969f352578258df48c8eb051caadae0015bc840\", \"files\": {}}", + "dest": "cargo/vendor/tar-0.4.46", + "dest-filename": ".cargo-checksum.json" + }, + { + "type": "archive", + "archive-type": "tar-gzip", + "url": "https://static.crates.io/crates/target-features/target-features-0.1.6.crate", + "sha256": "c1bbb9f3c5c463a01705937a24fdabc5047929ac764b2d5b9cf681c1f5041ed5", + "dest": "cargo/vendor/target-features-0.1.6" + }, + { + "type": "inline", + "contents": "{\"package\": \"c1bbb9f3c5c463a01705937a24fdabc5047929ac764b2d5b9cf681c1f5041ed5\", \"files\": {}}", + "dest": "cargo/vendor/target-features-0.1.6", + "dest-filename": ".cargo-checksum.json" + }, { "type": "archive", "archive-type": "tar-gzip", @@ -6713,6 +8034,71 @@ "dest": "cargo/vendor/tiff-0.11.3", "dest-filename": ".cargo-checksum.json" }, + { + "type": "archive", + "archive-type": "tar-gzip", + "url": "https://static.crates.io/crates/time/time-0.3.55.crate", + "sha256": "cdb87b95ec50ddfa440816d227a17b2ccbdda963a316a727fda0fc4334f7d134", + "dest": "cargo/vendor/time-0.3.55" + }, + { + "type": "inline", + "contents": "{\"package\": \"cdb87b95ec50ddfa440816d227a17b2ccbdda963a316a727fda0fc4334f7d134\", \"files\": {}}", + "dest": "cargo/vendor/time-0.3.55", + "dest-filename": ".cargo-checksum.json" + }, + { + "type": "archive", + "archive-type": "tar-gzip", + "url": "https://static.crates.io/crates/time-core/time-core-0.1.9.crate", + "sha256": "9e1c906769ad99c88eaa54e728060edef082f8e358ff32030cb7c7d315e81109", + "dest": "cargo/vendor/time-core-0.1.9" + }, + { + "type": "inline", + "contents": "{\"package\": \"9e1c906769ad99c88eaa54e728060edef082f8e358ff32030cb7c7d315e81109\", \"files\": {}}", + "dest": "cargo/vendor/time-core-0.1.9", + "dest-filename": ".cargo-checksum.json" + }, + { + "type": "archive", + "archive-type": "tar-gzip", + "url": "https://static.crates.io/crates/time-macros/time-macros-0.2.32.crate", + "sha256": "7e689342a48d2ea927c87ea50cabf8594854bf940e9310208848d680d668ed85", + "dest": "cargo/vendor/time-macros-0.2.32" + }, + { + "type": "inline", + "contents": "{\"package\": \"7e689342a48d2ea927c87ea50cabf8594854bf940e9310208848d680d668ed85\", \"files\": {}}", + "dest": "cargo/vendor/time-macros-0.2.32", + "dest-filename": ".cargo-checksum.json" + }, + { + "type": "archive", + "archive-type": "tar-gzip", + "url": "https://static.crates.io/crates/tinystr/tinystr-0.8.4.crate", + "sha256": "b1e27c91459209c2986af3dcf603a5a74a4368754ce37414f59acc971167f643", + "dest": "cargo/vendor/tinystr-0.8.4" + }, + { + "type": "inline", + "contents": "{\"package\": \"b1e27c91459209c2986af3dcf603a5a74a4368754ce37414f59acc971167f643\", \"files\": {}}", + "dest": "cargo/vendor/tinystr-0.8.4", + "dest-filename": ".cargo-checksum.json" + }, + { + "type": "archive", + "archive-type": "tar-gzip", + "url": "https://static.crates.io/crates/tinyvec/tinyvec-1.13.3.crate", + "sha256": "fd3ca314f692efd6c868f8408f53fe444634a845f96c028b97d35f6a1f79f0ee", + "dest": "cargo/vendor/tinyvec-1.13.3" + }, + { + "type": "inline", + "contents": "{\"package\": \"fd3ca314f692efd6c868f8408f53fe444634a845f96c028b97d35f6a1f79f0ee\", \"files\": {}}", + "dest": "cargo/vendor/tinyvec-1.13.3", + "dest-filename": ".cargo-checksum.json" + }, { "type": "archive", "archive-type": "tar-gzip", @@ -6882,6 +8268,19 @@ "dest": "cargo/vendor/typed-path-0.12.3", "dest-filename": ".cargo-checksum.json" }, + { + "type": "archive", + "archive-type": "tar-gzip", + "url": "https://static.crates.io/crates/typed-path/typed-path-0.13.0.crate", + "sha256": "9ce898823d8cd0f028662d2f349694b1af0a5cc9be83f1d213a00d3147445e1e", + "dest": "cargo/vendor/typed-path-0.13.0" + }, + { + "type": "inline", + "contents": "{\"package\": \"9ce898823d8cd0f028662d2f349694b1af0a5cc9be83f1d213a00d3147445e1e\", \"files\": {}}", + "dest": "cargo/vendor/typed-path-0.13.0", + "dest-filename": ".cargo-checksum.json" + }, { "type": "archive", "archive-type": "tar-gzip", @@ -6986,6 +8385,19 @@ "dest": "cargo/vendor/unicode-ident-1.0.26", "dest-filename": ".cargo-checksum.json" }, + { + "type": "archive", + "archive-type": "tar-gzip", + "url": "https://static.crates.io/crates/unicode-normalization/unicode-normalization-0.1.26.crate", + "sha256": "75cd3fb03d5288b3ba9a1ee103ac7e9cbb59f0b03d64f8ddfcc04dd42758a85d", + "dest": "cargo/vendor/unicode-normalization-0.1.26" + }, + { + "type": "inline", + "contents": "{\"package\": \"75cd3fb03d5288b3ba9a1ee103ac7e9cbb59f0b03d64f8ddfcc04dd42758a85d\", \"files\": {}}", + "dest": "cargo/vendor/unicode-normalization-0.1.26", + "dest-filename": ".cargo-checksum.json" + }, { "type": "archive", "archive-type": "tar-gzip", @@ -7051,6 +8463,71 @@ "dest": "cargo/vendor/untrusted-0.9.0", "dest-filename": ".cargo-checksum.json" }, + { + "type": "archive", + "archive-type": "tar-gzip", + "url": "https://static.crates.io/crates/ureq/ureq-3.4.2.crate", + "sha256": "9a7ac20be9b7726e0bbdbf974c059676d9acb1cd414961f570a4e8231cacd7fc", + "dest": "cargo/vendor/ureq-3.4.2" + }, + { + "type": "inline", + "contents": "{\"package\": \"9a7ac20be9b7726e0bbdbf974c059676d9acb1cd414961f570a4e8231cacd7fc\", \"files\": {}}", + "dest": "cargo/vendor/ureq-3.4.2", + "dest-filename": ".cargo-checksum.json" + }, + { + "type": "archive", + "archive-type": "tar-gzip", + "url": "https://static.crates.io/crates/ureq-proto/ureq-proto-0.6.5.crate", + "sha256": "841583fc36089d7d59419568ae157f43a5a03a2e5a81ba87c77d1596ef46e922", + "dest": "cargo/vendor/ureq-proto-0.6.5" + }, + { + "type": "inline", + "contents": "{\"package\": \"841583fc36089d7d59419568ae157f43a5a03a2e5a81ba87c77d1596ef46e922\", \"files\": {}}", + "dest": "cargo/vendor/ureq-proto-0.6.5", + "dest-filename": ".cargo-checksum.json" + }, + { + "type": "archive", + "archive-type": "tar-gzip", + "url": "https://static.crates.io/crates/utf16_iter/utf16_iter-1.0.5.crate", + "sha256": "c8232dd3cdaed5356e0f716d285e4b40b932ac434100fe9b7e0e8e935b9e6246", + "dest": "cargo/vendor/utf16_iter-1.0.5" + }, + { + "type": "inline", + "contents": "{\"package\": \"c8232dd3cdaed5356e0f716d285e4b40b932ac434100fe9b7e0e8e935b9e6246\", \"files\": {}}", + "dest": "cargo/vendor/utf16_iter-1.0.5", + "dest-filename": ".cargo-checksum.json" + }, + { + "type": "archive", + "archive-type": "tar-gzip", + "url": "https://static.crates.io/crates/utf8-zero/utf8-zero-0.8.1.crate", + "sha256": "b8c0a043c9540bae7c578c88f91dda8bd82e59ae27c21baca69c8b191aaf5a6e", + "dest": "cargo/vendor/utf8-zero-0.8.1" + }, + { + "type": "inline", + "contents": "{\"package\": \"b8c0a043c9540bae7c578c88f91dda8bd82e59ae27c21baca69c8b191aaf5a6e\", \"files\": {}}", + "dest": "cargo/vendor/utf8-zero-0.8.1", + "dest-filename": ".cargo-checksum.json" + }, + { + "type": "archive", + "archive-type": "tar-gzip", + "url": "https://static.crates.io/crates/utf8_iter/utf8_iter-1.0.4.crate", + "sha256": "b6c140620e7ffbb22c2dee59cafe6084a59b5ffc27a8859a5f0d494b5d52b6be", + "dest": "cargo/vendor/utf8_iter-1.0.4" + }, + { + "type": "inline", + "contents": "{\"package\": \"b6c140620e7ffbb22c2dee59cafe6084a59b5ffc27a8859a5f0d494b5d52b6be\", \"files\": {}}", + "dest": "cargo/vendor/utf8_iter-1.0.4", + "dest-filename": ".cargo-checksum.json" + }, { "type": "archive", "archive-type": "tar-gzip", @@ -7103,6 +8580,19 @@ "dest": "cargo/vendor/vello_cpu-0.2.0", "dest-filename": ".cargo-checksum.json" }, + { + "type": "archive", + "archive-type": "tar-gzip", + "url": "https://static.crates.io/crates/verifysign/verifysign-1.0.1.crate", + "sha256": "6acfcc42a8d44f340d001193d97ef56bf33210b51ad760ae8308c97d5241ca51", + "dest": "cargo/vendor/verifysign-1.0.1" + }, + { + "type": "inline", + "contents": "{\"package\": \"6acfcc42a8d44f340d001193d97ef56bf33210b51ad760ae8308c97d5241ca51\", \"files\": {}}", + "dest": "cargo/vendor/verifysign-1.0.1", + "dest-filename": ".cargo-checksum.json" + }, { "type": "archive", "archive-type": "tar-gzip", @@ -7405,14 +8895,27 @@ { "type": "archive", "archive-type": "tar-gzip", - "url": "https://static.crates.io/crates/webpki-roots/webpki-roots-1.0.9.crate", - "sha256": "7dcd9d09a39985f5344844e66b0c530a33843579125f23e21e9f0f220850f22a", - "dest": "cargo/vendor/webpki-roots-1.0.9" + "url": "https://static.crates.io/crates/webpki-root-certs/webpki-root-certs-1.0.11.crate", + "sha256": "e49d0e65abc00c142e8f9428da991da9f1a250c39be97459901eb12b9b49f62a", + "dest": "cargo/vendor/webpki-root-certs-1.0.11" }, { "type": "inline", - "contents": "{\"package\": \"7dcd9d09a39985f5344844e66b0c530a33843579125f23e21e9f0f220850f22a\", \"files\": {}}", - "dest": "cargo/vendor/webpki-roots-1.0.9", + "contents": "{\"package\": \"e49d0e65abc00c142e8f9428da991da9f1a250c39be97459901eb12b9b49f62a\", \"files\": {}}", + "dest": "cargo/vendor/webpki-root-certs-1.0.11", + "dest-filename": ".cargo-checksum.json" + }, + { + "type": "archive", + "archive-type": "tar-gzip", + "url": "https://static.crates.io/crates/webpki-roots/webpki-roots-1.0.10.crate", + "sha256": "1c1c8e20c8a38fc7d65abfe74eb7280e4aa667e8eec8bc84996d2874810748d9", + "dest": "cargo/vendor/webpki-roots-1.0.10" + }, + { + "type": "inline", + "contents": "{\"package\": \"1c1c8e20c8a38fc7d65abfe74eb7280e4aa667e8eec8bc84996d2874810748d9\", \"files\": {}}", + "dest": "cargo/vendor/webpki-roots-1.0.10", "dest-filename": ".cargo-checksum.json" }, { @@ -7662,6 +9165,19 @@ "dest": "cargo/vendor/windows-numerics-0.3.1", "dest-filename": ".cargo-checksum.json" }, + { + "type": "archive", + "archive-type": "tar-gzip", + "url": "https://static.crates.io/crates/windows-registry/windows-registry-0.6.1.crate", + "sha256": "02752bf7fbdcce7f2a27a742f798510f3e5ad88dbe84871e5168e2120c3d5720", + "dest": "cargo/vendor/windows-registry-0.6.1" + }, + { + "type": "inline", + "contents": "{\"package\": \"02752bf7fbdcce7f2a27a742f798510f3e5ad88dbe84871e5168e2120c3d5720\", \"files\": {}}", + "dest": "cargo/vendor/windows-registry-0.6.1", + "dest-filename": ".cargo-checksum.json" + }, { "type": "archive", "archive-type": "tar-gzip", @@ -7714,19 +9230,6 @@ "dest": "cargo/vendor/windows-sys-0.59.0", "dest-filename": ".cargo-checksum.json" }, - { - "type": "archive", - "archive-type": "tar-gzip", - "url": "https://static.crates.io/crates/windows-sys/windows-sys-0.60.2.crate", - "sha256": "f2f500e4d28234f72040990ec9d39e3a6b950f9f22d3dba18416c35882612bcb", - "dest": "cargo/vendor/windows-sys-0.60.2" - }, - { - "type": "inline", - "contents": "{\"package\": \"f2f500e4d28234f72040990ec9d39e3a6b950f9f22d3dba18416c35882612bcb\", \"files\": {}}", - "dest": "cargo/vendor/windows-sys-0.60.2", - "dest-filename": ".cargo-checksum.json" - }, { "type": "archive", "archive-type": "tar-gzip", @@ -7753,19 +9256,6 @@ "dest": "cargo/vendor/windows-targets-0.52.6", "dest-filename": ".cargo-checksum.json" }, - { - "type": "archive", - "archive-type": "tar-gzip", - "url": "https://static.crates.io/crates/windows-targets/windows-targets-0.53.5.crate", - "sha256": "4945f9f551b88e0d65f3db0bc25c33b8acea4d9e41163edf90dcd0b19f9069f3", - "dest": "cargo/vendor/windows-targets-0.53.5" - }, - { - "type": "inline", - "contents": "{\"package\": \"4945f9f551b88e0d65f3db0bc25c33b8acea4d9e41163edf90dcd0b19f9069f3\", \"files\": {}}", - "dest": "cargo/vendor/windows-targets-0.53.5", - "dest-filename": ".cargo-checksum.json" - }, { "type": "archive", "archive-type": "tar-gzip", @@ -7792,19 +9282,6 @@ "dest": "cargo/vendor/windows_aarch64_gnullvm-0.52.6", "dest-filename": ".cargo-checksum.json" }, - { - "type": "archive", - "archive-type": "tar-gzip", - "url": "https://static.crates.io/crates/windows_aarch64_gnullvm/windows_aarch64_gnullvm-0.53.1.crate", - "sha256": "a9d8416fa8b42f5c947f8482c43e7d89e73a173cead56d044f6a56104a6d1b53", - "dest": "cargo/vendor/windows_aarch64_gnullvm-0.53.1" - }, - { - "type": "inline", - "contents": "{\"package\": \"a9d8416fa8b42f5c947f8482c43e7d89e73a173cead56d044f6a56104a6d1b53\", \"files\": {}}", - "dest": "cargo/vendor/windows_aarch64_gnullvm-0.53.1", - "dest-filename": ".cargo-checksum.json" - }, { "type": "archive", "archive-type": "tar-gzip", @@ -7818,19 +9295,6 @@ "dest": "cargo/vendor/windows_aarch64_msvc-0.52.6", "dest-filename": ".cargo-checksum.json" }, - { - "type": "archive", - "archive-type": "tar-gzip", - "url": "https://static.crates.io/crates/windows_aarch64_msvc/windows_aarch64_msvc-0.53.1.crate", - "sha256": "b9d782e804c2f632e395708e99a94275910eb9100b2114651e04744e9b125006", - "dest": "cargo/vendor/windows_aarch64_msvc-0.53.1" - }, - { - "type": "inline", - "contents": "{\"package\": \"b9d782e804c2f632e395708e99a94275910eb9100b2114651e04744e9b125006\", \"files\": {}}", - "dest": "cargo/vendor/windows_aarch64_msvc-0.53.1", - "dest-filename": ".cargo-checksum.json" - }, { "type": "archive", "archive-type": "tar-gzip", @@ -7844,19 +9308,6 @@ "dest": "cargo/vendor/windows_i686_gnu-0.52.6", "dest-filename": ".cargo-checksum.json" }, - { - "type": "archive", - "archive-type": "tar-gzip", - "url": "https://static.crates.io/crates/windows_i686_gnu/windows_i686_gnu-0.53.1.crate", - "sha256": "960e6da069d81e09becb0ca57a65220ddff016ff2d6af6a223cf372a506593a3", - "dest": "cargo/vendor/windows_i686_gnu-0.53.1" - }, - { - "type": "inline", - "contents": "{\"package\": \"960e6da069d81e09becb0ca57a65220ddff016ff2d6af6a223cf372a506593a3\", \"files\": {}}", - "dest": "cargo/vendor/windows_i686_gnu-0.53.1", - "dest-filename": ".cargo-checksum.json" - }, { "type": "archive", "archive-type": "tar-gzip", @@ -7870,19 +9321,6 @@ "dest": "cargo/vendor/windows_i686_gnullvm-0.52.6", "dest-filename": ".cargo-checksum.json" }, - { - "type": "archive", - "archive-type": "tar-gzip", - "url": "https://static.crates.io/crates/windows_i686_gnullvm/windows_i686_gnullvm-0.53.1.crate", - "sha256": "fa7359d10048f68ab8b09fa71c3daccfb0e9b559aed648a8f95469c27057180c", - "dest": "cargo/vendor/windows_i686_gnullvm-0.53.1" - }, - { - "type": "inline", - "contents": "{\"package\": \"fa7359d10048f68ab8b09fa71c3daccfb0e9b559aed648a8f95469c27057180c\", \"files\": {}}", - "dest": "cargo/vendor/windows_i686_gnullvm-0.53.1", - "dest-filename": ".cargo-checksum.json" - }, { "type": "archive", "archive-type": "tar-gzip", @@ -7896,19 +9334,6 @@ "dest": "cargo/vendor/windows_i686_msvc-0.52.6", "dest-filename": ".cargo-checksum.json" }, - { - "type": "archive", - "archive-type": "tar-gzip", - "url": "https://static.crates.io/crates/windows_i686_msvc/windows_i686_msvc-0.53.1.crate", - "sha256": "1e7ac75179f18232fe9c285163565a57ef8d3c89254a30685b57d83a38d326c2", - "dest": "cargo/vendor/windows_i686_msvc-0.53.1" - }, - { - "type": "inline", - "contents": "{\"package\": \"1e7ac75179f18232fe9c285163565a57ef8d3c89254a30685b57d83a38d326c2\", \"files\": {}}", - "dest": "cargo/vendor/windows_i686_msvc-0.53.1", - "dest-filename": ".cargo-checksum.json" - }, { "type": "archive", "archive-type": "tar-gzip", @@ -7922,19 +9347,6 @@ "dest": "cargo/vendor/windows_x86_64_gnu-0.52.6", "dest-filename": ".cargo-checksum.json" }, - { - "type": "archive", - "archive-type": "tar-gzip", - "url": "https://static.crates.io/crates/windows_x86_64_gnu/windows_x86_64_gnu-0.53.1.crate", - "sha256": "9c3842cdd74a865a8066ab39c8a7a473c0778a3f29370b5fd6b4b9aa7df4a499", - "dest": "cargo/vendor/windows_x86_64_gnu-0.53.1" - }, - { - "type": "inline", - "contents": "{\"package\": \"9c3842cdd74a865a8066ab39c8a7a473c0778a3f29370b5fd6b4b9aa7df4a499\", \"files\": {}}", - "dest": "cargo/vendor/windows_x86_64_gnu-0.53.1", - "dest-filename": ".cargo-checksum.json" - }, { "type": "archive", "archive-type": "tar-gzip", @@ -7948,19 +9360,6 @@ "dest": "cargo/vendor/windows_x86_64_gnullvm-0.52.6", "dest-filename": ".cargo-checksum.json" }, - { - "type": "archive", - "archive-type": "tar-gzip", - "url": "https://static.crates.io/crates/windows_x86_64_gnullvm/windows_x86_64_gnullvm-0.53.1.crate", - "sha256": "0ffa179e2d07eee8ad8f57493436566c7cc30ac536a3379fdf008f47f6bb7ae1", - "dest": "cargo/vendor/windows_x86_64_gnullvm-0.53.1" - }, - { - "type": "inline", - "contents": "{\"package\": \"0ffa179e2d07eee8ad8f57493436566c7cc30ac536a3379fdf008f47f6bb7ae1\", \"files\": {}}", - "dest": "cargo/vendor/windows_x86_64_gnullvm-0.53.1", - "dest-filename": ".cargo-checksum.json" - }, { "type": "archive", "archive-type": "tar-gzip", @@ -7974,19 +9373,6 @@ "dest": "cargo/vendor/windows_x86_64_msvc-0.52.6", "dest-filename": ".cargo-checksum.json" }, - { - "type": "archive", - "archive-type": "tar-gzip", - "url": "https://static.crates.io/crates/windows_x86_64_msvc/windows_x86_64_msvc-0.53.1.crate", - "sha256": "d6bbff5f0aada427a1e5a6da5f1f98158182f26556f345ac9e04d36d0ebed650", - "dest": "cargo/vendor/windows_x86_64_msvc-0.53.1" - }, - { - "type": "inline", - "contents": "{\"package\": \"d6bbff5f0aada427a1e5a6da5f1f98158182f26556f345ac9e04d36d0ebed650\", \"files\": {}}", - "dest": "cargo/vendor/windows_x86_64_msvc-0.53.1", - "dest-filename": ".cargo-checksum.json" - }, { "type": "shell", "commands": [ @@ -8021,14 +9407,40 @@ { "type": "archive", "archive-type": "tar-gzip", - "url": "https://static.crates.io/crates/winresource/winresource-0.1.31.crate", - "sha256": "0986a8b1d586b7d3e4fe3d9ea39fb451ae22869dcea4aa109d287a374d866087", - "dest": "cargo/vendor/winresource-0.1.31" + "url": "https://static.crates.io/crates/winreg/winreg-0.55.0.crate", + "sha256": "cb5a765337c50e9ec252c2069be9bf91c7df47afb103b642ba3a53bf8101be97", + "dest": "cargo/vendor/winreg-0.55.0" }, { "type": "inline", - "contents": "{\"package\": \"0986a8b1d586b7d3e4fe3d9ea39fb451ae22869dcea4aa109d287a374d866087\", \"files\": {}}", - "dest": "cargo/vendor/winresource-0.1.31", + "contents": "{\"package\": \"cb5a765337c50e9ec252c2069be9bf91c7df47afb103b642ba3a53bf8101be97\", \"files\": {}}", + "dest": "cargo/vendor/winreg-0.55.0", + "dest-filename": ".cargo-checksum.json" + }, + { + "type": "archive", + "archive-type": "tar-gzip", + "url": "https://static.crates.io/crates/winresource/winresource-0.1.34.crate", + "sha256": "a2bc6d36480b829272a5bdabf08e6dca8004761c1da7e35efef800540c66221b", + "dest": "cargo/vendor/winresource-0.1.34" + }, + { + "type": "inline", + "contents": "{\"package\": \"a2bc6d36480b829272a5bdabf08e6dca8004761c1da7e35efef800540c66221b\", \"files\": {}}", + "dest": "cargo/vendor/winresource-0.1.34", + "dest-filename": ".cargo-checksum.json" + }, + { + "type": "archive", + "archive-type": "tar-gzip", + "url": "https://static.crates.io/crates/winsafe/winsafe-0.0.29.crate", + "sha256": "9ef0ffc427f045c0cc9ebffd6f4f91153dcd2a1547b5c3c29ee3f541e16e95c6", + "dest": "cargo/vendor/winsafe-0.0.29" + }, + { + "type": "inline", + "contents": "{\"package\": \"9ef0ffc427f045c0cc9ebffd6f4f91153dcd2a1547b5c3c29ee3f541e16e95c6\", \"files\": {}}", + "dest": "cargo/vendor/winsafe-0.0.29", "dest-filename": ".cargo-checksum.json" }, { @@ -8057,6 +9469,32 @@ "dest": "cargo/vendor/wl-clipboard-rs-0.9.4", "dest-filename": ".cargo-checksum.json" }, + { + "type": "archive", + "archive-type": "tar-gzip", + "url": "https://static.crates.io/crates/write16/write16-1.0.0.crate", + "sha256": "d1890f4022759daae28ed4fe62859b1236caebfc61ede2f63ed4e695f3f6d936", + "dest": "cargo/vendor/write16-1.0.0" + }, + { + "type": "inline", + "contents": "{\"package\": \"d1890f4022759daae28ed4fe62859b1236caebfc61ede2f63ed4e695f3f6d936\", \"files\": {}}", + "dest": "cargo/vendor/write16-1.0.0", + "dest-filename": ".cargo-checksum.json" + }, + { + "type": "archive", + "archive-type": "tar-gzip", + "url": "https://static.crates.io/crates/writeable/writeable-0.6.4.crate", + "sha256": "3ad82d2a33cdc9674dc7465672f271e096168fcdbe0f799d9e6db8c5892679dc", + "dest": "cargo/vendor/writeable-0.6.4" + }, + { + "type": "inline", + "contents": "{\"package\": \"3ad82d2a33cdc9674dc7465672f271e096168fcdbe0f799d9e6db8c5892679dc\", \"files\": {}}", + "dest": "cargo/vendor/writeable-0.6.4", + "dest-filename": ".cargo-checksum.json" + }, { "type": "archive", "archive-type": "tar-gzip", @@ -8398,14 +9836,66 @@ { "type": "archive", "archive-type": "tar-gzip", - "url": "https://static.crates.io/crates/zip/zip-7.2.0.crate", - "sha256": "c42e33efc22a0650c311c2ef19115ce232583abbe80850bc8b66509ebef02de0", - "dest": "cargo/vendor/zip-7.2.0" + "url": "https://static.crates.io/crates/zerotrie/zerotrie-0.2.5.crate", + "sha256": "4ea269c3bd32f0a32c321907a2ae912ba6f4649bb0fc764a15627e99a7095a3f", + "dest": "cargo/vendor/zerotrie-0.2.5" }, { "type": "inline", - "contents": "{\"package\": \"c42e33efc22a0650c311c2ef19115ce232583abbe80850bc8b66509ebef02de0\", \"files\": {}}", - "dest": "cargo/vendor/zip-7.2.0", + "contents": "{\"package\": \"4ea269c3bd32f0a32c321907a2ae912ba6f4649bb0fc764a15627e99a7095a3f\", \"files\": {}}", + "dest": "cargo/vendor/zerotrie-0.2.5", + "dest-filename": ".cargo-checksum.json" + }, + { + "type": "archive", + "archive-type": "tar-gzip", + "url": "https://static.crates.io/crates/zerovec/zerovec-0.11.8.crate", + "sha256": "bb0464e17806c1d976d5cba29399c7f08e516e279e2ba493f63123b5fca67dd8", + "dest": "cargo/vendor/zerovec-0.11.8" + }, + { + "type": "inline", + "contents": "{\"package\": \"bb0464e17806c1d976d5cba29399c7f08e516e279e2ba493f63123b5fca67dd8\", \"files\": {}}", + "dest": "cargo/vendor/zerovec-0.11.8", + "dest-filename": ".cargo-checksum.json" + }, + { + "type": "archive", + "archive-type": "tar-gzip", + "url": "https://static.crates.io/crates/zerovec-derive/zerovec-derive-0.11.7.crate", + "sha256": "c3743ddbf47738d929cd1ae2e199d40d0162979dfe31aef8ae646d2bf00bf97a", + "dest": "cargo/vendor/zerovec-derive-0.11.7" + }, + { + "type": "inline", + "contents": "{\"package\": \"c3743ddbf47738d929cd1ae2e199d40d0162979dfe31aef8ae646d2bf00bf97a\", \"files\": {}}", + "dest": "cargo/vendor/zerovec-derive-0.11.7", + "dest-filename": ".cargo-checksum.json" + }, + { + "type": "archive", + "archive-type": "tar-gzip", + "url": "https://static.crates.io/crates/zip/zip-7.4.0.crate", + "sha256": "cc12baa6db2b15a140161ce53d72209dacea594230798c24774139b54ecaa980", + "dest": "cargo/vendor/zip-7.4.0" + }, + { + "type": "inline", + "contents": "{\"package\": \"cc12baa6db2b15a140161ce53d72209dacea594230798c24774139b54ecaa980\", \"files\": {}}", + "dest": "cargo/vendor/zip-7.4.0", + "dest-filename": ".cargo-checksum.json" + }, + { + "type": "archive", + "archive-type": "tar-gzip", + "url": "https://static.crates.io/crates/zip/zip-9.1.3.crate", + "sha256": "1156b39d142a34b999c2310a50455e0cb3760bf7efad0122f796d813bee26ccb", + "dest": "cargo/vendor/zip-9.1.3" + }, + { + "type": "inline", + "contents": "{\"package\": \"1156b39d142a34b999c2310a50455e0cb3760bf7efad0122f796d813bee26ccb\", \"files\": {}}", + "dest": "cargo/vendor/zip-9.1.3", "dest-filename": ".cargo-checksum.json" }, { @@ -8447,6 +9937,19 @@ "dest": "cargo/vendor/zune-core-0.5.3", "dest-filename": ".cargo-checksum.json" }, + { + "type": "archive", + "archive-type": "tar-gzip", + "url": "https://static.crates.io/crates/zune-inflate/zune-inflate-0.2.54.crate", + "sha256": "73ab332fe2f6680068f3582b16a24f90ad7096d5d39b974d1c0aff0125116f02", + "dest": "cargo/vendor/zune-inflate-0.2.54" + }, + { + "type": "inline", + "contents": "{\"package\": \"73ab332fe2f6680068f3582b16a24f90ad7096d5d39b974d1c0aff0125116f02\", \"files\": {}}", + "dest": "cargo/vendor/zune-inflate-0.2.54", + "dest-filename": ".cargo-checksum.json" + }, { "type": "archive", "archive-type": "tar-gzip", @@ -8530,24 +10033,6 @@ "dest": "cargo/vendor/egui_demo_lib", "dest-filename": ".cargo-checksum.json" }, - { - "type": "shell", - "commands": [ - "cp -r --reflink=auto \"flatpak-cargo/git/egui-6d518fc/crates/egui_extras\" \"cargo/vendor/egui_extras\"" - ] - }, - { - "type": "inline", - "contents": "[package]\nname = \"egui_extras\"\nversion = \"0.37.0\"\nauthors = [\"Dominik R\u00f6ssler <dominik@freshx.de>\", \"Emil Ernerfeldt <emil.ernerfeldt@gmail.com>\", \"Ren\u00e9 R\u00f6ssler <rene@freshx.de>\"]\ndescription = \"Extra functionality and widgets for the egui GUI library\"\nedition = \"2024\"\nrust-version = \"1.95\"\nhomepage = \"https://github.com/emilk/egui\"\nlicense = \"MIT OR Apache-2.0\"\nreadme = \"README.md\"\nrepository = \"https://github.com/emilk/egui\"\ncategories = [\"gui\", \"game-development\"]\nkeywords = [\"gui\", \"imgui\", \"immediate\", \"portable\", \"gamedev\"]\ninclude = [\"../../LICENSE-APACHE\", \"../../LICENSE-MIT\", \"**/*.rs\", \"Cargo.toml\"]\n\n[package.metadata.docs.rs]\nall-features = true\nrustdoc-args = [\"--generate-link-to-definition\"]\n\n[lints.rust]\nunsafe_code = \"deny\"\ntrivial_numeric_casts = \"warn\"\nunused_import_braces = \"warn\"\nunused_lifetimes = \"warn\"\ntrivial_casts = \"allow\"\nunused_qualifications = \"allow\"\n\n[lints.rust.future_incompatible]\nlevel = \"warn\"\npriority = -1\n\n[lints.rust.nonstandard_style]\nlevel = \"warn\"\npriority = -1\n\n[lints.rust.rust_2018_idioms]\nlevel = \"warn\"\npriority = -1\n\n[lints.rust.unexpected_cfgs]\nlevel = \"warn\"\ncheck-cfg = [\"cfg(web_sys_unstable_apis)\"]\n\n[lints.rustdoc]\nall = \"warn\"\n\n[lints.clippy]\nallow_attributes = \"warn\"\nas_ptr_cast_mut = \"warn\"\nbranches_sharing_code = \"warn\"\nclear_with_drain = \"warn\"\nclone_on_ref_ptr = \"warn\"\ncoerce_container_to_any = \"warn\"\ndbg_macro = \"warn\"\ndebug_assert_with_mut_call = \"warn\"\ndefault_union_representation = \"warn\"\nderive_partial_eq_without_eq = \"warn\"\ndisallowed_script_idents = \"warn\"\ndoc_include_without_cfg = \"warn\"\nempty_enum_variants_with_brackets = \"warn\"\nequatable_if_let = \"warn\"\nexit = \"warn\"\nfallible_impl_from = \"warn\"\nfloat_cmp_const = \"warn\"\nfn_to_numeric_cast_any = \"warn\"\nget_unwrap = \"warn\"\nimprecise_flops = \"warn\"\ninfinite_loop = \"warn\"\niter_on_empty_collections = \"warn\"\niter_on_single_items = \"warn\"\niter_over_hash_type = \"warn\"\nlarge_include_file = \"warn\"\nlarge_stack_frames = \"warn\"\nliteral_string_with_formatting_args = \"warn\"\nlossy_float_literal = \"warn\"\nmap_err_ignore = \"warn\"\nmem_forget = \"warn\"\nmissing_assert_message = \"warn\"\nmutex_integer = \"warn\"\nneedless_pass_by_ref_mut = \"warn\"\nneedless_type_cast = \"warn\"\nnon_zero_suggestions = \"warn\"\nnonstandard_macro_braces = \"warn\"\nor_fun_call = \"warn\"\npath_buf_push_overwrite = \"warn\"\npathbuf_init_then_push = \"warn\"\nprecedence_bits = \"warn\"\nprint_stderr = \"warn\"\nprint_stdout = \"warn\"\npub_without_shorthand = \"warn\"\nrc_mutex = \"warn\"\nredundant_type_annotations = \"warn\"\nref_patterns = \"warn\"\nrest_pat_in_fully_bound_structs = \"warn\"\nreturn_and_then = \"warn\"\nset_contains_or_insert = \"warn\"\nsingle_option_map = \"warn\"\nstd_instead_of_core = \"warn\"\nstr_to_string = \"warn\"\nstring_add = \"warn\"\nstring_lit_as_bytes = \"warn\"\nstring_lit_chars_any = \"warn\"\nsuspicious_xor_used_as_pow = \"warn\"\ntodo = \"warn\"\ntoo_long_first_doc_paragraph = \"warn\"\ntrailing_empty_array = \"warn\"\ntrait_duplication_in_bounds = \"warn\"\ntuple_array_conversions = \"warn\"\nundocumented_unsafe_blocks = \"warn\"\nunimplemented = \"warn\"\nuninhabited_references = \"warn\"\nunnecessary_safety_comment = \"warn\"\nunnecessary_safety_doc = \"warn\"\nunnecessary_self_imports = \"warn\"\nunnecessary_struct_initialization = \"warn\"\nunused_peekable = \"warn\"\nunused_rounding = \"warn\"\nunused_trait_names = \"warn\"\nunwrap_used = \"warn\"\nuse_self = \"warn\"\nuseless_let_if_seq = \"warn\"\nverbose_file_reads = \"warn\"\ncast_lossless = \"allow\"\ncast_possible_truncation = \"allow\"\ncast_possible_wrap = \"allow\"\ncast_precision_loss = \"allow\"\ncast_sign_loss = \"allow\"\ncomparison_chain = \"allow\"\ndefault_trait_access = \"allow\"\nfloat_cmp = \"allow\"\ninline_always = \"allow\"\nitems_after_statements = \"allow\"\nmany_single_char_names = \"allow\"\nmissing_panics_doc = \"allow\"\nmust_use_candidate = \"allow\"\nredundant_closure_for_method_calls = \"allow\"\nreturn_self_not_must_use = \"allow\"\nshould_panic_without_expect = \"allow\"\nsimilar_names = \"allow\"\nstruct_excessive_bools = \"allow\"\nstruct_field_names = \"allow\"\ntoo_many_lines = \"allow\"\ntrivially_copy_pass_by_ref = \"allow\"\nunreadable_literal = \"allow\"\nused_underscore_binding = \"allow\"\nassigning_clones = \"allow\"\nmanual_range_contains = \"allow\"\nmap_unwrap_or = \"allow\"\nmultiple_crate_versions = \"allow\"\nwildcard_imports = \"allow\"\nlet_underscore_must_use = \"allow\"\nlet_underscore_untyped = \"allow\"\nself_named_module_files = \"allow\"\nsignificant_drop_tightening = \"allow\"\n\n[lints.clippy.all]\nlevel = \"warn\"\npriority = -1\n\n[lints.clippy.cargo]\nlevel = \"warn\"\npriority = -1\n\n[lints.clippy.pedantic]\nlevel = \"warn\"\npriority = -1\n\n[lib]\n\n[features]\ndefault = [\"dep:mime_guess2\"]\nall_loaders = [\"file\", \"http\", \"image\", \"svg\", \"gif\", \"webp\"]\ndatepicker = [\"jiff\"]\nfile = [\"dep:mime_guess2\"]\ngif = [\"image\", \"image/gif\"]\nwebp = [\"image\", \"image/webp\"]\nhttp = [\"dep:ehttp\"]\nimage = [\"dep:image\"]\nserde = [\"egui/serde\", \"enum-map/serde\", \"dep:serde\"]\nsvg = [\"resvg\"]\nsvg_text = [\"svg\", \"resvg/text\", \"resvg/system-fonts\"]\nsvg_images = [\"svg\", \"resvg/raster-images\"]\nsyntect = [\"dep:syntect\"]\n\n[dependencies]\nenum-map = \"3.1\"\nitertools = \"0.15.0\"\n\n[dependencies.egui]\ndefault-features = false\nversion = \"0.37.0\"\npath = \"crates/egui\"\n\n[dependencies.ahash]\nversion = \"0.8.12\"\ndefault-features = false\nfeatures = [\"no-rng\", \"std\"]\n\n[dependencies.log]\nversion = \"0.4.34\"\nfeatures = [\"std\"]\n\n[dependencies.profiling]\nversion = \"1.0\"\ndefault-features = false\n\n[dependencies.serde]\noptional = true\nversion = \"1.0\"\nfeatures = [\"derive\"]\n\n[dependencies.jiff]\noptional = true\nfeatures = [\"std\", \"tz-system\", \"js\"]\nversion = \"0.2.35\"\ndefault-features = false\n\n[dependencies.document-features]\noptional = true\nversion = \"0.2.12\"\n\n[dependencies.image]\noptional = true\nversion = \"0.25.10\"\ndefault-features = false\n\n[dependencies.mime_guess2]\noptional = true\nversion = \"2.3\"\ndefault-features = false\n\n[dependencies.syntect]\noptional = true\nfeatures = [\"default-fancy\"]\nversion = \"5.3\"\ndefault-features = false\n\n[dependencies.resvg]\noptional = true\nversion = \"0.45.1\"\ndefault-features = false\n\n[dependencies.ehttp]\noptional = true\nversion = \"0.7.1\"\ndefault-features = false\n\n[dev-dependencies]\ntempfile = \"3.27\"\n\n[dev-dependencies.egui]\nfeatures = [\"default_fonts\"]\nversion = \"0.37.0\"\npath = \"crates/egui\"\ndefault-features = false\n\n[dev-dependencies.egui_kittest]\npath = \"../egui_kittest\"\nfeatures = [\"snapshot\", \"wgpu\"]\n", - "dest": "cargo/vendor/egui_extras", - "dest-filename": "Cargo.toml" - }, - { - "type": "inline", - "contents": "{\"package\": null, \"files\": {}}", - "dest": "cargo/vendor/egui_extras", - "dest-filename": ".cargo-checksum.json" - }, { "type": "shell", "commands": [ @@ -8586,7 +10071,7 @@ }, { "type": "inline", - "contents": "[source.vendored-sources]\ndirectory = \"cargo/vendor\"\n\n[source.crates-io]\nreplace-with = \"vendored-sources\"\n\n[source.\"https://github.com/storytold/craft-libs?rev=82a24b006eefa036b43c09a67fb9a3fbd17ffe63\"]\ngit = \"https://github.com/storytold/craft-libs\"\nreplace-with = \"vendored-sources\"\nrev = \"82a24b006eefa036b43c09a67fb9a3fbd17ffe63\"\n\n[source.\"https://github.com/storytold/craft-libs?rev=25da1314d443171b4adeaad2cd9454b273f35c6f\"]\ngit = \"https://github.com/storytold/craft-libs\"\nreplace-with = \"vendored-sources\"\nrev = \"25da1314d443171b4adeaad2cd9454b273f35c6f\"\n\n[source.\"https://github.com/storytold/egui.git?rev=6d518fc799681571963842f95b55a6b68431b15a\"]\ngit = \"https://github.com/storytold/egui\"\nreplace-with = \"vendored-sources\"\nrev = \"6d518fc799681571963842f95b55a6b68431b15a\"\n\n[source.\"https://github.com/storytold/winit.git?rev=a517b3846ee8457d84ee4975110bfda6797c44dc\"]\ngit = \"https://github.com/storytold/winit\"\nreplace-with = \"vendored-sources\"\nrev = \"a517b3846ee8457d84ee4975110bfda6797c44dc\"\n", + "contents": "[source.vendored-sources]\ndirectory = \"cargo/vendor\"\n\n[source.crates-io]\nreplace-with = \"vendored-sources\"\n\n[source.\"https://github.com/storytold/craft-libs?rev=94777dcf7f8962476e96b049d08d22e25b9330c2\"]\ngit = \"https://github.com/storytold/craft-libs\"\nreplace-with = \"vendored-sources\"\nrev = \"94777dcf7f8962476e96b049d08d22e25b9330c2\"\n\n[source.\"https://github.com/storytold/craft-libs?rev=f0f4758c01581d79577b9bf5046c06f4e77b1f18\"]\ngit = \"https://github.com/storytold/craft-libs\"\nreplace-with = \"vendored-sources\"\nrev = \"f0f4758c01581d79577b9bf5046c06f4e77b1f18\"\n\n[source.\"https://github.com/storytold/craft-libs?rev=c5a1cbfb5f9049f9270955caffb5bee5997aebf7\"]\ngit = \"https://github.com/storytold/craft-libs\"\nreplace-with = \"vendored-sources\"\nrev = \"c5a1cbfb5f9049f9270955caffb5bee5997aebf7\"\n\n[source.\"https://github.com/storytold/craft-libs?rev=9dcbd90c7d16e1a668b3afa057e940e2db328b93\"]\ngit = \"https://github.com/storytold/craft-libs\"\nreplace-with = \"vendored-sources\"\nrev = \"9dcbd90c7d16e1a668b3afa057e940e2db328b93\"\n\n[source.\"https://github.com/storytold/craft-libs?rev=b77af389f30bb10de10d8436ca9b39fe94e3bb67\"]\ngit = \"https://github.com/storytold/craft-libs\"\nreplace-with = \"vendored-sources\"\nrev = \"b77af389f30bb10de10d8436ca9b39fe94e3bb67\"\n\n[source.\"https://github.com/storytold/craft-libs?rev=478c50560d3c6fad3d613af2a30b35c3bc9f4c0f\"]\ngit = \"https://github.com/storytold/craft-libs\"\nreplace-with = \"vendored-sources\"\nrev = \"478c50560d3c6fad3d613af2a30b35c3bc9f4c0f\"\n\n[source.\"https://github.com/storytold/craft-libs?rev=2651dbeb2b13f621db23f65347380e7f26e316f0\"]\ngit = \"https://github.com/storytold/craft-libs\"\nreplace-with = \"vendored-sources\"\nrev = \"2651dbeb2b13f621db23f65347380e7f26e316f0\"\n\n[source.\"https://github.com/storytold/craft-libs?rev=6e03f65bf45181db77ba6229716e6624db9eb25b\"]\ngit = \"https://github.com/storytold/craft-libs\"\nreplace-with = \"vendored-sources\"\nrev = \"6e03f65bf45181db77ba6229716e6624db9eb25b\"\n\n[source.\"https://github.com/storytold/egui.git?rev=6d518fc799681571963842f95b55a6b68431b15a\"]\ngit = \"https://github.com/storytold/egui\"\nreplace-with = \"vendored-sources\"\nrev = \"6d518fc799681571963842f95b55a6b68431b15a\"\n\n[source.\"https://github.com/storytold/winit.git?rev=a517b3846ee8457d84ee4975110bfda6797c44dc\"]\ngit = \"https://github.com/storytold/winit\"\nreplace-with = \"vendored-sources\"\nrev = \"a517b3846ee8457d84ee4975110bfda6797c44dc\"\n", "dest": "cargo", "dest-filename": "config" } From 5a68b04bcca0faf584badc17bc337c1b18ad9095 Mon Sep 17 00:00:00 2001 From: "Dylan M. Taylor" <dylan@dylanmtaylor.com> Date: Sun, 15 Nov 2026 18:46:17 -0500 Subject: [PATCH 47/61] fix(flatpak): isolate vendored Git source revisions --- packaging/linux/flatpak/cargo-sources.json | 236 +++++++++--------- .../linux/flatpak/generate-cargo-sources.py | 51 +++- .../flatpak/test_generate_cargo_sources.py | 44 ++++ 3 files changed, 209 insertions(+), 122 deletions(-) diff --git a/packaging/linux/flatpak/cargo-sources.json b/packaging/linux/flatpak/cargo-sources.json index 47d8e3021f..e36140f1e1 100644 --- a/packaging/linux/flatpak/cargo-sources.json +++ b/packaging/linux/flatpak/cargo-sources.json @@ -1570,433 +1570,433 @@ { "type": "shell", "commands": [ - "cp -r --reflink=auto \"flatpak-cargo/git/craft-libs-94777dc/crates/cms\" \"cargo/vendor/craft-cms\"" + "mkdir -p \"cargo/vendor-git/6fd0ceba5f4137be1fe00e9c031f810234e38df6f60195003fed7057c96f0aa1\" && cp -r --reflink=auto \"flatpak-cargo/git/craft-libs-94777dc/crates/cms\" \"cargo/vendor-git/6fd0ceba5f4137be1fe00e9c031f810234e38df6f60195003fed7057c96f0aa1/craft-cms\"" ] }, { "type": "inline", "contents": "[package]\nname = \"craft-cms\"\nversion = \"0.1.0\"\nedition = \"2024\"\nlicense = \"MIT OR Apache-2.0\"\nrust-version = \"1.95\"\nrepository = \"https://github.com/storytold/craft-libs\"\ndescription = \"Pure-Rust ICC v2/v4 colour management: profile parsing and writing, transforms, rendering intents, black point compensation\"\nexclude = [\"tests/data\", \"tests/fogra39.rs\"]\n\n[lints.rust]\nunsafe_code = \"forbid\"\nunused_workspace_dependencies = \"allow\"\n\n[lints.rust.unexpected_cfgs]\nlevel = \"warn\"\ncheck-cfg = [\"cfg(craft_pdf_unicode_fixtures)\"]\n\n[lints.clippy]\ncognitive_complexity = \"deny\"\ntoo_many_arguments = \"deny\"\nunused_workspace_dependencies = \"allow\"\nwildcard_imports = \"deny\"\ndbg_macro = \"warn\"\ntodo = \"warn\"\n\n[dependencies.md5]\npackage = \"md-5\"\nversion = \"0.10\"\ndefault-features = false\n\n[target.\"cfg(not(target_arch = \\\"wasm32\\\"))\".dependencies]\nrayon = \"1\"\n\n[dev-dependencies]\nmoxcms = \"0.8\"\n", - "dest": "cargo/vendor/craft-cms", + "dest": "cargo/vendor-git/6fd0ceba5f4137be1fe00e9c031f810234e38df6f60195003fed7057c96f0aa1/craft-cms", "dest-filename": "Cargo.toml" }, { "type": "inline", "contents": "{\"package\": null, \"files\": {}}", - "dest": "cargo/vendor/craft-cms", + "dest": "cargo/vendor-git/6fd0ceba5f4137be1fe00e9c031f810234e38df6f60195003fed7057c96f0aa1/craft-cms", "dest-filename": ".cargo-checksum.json" }, { "type": "shell", "commands": [ - "cp -r --reflink=auto \"flatpak-cargo/git/craft-libs-f0f4758/crates/codepage\" \"cargo/vendor/craft-codepage\"" + "mkdir -p \"cargo/vendor-git/bc00bd22a20692df38f25839a8568cd55b90e379a41719721bbc0f04fe5e29f7\" && cp -r --reflink=auto \"flatpak-cargo/git/craft-libs-f0f4758/crates/codepage\" \"cargo/vendor-git/bc00bd22a20692df38f25839a8568cd55b90e379a41719721bbc0f04fe5e29f7/craft-codepage\"" ] }, { "type": "inline", "contents": "[package]\nname = \"craft-codepage\"\ndescription = \"Legacy 8-bit code pages, one table each: the single-byte Windows pages, Mac OS Roman and the DOS (OEM) pages, keyed by Windows code page number, with the RTF/Word font charsets.\"\nversion = \"0.1.0\"\nedition = \"2024\"\nlicense = \"MIT OR Apache-2.0\"\nrust-version = \"1.95\"\nrepository = \"https://github.com/storytold/craft-libs\"\n\n[lints.rust]\nunsafe_code = \"forbid\"\nunused_workspace_dependencies = \"allow\"\n\n[lints.rust.unexpected_cfgs]\nlevel = \"warn\"\ncheck-cfg = [\"cfg(craft_pdf_unicode_fixtures)\"]\n\n[lints.clippy]\ncognitive_complexity = \"deny\"\ntoo_many_arguments = \"deny\"\nunused_workspace_dependencies = \"allow\"\nwildcard_imports = \"deny\"\ndbg_macro = \"warn\"\ntodo = \"warn\"\n\n[dev-dependencies]\nencoding_rs = \"0.8\"\n", - "dest": "cargo/vendor/craft-codepage", + "dest": "cargo/vendor-git/bc00bd22a20692df38f25839a8568cd55b90e379a41719721bbc0f04fe5e29f7/craft-codepage", "dest-filename": "Cargo.toml" }, { "type": "inline", "contents": "{\"package\": null, \"files\": {}}", - "dest": "cargo/vendor/craft-codepage", + "dest": "cargo/vendor-git/bc00bd22a20692df38f25839a8568cd55b90e379a41719721bbc0f04fe5e29f7/craft-codepage", "dest-filename": ".cargo-checksum.json" }, { "type": "shell", "commands": [ - "cp -r --reflink=auto \"flatpak-cargo/git/craft-libs-94777dc/crates/crw\" \"cargo/vendor/craft-crw\"" + "mkdir -p \"cargo/vendor-git/6fd0ceba5f4137be1fe00e9c031f810234e38df6f60195003fed7057c96f0aa1\" && cp -r --reflink=auto \"flatpak-cargo/git/craft-libs-94777dc/crates/crw\" \"cargo/vendor-git/6fd0ceba5f4137be1fe00e9c031f810234e38df6f60195003fed7057c96f0aa1/craft-crw\"" ] }, { "type": "inline", "contents": "[package]\nname = \"craft-crw\"\ndescription = \"Clean-room Canon CRW (CIFF) raw decoder: the heap container, the derived entropy coding, sensor levels and as-shot white balance.\"\nversion = \"0.1.0\"\nedition = \"2024\"\nlicense = \"MIT OR Apache-2.0\"\nrust-version = \"1.95\"\nrepository = \"https://github.com/storytold/craft-libs\"\n\n[lints.rust]\nunsafe_code = \"forbid\"\nunused_workspace_dependencies = \"allow\"\n\n[lints.rust.unexpected_cfgs]\nlevel = \"warn\"\ncheck-cfg = [\"cfg(craft_pdf_unicode_fixtures)\"]\n\n[lints.clippy]\ncognitive_complexity = \"deny\"\ntoo_many_arguments = \"deny\"\nunused_workspace_dependencies = \"allow\"\nwildcard_imports = \"deny\"\ndbg_macro = \"warn\"\ntodo = \"warn\"\n\n[dependencies]\nthiserror = \"2\"\n\n[dev-dependencies]\nproptest = \"1\"\nserde_json = \"1\"\n\n[dev-dependencies.serde]\nversion = \"1\"\nfeatures = [\"derive\"]\n\n[dev-dependencies.sha2]\nversion = \"0.10\"\ndefault-features = false\nfeatures = [\"std\"]\n", - "dest": "cargo/vendor/craft-crw", + "dest": "cargo/vendor-git/6fd0ceba5f4137be1fe00e9c031f810234e38df6f60195003fed7057c96f0aa1/craft-crw", "dest-filename": "Cargo.toml" }, { "type": "inline", "contents": "{\"package\": null, \"files\": {}}", - "dest": "cargo/vendor/craft-crw", + "dest": "cargo/vendor-git/6fd0ceba5f4137be1fe00e9c031f810234e38df6f60195003fed7057c96f0aa1/craft-crw", "dest-filename": ".cargo-checksum.json" }, { "type": "shell", "commands": [ - "cp -r --reflink=auto \"flatpak-cargo/git/craft-libs-c5a1cbf/crates/docpath\" \"cargo/vendor/craft-docpath\"" + "mkdir -p \"cargo/vendor-git/11a22760e699d74db2deeccbdb390b343ad010ce425dcb15451f0e14e45ff298\" && cp -r --reflink=auto \"flatpak-cargo/git/craft-libs-c5a1cbf/crates/docpath\" \"cargo/vendor-git/11a22760e699d74db2deeccbdb390b343ad010ce425dcb15451f0e14e45ff298/craft-docpath\"" ] }, { "type": "inline", "contents": "[package]\nname = \"craft-docpath\"\ndescription = \"Decide whether a file path or file URL stored in a document refers to a local file.\"\nversion = \"0.1.0\"\nedition = \"2024\"\nlicense = \"MIT OR Apache-2.0\"\nrust-version = \"1.95\"\nrepository = \"https://github.com/storytold/craft-libs\"\n\n[lints.rust]\nunsafe_code = \"forbid\"\n\n[lints.rust.unexpected_cfgs]\nlevel = \"warn\"\ncheck-cfg = [\"cfg(craft_pdf_unicode_fixtures)\"]\n\n[lints.clippy]\ncognitive_complexity = \"deny\"\ntoo_many_arguments = \"deny\"\nwildcard_imports = \"deny\"\ndbg_macro = \"warn\"\ntodo = \"warn\"\n", - "dest": "cargo/vendor/craft-docpath", + "dest": "cargo/vendor-git/11a22760e699d74db2deeccbdb390b343ad010ce425dcb15451f0e14e45ff298/craft-docpath", "dest-filename": "Cargo.toml" }, { "type": "inline", "contents": "{\"package\": null, \"files\": {}}", - "dest": "cargo/vendor/craft-docpath", + "dest": "cargo/vendor-git/11a22760e699d74db2deeccbdb390b343ad010ce425dcb15451f0e14e45ff298/craft-docpath", "dest-filename": ".cargo-checksum.json" }, { "type": "shell", "commands": [ - "cp -r --reflink=auto \"flatpak-cargo/git/craft-libs-c5a1cbf/crates/fonts-build\" \"cargo/vendor/craft-fonts-build\"" + "mkdir -p \"cargo/vendor-git/11a22760e699d74db2deeccbdb390b343ad010ce425dcb15451f0e14e45ff298\" && cp -r --reflink=auto \"flatpak-cargo/git/craft-libs-c5a1cbf/crates/fonts-build\" \"cargo/vendor-git/11a22760e699d74db2deeccbdb390b343ad010ce425dcb15451f0e14e45ff298/craft-fonts-build\"" ] }, { "type": "inline", "contents": "[package]\nname = \"craft-fonts-build\"\ndescription = \"Embeds the optional craft-fonts faces from an app's build.rs, plus the EmbeddedFace type the generated table uses.\"\nversion = \"0.1.0\"\nedition = \"2024\"\nlicense = \"MIT OR Apache-2.0\"\nrust-version = \"1.95\"\nrepository = \"https://github.com/storytold/craft-libs\"\n\n[features]\nsubset = [\"dep:skera\", \"dep:skrifa\"]\n\n[dependencies.skera]\nversion = \"0.8\"\noptional = true\n\n[dependencies.skrifa]\nversion = \"0.48\"\ndefault-features = false\nfeatures = [\"std\"]\noptional = true\n\n[dev-dependencies.craft-fonts-build-consumer]\npath = \"tests/consumer\"\n\n[lints.rust]\nunsafe_code = \"forbid\"\n\n[lints.rust.unexpected_cfgs]\nlevel = \"warn\"\ncheck-cfg = [\"cfg(craft_pdf_unicode_fixtures)\"]\n\n[lints.clippy]\ncognitive_complexity = \"deny\"\ntoo_many_arguments = \"deny\"\nwildcard_imports = \"deny\"\ndbg_macro = \"warn\"\ntodo = \"warn\"\n", - "dest": "cargo/vendor/craft-fonts-build", + "dest": "cargo/vendor-git/11a22760e699d74db2deeccbdb390b343ad010ce425dcb15451f0e14e45ff298/craft-fonts-build", "dest-filename": "Cargo.toml" }, { "type": "inline", "contents": "{\"package\": null, \"files\": {}}", - "dest": "cargo/vendor/craft-fonts-build", + "dest": "cargo/vendor-git/11a22760e699d74db2deeccbdb390b343ad010ce425dcb15451f0e14e45ff298/craft-fonts-build", "dest-filename": ".cargo-checksum.json" }, { "type": "shell", "commands": [ - "cp -r --reflink=auto \"flatpak-cargo/git/craft-libs-9dcbd90/crates/gainmap\" \"cargo/vendor/craft-gainmap\"" + "mkdir -p \"cargo/vendor-git/36bf00be069421f8a8a7428c4360efee8b4243207a59d7b566c6f48fc5918f61\" && cp -r --reflink=auto \"flatpak-cargo/git/craft-libs-9dcbd90/crates/gainmap\" \"cargo/vendor-git/36bf00be069421f8a8a7428c4360efee8b4243207a59d7b566c6f48fc5918f61/craft-gainmap\"" ] }, { "type": "inline", "contents": "[package]\nname = \"craft-gainmap\"\ndescription = \"HDR gain maps (ISO 21496-1, Adobe hdrgm, Apple): metadata reader and writer, and the arithmetic that measures and applies a gain map.\"\nversion = \"0.1.0\"\nedition = \"2024\"\nlicense = \"MIT OR Apache-2.0\"\nrust-version = \"1.95\"\nrepository = \"https://github.com/storytold/craft-libs\"\n\n[lints.rust]\nunsafe_code = \"forbid\"\nunused_workspace_dependencies = \"allow\"\n\n[lints.rust.unexpected_cfgs]\nlevel = \"warn\"\ncheck-cfg = [\"cfg(craft_pdf_unicode_fixtures)\"]\n\n[lints.clippy]\ncognitive_complexity = \"deny\"\ntoo_many_arguments = \"deny\"\nunused_workspace_dependencies = \"allow\"\nwildcard_imports = \"deny\"\ndbg_macro = \"warn\"\ntodo = \"warn\"\n\n[dependencies]\nthiserror = \"2\"\n", - "dest": "cargo/vendor/craft-gainmap", + "dest": "cargo/vendor-git/36bf00be069421f8a8a7428c4360efee8b4243207a59d7b566c6f48fc5918f61/craft-gainmap", "dest-filename": "Cargo.toml" }, { "type": "inline", "contents": "{\"package\": null, \"files\": {}}", - "dest": "cargo/vendor/craft-gainmap", + "dest": "cargo/vendor-git/36bf00be069421f8a8a7428c4360efee8b4243207a59d7b566c6f48fc5918f61/craft-gainmap", "dest-filename": ".cargo-checksum.json" }, { "type": "shell", "commands": [ - "cp -r --reflink=auto \"flatpak-cargo/git/craft-libs-b77af38/crates/gif\" \"cargo/vendor/craft-gif\"" + "mkdir -p \"cargo/vendor-git/a51e2c3f46af71f1caed91009f88b4f9982db0c4152c6659d11967a7731b1ccc\" && cp -r --reflink=auto \"flatpak-cargo/git/craft-libs-b77af38/crates/gif\" \"cargo/vendor-git/a51e2c3f46af71f1caed91009f88b4f9982db0c4152c6659d11967a7731b1ccc/craft-gif\"" ] }, { "type": "inline", "contents": "[package]\nname = \"craft-gif\"\ndescription = \"GIF block reader, bounded frame decoder and animation writer.\"\nversion = \"0.1.0\"\nedition = \"2024\"\nlicense = \"MIT OR Apache-2.0\"\nrust-version = \"1.95\"\nrepository = \"https://github.com/storytold/craft-libs\"\n\n[lints.rust]\nunsafe_code = \"forbid\"\nunused_workspace_dependencies = \"allow\"\n\n[lints.rust.unexpected_cfgs]\nlevel = \"warn\"\ncheck-cfg = [\"cfg(craft_pdf_unicode_fixtures)\"]\n\n[lints.clippy]\ncognitive_complexity = \"deny\"\ntoo_many_arguments = \"deny\"\nunused_workspace_dependencies = \"allow\"\nwildcard_imports = \"deny\"\ndbg_macro = \"warn\"\ntodo = \"warn\"\n\n[features]\nframes = [\"dep:image\"]\n\n[dependencies]\ngif = \"0.14\"\n\n[dependencies.image]\nversion = \"0.25\"\ndefault-features = false\nfeatures = [\"gif\"]\noptional = true\n\n[dev-dependencies.image]\nversion = \"0.25\"\ndefault-features = false\nfeatures = [\"gif\"]\n", - "dest": "cargo/vendor/craft-gif", + "dest": "cargo/vendor-git/a51e2c3f46af71f1caed91009f88b4f9982db0c4152c6659d11967a7731b1ccc/craft-gif", "dest-filename": "Cargo.toml" }, { "type": "inline", "contents": "{\"package\": null, \"files\": {}}", - "dest": "cargo/vendor/craft-gif", + "dest": "cargo/vendor-git/a51e2c3f46af71f1caed91009f88b4f9982db0c4152c6659d11967a7731b1ccc/craft-gif", "dest-filename": ".cargo-checksum.json" }, { "type": "shell", "commands": [ - "cp -r --reflink=auto \"flatpak-cargo/git/craft-libs-9dcbd90/crates/heif\" \"cargo/vendor/craft-heif\"" + "mkdir -p \"cargo/vendor-git/36bf00be069421f8a8a7428c4360efee8b4243207a59d7b566c6f48fc5918f61\" && cp -r --reflink=auto \"flatpak-cargo/git/craft-libs-9dcbd90/crates/heif\" \"cargo/vendor-git/36bf00be069421f8a8a7428c4360efee8b4243207a59d7b566c6f48fc5918f61/craft-heif\"" ] }, { "type": "inline", "contents": "[package]\nname = \"craft-heif\"\ndescription = \"Optional HEIF/HEIC still-image decoder: heic-rs for the container and HEVC, libheif-matching colour conversion, panic-guarded.\"\nversion = \"0.1.0\"\nedition = \"2024\"\nlicense = \"MIT OR Apache-2.0\"\nrust-version = \"1.95\"\nrepository = \"https://github.com/storytold/craft-libs\"\n\n[dependencies.heic-rs]\nversion = \"=0.1.4\"\ndefault-features = false\nfeatures = [\"std\"]\noptional = true\n\n[target.\"cfg(not(target_arch = \\\"wasm32\\\"))\".dependencies.heic-rs]\nversion = \"=0.1.4\"\ndefault-features = false\nfeatures = [\"std\", \"parallel\"]\noptional = true\n\n[target.\"cfg(not(target_arch = \\\"wasm32\\\"))\".dependencies.rayon]\noptional = true\nversion = \"1\"\n\n[features]\ndefault = [\"decode\"]\ndecode = [\"dep:heic-rs\", \"dep:rayon\"]\nmetadata = []\ntestdata = []\n\n[lints.rust]\nunsafe_code = \"forbid\"\nunused_workspace_dependencies = \"allow\"\n\n[lints.rust.unexpected_cfgs]\nlevel = \"warn\"\ncheck-cfg = [\"cfg(craft_pdf_unicode_fixtures)\"]\n\n[lints.clippy]\ncognitive_complexity = \"deny\"\ntoo_many_arguments = \"deny\"\nunused_workspace_dependencies = \"allow\"\nwildcard_imports = \"deny\"\ndbg_macro = \"warn\"\ntodo = \"warn\"\n", - "dest": "cargo/vendor/craft-heif", + "dest": "cargo/vendor-git/36bf00be069421f8a8a7428c4360efee8b4243207a59d7b566c6f48fc5918f61/craft-heif", "dest-filename": "Cargo.toml" }, { "type": "inline", "contents": "{\"package\": null, \"files\": {}}", - "dest": "cargo/vendor/craft-heif", + "dest": "cargo/vendor-git/36bf00be069421f8a8a7428c4360efee8b4243207a59d7b566c6f48fc5918f61/craft-heif", "dest-filename": ".cargo-checksum.json" }, { "type": "shell", "commands": [ - "cp -r --reflink=auto \"flatpak-cargo/git/craft-libs-c5a1cbf/crates/i18n\" \"cargo/vendor/craft-i18n\"" + "mkdir -p \"cargo/vendor-git/11a22760e699d74db2deeccbdb390b343ad010ce425dcb15451f0e14e45ff298\" && cp -r --reflink=auto \"flatpak-cargo/git/craft-libs-c5a1cbf/crates/i18n\" \"cargo/vendor-git/11a22760e699d74db2deeccbdb390b343ad010ce425dcb15451f0e14e45ff298/craft-i18n\"" ] }, { "type": "inline", "contents": "[package]\nname = \"craft-i18n\"\ndescription = \"Translations for the Craft apps: the embedded craft-i18n catalogs, lookup with fallback, plurals, numbers for a region, language names, the system locale, search folding and locale sorting.\"\nversion = \"0.1.0\"\nedition = \"2024\"\nlicense = \"MIT OR Apache-2.0\"\nrust-version = \"1.95\"\nrepository = \"https://github.com/storytold/craft-libs\"\n\n[dependencies]\nwriteable = \"0.6\"\nlog = \"0.4\"\nsys-locale = \"0.3\"\nicu_normalizer = \"~2.3\"\nicu_properties = \"~2.3\"\nunicode-bidi = \"0.3\"\n\n[dependencies.fixed_decimal]\nversion = \"0.7.2\"\ndefault-features = false\n\n[dependencies.icu_decimal]\nversion = \"~2.3\"\ndefault-features = false\nfeatures = [\"serde\"]\n\n[dependencies.icu_locale_core]\nversion = \"~2.3\"\ndefault-features = false\n\n[dependencies.icu_locale_fallback]\nversion = \"~2.3\"\ndefault-features = false\nfeatures = [\"compiled_data\"]\n\n[dependencies.icu_plurals]\nversion = \"~2.3\"\ndefault-features = false\nfeatures = [\"serde\"]\n\n[dependencies.icu_provider]\nversion = \"~2.3\"\ndefault-features = false\nfeatures = [\"sync\"]\n\n[dependencies.icu_provider_adapters]\nversion = \"~2.3\"\ndefault-features = false\n\n[dependencies.icu_provider_blob]\nversion = \"~2.3\"\ndefault-features = false\n\n[dependencies.icu_collator]\nversion = \"~2.3.1\"\ndefault-features = false\nfeatures = [\"serde\"]\noptional = true\n\n[target.\"cfg(target_arch = \\\"wasm32\\\")\".dependencies.sys-locale]\nversion = \"0.3\"\nfeatures = [\"js\"]\n\n[target.\"cfg(windows)\".dependencies]\nwindows-registry = \"0.6\"\n\n[target.\"cfg(target_vendor = \\\"apple\\\")\".dependencies.objc2-foundation]\nversion = \"0.3.2\"\ndefault-features = false\nfeatures = [\"std\", \"NSDateFormatter\", \"NSFormatter\", \"NSLocale\", \"NSString\"]\n\n[features]\ncollate = [\"dep:icu_collator\", \"icu_provider/serde\", \"icu_provider_blob/alloc\"]\n\n[lints.rust]\nunsafe_code = \"forbid\"\n\n[lints.rust.unexpected_cfgs]\nlevel = \"warn\"\ncheck-cfg = [\"cfg(craft_pdf_unicode_fixtures)\"]\n\n[lints.clippy]\ncognitive_complexity = \"deny\"\ntoo_many_arguments = \"deny\"\nwildcard_imports = \"deny\"\ndbg_macro = \"warn\"\ntodo = \"warn\"\n", - "dest": "cargo/vendor/craft-i18n", + "dest": "cargo/vendor-git/11a22760e699d74db2deeccbdb390b343ad010ce425dcb15451f0e14e45ff298/craft-i18n", "dest-filename": "Cargo.toml" }, { "type": "inline", "contents": "{\"package\": null, \"files\": {}}", - "dest": "cargo/vendor/craft-i18n", + "dest": "cargo/vendor-git/11a22760e699d74db2deeccbdb390b343ad010ce425dcb15451f0e14e45ff298/craft-i18n", "dest-filename": ".cargo-checksum.json" }, { "type": "shell", "commands": [ - "cp -r --reflink=auto \"flatpak-cargo/git/craft-libs-478c505/crates/image-codecs\" \"cargo/vendor/craft-image-codecs\"" + "mkdir -p \"cargo/vendor-git/cb31475a7a9d19c00f48b4c43603f2f1a464c6dce15da1d21bba4c653eeba6b2\" && cp -r --reflink=auto \"flatpak-cargo/git/craft-libs-478c505/crates/image-codecs\" \"cargo/vendor-git/cb31475a7a9d19c00f48b4c43603f2f1a464c6dce15da1d21bba4c653eeba6b2/craft-image-codecs\"" ] }, { "type": "inline", "contents": "[package]\nname = \"craft-image-codecs\"\ndescription = \"Bounded, depth- and metadata-preserving codecs for flat raster image formats\"\nversion = \"0.1.0\"\nedition = \"2024\"\nlicense = \"MIT OR Apache-2.0\"\nrust-version = \"1.95\"\nrepository = \"https://github.com/storytold/craft-libs\"\n\n[lints.rust]\nunsafe_code = \"forbid\"\nunused_workspace_dependencies = \"allow\"\n\n[lints.rust.unexpected_cfgs]\nlevel = \"warn\"\ncheck-cfg = [\"cfg(craft_pdf_unicode_fixtures)\"]\n\n[lints.clippy]\ncognitive_complexity = \"deny\"\ntoo_many_arguments = \"deny\"\nunused_workspace_dependencies = \"allow\"\nwildcard_imports = \"deny\"\ndbg_macro = \"warn\"\ntodo = \"warn\"\n\n[features]\ncorpus = []\ndefault = []\navif = [\"image/avif\", \"dep:ravif\", \"dep:rav1e\", \"dep:avif-serialize\"]\nheif = [\"dep:craft-heif\"]\n\n[dependencies]\ncrc32fast = \"1.5\"\nthiserror = \"2\"\npng = \"0.18\"\nhalf = \"2\"\nserde_json = \"1\"\nimage-webp = \"0.2\"\nzune-jpeg = \"0.5\"\nzune-core = \"0.5\"\njpeg-encoder = \"0.6\"\n\n[dependencies.image]\nversion = \"0.25\"\ndefault-features = false\nfeatures = [\"png\", \"jpeg\", \"tiff\", \"gif\", \"bmp\", \"tga\", \"ico\", \"qoi\", \"hdr\"]\n\n[dependencies.tiff]\nversion = \"0.11\"\ndefault-features = false\nfeatures = [\"deflate\", \"fax\", \"jpeg\", \"lzw\"]\n\n[dependencies.exr]\nversion = \"1.73\"\ndefault-features = false\n\n[dependencies.flate2]\nversion = \"1.1.10\"\ndefault-features = false\nfeatures = [\"zlib-rs\", \"runtime_detection\"]\n\n[dependencies.craft-jpeg]\npath = \"crates/jpeg\"\n\n[dependencies.craft-metadata]\npath = \"crates/metadata\"\n\n[dependencies.zune-jpegxl]\nversion = \"=0.5.2\"\ndefault-features = false\nfeatures = [\"std\"]\n\n[dependencies.craft-heif]\noptional = true\npath = \"crates/heif\"\n\n[dependencies.ravif]\nversion = \"0.13\"\ndefault-features = false\noptional = true\n\n[dependencies.rav1e]\nversion = \"0.8\"\ndefault-features = false\noptional = true\n\n[dependencies.avif-serialize]\nversion = \"0.8\"\noptional = true\n\n[dependencies.hayro-jpeg2000]\nversion = \"=0.3.5\"\ndefault-features = false\nfeatures = [\"std\", \"simd\"]\n\n[target.\"cfg(not(target_arch = \\\"wasm32\\\"))\".dependencies]\nrayon = \"1\"\n\n[target.\"cfg(not(target_arch = \\\"wasm32\\\"))\".dependencies.exr]\nversion = \"1.73\"\ndefault-features = false\nfeatures = [\"rayon\"]\n\n[target.\"cfg(not(target_arch = \\\"wasm32\\\"))\".dev-dependencies.craft-video]\nfeatures = [\"av1-decode\"]\npath = \"crates/video\"\n\n[target.\"cfg(not(target_arch = \\\"wasm32\\\"))\".dev-dependencies.jxl-oxide]\nversion = \"=0.12.6\"\ndefault-features = false\nfeatures = [\"rayon\"]\n\n[dev-dependencies]\nproptest = \"1\"\n\n[dev-dependencies.image]\nversion = \"0.25\"\ndefault-features = false\nfeatures = [\"png\", \"jpeg\", \"tiff\"]\n\n[dev-dependencies.sha2]\nversion = \"0.10\"\ndefault-features = false\nfeatures = [\"std\"]\n", - "dest": "cargo/vendor/craft-image-codecs", + "dest": "cargo/vendor-git/cb31475a7a9d19c00f48b4c43603f2f1a464c6dce15da1d21bba4c653eeba6b2/craft-image-codecs", "dest-filename": "Cargo.toml" }, { "type": "inline", "contents": "{\"package\": null, \"files\": {}}", - "dest": "cargo/vendor/craft-image-codecs", + "dest": "cargo/vendor-git/cb31475a7a9d19c00f48b4c43603f2f1a464c6dce15da1d21bba4c653eeba6b2/craft-image-codecs", "dest-filename": ".cargo-checksum.json" }, { "type": "shell", "commands": [ - "cp -r --reflink=auto \"flatpak-cargo/git/craft-libs-478c505/crates/jpeg\" \"cargo/vendor/craft-jpeg\"" + "mkdir -p \"cargo/vendor-git/cb31475a7a9d19c00f48b4c43603f2f1a464c6dce15da1d21bba4c653eeba6b2\" && cp -r --reflink=auto \"flatpak-cargo/git/craft-libs-478c505/crates/jpeg\" \"cargo/vendor-git/cb31475a7a9d19c00f48b4c43603f2f1a464c6dce15da1d21bba4c653eeba6b2/craft-jpeg\"" ] }, { "type": "inline", "contents": "[package]\nname = \"craft-jpeg\"\ndescription = \"Clean-room JPEG decoder and 8-bit optimized baseline encoder (ITU-T T.81).\"\nversion = \"0.1.0\"\nedition = \"2024\"\nlicense = \"MIT OR Apache-2.0\"\nrust-version = \"1.95\"\nrepository = \"https://github.com/storytold/craft-libs\"\n\n[lints.rust]\nunsafe_code = \"forbid\"\nunused_workspace_dependencies = \"allow\"\n\n[lints.rust.unexpected_cfgs]\nlevel = \"warn\"\ncheck-cfg = [\"cfg(craft_pdf_unicode_fixtures)\"]\n\n[lints.clippy]\ncognitive_complexity = \"deny\"\ntoo_many_arguments = \"deny\"\nunused_workspace_dependencies = \"allow\"\nwildcard_imports = \"deny\"\ndbg_macro = \"warn\"\ntodo = \"warn\"\n\n[dependencies]\nthiserror = \"2\"\n\n[dependencies.rayon]\noptional = true\nversion = \"1\"\n\n[dev-dependencies]\njpeg-encoder = \"0.6\"\nzune-jpeg = \"0.5\"\njpeg-decoder = \"0.3\"\n\n[features]\ndefault = []\nparallel = [\"dep:rayon\"]\n", - "dest": "cargo/vendor/craft-jpeg", + "dest": "cargo/vendor-git/cb31475a7a9d19c00f48b4c43603f2f1a464c6dce15da1d21bba4c653eeba6b2/craft-jpeg", "dest-filename": "Cargo.toml" }, { "type": "inline", "contents": "{\"package\": null, \"files\": {}}", - "dest": "cargo/vendor/craft-jpeg", + "dest": "cargo/vendor-git/cb31475a7a9d19c00f48b4c43603f2f1a464c6dce15da1d21bba4c653eeba6b2/craft-jpeg", "dest-filename": ".cargo-checksum.json" }, { "type": "shell", "commands": [ - "cp -r --reflink=auto \"flatpak-cargo/git/craft-libs-b77af38/crates/jxl\" \"cargo/vendor/craft-jxl\"" + "mkdir -p \"cargo/vendor-git/a51e2c3f46af71f1caed91009f88b4f9982db0c4152c6659d11967a7731b1ccc\" && cp -r --reflink=auto \"flatpak-cargo/git/craft-libs-b77af38/crates/jxl\" \"cargo/vendor-git/a51e2c3f46af71f1caed91009f88b4f9982db0c4152c6659d11967a7731b1ccc/craft-jxl\"" ] }, { "type": "inline", "contents": "[package]\nname = \"craft-jxl\"\ndescription = \"JPEG XL image decoding and encoding with bounded input and allocation tracking.\"\nversion = \"0.1.0\"\nedition = \"2024\"\nlicense = \"MIT OR Apache-2.0\"\nrust-version = \"1.95\"\nrepository = \"https://github.com/storytold/craft-libs\"\n\n[lints.rust]\nunsafe_code = \"forbid\"\nunused_workspace_dependencies = \"allow\"\n\n[lints.rust.unexpected_cfgs]\nlevel = \"warn\"\ncheck-cfg = [\"cfg(craft_pdf_unicode_fixtures)\"]\n\n[lints.clippy]\ncognitive_complexity = \"deny\"\ntoo_many_arguments = \"deny\"\nunused_workspace_dependencies = \"allow\"\nwildcard_imports = \"deny\"\ndbg_macro = \"warn\"\ntodo = \"warn\"\n\n[features]\ndefault = [\"decode\", \"encode\"]\ndecode = [\"dep:jxl-oxide\"]\nencode = [\"dep:jixel\"]\n\n[dependencies]\nthiserror = \"2\"\n\n[dependencies.jxl-oxide]\noptional = true\nversion = \"0.12\"\ndefault-features = false\n\n[dev-dependencies.craft-cms]\npath = \"crates/cms\"\n\n[target.\"cfg(not(target_arch = \\\"wasm32\\\"))\".dependencies.jixel]\noptional = true\nversion = \"=0.3.4\"\n", - "dest": "cargo/vendor/craft-jxl", + "dest": "cargo/vendor-git/a51e2c3f46af71f1caed91009f88b4f9982db0c4152c6659d11967a7731b1ccc/craft-jxl", "dest-filename": "Cargo.toml" }, { "type": "inline", "contents": "{\"package\": null, \"files\": {}}", - "dest": "cargo/vendor/craft-jxl", + "dest": "cargo/vendor-git/a51e2c3f46af71f1caed91009f88b4f9982db0c4152c6659d11967a7731b1ccc/craft-jxl", "dest-filename": ".cargo-checksum.json" }, { "type": "shell", "commands": [ - "cp -r --reflink=auto \"flatpak-cargo/git/craft-libs-478c505/crates/metadata\" \"cargo/vendor/craft-metadata\"" + "mkdir -p \"cargo/vendor-git/cb31475a7a9d19c00f48b4c43603f2f1a464c6dce15da1d21bba4c653eeba6b2\" && cp -r --reflink=auto \"flatpak-cargo/git/craft-libs-478c505/crates/metadata\" \"cargo/vendor-git/cb31475a7a9d19c00f48b4c43603f2f1a464c6dce15da1d21bba4c653eeba6b2/craft-metadata\"" ] }, { "type": "inline", "contents": "[package]\nname = \"craft-metadata\"\ndescription = \"Photo metadata: EXIF, IPTC-IIM, XMP packets (read, write, merge) and GPX track logs, the blocks that carry them in JPEG, PNG, WebP, TIFF and CR3 files, and one model they all read into.\"\nversion = \"0.1.0\"\nedition = \"2024\"\nlicense = \"MIT OR Apache-2.0\"\nrust-version = \"1.95\"\nrepository = \"https://github.com/storytold/craft-libs\"\n\n[lints.rust]\nunsafe_code = \"forbid\"\nunused_workspace_dependencies = \"allow\"\n\n[lints.rust.unexpected_cfgs]\nlevel = \"warn\"\ncheck-cfg = [\"cfg(craft_pdf_unicode_fixtures)\"]\n\n[lints.clippy]\ncognitive_complexity = \"deny\"\ntoo_many_arguments = \"deny\"\nunused_workspace_dependencies = \"allow\"\nwildcard_imports = \"deny\"\ndbg_macro = \"warn\"\ntodo = \"warn\"\n\n[dependencies]\nquick-xml = \"0.41\"\n\n[dependencies.craft-tiff]\npath = \"crates/tiff\"\n\n[dependencies.serde]\nversion = \"1\"\nfeatures = [\"derive\"]\n\n[dependencies.chrono]\nversion = \"0.4.45\"\ndefault-features = false\nfeatures = [\"std\"]\n\n[dependencies.brotli-decompressor]\nversion = \"6\"\ndefault-features = false\nfeatures = [\"std\"]\n\n[dev-dependencies]\nproptest = \"1\"\nserde_json = \"1\"\n\n[dev-dependencies.brotli]\nversion = \"9\"\ndefault-features = false\nfeatures = [\"std\"]\n", - "dest": "cargo/vendor/craft-metadata", + "dest": "cargo/vendor-git/cb31475a7a9d19c00f48b4c43603f2f1a464c6dce15da1d21bba4c653eeba6b2/craft-metadata", "dest-filename": "Cargo.toml" }, { "type": "inline", "contents": "{\"package\": null, \"files\": {}}", - "dest": "cargo/vendor/craft-metadata", + "dest": "cargo/vendor-git/cb31475a7a9d19c00f48b4c43603f2f1a464c6dce15da1d21bba4c653eeba6b2/craft-metadata", "dest-filename": ".cargo-checksum.json" }, { "type": "shell", "commands": [ - "cp -r --reflink=auto \"flatpak-cargo/git/craft-libs-94777dc/crates/metadata\" \"cargo/vendor/craft-metadata\"" + "mkdir -p \"cargo/vendor-git/6fd0ceba5f4137be1fe00e9c031f810234e38df6f60195003fed7057c96f0aa1\" && cp -r --reflink=auto \"flatpak-cargo/git/craft-libs-94777dc/crates/metadata\" \"cargo/vendor-git/6fd0ceba5f4137be1fe00e9c031f810234e38df6f60195003fed7057c96f0aa1/craft-metadata\"" ] }, { "type": "inline", "contents": "[package]\nname = \"craft-metadata\"\ndescription = \"Photo metadata: EXIF, IPTC-IIM, XMP packets (read, write, merge) and GPX track logs, the blocks that carry them in JPEG, PNG, WebP, TIFF and CR3 files, and one model they all read into.\"\nversion = \"0.1.0\"\nedition = \"2024\"\nlicense = \"MIT OR Apache-2.0\"\nrust-version = \"1.95\"\nrepository = \"https://github.com/storytold/craft-libs\"\n\n[lints.rust]\nunsafe_code = \"forbid\"\nunused_workspace_dependencies = \"allow\"\n\n[lints.rust.unexpected_cfgs]\nlevel = \"warn\"\ncheck-cfg = [\"cfg(craft_pdf_unicode_fixtures)\"]\n\n[lints.clippy]\ncognitive_complexity = \"deny\"\ntoo_many_arguments = \"deny\"\nunused_workspace_dependencies = \"allow\"\nwildcard_imports = \"deny\"\ndbg_macro = \"warn\"\ntodo = \"warn\"\n\n[dependencies]\nquick-xml = \"0.41\"\n\n[dependencies.craft-tiff]\npath = \"crates/tiff\"\n\n[dependencies.serde]\nversion = \"1\"\nfeatures = [\"derive\"]\n\n[dependencies.chrono]\nversion = \"0.4.45\"\ndefault-features = false\nfeatures = [\"std\"]\n\n[dependencies.brotli-decompressor]\nversion = \"6\"\ndefault-features = false\nfeatures = [\"std\"]\n\n[dev-dependencies]\nproptest = \"1\"\nserde_json = \"1\"\n\n[dev-dependencies.brotli]\nversion = \"9\"\ndefault-features = false\nfeatures = [\"std\"]\n", - "dest": "cargo/vendor/craft-metadata", + "dest": "cargo/vendor-git/6fd0ceba5f4137be1fe00e9c031f810234e38df6f60195003fed7057c96f0aa1/craft-metadata", "dest-filename": "Cargo.toml" }, { "type": "inline", "contents": "{\"package\": null, \"files\": {}}", - "dest": "cargo/vendor/craft-metadata", + "dest": "cargo/vendor-git/6fd0ceba5f4137be1fe00e9c031f810234e38df6f60195003fed7057c96f0aa1/craft-metadata", "dest-filename": ".cargo-checksum.json" }, { "type": "shell", "commands": [ - "cp -r --reflink=auto \"flatpak-cargo/git/craft-libs-f0f4758/crates/mime\" \"cargo/vendor/craft-mime\"" + "mkdir -p \"cargo/vendor-git/bc00bd22a20692df38f25839a8568cd55b90e379a41719721bbc0f04fe5e29f7\" && cp -r --reflink=auto \"flatpak-cargo/git/craft-libs-f0f4758/crates/mime\" \"cargo/vendor-git/bc00bd22a20692df38f25839a8568cd55b90e379a41719721bbc0f04fe5e29f7/craft-mime\"" ] }, { "type": "inline", "contents": "[package]\nname = \"craft-mime\"\ndescription = \"Internet messages and MIME: RFC 5322 headers, RFC 2045-2049 parts, encoded words, RFC 2231 parameters, transfer encodings, mbox and multipart/related lookups, read and written.\"\nversion = \"0.1.0\"\nedition = \"2024\"\nlicense = \"MIT OR Apache-2.0\"\nrust-version = \"1.95\"\nrepository = \"https://github.com/storytold/craft-libs\"\n\n[lints.rust]\nunsafe_code = \"forbid\"\nunused_workspace_dependencies = \"allow\"\n\n[lints.rust.unexpected_cfgs]\nlevel = \"warn\"\ncheck-cfg = [\"cfg(craft_pdf_unicode_fixtures)\"]\n\n[lints.clippy]\ncognitive_complexity = \"deny\"\ntoo_many_arguments = \"deny\"\nunused_workspace_dependencies = \"allow\"\nwildcard_imports = \"deny\"\ndbg_macro = \"warn\"\ntodo = \"warn\"\n\n[dependencies]\nencoding_rs = \"0.8\"\n\n[dependencies.craft-codepage]\npath = \"crates/codepage\"\n\n[dependencies.chrono]\nversion = \"0.4.45\"\ndefault-features = false\nfeatures = [\"std\"]\n\n[dependencies.chardetng]\nversion = \"1\"\noptional = true\n\n[features]\ndetect = [\"dep:chardetng\"]\n\n[dev-dependencies]\nproptest = \"1\"\n", - "dest": "cargo/vendor/craft-mime", + "dest": "cargo/vendor-git/bc00bd22a20692df38f25839a8568cd55b90e379a41719721bbc0f04fe5e29f7/craft-mime", "dest-filename": "Cargo.toml" }, { "type": "inline", "contents": "{\"package\": null, \"files\": {}}", - "dest": "cargo/vendor/craft-mime", + "dest": "cargo/vendor-git/bc00bd22a20692df38f25839a8568cd55b90e379a41719721bbc0f04fe5e29f7/craft-mime", "dest-filename": ".cargo-checksum.json" }, { "type": "shell", "commands": [ - "cp -r --reflink=auto \"flatpak-cargo/git/craft-libs-2651dbe/crates/pdf\" \"cargo/vendor/craft-pdf\"" + "mkdir -p \"cargo/vendor-git/677ec4bd11b9c98fb90165eb3a009c5b05f30eee72bbe079c4c936aa3feb3ff9\" && cp -r --reflink=auto \"flatpak-cargo/git/craft-libs-2651dbe/crates/pdf\" \"cargo/vendor-git/677ec4bd11b9c98fb90165eb3a009c5b05f30eee72bbe079c4c936aa3feb3ff9/craft-pdf\"" ] }, { "type": "inline", "contents": "[package]\nname = \"craft-pdf\"\ndescription = \"Shared PDF reading, rendering and optional writing for Craft apps\"\nversion = \"0.1.0\"\nedition = \"2024\"\nlicense = \"MIT OR Apache-2.0\"\nrepository = \"https://github.com/storytold/craft-libs\"\nrust-version = \"1.95\"\n\n[lints.rust]\nunsafe_code = \"forbid\"\nunused_workspace_dependencies = \"allow\"\n\n[lints.rust.unexpected_cfgs]\nlevel = \"warn\"\ncheck-cfg = [\"cfg(craft_pdf_unicode_fixtures)\"]\n\n[lints.clippy]\ncognitive_complexity = \"deny\"\ntoo_many_arguments = \"deny\"\nunused_workspace_dependencies = \"allow\"\nwildcard_imports = \"deny\"\ndbg_macro = \"warn\"\ntodo = \"warn\"\n\n[features]\ndefault = []\nread = [\"dep:hayro-syntax\", \"dep:thiserror\"]\ninterpret = [\"read\", \"dep:hayro-interpret\"]\npaths = [\"interpret\", \"dep:kurbo\"]\nraster = [\"interpret\", \"dep:hayro\", \"dep:bytemuck\"]\nwrite = [\"dep:krilla\", \"dep:thiserror\"]\nwrite-svg = [\"write\", \"dep:craft-svg\", \"dep:krilla-svg\", \"dep:usvg\", \"craft-svg/tree-text\"]\nwrite-pdf = [\"write\", \"krilla/pdf\"]\nwrite-raster = [\"dep:flate2\", \"dep:roxmltree\"]\nwrite-simple-text = [\"write\", \"krilla/simple-text\"]\nfilters = [\"dep:craft-stream-codecs\", \"dep:flate2\", \"dep:thiserror\"]\ncos = [\"crypt\", \"filters\", \"dep:chrono\", \"dep:js-sys\", \"dep:wasm-bindgen\"]\ncrypt = [\"dep:aes\", \"dep:md-5\", \"dep:sha2\", \"dep:stringprep\", \"dep:zeroize\", \"dep:thiserror\"]\n\n[dependencies.hayro-syntax]\noptional = true\nversion = \"=0.7.2\"\ndefault-features = false\nfeatures = [\"std\"]\n\n[dependencies.hayro-interpret]\noptional = true\nversion = \"=0.7.0\"\ndefault-features = false\nfeatures = [\"embed-fonts\", \"embed-cmaps\"]\n\n[dependencies.hayro]\noptional = true\nversion = \"=0.7.1\"\ndefault-features = false\n\n[dependencies.bytemuck]\noptional = true\nversion = \"1\"\n\n[dependencies.krilla]\noptional = true\nversion = \"=0.8.2\"\ndefault-features = false\nfeatures = [\"raster-images\"]\n\n[dependencies.craft-svg]\noptional = true\npath = \"crates/svg\"\n\n[dependencies.krilla-svg]\nversion = \"=0.8.1\"\noptional = true\n\n[dependencies.usvg]\nversion = \"=0.47.0\"\nfeatures = [\"text\"]\noptional = true\n\n[dependencies.thiserror]\noptional = true\nversion = \"2\"\n\n[dependencies.flate2]\nversion = \"1.1\"\ndefault-features = false\nfeatures = [\"zlib-rs\"]\noptional = true\n\n[dependencies.roxmltree]\nversion = \"0.21\"\noptional = true\n\n[dependencies.craft-stream-codecs]\noptional = true\npath = \"crates/stream-codecs\"\n\n[dependencies.aes]\nversion = \"0.9\"\noptional = true\n\n[dependencies.md-5]\nversion = \"0.11\"\noptional = true\n\n[dependencies.sha2]\nversion = \"0.11\"\noptional = true\n\n[dependencies.stringprep]\nversion = \"0.1\"\noptional = true\n\n[dependencies.zeroize]\nversion = \"1\"\noptional = true\n\n[dependencies.chrono]\noptional = true\nversion = \"0.4.45\"\ndefault-features = false\nfeatures = [\"std\"]\n\n[dependencies.kurbo]\noptional = true\nversion = \"0.13\"\n\n[target.\"cfg(target_arch = \\\"wasm32\\\")\".dependencies.js-sys]\nversion = \"0.3\"\noptional = true\n\n[target.\"cfg(target_arch = \\\"wasm32\\\")\".dependencies.wasm-bindgen]\nversion = \"0.2\"\noptional = true\n\n[target.\"cfg(target_arch = \\\"wasm32\\\")\".dev-dependencies]\nwasm-bindgen-test = \"0.3\"\n\n[target.\"cfg(not(target_arch = \\\"wasm32\\\"))\".dev-dependencies]\nproptest = \"1\"\n\n[dev-dependencies]\nserde_json = \"1\"\nhayro-syntax = \"=0.7.2\"\nhayro-cmap = \"=0.1.0\"\nkurbo = \"0.13\"\nttf-parser = \"=0.25.1\"\n\n[dev-dependencies.hayro-interpret]\nversion = \"=0.7.0\"\ndefault-features = false\n\n[[example]]\nname = \"cos_info\"\nrequired-features = [\"cos\"]\n\n[[example]]\nname = \"cos_protect\"\nrequired-features = [\"cos\"]\n", - "dest": "cargo/vendor/craft-pdf", + "dest": "cargo/vendor-git/677ec4bd11b9c98fb90165eb3a009c5b05f30eee72bbe079c4c936aa3feb3ff9/craft-pdf", "dest-filename": "Cargo.toml" }, { "type": "inline", "contents": "{\"package\": null, \"files\": {}}", - "dest": "cargo/vendor/craft-pdf", + "dest": "cargo/vendor-git/677ec4bd11b9c98fb90165eb3a009c5b05f30eee72bbe079c4c936aa3feb3ff9/craft-pdf", "dest-filename": ".cargo-checksum.json" }, { "type": "shell", "commands": [ - "cp -r --reflink=auto \"flatpak-cargo/git/craft-libs-9dcbd90/crates/psd\" \"cargo/vendor/craft-psd\"" + "mkdir -p \"cargo/vendor-git/36bf00be069421f8a8a7428c4360efee8b4243207a59d7b566c6f48fc5918f61\" && cp -r --reflink=auto \"flatpak-cargo/git/craft-libs-9dcbd90/crates/psd\" \"cargo/vendor-git/36bf00be069421f8a8a7428c4360efee8b4243207a59d7b566c6f48fc5918f61/craft-psd\"" ] }, { "type": "inline", "contents": "[package]\nname = \"craft-psd\"\ndescription = \"Faithful, lossless reader and writer for Adobe Photoshop PSD and PSB files, and for the Photoshop resource files that share their primitives (ABR, ASL, ACO, ACT, ASE, GRD, PAT, ATN, CSH, SHC)\"\nversion = \"0.1.0\"\nedition = \"2024\"\nlicense = \"MIT OR Apache-2.0\"\nrust-version = \"1.95\"\nrepository = \"https://github.com/storytold/craft-libs\"\n\n[features]\ncorpus = []\ndefault = []\nserde = [\"dep:serde\"]\ntestgen = []\n\n[dependencies]\nthiserror = \"2\"\nencoding_rs = \"0.8\"\n\n[dependencies.flate2]\nversion = \"1.1.10\"\ndefault-features = false\nfeatures = [\"zlib-rs\", \"runtime_detection\"]\n\n[dependencies.serde]\noptional = true\nversion = \"1\"\nfeatures = [\"derive\"]\n\n[target.\"cfg(not(target_arch = \\\"wasm32\\\"))\".dependencies]\nrayon = \"1\"\n\n[dev-dependencies]\nproptest = \"1\"\n\n[dev-dependencies.craft-psd]\npath = \".\"\nfeatures = [\"testgen\"]\n\n[lints.rust]\nunsafe_code = \"forbid\"\nunused_workspace_dependencies = \"allow\"\n\n[lints.rust.unexpected_cfgs]\nlevel = \"warn\"\ncheck-cfg = [\"cfg(craft_pdf_unicode_fixtures)\"]\n\n[lints.clippy]\ncognitive_complexity = \"deny\"\ntoo_many_arguments = \"deny\"\nunused_workspace_dependencies = \"allow\"\nwildcard_imports = \"deny\"\ndbg_macro = \"warn\"\ntodo = \"warn\"\n", - "dest": "cargo/vendor/craft-psd", + "dest": "cargo/vendor-git/36bf00be069421f8a8a7428c4360efee8b4243207a59d7b566c6f48fc5918f61/craft-psd", "dest-filename": "Cargo.toml" }, { "type": "inline", "contents": "{\"package\": null, \"files\": {}}", - "dest": "cargo/vendor/craft-psd", + "dest": "cargo/vendor-git/36bf00be069421f8a8a7428c4360efee8b4243207a59d7b566c6f48fc5918f61/craft-psd", "dest-filename": ".cargo-checksum.json" }, { "type": "shell", "commands": [ - "cp -r --reflink=auto \"flatpak-cargo/git/craft-libs-94777dc/crates/raw\" \"cargo/vendor/craft-raw\"" + "mkdir -p \"cargo/vendor-git/6fd0ceba5f4137be1fe00e9c031f810234e38df6f60195003fed7057c96f0aa1\" && cp -r --reflink=auto \"flatpak-cargo/git/craft-libs-94777dc/crates/raw\" \"cargo/vendor-git/6fd0ceba5f4137be1fe00e9c031f810234e38df6f60195003fed7057c96f0aa1/craft-raw\"" ] }, { "type": "inline", "contents": "[package]\nname = \"craft-raw\"\ndescription = \"Camera raw files, the file-format layer: container parsing, decompression and the sensor data out as a neutral raw image with its levels, crop, orientation, colour tags and embedded previews. DNG (read and write), Hasselblad 3FR/FFF, MRW, ERF, MEF, Kodak DCS, Pentax PEF, Samsung SRW, Canon CR2, Nikon NEF/NRW, Panasonic RW2, Fujifilm RAF, Olympus ORF (uncompressed), Sony ARW, Canon CR3 and Canon CRW so far.\"\nversion = \"0.1.0\"\nedition = \"2024\"\nlicense = \"MIT OR Apache-2.0\"\nrust-version = \"1.95\"\nrepository = \"https://github.com/storytold/craft-libs\"\n\n[lints.rust]\nunsafe_code = \"forbid\"\nunused_workspace_dependencies = \"allow\"\n\n[lints.rust.unexpected_cfgs]\nlevel = \"warn\"\ncheck-cfg = [\"cfg(craft_pdf_unicode_fixtures)\"]\n\n[lints.clippy]\ncognitive_complexity = \"deny\"\ntoo_many_arguments = \"deny\"\nunused_workspace_dependencies = \"allow\"\nwildcard_imports = \"deny\"\ndbg_macro = \"warn\"\ntodo = \"warn\"\n\n[features]\ndefault = [\"dng\", \"jxl\", \"crw\", \"hasselblad\", \"mrw\", \"erf\", \"mef\", \"kodak\", \"pef\", \"srw\", \"cr2\", \"nef\", \"rw2\", \"raf\", \"orf\", \"arw\", \"cr3\"]\ndng = [\"dep:miniz_oxide\", \"dep:zune-jpeg\", \"dep:zune-core\"]\njxl = [\"dng\", \"dep:jxl-oxide\"]\nhasselblad = [\"dng\"]\nmrw = []\nerf = []\nmef = []\nkodak = []\npef = []\nsrw = []\ncr2 = []\nnef = []\nrw2 = []\nraf = []\norf = []\narw = []\ncr3 = [\"dep:craft-metadata\"]\ncrw = [\"dep:craft-crw\", \"dep:chrono\"]\n\n[dependencies]\nthiserror = \"2\"\nrayon = \"1\"\n\n[dependencies.craft-tiff]\npath = \"crates/tiff\"\n\n[dependencies.craft-crw]\noptional = true\npath = \"crates/crw\"\n\n[dependencies.craft-metadata]\noptional = true\npath = \"crates/metadata\"\n\n[dependencies.serde]\nversion = \"1\"\nfeatures = [\"derive\"]\n\n[dependencies.chrono]\noptional = true\nversion = \"0.4.45\"\ndefault-features = false\nfeatures = [\"std\"]\n\n[dependencies.miniz_oxide]\nversion = \"0.9\"\noptional = true\n\n[dependencies.zune-jpeg]\nversion = \"0.5\"\ndefault-features = false\nfeatures = [\"std\", \"x86\", \"neon\"]\noptional = true\n\n[dependencies.zune-core]\nversion = \"0.5\"\ndefault-features = false\nfeatures = [\"std\"]\noptional = true\n\n[dependencies.jxl-oxide]\nversion = \"0.12\"\ndefault-features = false\noptional = true\n\n[dev-dependencies]\nproptest = \"1\"\n\n[dev-dependencies.sha2]\nversion = \"0.10\"\ndefault-features = false\nfeatures = [\"std\"]\n\n[dev-dependencies.jpeg-encoder]\nversion = \"0.7\"\ndefault-features = false\nfeatures = [\"std\"]\n\n[dev-dependencies.zune-jpegxl]\nversion = \"0.5\"\ndefault-features = false\nfeatures = [\"std\"]\n", - "dest": "cargo/vendor/craft-raw", + "dest": "cargo/vendor-git/6fd0ceba5f4137be1fe00e9c031f810234e38df6f60195003fed7057c96f0aa1/craft-raw", "dest-filename": "Cargo.toml" }, { "type": "inline", "contents": "{\"package\": null, \"files\": {}}", - "dest": "cargo/vendor/craft-raw", + "dest": "cargo/vendor-git/6fd0ceba5f4137be1fe00e9c031f810234e38df6f60195003fed7057c96f0aa1/craft-raw", "dest-filename": ".cargo-checksum.json" }, { "type": "shell", "commands": [ - "cp -r --reflink=auto \"flatpak-cargo/git/craft-libs-478c505/crates/tiff\" \"cargo/vendor/craft-tiff\"" + "mkdir -p \"cargo/vendor-git/cb31475a7a9d19c00f48b4c43603f2f1a464c6dce15da1d21bba4c653eeba6b2\" && cp -r --reflink=auto \"flatpak-cargo/git/craft-libs-478c505/crates/tiff\" \"cargo/vendor-git/cb31475a7a9d19c00f48b4c43603f2f1a464c6dce15da1d21bba4c653eeba6b2/craft-tiff\"" ] }, { "type": "inline", "contents": "[package]\nname = \"craft-tiff\"\ndescription = \"TIFF and BigTIFF IFD reader and writer: every field type, the Exif/GPS/Interop pointer IFDs, maker-note IFDs, strip and tile layout.\"\nversion = \"0.1.0\"\nedition = \"2024\"\nlicense = \"MIT OR Apache-2.0\"\nrust-version = \"1.95\"\nrepository = \"https://github.com/storytold/craft-libs\"\n\n[lints.rust]\nunsafe_code = \"forbid\"\nunused_workspace_dependencies = \"allow\"\n\n[lints.rust.unexpected_cfgs]\nlevel = \"warn\"\ncheck-cfg = [\"cfg(craft_pdf_unicode_fixtures)\"]\n\n[lints.clippy]\ncognitive_complexity = \"deny\"\ntoo_many_arguments = \"deny\"\nunused_workspace_dependencies = \"allow\"\nwildcard_imports = \"deny\"\ndbg_macro = \"warn\"\ntodo = \"warn\"\n\n[dependencies]\nthiserror = \"2\"\n\n[dependencies.serde]\nversion = \"1\"\nfeatures = [\"derive\"]\n\n[dev-dependencies]\nproptest = \"1\"\n", - "dest": "cargo/vendor/craft-tiff", + "dest": "cargo/vendor-git/cb31475a7a9d19c00f48b4c43603f2f1a464c6dce15da1d21bba4c653eeba6b2/craft-tiff", "dest-filename": "Cargo.toml" }, { "type": "inline", "contents": "{\"package\": null, \"files\": {}}", - "dest": "cargo/vendor/craft-tiff", + "dest": "cargo/vendor-git/cb31475a7a9d19c00f48b4c43603f2f1a464c6dce15da1d21bba4c653eeba6b2/craft-tiff", "dest-filename": ".cargo-checksum.json" }, { "type": "shell", "commands": [ - "cp -r --reflink=auto \"flatpak-cargo/git/craft-libs-94777dc/crates/tiff\" \"cargo/vendor/craft-tiff\"" + "mkdir -p \"cargo/vendor-git/6fd0ceba5f4137be1fe00e9c031f810234e38df6f60195003fed7057c96f0aa1\" && cp -r --reflink=auto \"flatpak-cargo/git/craft-libs-94777dc/crates/tiff\" \"cargo/vendor-git/6fd0ceba5f4137be1fe00e9c031f810234e38df6f60195003fed7057c96f0aa1/craft-tiff\"" ] }, { "type": "inline", "contents": "[package]\nname = \"craft-tiff\"\ndescription = \"TIFF and BigTIFF IFD reader and writer: every field type, the Exif/GPS/Interop pointer IFDs, maker-note IFDs, strip and tile layout.\"\nversion = \"0.1.0\"\nedition = \"2024\"\nlicense = \"MIT OR Apache-2.0\"\nrust-version = \"1.95\"\nrepository = \"https://github.com/storytold/craft-libs\"\n\n[lints.rust]\nunsafe_code = \"forbid\"\nunused_workspace_dependencies = \"allow\"\n\n[lints.rust.unexpected_cfgs]\nlevel = \"warn\"\ncheck-cfg = [\"cfg(craft_pdf_unicode_fixtures)\"]\n\n[lints.clippy]\ncognitive_complexity = \"deny\"\ntoo_many_arguments = \"deny\"\nunused_workspace_dependencies = \"allow\"\nwildcard_imports = \"deny\"\ndbg_macro = \"warn\"\ntodo = \"warn\"\n\n[dependencies]\nthiserror = \"2\"\n\n[dependencies.serde]\nversion = \"1\"\nfeatures = [\"derive\"]\n\n[dev-dependencies]\nproptest = \"1\"\n", - "dest": "cargo/vendor/craft-tiff", + "dest": "cargo/vendor-git/6fd0ceba5f4137be1fe00e9c031f810234e38df6f60195003fed7057c96f0aa1/craft-tiff", "dest-filename": "Cargo.toml" }, { "type": "inline", "contents": "{\"package\": null, \"files\": {}}", - "dest": "cargo/vendor/craft-tiff", + "dest": "cargo/vendor-git/6fd0ceba5f4137be1fe00e9c031f810234e38df6f60195003fed7057c96f0aa1/craft-tiff", "dest-filename": ".cargo-checksum.json" }, { "type": "shell", "commands": [ - "cp -r --reflink=auto \"flatpak-cargo/git/craft-libs-c5a1cbf/crates/ui\" \"cargo/vendor/craft-ui\"" + "mkdir -p \"cargo/vendor-git/11a22760e699d74db2deeccbdb390b343ad010ce425dcb15451f0e14e45ff298\" && cp -r --reflink=auto \"flatpak-cargo/git/craft-libs-c5a1cbf/crates/ui\" \"cargo/vendor-git/11a22760e699d74db2deeccbdb390b343ad010ce425dcb15451f0e14e45ff298/craft-ui\"" ] }, { "type": "inline", "contents": "[package]\nname = \"craft-ui\"\nversion = \"0.1.0\"\nedition = \"2024\"\nlicense = \"MIT OR Apache-2.0\"\nrepository = \"https://github.com/storytold/craft-libs\"\nrust-version = \"1.95\"\ndescription = \"Reusable egui controls and icon catalogs for Craft frontends\"\n\n[lints.rust]\nunsafe_code = \"forbid\"\n\n[lints.rust.unexpected_cfgs]\nlevel = \"warn\"\ncheck-cfg = [\"cfg(craft_pdf_unicode_fixtures)\"]\n\n[lints.clippy]\ncognitive_complexity = \"deny\"\ntoo_many_arguments = \"deny\"\nwildcard_imports = \"deny\"\ndbg_macro = \"warn\"\ntodo = \"warn\"\n\n[dependencies]\nlog = \"0.4\"\n\n[dependencies.craft-fonts-build]\npath = \"crates/fonts-build\"\n\n[dependencies.craft-i18n]\npath = \"crates/i18n\"\n\n[dependencies.egui]\nversion = \"0.37\"\ndefault-features = false\n\n[dependencies.epaint]\nversion = \"0.37\"\ndefault-features = false\n\n[dependencies.serde]\nversion = \"1\"\nfeatures = [\"derive\"]\noptional = true\n\n[dependencies.skrifa]\nversion = \"0.44\"\ndefault-features = false\nfeatures = [\"std\"]\n\n[target.\"cfg(not(target_arch = \\\"wasm32\\\"))\".dependencies.egui_kittest]\nversion = \"0.37\"\nfeatures = [\"snapshot\", \"wgpu\"]\noptional = true\n\n[target.\"cfg(not(target_arch = \\\"wasm32\\\"))\".dependencies.fontique]\nversion = \"0.11.1\"\ndefault-features = false\nfeatures = [\"system\", \"fontconfig-dlopen\"]\noptional = true\n\n[target.\"cfg(not(target_arch = \\\"wasm32\\\"))\".dependencies.unicode-script]\nversion = \"0.5.8\"\noptional = true\n\n[target.\"cfg(not(target_arch = \\\"wasm32\\\"))\".dev-dependencies.egui_kittest]\nversion = \"0.37\"\nfeatures = [\"wgpu\"]\n\n[target.\"cfg(not(target_arch = \\\"wasm32\\\"))\".dev-dependencies.eframe]\nversion = \"0.37\"\ndefault-features = false\nfeatures = [\"wgpu\", \"x11\", \"default_fonts\"]\n\n[target.\"cfg(target_arch = \\\"wasm32\\\")\".dependencies]\njs-sys = \"0.3\"\nwasm-bindgen = \"0.2\"\nwasm-bindgen-futures = \"0.4\"\n\n[target.\"cfg(target_arch = \\\"wasm32\\\")\".dependencies.web-sys]\nversion = \"0.3\"\nfeatures = [\"Window\", \"RequestInit\", \"Response\", \"console\"]\n\n[target.\"cfg(target_arch = \\\"wasm32\\\")\".dev-dependencies]\njs-sys = \"0.3\"\nwasm-bindgen = \"0.2\"\nwasm-bindgen-futures = \"0.4\"\nwasm-bindgen-test = \"0.3\"\n\n[target.\"cfg(target_arch = \\\"wasm32\\\")\".dev-dependencies.web-sys]\nversion = \"0.3\"\nfeatures = [\"Window\", \"Response\"]\n\n[target.\"cfg(target_os = \\\"macos\\\")\".dependencies]\nobjc2 = \"0.6\"\n\n[target.\"cfg(target_os = \\\"macos\\\")\".dependencies.objc2-app-kit]\nversion = \"0.3\"\ndefault-features = false\nfeatures = [\"std\", \"objc2-core-foundation\", \"NSApplication\", \"NSEvent\", \"NSResponder\", \"NSScreen\", \"NSWindow\"]\n\n[target.\"cfg(target_os = \\\"macos\\\")\".dependencies.objc2-foundation]\nversion = \"0.3\"\ndefault-features = false\nfeatures = [\"std\", \"NSArray\", \"NSEnumerator\", \"NSString\"]\n\n[features]\ndefault = []\nserde = [\"dep:serde\"]\nnative-windows = []\ncolor_fonts = [\"epaint/color_fonts\"]\nsystem_fonts = [\"dep:fontique\", \"dep:unicode-script\"]\ntesting = []\nscreen-testing = [\"dep:egui_kittest\"]\n\n[dev-dependencies]\nserde_json = \"1\"\n\n[dev-dependencies.egui]\nfeatures = [\"default_fonts\", \"serde\"]\nversion = \"0.37\"\ndefault-features = false\n\n[dev-dependencies.egui_extras]\nversion = \"0.37\"\ndefault-features = false\nfeatures = [\"svg\"]\n\n[dev-dependencies.image]\nversion = \"0.25\"\ndefault-features = false\nfeatures = [\"png\"]\n\n[[example]]\nname = \"docking_native\"\nrequired-features = [\"native-windows\"]\n\n[[test]]\nname = \"screens\"\nrequired-features = [\"screen-testing\"]\n", - "dest": "cargo/vendor/craft-ui", + "dest": "cargo/vendor-git/11a22760e699d74db2deeccbdb390b343ad010ce425dcb15451f0e14e45ff298/craft-ui", "dest-filename": "Cargo.toml" }, { "type": "inline", "contents": "{\"package\": null, \"files\": {}}", - "dest": "cargo/vendor/craft-ui", + "dest": "cargo/vendor-git/11a22760e699d74db2deeccbdb390b343ad010ce425dcb15451f0e14e45ff298/craft-ui", "dest-filename": ".cargo-checksum.json" }, { "type": "shell", "commands": [ - "cp -r --reflink=auto \"flatpak-cargo/git/craft-libs-6e03f65/crates/update\" \"cargo/vendor/craft-update\"" + "mkdir -p \"cargo/vendor-git/4765c8f813a43ec0005270c9f4b16bff2eb2e09aeb15e4230bcd10e5bba1c4ba\" && cp -r --reflink=auto \"flatpak-cargo/git/craft-libs-6e03f65/crates/update\" \"cargo/vendor-git/4765c8f813a43ec0005270c9f4b16bff2eb2e09aeb15e4230bcd10e5bba1c4ba/craft-update\"" ] }, { "type": "inline", "contents": "[package]\nname = \"craft-update\"\ndescription = \"Release checking, downloading, installing and self-updating for the Craft App Suite and ArtCraft Launcher\"\nversion = \"0.1.0\"\nedition = \"2024\"\nlicense = \"MIT OR Apache-2.0\"\nrust-version = \"1.95\"\nrepository = \"https://github.com/storytold/craft-libs\"\n\n[lints.rust]\nunsafe_code = \"forbid\"\n\n[lints.rust.unexpected_cfgs]\nlevel = \"warn\"\ncheck-cfg = [\"cfg(craft_pdf_unicode_fixtures)\"]\n\n[lints.clippy]\ncognitive_complexity = \"deny\"\ntoo_many_arguments = \"deny\"\nwildcard_imports = \"deny\"\ndbg_macro = \"warn\"\ntodo = \"warn\"\n\n[features]\ndefault = []\negui = [\"dep:egui\", \"dep:image\"]\nlocal-mirror = []\nsnapshot = [\"egui\", \"egui_kittest/wgpu\"]\n\n[dependencies]\nserde_json = \"1\"\nlog = \"0.4\"\ngetrandom = \"0.3\"\ntempfile = \"3\"\nsha2 = \"0.10\"\n\n[dependencies.egui]\noptional = true\nversion = \"0.37\"\ndefault-features = false\n\n[dependencies.image]\nversion = \"0.25\"\ndefault-features = false\nfeatures = [\"png\"]\noptional = true\n\n[dependencies.serde]\nversion = \"1\"\nfeatures = [\"derive\"]\n\n[dependencies.ureq]\nversion = \"3.4\"\ndefault-features = false\nfeatures = [\"rustls-no-provider\", \"_ring\", \"gzip\", \"platform-verifier\"]\n\n[dependencies.chrono]\nversion = \"0.4.45\"\ndefault-features = false\nfeatures = [\"std\"]\n\n[dependencies.semver]\nversion = \"1\"\nfeatures = [\"serde\"]\n\n[dev-dependencies]\nflate2 = \"1\"\negui_kittest = \"0.37\"\nepaint_default_fonts = \"0.37\"\n\n[target.\"cfg(unix)\".dependencies]\nflate2 = \"1\"\n\n[target.\"cfg(unix)\".dependencies.tar]\nversion = \"0.4\"\ndefault-features = false\n\n[target.\"cfg(target_os = \\\"macos\\\")\".dependencies]\nplist = \"1\"\n\n[target.\"cfg(any(target_os = \\\"macos\\\", target_os = \\\"linux\\\"))\".dependencies.rustix]\nversion = \"1.1\"\ndefault-features = false\nfeatures = [\"std\", \"fs\", \"process\"]\n\n[target.\"cfg(target_os = \\\"windows\\\")\".dependencies]\nwinreg = \"0.55\"\ndunce = \"1\"\nflate2 = \"1\"\nverifysign = \"1\"\n\n[target.\"cfg(target_os = \\\"windows\\\")\".dependencies.zip]\nversion = \"9\"\ndefault-features = false\nfeatures = [\"deflate-flate2\"]\n\n[target.\"cfg(target_os = \\\"windows\\\")\".dependencies.winsafe]\nversion = \"0.0.29\"\nfeatures = [\"advapi\", \"kernel\", \"shell\", \"version\"]\n", - "dest": "cargo/vendor/craft-update", + "dest": "cargo/vendor-git/4765c8f813a43ec0005270c9f4b16bff2eb2e09aeb15e4230bcd10e5bba1c4ba/craft-update", "dest-filename": "Cargo.toml" }, { "type": "inline", "contents": "{\"package\": null, \"files\": {}}", - "dest": "cargo/vendor/craft-update", + "dest": "cargo/vendor-git/4765c8f813a43ec0005270c9f4b16bff2eb2e09aeb15e4230bcd10e5bba1c4ba/craft-update", "dest-filename": ".cargo-checksum.json" }, { "type": "shell", "commands": [ - "cp -r --reflink=auto \"flatpak-cargo/git/craft-libs-c5a1cbf/crates/window\" \"cargo/vendor/craft-window\"" + "mkdir -p \"cargo/vendor-git/11a22760e699d74db2deeccbdb390b343ad010ce425dcb15451f0e14e45ff298\" && cp -r --reflink=auto \"flatpak-cargo/git/craft-libs-c5a1cbf/crates/window\" \"cargo/vendor-git/11a22760e699d74db2deeccbdb390b343ad010ce425dcb15451f0e14e45ff298/craft-window\"" ] }, { "type": "inline", "contents": "[package]\nname = \"craft-window\"\ndescription = \"Decide who draws the window frame (the desktop or the app) so every Craft app gets the same titlebar and borders per desktop, make an app-drawn strip act as the title bar, and keep the window list, cascade placement and Window menu for apps with one window per document.\"\nversion = \"0.1.0\"\nedition = \"2024\"\nlicense = \"MIT OR Apache-2.0\"\nrust-version = \"1.95\"\nrepository = \"https://github.com/storytold/craft-libs\"\n\n[features]\negui = [\"dep:egui\", \"dep:objc2\", \"dep:objc2-app-kit\"]\n\n[dependencies.egui]\noptional = true\nversion = \"0.37\"\ndefault-features = false\n\n[target.\"cfg(any(target_os = \\\"linux\\\", target_os = \\\"freebsd\\\", target_os = \\\"openbsd\\\", target_os = \\\"netbsd\\\"))\".dependencies]\nwayland-client = \"0.31\"\n\n[target.\"cfg(target_os = \\\"macos\\\")\".dependencies.objc2]\nversion = \"0.6.4\"\ndefault-features = false\nfeatures = [\"std\"]\noptional = true\n\n[target.\"cfg(target_os = \\\"macos\\\")\".dependencies.objc2-app-kit]\nversion = \"0.3.2\"\ndefault-features = false\nfeatures = [\"std\", \"NSApplication\", \"NSButton\", \"NSControl\", \"NSResponder\", \"NSView\", \"NSWindow\"]\noptional = true\n\n[lints.rust]\nunsafe_code = \"forbid\"\n\n[lints.rust.unexpected_cfgs]\nlevel = \"warn\"\ncheck-cfg = [\"cfg(craft_pdf_unicode_fixtures)\"]\n\n[lints.clippy]\ncognitive_complexity = \"deny\"\ntoo_many_arguments = \"deny\"\nwildcard_imports = \"deny\"\ndbg_macro = \"warn\"\ntodo = \"warn\"\n", - "dest": "cargo/vendor/craft-window", + "dest": "cargo/vendor-git/11a22760e699d74db2deeccbdb390b343ad010ce425dcb15451f0e14e45ff298/craft-window", "dest-filename": "Cargo.toml" }, { "type": "inline", "contents": "{\"package\": null, \"files\": {}}", - "dest": "cargo/vendor/craft-window", + "dest": "cargo/vendor-git/11a22760e699d74db2deeccbdb390b343ad010ce425dcb15451f0e14e45ff298/craft-window", "dest-filename": ".cargo-checksum.json" }, { "type": "shell", "commands": [ - "cp -r --reflink=auto \"flatpak-cargo/git/craft-libs-f0f4758/crates/xml\" \"cargo/vendor/craft-xml\"" + "mkdir -p \"cargo/vendor-git/bc00bd22a20692df38f25839a8568cd55b90e379a41719721bbc0f04fe5e29f7\" && cp -r --reflink=auto \"flatpak-cargo/git/craft-libs-f0f4758/crates/xml\" \"cargo/vendor-git/bc00bd22a20692df38f25839a8568cd55b90e379a41719721bbc0f04fe5e29f7/craft-xml\"" ] }, { "type": "inline", "contents": "[package]\nname = \"craft-xml\"\ndescription = \"Bounded XML for hostile input: an owned element tree, streaming of repeated elements, a pull reader, escaping and a writer. No DTDs, no entity expansion.\"\nversion = \"0.1.0\"\nedition = \"2024\"\nlicense = \"MIT OR Apache-2.0\"\nrust-version = \"1.95\"\nrepository = \"https://github.com/storytold/craft-libs\"\n\n[lints.rust]\nunsafe_code = \"forbid\"\nunused_workspace_dependencies = \"allow\"\n\n[lints.rust.unexpected_cfgs]\nlevel = \"warn\"\ncheck-cfg = [\"cfg(craft_pdf_unicode_fixtures)\"]\n\n[lints.clippy]\ncognitive_complexity = \"deny\"\ntoo_many_arguments = \"deny\"\nunused_workspace_dependencies = \"allow\"\nwildcard_imports = \"deny\"\ndbg_macro = \"warn\"\ntodo = \"warn\"\n\n[dependencies]\nthiserror = \"2\"\n\n[dependencies.quick-xml]\nversion = \"0.41\"\ndefault-features = false\n", - "dest": "cargo/vendor/craft-xml", + "dest": "cargo/vendor-git/bc00bd22a20692df38f25839a8568cd55b90e379a41719721bbc0f04fe5e29f7/craft-xml", "dest-filename": "Cargo.toml" }, { "type": "inline", "contents": "{\"package\": null, \"files\": {}}", - "dest": "cargo/vendor/craft-xml", + "dest": "cargo/vendor-git/bc00bd22a20692df38f25839a8568cd55b90e379a41719721bbc0f04fe5e29f7/craft-xml", "dest-filename": ".cargo-checksum.json" }, { @@ -2379,19 +2379,19 @@ { "type": "shell", "commands": [ - "cp -r --reflink=auto \"flatpak-cargo/git/egui-6d518fc/crates/ecolor\" \"cargo/vendor/ecolor\"" + "mkdir -p \"cargo/vendor-git/11e349eb0774eb3ab9192b38c47d748bf18abba91a0e3952d8f196513da96ee6\" && cp -r --reflink=auto \"flatpak-cargo/git/egui-6d518fc/crates/ecolor\" \"cargo/vendor-git/11e349eb0774eb3ab9192b38c47d748bf18abba91a0e3952d8f196513da96ee6/ecolor\"" ] }, { "type": "inline", "contents": "[package]\nname = \"ecolor\"\nversion = \"0.37.0\"\nauthors = [\"Emil Ernerfeldt <emil.ernerfeldt@gmail.com>\", \"Andreas Reich <reichandreas@gmx.de>\"]\ndescription = \"Color structs and color conversion utilities\"\nedition = \"2024\"\nrust-version = \"1.95\"\nhomepage = \"https://github.com/emilk/egui\"\nlicense = \"MIT OR Apache-2.0\"\nreadme = \"README.md\"\nrepository = \"https://github.com/emilk/egui\"\ncategories = [\"mathematics\", \"encoding\"]\nkeywords = [\"gui\", \"color\", \"conversion\", \"gamedev\", \"images\"]\ninclude = [\"../../LICENSE-APACHE\", \"../../LICENSE-MIT\", \"**/*.rs\", \"Cargo.toml\"]\n\n[package.metadata.docs.rs]\nall-features = true\nrustdoc-args = [\"--generate-link-to-definition\"]\n\n[lints.rust]\nunsafe_code = \"deny\"\ntrivial_numeric_casts = \"warn\"\nunused_import_braces = \"warn\"\nunused_lifetimes = \"warn\"\ntrivial_casts = \"allow\"\nunused_qualifications = \"allow\"\n\n[lints.rust.future_incompatible]\nlevel = \"warn\"\npriority = -1\n\n[lints.rust.nonstandard_style]\nlevel = \"warn\"\npriority = -1\n\n[lints.rust.rust_2018_idioms]\nlevel = \"warn\"\npriority = -1\n\n[lints.rust.unexpected_cfgs]\nlevel = \"warn\"\ncheck-cfg = [\"cfg(web_sys_unstable_apis)\"]\n\n[lints.rustdoc]\nall = \"warn\"\n\n[lints.clippy]\nallow_attributes = \"warn\"\nas_ptr_cast_mut = \"warn\"\nbranches_sharing_code = \"warn\"\nclear_with_drain = \"warn\"\nclone_on_ref_ptr = \"warn\"\ncoerce_container_to_any = \"warn\"\ndbg_macro = \"warn\"\ndebug_assert_with_mut_call = \"warn\"\ndefault_union_representation = \"warn\"\nderive_partial_eq_without_eq = \"warn\"\ndisallowed_script_idents = \"warn\"\ndoc_include_without_cfg = \"warn\"\nempty_enum_variants_with_brackets = \"warn\"\nequatable_if_let = \"warn\"\nexit = \"warn\"\nfallible_impl_from = \"warn\"\nfloat_cmp_const = \"warn\"\nfn_to_numeric_cast_any = \"warn\"\nget_unwrap = \"warn\"\nimprecise_flops = \"warn\"\ninfinite_loop = \"warn\"\niter_on_empty_collections = \"warn\"\niter_on_single_items = \"warn\"\niter_over_hash_type = \"warn\"\nlarge_include_file = \"warn\"\nlarge_stack_frames = \"warn\"\nliteral_string_with_formatting_args = \"warn\"\nlossy_float_literal = \"warn\"\nmap_err_ignore = \"warn\"\nmem_forget = \"warn\"\nmissing_assert_message = \"warn\"\nmutex_integer = \"warn\"\nneedless_pass_by_ref_mut = \"warn\"\nneedless_type_cast = \"warn\"\nnon_zero_suggestions = \"warn\"\nnonstandard_macro_braces = \"warn\"\nor_fun_call = \"warn\"\npath_buf_push_overwrite = \"warn\"\npathbuf_init_then_push = \"warn\"\nprecedence_bits = \"warn\"\nprint_stderr = \"warn\"\nprint_stdout = \"warn\"\npub_without_shorthand = \"warn\"\nrc_mutex = \"warn\"\nredundant_type_annotations = \"warn\"\nref_patterns = \"warn\"\nrest_pat_in_fully_bound_structs = \"warn\"\nreturn_and_then = \"warn\"\nset_contains_or_insert = \"warn\"\nsingle_option_map = \"warn\"\nstd_instead_of_core = \"warn\"\nstr_to_string = \"warn\"\nstring_add = \"warn\"\nstring_lit_as_bytes = \"warn\"\nstring_lit_chars_any = \"warn\"\nsuspicious_xor_used_as_pow = \"warn\"\ntodo = \"warn\"\ntoo_long_first_doc_paragraph = \"warn\"\ntrailing_empty_array = \"warn\"\ntrait_duplication_in_bounds = \"warn\"\ntuple_array_conversions = \"warn\"\nundocumented_unsafe_blocks = \"warn\"\nunimplemented = \"warn\"\nuninhabited_references = \"warn\"\nunnecessary_safety_comment = \"warn\"\nunnecessary_safety_doc = \"warn\"\nunnecessary_self_imports = \"warn\"\nunnecessary_struct_initialization = \"warn\"\nunused_peekable = \"warn\"\nunused_rounding = \"warn\"\nunused_trait_names = \"warn\"\nunwrap_used = \"warn\"\nuse_self = \"warn\"\nuseless_let_if_seq = \"warn\"\nverbose_file_reads = \"warn\"\ncast_lossless = \"allow\"\ncast_possible_truncation = \"allow\"\ncast_possible_wrap = \"allow\"\ncast_precision_loss = \"allow\"\ncast_sign_loss = \"allow\"\ncomparison_chain = \"allow\"\ndefault_trait_access = \"allow\"\nfloat_cmp = \"allow\"\ninline_always = \"allow\"\nitems_after_statements = \"allow\"\nmany_single_char_names = \"allow\"\nmissing_panics_doc = \"allow\"\nmust_use_candidate = \"allow\"\nredundant_closure_for_method_calls = \"allow\"\nreturn_self_not_must_use = \"allow\"\nshould_panic_without_expect = \"allow\"\nsimilar_names = \"allow\"\nstruct_excessive_bools = \"allow\"\nstruct_field_names = \"allow\"\ntoo_many_lines = \"allow\"\ntrivially_copy_pass_by_ref = \"allow\"\nunreadable_literal = \"allow\"\nused_underscore_binding = \"allow\"\nassigning_clones = \"allow\"\nmanual_range_contains = \"allow\"\nmap_unwrap_or = \"allow\"\nmultiple_crate_versions = \"allow\"\nwildcard_imports = \"allow\"\nlet_underscore_must_use = \"allow\"\nlet_underscore_untyped = \"allow\"\nself_named_module_files = \"allow\"\nsignificant_drop_tightening = \"allow\"\n\n[lints.clippy.all]\nlevel = \"warn\"\npriority = -1\n\n[lints.clippy.cargo]\nlevel = \"warn\"\npriority = -1\n\n[lints.clippy.pedantic]\nlevel = \"warn\"\npriority = -1\n\n[lib]\n\n[features]\ndefault = []\n\n[dependencies.emath]\nversion = \"0.37.0\"\npath = \"crates/emath\"\ndefault-features = false\n\n[dependencies.bytemuck]\noptional = true\nfeatures = [\"derive\"]\nversion = \"1.25\"\n\n[dependencies.cint]\noptional = true\nversion = \"0.3.1\"\n\n[dependencies.color-hex]\noptional = true\nversion = \"0.2.0\"\n\n[dependencies.document-features]\noptional = true\nversion = \"0.2.12\"\n\n[dependencies.serde]\noptional = true\nversion = \"1.0\"\nfeatures = [\"derive\"]\n", - "dest": "cargo/vendor/ecolor", + "dest": "cargo/vendor-git/11e349eb0774eb3ab9192b38c47d748bf18abba91a0e3952d8f196513da96ee6/ecolor", "dest-filename": "Cargo.toml" }, { "type": "inline", "contents": "{\"package\": null, \"files\": {}}", - "dest": "cargo/vendor/ecolor", + "dest": "cargo/vendor-git/11e349eb0774eb3ab9192b38c47d748bf18abba91a0e3952d8f196513da96ee6/ecolor", "dest-filename": ".cargo-checksum.json" }, { @@ -2423,127 +2423,127 @@ { "type": "shell", "commands": [ - "cp -r --reflink=auto \"flatpak-cargo/git/egui-6d518fc/crates/eframe\" \"cargo/vendor/eframe\"" + "mkdir -p \"cargo/vendor-git/11e349eb0774eb3ab9192b38c47d748bf18abba91a0e3952d8f196513da96ee6\" && cp -r --reflink=auto \"flatpak-cargo/git/egui-6d518fc/crates/eframe\" \"cargo/vendor-git/11e349eb0774eb3ab9192b38c47d748bf18abba91a0e3952d8f196513da96ee6/eframe\"" ] }, { "type": "inline", "contents": "[package]\nname = \"eframe\"\nversion = \"0.37.0\"\nauthors = [\"Emil Ernerfeldt <emil.ernerfeldt@gmail.com>\"]\ndescription = \"egui framework - write GUI apps that compiles to web and/or natively\"\nedition = \"2024\"\nrust-version = \"1.95\"\nhomepage = \"https://github.com/emilk/egui/tree/main/crates/eframe\"\nlicense = \"MIT OR Apache-2.0\"\nreadme = \"README.md\"\nrepository = \"https://github.com/emilk/egui/tree/main/crates/eframe\"\ncategories = [\"gui\", \"game-development\"]\nkeywords = [\"egui\", \"gui\", \"gamedev\"]\ninclude = [\"../../LICENSE-APACHE\", \"../../LICENSE-MIT\", \"**/*.rs\", \"Cargo.toml\", \"data/icon.png\"]\n\n[package.metadata.docs.rs]\nall-features = true\ntargets = [\"x86_64-unknown-linux-gnu\", \"wasm32-unknown-unknown\"]\nrustdoc-args = [\"--generate-link-to-definition\"]\n\n[lints.rust]\nunsafe_code = \"deny\"\ntrivial_numeric_casts = \"warn\"\nunused_import_braces = \"warn\"\nunused_lifetimes = \"warn\"\ntrivial_casts = \"allow\"\nunused_qualifications = \"allow\"\n\n[lints.rust.future_incompatible]\nlevel = \"warn\"\npriority = -1\n\n[lints.rust.nonstandard_style]\nlevel = \"warn\"\npriority = -1\n\n[lints.rust.rust_2018_idioms]\nlevel = \"warn\"\npriority = -1\n\n[lints.rust.unexpected_cfgs]\nlevel = \"warn\"\ncheck-cfg = [\"cfg(web_sys_unstable_apis)\"]\n\n[lints.rustdoc]\nall = \"warn\"\n\n[lints.clippy]\nallow_attributes = \"warn\"\nas_ptr_cast_mut = \"warn\"\nbranches_sharing_code = \"warn\"\nclear_with_drain = \"warn\"\nclone_on_ref_ptr = \"warn\"\ncoerce_container_to_any = \"warn\"\ndbg_macro = \"warn\"\ndebug_assert_with_mut_call = \"warn\"\ndefault_union_representation = \"warn\"\nderive_partial_eq_without_eq = \"warn\"\ndisallowed_script_idents = \"warn\"\ndoc_include_without_cfg = \"warn\"\nempty_enum_variants_with_brackets = \"warn\"\nequatable_if_let = \"warn\"\nexit = \"warn\"\nfallible_impl_from = \"warn\"\nfloat_cmp_const = \"warn\"\nfn_to_numeric_cast_any = \"warn\"\nget_unwrap = \"warn\"\nimprecise_flops = \"warn\"\ninfinite_loop = \"warn\"\niter_on_empty_collections = \"warn\"\niter_on_single_items = \"warn\"\niter_over_hash_type = \"warn\"\nlarge_include_file = \"warn\"\nlarge_stack_frames = \"warn\"\nliteral_string_with_formatting_args = \"warn\"\nlossy_float_literal = \"warn\"\nmap_err_ignore = \"warn\"\nmem_forget = \"warn\"\nmissing_assert_message = \"warn\"\nmutex_integer = \"warn\"\nneedless_pass_by_ref_mut = \"warn\"\nneedless_type_cast = \"warn\"\nnon_zero_suggestions = \"warn\"\nnonstandard_macro_braces = \"warn\"\nor_fun_call = \"warn\"\npath_buf_push_overwrite = \"warn\"\npathbuf_init_then_push = \"warn\"\nprecedence_bits = \"warn\"\nprint_stderr = \"warn\"\nprint_stdout = \"warn\"\npub_without_shorthand = \"warn\"\nrc_mutex = \"warn\"\nredundant_type_annotations = \"warn\"\nref_patterns = \"warn\"\nrest_pat_in_fully_bound_structs = \"warn\"\nreturn_and_then = \"warn\"\nset_contains_or_insert = \"warn\"\nsingle_option_map = \"warn\"\nstd_instead_of_core = \"warn\"\nstr_to_string = \"warn\"\nstring_add = \"warn\"\nstring_lit_as_bytes = \"warn\"\nstring_lit_chars_any = \"warn\"\nsuspicious_xor_used_as_pow = \"warn\"\ntodo = \"warn\"\ntoo_long_first_doc_paragraph = \"warn\"\ntrailing_empty_array = \"warn\"\ntrait_duplication_in_bounds = \"warn\"\ntuple_array_conversions = \"warn\"\nundocumented_unsafe_blocks = \"warn\"\nunimplemented = \"warn\"\nuninhabited_references = \"warn\"\nunnecessary_safety_comment = \"warn\"\nunnecessary_safety_doc = \"warn\"\nunnecessary_self_imports = \"warn\"\nunnecessary_struct_initialization = \"warn\"\nunused_peekable = \"warn\"\nunused_rounding = \"warn\"\nunused_trait_names = \"warn\"\nunwrap_used = \"warn\"\nuse_self = \"warn\"\nuseless_let_if_seq = \"warn\"\nverbose_file_reads = \"warn\"\ncast_lossless = \"allow\"\ncast_possible_truncation = \"allow\"\ncast_possible_wrap = \"allow\"\ncast_precision_loss = \"allow\"\ncast_sign_loss = \"allow\"\ncomparison_chain = \"allow\"\ndefault_trait_access = \"allow\"\nfloat_cmp = \"allow\"\ninline_always = \"allow\"\nitems_after_statements = \"allow\"\nmany_single_char_names = \"allow\"\nmissing_panics_doc = \"allow\"\nmust_use_candidate = \"allow\"\nredundant_closure_for_method_calls = \"allow\"\nreturn_self_not_must_use = \"allow\"\nshould_panic_without_expect = \"allow\"\nsimilar_names = \"allow\"\nstruct_excessive_bools = \"allow\"\nstruct_field_names = \"allow\"\ntoo_many_lines = \"allow\"\ntrivially_copy_pass_by_ref = \"allow\"\nunreadable_literal = \"allow\"\nused_underscore_binding = \"allow\"\nassigning_clones = \"allow\"\nmanual_range_contains = \"allow\"\nmap_unwrap_or = \"allow\"\nmultiple_crate_versions = \"allow\"\nwildcard_imports = \"allow\"\nlet_underscore_must_use = \"allow\"\nlet_underscore_untyped = \"allow\"\nself_named_module_files = \"allow\"\nsignificant_drop_tightening = \"allow\"\n\n[lints.clippy.all]\nlevel = \"warn\"\npriority = -1\n\n[lints.clippy.cargo]\nlevel = \"warn\"\npriority = -1\n\n[lints.clippy.pedantic]\nlevel = \"warn\"\npriority = -1\n\n[lib]\n\n[features]\ndefault = [\"accesskit\", \"clipboard\", \"default_fonts\", \"links\", \"system_fonts\", \"wayland\", \"web_screen_reader\", \"wgpu\", \"winit/default\", \"x11\"]\naccesskit = [\"egui-winit/accesskit\"]\nandroid-game-activity = [\"egui-winit/android-game-activity\"]\nandroid-native-activity = [\"egui-winit/android-native-activity\"]\ndefault_fonts = [\"egui/default_fonts\"]\nexperimental = [\"egui/experimental\"]\nglow = [\"dep:egui_glow\", \"dep:glow\", \"dep:glutin-winit\", \"dep:glutin\"]\npersistence = [\"egui-winit/serde\", \"egui/persistence\", \"ron\", \"serde\"]\nwayland = [\"egui-winit/wayland\", \"egui-wgpu?/wayland\", \"egui_glow?/wayland\", \"glutin?/wayland\", \"glutin-winit?/wayland\"]\nsystem_fonts = [\"dep:egui_system_font_provider\"]\nweb_screen_reader = [\"web-sys/SpeechSynthesis\", \"web-sys/SpeechSynthesisUtterance\"]\nwgpu = [\"wgpu_no_default_features\", \"egui-wgpu/default\"]\nwgpu_no_default_features = [\"dep:wgpu\", \"dep:egui-wgpu\", \"dep:pollster\"]\nx11 = [\"egui-winit/x11\", \"egui-wgpu?/x11\", \"egui_glow?/x11\", \"glutin?/x11\", \"glutin?/glx\", \"glutin-winit?/x11\", \"glutin-winit?/glx\"]\n__screenshot = []\ninspection = [\"dep:egui_inspection\", \"accesskit\"]\nlinks = [\"egui-winit/links\"]\nclipboard = [\"egui-winit/clipboard\", \"egui-winit/clipboard-image\"]\n\n[dependencies]\ndocument-features = \"0.2.12\"\nparking_lot = \"0.12.5\"\nraw-window-handle = \"0.6.2\"\nstatic_assertions = \"1.1\"\nweb-time = \"1.1\"\n\n[dependencies.egui]\ndefault-features = false\nfeatures = [\"bytemuck\"]\nversion = \"0.37.0\"\npath = \"crates/egui\"\n\n[dependencies.ahash]\nversion = \"0.8.12\"\ndefault-features = false\nfeatures = [\"no-rng\", \"std\"]\n\n[dependencies.log]\nversion = \"0.4.34\"\nfeatures = [\"std\"]\n\n[dependencies.profiling]\nversion = \"1.0\"\ndefault-features = false\n\n[dependencies.egui_glow]\noptional = true\ndefault-features = false\nversion = \"0.37.0\"\npath = \"crates/egui_glow\"\n\n[dependencies.egui_inspection]\noptional = true\nfeatures = [\"plugin\"]\nversion = \"0.37.0\"\npath = \"crates/egui_inspection\"\ndefault-features = false\n\n[dependencies.glow]\noptional = true\nversion = \"0.17.0\"\n\n[dependencies.ron]\noptional = true\nfeatures = [\"integer128\"]\nversion = \"0.12.2\"\n\n[dependencies.serde]\noptional = true\nversion = \"1.0\"\nfeatures = [\"derive\"]\n\n[target.\"cfg(not(target_arch = \\\"wasm32\\\"))\".dependencies.egui-winit]\ndefault-features = false\nversion = \"0.37.0\"\npath = \"crates/egui-winit\"\n\n[target.\"cfg(not(target_arch = \\\"wasm32\\\"))\".dependencies.image]\nfeatures = [\"png\"]\nversion = \"0.25.10\"\ndefault-features = false\n\n[target.\"cfg(not(target_arch = \\\"wasm32\\\"))\".dependencies.winit]\ndefault-features = false\nfeatures = [\"rwh_06\"]\nversion = \"0.30.13\"\n\n[target.\"cfg(not(target_arch = \\\"wasm32\\\"))\".dependencies.egui_system_font_provider]\noptional = true\nversion = \"0.37.0\"\npath = \"crates/egui_system_font_provider\"\ndefault-features = false\n\n[target.\"cfg(not(target_arch = \\\"wasm32\\\"))\".dependencies.egui-wgpu]\noptional = true\nfeatures = [\"winit\", \"capture\"]\nversion = \"0.37.0\"\npath = \"crates/egui-wgpu\"\ndefault-features = false\n\n[target.\"cfg(not(target_arch = \\\"wasm32\\\"))\".dependencies.pollster]\noptional = true\nversion = \"1.0\"\n\n[target.\"cfg(not(target_arch = \\\"wasm32\\\"))\".dependencies.glutin]\noptional = true\ndefault-features = false\nfeatures = [\"egl\", \"wgl\"]\nversion = \"0.32.3\"\n\n[target.\"cfg(not(target_arch = \\\"wasm32\\\"))\".dependencies.glutin-winit]\noptional = true\ndefault-features = false\nfeatures = [\"egl\", \"wgl\"]\nversion = \"0.5.0\"\n\n[target.\"cfg(not(target_arch = \\\"wasm32\\\"))\".dev-dependencies]\ndirectories = \"6.0\"\n\n[target.\"cfg(any(target_os = \\\"macos\\\"))\".dependencies]\nobjc2 = \"0.6.4\"\n\n[target.\"cfg(any(target_os = \\\"macos\\\"))\".dependencies.objc2-foundation]\ndefault-features = false\nfeatures = [\"std\", \"block2\", \"NSData\", \"NSString\"]\nversion = \"0.3.2\"\n\n[target.\"cfg(any(target_os = \\\"macos\\\"))\".dependencies.objc2-app-kit]\ndefault-features = false\nfeatures = [\"std\", \"NSApplication\", \"NSBitmapImageRep\", \"NSButton\", \"NSControl\", \"NSGraphics\", \"NSImage\", \"NSImageRep\", \"NSMenu\", \"NSMenuItem\", \"NSResponder\", \"NSView\", \"NSWindow\"]\nversion = \"0.3.2\"\n\n[target.\"cfg(any(target_os = \\\"windows\\\"))\".dependencies.windows-sys]\nfeatures = [\"Win32_Foundation\", \"Win32_System_Com\", \"Win32_UI_Input_KeyboardAndMouse\", \"Win32_UI_Shell\", \"Win32_UI_WindowsAndMessaging\"]\nversion = \"0.61.2\"\n\n[target.\"cfg(target_arch = \\\"wasm32\\\")\".dependencies]\nbytemuck = \"1.25\"\njs-sys = \"0.3.103\"\npercent-encoding = \"2.3\"\nsend_wrapper = \"0.6\"\nwasm-bindgen = \"0.2.126\"\n\n[target.\"cfg(target_arch = \\\"wasm32\\\")\".dependencies.egui]\nfeatures = [\"web_file\"]\nversion = \"0.37.0\"\npath = \"crates/egui\"\ndefault-features = false\n\n[target.\"cfg(target_arch = \\\"wasm32\\\")\".dependencies.image]\nfeatures = [\"png\"]\nversion = \"0.25.10\"\ndefault-features = false\n\n[target.\"cfg(target_arch = \\\"wasm32\\\")\".dependencies.web-sys]\nfeatures = [\"AddEventListenerOptions\", \"BinaryType\", \"Blob\", \"BlobPropertyBag\", \"Clipboard\", \"ClipboardEvent\", \"ClipboardItem\", \"CanvasRenderingContext2d\", \"CompositionEvent\", \"console\", \"CssStyleDeclaration\", \"DataTransfer\", \"DataTransferItem\", \"DataTransferItemList\", \"Document\", \"DomRect\", \"DragEvent\", \"Element\", \"Event\", \"EventListener\", \"EventTarget\", \"ExtSRgb\", \"File\", \"FileList\", \"FocusEvent\", \"FocusOptions\", \"HtmlCanvasElement\", \"HtmlElement\", \"HtmlInputElement\", \"InputEvent\", \"ImageData\", \"KeyboardEvent\", \"Location\", \"MediaQueryList\", \"MediaQueryListEvent\", \"MouseEvent\", \"Navigator\", \"Node\", \"NodeList\", \"Performance\", \"ResizeObserver\", \"ResizeObserverBoxOptions\", \"ResizeObserverEntry\", \"ResizeObserverOptions\", \"ResizeObserverSize\", \"ShadowRoot\", \"Storage\", \"TextMetrics\", \"Touch\", \"TouchEvent\", \"PointerEvent\", \"TouchList\", \"WebGl2RenderingContext\", \"WebglDebugRendererInfo\", \"WebGlRenderingContext\", \"WheelEvent\", \"Window\"]\nversion = \"0.3.103\"\n\n[target.\"cfg(target_arch = \\\"wasm32\\\")\".dependencies.egui-wgpu]\noptional = true\nfeatures = [\"capture\"]\nversion = \"0.37.0\"\npath = \"crates/egui-wgpu\"\ndefault-features = false\n\n[target.\"cfg(target_arch = \\\"wasm32\\\")\".dependencies.wgpu]\noptional = true\nversion = \"30.0\"\ndefault-features = false\nfeatures = [\"std\"]\n\n[target.\"cfg(target_arch = \\\"wasm32\\\")\".dev-dependencies]\nwasm-bindgen-test = \"=0.3.76\"\n", - "dest": "cargo/vendor/eframe", + "dest": "cargo/vendor-git/11e349eb0774eb3ab9192b38c47d748bf18abba91a0e3952d8f196513da96ee6/eframe", "dest-filename": "Cargo.toml" }, { "type": "inline", "contents": "{\"package\": null, \"files\": {}}", - "dest": "cargo/vendor/eframe", + "dest": "cargo/vendor-git/11e349eb0774eb3ab9192b38c47d748bf18abba91a0e3952d8f196513da96ee6/eframe", "dest-filename": ".cargo-checksum.json" }, { "type": "shell", "commands": [ - "cp -r --reflink=auto \"flatpak-cargo/git/egui-6d518fc/crates/egui\" \"cargo/vendor/egui\"" + "mkdir -p \"cargo/vendor-git/11e349eb0774eb3ab9192b38c47d748bf18abba91a0e3952d8f196513da96ee6\" && cp -r --reflink=auto \"flatpak-cargo/git/egui-6d518fc/crates/egui\" \"cargo/vendor-git/11e349eb0774eb3ab9192b38c47d748bf18abba91a0e3952d8f196513da96ee6/egui\"" ] }, { "type": "inline", "contents": "[package]\nname = \"egui\"\nversion = \"0.37.0\"\nauthors = [\"Emil Ernerfeldt <emil.ernerfeldt@gmail.com>\"]\ndescription = \"An easy-to-use immediate mode GUI that runs on both web and native\"\nedition = \"2024\"\nrust-version = \"1.95\"\nhomepage = \"https://github.com/emilk/egui\"\nlicense = \"MIT OR Apache-2.0\"\nreadme = \"../../README.md\"\nrepository = \"https://github.com/emilk/egui\"\ncategories = [\"gui\", \"game-development\"]\nkeywords = [\"gui\", \"imgui\", \"immediate\", \"portable\", \"gamedev\"]\ninclude = [\"../../LICENSE-APACHE\", \"../../LICENSE-MIT\", \"**/*.rs\", \"Cargo.toml\"]\n\n[package.metadata.docs.rs]\nall-features = true\nrustdoc-args = [\"--generate-link-to-definition\"]\ntargets = [\"x86_64-unknown-linux-gnu\", \"wasm32-unknown-unknown\"]\n\n[lints.rust]\nunsafe_code = \"deny\"\ntrivial_numeric_casts = \"warn\"\nunused_import_braces = \"warn\"\nunused_lifetimes = \"warn\"\ntrivial_casts = \"allow\"\nunused_qualifications = \"allow\"\n\n[lints.rust.future_incompatible]\nlevel = \"warn\"\npriority = -1\n\n[lints.rust.nonstandard_style]\nlevel = \"warn\"\npriority = -1\n\n[lints.rust.rust_2018_idioms]\nlevel = \"warn\"\npriority = -1\n\n[lints.rust.unexpected_cfgs]\nlevel = \"warn\"\ncheck-cfg = [\"cfg(web_sys_unstable_apis)\"]\n\n[lints.rustdoc]\nall = \"warn\"\n\n[lints.clippy]\nallow_attributes = \"warn\"\nas_ptr_cast_mut = \"warn\"\nbranches_sharing_code = \"warn\"\nclear_with_drain = \"warn\"\nclone_on_ref_ptr = \"warn\"\ncoerce_container_to_any = \"warn\"\ndbg_macro = \"warn\"\ndebug_assert_with_mut_call = \"warn\"\ndefault_union_representation = \"warn\"\nderive_partial_eq_without_eq = \"warn\"\ndisallowed_script_idents = \"warn\"\ndoc_include_without_cfg = \"warn\"\nempty_enum_variants_with_brackets = \"warn\"\nequatable_if_let = \"warn\"\nexit = \"warn\"\nfallible_impl_from = \"warn\"\nfloat_cmp_const = \"warn\"\nfn_to_numeric_cast_any = \"warn\"\nget_unwrap = \"warn\"\nimprecise_flops = \"warn\"\ninfinite_loop = \"warn\"\niter_on_empty_collections = \"warn\"\niter_on_single_items = \"warn\"\niter_over_hash_type = \"warn\"\nlarge_include_file = \"warn\"\nlarge_stack_frames = \"warn\"\nliteral_string_with_formatting_args = \"warn\"\nlossy_float_literal = \"warn\"\nmap_err_ignore = \"warn\"\nmem_forget = \"warn\"\nmissing_assert_message = \"warn\"\nmutex_integer = \"warn\"\nneedless_pass_by_ref_mut = \"warn\"\nneedless_type_cast = \"warn\"\nnon_zero_suggestions = \"warn\"\nnonstandard_macro_braces = \"warn\"\nor_fun_call = \"warn\"\npath_buf_push_overwrite = \"warn\"\npathbuf_init_then_push = \"warn\"\nprecedence_bits = \"warn\"\nprint_stderr = \"warn\"\nprint_stdout = \"warn\"\npub_without_shorthand = \"warn\"\nrc_mutex = \"warn\"\nredundant_type_annotations = \"warn\"\nref_patterns = \"warn\"\nrest_pat_in_fully_bound_structs = \"warn\"\nreturn_and_then = \"warn\"\nset_contains_or_insert = \"warn\"\nsingle_option_map = \"warn\"\nstd_instead_of_core = \"warn\"\nstr_to_string = \"warn\"\nstring_add = \"warn\"\nstring_lit_as_bytes = \"warn\"\nstring_lit_chars_any = \"warn\"\nsuspicious_xor_used_as_pow = \"warn\"\ntodo = \"warn\"\ntoo_long_first_doc_paragraph = \"warn\"\ntrailing_empty_array = \"warn\"\ntrait_duplication_in_bounds = \"warn\"\ntuple_array_conversions = \"warn\"\nundocumented_unsafe_blocks = \"warn\"\nunimplemented = \"warn\"\nuninhabited_references = \"warn\"\nunnecessary_safety_comment = \"warn\"\nunnecessary_safety_doc = \"warn\"\nunnecessary_self_imports = \"warn\"\nunnecessary_struct_initialization = \"warn\"\nunused_peekable = \"warn\"\nunused_rounding = \"warn\"\nunused_trait_names = \"warn\"\nunwrap_used = \"warn\"\nuse_self = \"warn\"\nuseless_let_if_seq = \"warn\"\nverbose_file_reads = \"warn\"\ncast_lossless = \"allow\"\ncast_possible_truncation = \"allow\"\ncast_possible_wrap = \"allow\"\ncast_precision_loss = \"allow\"\ncast_sign_loss = \"allow\"\ncomparison_chain = \"allow\"\ndefault_trait_access = \"allow\"\nfloat_cmp = \"allow\"\ninline_always = \"allow\"\nitems_after_statements = \"allow\"\nmany_single_char_names = \"allow\"\nmissing_panics_doc = \"allow\"\nmust_use_candidate = \"allow\"\nredundant_closure_for_method_calls = \"allow\"\nreturn_self_not_must_use = \"allow\"\nshould_panic_without_expect = \"allow\"\nsimilar_names = \"allow\"\nstruct_excessive_bools = \"allow\"\nstruct_field_names = \"allow\"\ntoo_many_lines = \"allow\"\ntrivially_copy_pass_by_ref = \"allow\"\nunreadable_literal = \"allow\"\nused_underscore_binding = \"allow\"\nassigning_clones = \"allow\"\nmanual_range_contains = \"allow\"\nmap_unwrap_or = \"allow\"\nmultiple_crate_versions = \"allow\"\nwildcard_imports = \"allow\"\nlet_underscore_must_use = \"allow\"\nlet_underscore_untyped = \"allow\"\nself_named_module_files = \"allow\"\nsignificant_drop_tightening = \"allow\"\n\n[lints.clippy.all]\nlevel = \"warn\"\npriority = -1\n\n[lints.clippy.cargo]\nlevel = \"warn\"\npriority = -1\n\n[lints.clippy.pedantic]\nlevel = \"warn\"\npriority = -1\n\n[lib]\n\n[features]\ndefault = []\nbytemuck = [\"epaint/bytemuck\"]\ncallstack = [\"dep:backtrace\"]\ncint = [\"epaint/cint\"]\ncolor-hex = [\"epaint/color-hex\"]\ndefault_fonts = [\"epaint/default_fonts\"]\nexperimental = []\nmint = [\"epaint/mint\"]\nmonochrome_emoji_fonts = [\"default_fonts\", \"epaint/monochrome_emoji_fonts\"]\npersistence = [\"serde\", \"epaint/serde\", \"ron\"]\nrayon = [\"epaint/rayon\"]\nserde = [\"dep:serde\", \"epaint/serde\", \"accesskit/serde\"]\nunity = [\"epaint/unity\"]\nweb_file = [\"dep:web-sys\"]\n_override_unity = [\"epaint/_override_unity\"]\n\n[dependencies]\naccesskit = \"0.25.0\"\nbitflags = \"2.13\"\nitertools = \"0.15.0\"\nnohash-hasher = \"0.2.0\"\nsmallvec = \"1.16\"\nunicode-segmentation = \"1.13\"\n\n[dependencies.emath]\ndefault-features = false\nversion = \"0.37.0\"\npath = \"crates/emath\"\n\n[dependencies.epaint]\ndefault-features = false\nversion = \"0.37.0\"\npath = \"crates/epaint\"\n\n[dependencies.ahash]\nversion = \"0.8.12\"\ndefault-features = false\nfeatures = [\"no-rng\", \"std\"]\n\n[dependencies.log]\nversion = \"0.4.34\"\nfeatures = [\"std\"]\n\n[dependencies.profiling]\nversion = \"1.0\"\ndefault-features = false\n\n[dependencies.backtrace]\noptional = true\nversion = \"0.3.76\"\n\n[dependencies.document-features]\noptional = true\nversion = \"0.2.12\"\n\n[dependencies.ron]\noptional = true\nversion = \"0.12.2\"\n\n[dependencies.serde]\noptional = true\nfeatures = [\"derive\", \"rc\", \"derive\"]\nversion = \"1.0\"\n\n[target.\"cfg(target_arch = \\\"wasm32\\\")\".dependencies.web-sys]\noptional = true\nfeatures = [\"File\"]\nversion = \"0.3.103\"\n\n[dev-dependencies.skrifa]\nversion = \"0.44.0\"\ndefault-features = false\nfeatures = [\"std\", \"autohint_shaping\"]\n", - "dest": "cargo/vendor/egui", + "dest": "cargo/vendor-git/11e349eb0774eb3ab9192b38c47d748bf18abba91a0e3952d8f196513da96ee6/egui", "dest-filename": "Cargo.toml" }, { "type": "inline", "contents": "{\"package\": null, \"files\": {}}", - "dest": "cargo/vendor/egui", + "dest": "cargo/vendor-git/11e349eb0774eb3ab9192b38c47d748bf18abba91a0e3952d8f196513da96ee6/egui", "dest-filename": ".cargo-checksum.json" }, { "type": "shell", "commands": [ - "cp -r --reflink=auto \"flatpak-cargo/git/egui-6d518fc/crates/egui-wgpu\" \"cargo/vendor/egui-wgpu\"" + "mkdir -p \"cargo/vendor-git/11e349eb0774eb3ab9192b38c47d748bf18abba91a0e3952d8f196513da96ee6\" && cp -r --reflink=auto \"flatpak-cargo/git/egui-6d518fc/crates/egui-wgpu\" \"cargo/vendor-git/11e349eb0774eb3ab9192b38c47d748bf18abba91a0e3952d8f196513da96ee6/egui-wgpu\"" ] }, { "type": "inline", "contents": "[package]\nname = \"egui-wgpu\"\nversion = \"0.37.0\"\ndescription = \"Bindings for using egui natively using the wgpu library\"\nauthors = [\"Nils Hasenbanck <nils@hasenbanck.de>\", \"embotech <opensource@embotech.com>\", \"Emil Ernerfeldt <emil.ernerfeldt@gmail.com>\"]\nedition = \"2024\"\nrust-version = \"1.95\"\nhomepage = \"https://github.com/emilk/egui/tree/main/crates/egui-wgpu\"\nlicense = \"MIT OR Apache-2.0\"\nreadme = \"README.md\"\nrepository = \"https://github.com/emilk/egui/tree/main/crates/egui-wgpu\"\ncategories = [\"gui\", \"game-development\"]\nkeywords = [\"wgpu\", \"egui\", \"gui\", \"gamedev\"]\ninclude = [\"../../LICENSE-APACHE\", \"../../LICENSE-MIT\", \"**/*.rs\", \"**/*.wgsl\", \"Cargo.toml\"]\n\n[package.metadata.docs.rs]\nall-features = true\nrustdoc-args = [\"--generate-link-to-definition\"]\n\n[lints.rust]\nunsafe_code = \"deny\"\ntrivial_numeric_casts = \"warn\"\nunused_import_braces = \"warn\"\nunused_lifetimes = \"warn\"\ntrivial_casts = \"allow\"\nunused_qualifications = \"allow\"\n\n[lints.rust.future_incompatible]\nlevel = \"warn\"\npriority = -1\n\n[lints.rust.nonstandard_style]\nlevel = \"warn\"\npriority = -1\n\n[lints.rust.rust_2018_idioms]\nlevel = \"warn\"\npriority = -1\n\n[lints.rust.unexpected_cfgs]\nlevel = \"warn\"\ncheck-cfg = [\"cfg(web_sys_unstable_apis)\"]\n\n[lints.rustdoc]\nall = \"warn\"\n\n[lints.clippy]\nallow_attributes = \"warn\"\nas_ptr_cast_mut = \"warn\"\nbranches_sharing_code = \"warn\"\nclear_with_drain = \"warn\"\nclone_on_ref_ptr = \"warn\"\ncoerce_container_to_any = \"warn\"\ndbg_macro = \"warn\"\ndebug_assert_with_mut_call = \"warn\"\ndefault_union_representation = \"warn\"\nderive_partial_eq_without_eq = \"warn\"\ndisallowed_script_idents = \"warn\"\ndoc_include_without_cfg = \"warn\"\nempty_enum_variants_with_brackets = \"warn\"\nequatable_if_let = \"warn\"\nexit = \"warn\"\nfallible_impl_from = \"warn\"\nfloat_cmp_const = \"warn\"\nfn_to_numeric_cast_any = \"warn\"\nget_unwrap = \"warn\"\nimprecise_flops = \"warn\"\ninfinite_loop = \"warn\"\niter_on_empty_collections = \"warn\"\niter_on_single_items = \"warn\"\niter_over_hash_type = \"warn\"\nlarge_include_file = \"warn\"\nlarge_stack_frames = \"warn\"\nliteral_string_with_formatting_args = \"warn\"\nlossy_float_literal = \"warn\"\nmap_err_ignore = \"warn\"\nmem_forget = \"warn\"\nmissing_assert_message = \"warn\"\nmutex_integer = \"warn\"\nneedless_pass_by_ref_mut = \"warn\"\nneedless_type_cast = \"warn\"\nnon_zero_suggestions = \"warn\"\nnonstandard_macro_braces = \"warn\"\nor_fun_call = \"warn\"\npath_buf_push_overwrite = \"warn\"\npathbuf_init_then_push = \"warn\"\nprecedence_bits = \"warn\"\nprint_stderr = \"warn\"\nprint_stdout = \"warn\"\npub_without_shorthand = \"warn\"\nrc_mutex = \"warn\"\nredundant_type_annotations = \"warn\"\nref_patterns = \"warn\"\nrest_pat_in_fully_bound_structs = \"warn\"\nreturn_and_then = \"warn\"\nset_contains_or_insert = \"warn\"\nsingle_option_map = \"warn\"\nstd_instead_of_core = \"warn\"\nstr_to_string = \"warn\"\nstring_add = \"warn\"\nstring_lit_as_bytes = \"warn\"\nstring_lit_chars_any = \"warn\"\nsuspicious_xor_used_as_pow = \"warn\"\ntodo = \"warn\"\ntoo_long_first_doc_paragraph = \"warn\"\ntrailing_empty_array = \"warn\"\ntrait_duplication_in_bounds = \"warn\"\ntuple_array_conversions = \"warn\"\nundocumented_unsafe_blocks = \"warn\"\nunimplemented = \"warn\"\nuninhabited_references = \"warn\"\nunnecessary_safety_comment = \"warn\"\nunnecessary_safety_doc = \"warn\"\nunnecessary_self_imports = \"warn\"\nunnecessary_struct_initialization = \"warn\"\nunused_peekable = \"warn\"\nunused_rounding = \"warn\"\nunused_trait_names = \"warn\"\nunwrap_used = \"warn\"\nuse_self = \"warn\"\nuseless_let_if_seq = \"warn\"\nverbose_file_reads = \"warn\"\ncast_lossless = \"allow\"\ncast_possible_truncation = \"allow\"\ncast_possible_wrap = \"allow\"\ncast_precision_loss = \"allow\"\ncast_sign_loss = \"allow\"\ncomparison_chain = \"allow\"\ndefault_trait_access = \"allow\"\nfloat_cmp = \"allow\"\ninline_always = \"allow\"\nitems_after_statements = \"allow\"\nmany_single_char_names = \"allow\"\nmissing_panics_doc = \"allow\"\nmust_use_candidate = \"allow\"\nredundant_closure_for_method_calls = \"allow\"\nreturn_self_not_must_use = \"allow\"\nshould_panic_without_expect = \"allow\"\nsimilar_names = \"allow\"\nstruct_excessive_bools = \"allow\"\nstruct_field_names = \"allow\"\ntoo_many_lines = \"allow\"\ntrivially_copy_pass_by_ref = \"allow\"\nunreadable_literal = \"allow\"\nused_underscore_binding = \"allow\"\nassigning_clones = \"allow\"\nmanual_range_contains = \"allow\"\nmap_unwrap_or = \"allow\"\nmultiple_crate_versions = \"allow\"\nwildcard_imports = \"allow\"\nlet_underscore_must_use = \"allow\"\nlet_underscore_untyped = \"allow\"\nself_named_module_files = \"allow\"\nsignificant_drop_tightening = \"allow\"\n\n[lints.clippy.all]\nlevel = \"warn\"\npriority = -1\n\n[lints.clippy.cargo]\nlevel = \"warn\"\npriority = -1\n\n[lints.clippy.pedantic]\nlevel = \"warn\"\npriority = -1\n\n[features]\ndefault = [\"fragile-send-sync-non-atomic-wasm\", \"macos-window-resize-jitter-fix\", \"wgpu/default\", \"wgpu/webgl\"]\ncapture = [\"dep:egui\"]\nwinit = [\"dep:winit\", \"winit/rwh_06\", \"dep:egui\", \"capture\"]\nwayland = [\"winit?/wayland\"]\nx11 = [\"winit?/x11\"]\nfragile-send-sync-non-atomic-wasm = [\"wgpu/fragile-send-sync-non-atomic-wasm\"]\nmacos-window-resize-jitter-fix = [\"wgpu/metal\"]\n\n[dependencies]\nbytemuck = \"1.25\"\ndocument-features = \"0.2.12\"\nthiserror = \"2.0\"\ntype-map = \"0.5.1\"\nweb-time = \"1.1\"\n\n[dependencies.epaint]\ndefault-features = false\nfeatures = [\"bytemuck\"]\nversion = \"0.37.0\"\npath = \"crates/epaint\"\n\n[dependencies.ahash]\nversion = \"0.8.12\"\ndefault-features = false\nfeatures = [\"no-rng\", \"std\"]\n\n[dependencies.log]\nversion = \"0.4.34\"\nfeatures = [\"std\"]\n\n[dependencies.profiling]\nversion = \"1.0\"\ndefault-features = false\n\n[dependencies.wgpu]\nfeatures = [\"wgsl\", \"std\"]\nversion = \"30.0\"\ndefault-features = false\n\n[dependencies.egui]\noptional = true\ndefault-features = false\nversion = \"0.37.0\"\npath = \"crates/egui\"\n\n[dependencies.winit]\noptional = true\ndefault-features = false\nversion = \"0.30.13\"\n", - "dest": "cargo/vendor/egui-wgpu", + "dest": "cargo/vendor-git/11e349eb0774eb3ab9192b38c47d748bf18abba91a0e3952d8f196513da96ee6/egui-wgpu", "dest-filename": "Cargo.toml" }, { "type": "inline", "contents": "{\"package\": null, \"files\": {}}", - "dest": "cargo/vendor/egui-wgpu", + "dest": "cargo/vendor-git/11e349eb0774eb3ab9192b38c47d748bf18abba91a0e3952d8f196513da96ee6/egui-wgpu", "dest-filename": ".cargo-checksum.json" }, { "type": "shell", "commands": [ - "cp -r --reflink=auto \"flatpak-cargo/git/egui-6d518fc/crates/egui-winit\" \"cargo/vendor/egui-winit\"" + "mkdir -p \"cargo/vendor-git/11e349eb0774eb3ab9192b38c47d748bf18abba91a0e3952d8f196513da96ee6\" && cp -r --reflink=auto \"flatpak-cargo/git/egui-6d518fc/crates/egui-winit\" \"cargo/vendor-git/11e349eb0774eb3ab9192b38c47d748bf18abba91a0e3952d8f196513da96ee6/egui-winit\"" ] }, { "type": "inline", "contents": "[package]\nname = \"egui-winit\"\nversion = \"0.37.0\"\nauthors = [\"Emil Ernerfeldt <emil.ernerfeldt@gmail.com>\"]\ndescription = \"Bindings for using egui with winit\"\nedition = \"2024\"\nrust-version = \"1.95\"\nhomepage = \"https://github.com/emilk/egui/tree/main/crates/egui-winit\"\nlicense = \"MIT OR Apache-2.0\"\nreadme = \"README.md\"\nrepository = \"https://github.com/emilk/egui/tree/main/crates/egui-winit\"\ncategories = [\"gui\", \"game-development\"]\nkeywords = [\"winit\", \"egui\", \"gui\", \"gamedev\"]\ninclude = [\"../../LICENSE-APACHE\", \"../../LICENSE-MIT\", \"**/*.rs\", \"Cargo.toml\"]\n\n[package.metadata.docs.rs]\nall-features = true\nrustdoc-args = [\"--generate-link-to-definition\"]\n\n[package.metadata.cargo-shear]\nignored = [\"wayland-cursor\"]\n\n[lints.rust]\nunsafe_code = \"deny\"\ntrivial_numeric_casts = \"warn\"\nunused_import_braces = \"warn\"\nunused_lifetimes = \"warn\"\ntrivial_casts = \"allow\"\nunused_qualifications = \"allow\"\n\n[lints.rust.future_incompatible]\nlevel = \"warn\"\npriority = -1\n\n[lints.rust.nonstandard_style]\nlevel = \"warn\"\npriority = -1\n\n[lints.rust.rust_2018_idioms]\nlevel = \"warn\"\npriority = -1\n\n[lints.rust.unexpected_cfgs]\nlevel = \"warn\"\ncheck-cfg = [\"cfg(web_sys_unstable_apis)\"]\n\n[lints.rustdoc]\nall = \"warn\"\n\n[lints.clippy]\nallow_attributes = \"warn\"\nas_ptr_cast_mut = \"warn\"\nbranches_sharing_code = \"warn\"\nclear_with_drain = \"warn\"\nclone_on_ref_ptr = \"warn\"\ncoerce_container_to_any = \"warn\"\ndbg_macro = \"warn\"\ndebug_assert_with_mut_call = \"warn\"\ndefault_union_representation = \"warn\"\nderive_partial_eq_without_eq = \"warn\"\ndisallowed_script_idents = \"warn\"\ndoc_include_without_cfg = \"warn\"\nempty_enum_variants_with_brackets = \"warn\"\nequatable_if_let = \"warn\"\nexit = \"warn\"\nfallible_impl_from = \"warn\"\nfloat_cmp_const = \"warn\"\nfn_to_numeric_cast_any = \"warn\"\nget_unwrap = \"warn\"\nimprecise_flops = \"warn\"\ninfinite_loop = \"warn\"\niter_on_empty_collections = \"warn\"\niter_on_single_items = \"warn\"\niter_over_hash_type = \"warn\"\nlarge_include_file = \"warn\"\nlarge_stack_frames = \"warn\"\nliteral_string_with_formatting_args = \"warn\"\nlossy_float_literal = \"warn\"\nmap_err_ignore = \"warn\"\nmem_forget = \"warn\"\nmissing_assert_message = \"warn\"\nmutex_integer = \"warn\"\nneedless_pass_by_ref_mut = \"warn\"\nneedless_type_cast = \"warn\"\nnon_zero_suggestions = \"warn\"\nnonstandard_macro_braces = \"warn\"\nor_fun_call = \"warn\"\npath_buf_push_overwrite = \"warn\"\npathbuf_init_then_push = \"warn\"\nprecedence_bits = \"warn\"\nprint_stderr = \"warn\"\nprint_stdout = \"warn\"\npub_without_shorthand = \"warn\"\nrc_mutex = \"warn\"\nredundant_type_annotations = \"warn\"\nref_patterns = \"warn\"\nrest_pat_in_fully_bound_structs = \"warn\"\nreturn_and_then = \"warn\"\nset_contains_or_insert = \"warn\"\nsingle_option_map = \"warn\"\nstd_instead_of_core = \"warn\"\nstr_to_string = \"warn\"\nstring_add = \"warn\"\nstring_lit_as_bytes = \"warn\"\nstring_lit_chars_any = \"warn\"\nsuspicious_xor_used_as_pow = \"warn\"\ntodo = \"warn\"\ntoo_long_first_doc_paragraph = \"warn\"\ntrailing_empty_array = \"warn\"\ntrait_duplication_in_bounds = \"warn\"\ntuple_array_conversions = \"warn\"\nundocumented_unsafe_blocks = \"warn\"\nunimplemented = \"warn\"\nuninhabited_references = \"warn\"\nunnecessary_safety_comment = \"warn\"\nunnecessary_safety_doc = \"warn\"\nunnecessary_self_imports = \"warn\"\nunnecessary_struct_initialization = \"warn\"\nunused_peekable = \"warn\"\nunused_rounding = \"warn\"\nunused_trait_names = \"warn\"\nunwrap_used = \"warn\"\nuse_self = \"warn\"\nuseless_let_if_seq = \"warn\"\nverbose_file_reads = \"warn\"\ncast_lossless = \"allow\"\ncast_possible_truncation = \"allow\"\ncast_possible_wrap = \"allow\"\ncast_precision_loss = \"allow\"\ncast_sign_loss = \"allow\"\ncomparison_chain = \"allow\"\ndefault_trait_access = \"allow\"\nfloat_cmp = \"allow\"\ninline_always = \"allow\"\nitems_after_statements = \"allow\"\nmany_single_char_names = \"allow\"\nmissing_panics_doc = \"allow\"\nmust_use_candidate = \"allow\"\nredundant_closure_for_method_calls = \"allow\"\nreturn_self_not_must_use = \"allow\"\nshould_panic_without_expect = \"allow\"\nsimilar_names = \"allow\"\nstruct_excessive_bools = \"allow\"\nstruct_field_names = \"allow\"\ntoo_many_lines = \"allow\"\ntrivially_copy_pass_by_ref = \"allow\"\nunreadable_literal = \"allow\"\nused_underscore_binding = \"allow\"\nassigning_clones = \"allow\"\nmanual_range_contains = \"allow\"\nmap_unwrap_or = \"allow\"\nmultiple_crate_versions = \"allow\"\nwildcard_imports = \"allow\"\nlet_underscore_must_use = \"allow\"\nlet_underscore_untyped = \"allow\"\nself_named_module_files = \"allow\"\nsignificant_drop_tightening = \"allow\"\n\n[lints.clippy.all]\nlevel = \"warn\"\npriority = -1\n\n[lints.clippy.cargo]\nlevel = \"warn\"\npriority = -1\n\n[lints.clippy.pedantic]\nlevel = \"warn\"\npriority = -1\n\n[features]\ndefault = [\"clipboard\", \"clipboard-image\", \"links\", \"wayland\", \"winit/default\", \"x11\"]\naccesskit = [\"dep:accesskit_winit\"]\nandroid-game-activity = [\"winit/android-game-activity\"]\nandroid-native-activity = [\"winit/android-native-activity\"]\nbytemuck = [\"egui/bytemuck\", \"dep:bytemuck\"]\nclipboard = [\"arboard\", \"bytemuck\", \"smithay-clipboard\"]\nclipboard-image = [\"clipboard\", \"dep:image\", \"dep:parking_lot\"]\nlinks = [\"webbrowser\"]\nserde = [\"egui/serde\", \"dep:serde\"]\nwayland = [\"winit/wayland\", \"bytemuck\", \"arboard?/wayland-data-control\"]\nx11 = [\"winit/x11\", \"winit/rwh_06\", \"bytemuck\"]\n\n[dependencies]\nraw-window-handle = \"0.6.2\"\nweb-time = \"1.1\"\n\n[dependencies.egui]\ndefault-features = false\nversion = \"0.37.0\"\npath = \"crates/egui\"\n\n[dependencies.log]\nversion = \"0.4.34\"\nfeatures = [\"std\"]\n\n[dependencies.profiling]\nversion = \"1.0\"\ndefault-features = false\n\n[dependencies.winit]\ndefault-features = false\nversion = \"0.30.13\"\n\n[dependencies.accesskit_winit]\noptional = true\nversion = \"0.34.0\"\n\n[dependencies.bytemuck]\noptional = true\nversion = \"1.25\"\n\n[dependencies.document-features]\noptional = true\nversion = \"0.2.12\"\n\n[dependencies.serde]\noptional = true\nversion = \"1.0\"\nfeatures = [\"derive\"]\n\n[dependencies.webbrowser]\noptional = true\nversion = \"1.2.4\"\n\n[dependencies.image]\ndefault-features = false\nfeatures = [\"png\"]\noptional = true\nversion = \"0.25.10\"\n\n[target.\"cfg(target_os = \\\"macos\\\")\".dependencies]\nblock2 = \"0.6.2\"\nobjc2 = \"0.6.4\"\n\n[target.\"cfg(target_os = \\\"macos\\\")\".dependencies.objc2-app-kit]\ndefault-features = false\nfeatures = [\"std\", \"block2\", \"NSEvent\", \"NSResponder\"]\nversion = \"0.3.2\"\n\n[target.\"cfg(target_os = \\\"ios\\\")\".dependencies]\nobjc2 = \"0.6.4\"\n\n[target.\"cfg(target_os = \\\"ios\\\")\".dependencies.objc2-foundation]\nfeatures = [\"std\", \"NSThread\"]\nversion = \"0.3.2\"\ndefault-features = false\n\n[target.\"cfg(target_os = \\\"ios\\\")\".dependencies.objc2-ui-kit]\nfeatures = [\"std\", \"objc2-core-foundation\", \"UIApplication\", \"UIGeometry\", \"UIResponder\", \"UIScene\", \"UISceneDefinitions\", \"UIView\", \"UIWindow\", \"UIWindowScene\"]\nversion = \"0.3.2\"\ndefault-features = false\n\n[target.\"cfg(target_os = \\\"windows\\\")\".dependencies.windows-sys]\nfeatures = [\"Win32_Foundation\", \"Win32_Graphics_Dwm\", \"Win32_UI_Input_KeyboardAndMouse\", \"Win32_UI_WindowsAndMessaging\"]\nversion = \"0.61.2\"\n\n[target.\"cfg(any(target_os=\\\"linux\\\", target_os=\\\"dragonfly\\\", target_os=\\\"freebsd\\\", target_os=\\\"netbsd\\\", target_os=\\\"openbsd\\\"))\".dependencies.smithay-clipboard]\noptional = true\nversion = \"0.7.2\"\n\n[target.\"cfg(any(target_os=\\\"linux\\\", target_os=\\\"dragonfly\\\", target_os=\\\"freebsd\\\", target_os=\\\"netbsd\\\", target_os=\\\"openbsd\\\"))\".dependencies.parking_lot]\noptional = true\nversion = \"0.12.5\"\n\n[target.\"cfg(any(target_os=\\\"linux\\\", target_os=\\\"dragonfly\\\", target_os=\\\"freebsd\\\", target_os=\\\"netbsd\\\", target_os=\\\"openbsd\\\"))\".dependencies.wayland-cursor]\noptional = true\nversion = \"0.31.14\"\ndefault-features = false\n\n[target.\"cfg(not(target_os = \\\"android\\\"))\".dependencies.arboard]\noptional = true\nfeatures = [\"image-data\"]\nversion = \"3.6\"\ndefault-features = false\n\n[target.\"cfg(target_os = \\\"linux\\\")\".dev-dependencies.softbuffer]\nversion = \"0.4.8\"\ndefault-features = false\nfeatures = [\"wayland\", \"wayland-dlopen\"]\n\n[[example]]\nname = \"clipboard_image_probe\"\nrequired-features = [\"wayland\", \"clipboard-image\"]\n", - "dest": "cargo/vendor/egui-winit", + "dest": "cargo/vendor-git/11e349eb0774eb3ab9192b38c47d748bf18abba91a0e3952d8f196513da96ee6/egui-winit", "dest-filename": "Cargo.toml" }, { "type": "inline", "contents": "{\"package\": null, \"files\": {}}", - "dest": "cargo/vendor/egui-winit", + "dest": "cargo/vendor-git/11e349eb0774eb3ab9192b38c47d748bf18abba91a0e3952d8f196513da96ee6/egui-winit", "dest-filename": ".cargo-checksum.json" }, { "type": "shell", "commands": [ - "cp -r --reflink=auto \"flatpak-cargo/git/egui-6d518fc/crates/egui_extras\" \"cargo/vendor/egui_extras\"" + "mkdir -p \"cargo/vendor-git/11e349eb0774eb3ab9192b38c47d748bf18abba91a0e3952d8f196513da96ee6\" && cp -r --reflink=auto \"flatpak-cargo/git/egui-6d518fc/crates/egui_extras\" \"cargo/vendor-git/11e349eb0774eb3ab9192b38c47d748bf18abba91a0e3952d8f196513da96ee6/egui_extras\"" ] }, { "type": "inline", "contents": "[package]\nname = \"egui_extras\"\nversion = \"0.37.0\"\nauthors = [\"Dominik R\u00f6ssler <dominik@freshx.de>\", \"Emil Ernerfeldt <emil.ernerfeldt@gmail.com>\", \"Ren\u00e9 R\u00f6ssler <rene@freshx.de>\"]\ndescription = \"Extra functionality and widgets for the egui GUI library\"\nedition = \"2024\"\nrust-version = \"1.95\"\nhomepage = \"https://github.com/emilk/egui\"\nlicense = \"MIT OR Apache-2.0\"\nreadme = \"README.md\"\nrepository = \"https://github.com/emilk/egui\"\ncategories = [\"gui\", \"game-development\"]\nkeywords = [\"gui\", \"imgui\", \"immediate\", \"portable\", \"gamedev\"]\ninclude = [\"../../LICENSE-APACHE\", \"../../LICENSE-MIT\", \"**/*.rs\", \"Cargo.toml\"]\n\n[package.metadata.docs.rs]\nall-features = true\nrustdoc-args = [\"--generate-link-to-definition\"]\n\n[lints.rust]\nunsafe_code = \"deny\"\ntrivial_numeric_casts = \"warn\"\nunused_import_braces = \"warn\"\nunused_lifetimes = \"warn\"\ntrivial_casts = \"allow\"\nunused_qualifications = \"allow\"\n\n[lints.rust.future_incompatible]\nlevel = \"warn\"\npriority = -1\n\n[lints.rust.nonstandard_style]\nlevel = \"warn\"\npriority = -1\n\n[lints.rust.rust_2018_idioms]\nlevel = \"warn\"\npriority = -1\n\n[lints.rust.unexpected_cfgs]\nlevel = \"warn\"\ncheck-cfg = [\"cfg(web_sys_unstable_apis)\"]\n\n[lints.rustdoc]\nall = \"warn\"\n\n[lints.clippy]\nallow_attributes = \"warn\"\nas_ptr_cast_mut = \"warn\"\nbranches_sharing_code = \"warn\"\nclear_with_drain = \"warn\"\nclone_on_ref_ptr = \"warn\"\ncoerce_container_to_any = \"warn\"\ndbg_macro = \"warn\"\ndebug_assert_with_mut_call = \"warn\"\ndefault_union_representation = \"warn\"\nderive_partial_eq_without_eq = \"warn\"\ndisallowed_script_idents = \"warn\"\ndoc_include_without_cfg = \"warn\"\nempty_enum_variants_with_brackets = \"warn\"\nequatable_if_let = \"warn\"\nexit = \"warn\"\nfallible_impl_from = \"warn\"\nfloat_cmp_const = \"warn\"\nfn_to_numeric_cast_any = \"warn\"\nget_unwrap = \"warn\"\nimprecise_flops = \"warn\"\ninfinite_loop = \"warn\"\niter_on_empty_collections = \"warn\"\niter_on_single_items = \"warn\"\niter_over_hash_type = \"warn\"\nlarge_include_file = \"warn\"\nlarge_stack_frames = \"warn\"\nliteral_string_with_formatting_args = \"warn\"\nlossy_float_literal = \"warn\"\nmap_err_ignore = \"warn\"\nmem_forget = \"warn\"\nmissing_assert_message = \"warn\"\nmutex_integer = \"warn\"\nneedless_pass_by_ref_mut = \"warn\"\nneedless_type_cast = \"warn\"\nnon_zero_suggestions = \"warn\"\nnonstandard_macro_braces = \"warn\"\nor_fun_call = \"warn\"\npath_buf_push_overwrite = \"warn\"\npathbuf_init_then_push = \"warn\"\nprecedence_bits = \"warn\"\nprint_stderr = \"warn\"\nprint_stdout = \"warn\"\npub_without_shorthand = \"warn\"\nrc_mutex = \"warn\"\nredundant_type_annotations = \"warn\"\nref_patterns = \"warn\"\nrest_pat_in_fully_bound_structs = \"warn\"\nreturn_and_then = \"warn\"\nset_contains_or_insert = \"warn\"\nsingle_option_map = \"warn\"\nstd_instead_of_core = \"warn\"\nstr_to_string = \"warn\"\nstring_add = \"warn\"\nstring_lit_as_bytes = \"warn\"\nstring_lit_chars_any = \"warn\"\nsuspicious_xor_used_as_pow = \"warn\"\ntodo = \"warn\"\ntoo_long_first_doc_paragraph = \"warn\"\ntrailing_empty_array = \"warn\"\ntrait_duplication_in_bounds = \"warn\"\ntuple_array_conversions = \"warn\"\nundocumented_unsafe_blocks = \"warn\"\nunimplemented = \"warn\"\nuninhabited_references = \"warn\"\nunnecessary_safety_comment = \"warn\"\nunnecessary_safety_doc = \"warn\"\nunnecessary_self_imports = \"warn\"\nunnecessary_struct_initialization = \"warn\"\nunused_peekable = \"warn\"\nunused_rounding = \"warn\"\nunused_trait_names = \"warn\"\nunwrap_used = \"warn\"\nuse_self = \"warn\"\nuseless_let_if_seq = \"warn\"\nverbose_file_reads = \"warn\"\ncast_lossless = \"allow\"\ncast_possible_truncation = \"allow\"\ncast_possible_wrap = \"allow\"\ncast_precision_loss = \"allow\"\ncast_sign_loss = \"allow\"\ncomparison_chain = \"allow\"\ndefault_trait_access = \"allow\"\nfloat_cmp = \"allow\"\ninline_always = \"allow\"\nitems_after_statements = \"allow\"\nmany_single_char_names = \"allow\"\nmissing_panics_doc = \"allow\"\nmust_use_candidate = \"allow\"\nredundant_closure_for_method_calls = \"allow\"\nreturn_self_not_must_use = \"allow\"\nshould_panic_without_expect = \"allow\"\nsimilar_names = \"allow\"\nstruct_excessive_bools = \"allow\"\nstruct_field_names = \"allow\"\ntoo_many_lines = \"allow\"\ntrivially_copy_pass_by_ref = \"allow\"\nunreadable_literal = \"allow\"\nused_underscore_binding = \"allow\"\nassigning_clones = \"allow\"\nmanual_range_contains = \"allow\"\nmap_unwrap_or = \"allow\"\nmultiple_crate_versions = \"allow\"\nwildcard_imports = \"allow\"\nlet_underscore_must_use = \"allow\"\nlet_underscore_untyped = \"allow\"\nself_named_module_files = \"allow\"\nsignificant_drop_tightening = \"allow\"\n\n[lints.clippy.all]\nlevel = \"warn\"\npriority = -1\n\n[lints.clippy.cargo]\nlevel = \"warn\"\npriority = -1\n\n[lints.clippy.pedantic]\nlevel = \"warn\"\npriority = -1\n\n[lib]\n\n[features]\ndefault = [\"dep:mime_guess2\"]\nall_loaders = [\"file\", \"http\", \"image\", \"svg\", \"gif\", \"webp\"]\ndatepicker = [\"jiff\"]\nfile = [\"dep:mime_guess2\"]\ngif = [\"image\", \"image/gif\"]\nwebp = [\"image\", \"image/webp\"]\nhttp = [\"dep:ehttp\"]\nimage = [\"dep:image\"]\nserde = [\"egui/serde\", \"enum-map/serde\", \"dep:serde\"]\nsvg = [\"resvg\"]\nsvg_text = [\"svg\", \"resvg/text\", \"resvg/system-fonts\"]\nsvg_images = [\"svg\", \"resvg/raster-images\"]\nsyntect = [\"dep:syntect\"]\n\n[dependencies]\nenum-map = \"3.1\"\nitertools = \"0.15.0\"\n\n[dependencies.egui]\ndefault-features = false\nversion = \"0.37.0\"\npath = \"crates/egui\"\n\n[dependencies.ahash]\nversion = \"0.8.12\"\ndefault-features = false\nfeatures = [\"no-rng\", \"std\"]\n\n[dependencies.log]\nversion = \"0.4.34\"\nfeatures = [\"std\"]\n\n[dependencies.profiling]\nversion = \"1.0\"\ndefault-features = false\n\n[dependencies.serde]\noptional = true\nversion = \"1.0\"\nfeatures = [\"derive\"]\n\n[dependencies.jiff]\noptional = true\nfeatures = [\"std\", \"tz-system\", \"js\"]\nversion = \"0.2.35\"\ndefault-features = false\n\n[dependencies.document-features]\noptional = true\nversion = \"0.2.12\"\n\n[dependencies.image]\noptional = true\nversion = \"0.25.10\"\ndefault-features = false\n\n[dependencies.mime_guess2]\noptional = true\nversion = \"2.3\"\ndefault-features = false\n\n[dependencies.syntect]\noptional = true\nfeatures = [\"default-fancy\"]\nversion = \"5.3\"\ndefault-features = false\n\n[dependencies.resvg]\noptional = true\nversion = \"0.45.1\"\ndefault-features = false\n\n[dependencies.ehttp]\noptional = true\nversion = \"0.7.1\"\ndefault-features = false\n\n[dev-dependencies]\ntempfile = \"3.27\"\n\n[dev-dependencies.egui]\nfeatures = [\"default_fonts\"]\nversion = \"0.37.0\"\npath = \"crates/egui\"\ndefault-features = false\n\n[dev-dependencies.egui_kittest]\npath = \"../egui_kittest\"\nfeatures = [\"snapshot\", \"wgpu\"]\n", - "dest": "cargo/vendor/egui_extras", + "dest": "cargo/vendor-git/11e349eb0774eb3ab9192b38c47d748bf18abba91a0e3952d8f196513da96ee6/egui_extras", "dest-filename": "Cargo.toml" }, { "type": "inline", "contents": "{\"package\": null, \"files\": {}}", - "dest": "cargo/vendor/egui_extras", + "dest": "cargo/vendor-git/11e349eb0774eb3ab9192b38c47d748bf18abba91a0e3952d8f196513da96ee6/egui_extras", "dest-filename": ".cargo-checksum.json" }, { "type": "shell", "commands": [ - "cp -r --reflink=auto \"flatpak-cargo/git/egui-6d518fc/crates/egui_glow\" \"cargo/vendor/egui_glow\"" + "mkdir -p \"cargo/vendor-git/11e349eb0774eb3ab9192b38c47d748bf18abba91a0e3952d8f196513da96ee6\" && cp -r --reflink=auto \"flatpak-cargo/git/egui-6d518fc/crates/egui_glow\" \"cargo/vendor-git/11e349eb0774eb3ab9192b38c47d748bf18abba91a0e3952d8f196513da96ee6/egui_glow\"" ] }, { "type": "inline", "contents": "[package]\nname = \"egui_glow\"\nversion = \"0.37.0\"\nauthors = [\"Emil Ernerfeldt <emil.ernerfeldt@gmail.com>\"]\ndescription = \"Bindings for using egui natively using the glow library\"\nedition = \"2024\"\nrust-version = \"1.95\"\nhomepage = \"https://github.com/emilk/egui/tree/main/crates/egui_glow\"\nlicense = \"MIT OR Apache-2.0\"\nreadme = \"README.md\"\nrepository = \"https://github.com/emilk/egui/tree/main/crates/egui_glow\"\ncategories = [\"gui\", \"game-development\"]\nkeywords = [\"glow\", \"egui\", \"gui\", \"gamedev\"]\ninclude = [\"../../LICENSE-APACHE\", \"../../LICENSE-MIT\", \"**/*.rs\", \"Cargo.toml\", \"src/shader/*.glsl\"]\n\n[package.metadata.docs.rs]\nall-features = true\nrustdoc-args = [\"--generate-link-to-definition\"]\n\n[lints.rust]\nunsafe_code = \"deny\"\ntrivial_numeric_casts = \"warn\"\nunused_import_braces = \"warn\"\nunused_lifetimes = \"warn\"\ntrivial_casts = \"allow\"\nunused_qualifications = \"allow\"\n\n[lints.rust.future_incompatible]\nlevel = \"warn\"\npriority = -1\n\n[lints.rust.nonstandard_style]\nlevel = \"warn\"\npriority = -1\n\n[lints.rust.rust_2018_idioms]\nlevel = \"warn\"\npriority = -1\n\n[lints.rust.unexpected_cfgs]\nlevel = \"warn\"\ncheck-cfg = [\"cfg(web_sys_unstable_apis)\"]\n\n[lints.rustdoc]\nall = \"warn\"\n\n[lints.clippy]\nallow_attributes = \"warn\"\nas_ptr_cast_mut = \"warn\"\nbranches_sharing_code = \"warn\"\nclear_with_drain = \"warn\"\nclone_on_ref_ptr = \"warn\"\ncoerce_container_to_any = \"warn\"\ndbg_macro = \"warn\"\ndebug_assert_with_mut_call = \"warn\"\ndefault_union_representation = \"warn\"\nderive_partial_eq_without_eq = \"warn\"\ndisallowed_script_idents = \"warn\"\ndoc_include_without_cfg = \"warn\"\nempty_enum_variants_with_brackets = \"warn\"\nequatable_if_let = \"warn\"\nexit = \"warn\"\nfallible_impl_from = \"warn\"\nfloat_cmp_const = \"warn\"\nfn_to_numeric_cast_any = \"warn\"\nget_unwrap = \"warn\"\nimprecise_flops = \"warn\"\ninfinite_loop = \"warn\"\niter_on_empty_collections = \"warn\"\niter_on_single_items = \"warn\"\niter_over_hash_type = \"warn\"\nlarge_include_file = \"warn\"\nlarge_stack_frames = \"warn\"\nliteral_string_with_formatting_args = \"warn\"\nlossy_float_literal = \"warn\"\nmap_err_ignore = \"warn\"\nmem_forget = \"warn\"\nmissing_assert_message = \"warn\"\nmutex_integer = \"warn\"\nneedless_pass_by_ref_mut = \"warn\"\nneedless_type_cast = \"warn\"\nnon_zero_suggestions = \"warn\"\nnonstandard_macro_braces = \"warn\"\nor_fun_call = \"warn\"\npath_buf_push_overwrite = \"warn\"\npathbuf_init_then_push = \"warn\"\nprecedence_bits = \"warn\"\nprint_stderr = \"warn\"\nprint_stdout = \"warn\"\npub_without_shorthand = \"warn\"\nrc_mutex = \"warn\"\nredundant_type_annotations = \"warn\"\nref_patterns = \"warn\"\nrest_pat_in_fully_bound_structs = \"warn\"\nreturn_and_then = \"warn\"\nset_contains_or_insert = \"warn\"\nsingle_option_map = \"warn\"\nstd_instead_of_core = \"warn\"\nstr_to_string = \"warn\"\nstring_add = \"warn\"\nstring_lit_as_bytes = \"warn\"\nstring_lit_chars_any = \"warn\"\nsuspicious_xor_used_as_pow = \"warn\"\ntodo = \"warn\"\ntoo_long_first_doc_paragraph = \"warn\"\ntrailing_empty_array = \"warn\"\ntrait_duplication_in_bounds = \"warn\"\ntuple_array_conversions = \"warn\"\nundocumented_unsafe_blocks = \"warn\"\nunimplemented = \"warn\"\nuninhabited_references = \"warn\"\nunnecessary_safety_comment = \"warn\"\nunnecessary_safety_doc = \"warn\"\nunnecessary_self_imports = \"warn\"\nunnecessary_struct_initialization = \"warn\"\nunused_peekable = \"warn\"\nunused_rounding = \"warn\"\nunused_trait_names = \"warn\"\nunwrap_used = \"warn\"\nuse_self = \"warn\"\nuseless_let_if_seq = \"warn\"\nverbose_file_reads = \"warn\"\ncast_lossless = \"allow\"\ncast_possible_truncation = \"allow\"\ncast_possible_wrap = \"allow\"\ncast_precision_loss = \"allow\"\ncast_sign_loss = \"allow\"\ncomparison_chain = \"allow\"\ndefault_trait_access = \"allow\"\nfloat_cmp = \"allow\"\ninline_always = \"allow\"\nitems_after_statements = \"allow\"\nmany_single_char_names = \"allow\"\nmissing_panics_doc = \"allow\"\nmust_use_candidate = \"allow\"\nredundant_closure_for_method_calls = \"allow\"\nreturn_self_not_must_use = \"allow\"\nshould_panic_without_expect = \"allow\"\nsimilar_names = \"allow\"\nstruct_excessive_bools = \"allow\"\nstruct_field_names = \"allow\"\ntoo_many_lines = \"allow\"\ntrivially_copy_pass_by_ref = \"allow\"\nunreadable_literal = \"allow\"\nused_underscore_binding = \"allow\"\nassigning_clones = \"allow\"\nmanual_range_contains = \"allow\"\nmap_unwrap_or = \"allow\"\nmultiple_crate_versions = \"allow\"\nwildcard_imports = \"allow\"\nlet_underscore_must_use = \"allow\"\nlet_underscore_untyped = \"allow\"\nself_named_module_files = \"allow\"\nsignificant_drop_tightening = \"allow\"\n\n[lints.clippy.all]\nlevel = \"warn\"\npriority = -1\n\n[lints.clippy.cargo]\nlevel = \"warn\"\npriority = -1\n\n[lints.clippy.pedantic]\nlevel = \"warn\"\npriority = -1\n\n[features]\ndefault = []\nclipboard = [\"egui-winit?/clipboard\"]\nlinks = [\"egui-winit?/links\"]\nwinit = [\"egui-winit\", \"dep:winit\"]\nwayland = [\"winit?/wayland\"]\nx11 = [\"winit?/x11\"]\n\n[dependencies]\nbytemuck = \"1.25\"\nglow = \"0.17.0\"\n\n[dependencies.egui]\ndefault-features = false\nfeatures = [\"bytemuck\"]\nversion = \"0.37.0\"\npath = \"crates/egui\"\n\n[dependencies.egui-winit]\noptional = true\ndefault-features = false\nversion = \"0.37.0\"\npath = \"crates/egui-winit\"\n\n[dependencies.log]\nversion = \"0.4.34\"\nfeatures = [\"std\"]\n\n[dependencies.profiling]\nversion = \"1.0\"\ndefault-features = false\n\n[dependencies.document-features]\noptional = true\nversion = \"0.2.12\"\n\n[dependencies.winit]\noptional = true\ndefault-features = false\nfeatures = [\"rwh_06\"]\nversion = \"0.30.13\"\n\n[dev-dependencies.glutin]\ndefault-features = false\nversion = \"0.32.3\"\n\n[dev-dependencies.glutin-winit]\ndefault-features = false\nversion = \"0.5.0\"\n\n[[example]]\nname = \"pure_glow\"\nrequired-features = [\"winit\", \"egui/default_fonts\"]\n", - "dest": "cargo/vendor/egui_glow", + "dest": "cargo/vendor-git/11e349eb0774eb3ab9192b38c47d748bf18abba91a0e3952d8f196513da96ee6/egui_glow", "dest-filename": "Cargo.toml" }, { "type": "inline", "contents": "{\"package\": null, \"files\": {}}", - "dest": "cargo/vendor/egui_glow", + "dest": "cargo/vendor-git/11e349eb0774eb3ab9192b38c47d748bf18abba91a0e3952d8f196513da96ee6/egui_glow", "dest-filename": ".cargo-checksum.json" }, { "type": "shell", "commands": [ - "cp -r --reflink=auto \"flatpak-cargo/git/egui-6d518fc/crates/egui_kittest\" \"cargo/vendor/egui_kittest\"" + "mkdir -p \"cargo/vendor-git/11e349eb0774eb3ab9192b38c47d748bf18abba91a0e3952d8f196513da96ee6\" && cp -r --reflink=auto \"flatpak-cargo/git/egui-6d518fc/crates/egui_kittest\" \"cargo/vendor-git/11e349eb0774eb3ab9192b38c47d748bf18abba91a0e3952d8f196513da96ee6/egui_kittest\"" ] }, { "type": "inline", "contents": "[package]\nname = \"egui_kittest\"\nversion = \"0.37.0\"\nauthors = [\"Lucas Meurer <hi@lucasmerlin.me>\", \"Emil Ernerfeldt <emil.ernerfeldt@gmail.com>\"]\ndescription = \"Testing library for egui based on kittest and AccessKit\"\nedition = \"2024\"\nrust-version = \"1.95\"\nhomepage = \"https://github.com/emilk/egui\"\nlicense = \"MIT OR Apache-2.0\"\nreadme = \"./README.md\"\nrepository = \"https://github.com/emilk/egui\"\ncategories = [\"gui\", \"development-tools::testing\", \"accessibility\"]\nkeywords = [\"gui\", \"immediate\", \"egui\", \"testing\", \"accesskit\"]\ninclude = [\"../../LICENSE-APACHE\", \"../../LICENSE-MIT\", \"**/*.rs\", \"Cargo.toml\"]\n\n[package.metadata.docs.rs]\nall-features = true\nrustdoc-args = [\"--generate-link-to-definition\"]\n\n[features]\nwgpu = [\"dep:egui-wgpu\", \"dep:pollster\", \"dep:image\", \"dep:wgpu\", \"eframe?/wgpu\"]\nsnapshot = [\"dep:dify\", \"dep:image\", \"dep:open\", \"dep:tempfile\", \"image/png\"]\nvideo = [\"snapshot\"]\neframe = [\"dep:eframe\", \"eframe/accesskit\"]\nx11 = [\"eframe?/x11\"]\n\n[dependencies.egui]\nversion = \"0.37.0\"\npath = \"crates/egui\"\ndefault-features = false\n\n[dependencies.eframe]\noptional = true\nversion = \"0.37.0\"\npath = \"crates/eframe\"\ndefault-features = false\n\n[dependencies.kittest]\nversion = \"0.5.0\"\n\n[dependencies.log]\nversion = \"0.4.34\"\nfeatures = [\"std\"]\n\n[dependencies.serde]\nversion = \"1.0\"\nfeatures = [\"derive\"]\n\n[dependencies.toml]\nfeatures = [\"parse\", \"serde\"]\nversion = \"1.1\"\ndefault-features = false\n\n[dependencies.egui-wgpu]\noptional = true\nversion = \"0.37.0\"\npath = \"crates/egui-wgpu\"\ndefault-features = false\n\n[dependencies.pollster]\noptional = true\nversion = \"1.0\"\n\n[dependencies.image]\noptional = true\nversion = \"0.25.10\"\ndefault-features = false\n\n[dependencies.wgpu]\nfeatures = [\"metal\", \"dx12\", \"vulkan\", \"gles\", \"std\"]\noptional = true\nversion = \"30.0\"\ndefault-features = false\n\n[dependencies.dify]\noptional = true\nversion = \"0.8.0\"\ndefault-features = false\n\n[dependencies.document-features]\noptional = true\nversion = \"0.2.12\"\n\n[target.\"cfg(not(target_arch = \\\"wasm32\\\"))\".dependencies.open]\noptional = true\nversion = \"5.4\"\n\n[target.\"cfg(not(target_arch = \\\"wasm32\\\"))\".dependencies.tempfile]\noptional = true\nversion = \"3.27\"\n\n[dev-dependencies]\ntempfile = \"3.27\"\n\n[dev-dependencies.egui]\nfeatures = [\"default_fonts\", \"monochrome_emoji_fonts\"]\nversion = \"0.37.0\"\npath = \"crates/egui\"\ndefault-features = false\n\n[dev-dependencies.image]\nfeatures = [\"png\"]\nversion = \"0.25.10\"\ndefault-features = false\n\n[dev-dependencies.egui_extras]\nfeatures = [\"image\", \"http\"]\nversion = \"0.37.0\"\npath = \"crates/egui_extras\"\ndefault-features = false\n\n[lints.rust]\nunsafe_code = \"deny\"\ntrivial_numeric_casts = \"warn\"\nunused_import_braces = \"warn\"\nunused_lifetimes = \"warn\"\ntrivial_casts = \"allow\"\nunused_qualifications = \"allow\"\n\n[lints.rust.future_incompatible]\nlevel = \"warn\"\npriority = -1\n\n[lints.rust.nonstandard_style]\nlevel = \"warn\"\npriority = -1\n\n[lints.rust.rust_2018_idioms]\nlevel = \"warn\"\npriority = -1\n\n[lints.rust.unexpected_cfgs]\nlevel = \"warn\"\ncheck-cfg = [\"cfg(web_sys_unstable_apis)\"]\n\n[lints.rustdoc]\nall = \"warn\"\n\n[lints.clippy]\nallow_attributes = \"warn\"\nas_ptr_cast_mut = \"warn\"\nbranches_sharing_code = \"warn\"\nclear_with_drain = \"warn\"\nclone_on_ref_ptr = \"warn\"\ncoerce_container_to_any = \"warn\"\ndbg_macro = \"warn\"\ndebug_assert_with_mut_call = \"warn\"\ndefault_union_representation = \"warn\"\nderive_partial_eq_without_eq = \"warn\"\ndisallowed_script_idents = \"warn\"\ndoc_include_without_cfg = \"warn\"\nempty_enum_variants_with_brackets = \"warn\"\nequatable_if_let = \"warn\"\nexit = \"warn\"\nfallible_impl_from = \"warn\"\nfloat_cmp_const = \"warn\"\nfn_to_numeric_cast_any = \"warn\"\nget_unwrap = \"warn\"\nimprecise_flops = \"warn\"\ninfinite_loop = \"warn\"\niter_on_empty_collections = \"warn\"\niter_on_single_items = \"warn\"\niter_over_hash_type = \"warn\"\nlarge_include_file = \"warn\"\nlarge_stack_frames = \"warn\"\nliteral_string_with_formatting_args = \"warn\"\nlossy_float_literal = \"warn\"\nmap_err_ignore = \"warn\"\nmem_forget = \"warn\"\nmissing_assert_message = \"warn\"\nmutex_integer = \"warn\"\nneedless_pass_by_ref_mut = \"warn\"\nneedless_type_cast = \"warn\"\nnon_zero_suggestions = \"warn\"\nnonstandard_macro_braces = \"warn\"\nor_fun_call = \"warn\"\npath_buf_push_overwrite = \"warn\"\npathbuf_init_then_push = \"warn\"\nprecedence_bits = \"warn\"\nprint_stderr = \"warn\"\nprint_stdout = \"warn\"\npub_without_shorthand = \"warn\"\nrc_mutex = \"warn\"\nredundant_type_annotations = \"warn\"\nref_patterns = \"warn\"\nrest_pat_in_fully_bound_structs = \"warn\"\nreturn_and_then = \"warn\"\nset_contains_or_insert = \"warn\"\nsingle_option_map = \"warn\"\nstd_instead_of_core = \"warn\"\nstr_to_string = \"warn\"\nstring_add = \"warn\"\nstring_lit_as_bytes = \"warn\"\nstring_lit_chars_any = \"warn\"\nsuspicious_xor_used_as_pow = \"warn\"\ntodo = \"warn\"\ntoo_long_first_doc_paragraph = \"warn\"\ntrailing_empty_array = \"warn\"\ntrait_duplication_in_bounds = \"warn\"\ntuple_array_conversions = \"warn\"\nundocumented_unsafe_blocks = \"warn\"\nunimplemented = \"warn\"\nuninhabited_references = \"warn\"\nunnecessary_safety_comment = \"warn\"\nunnecessary_safety_doc = \"warn\"\nunnecessary_self_imports = \"warn\"\nunnecessary_struct_initialization = \"warn\"\nunused_peekable = \"warn\"\nunused_rounding = \"warn\"\nunused_trait_names = \"warn\"\nunwrap_used = \"warn\"\nuse_self = \"warn\"\nuseless_let_if_seq = \"warn\"\nverbose_file_reads = \"warn\"\ncast_lossless = \"allow\"\ncast_possible_truncation = \"allow\"\ncast_possible_wrap = \"allow\"\ncast_precision_loss = \"allow\"\ncast_sign_loss = \"allow\"\ncomparison_chain = \"allow\"\ndefault_trait_access = \"allow\"\nfloat_cmp = \"allow\"\ninline_always = \"allow\"\nitems_after_statements = \"allow\"\nmany_single_char_names = \"allow\"\nmissing_panics_doc = \"allow\"\nmust_use_candidate = \"allow\"\nredundant_closure_for_method_calls = \"allow\"\nreturn_self_not_must_use = \"allow\"\nshould_panic_without_expect = \"allow\"\nsimilar_names = \"allow\"\nstruct_excessive_bools = \"allow\"\nstruct_field_names = \"allow\"\ntoo_many_lines = \"allow\"\ntrivially_copy_pass_by_ref = \"allow\"\nunreadable_literal = \"allow\"\nused_underscore_binding = \"allow\"\nassigning_clones = \"allow\"\nmanual_range_contains = \"allow\"\nmap_unwrap_or = \"allow\"\nmultiple_crate_versions = \"allow\"\nwildcard_imports = \"allow\"\nlet_underscore_must_use = \"allow\"\nlet_underscore_untyped = \"allow\"\nself_named_module_files = \"allow\"\nsignificant_drop_tightening = \"allow\"\n\n[lints.clippy.all]\nlevel = \"warn\"\npriority = -1\n\n[lints.clippy.cargo]\nlevel = \"warn\"\npriority = -1\n\n[lints.clippy.pedantic]\nlevel = \"warn\"\npriority = -1\n", - "dest": "cargo/vendor/egui_kittest", + "dest": "cargo/vendor-git/11e349eb0774eb3ab9192b38c47d748bf18abba91a0e3952d8f196513da96ee6/egui_kittest", "dest-filename": "Cargo.toml" }, { "type": "inline", "contents": "{\"package\": null, \"files\": {}}", - "dest": "cargo/vendor/egui_kittest", + "dest": "cargo/vendor-git/11e349eb0774eb3ab9192b38c47d748bf18abba91a0e3952d8f196513da96ee6/egui_kittest", "dest-filename": ".cargo-checksum.json" }, { @@ -2575,19 +2575,19 @@ { "type": "shell", "commands": [ - "cp -r --reflink=auto \"flatpak-cargo/git/egui-6d518fc/crates/emath\" \"cargo/vendor/emath\"" + "mkdir -p \"cargo/vendor-git/11e349eb0774eb3ab9192b38c47d748bf18abba91a0e3952d8f196513da96ee6\" && cp -r --reflink=auto \"flatpak-cargo/git/egui-6d518fc/crates/emath\" \"cargo/vendor-git/11e349eb0774eb3ab9192b38c47d748bf18abba91a0e3952d8f196513da96ee6/emath\"" ] }, { "type": "inline", "contents": "[package]\nname = \"emath\"\nversion = \"0.37.0\"\nauthors = [\"Emil Ernerfeldt <emil.ernerfeldt@gmail.com>\"]\ndescription = \"Minimal 2D math library for GUI work\"\nedition = \"2024\"\nrust-version = \"1.95\"\nhomepage = \"https://github.com/emilk/egui/tree/main/crates/emath\"\nlicense = \"MIT OR Apache-2.0\"\nreadme = \"README.md\"\nrepository = \"https://github.com/emilk/egui/tree/main/crates/emath\"\ncategories = [\"mathematics\", \"gui\"]\nkeywords = [\"math\", \"gui\"]\ninclude = [\"../../LICENSE-APACHE\", \"../../LICENSE-MIT\", \"**/*.rs\", \"Cargo.toml\"]\n\n[package.metadata.docs.rs]\nall-features = true\nrustdoc-args = [\"--generate-link-to-definition\"]\n\n[lints.rust]\nunsafe_code = \"deny\"\ntrivial_numeric_casts = \"warn\"\nunused_import_braces = \"warn\"\nunused_lifetimes = \"warn\"\ntrivial_casts = \"allow\"\nunused_qualifications = \"allow\"\n\n[lints.rust.future_incompatible]\nlevel = \"warn\"\npriority = -1\n\n[lints.rust.nonstandard_style]\nlevel = \"warn\"\npriority = -1\n\n[lints.rust.rust_2018_idioms]\nlevel = \"warn\"\npriority = -1\n\n[lints.rust.unexpected_cfgs]\nlevel = \"warn\"\ncheck-cfg = [\"cfg(web_sys_unstable_apis)\"]\n\n[lints.rustdoc]\nall = \"warn\"\n\n[lints.clippy]\nallow_attributes = \"warn\"\nas_ptr_cast_mut = \"warn\"\nbranches_sharing_code = \"warn\"\nclear_with_drain = \"warn\"\nclone_on_ref_ptr = \"warn\"\ncoerce_container_to_any = \"warn\"\ndbg_macro = \"warn\"\ndebug_assert_with_mut_call = \"warn\"\ndefault_union_representation = \"warn\"\nderive_partial_eq_without_eq = \"warn\"\ndisallowed_script_idents = \"warn\"\ndoc_include_without_cfg = \"warn\"\nempty_enum_variants_with_brackets = \"warn\"\nequatable_if_let = \"warn\"\nexit = \"warn\"\nfallible_impl_from = \"warn\"\nfloat_cmp_const = \"warn\"\nfn_to_numeric_cast_any = \"warn\"\nget_unwrap = \"warn\"\nimprecise_flops = \"warn\"\ninfinite_loop = \"warn\"\niter_on_empty_collections = \"warn\"\niter_on_single_items = \"warn\"\niter_over_hash_type = \"warn\"\nlarge_include_file = \"warn\"\nlarge_stack_frames = \"warn\"\nliteral_string_with_formatting_args = \"warn\"\nlossy_float_literal = \"warn\"\nmap_err_ignore = \"warn\"\nmem_forget = \"warn\"\nmissing_assert_message = \"warn\"\nmutex_integer = \"warn\"\nneedless_pass_by_ref_mut = \"warn\"\nneedless_type_cast = \"warn\"\nnon_zero_suggestions = \"warn\"\nnonstandard_macro_braces = \"warn\"\nor_fun_call = \"warn\"\npath_buf_push_overwrite = \"warn\"\npathbuf_init_then_push = \"warn\"\nprecedence_bits = \"warn\"\nprint_stderr = \"warn\"\nprint_stdout = \"warn\"\npub_without_shorthand = \"warn\"\nrc_mutex = \"warn\"\nredundant_type_annotations = \"warn\"\nref_patterns = \"warn\"\nrest_pat_in_fully_bound_structs = \"warn\"\nreturn_and_then = \"warn\"\nset_contains_or_insert = \"warn\"\nsingle_option_map = \"warn\"\nstd_instead_of_core = \"warn\"\nstr_to_string = \"warn\"\nstring_add = \"warn\"\nstring_lit_as_bytes = \"warn\"\nstring_lit_chars_any = \"warn\"\nsuspicious_xor_used_as_pow = \"warn\"\ntodo = \"warn\"\ntoo_long_first_doc_paragraph = \"warn\"\ntrailing_empty_array = \"warn\"\ntrait_duplication_in_bounds = \"warn\"\ntuple_array_conversions = \"warn\"\nundocumented_unsafe_blocks = \"warn\"\nunimplemented = \"warn\"\nuninhabited_references = \"warn\"\nunnecessary_safety_comment = \"warn\"\nunnecessary_safety_doc = \"warn\"\nunnecessary_self_imports = \"warn\"\nunnecessary_struct_initialization = \"warn\"\nunused_peekable = \"warn\"\nunused_rounding = \"warn\"\nunused_trait_names = \"warn\"\nunwrap_used = \"warn\"\nuse_self = \"warn\"\nuseless_let_if_seq = \"warn\"\nverbose_file_reads = \"warn\"\ncast_lossless = \"allow\"\ncast_possible_truncation = \"allow\"\ncast_possible_wrap = \"allow\"\ncast_precision_loss = \"allow\"\ncast_sign_loss = \"allow\"\ncomparison_chain = \"allow\"\ndefault_trait_access = \"allow\"\nfloat_cmp = \"allow\"\ninline_always = \"allow\"\nitems_after_statements = \"allow\"\nmany_single_char_names = \"allow\"\nmissing_panics_doc = \"allow\"\nmust_use_candidate = \"allow\"\nredundant_closure_for_method_calls = \"allow\"\nreturn_self_not_must_use = \"allow\"\nshould_panic_without_expect = \"allow\"\nsimilar_names = \"allow\"\nstruct_excessive_bools = \"allow\"\nstruct_field_names = \"allow\"\ntoo_many_lines = \"allow\"\ntrivially_copy_pass_by_ref = \"allow\"\nunreadable_literal = \"allow\"\nused_underscore_binding = \"allow\"\nassigning_clones = \"allow\"\nmanual_range_contains = \"allow\"\nmap_unwrap_or = \"allow\"\nmultiple_crate_versions = \"allow\"\nwildcard_imports = \"allow\"\nlet_underscore_must_use = \"allow\"\nlet_underscore_untyped = \"allow\"\nself_named_module_files = \"allow\"\nsignificant_drop_tightening = \"allow\"\n\n[lints.clippy.all]\nlevel = \"warn\"\npriority = -1\n\n[lints.clippy.cargo]\nlevel = \"warn\"\npriority = -1\n\n[lints.clippy.pedantic]\nlevel = \"warn\"\npriority = -1\n\n[lib]\n\n[features]\ndefault = []\n\n[dependencies.bytemuck]\noptional = true\nfeatures = [\"derive\"]\nversion = \"1.25\"\n\n[dependencies.document-features]\noptional = true\nversion = \"0.2.12\"\n\n[dependencies.mint]\noptional = true\nversion = \"0.5.9\"\n\n[dependencies.serde]\noptional = true\nversion = \"1.0\"\nfeatures = [\"derive\"]\n", - "dest": "cargo/vendor/emath", + "dest": "cargo/vendor-git/11e349eb0774eb3ab9192b38c47d748bf18abba91a0e3952d8f196513da96ee6/emath", "dest-filename": "Cargo.toml" }, { "type": "inline", "contents": "{\"package\": null, \"files\": {}}", - "dest": "cargo/vendor/emath", + "dest": "cargo/vendor-git/11e349eb0774eb3ab9192b38c47d748bf18abba91a0e3952d8f196513da96ee6/emath", "dest-filename": ".cargo-checksum.json" }, { @@ -2684,37 +2684,37 @@ { "type": "shell", "commands": [ - "cp -r --reflink=auto \"flatpak-cargo/git/egui-6d518fc/crates/epaint\" \"cargo/vendor/epaint\"" + "mkdir -p \"cargo/vendor-git/11e349eb0774eb3ab9192b38c47d748bf18abba91a0e3952d8f196513da96ee6\" && cp -r --reflink=auto \"flatpak-cargo/git/egui-6d518fc/crates/epaint\" \"cargo/vendor-git/11e349eb0774eb3ab9192b38c47d748bf18abba91a0e3952d8f196513da96ee6/epaint\"" ] }, { "type": "inline", "contents": "[package]\nname = \"epaint\"\nversion = \"0.37.0\"\nauthors = [\"Emil Ernerfeldt <emil.ernerfeldt@gmail.com>\"]\ndescription = \"Minimal 2D graphics library for GUI work\"\nedition = \"2024\"\nrust-version = \"1.95\"\nhomepage = \"https://github.com/emilk/egui/tree/main/crates/epaint\"\nlicense = \"MIT OR Apache-2.0\"\nreadme = \"README.md\"\nrepository = \"https://github.com/emilk/egui/tree/main/crates/epaint\"\ncategories = [\"graphics\", \"gui\"]\nkeywords = [\"graphics\", \"gui\", \"egui\"]\ninclude = [\"../../LICENSE-APACHE\", \"../../LICENSE-MIT\", \"**/*.rs\", \"Cargo.toml\"]\n\n[package.metadata.docs.rs]\nall-features = true\nrustdoc-args = [\"--generate-link-to-definition\"]\n\n[lints.rust]\nunsafe_code = \"deny\"\ntrivial_numeric_casts = \"warn\"\nunused_import_braces = \"warn\"\nunused_lifetimes = \"warn\"\ntrivial_casts = \"allow\"\nunused_qualifications = \"allow\"\n\n[lints.rust.future_incompatible]\nlevel = \"warn\"\npriority = -1\n\n[lints.rust.nonstandard_style]\nlevel = \"warn\"\npriority = -1\n\n[lints.rust.rust_2018_idioms]\nlevel = \"warn\"\npriority = -1\n\n[lints.rust.unexpected_cfgs]\nlevel = \"warn\"\ncheck-cfg = [\"cfg(web_sys_unstable_apis)\"]\n\n[lints.rustdoc]\nall = \"warn\"\n\n[lints.clippy]\nallow_attributes = \"warn\"\nas_ptr_cast_mut = \"warn\"\nbranches_sharing_code = \"warn\"\nclear_with_drain = \"warn\"\nclone_on_ref_ptr = \"warn\"\ncoerce_container_to_any = \"warn\"\ndbg_macro = \"warn\"\ndebug_assert_with_mut_call = \"warn\"\ndefault_union_representation = \"warn\"\nderive_partial_eq_without_eq = \"warn\"\ndisallowed_script_idents = \"warn\"\ndoc_include_without_cfg = \"warn\"\nempty_enum_variants_with_brackets = \"warn\"\nequatable_if_let = \"warn\"\nexit = \"warn\"\nfallible_impl_from = \"warn\"\nfloat_cmp_const = \"warn\"\nfn_to_numeric_cast_any = \"warn\"\nget_unwrap = \"warn\"\nimprecise_flops = \"warn\"\ninfinite_loop = \"warn\"\niter_on_empty_collections = \"warn\"\niter_on_single_items = \"warn\"\niter_over_hash_type = \"warn\"\nlarge_include_file = \"warn\"\nlarge_stack_frames = \"warn\"\nliteral_string_with_formatting_args = \"warn\"\nlossy_float_literal = \"warn\"\nmap_err_ignore = \"warn\"\nmem_forget = \"warn\"\nmissing_assert_message = \"warn\"\nmutex_integer = \"warn\"\nneedless_pass_by_ref_mut = \"warn\"\nneedless_type_cast = \"warn\"\nnon_zero_suggestions = \"warn\"\nnonstandard_macro_braces = \"warn\"\nor_fun_call = \"warn\"\npath_buf_push_overwrite = \"warn\"\npathbuf_init_then_push = \"warn\"\nprecedence_bits = \"warn\"\nprint_stderr = \"warn\"\nprint_stdout = \"warn\"\npub_without_shorthand = \"warn\"\nrc_mutex = \"warn\"\nredundant_type_annotations = \"warn\"\nref_patterns = \"warn\"\nrest_pat_in_fully_bound_structs = \"warn\"\nreturn_and_then = \"warn\"\nset_contains_or_insert = \"warn\"\nsingle_option_map = \"warn\"\nstd_instead_of_core = \"warn\"\nstr_to_string = \"warn\"\nstring_add = \"warn\"\nstring_lit_as_bytes = \"warn\"\nstring_lit_chars_any = \"warn\"\nsuspicious_xor_used_as_pow = \"warn\"\ntodo = \"warn\"\ntoo_long_first_doc_paragraph = \"warn\"\ntrailing_empty_array = \"warn\"\ntrait_duplication_in_bounds = \"warn\"\ntuple_array_conversions = \"warn\"\nundocumented_unsafe_blocks = \"warn\"\nunimplemented = \"warn\"\nuninhabited_references = \"warn\"\nunnecessary_safety_comment = \"warn\"\nunnecessary_safety_doc = \"warn\"\nunnecessary_self_imports = \"warn\"\nunnecessary_struct_initialization = \"warn\"\nunused_peekable = \"warn\"\nunused_rounding = \"warn\"\nunused_trait_names = \"warn\"\nunwrap_used = \"warn\"\nuse_self = \"warn\"\nuseless_let_if_seq = \"warn\"\nverbose_file_reads = \"warn\"\ncast_lossless = \"allow\"\ncast_possible_truncation = \"allow\"\ncast_possible_wrap = \"allow\"\ncast_precision_loss = \"allow\"\ncast_sign_loss = \"allow\"\ncomparison_chain = \"allow\"\ndefault_trait_access = \"allow\"\nfloat_cmp = \"allow\"\ninline_always = \"allow\"\nitems_after_statements = \"allow\"\nmany_single_char_names = \"allow\"\nmissing_panics_doc = \"allow\"\nmust_use_candidate = \"allow\"\nredundant_closure_for_method_calls = \"allow\"\nreturn_self_not_must_use = \"allow\"\nshould_panic_without_expect = \"allow\"\nsimilar_names = \"allow\"\nstruct_excessive_bools = \"allow\"\nstruct_field_names = \"allow\"\ntoo_many_lines = \"allow\"\ntrivially_copy_pass_by_ref = \"allow\"\nunreadable_literal = \"allow\"\nused_underscore_binding = \"allow\"\nassigning_clones = \"allow\"\nmanual_range_contains = \"allow\"\nmap_unwrap_or = \"allow\"\nmultiple_crate_versions = \"allow\"\nwildcard_imports = \"allow\"\nlet_underscore_must_use = \"allow\"\nlet_underscore_untyped = \"allow\"\nself_named_module_files = \"allow\"\nsignificant_drop_tightening = \"allow\"\n\n[lints.clippy.all]\nlevel = \"warn\"\npriority = -1\n\n[lints.clippy.cargo]\nlevel = \"warn\"\npriority = -1\n\n[lints.clippy.pedantic]\nlevel = \"warn\"\npriority = -1\n\n[lib]\n\n[features]\ndefault = []\nbytemuck = [\"dep:bytemuck\", \"emath/bytemuck\", \"ecolor/bytemuck\"]\ncint = [\"ecolor/cint\"]\ncolor-hex = [\"ecolor/color-hex\"]\ncolor_fonts = [\"vello_cpu/png\", \"vello_cpu/text\"]\ndefault_fonts = [\"epaint_default_fonts\"]\nmint = [\"emath/mint\"]\nmonochrome_emoji_fonts = [\"default_fonts\", \"epaint_default_fonts/monochrome_emoji_fonts\"]\nrayon = [\"dep:rayon\"]\nserde = [\"dep:serde\", \"ahash/serde\", \"ecolor/serde\", \"emath/serde\", \"font-types/serde\", \"smallvec/serde\"]\nunity = []\n_override_unity = []\n\n[dependencies]\nharfrust = \"0.12.0\"\nnohash-hasher = \"0.2.0\"\nparking_lot = \"0.12.5\"\nself_cell = \"1.3\"\nsmallvec = \"1.16\"\nunicode-general-category = \"1.1\"\nunicode-segmentation = \"1.13\"\n\n[dependencies.emath]\nversion = \"0.37.0\"\npath = \"crates/emath\"\ndefault-features = false\n\n[dependencies.ecolor]\nversion = \"0.37.0\"\npath = \"crates/ecolor\"\ndefault-features = false\n\n[dependencies.ahash]\nversion = \"0.8.12\"\ndefault-features = false\nfeatures = [\"no-rng\", \"std\"]\n\n[dependencies.font-types]\nversion = \"0.12.4\"\ndefault-features = false\nfeatures = [\"std\"]\n\n[dependencies.log]\nversion = \"0.4.34\"\nfeatures = [\"std\"]\n\n[dependencies.profiling]\nversion = \"1.0\"\ndefault-features = false\n\n[dependencies.skrifa]\nversion = \"0.44.0\"\ndefault-features = false\nfeatures = [\"std\", \"autohint_shaping\"]\n\n[dependencies.unicode-bidi]\nversion = \"0.3.18\"\ndefault-features = false\nfeatures = [\"hardcoded-data\", \"std\"]\n\n[dependencies.unicode-properties]\nversion = \"0.1.4\"\ndefault-features = false\nfeatures = [\"emoji\"]\n\n[dependencies.vello_cpu]\nversion = \"0.2.0\"\ndefault-features = false\nfeatures = [\"std\", \"u8_pipeline\", \"f32_pipeline\"]\n\n[dependencies.bytemuck]\noptional = true\nfeatures = [\"derive\"]\nversion = \"1.25\"\n\n[dependencies.document-features]\noptional = true\nversion = \"0.2.12\"\n\n[dependencies.rayon]\noptional = true\nversion = \"1.12\"\n\n[dependencies.serde]\noptional = true\nfeatures = [\"derive\", \"rc\", \"derive\"]\nversion = \"1.0\"\n\n[dependencies.epaint_default_fonts]\noptional = true\nversion = \"0.37.0\"\npath = \"crates/epaint_default_fonts\"\n\n[dev-dependencies]\nmimalloc = \"0.1.52\"\nsimilar-asserts = \"2.0\"\n\n[dev-dependencies.criterion]\nversion = \"0.8.2\"\ndefault-features = false\n\n[target.\"cfg(not(target_arch = \\\"wasm32\\\"))\".dev-dependencies.vello_cpu]\nfeatures = [\"multithreading\", \"std\", \"u8_pipeline\", \"f32_pipeline\"]\nversion = \"0.2.0\"\ndefault-features = false\n\n[[bench]]\nname = \"benchmark\"\nharness = false\n", - "dest": "cargo/vendor/epaint", + "dest": "cargo/vendor-git/11e349eb0774eb3ab9192b38c47d748bf18abba91a0e3952d8f196513da96ee6/epaint", "dest-filename": "Cargo.toml" }, { "type": "inline", "contents": "{\"package\": null, \"files\": {}}", - "dest": "cargo/vendor/epaint", + "dest": "cargo/vendor-git/11e349eb0774eb3ab9192b38c47d748bf18abba91a0e3952d8f196513da96ee6/epaint", "dest-filename": ".cargo-checksum.json" }, { "type": "shell", "commands": [ - "cp -r --reflink=auto \"flatpak-cargo/git/egui-6d518fc/crates/epaint_default_fonts\" \"cargo/vendor/epaint_default_fonts\"" + "mkdir -p \"cargo/vendor-git/11e349eb0774eb3ab9192b38c47d748bf18abba91a0e3952d8f196513da96ee6\" && cp -r --reflink=auto \"flatpak-cargo/git/egui-6d518fc/crates/epaint_default_fonts\" \"cargo/vendor-git/11e349eb0774eb3ab9192b38c47d748bf18abba91a0e3952d8f196513da96ee6/epaint_default_fonts\"" ] }, { "type": "inline", "contents": "[package]\nname = \"epaint_default_fonts\"\nversion = \"0.37.0\"\nauthors = [\"Emil Ernerfeldt <emil.ernerfeldt@gmail.com>\"]\ndescription = \"Default fonts for use in epaint / egui\"\nedition = \"2024\"\nrust-version = \"1.95\"\nhomepage = \"https://github.com/emilk/egui/tree/main/crates/epaint_default_fonts\"\nlicense = \"(MIT OR Apache-2.0) AND OFL-1.1 AND Ubuntu-font-1.0\"\nreadme = \"README.md\"\nrepository = \"https://github.com/emilk/egui/tree/main/crates/epaint_default_fonts\"\ncategories = [\"graphics\", \"gui\"]\nkeywords = [\"graphics\", \"gui\", \"egui\"]\ninclude = [\"../../LICENSE-APACHE\", \"../../LICENSE-MIT\", \"**/*.rs\", \"Cargo.toml\", \"fonts/*.ttf\", \"fonts/*.txt\", \"fonts/OFL.txt\", \"fonts/UFL.txt\"]\n\n[package.metadata.docs.rs]\nall-features = true\nrustdoc-args = [\"--generate-link-to-definition\"]\n\n[lints.rust]\nunsafe_code = \"deny\"\ntrivial_numeric_casts = \"warn\"\nunused_import_braces = \"warn\"\nunused_lifetimes = \"warn\"\ntrivial_casts = \"allow\"\nunused_qualifications = \"allow\"\n\n[lints.rust.future_incompatible]\nlevel = \"warn\"\npriority = -1\n\n[lints.rust.nonstandard_style]\nlevel = \"warn\"\npriority = -1\n\n[lints.rust.rust_2018_idioms]\nlevel = \"warn\"\npriority = -1\n\n[lints.rust.unexpected_cfgs]\nlevel = \"warn\"\ncheck-cfg = [\"cfg(web_sys_unstable_apis)\"]\n\n[lints.rustdoc]\nall = \"warn\"\n\n[lints.clippy]\nallow_attributes = \"warn\"\nas_ptr_cast_mut = \"warn\"\nbranches_sharing_code = \"warn\"\nclear_with_drain = \"warn\"\nclone_on_ref_ptr = \"warn\"\ncoerce_container_to_any = \"warn\"\ndbg_macro = \"warn\"\ndebug_assert_with_mut_call = \"warn\"\ndefault_union_representation = \"warn\"\nderive_partial_eq_without_eq = \"warn\"\ndisallowed_script_idents = \"warn\"\ndoc_include_without_cfg = \"warn\"\nempty_enum_variants_with_brackets = \"warn\"\nequatable_if_let = \"warn\"\nexit = \"warn\"\nfallible_impl_from = \"warn\"\nfloat_cmp_const = \"warn\"\nfn_to_numeric_cast_any = \"warn\"\nget_unwrap = \"warn\"\nimprecise_flops = \"warn\"\ninfinite_loop = \"warn\"\niter_on_empty_collections = \"warn\"\niter_on_single_items = \"warn\"\niter_over_hash_type = \"warn\"\nlarge_include_file = \"warn\"\nlarge_stack_frames = \"warn\"\nliteral_string_with_formatting_args = \"warn\"\nlossy_float_literal = \"warn\"\nmap_err_ignore = \"warn\"\nmem_forget = \"warn\"\nmissing_assert_message = \"warn\"\nmutex_integer = \"warn\"\nneedless_pass_by_ref_mut = \"warn\"\nneedless_type_cast = \"warn\"\nnon_zero_suggestions = \"warn\"\nnonstandard_macro_braces = \"warn\"\nor_fun_call = \"warn\"\npath_buf_push_overwrite = \"warn\"\npathbuf_init_then_push = \"warn\"\nprecedence_bits = \"warn\"\nprint_stderr = \"warn\"\nprint_stdout = \"warn\"\npub_without_shorthand = \"warn\"\nrc_mutex = \"warn\"\nredundant_type_annotations = \"warn\"\nref_patterns = \"warn\"\nrest_pat_in_fully_bound_structs = \"warn\"\nreturn_and_then = \"warn\"\nset_contains_or_insert = \"warn\"\nsingle_option_map = \"warn\"\nstd_instead_of_core = \"warn\"\nstr_to_string = \"warn\"\nstring_add = \"warn\"\nstring_lit_as_bytes = \"warn\"\nstring_lit_chars_any = \"warn\"\nsuspicious_xor_used_as_pow = \"warn\"\ntodo = \"warn\"\ntoo_long_first_doc_paragraph = \"warn\"\ntrailing_empty_array = \"warn\"\ntrait_duplication_in_bounds = \"warn\"\ntuple_array_conversions = \"warn\"\nundocumented_unsafe_blocks = \"warn\"\nunimplemented = \"warn\"\nuninhabited_references = \"warn\"\nunnecessary_safety_comment = \"warn\"\nunnecessary_safety_doc = \"warn\"\nunnecessary_self_imports = \"warn\"\nunnecessary_struct_initialization = \"warn\"\nunused_peekable = \"warn\"\nunused_rounding = \"warn\"\nunused_trait_names = \"warn\"\nunwrap_used = \"warn\"\nuse_self = \"warn\"\nuseless_let_if_seq = \"warn\"\nverbose_file_reads = \"warn\"\ncast_lossless = \"allow\"\ncast_possible_truncation = \"allow\"\ncast_possible_wrap = \"allow\"\ncast_precision_loss = \"allow\"\ncast_sign_loss = \"allow\"\ncomparison_chain = \"allow\"\ndefault_trait_access = \"allow\"\nfloat_cmp = \"allow\"\ninline_always = \"allow\"\nitems_after_statements = \"allow\"\nmany_single_char_names = \"allow\"\nmissing_panics_doc = \"allow\"\nmust_use_candidate = \"allow\"\nredundant_closure_for_method_calls = \"allow\"\nreturn_self_not_must_use = \"allow\"\nshould_panic_without_expect = \"allow\"\nsimilar_names = \"allow\"\nstruct_excessive_bools = \"allow\"\nstruct_field_names = \"allow\"\ntoo_many_lines = \"allow\"\ntrivially_copy_pass_by_ref = \"allow\"\nunreadable_literal = \"allow\"\nused_underscore_binding = \"allow\"\nassigning_clones = \"allow\"\nmanual_range_contains = \"allow\"\nmap_unwrap_or = \"allow\"\nmultiple_crate_versions = \"allow\"\nwildcard_imports = \"allow\"\nlet_underscore_must_use = \"allow\"\nlet_underscore_untyped = \"allow\"\nself_named_module_files = \"allow\"\nsignificant_drop_tightening = \"allow\"\n\n[lints.clippy.all]\nlevel = \"warn\"\npriority = -1\n\n[lints.clippy.cargo]\nlevel = \"warn\"\npriority = -1\n\n[lints.clippy.pedantic]\nlevel = \"warn\"\npriority = -1\n\n[features]\ndefault = []\nmonochrome_emoji_fonts = []\n", - "dest": "cargo/vendor/epaint_default_fonts", + "dest": "cargo/vendor-git/11e349eb0774eb3ab9192b38c47d748bf18abba91a0e3952d8f196513da96ee6/epaint_default_fonts", "dest-filename": "Cargo.toml" }, { "type": "inline", "contents": "{\"package\": null, \"files\": {}}", - "dest": "cargo/vendor/epaint_default_fonts", + "dest": "cargo/vendor-git/11e349eb0774eb3ab9192b38c47d748bf18abba91a0e3952d8f196513da96ee6/epaint_default_fonts", "dest-filename": ".cargo-checksum.json" }, { @@ -9376,19 +9376,19 @@ { "type": "shell", "commands": [ - "cp -r --reflink=auto \"flatpak-cargo/git/winit-a517b38/.\" \"cargo/vendor/winit\"" + "mkdir -p \"cargo/vendor-git/9c7f809a50c4212d761a5b6359c5e4a02fcf86376d330a441c4ce9d112706ee9\" && cp -r --reflink=auto \"flatpak-cargo/git/winit-a517b38/.\" \"cargo/vendor-git/9c7f809a50c4212d761a5b6359c5e4a02fcf86376d330a441c4ce9d112706ee9/winit\"" ] }, { "type": "inline", "contents": "[package]\nname = \"winit\"\nversion = \"0.30.13\"\nauthors = [\"The winit contributors\", \"Pierre Krieger <pierre.krieger1708@gmail.com>\"]\ndescription = \"Cross-platform window creation library.\"\nkeywords = [\"windowing\"]\nreadme = \"README.md\"\ndocumentation = \"https://docs.rs/winit\"\ncategories = [\"gui\"]\nrust-version = \"1.70.0\"\nrepository = \"https://github.com/rust-windowing/winit\"\nlicense = \"Apache-2.0\"\nedition = \"2021\"\ninclude = [\"/build.rs\", \"/docs\", \"/examples\", \"/FEATURES.md\", \"/LICENSE\", \"/src\", \"!/src/platform_impl/web/script\", \"/src/platform_impl/web/script/**/*.min.js\", \"/tests\"]\n\n[package.metadata.docs.rs]\nfeatures = [\"rwh_04\", \"rwh_05\", \"rwh_06\", \"serde\", \"mint\", \"android-native-activity\"]\ntargets = [\"i686-pc-windows-msvc\", \"x86_64-pc-windows-msvc\", \"x86_64-apple-darwin\", \"i686-unknown-linux-gnu\", \"x86_64-unknown-linux-gnu\", \"x86_64-apple-ios\", \"aarch64-linux-android\", \"wasm32-unknown-unknown\"]\nrustdoc-args = [\"--cfg\", \"docsrs\"]\n\n[features]\ndefault = [\"rwh_06\", \"x11\", \"wayland\", \"wayland-dlopen\", \"wayland-csd-adwaita\"]\nx11 = [\"x11-dl\", \"bytemuck\", \"percent-encoding\", \"xkbcommon-dl/x11\", \"x11rb\"]\nwayland = [\"wayland-client\", \"wayland-backend\", \"wayland-protocols\", \"wayland-protocols-plasma\", \"sctk\", \"ahash\", \"memmap2\", \"percent-encoding\"]\nwayland-dlopen = [\"wayland-backend/dlopen\"]\nwayland-csd-adwaita = [\"sctk-adwaita\", \"sctk-adwaita/ab_glyph\"]\nwayland-csd-adwaita-crossfont = [\"sctk-adwaita\", \"sctk-adwaita/crossfont\"]\nwayland-csd-adwaita-notitle = [\"sctk-adwaita\"]\nandroid-native-activity = [\"android-activity/native-activity\"]\nandroid-game-activity = [\"android-activity/game-activity\"]\nserde = [\"dep:serde\", \"cursor-icon/serde\", \"smol_str/serde\", \"dpi/serde\"]\nmint = [\"dpi/mint\"]\nrwh_04 = [\"dep:rwh_04\", \"ndk/rwh_04\"]\nrwh_05 = [\"dep:rwh_05\", \"ndk/rwh_05\"]\nrwh_06 = [\"dep:rwh_06\", \"ndk/rwh_06\"]\n\n[build-dependencies]\ncfg_aliases = \"0.2.1\"\n\n[dependencies]\nbitflags = \"2\"\ncursor-icon = \"1.1.0\"\ndpi = \"0.1.1\"\nsmol_str = \"0.2.0\"\n\n[dependencies.rwh_04]\npackage = \"raw-window-handle\"\nversion = \"0.4\"\noptional = true\n\n[dependencies.rwh_05]\npackage = \"raw-window-handle\"\nversion = \"0.5.2\"\nfeatures = [\"std\"]\noptional = true\n\n[dependencies.rwh_06]\npackage = \"raw-window-handle\"\nversion = \"0.6\"\nfeatures = [\"std\"]\noptional = true\n\n[dependencies.serde]\noptional = true\nversion = \"1\"\nfeatures = [\"serde_derive\"]\n\n[dependencies.tracing]\nversion = \"0.1.40\"\ndefault-features = false\n\n[dev-dependencies.image]\nversion = \"0.25.0\"\ndefault-features = false\nfeatures = [\"png\"]\n\n[dev-dependencies.tracing]\nversion = \"0.1.40\"\ndefault-features = false\nfeatures = [\"log\"]\n\n[dev-dependencies.tracing-subscriber]\nversion = \"0.3.18\"\nfeatures = [\"env-filter\"]\n\n[dev-dependencies.winit]\npath = \".\"\nfeatures = [\"rwh_05\"]\n\n[target.\"cfg(not(any(target_os = \\\"android\\\", target_os = \\\"ios\\\")))\".dev-dependencies.softbuffer]\nversion = \"0.4.0\"\ndefault-features = false\nfeatures = [\"x11\", \"x11-dlopen\", \"wayland\", \"wayland-dlopen\"]\n\n[target.\"cfg(target_os = \\\"android\\\")\".dependencies]\nandroid-activity = \"0.6.0\"\n\n[target.\"cfg(target_os = \\\"android\\\")\".dependencies.ndk]\nversion = \"0.9.0\"\ndefault-features = false\n\n[target.\"cfg(any(target_os = \\\"ios\\\", target_os = \\\"macos\\\"))\".dependencies]\nblock2 = \"0.5.1\"\ncore-foundation = \"0.9.3\"\n\n[target.\"cfg(any(target_os = \\\"ios\\\", target_os = \\\"macos\\\"))\".dependencies.objc2]\nversion = \"0.5.2\"\nfeatures = [\"relax-sign-encoding\"]\n\n[target.\"cfg(target_os = \\\"macos\\\")\".dependencies]\ncore-graphics = \"0.23.1\"\n\n[target.\"cfg(target_os = \\\"macos\\\")\".dependencies.objc2-foundation]\nversion = \"0.2.2\"\nfeatures = [\"block2\", \"dispatch\", \"NSArray\", \"NSAttributedString\", \"NSData\", \"NSDictionary\", \"NSDistributedNotificationCenter\", \"NSEnumerator\", \"NSKeyValueObserving\", \"NSNotification\", \"NSObjCRuntime\", \"NSPathUtilities\", \"NSProcessInfo\", \"NSRunLoop\", \"NSString\", \"NSThread\", \"NSValue\"]\n\n[target.\"cfg(target_os = \\\"macos\\\")\".dependencies.objc2-app-kit]\nversion = \"0.2.2\"\nfeatures = [\"NSAppearance\", \"NSApplication\", \"NSBitmapImageRep\", \"NSButton\", \"NSColor\", \"NSControl\", \"NSCursor\", \"NSDragging\", \"NSEvent\", \"NSGraphics\", \"NSGraphicsContext\", \"NSImage\", \"NSImageRep\", \"NSMenu\", \"NSMenuItem\", \"NSOpenGLView\", \"NSPasteboard\", \"NSResponder\", \"NSRunningApplication\", \"NSScreen\", \"NSTextInputClient\", \"NSTextInputContext\", \"NSView\", \"NSWindow\", \"NSWindowScripting\", \"NSWindowTabGroup\"]\n\n[target.\"cfg(target_os = \\\"ios\\\")\".dependencies.objc2-foundation]\nversion = \"0.2.2\"\nfeatures = [\"block2\", \"dispatch\", \"NSArray\", \"NSEnumerator\", \"NSGeometry\", \"NSObjCRuntime\", \"NSOperation\", \"NSString\", \"NSProcessInfo\", \"NSThread\", \"NSSet\"]\n\n[target.\"cfg(target_os = \\\"ios\\\")\".dependencies.objc2-ui-kit]\nversion = \"0.2.2\"\nfeatures = [\"UIApplication\", \"UIDevice\", \"UIEvent\", \"UIGeometry\", \"UIGestureRecognizer\", \"UITextInput\", \"UITextInputTraits\", \"UIOrientation\", \"UIPanGestureRecognizer\", \"UIPinchGestureRecognizer\", \"UIResponder\", \"UIRotationGestureRecognizer\", \"UIScreen\", \"UIScreenMode\", \"UITapGestureRecognizer\", \"UITouch\", \"UITraitCollection\", \"UIView\", \"UIViewController\", \"UIWindow\"]\n\n[target.\"cfg(target_os = \\\"windows\\\")\".dependencies]\nunicode-segmentation = \"1.7.1\"\n\n[target.\"cfg(target_os = \\\"windows\\\")\".dependencies.windows-sys]\nversion = \"0.52.0\"\nfeatures = [\"Win32_Devices_HumanInterfaceDevice\", \"Win32_Foundation\", \"Win32_Globalization\", \"Win32_Graphics_Dwm\", \"Win32_Graphics_Gdi\", \"Win32_Media\", \"Win32_System_Com_StructuredStorage\", \"Win32_System_Com\", \"Win32_System_LibraryLoader\", \"Win32_System_Ole\", \"Win32_Security\", \"Win32_System_SystemInformation\", \"Win32_System_SystemServices\", \"Win32_System_Threading\", \"Win32_System_WindowsProgramming\", \"Win32_UI_Accessibility\", \"Win32_UI_Controls\", \"Win32_UI_HiDpi\", \"Win32_UI_Input_Ime\", \"Win32_UI_Input_KeyboardAndMouse\", \"Win32_UI_Input_Pointer\", \"Win32_UI_Input_Touch\", \"Win32_UI_Shell\", \"Win32_UI_TextServices\", \"Win32_UI_WindowsAndMessaging\"]\n\n[target.\"cfg(all(unix, not(any(target_os = \\\"redox\\\", target_family = \\\"wasm\\\", target_os = \\\"android\\\", target_os = \\\"ios\\\", target_os = \\\"macos\\\"))))\".dependencies]\ncalloop = \"0.13.0\"\nlibc = \"0.2.64\"\nxkbcommon-dl = \"0.4.2\"\n\n[target.\"cfg(all(unix, not(any(target_os = \\\"redox\\\", target_family = \\\"wasm\\\", target_os = \\\"android\\\", target_os = \\\"ios\\\", target_os = \\\"macos\\\"))))\".dependencies.ahash]\nversion = \"0.8.7\"\nfeatures = [\"no-rng\"]\noptional = true\n\n[target.\"cfg(all(unix, not(any(target_os = \\\"redox\\\", target_family = \\\"wasm\\\", target_os = \\\"android\\\", target_os = \\\"ios\\\", target_os = \\\"macos\\\"))))\".dependencies.bytemuck]\nversion = \"1.13.1\"\ndefault-features = false\noptional = true\n\n[target.\"cfg(all(unix, not(any(target_os = \\\"redox\\\", target_family = \\\"wasm\\\", target_os = \\\"android\\\", target_os = \\\"ios\\\", target_os = \\\"macos\\\"))))\".dependencies.memmap2]\nversion = \"0.9.0\"\noptional = true\n\n[target.\"cfg(all(unix, not(any(target_os = \\\"redox\\\", target_family = \\\"wasm\\\", target_os = \\\"android\\\", target_os = \\\"ios\\\", target_os = \\\"macos\\\"))))\".dependencies.percent-encoding]\nversion = \"2.0\"\noptional = true\n\n[target.\"cfg(all(unix, not(any(target_os = \\\"redox\\\", target_family = \\\"wasm\\\", target_os = \\\"android\\\", target_os = \\\"ios\\\", target_os = \\\"macos\\\"))))\".dependencies.rustix]\nversion = \"0.38.4\"\ndefault-features = false\nfeatures = [\"std\", \"system\", \"thread\", \"process\", \"event\", \"fs\", \"pipe\"]\n\n[target.\"cfg(all(unix, not(any(target_os = \\\"redox\\\", target_family = \\\"wasm\\\", target_os = \\\"android\\\", target_os = \\\"ios\\\", target_os = \\\"macos\\\"))))\".dependencies.sctk]\npackage = \"smithay-client-toolkit\"\nversion = \"0.19.2\"\ndefault-features = false\nfeatures = [\"calloop\"]\noptional = true\n\n[target.\"cfg(all(unix, not(any(target_os = \\\"redox\\\", target_family = \\\"wasm\\\", target_os = \\\"android\\\", target_os = \\\"ios\\\", target_os = \\\"macos\\\"))))\".dependencies.sctk-adwaita]\nversion = \"0.10.1\"\ndefault-features = false\noptional = true\n\n[target.\"cfg(all(unix, not(any(target_os = \\\"redox\\\", target_family = \\\"wasm\\\", target_os = \\\"android\\\", target_os = \\\"ios\\\", target_os = \\\"macos\\\"))))\".dependencies.wayland-backend]\nversion = \"0.3.10\"\ndefault-features = false\nfeatures = [\"client_system\"]\noptional = true\n\n[target.\"cfg(all(unix, not(any(target_os = \\\"redox\\\", target_family = \\\"wasm\\\", target_os = \\\"android\\\", target_os = \\\"ios\\\", target_os = \\\"macos\\\"))))\".dependencies.wayland-client]\nversion = \"0.31.10\"\noptional = true\n\n[target.\"cfg(all(unix, not(any(target_os = \\\"redox\\\", target_family = \\\"wasm\\\", target_os = \\\"android\\\", target_os = \\\"ios\\\", target_os = \\\"macos\\\"))))\".dependencies.wayland-protocols]\nversion = \"0.32.8\"\nfeatures = [\"staging\"]\noptional = true\n\n[target.\"cfg(all(unix, not(any(target_os = \\\"redox\\\", target_family = \\\"wasm\\\", target_os = \\\"android\\\", target_os = \\\"ios\\\", target_os = \\\"macos\\\"))))\".dependencies.wayland-protocols-plasma]\nversion = \"0.3.8\"\nfeatures = [\"client\"]\noptional = true\n\n[target.\"cfg(all(unix, not(any(target_os = \\\"redox\\\", target_family = \\\"wasm\\\", target_os = \\\"android\\\", target_os = \\\"ios\\\", target_os = \\\"macos\\\"))))\".dependencies.x11-dl]\nversion = \"2.19.1\"\noptional = true\n\n[target.\"cfg(all(unix, not(any(target_os = \\\"redox\\\", target_family = \\\"wasm\\\", target_os = \\\"android\\\", target_os = \\\"ios\\\", target_os = \\\"macos\\\"))))\".dependencies.x11rb]\nversion = \"0.13.0\"\ndefault-features = false\nfeatures = [\"allow-unsafe-code\", \"dl-libxcb\", \"randr\", \"resource_manager\", \"xinput\", \"xkb\"]\noptional = true\n\n[target.\"cfg(target_os = \\\"redox\\\")\".dependencies]\nredox_syscall = \"0.4.1\"\n\n[target.\"cfg(target_os = \\\"redox\\\")\".dependencies.orbclient]\nversion = \"0.3.47\"\ndefault-features = false\n\n[target.\"cfg(target_family = \\\"wasm\\\")\".dependencies]\njs-sys = \"0.3.70\"\npin-project = \"1\"\nwasm-bindgen = \"0.2.93\"\nwasm-bindgen-futures = \"0.4.43\"\nweb-time = \"1\"\n\n[target.\"cfg(target_family = \\\"wasm\\\")\".dependencies.web_sys]\npackage = \"web-sys\"\nversion = \"0.3.70\"\nfeatures = [\"AbortController\", \"AbortSignal\", \"Blob\", \"BlobPropertyBag\", \"console\", \"CssStyleDeclaration\", \"Document\", \"DomException\", \"DomRect\", \"DomRectReadOnly\", \"Element\", \"Event\", \"EventTarget\", \"FocusEvent\", \"HtmlCanvasElement\", \"HtmlElement\", \"HtmlImageElement\", \"ImageBitmap\", \"ImageBitmapOptions\", \"ImageBitmapRenderingContext\", \"ImageData\", \"IntersectionObserver\", \"IntersectionObserverEntry\", \"KeyboardEvent\", \"MediaQueryList\", \"MessageChannel\", \"MessagePort\", \"Navigator\", \"Node\", \"OrientationLockType\", \"OrientationType\", \"PageTransitionEvent\", \"Permissions\", \"PermissionState\", \"PermissionStatus\", \"PointerEvent\", \"PremultiplyAlpha\", \"ResizeObserver\", \"ResizeObserverBoxOptions\", \"ResizeObserverEntry\", \"ResizeObserverOptions\", \"ResizeObserverSize\", \"Screen\", \"ScreenOrientation\", \"Url\", \"VisibilityState\", \"WheelEvent\", \"Window\", \"Worker\"]\n\n[target.\"cfg(target_family = \\\"wasm\\\")\".dev-dependencies]\nconsole_error_panic_hook = \"0.1\"\ntracing-web = \"0.1\"\n\n[target.\"cfg(all(target_family = \\\"wasm\\\", target_feature = \\\"atomics\\\"))\".dependencies]\natomic-waker = \"1\"\n\n[target.\"cfg(all(target_family = \\\"wasm\\\", target_feature = \\\"atomics\\\"))\".dependencies.concurrent-queue]\nversion = \"2\"\ndefault-features = false\n\n[[example]]\ndoc-scrape-examples = true\nname = \"window\"\n\n[workspace]\nresolver = \"2\"\nmembers = [\"dpi\"]\n\n[workspace.package]\nrust-version = \"1.70.0\"\nrepository = \"https://github.com/rust-windowing/winit\"\nlicense = \"Apache-2.0\"\nedition = \"2021\"\n\n[workspace.dependencies]\nmint = \"0.5.6\"\n\n[workspace.dependencies.serde]\nversion = \"1\"\nfeatures = [\"serde_derive\"]\n\n[[test]]\nname = \"macos_termination\"\npath = \"tests/macos_termination.rs\"\nharness = false\n\n[[test]]\nname = \"ime_reset_dispatch\"\npath = \"tests/ime_reset_dispatch.rs\"\nharness = false\n", - "dest": "cargo/vendor/winit", + "dest": "cargo/vendor-git/9c7f809a50c4212d761a5b6359c5e4a02fcf86376d330a441c4ce9d112706ee9/winit", "dest-filename": "Cargo.toml" }, { "type": "inline", "contents": "{\"package\": null, \"files\": {}}", - "dest": "cargo/vendor/winit", + "dest": "cargo/vendor-git/9c7f809a50c4212d761a5b6359c5e4a02fcf86376d330a441c4ce9d112706ee9/winit", "dest-filename": ".cargo-checksum.json" }, { @@ -10018,60 +10018,60 @@ { "type": "shell", "commands": [ - "cp -r --reflink=auto \"flatpak-cargo/git/egui-6d518fc/crates/egui_demo_lib\" \"cargo/vendor/egui_demo_lib\"" + "mkdir -p \"cargo/vendor-git/11e349eb0774eb3ab9192b38c47d748bf18abba91a0e3952d8f196513da96ee6\" && cp -r --reflink=auto \"flatpak-cargo/git/egui-6d518fc/crates/egui_demo_lib\" \"cargo/vendor-git/11e349eb0774eb3ab9192b38c47d748bf18abba91a0e3952d8f196513da96ee6/egui_demo_lib\"" ] }, { "type": "inline", "contents": "[package]\nname = \"egui_demo_lib\"\nversion = \"0.37.0\"\nauthors = [\"Emil Ernerfeldt <emil.ernerfeldt@gmail.com>\"]\ndescription = \"Example library for egui\"\nedition = \"2024\"\nrust-version = \"1.95\"\nhomepage = \"https://github.com/emilk/egui/tree/main/crates/egui_demo_lib\"\nlicense = \"MIT OR Apache-2.0\"\nreadme = \"README.md\"\nrepository = \"https://github.com/emilk/egui/tree/main/crates/egui_demo_lib\"\ncategories = [\"gui\", \"graphics\"]\nkeywords = [\"glow\", \"egui\", \"gui\", \"gamedev\"]\ninclude = [\"../../LICENSE-APACHE\", \"../../LICENSE-MIT\", \"**/*.rs\", \"Cargo.toml\", \"data/*\"]\n\n[package.metadata.docs.rs]\nall-features = true\nrustdoc-args = [\"--generate-link-to-definition\"]\n\n[package.metadata.cargo-shear]\nignored = [\"image\"]\n\n[lints.rust]\nunsafe_code = \"deny\"\ntrivial_numeric_casts = \"warn\"\nunused_import_braces = \"warn\"\nunused_lifetimes = \"warn\"\ntrivial_casts = \"allow\"\nunused_qualifications = \"allow\"\n\n[lints.rust.future_incompatible]\nlevel = \"warn\"\npriority = -1\n\n[lints.rust.nonstandard_style]\nlevel = \"warn\"\npriority = -1\n\n[lints.rust.rust_2018_idioms]\nlevel = \"warn\"\npriority = -1\n\n[lints.rust.unexpected_cfgs]\nlevel = \"warn\"\ncheck-cfg = [\"cfg(web_sys_unstable_apis)\"]\n\n[lints.rustdoc]\nall = \"warn\"\n\n[lints.clippy]\nallow_attributes = \"warn\"\nas_ptr_cast_mut = \"warn\"\nbranches_sharing_code = \"warn\"\nclear_with_drain = \"warn\"\nclone_on_ref_ptr = \"warn\"\ncoerce_container_to_any = \"warn\"\ndbg_macro = \"warn\"\ndebug_assert_with_mut_call = \"warn\"\ndefault_union_representation = \"warn\"\nderive_partial_eq_without_eq = \"warn\"\ndisallowed_script_idents = \"warn\"\ndoc_include_without_cfg = \"warn\"\nempty_enum_variants_with_brackets = \"warn\"\nequatable_if_let = \"warn\"\nexit = \"warn\"\nfallible_impl_from = \"warn\"\nfloat_cmp_const = \"warn\"\nfn_to_numeric_cast_any = \"warn\"\nget_unwrap = \"warn\"\nimprecise_flops = \"warn\"\ninfinite_loop = \"warn\"\niter_on_empty_collections = \"warn\"\niter_on_single_items = \"warn\"\niter_over_hash_type = \"warn\"\nlarge_include_file = \"warn\"\nlarge_stack_frames = \"warn\"\nliteral_string_with_formatting_args = \"warn\"\nlossy_float_literal = \"warn\"\nmap_err_ignore = \"warn\"\nmem_forget = \"warn\"\nmissing_assert_message = \"warn\"\nmutex_integer = \"warn\"\nneedless_pass_by_ref_mut = \"warn\"\nneedless_type_cast = \"warn\"\nnon_zero_suggestions = \"warn\"\nnonstandard_macro_braces = \"warn\"\nor_fun_call = \"warn\"\npath_buf_push_overwrite = \"warn\"\npathbuf_init_then_push = \"warn\"\nprecedence_bits = \"warn\"\nprint_stderr = \"warn\"\nprint_stdout = \"warn\"\npub_without_shorthand = \"warn\"\nrc_mutex = \"warn\"\nredundant_type_annotations = \"warn\"\nref_patterns = \"warn\"\nrest_pat_in_fully_bound_structs = \"warn\"\nreturn_and_then = \"warn\"\nset_contains_or_insert = \"warn\"\nsingle_option_map = \"warn\"\nstd_instead_of_core = \"warn\"\nstr_to_string = \"warn\"\nstring_add = \"warn\"\nstring_lit_as_bytes = \"warn\"\nstring_lit_chars_any = \"warn\"\nsuspicious_xor_used_as_pow = \"warn\"\ntodo = \"warn\"\ntoo_long_first_doc_paragraph = \"warn\"\ntrailing_empty_array = \"warn\"\ntrait_duplication_in_bounds = \"warn\"\ntuple_array_conversions = \"warn\"\nundocumented_unsafe_blocks = \"warn\"\nunimplemented = \"warn\"\nuninhabited_references = \"warn\"\nunnecessary_safety_comment = \"warn\"\nunnecessary_safety_doc = \"warn\"\nunnecessary_self_imports = \"warn\"\nunnecessary_struct_initialization = \"warn\"\nunused_peekable = \"warn\"\nunused_rounding = \"warn\"\nunused_trait_names = \"warn\"\nunwrap_used = \"warn\"\nuse_self = \"warn\"\nuseless_let_if_seq = \"warn\"\nverbose_file_reads = \"warn\"\ncast_lossless = \"allow\"\ncast_possible_truncation = \"allow\"\ncast_possible_wrap = \"allow\"\ncast_precision_loss = \"allow\"\ncast_sign_loss = \"allow\"\ncomparison_chain = \"allow\"\ndefault_trait_access = \"allow\"\nfloat_cmp = \"allow\"\ninline_always = \"allow\"\nitems_after_statements = \"allow\"\nmany_single_char_names = \"allow\"\nmissing_panics_doc = \"allow\"\nmust_use_candidate = \"allow\"\nredundant_closure_for_method_calls = \"allow\"\nreturn_self_not_must_use = \"allow\"\nshould_panic_without_expect = \"allow\"\nsimilar_names = \"allow\"\nstruct_excessive_bools = \"allow\"\nstruct_field_names = \"allow\"\ntoo_many_lines = \"allow\"\ntrivially_copy_pass_by_ref = \"allow\"\nunreadable_literal = \"allow\"\nused_underscore_binding = \"allow\"\nassigning_clones = \"allow\"\nmanual_range_contains = \"allow\"\nmap_unwrap_or = \"allow\"\nmultiple_crate_versions = \"allow\"\nwildcard_imports = \"allow\"\nlet_underscore_must_use = \"allow\"\nlet_underscore_untyped = \"allow\"\nself_named_module_files = \"allow\"\nsignificant_drop_tightening = \"allow\"\n\n[lints.clippy.all]\nlevel = \"warn\"\npriority = -1\n\n[lints.clippy.cargo]\nlevel = \"warn\"\npriority = -1\n\n[lints.clippy.pedantic]\nlevel = \"warn\"\npriority = -1\n\n[lib]\n\n[features]\ndefault = []\njiff = [\"egui_extras/datepicker\", \"dep:jiff\"]\nserde = [\"egui/serde\", \"dep:serde\", \"egui_extras/serde\"]\nsyntect = [\"egui_extras/syntect\"]\n\n[dependencies.egui]\ndefault-features = false\nfeatures = [\"color-hex\", \"default_fonts\"]\nversion = \"0.37.0\"\npath = \"crates/egui\"\n\n[dependencies.egui_extras]\nfeatures = [\"image\", \"svg\"]\nversion = \"0.37.0\"\npath = \"crates/egui_extras\"\ndefault-features = false\n\n[dependencies.log]\nversion = \"0.4.34\"\nfeatures = [\"std\"]\n\n[dependencies.unicode_names2]\nversion = \"3.1\"\ndefault-features = false\n\n[dependencies.jiff]\noptional = true\nfeatures = [\"std\", \"js\"]\nversion = \"0.2.35\"\ndefault-features = false\n\n[dependencies.document-features]\noptional = true\nversion = \"0.2.12\"\n\n[dependencies.serde]\noptional = true\nversion = \"1.0\"\nfeatures = [\"derive\"]\n\n[dev-dependencies]\nmimalloc = \"0.1.52\"\nrand = \"0.10.2\"\n\n[dev-dependencies.criterion]\nversion = \"0.8.2\"\ndefault-features = false\n\n[dev-dependencies.egui]\nfeatures = [\"default_fonts\", \"monochrome_emoji_fonts\"]\nversion = \"0.37.0\"\npath = \"crates/egui\"\ndefault-features = false\n\n[dev-dependencies.egui_extras]\nfeatures = [\"image\", \"svg\"]\nversion = \"0.37.0\"\npath = \"crates/egui_extras\"\ndefault-features = false\n\n[dev-dependencies.egui_kittest]\nfeatures = [\"wgpu\", \"snapshot\"]\nversion = \"0.37.0\"\npath = \"crates/egui_kittest\"\ndefault-features = false\n\n[dev-dependencies.image]\nfeatures = [\"png\"]\nversion = \"0.25.10\"\ndefault-features = false\n\n[[bench]]\nname = \"benchmark\"\nharness = false\n", - "dest": "cargo/vendor/egui_demo_lib", + "dest": "cargo/vendor-git/11e349eb0774eb3ab9192b38c47d748bf18abba91a0e3952d8f196513da96ee6/egui_demo_lib", "dest-filename": "Cargo.toml" }, { "type": "inline", "contents": "{\"package\": null, \"files\": {}}", - "dest": "cargo/vendor/egui_demo_lib", + "dest": "cargo/vendor-git/11e349eb0774eb3ab9192b38c47d748bf18abba91a0e3952d8f196513da96ee6/egui_demo_lib", "dest-filename": ".cargo-checksum.json" }, { "type": "shell", "commands": [ - "cp -r --reflink=auto \"flatpak-cargo/git/egui-6d518fc/crates/egui_inspection\" \"cargo/vendor/egui_inspection\"" + "mkdir -p \"cargo/vendor-git/11e349eb0774eb3ab9192b38c47d748bf18abba91a0e3952d8f196513da96ee6\" && cp -r --reflink=auto \"flatpak-cargo/git/egui-6d518fc/crates/egui_inspection\" \"cargo/vendor-git/11e349eb0774eb3ab9192b38c47d748bf18abba91a0e3952d8f196513da96ee6/egui_inspection\"" ] }, { "type": "inline", "contents": "[package]\nname = \"egui_inspection\"\nversion = \"0.37.0\"\nauthors = [\"Lucas Meurer <hi@lucasmerlin.me>\", \"Emil Ernerfeldt <emil.ernerfeldt@gmail.com>\"]\ndescription = \"Protocol and egui::Plugin for inspection of egui apps\"\nedition = \"2024\"\nrust-version = \"1.95\"\nhomepage = \"https://github.com/emilk/egui\"\nlicense = \"MIT OR Apache-2.0\"\nreadme = \"./README.md\"\nrepository = \"https://github.com/emilk/egui\"\ncategories = [\"gui\", \"development-tools::testing\", \"accessibility\"]\nkeywords = [\"gui\", \"egui\", \"inspector\", \"accesskit\", \"mcp\"]\ninclude = [\"../../LICENSE-APACHE\", \"../../LICENSE-MIT\", \"**/*.rs\", \"Cargo.toml\"]\n\n[package.metadata.docs.rs]\nall-features = true\nrustdoc-args = [\"--generate-link-to-definition\"]\n\n[features]\ndefault = []\npng = [\"dep:image\", \"image/png\", \"egui/bytemuck\"]\nplugin = [\"png\", \"dep:log\"]\n\n[dependencies]\nserde_bytes = \"0.11.19\"\nrmp-serde = \"1.3\"\n\n[dependencies.egui]\nfeatures = [\"serde\"]\nversion = \"0.37.0\"\npath = \"crates/egui\"\ndefault-features = false\n\n[dependencies.serde]\nversion = \"1.0\"\nfeatures = [\"derive\"]\n\n[dependencies.image]\noptional = true\nversion = \"0.25.10\"\ndefault-features = false\n\n[dependencies.log]\noptional = true\nversion = \"0.4.34\"\nfeatures = [\"std\"]\n\n[dependencies.document-features]\noptional = true\nversion = \"0.2.12\"\n\n[lints.rust]\nunsafe_code = \"deny\"\ntrivial_numeric_casts = \"warn\"\nunused_import_braces = \"warn\"\nunused_lifetimes = \"warn\"\ntrivial_casts = \"allow\"\nunused_qualifications = \"allow\"\n\n[lints.rust.future_incompatible]\nlevel = \"warn\"\npriority = -1\n\n[lints.rust.nonstandard_style]\nlevel = \"warn\"\npriority = -1\n\n[lints.rust.rust_2018_idioms]\nlevel = \"warn\"\npriority = -1\n\n[lints.rust.unexpected_cfgs]\nlevel = \"warn\"\ncheck-cfg = [\"cfg(web_sys_unstable_apis)\"]\n\n[lints.rustdoc]\nall = \"warn\"\n\n[lints.clippy]\nallow_attributes = \"warn\"\nas_ptr_cast_mut = \"warn\"\nbranches_sharing_code = \"warn\"\nclear_with_drain = \"warn\"\nclone_on_ref_ptr = \"warn\"\ncoerce_container_to_any = \"warn\"\ndbg_macro = \"warn\"\ndebug_assert_with_mut_call = \"warn\"\ndefault_union_representation = \"warn\"\nderive_partial_eq_without_eq = \"warn\"\ndisallowed_script_idents = \"warn\"\ndoc_include_without_cfg = \"warn\"\nempty_enum_variants_with_brackets = \"warn\"\nequatable_if_let = \"warn\"\nexit = \"warn\"\nfallible_impl_from = \"warn\"\nfloat_cmp_const = \"warn\"\nfn_to_numeric_cast_any = \"warn\"\nget_unwrap = \"warn\"\nimprecise_flops = \"warn\"\ninfinite_loop = \"warn\"\niter_on_empty_collections = \"warn\"\niter_on_single_items = \"warn\"\niter_over_hash_type = \"warn\"\nlarge_include_file = \"warn\"\nlarge_stack_frames = \"warn\"\nliteral_string_with_formatting_args = \"warn\"\nlossy_float_literal = \"warn\"\nmap_err_ignore = \"warn\"\nmem_forget = \"warn\"\nmissing_assert_message = \"warn\"\nmutex_integer = \"warn\"\nneedless_pass_by_ref_mut = \"warn\"\nneedless_type_cast = \"warn\"\nnon_zero_suggestions = \"warn\"\nnonstandard_macro_braces = \"warn\"\nor_fun_call = \"warn\"\npath_buf_push_overwrite = \"warn\"\npathbuf_init_then_push = \"warn\"\nprecedence_bits = \"warn\"\nprint_stderr = \"warn\"\nprint_stdout = \"warn\"\npub_without_shorthand = \"warn\"\nrc_mutex = \"warn\"\nredundant_type_annotations = \"warn\"\nref_patterns = \"warn\"\nrest_pat_in_fully_bound_structs = \"warn\"\nreturn_and_then = \"warn\"\nset_contains_or_insert = \"warn\"\nsingle_option_map = \"warn\"\nstd_instead_of_core = \"warn\"\nstr_to_string = \"warn\"\nstring_add = \"warn\"\nstring_lit_as_bytes = \"warn\"\nstring_lit_chars_any = \"warn\"\nsuspicious_xor_used_as_pow = \"warn\"\ntodo = \"warn\"\ntoo_long_first_doc_paragraph = \"warn\"\ntrailing_empty_array = \"warn\"\ntrait_duplication_in_bounds = \"warn\"\ntuple_array_conversions = \"warn\"\nundocumented_unsafe_blocks = \"warn\"\nunimplemented = \"warn\"\nuninhabited_references = \"warn\"\nunnecessary_safety_comment = \"warn\"\nunnecessary_safety_doc = \"warn\"\nunnecessary_self_imports = \"warn\"\nunnecessary_struct_initialization = \"warn\"\nunused_peekable = \"warn\"\nunused_rounding = \"warn\"\nunused_trait_names = \"warn\"\nunwrap_used = \"warn\"\nuse_self = \"warn\"\nuseless_let_if_seq = \"warn\"\nverbose_file_reads = \"warn\"\ncast_lossless = \"allow\"\ncast_possible_truncation = \"allow\"\ncast_possible_wrap = \"allow\"\ncast_precision_loss = \"allow\"\ncast_sign_loss = \"allow\"\ncomparison_chain = \"allow\"\ndefault_trait_access = \"allow\"\nfloat_cmp = \"allow\"\ninline_always = \"allow\"\nitems_after_statements = \"allow\"\nmany_single_char_names = \"allow\"\nmissing_panics_doc = \"allow\"\nmust_use_candidate = \"allow\"\nredundant_closure_for_method_calls = \"allow\"\nreturn_self_not_must_use = \"allow\"\nshould_panic_without_expect = \"allow\"\nsimilar_names = \"allow\"\nstruct_excessive_bools = \"allow\"\nstruct_field_names = \"allow\"\ntoo_many_lines = \"allow\"\ntrivially_copy_pass_by_ref = \"allow\"\nunreadable_literal = \"allow\"\nused_underscore_binding = \"allow\"\nassigning_clones = \"allow\"\nmanual_range_contains = \"allow\"\nmap_unwrap_or = \"allow\"\nmultiple_crate_versions = \"allow\"\nwildcard_imports = \"allow\"\nlet_underscore_must_use = \"allow\"\nlet_underscore_untyped = \"allow\"\nself_named_module_files = \"allow\"\nsignificant_drop_tightening = \"allow\"\n\n[lints.clippy.all]\nlevel = \"warn\"\npriority = -1\n\n[lints.clippy.cargo]\nlevel = \"warn\"\npriority = -1\n\n[lints.clippy.pedantic]\nlevel = \"warn\"\npriority = -1\n", - "dest": "cargo/vendor/egui_inspection", + "dest": "cargo/vendor-git/11e349eb0774eb3ab9192b38c47d748bf18abba91a0e3952d8f196513da96ee6/egui_inspection", "dest-filename": "Cargo.toml" }, { "type": "inline", "contents": "{\"package\": null, \"files\": {}}", - "dest": "cargo/vendor/egui_inspection", + "dest": "cargo/vendor-git/11e349eb0774eb3ab9192b38c47d748bf18abba91a0e3952d8f196513da96ee6/egui_inspection", "dest-filename": ".cargo-checksum.json" }, { "type": "shell", "commands": [ - "cp -r --reflink=auto \"flatpak-cargo/git/egui-6d518fc/crates/egui_system_font_provider\" \"cargo/vendor/egui_system_font_provider\"" + "mkdir -p \"cargo/vendor-git/11e349eb0774eb3ab9192b38c47d748bf18abba91a0e3952d8f196513da96ee6\" && cp -r --reflink=auto \"flatpak-cargo/git/egui-6d518fc/crates/egui_system_font_provider\" \"cargo/vendor-git/11e349eb0774eb3ab9192b38c47d748bf18abba91a0e3952d8f196513da96ee6/egui_system_font_provider\"" ] }, { "type": "inline", "contents": "[package]\nname = \"egui_system_font_provider\"\nversion = \"0.37.0\"\nauthors = [\"Emil Ernerfeldt <emil.ernerfeldt@gmail.com>\"]\ndescription = \"Load system fonts on demand for characters the egui fonts lack\"\nedition = \"2024\"\nrust-version = \"1.95\"\nhomepage = \"https://github.com/emilk/egui/tree/main/crates/egui_system_font_provider\"\nlicense = \"MIT OR Apache-2.0\"\nreadme = \"README.md\"\nrepository = \"https://github.com/emilk/egui/tree/main/crates/egui_system_font_provider\"\ncategories = [\"gui\"]\nkeywords = [\"egui\", \"gui\", \"fonts\", \"text\"]\ninclude = [\"../../LICENSE-APACHE\", \"../../LICENSE-MIT\", \"**/*.rs\", \"Cargo.toml\"]\n\n[package.metadata.docs.rs]\nall-features = true\nrustdoc-args = [\"--generate-link-to-definition\"]\n\n[lints.rust]\nunsafe_code = \"deny\"\ntrivial_numeric_casts = \"warn\"\nunused_import_braces = \"warn\"\nunused_lifetimes = \"warn\"\ntrivial_casts = \"allow\"\nunused_qualifications = \"allow\"\n\n[lints.rust.future_incompatible]\nlevel = \"warn\"\npriority = -1\n\n[lints.rust.nonstandard_style]\nlevel = \"warn\"\npriority = -1\n\n[lints.rust.rust_2018_idioms]\nlevel = \"warn\"\npriority = -1\n\n[lints.rust.unexpected_cfgs]\nlevel = \"warn\"\ncheck-cfg = [\"cfg(web_sys_unstable_apis)\"]\n\n[lints.rustdoc]\nall = \"warn\"\n\n[lints.clippy]\nallow_attributes = \"warn\"\nas_ptr_cast_mut = \"warn\"\nbranches_sharing_code = \"warn\"\nclear_with_drain = \"warn\"\nclone_on_ref_ptr = \"warn\"\ncoerce_container_to_any = \"warn\"\ndbg_macro = \"warn\"\ndebug_assert_with_mut_call = \"warn\"\ndefault_union_representation = \"warn\"\nderive_partial_eq_without_eq = \"warn\"\ndisallowed_script_idents = \"warn\"\ndoc_include_without_cfg = \"warn\"\nempty_enum_variants_with_brackets = \"warn\"\nequatable_if_let = \"warn\"\nexit = \"warn\"\nfallible_impl_from = \"warn\"\nfloat_cmp_const = \"warn\"\nfn_to_numeric_cast_any = \"warn\"\nget_unwrap = \"warn\"\nimprecise_flops = \"warn\"\ninfinite_loop = \"warn\"\niter_on_empty_collections = \"warn\"\niter_on_single_items = \"warn\"\niter_over_hash_type = \"warn\"\nlarge_include_file = \"warn\"\nlarge_stack_frames = \"warn\"\nliteral_string_with_formatting_args = \"warn\"\nlossy_float_literal = \"warn\"\nmap_err_ignore = \"warn\"\nmem_forget = \"warn\"\nmissing_assert_message = \"warn\"\nmutex_integer = \"warn\"\nneedless_pass_by_ref_mut = \"warn\"\nneedless_type_cast = \"warn\"\nnon_zero_suggestions = \"warn\"\nnonstandard_macro_braces = \"warn\"\nor_fun_call = \"warn\"\npath_buf_push_overwrite = \"warn\"\npathbuf_init_then_push = \"warn\"\nprecedence_bits = \"warn\"\nprint_stderr = \"warn\"\nprint_stdout = \"warn\"\npub_without_shorthand = \"warn\"\nrc_mutex = \"warn\"\nredundant_type_annotations = \"warn\"\nref_patterns = \"warn\"\nrest_pat_in_fully_bound_structs = \"warn\"\nreturn_and_then = \"warn\"\nset_contains_or_insert = \"warn\"\nsingle_option_map = \"warn\"\nstd_instead_of_core = \"warn\"\nstr_to_string = \"warn\"\nstring_add = \"warn\"\nstring_lit_as_bytes = \"warn\"\nstring_lit_chars_any = \"warn\"\nsuspicious_xor_used_as_pow = \"warn\"\ntodo = \"warn\"\ntoo_long_first_doc_paragraph = \"warn\"\ntrailing_empty_array = \"warn\"\ntrait_duplication_in_bounds = \"warn\"\ntuple_array_conversions = \"warn\"\nundocumented_unsafe_blocks = \"warn\"\nunimplemented = \"warn\"\nuninhabited_references = \"warn\"\nunnecessary_safety_comment = \"warn\"\nunnecessary_safety_doc = \"warn\"\nunnecessary_self_imports = \"warn\"\nunnecessary_struct_initialization = \"warn\"\nunused_peekable = \"warn\"\nunused_rounding = \"warn\"\nunused_trait_names = \"warn\"\nunwrap_used = \"warn\"\nuse_self = \"warn\"\nuseless_let_if_seq = \"warn\"\nverbose_file_reads = \"warn\"\ncast_lossless = \"allow\"\ncast_possible_truncation = \"allow\"\ncast_possible_wrap = \"allow\"\ncast_precision_loss = \"allow\"\ncast_sign_loss = \"allow\"\ncomparison_chain = \"allow\"\ndefault_trait_access = \"allow\"\nfloat_cmp = \"allow\"\ninline_always = \"allow\"\nitems_after_statements = \"allow\"\nmany_single_char_names = \"allow\"\nmissing_panics_doc = \"allow\"\nmust_use_candidate = \"allow\"\nredundant_closure_for_method_calls = \"allow\"\nreturn_self_not_must_use = \"allow\"\nshould_panic_without_expect = \"allow\"\nsimilar_names = \"allow\"\nstruct_excessive_bools = \"allow\"\nstruct_field_names = \"allow\"\ntoo_many_lines = \"allow\"\ntrivially_copy_pass_by_ref = \"allow\"\nunreadable_literal = \"allow\"\nused_underscore_binding = \"allow\"\nassigning_clones = \"allow\"\nmanual_range_contains = \"allow\"\nmap_unwrap_or = \"allow\"\nmultiple_crate_versions = \"allow\"\nwildcard_imports = \"allow\"\nlet_underscore_must_use = \"allow\"\nlet_underscore_untyped = \"allow\"\nself_named_module_files = \"allow\"\nsignificant_drop_tightening = \"allow\"\n\n[lints.clippy.all]\nlevel = \"warn\"\npriority = -1\n\n[lints.clippy.cargo]\nlevel = \"warn\"\npriority = -1\n\n[lints.clippy.pedantic]\nlevel = \"warn\"\npriority = -1\n\n[lib]\n\n[dependencies]\nsys-locale = \"0.3.2\"\nunicode-script = \"0.5.8\"\n\n[dependencies.epaint]\nfeatures = [\"color_fonts\"]\nversion = \"0.37.0\"\npath = \"crates/epaint\"\ndefault-features = false\n\n[dependencies.fontique]\nversion = \"0.11.1\"\ndefault-features = false\nfeatures = [\"system\", \"fontconfig-dlopen\"]\n\n[dependencies.log]\nversion = \"0.4.34\"\nfeatures = [\"std\"]\n\n[dependencies.poll-promise]\nversion = \"0.3.0\"\ndefault-features = false\n\n[dependencies.skrifa]\nversion = \"0.44.0\"\ndefault-features = false\nfeatures = [\"std\", \"autohint_shaping\"]\n\n[dev-dependencies.egui]\nversion = \"0.37.0\"\npath = \"crates/egui\"\ndefault-features = false\n", - "dest": "cargo/vendor/egui_system_font_provider", + "dest": "cargo/vendor-git/11e349eb0774eb3ab9192b38c47d748bf18abba91a0e3952d8f196513da96ee6/egui_system_font_provider", "dest-filename": "Cargo.toml" }, { "type": "inline", "contents": "{\"package\": null, \"files\": {}}", - "dest": "cargo/vendor/egui_system_font_provider", + "dest": "cargo/vendor-git/11e349eb0774eb3ab9192b38c47d748bf18abba91a0e3952d8f196513da96ee6/egui_system_font_provider", "dest-filename": ".cargo-checksum.json" }, { "type": "inline", - "contents": "[source.vendored-sources]\ndirectory = \"cargo/vendor\"\n\n[source.crates-io]\nreplace-with = \"vendored-sources\"\n\n[source.\"https://github.com/storytold/craft-libs?rev=94777dcf7f8962476e96b049d08d22e25b9330c2\"]\ngit = \"https://github.com/storytold/craft-libs\"\nreplace-with = \"vendored-sources\"\nrev = \"94777dcf7f8962476e96b049d08d22e25b9330c2\"\n\n[source.\"https://github.com/storytold/craft-libs?rev=f0f4758c01581d79577b9bf5046c06f4e77b1f18\"]\ngit = \"https://github.com/storytold/craft-libs\"\nreplace-with = \"vendored-sources\"\nrev = \"f0f4758c01581d79577b9bf5046c06f4e77b1f18\"\n\n[source.\"https://github.com/storytold/craft-libs?rev=c5a1cbfb5f9049f9270955caffb5bee5997aebf7\"]\ngit = \"https://github.com/storytold/craft-libs\"\nreplace-with = \"vendored-sources\"\nrev = \"c5a1cbfb5f9049f9270955caffb5bee5997aebf7\"\n\n[source.\"https://github.com/storytold/craft-libs?rev=9dcbd90c7d16e1a668b3afa057e940e2db328b93\"]\ngit = \"https://github.com/storytold/craft-libs\"\nreplace-with = \"vendored-sources\"\nrev = \"9dcbd90c7d16e1a668b3afa057e940e2db328b93\"\n\n[source.\"https://github.com/storytold/craft-libs?rev=b77af389f30bb10de10d8436ca9b39fe94e3bb67\"]\ngit = \"https://github.com/storytold/craft-libs\"\nreplace-with = \"vendored-sources\"\nrev = \"b77af389f30bb10de10d8436ca9b39fe94e3bb67\"\n\n[source.\"https://github.com/storytold/craft-libs?rev=478c50560d3c6fad3d613af2a30b35c3bc9f4c0f\"]\ngit = \"https://github.com/storytold/craft-libs\"\nreplace-with = \"vendored-sources\"\nrev = \"478c50560d3c6fad3d613af2a30b35c3bc9f4c0f\"\n\n[source.\"https://github.com/storytold/craft-libs?rev=2651dbeb2b13f621db23f65347380e7f26e316f0\"]\ngit = \"https://github.com/storytold/craft-libs\"\nreplace-with = \"vendored-sources\"\nrev = \"2651dbeb2b13f621db23f65347380e7f26e316f0\"\n\n[source.\"https://github.com/storytold/craft-libs?rev=6e03f65bf45181db77ba6229716e6624db9eb25b\"]\ngit = \"https://github.com/storytold/craft-libs\"\nreplace-with = \"vendored-sources\"\nrev = \"6e03f65bf45181db77ba6229716e6624db9eb25b\"\n\n[source.\"https://github.com/storytold/egui.git?rev=6d518fc799681571963842f95b55a6b68431b15a\"]\ngit = \"https://github.com/storytold/egui\"\nreplace-with = \"vendored-sources\"\nrev = \"6d518fc799681571963842f95b55a6b68431b15a\"\n\n[source.\"https://github.com/storytold/winit.git?rev=a517b3846ee8457d84ee4975110bfda6797c44dc\"]\ngit = \"https://github.com/storytold/winit\"\nreplace-with = \"vendored-sources\"\nrev = \"a517b3846ee8457d84ee4975110bfda6797c44dc\"\n", + "contents": "[source.vendored-sources]\ndirectory = \"cargo/vendor\"\n\n[source.crates-io]\nreplace-with = \"vendored-sources\"\n\n[source.\"https://github.com/storytold/craft-libs?rev=94777dcf7f8962476e96b049d08d22e25b9330c2\"]\ngit = \"https://github.com/storytold/craft-libs\"\nreplace-with = \"git-vendor-6fd0ceba5f4137be1fe00e9c031f810234e38df6f60195003fed7057c96f0aa1\"\nrev = \"94777dcf7f8962476e96b049d08d22e25b9330c2\"\n\n[source.git-vendor-6fd0ceba5f4137be1fe00e9c031f810234e38df6f60195003fed7057c96f0aa1]\ndirectory = \"cargo/vendor-git/6fd0ceba5f4137be1fe00e9c031f810234e38df6f60195003fed7057c96f0aa1\"\n\n[source.\"https://github.com/storytold/craft-libs?rev=f0f4758c01581d79577b9bf5046c06f4e77b1f18\"]\ngit = \"https://github.com/storytold/craft-libs\"\nreplace-with = \"git-vendor-bc00bd22a20692df38f25839a8568cd55b90e379a41719721bbc0f04fe5e29f7\"\nrev = \"f0f4758c01581d79577b9bf5046c06f4e77b1f18\"\n\n[source.git-vendor-bc00bd22a20692df38f25839a8568cd55b90e379a41719721bbc0f04fe5e29f7]\ndirectory = \"cargo/vendor-git/bc00bd22a20692df38f25839a8568cd55b90e379a41719721bbc0f04fe5e29f7\"\n\n[source.\"https://github.com/storytold/craft-libs?rev=c5a1cbfb5f9049f9270955caffb5bee5997aebf7\"]\ngit = \"https://github.com/storytold/craft-libs\"\nreplace-with = \"git-vendor-11a22760e699d74db2deeccbdb390b343ad010ce425dcb15451f0e14e45ff298\"\nrev = \"c5a1cbfb5f9049f9270955caffb5bee5997aebf7\"\n\n[source.git-vendor-11a22760e699d74db2deeccbdb390b343ad010ce425dcb15451f0e14e45ff298]\ndirectory = \"cargo/vendor-git/11a22760e699d74db2deeccbdb390b343ad010ce425dcb15451f0e14e45ff298\"\n\n[source.\"https://github.com/storytold/craft-libs?rev=9dcbd90c7d16e1a668b3afa057e940e2db328b93\"]\ngit = \"https://github.com/storytold/craft-libs\"\nreplace-with = \"git-vendor-36bf00be069421f8a8a7428c4360efee8b4243207a59d7b566c6f48fc5918f61\"\nrev = \"9dcbd90c7d16e1a668b3afa057e940e2db328b93\"\n\n[source.git-vendor-36bf00be069421f8a8a7428c4360efee8b4243207a59d7b566c6f48fc5918f61]\ndirectory = \"cargo/vendor-git/36bf00be069421f8a8a7428c4360efee8b4243207a59d7b566c6f48fc5918f61\"\n\n[source.\"https://github.com/storytold/craft-libs?rev=b77af389f30bb10de10d8436ca9b39fe94e3bb67\"]\ngit = \"https://github.com/storytold/craft-libs\"\nreplace-with = \"git-vendor-a51e2c3f46af71f1caed91009f88b4f9982db0c4152c6659d11967a7731b1ccc\"\nrev = \"b77af389f30bb10de10d8436ca9b39fe94e3bb67\"\n\n[source.git-vendor-a51e2c3f46af71f1caed91009f88b4f9982db0c4152c6659d11967a7731b1ccc]\ndirectory = \"cargo/vendor-git/a51e2c3f46af71f1caed91009f88b4f9982db0c4152c6659d11967a7731b1ccc\"\n\n[source.\"https://github.com/storytold/craft-libs?rev=478c50560d3c6fad3d613af2a30b35c3bc9f4c0f\"]\ngit = \"https://github.com/storytold/craft-libs\"\nreplace-with = \"git-vendor-cb31475a7a9d19c00f48b4c43603f2f1a464c6dce15da1d21bba4c653eeba6b2\"\nrev = \"478c50560d3c6fad3d613af2a30b35c3bc9f4c0f\"\n\n[source.git-vendor-cb31475a7a9d19c00f48b4c43603f2f1a464c6dce15da1d21bba4c653eeba6b2]\ndirectory = \"cargo/vendor-git/cb31475a7a9d19c00f48b4c43603f2f1a464c6dce15da1d21bba4c653eeba6b2\"\n\n[source.\"https://github.com/storytold/craft-libs?rev=2651dbeb2b13f621db23f65347380e7f26e316f0\"]\ngit = \"https://github.com/storytold/craft-libs\"\nreplace-with = \"git-vendor-677ec4bd11b9c98fb90165eb3a009c5b05f30eee72bbe079c4c936aa3feb3ff9\"\nrev = \"2651dbeb2b13f621db23f65347380e7f26e316f0\"\n\n[source.git-vendor-677ec4bd11b9c98fb90165eb3a009c5b05f30eee72bbe079c4c936aa3feb3ff9]\ndirectory = \"cargo/vendor-git/677ec4bd11b9c98fb90165eb3a009c5b05f30eee72bbe079c4c936aa3feb3ff9\"\n\n[source.\"https://github.com/storytold/craft-libs?rev=6e03f65bf45181db77ba6229716e6624db9eb25b\"]\ngit = \"https://github.com/storytold/craft-libs\"\nreplace-with = \"git-vendor-4765c8f813a43ec0005270c9f4b16bff2eb2e09aeb15e4230bcd10e5bba1c4ba\"\nrev = \"6e03f65bf45181db77ba6229716e6624db9eb25b\"\n\n[source.git-vendor-4765c8f813a43ec0005270c9f4b16bff2eb2e09aeb15e4230bcd10e5bba1c4ba]\ndirectory = \"cargo/vendor-git/4765c8f813a43ec0005270c9f4b16bff2eb2e09aeb15e4230bcd10e5bba1c4ba\"\n\n[source.\"https://github.com/storytold/egui.git?rev=6d518fc799681571963842f95b55a6b68431b15a\"]\ngit = \"https://github.com/storytold/egui\"\nreplace-with = \"git-vendor-11e349eb0774eb3ab9192b38c47d748bf18abba91a0e3952d8f196513da96ee6\"\nrev = \"6d518fc799681571963842f95b55a6b68431b15a\"\n\n[source.git-vendor-11e349eb0774eb3ab9192b38c47d748bf18abba91a0e3952d8f196513da96ee6]\ndirectory = \"cargo/vendor-git/11e349eb0774eb3ab9192b38c47d748bf18abba91a0e3952d8f196513da96ee6\"\n\n[source.\"https://github.com/storytold/winit.git?rev=a517b3846ee8457d84ee4975110bfda6797c44dc\"]\ngit = \"https://github.com/storytold/winit\"\nreplace-with = \"git-vendor-9c7f809a50c4212d761a5b6359c5e4a02fcf86376d330a441c4ce9d112706ee9\"\nrev = \"a517b3846ee8457d84ee4975110bfda6797c44dc\"\n\n[source.git-vendor-9c7f809a50c4212d761a5b6359c5e4a02fcf86376d330a441c4ce9d112706ee9]\ndirectory = \"cargo/vendor-git/9c7f809a50c4212d761a5b6359c5e4a02fcf86376d330a441c4ce9d112706ee9\"\n", "dest": "cargo", "dest-filename": "config" } diff --git a/packaging/linux/flatpak/generate-cargo-sources.py b/packaging/linux/flatpak/generate-cargo-sources.py index 43ed785a2a..182a1c0390 100755 --- a/packaging/linux/flatpak/generate-cargo-sources.py +++ b/packaging/linux/flatpak/generate-cargo-sources.py @@ -2,13 +2,14 @@ """Regenerate cargo-sources.json for the from-source Flatpak manifest. The upstream flatpak-cargo-generator is downloaded from a pinned commit and -verified before use; the full script is intentionally not vendored here. Two -small, reviewed patches are applied in memory: +verified before use; the full script is intentionally not vendored here. The following +small patches are applied in memory: 1. Key cargo source replacements by the full source URL (including ?rev=...) instead of only the repository URL, so two different revisions of the same repository stay distinct. -2. Include Cargo.lock's [patch.unused] entries, so crates such as egui_demo_lib +2. Isolate Git package directories and replacement sources by locked identity. +3. Include Cargo.lock's [patch.unused] entries, so crates such as egui_demo_lib are vendored even though they are not in the resolved package graph. This only produces and validates the source inventory; a full Flatpak SDK @@ -42,7 +43,7 @@ UPSTREAM_URL = ( f"{UPSTREAM_COMMIT}/cargo/flatpak-cargo-generator.py" ) UPSTREAM_SHA256 = "0a2db6be87d75910facef28ab46d4d6460802e8419ab850d0caa6a364d26b380" -PATCHED_SHA256 = "1e7c61d98d18e88156fb8cd4b91f526e04a6c504b185ae7b12f775ec1dd48512" +PATCHED_SHA256 = "56e06136037ca106a690c3c6d50d5b385462f6567ca63afdd7efb257049efe86" # Allow cold git caches while bounding stalled inventory regeneration. GENERATOR_TIMEOUT_SECONDS = 30 * 60 @@ -85,6 +86,48 @@ PATCHES = ( ), ) +# Isolate same-name/version Git packages by complete locked source identity. +PATCHES += ( + ( + 'isolate Git directory sources', + """ logging.info("Adding package %s from %s", name, repo_url) + git_pkg = git_repo["commits"][commit][name] +""", + """ # Directory sources cannot distinguish equal name/version packages from + # different Git revisions. Isolate both the files and replacement source. + identity = hashlib.sha256(source.encode("utf-8")).hexdigest() + vendor_name = f"git-vendor-{identity}" + vendor_root = f"{CARGO_HOME}/vendor-git/{identity}" + for entry in cargo_vendored_entry.values(): + entry["replace-with"] = vendor_name + cargo_vendored_entry[vendor_name] = {"directory": vendor_root} + + logging.info("Adding package %s from %s", name, repo_url) + git_pkg = git_repo["commits"][commit][name] +""", + ), + ( + 'create isolated Git package directory', + """ f'cp -r --reflink=auto "{pkg_repo_dir}" "{CARGO_CRATES}/{name}"'""", + """ f'mkdir -p "{vendor_root}" && ' + f'cp -r --reflink=auto "{pkg_repo_dir}" "{vendor_root}/{name}"'""", + ), + ( + 'isolate Git Cargo.toml destination', + """ "dest": f"{CARGO_CRATES}/{name}", # -{version}', + "dest-filename": "Cargo.toml",""", + """ "dest": f"{vendor_root}/{name}", + "dest-filename": "Cargo.toml",""", + ), + ( + 'isolate Git .cargo-checksum.json destination', + """ "dest": f"{CARGO_CRATES}/{name}", # -{version}', + "dest-filename": ".cargo-checksum.json",""", + """ "dest": f"{vendor_root}/{name}", + "dest-filename": ".cargo-checksum.json",""", + ), +) + def sha256(data: bytes) -> str: return hashlib.sha256(data).hexdigest() diff --git a/packaging/linux/flatpak/test_generate_cargo_sources.py b/packaging/linux/flatpak/test_generate_cargo_sources.py index cfa38bc38e..aa167ccb81 100644 --- a/packaging/linux/flatpak/test_generate_cargo_sources.py +++ b/packaging/linux/flatpak/test_generate_cargo_sources.py @@ -479,5 +479,49 @@ class InventoryFailures(unittest.TestCase): self.assertEqual(list(root.glob('.sources.json.*.tmp')), []) + +class GitSourceIsolationTests(unittest.TestCase): + """Exercise the identity block inserted into the hash-pinned generator.""" + + def identity(self, source, name='same-crate'): + import logging + import textwrap + from urllib.parse import urlparse + repo = 'https://github.com/example/formats' + commit = urlparse(source).fragment + key = source.removeprefix('git+').split('#', 1)[0] + scope = { + 'hashlib': hashlib, 'source': source, 'CARGO_HOME': 'cargo', + 'cargo_vendored_entry': {key: {'git': repo, 'replace-with': 'vendored-sources'}}, + 'logging': logging, 'name': name, 'repo_url': repo, 'commit': commit, + 'git_repo': {'commits': {commit: {name: object()}}}, + } + block = next(new for label, _, new in wrapper.PATCHES if label == 'isolate Git directory sources') + exec(textwrap.dedent(block), scope) + mapping = scope['cargo_vendored_entry'] + replacement = mapping[key]['replace-with'] + self.assertEqual(mapping[replacement]['directory'], scope['vendor_root']) + self.assertNotEqual(replacement, 'vendored-sources') + return scope['vendor_root'], replacement + + def test_same_package_and_version_at_two_revisions_are_isolated(self): + prefix = 'git+https://github.com/example/formats?rev=' + first = self.identity(prefix + 'a' * 40 + '#' + 'a' * 40) + second = self.identity(prefix + 'b' * 40 + '#' + 'b' * 40) + self.assertNotEqual(first[0], second[0]) + self.assertNotEqual(first[1], second[1]) + self.assertTrue(first[0].startswith('cargo/vendor-git/')) + + def test_packages_from_one_locked_source_share_one_root(self): + source = 'git+https://github.com/example/formats?rev=' + 'a' * 40 + '#' + 'a' * 40 + self.assertEqual(self.identity(source, 'metadata'), self.identity(source, 'tiff')) + + def test_distinct_source_aliases_do_not_repeat_copy_into_same_directory(self): + commit = 'a' * 40 + first = self.identity('git+https://github.com/example/formats?rev=' + commit + '#' + commit) + second = self.identity('git+https://github.com/example/formats?tag=release#' + commit) + self.assertNotEqual(first, second) + + if __name__ == '__main__': unittest.main(verbosity=2) From 2ef3e332a98bf493610504eaddf723232969c625 Mon Sep 17 00:00:00 2001 From: "Dylan M. Taylor" <dylan@dylanmtaylor.com> Date: Sun, 15 Nov 2026 18:51:09 -0500 Subject: [PATCH 48/61] print: pin merged shared raster writer --- Cargo.lock | 2 +- Cargo.toml | 2 +- packaging/linux/flatpak/cargo-sources.json | 12 ++++++------ 3 files changed, 8 insertions(+), 8 deletions(-) diff --git a/Cargo.lock b/Cargo.lock index f2d6118f8d..0b6247b273 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -1349,7 +1349,7 @@ dependencies = [ [[package]] name = "craft-pdf" version = "0.1.0" -source = "git+https://github.com/storytold/craft-libs?rev=2651dbeb2b13f621db23f65347380e7f26e316f0#2651dbeb2b13f621db23f65347380e7f26e316f0" +source = "git+https://github.com/storytold/craft-libs?rev=0fd30aeb3e02207d9d4c7c601540d9da45abf8de#0fd30aeb3e02207d9d4c7c601540d9da45abf8de" dependencies = [ "flate2", "roxmltree", diff --git a/Cargo.toml b/Cargo.toml index c0ca9ebea3..8e0ce1cbf7 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -10,7 +10,7 @@ rust-version = "1.95" repository = "https://github.com/storytold/lightcraft" [workspace.dependencies] -craft-pdf-print = { package = "craft-pdf", git = "https://github.com/storytold/craft-libs", rev = "2651dbeb2b13f621db23f65347380e7f26e316f0", default-features = false, features = ["write-raster"] } +craft-pdf-print = { package = "craft-pdf", git = "https://github.com/storytold/craft-libs", rev = "0fd30aeb3e02207d9d4c7c601540d9da45abf8de", default-features = false, features = ["write-raster"] } craft-ui = { git = "https://github.com/storytold/craft-libs", rev = "c5a1cbfb5f9049f9270955caffb5bee5997aebf7", features = ["serde"] } craft-docpath = { version = "0.1.0", git = "https://github.com/storytold/craft-libs", rev = "c5a1cbfb5f9049f9270955caffb5bee5997aebf7" } # Canon CRW decoder shared with the other Craft apps diff --git a/packaging/linux/flatpak/cargo-sources.json b/packaging/linux/flatpak/cargo-sources.json index e36140f1e1..58c13aa3ae 100644 --- a/packaging/linux/flatpak/cargo-sources.json +++ b/packaging/linux/flatpak/cargo-sources.json @@ -38,8 +38,8 @@ { "type": "git", "url": "https://github.com/storytold/craft-libs", - "commit": "2651dbeb2b13f621db23f65347380e7f26e316f0", - "dest": "flatpak-cargo/git/craft-libs-2651dbe" + "commit": "0fd30aeb3e02207d9d4c7c601540d9da45abf8de", + "dest": "flatpak-cargo/git/craft-libs-0fd30ae" }, { "type": "git", @@ -1840,19 +1840,19 @@ { "type": "shell", "commands": [ - "mkdir -p \"cargo/vendor-git/677ec4bd11b9c98fb90165eb3a009c5b05f30eee72bbe079c4c936aa3feb3ff9\" && cp -r --reflink=auto \"flatpak-cargo/git/craft-libs-2651dbe/crates/pdf\" \"cargo/vendor-git/677ec4bd11b9c98fb90165eb3a009c5b05f30eee72bbe079c4c936aa3feb3ff9/craft-pdf\"" + "mkdir -p \"cargo/vendor-git/fafb086755da4e9bf32b4ac1b53a42a6017167d56ec0071462788465fa35eb30\" && cp -r --reflink=auto \"flatpak-cargo/git/craft-libs-0fd30ae/crates/pdf\" \"cargo/vendor-git/fafb086755da4e9bf32b4ac1b53a42a6017167d56ec0071462788465fa35eb30/craft-pdf\"" ] }, { "type": "inline", "contents": "[package]\nname = \"craft-pdf\"\ndescription = \"Shared PDF reading, rendering and optional writing for Craft apps\"\nversion = \"0.1.0\"\nedition = \"2024\"\nlicense = \"MIT OR Apache-2.0\"\nrepository = \"https://github.com/storytold/craft-libs\"\nrust-version = \"1.95\"\n\n[lints.rust]\nunsafe_code = \"forbid\"\nunused_workspace_dependencies = \"allow\"\n\n[lints.rust.unexpected_cfgs]\nlevel = \"warn\"\ncheck-cfg = [\"cfg(craft_pdf_unicode_fixtures)\"]\n\n[lints.clippy]\ncognitive_complexity = \"deny\"\ntoo_many_arguments = \"deny\"\nunused_workspace_dependencies = \"allow\"\nwildcard_imports = \"deny\"\ndbg_macro = \"warn\"\ntodo = \"warn\"\n\n[features]\ndefault = []\nread = [\"dep:hayro-syntax\", \"dep:thiserror\"]\ninterpret = [\"read\", \"dep:hayro-interpret\"]\npaths = [\"interpret\", \"dep:kurbo\"]\nraster = [\"interpret\", \"dep:hayro\", \"dep:bytemuck\"]\nwrite = [\"dep:krilla\", \"dep:thiserror\"]\nwrite-svg = [\"write\", \"dep:craft-svg\", \"dep:krilla-svg\", \"dep:usvg\", \"craft-svg/tree-text\"]\nwrite-pdf = [\"write\", \"krilla/pdf\"]\nwrite-raster = [\"dep:flate2\", \"dep:roxmltree\"]\nwrite-simple-text = [\"write\", \"krilla/simple-text\"]\nfilters = [\"dep:craft-stream-codecs\", \"dep:flate2\", \"dep:thiserror\"]\ncos = [\"crypt\", \"filters\", \"dep:chrono\", \"dep:js-sys\", \"dep:wasm-bindgen\"]\ncrypt = [\"dep:aes\", \"dep:md-5\", \"dep:sha2\", \"dep:stringprep\", \"dep:zeroize\", \"dep:thiserror\"]\n\n[dependencies.hayro-syntax]\noptional = true\nversion = \"=0.7.2\"\ndefault-features = false\nfeatures = [\"std\"]\n\n[dependencies.hayro-interpret]\noptional = true\nversion = \"=0.7.0\"\ndefault-features = false\nfeatures = [\"embed-fonts\", \"embed-cmaps\"]\n\n[dependencies.hayro]\noptional = true\nversion = \"=0.7.1\"\ndefault-features = false\n\n[dependencies.bytemuck]\noptional = true\nversion = \"1\"\n\n[dependencies.krilla]\noptional = true\nversion = \"=0.8.2\"\ndefault-features = false\nfeatures = [\"raster-images\"]\n\n[dependencies.craft-svg]\noptional = true\npath = \"crates/svg\"\n\n[dependencies.krilla-svg]\nversion = \"=0.8.1\"\noptional = true\n\n[dependencies.usvg]\nversion = \"=0.47.0\"\nfeatures = [\"text\"]\noptional = true\n\n[dependencies.thiserror]\noptional = true\nversion = \"2\"\n\n[dependencies.flate2]\nversion = \"1.1\"\ndefault-features = false\nfeatures = [\"zlib-rs\"]\noptional = true\n\n[dependencies.roxmltree]\nversion = \"0.21\"\noptional = true\n\n[dependencies.craft-stream-codecs]\noptional = true\npath = \"crates/stream-codecs\"\n\n[dependencies.aes]\nversion = \"0.9\"\noptional = true\n\n[dependencies.md-5]\nversion = \"0.11\"\noptional = true\n\n[dependencies.sha2]\nversion = \"0.11\"\noptional = true\n\n[dependencies.stringprep]\nversion = \"0.1\"\noptional = true\n\n[dependencies.zeroize]\nversion = \"1\"\noptional = true\n\n[dependencies.chrono]\noptional = true\nversion = \"0.4.45\"\ndefault-features = false\nfeatures = [\"std\"]\n\n[dependencies.kurbo]\noptional = true\nversion = \"0.13\"\n\n[target.\"cfg(target_arch = \\\"wasm32\\\")\".dependencies.js-sys]\nversion = \"0.3\"\noptional = true\n\n[target.\"cfg(target_arch = \\\"wasm32\\\")\".dependencies.wasm-bindgen]\nversion = \"0.2\"\noptional = true\n\n[target.\"cfg(target_arch = \\\"wasm32\\\")\".dev-dependencies]\nwasm-bindgen-test = \"0.3\"\n\n[target.\"cfg(not(target_arch = \\\"wasm32\\\"))\".dev-dependencies]\nproptest = \"1\"\n\n[dev-dependencies]\nserde_json = \"1\"\nhayro-syntax = \"=0.7.2\"\nhayro-cmap = \"=0.1.0\"\nkurbo = \"0.13\"\nttf-parser = \"=0.25.1\"\n\n[dev-dependencies.hayro-interpret]\nversion = \"=0.7.0\"\ndefault-features = false\n\n[[example]]\nname = \"cos_info\"\nrequired-features = [\"cos\"]\n\n[[example]]\nname = \"cos_protect\"\nrequired-features = [\"cos\"]\n", - "dest": "cargo/vendor-git/677ec4bd11b9c98fb90165eb3a009c5b05f30eee72bbe079c4c936aa3feb3ff9/craft-pdf", + "dest": "cargo/vendor-git/fafb086755da4e9bf32b4ac1b53a42a6017167d56ec0071462788465fa35eb30/craft-pdf", "dest-filename": "Cargo.toml" }, { "type": "inline", "contents": "{\"package\": null, \"files\": {}}", - "dest": "cargo/vendor-git/677ec4bd11b9c98fb90165eb3a009c5b05f30eee72bbe079c4c936aa3feb3ff9/craft-pdf", + "dest": "cargo/vendor-git/fafb086755da4e9bf32b4ac1b53a42a6017167d56ec0071462788465fa35eb30/craft-pdf", "dest-filename": ".cargo-checksum.json" }, { @@ -10071,7 +10071,7 @@ }, { "type": "inline", - "contents": "[source.vendored-sources]\ndirectory = \"cargo/vendor\"\n\n[source.crates-io]\nreplace-with = \"vendored-sources\"\n\n[source.\"https://github.com/storytold/craft-libs?rev=94777dcf7f8962476e96b049d08d22e25b9330c2\"]\ngit = \"https://github.com/storytold/craft-libs\"\nreplace-with = \"git-vendor-6fd0ceba5f4137be1fe00e9c031f810234e38df6f60195003fed7057c96f0aa1\"\nrev = \"94777dcf7f8962476e96b049d08d22e25b9330c2\"\n\n[source.git-vendor-6fd0ceba5f4137be1fe00e9c031f810234e38df6f60195003fed7057c96f0aa1]\ndirectory = \"cargo/vendor-git/6fd0ceba5f4137be1fe00e9c031f810234e38df6f60195003fed7057c96f0aa1\"\n\n[source.\"https://github.com/storytold/craft-libs?rev=f0f4758c01581d79577b9bf5046c06f4e77b1f18\"]\ngit = \"https://github.com/storytold/craft-libs\"\nreplace-with = \"git-vendor-bc00bd22a20692df38f25839a8568cd55b90e379a41719721bbc0f04fe5e29f7\"\nrev = \"f0f4758c01581d79577b9bf5046c06f4e77b1f18\"\n\n[source.git-vendor-bc00bd22a20692df38f25839a8568cd55b90e379a41719721bbc0f04fe5e29f7]\ndirectory = \"cargo/vendor-git/bc00bd22a20692df38f25839a8568cd55b90e379a41719721bbc0f04fe5e29f7\"\n\n[source.\"https://github.com/storytold/craft-libs?rev=c5a1cbfb5f9049f9270955caffb5bee5997aebf7\"]\ngit = \"https://github.com/storytold/craft-libs\"\nreplace-with = \"git-vendor-11a22760e699d74db2deeccbdb390b343ad010ce425dcb15451f0e14e45ff298\"\nrev = \"c5a1cbfb5f9049f9270955caffb5bee5997aebf7\"\n\n[source.git-vendor-11a22760e699d74db2deeccbdb390b343ad010ce425dcb15451f0e14e45ff298]\ndirectory = \"cargo/vendor-git/11a22760e699d74db2deeccbdb390b343ad010ce425dcb15451f0e14e45ff298\"\n\n[source.\"https://github.com/storytold/craft-libs?rev=9dcbd90c7d16e1a668b3afa057e940e2db328b93\"]\ngit = \"https://github.com/storytold/craft-libs\"\nreplace-with = \"git-vendor-36bf00be069421f8a8a7428c4360efee8b4243207a59d7b566c6f48fc5918f61\"\nrev = \"9dcbd90c7d16e1a668b3afa057e940e2db328b93\"\n\n[source.git-vendor-36bf00be069421f8a8a7428c4360efee8b4243207a59d7b566c6f48fc5918f61]\ndirectory = \"cargo/vendor-git/36bf00be069421f8a8a7428c4360efee8b4243207a59d7b566c6f48fc5918f61\"\n\n[source.\"https://github.com/storytold/craft-libs?rev=b77af389f30bb10de10d8436ca9b39fe94e3bb67\"]\ngit = \"https://github.com/storytold/craft-libs\"\nreplace-with = \"git-vendor-a51e2c3f46af71f1caed91009f88b4f9982db0c4152c6659d11967a7731b1ccc\"\nrev = \"b77af389f30bb10de10d8436ca9b39fe94e3bb67\"\n\n[source.git-vendor-a51e2c3f46af71f1caed91009f88b4f9982db0c4152c6659d11967a7731b1ccc]\ndirectory = \"cargo/vendor-git/a51e2c3f46af71f1caed91009f88b4f9982db0c4152c6659d11967a7731b1ccc\"\n\n[source.\"https://github.com/storytold/craft-libs?rev=478c50560d3c6fad3d613af2a30b35c3bc9f4c0f\"]\ngit = \"https://github.com/storytold/craft-libs\"\nreplace-with = \"git-vendor-cb31475a7a9d19c00f48b4c43603f2f1a464c6dce15da1d21bba4c653eeba6b2\"\nrev = \"478c50560d3c6fad3d613af2a30b35c3bc9f4c0f\"\n\n[source.git-vendor-cb31475a7a9d19c00f48b4c43603f2f1a464c6dce15da1d21bba4c653eeba6b2]\ndirectory = \"cargo/vendor-git/cb31475a7a9d19c00f48b4c43603f2f1a464c6dce15da1d21bba4c653eeba6b2\"\n\n[source.\"https://github.com/storytold/craft-libs?rev=2651dbeb2b13f621db23f65347380e7f26e316f0\"]\ngit = \"https://github.com/storytold/craft-libs\"\nreplace-with = \"git-vendor-677ec4bd11b9c98fb90165eb3a009c5b05f30eee72bbe079c4c936aa3feb3ff9\"\nrev = \"2651dbeb2b13f621db23f65347380e7f26e316f0\"\n\n[source.git-vendor-677ec4bd11b9c98fb90165eb3a009c5b05f30eee72bbe079c4c936aa3feb3ff9]\ndirectory = \"cargo/vendor-git/677ec4bd11b9c98fb90165eb3a009c5b05f30eee72bbe079c4c936aa3feb3ff9\"\n\n[source.\"https://github.com/storytold/craft-libs?rev=6e03f65bf45181db77ba6229716e6624db9eb25b\"]\ngit = \"https://github.com/storytold/craft-libs\"\nreplace-with = \"git-vendor-4765c8f813a43ec0005270c9f4b16bff2eb2e09aeb15e4230bcd10e5bba1c4ba\"\nrev = \"6e03f65bf45181db77ba6229716e6624db9eb25b\"\n\n[source.git-vendor-4765c8f813a43ec0005270c9f4b16bff2eb2e09aeb15e4230bcd10e5bba1c4ba]\ndirectory = \"cargo/vendor-git/4765c8f813a43ec0005270c9f4b16bff2eb2e09aeb15e4230bcd10e5bba1c4ba\"\n\n[source.\"https://github.com/storytold/egui.git?rev=6d518fc799681571963842f95b55a6b68431b15a\"]\ngit = \"https://github.com/storytold/egui\"\nreplace-with = \"git-vendor-11e349eb0774eb3ab9192b38c47d748bf18abba91a0e3952d8f196513da96ee6\"\nrev = \"6d518fc799681571963842f95b55a6b68431b15a\"\n\n[source.git-vendor-11e349eb0774eb3ab9192b38c47d748bf18abba91a0e3952d8f196513da96ee6]\ndirectory = \"cargo/vendor-git/11e349eb0774eb3ab9192b38c47d748bf18abba91a0e3952d8f196513da96ee6\"\n\n[source.\"https://github.com/storytold/winit.git?rev=a517b3846ee8457d84ee4975110bfda6797c44dc\"]\ngit = \"https://github.com/storytold/winit\"\nreplace-with = \"git-vendor-9c7f809a50c4212d761a5b6359c5e4a02fcf86376d330a441c4ce9d112706ee9\"\nrev = \"a517b3846ee8457d84ee4975110bfda6797c44dc\"\n\n[source.git-vendor-9c7f809a50c4212d761a5b6359c5e4a02fcf86376d330a441c4ce9d112706ee9]\ndirectory = \"cargo/vendor-git/9c7f809a50c4212d761a5b6359c5e4a02fcf86376d330a441c4ce9d112706ee9\"\n", + "contents": "[source.vendored-sources]\ndirectory = \"cargo/vendor\"\n\n[source.crates-io]\nreplace-with = \"vendored-sources\"\n\n[source.\"https://github.com/storytold/craft-libs?rev=94777dcf7f8962476e96b049d08d22e25b9330c2\"]\ngit = \"https://github.com/storytold/craft-libs\"\nreplace-with = \"git-vendor-6fd0ceba5f4137be1fe00e9c031f810234e38df6f60195003fed7057c96f0aa1\"\nrev = \"94777dcf7f8962476e96b049d08d22e25b9330c2\"\n\n[source.git-vendor-6fd0ceba5f4137be1fe00e9c031f810234e38df6f60195003fed7057c96f0aa1]\ndirectory = \"cargo/vendor-git/6fd0ceba5f4137be1fe00e9c031f810234e38df6f60195003fed7057c96f0aa1\"\n\n[source.\"https://github.com/storytold/craft-libs?rev=f0f4758c01581d79577b9bf5046c06f4e77b1f18\"]\ngit = \"https://github.com/storytold/craft-libs\"\nreplace-with = \"git-vendor-bc00bd22a20692df38f25839a8568cd55b90e379a41719721bbc0f04fe5e29f7\"\nrev = \"f0f4758c01581d79577b9bf5046c06f4e77b1f18\"\n\n[source.git-vendor-bc00bd22a20692df38f25839a8568cd55b90e379a41719721bbc0f04fe5e29f7]\ndirectory = \"cargo/vendor-git/bc00bd22a20692df38f25839a8568cd55b90e379a41719721bbc0f04fe5e29f7\"\n\n[source.\"https://github.com/storytold/craft-libs?rev=c5a1cbfb5f9049f9270955caffb5bee5997aebf7\"]\ngit = \"https://github.com/storytold/craft-libs\"\nreplace-with = \"git-vendor-11a22760e699d74db2deeccbdb390b343ad010ce425dcb15451f0e14e45ff298\"\nrev = \"c5a1cbfb5f9049f9270955caffb5bee5997aebf7\"\n\n[source.git-vendor-11a22760e699d74db2deeccbdb390b343ad010ce425dcb15451f0e14e45ff298]\ndirectory = \"cargo/vendor-git/11a22760e699d74db2deeccbdb390b343ad010ce425dcb15451f0e14e45ff298\"\n\n[source.\"https://github.com/storytold/craft-libs?rev=9dcbd90c7d16e1a668b3afa057e940e2db328b93\"]\ngit = \"https://github.com/storytold/craft-libs\"\nreplace-with = \"git-vendor-36bf00be069421f8a8a7428c4360efee8b4243207a59d7b566c6f48fc5918f61\"\nrev = \"9dcbd90c7d16e1a668b3afa057e940e2db328b93\"\n\n[source.git-vendor-36bf00be069421f8a8a7428c4360efee8b4243207a59d7b566c6f48fc5918f61]\ndirectory = \"cargo/vendor-git/36bf00be069421f8a8a7428c4360efee8b4243207a59d7b566c6f48fc5918f61\"\n\n[source.\"https://github.com/storytold/craft-libs?rev=b77af389f30bb10de10d8436ca9b39fe94e3bb67\"]\ngit = \"https://github.com/storytold/craft-libs\"\nreplace-with = \"git-vendor-a51e2c3f46af71f1caed91009f88b4f9982db0c4152c6659d11967a7731b1ccc\"\nrev = \"b77af389f30bb10de10d8436ca9b39fe94e3bb67\"\n\n[source.git-vendor-a51e2c3f46af71f1caed91009f88b4f9982db0c4152c6659d11967a7731b1ccc]\ndirectory = \"cargo/vendor-git/a51e2c3f46af71f1caed91009f88b4f9982db0c4152c6659d11967a7731b1ccc\"\n\n[source.\"https://github.com/storytold/craft-libs?rev=478c50560d3c6fad3d613af2a30b35c3bc9f4c0f\"]\ngit = \"https://github.com/storytold/craft-libs\"\nreplace-with = \"git-vendor-cb31475a7a9d19c00f48b4c43603f2f1a464c6dce15da1d21bba4c653eeba6b2\"\nrev = \"478c50560d3c6fad3d613af2a30b35c3bc9f4c0f\"\n\n[source.git-vendor-cb31475a7a9d19c00f48b4c43603f2f1a464c6dce15da1d21bba4c653eeba6b2]\ndirectory = \"cargo/vendor-git/cb31475a7a9d19c00f48b4c43603f2f1a464c6dce15da1d21bba4c653eeba6b2\"\n\n[source.\"https://github.com/storytold/craft-libs?rev=0fd30aeb3e02207d9d4c7c601540d9da45abf8de\"]\ngit = \"https://github.com/storytold/craft-libs\"\nreplace-with = \"git-vendor-fafb086755da4e9bf32b4ac1b53a42a6017167d56ec0071462788465fa35eb30\"\nrev = \"0fd30aeb3e02207d9d4c7c601540d9da45abf8de\"\n\n[source.git-vendor-fafb086755da4e9bf32b4ac1b53a42a6017167d56ec0071462788465fa35eb30]\ndirectory = \"cargo/vendor-git/fafb086755da4e9bf32b4ac1b53a42a6017167d56ec0071462788465fa35eb30\"\n\n[source.\"https://github.com/storytold/craft-libs?rev=6e03f65bf45181db77ba6229716e6624db9eb25b\"]\ngit = \"https://github.com/storytold/craft-libs\"\nreplace-with = \"git-vendor-4765c8f813a43ec0005270c9f4b16bff2eb2e09aeb15e4230bcd10e5bba1c4ba\"\nrev = \"6e03f65bf45181db77ba6229716e6624db9eb25b\"\n\n[source.git-vendor-4765c8f813a43ec0005270c9f4b16bff2eb2e09aeb15e4230bcd10e5bba1c4ba]\ndirectory = \"cargo/vendor-git/4765c8f813a43ec0005270c9f4b16bff2eb2e09aeb15e4230bcd10e5bba1c4ba\"\n\n[source.\"https://github.com/storytold/egui.git?rev=6d518fc799681571963842f95b55a6b68431b15a\"]\ngit = \"https://github.com/storytold/egui\"\nreplace-with = \"git-vendor-11e349eb0774eb3ab9192b38c47d748bf18abba91a0e3952d8f196513da96ee6\"\nrev = \"6d518fc799681571963842f95b55a6b68431b15a\"\n\n[source.git-vendor-11e349eb0774eb3ab9192b38c47d748bf18abba91a0e3952d8f196513da96ee6]\ndirectory = \"cargo/vendor-git/11e349eb0774eb3ab9192b38c47d748bf18abba91a0e3952d8f196513da96ee6\"\n\n[source.\"https://github.com/storytold/winit.git?rev=a517b3846ee8457d84ee4975110bfda6797c44dc\"]\ngit = \"https://github.com/storytold/winit\"\nreplace-with = \"git-vendor-9c7f809a50c4212d761a5b6359c5e4a02fcf86376d330a441c4ce9d112706ee9\"\nrev = \"a517b3846ee8457d84ee4975110bfda6797c44dc\"\n\n[source.git-vendor-9c7f809a50c4212d761a5b6359c5e4a02fcf86376d330a441c4ce9d112706ee9]\ndirectory = \"cargo/vendor-git/9c7f809a50c4212d761a5b6359c5e4a02fcf86376d330a441c4ce9d112706ee9\"\n", "dest": "cargo", "dest-filename": "config" } From 629481764ed24c0f17b450c5513826114bf7e2d5 Mon Sep 17 00:00:00 2001 From: "Dylan M. Taylor" <dylan@dylanmtaylor.com> Date: Sun, 15 Nov 2026 19:44:00 -0500 Subject: [PATCH 49/61] fix(avif): preserve shared encoder threading without repinning other codecs --- Cargo.lock | 79 ++++++++++++++++++++++++++++++++----- Cargo.toml | 4 +- crates/codecs/Cargo.toml | 4 +- crates/codecs/src/encode.rs | 24 ++++++++--- 4 files changed, 93 insertions(+), 18 deletions(-) diff --git a/Cargo.lock b/Cargo.lock index 67ebbe23a7..632fdd7190 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -1273,8 +1273,7 @@ name = "craft-image-codecs" version = "0.1.0" source = "git+https://github.com/storytold/craft-libs?rev=478c50560d3c6fad3d613af2a30b35c3bc9f4c0f#478c50560d3c6fad3d613af2a30b35c3bc9f4c0f" dependencies = [ - "avif-serialize", - "craft-jpeg", + "craft-jpeg 0.1.0 (git+https://github.com/storytold/craft-libs?rev=478c50560d3c6fad3d613af2a30b35c3bc9f4c0f)", "craft-metadata 0.1.0 (git+https://github.com/storytold/craft-libs?rev=478c50560d3c6fad3d613af2a30b35c3bc9f4c0f)", "crc32fast", "exr", @@ -1285,6 +1284,33 @@ dependencies = [ "image-webp", "jpeg-encoder 0.6.1", "png", + "rayon", + "serde_json", + "thiserror 2.0.21", + "tiff", + "zune-core", + "zune-jpeg", + "zune-jpegxl", +] + +[[package]] +name = "craft-image-codecs" +version = "0.1.0" +source = "git+https://github.com/storytold/craft-libs?rev=d99d0d3f9dc66ae74e0bf9991189545c51f6c037#d99d0d3f9dc66ae74e0bf9991189545c51f6c037" +dependencies = [ + "avif-serialize", + "craft-jpeg 0.1.0 (git+https://github.com/storytold/craft-libs?rev=d99d0d3f9dc66ae74e0bf9991189545c51f6c037)", + "craft-metadata 0.1.0 (git+https://github.com/storytold/craft-libs?rev=d99d0d3f9dc66ae74e0bf9991189545c51f6c037)", + "craft-tiff 0.1.0 (git+https://github.com/storytold/craft-libs?rev=d99d0d3f9dc66ae74e0bf9991189545c51f6c037)", + "crc32fast", + "exr", + "flate2", + "half", + "hayro-jpeg2000", + "image", + "image-webp", + "jpeg-encoder 0.6.1", + "png", "rav1e", "ravif", "rayon", @@ -1305,6 +1331,14 @@ dependencies = [ "thiserror 2.0.21", ] +[[package]] +name = "craft-jpeg" +version = "0.1.0" +source = "git+https://github.com/storytold/craft-libs?rev=d99d0d3f9dc66ae74e0bf9991189545c51f6c037#d99d0d3f9dc66ae74e0bf9991189545c51f6c037" +dependencies = [ + "thiserror 2.0.21", +] + [[package]] name = "craft-jxl" version = "0.1.0" @@ -1318,7 +1352,7 @@ dependencies = [ [[package]] name = "craft-media" version = "0.1.0" -source = "git+https://github.com/storytold/craft-libs?rev=478c50560d3c6fad3d613af2a30b35c3bc9f4c0f#478c50560d3c6fad3d613af2a30b35c3bc9f4c0f" +source = "git+https://github.com/storytold/craft-libs?rev=d99d0d3f9dc66ae74e0bf9991189545c51f6c037#d99d0d3f9dc66ae74e0bf9991189545c51f6c037" dependencies = [ "thiserror 2.0.21", ] @@ -1347,6 +1381,18 @@ dependencies = [ "serde", ] +[[package]] +name = "craft-metadata" +version = "0.1.0" +source = "git+https://github.com/storytold/craft-libs?rev=d99d0d3f9dc66ae74e0bf9991189545c51f6c037#d99d0d3f9dc66ae74e0bf9991189545c51f6c037" +dependencies = [ + "brotli-decompressor 6.0.1", + "chrono", + "craft-tiff 0.1.0 (git+https://github.com/storytold/craft-libs?rev=d99d0d3f9dc66ae74e0bf9991189545c51f6c037)", + "quick-xml 0.41.0", + "serde", +] + [[package]] name = "craft-mime" version = "0.1.0" @@ -1404,6 +1450,15 @@ dependencies = [ "thiserror 2.0.21", ] +[[package]] +name = "craft-tiff" +version = "0.1.0" +source = "git+https://github.com/storytold/craft-libs?rev=d99d0d3f9dc66ae74e0bf9991189545c51f6c037#d99d0d3f9dc66ae74e0bf9991189545c51f6c037" +dependencies = [ + "serde", + "thiserror 2.0.21", +] + [[package]] name = "craft-ui" version = "0.1.0" @@ -1455,10 +1510,11 @@ dependencies = [ [[package]] name = "craft-video" version = "0.1.0" -source = "git+https://github.com/storytold/craft-libs?rev=478c50560d3c6fad3d613af2a30b35c3bc9f4c0f#478c50560d3c6fad3d613af2a30b35c3bc9f4c0f" +source = "git+https://github.com/storytold/craft-libs?rev=d99d0d3f9dc66ae74e0bf9991189545c51f6c037#d99d0d3f9dc66ae74e0bf9991189545c51f6c037" dependencies = [ "craft-media", "rav1e", + "rayon", "thiserror 2.0.21", ] @@ -3907,8 +3963,9 @@ dependencies = [ "craft-gainmap", "craft-gif", "craft-heif", - "craft-image-codecs", - "craft-jpeg", + "craft-image-codecs 0.1.0 (git+https://github.com/storytold/craft-libs?rev=478c50560d3c6fad3d613af2a30b35c3bc9f4c0f)", + "craft-image-codecs 0.1.0 (git+https://github.com/storytold/craft-libs?rev=d99d0d3f9dc66ae74e0bf9991189545c51f6c037)", + "craft-jpeg 0.1.0 (git+https://github.com/storytold/craft-libs?rev=478c50560d3c6fad3d613af2a30b35c3bc9f4c0f)", "craft-jxl", "craft-psd", "craft-tiff 0.1.0 (git+https://github.com/storytold/craft-libs?rev=94777dcf7f8962476e96b049d08d22e25b9330c2)", @@ -4161,7 +4218,7 @@ dependencies = [ name = "lightcraft-pipeline" version = "0.21.1" dependencies = [ - "craft-image-codecs", + "craft-image-codecs 0.1.0 (git+https://github.com/storytold/craft-libs?rev=478c50560d3c6fad3d613af2a30b35c3bc9f4c0f)", "dhat", "lightcraft-color", "lightcraft-develop", @@ -4180,7 +4237,7 @@ dependencies = [ name = "lightcraft-preview" version = "0.21.1" dependencies = [ - "craft-image-codecs", + "craft-image-codecs 0.1.0 (git+https://github.com/storytold/craft-libs?rev=478c50560d3c6fad3d613af2a30b35c3bc9f4c0f)", "lightcraft-raster", "log", "siphasher", @@ -4203,7 +4260,7 @@ name = "lightcraft-raw" version = "0.21.1" dependencies = [ "chrono", - "craft-image-codecs", + "craft-image-codecs 0.1.0 (git+https://github.com/storytold/craft-libs?rev=478c50560d3c6fad3d613af2a30b35c3bc9f4c0f)", "craft-jxl", "craft-raw", "craft-tiff 0.1.0 (git+https://github.com/storytold/craft-libs?rev=94777dcf7f8962476e96b049d08d22e25b9330c2)", @@ -4226,7 +4283,7 @@ dependencies = [ name = "lightcraft-scenes" version = "0.21.1" dependencies = [ - "craft-image-codecs", + "craft-image-codecs 0.1.0 (git+https://github.com/storytold/craft-libs?rev=478c50560d3c6fad3d613af2a30b35c3bc9f4c0f)", "lightcraft-color", "lightcraft-raster", "rayon", @@ -4417,6 +4474,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "8ea1f30cedd69f0a2954655f7188c6a834246d2bcf1e315e2ac40c4b24dc9519" dependencies = [ "cfg-if", + "rayon", ] [[package]] @@ -5924,6 +5982,7 @@ dependencies = [ "loop9", "quick-error 2.0.1", "rav1e", + "rayon", "rgb", ] diff --git a/Cargo.toml b/Cargo.toml index 34c11a2e4e..a1cb736e6b 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -24,7 +24,9 @@ craft-metadata = { git = "https://github.com/storytold/craft-libs", rev = "94777 craft-jpeg = { git = "https://github.com/storytold/craft-libs", rev = "478c50560d3c6fad3d613af2a30b35c3bc9f4c0f" } # AVIF EXIF, alpha quality and BT.2408 HLG levels (craft-libs#1448). craft-image-codecs = { git = "https://github.com/storytold/craft-libs", rev = "478c50560d3c6fad3d613af2a30b35c3bc9f4c0f" } -craft-video = { git = "https://github.com/storytold/craft-libs", rev = "478c50560d3c6fad3d613af2a30b35c3bc9f4c0f", features = ["av1", "av1-large-encode"] } +craft-video = { git = "https://github.com/storytold/craft-libs", rev = "d99d0d3f9dc66ae74e0bf9991189545c51f6c037", features = ["av1", "av1-large-encode", "threads"] } +# Isolate AVIF threading from the existing PNG/TIFF/WebP shared revision. +craft-avif-encode = { package = "craft-image-codecs", git = "https://github.com/storytold/craft-libs", rev = "d99d0d3f9dc66ae74e0bf9991189545c51f6c037", default-features = false, features = ["avif", "threads"] } craft-xml = { git = "https://github.com/storytold/craft-libs", rev = "f0f4758c01581d79577b9bf5046c06f4e77b1f18" } # craft-update: app-specific pretend versions apply to startup and manual checks. craft-update = { git = "https://github.com/storytold/craft-libs", version = "=0.1.0", rev = "6e03f65bf45181db77ba6229716e6624db9eb25b", features = ["egui"] } diff --git a/crates/codecs/Cargo.toml b/crates/codecs/Cargo.toml index 56bb5e5758..fb7020fa78 100644 --- a/crates/codecs/Cargo.toml +++ b/crates/codecs/Cargo.toml @@ -28,7 +28,7 @@ craft-jxl = { workspace = true, optional = true } [target.'cfg(not(target_arch = "wasm32"))'.dependencies] craft-video = { workspace = true, optional = true } -craft-image-codecs = { workspace = true, features = ["avif"] } +craft-avif-encode = { workspace = true, optional = true } [features] default = ["parallel", "jxl", "avif"] @@ -40,7 +40,7 @@ jxl = ["dep:craft-jxl"] # PhotoCraft); `cargo xtask ci` clippies and tests it (`--features heif`), releases don't ship it yet. heif = ["dep:craft-heif"] ## AVIF/AV1 encoding via craft-image-codecs / craft-video (pure Rust). Native targets only; a no-op on wasm32. -avif = ["dep:craft-video"] +avif = ["dep:craft-video", "dep:craft-avif-encode"] [dev-dependencies] # tests record why they skip (`cargo xtask ci` lists the skips) diff --git a/crates/codecs/src/encode.rs b/crates/codecs/src/encode.rs index d2f107dc9e..86be1c1ca7 100644 --- a/crates/codecs/src/encode.rs +++ b/crates/codecs/src/encode.rs @@ -290,9 +290,23 @@ pub fn encode_avif(img: &EncodeImage, quality: u8, speed: u8, meta: &EncodeMeta) img.validate()?; #[cfg(all(feature = "avif", not(target_arch = "wasm32")))] { - let mut ic_img = shared_image(img, Some("AVIF encoder needs 8- or 16-bit samples"))?; + // Keep AVIF on its threading-capable shared revision without changing other codecs. + use craft_avif_encode::{ChannelLayout, Image}; + let n = img.width as usize * img.height as usize * img.channels as usize; + let layout = match img.channels { + 1 => ChannelLayout::Gray, + 2 => ChannelLayout::GrayA, + 3 => ChannelLayout::Rgb, + _ => ChannelLayout::Rgba, + }; + let mut ic_img = match img.samples { + Samples::U8(s) => Image::from_u8(img.width, img.height, layout, s[..n].to_vec()), + Samples::U16(s) => Image::from_u16(img.width, img.height, layout, &s[..n]), + Samples::F32(_) => return Err(Error::Encode("AVIF encoder needs 8- or 16-bit samples".into())), + } + .map_err(|e| Error::Encode(e.to_string()))?; ic_img.meta.exif = meta.exif.map(|e| e.to_vec()); - craft_image_codecs::encode_avif_with_speed(&ic_img, quality, speed).map_err(|e| Error::Encode(e.to_string())) + craft_avif_encode::encode_avif_with_speed(&ic_img, quality, speed).map_err(|e| Error::Encode(e.to_string())) } #[cfg(not(all(feature = "avif", not(target_arch = "wasm32"))))] { @@ -370,10 +384,10 @@ pub fn encode_avif_hdr(width: u32, height: u32, rgb: &[f32], quality: u8, speed: { let _ = (w, h, n); let t = match transfer { - HdrTransfer::Pq => craft_image_codecs::HdrTransfer::Pq, - HdrTransfer::Hlg => craft_image_codecs::HdrTransfer::Hlg, + HdrTransfer::Pq => craft_avif_encode::HdrTransfer::Pq, + HdrTransfer::Hlg => craft_avif_encode::HdrTransfer::Hlg, }; - craft_image_codecs::encode_avif_hdr(width, height, rgb, quality, speed, meta.exif, t).map_err(|e| Error::Encode(e.to_string())) + craft_avif_encode::encode_avif_hdr(width, height, rgb, quality, speed, meta.exif, t).map_err(|e| Error::Encode(e.to_string())) } #[cfg(not(all(feature = "avif", not(target_arch = "wasm32"))))] { From 8a92b30605a381169e56baeb98fdbca67e6e2726 Mon Sep 17 00:00:00 2001 From: "Dylan M. Taylor" <dylan@dylanmtaylor.com> Date: Sun, 15 Nov 2026 20:55:54 -0500 Subject: [PATCH 50/61] build: pin AVIF threading to merged craft-libs --- Cargo.lock | 28 ++++++++++++++-------------- Cargo.toml | 4 ++-- 2 files changed, 16 insertions(+), 16 deletions(-) diff --git a/Cargo.lock b/Cargo.lock index 632fdd7190..1f276fab37 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -1296,12 +1296,12 @@ dependencies = [ [[package]] name = "craft-image-codecs" version = "0.1.0" -source = "git+https://github.com/storytold/craft-libs?rev=d99d0d3f9dc66ae74e0bf9991189545c51f6c037#d99d0d3f9dc66ae74e0bf9991189545c51f6c037" +source = "git+https://github.com/storytold/craft-libs?rev=5ac7c9664c8d54aaf69d1bb826e187686c1a4e1a#5ac7c9664c8d54aaf69d1bb826e187686c1a4e1a" dependencies = [ "avif-serialize", - "craft-jpeg 0.1.0 (git+https://github.com/storytold/craft-libs?rev=d99d0d3f9dc66ae74e0bf9991189545c51f6c037)", - "craft-metadata 0.1.0 (git+https://github.com/storytold/craft-libs?rev=d99d0d3f9dc66ae74e0bf9991189545c51f6c037)", - "craft-tiff 0.1.0 (git+https://github.com/storytold/craft-libs?rev=d99d0d3f9dc66ae74e0bf9991189545c51f6c037)", + "craft-jpeg 0.1.0 (git+https://github.com/storytold/craft-libs?rev=5ac7c9664c8d54aaf69d1bb826e187686c1a4e1a)", + "craft-metadata 0.1.0 (git+https://github.com/storytold/craft-libs?rev=5ac7c9664c8d54aaf69d1bb826e187686c1a4e1a)", + "craft-tiff 0.1.0 (git+https://github.com/storytold/craft-libs?rev=5ac7c9664c8d54aaf69d1bb826e187686c1a4e1a)", "crc32fast", "exr", "flate2", @@ -1334,7 +1334,7 @@ dependencies = [ [[package]] name = "craft-jpeg" version = "0.1.0" -source = "git+https://github.com/storytold/craft-libs?rev=d99d0d3f9dc66ae74e0bf9991189545c51f6c037#d99d0d3f9dc66ae74e0bf9991189545c51f6c037" +source = "git+https://github.com/storytold/craft-libs?rev=5ac7c9664c8d54aaf69d1bb826e187686c1a4e1a#5ac7c9664c8d54aaf69d1bb826e187686c1a4e1a" dependencies = [ "thiserror 2.0.21", ] @@ -1352,7 +1352,7 @@ dependencies = [ [[package]] name = "craft-media" version = "0.1.0" -source = "git+https://github.com/storytold/craft-libs?rev=d99d0d3f9dc66ae74e0bf9991189545c51f6c037#d99d0d3f9dc66ae74e0bf9991189545c51f6c037" +source = "git+https://github.com/storytold/craft-libs?rev=5ac7c9664c8d54aaf69d1bb826e187686c1a4e1a#5ac7c9664c8d54aaf69d1bb826e187686c1a4e1a" dependencies = [ "thiserror 2.0.21", ] @@ -1372,11 +1372,11 @@ dependencies = [ [[package]] name = "craft-metadata" version = "0.1.0" -source = "git+https://github.com/storytold/craft-libs?rev=94777dcf7f8962476e96b049d08d22e25b9330c2#94777dcf7f8962476e96b049d08d22e25b9330c2" +source = "git+https://github.com/storytold/craft-libs?rev=5ac7c9664c8d54aaf69d1bb826e187686c1a4e1a#5ac7c9664c8d54aaf69d1bb826e187686c1a4e1a" dependencies = [ "brotli-decompressor 6.0.1", "chrono", - "craft-tiff 0.1.0 (git+https://github.com/storytold/craft-libs?rev=94777dcf7f8962476e96b049d08d22e25b9330c2)", + "craft-tiff 0.1.0 (git+https://github.com/storytold/craft-libs?rev=5ac7c9664c8d54aaf69d1bb826e187686c1a4e1a)", "quick-xml 0.41.0", "serde", ] @@ -1384,11 +1384,11 @@ dependencies = [ [[package]] name = "craft-metadata" version = "0.1.0" -source = "git+https://github.com/storytold/craft-libs?rev=d99d0d3f9dc66ae74e0bf9991189545c51f6c037#d99d0d3f9dc66ae74e0bf9991189545c51f6c037" +source = "git+https://github.com/storytold/craft-libs?rev=94777dcf7f8962476e96b049d08d22e25b9330c2#94777dcf7f8962476e96b049d08d22e25b9330c2" dependencies = [ "brotli-decompressor 6.0.1", "chrono", - "craft-tiff 0.1.0 (git+https://github.com/storytold/craft-libs?rev=d99d0d3f9dc66ae74e0bf9991189545c51f6c037)", + "craft-tiff 0.1.0 (git+https://github.com/storytold/craft-libs?rev=94777dcf7f8962476e96b049d08d22e25b9330c2)", "quick-xml 0.41.0", "serde", ] @@ -1444,7 +1444,7 @@ dependencies = [ [[package]] name = "craft-tiff" version = "0.1.0" -source = "git+https://github.com/storytold/craft-libs?rev=94777dcf7f8962476e96b049d08d22e25b9330c2#94777dcf7f8962476e96b049d08d22e25b9330c2" +source = "git+https://github.com/storytold/craft-libs?rev=5ac7c9664c8d54aaf69d1bb826e187686c1a4e1a#5ac7c9664c8d54aaf69d1bb826e187686c1a4e1a" dependencies = [ "serde", "thiserror 2.0.21", @@ -1453,7 +1453,7 @@ dependencies = [ [[package]] name = "craft-tiff" version = "0.1.0" -source = "git+https://github.com/storytold/craft-libs?rev=d99d0d3f9dc66ae74e0bf9991189545c51f6c037#d99d0d3f9dc66ae74e0bf9991189545c51f6c037" +source = "git+https://github.com/storytold/craft-libs?rev=94777dcf7f8962476e96b049d08d22e25b9330c2#94777dcf7f8962476e96b049d08d22e25b9330c2" dependencies = [ "serde", "thiserror 2.0.21", @@ -1510,7 +1510,7 @@ dependencies = [ [[package]] name = "craft-video" version = "0.1.0" -source = "git+https://github.com/storytold/craft-libs?rev=d99d0d3f9dc66ae74e0bf9991189545c51f6c037#d99d0d3f9dc66ae74e0bf9991189545c51f6c037" +source = "git+https://github.com/storytold/craft-libs?rev=5ac7c9664c8d54aaf69d1bb826e187686c1a4e1a#5ac7c9664c8d54aaf69d1bb826e187686c1a4e1a" dependencies = [ "craft-media", "rav1e", @@ -3964,7 +3964,7 @@ dependencies = [ "craft-gif", "craft-heif", "craft-image-codecs 0.1.0 (git+https://github.com/storytold/craft-libs?rev=478c50560d3c6fad3d613af2a30b35c3bc9f4c0f)", - "craft-image-codecs 0.1.0 (git+https://github.com/storytold/craft-libs?rev=d99d0d3f9dc66ae74e0bf9991189545c51f6c037)", + "craft-image-codecs 0.1.0 (git+https://github.com/storytold/craft-libs?rev=5ac7c9664c8d54aaf69d1bb826e187686c1a4e1a)", "craft-jpeg 0.1.0 (git+https://github.com/storytold/craft-libs?rev=478c50560d3c6fad3d613af2a30b35c3bc9f4c0f)", "craft-jxl", "craft-psd", diff --git a/Cargo.toml b/Cargo.toml index a1cb736e6b..bdb0c1cb0e 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -24,9 +24,9 @@ craft-metadata = { git = "https://github.com/storytold/craft-libs", rev = "94777 craft-jpeg = { git = "https://github.com/storytold/craft-libs", rev = "478c50560d3c6fad3d613af2a30b35c3bc9f4c0f" } # AVIF EXIF, alpha quality and BT.2408 HLG levels (craft-libs#1448). craft-image-codecs = { git = "https://github.com/storytold/craft-libs", rev = "478c50560d3c6fad3d613af2a30b35c3bc9f4c0f" } -craft-video = { git = "https://github.com/storytold/craft-libs", rev = "d99d0d3f9dc66ae74e0bf9991189545c51f6c037", features = ["av1", "av1-large-encode", "threads"] } +craft-video = { git = "https://github.com/storytold/craft-libs", rev = "5ac7c9664c8d54aaf69d1bb826e187686c1a4e1a", features = ["av1", "av1-large-encode", "threads"] } # Isolate AVIF threading from the existing PNG/TIFF/WebP shared revision. -craft-avif-encode = { package = "craft-image-codecs", git = "https://github.com/storytold/craft-libs", rev = "d99d0d3f9dc66ae74e0bf9991189545c51f6c037", default-features = false, features = ["avif", "threads"] } +craft-avif-encode = { package = "craft-image-codecs", git = "https://github.com/storytold/craft-libs", rev = "5ac7c9664c8d54aaf69d1bb826e187686c1a4e1a", default-features = false, features = ["avif", "threads"] } craft-xml = { git = "https://github.com/storytold/craft-libs", rev = "f0f4758c01581d79577b9bf5046c06f4e77b1f18" } # craft-update: app-specific pretend versions apply to startup and manual checks. craft-update = { git = "https://github.com/storytold/craft-libs", version = "=0.1.0", rev = "6e03f65bf45181db77ba6229716e6624db9eb25b", features = ["egui"] } From 9a81246a52bfd9c83d1e7aa969290f9a48d57f03 Mon Sep 17 00:00:00 2001 From: "Dylan M. Taylor" <dylan@dylanmtaylor.com> Date: Sun, 15 Nov 2026 22:17:24 -0500 Subject: [PATCH 51/61] test: retain JXL post-header truncation coverage --- crates/codecs/tests/it/jxl_streaming.rs | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/crates/codecs/tests/it/jxl_streaming.rs b/crates/codecs/tests/it/jxl_streaming.rs index 401990b31f..310d308f8b 100644 --- a/crates/codecs/tests/it/jxl_streaming.rs +++ b/crates/codecs/tests/it/jxl_streaming.rs @@ -58,7 +58,7 @@ fn metadata_in_final_feed_matches_builder() { } #[test] -fn progressive_truncation_matches_builder() { +fn progressive_truncation_matches_shared_decoder() { let pixels = Rgba8::from_fn(96, 64, |x, y| { let mut seed = (y * 96 + x + 1) as u32; let mut rgb = [0; 4]; @@ -80,6 +80,13 @@ fn progressive_truncation_matches_builder() { for cut in [0, 1, 2, 12] { assert!(decode(&raw[..cut], DecodeOptions::default()).is_err(), "lossless={lossless}, cut={cut}/{}", raw.len()); } + // Progressive streams may contain a renderable partial frame. Preserve the + // post-header feed-boundary cases instead of requiring every truncation to fail. + for cut in [4095, 4096, 4097, raw.len() / 2, raw.len() - 1, raw.len()] { + let bytes = &raw[..cut]; + let shared_ok = craft_jxl::decode_with_color(bytes, craft_jxl::DecodeLimits::default(), craft_jxl::OutputColor::LinearRec2020).is_ok(); + assert_eq!(decode(bytes, DecodeOptions::default()).is_ok(), shared_ok, "lossless={lossless}, cut={cut}/{}", raw.len()); + } assert!(decode(&raw, DecodeOptions::default()).is_ok(), "lossless={lossless}"); } } From 0d61484dda9c0c75ee5edd0719c033819204aa3d Mon Sep 17 00:00:00 2001 From: "Dylan M. Taylor" <dylan@dylanmtaylor.com> Date: Sun, 15 Nov 2026 22:35:29 -0500 Subject: [PATCH 52/61] fix(codecs): preserve AV1 quality-100 quantizer --- Cargo.lock | 4 ++-- Cargo.toml | 2 +- crates/codecs/src/video.rs | 31 +++++++++++++++++++++++++++++-- 3 files changed, 32 insertions(+), 5 deletions(-) diff --git a/Cargo.lock b/Cargo.lock index 1f276fab37..a61b5d4a4d 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -1352,7 +1352,7 @@ dependencies = [ [[package]] name = "craft-media" version = "0.1.0" -source = "git+https://github.com/storytold/craft-libs?rev=5ac7c9664c8d54aaf69d1bb826e187686c1a4e1a#5ac7c9664c8d54aaf69d1bb826e187686c1a4e1a" +source = "git+https://github.com/storytold/craft-libs?rev=f450b5b59131e01d318ad398e8534899ca5a5aad#f450b5b59131e01d318ad398e8534899ca5a5aad" dependencies = [ "thiserror 2.0.21", ] @@ -1510,7 +1510,7 @@ dependencies = [ [[package]] name = "craft-video" version = "0.1.0" -source = "git+https://github.com/storytold/craft-libs?rev=5ac7c9664c8d54aaf69d1bb826e187686c1a4e1a#5ac7c9664c8d54aaf69d1bb826e187686c1a4e1a" +source = "git+https://github.com/storytold/craft-libs?rev=f450b5b59131e01d318ad398e8534899ca5a5aad#f450b5b59131e01d318ad398e8534899ca5a5aad" dependencies = [ "craft-media", "rav1e", diff --git a/Cargo.toml b/Cargo.toml index bdb0c1cb0e..09552e6abe 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -24,7 +24,7 @@ craft-metadata = { git = "https://github.com/storytold/craft-libs", rev = "94777 craft-jpeg = { git = "https://github.com/storytold/craft-libs", rev = "478c50560d3c6fad3d613af2a30b35c3bc9f4c0f" } # AVIF EXIF, alpha quality and BT.2408 HLG levels (craft-libs#1448). craft-image-codecs = { git = "https://github.com/storytold/craft-libs", rev = "478c50560d3c6fad3d613af2a30b35c3bc9f4c0f" } -craft-video = { git = "https://github.com/storytold/craft-libs", rev = "5ac7c9664c8d54aaf69d1bb826e187686c1a4e1a", features = ["av1", "av1-large-encode", "threads"] } +craft-video = { git = "https://github.com/storytold/craft-libs", rev = "f450b5b59131e01d318ad398e8534899ca5a5aad", features = ["av1", "av1-large-encode", "threads"] } # Isolate AVIF threading from the existing PNG/TIFF/WebP shared revision. craft-avif-encode = { package = "craft-image-codecs", git = "https://github.com/storytold/craft-libs", rev = "5ac7c9664c8d54aaf69d1bb826e187686c1a4e1a", default-features = false, features = ["avif", "threads"] } craft-xml = { git = "https://github.com/storytold/craft-libs", rev = "f0f4758c01581d79577b9bf5046c06f4e77b1f18" } diff --git a/crates/codecs/src/video.rs b/crates/codecs/src/video.rs index 6a8e3c6f8a..35a6b79311 100644 --- a/crates/codecs/src/video.rs +++ b/crates/codecs/src/video.rs @@ -852,9 +852,9 @@ impl Av1Encoder { { use craft_video::av1::{EncoderConfig, RateControl}; let mut ec = EncoderConfig::new(w as u32, h as u32, c.fps, 1); - ec.rate = RateControl::ConstantQ(quantizer(c.quality).clamp(1, 255) as u8); + ec.rate = RateControl::ConstantQ(quantizer(c.quality) as u8); ec.keyint = 120; - let enc = craft_video::av1::LargeEncoder::with_speed(&ec, c.speed).map_err(|e| bad(format!("AV1: {e}")))?; + let enc = craft_video::av1::LargeEncoder::with_exact_quantizer(&ec, c.speed).map_err(|e| bad(format!("AV1: {e}")))?; Ok(Av1Encoder { enc, durations: Vec::new(), returned: 0, failed: false, width: w, height: h }) } #[cfg(not(all(feature = "avif", not(target_arch = "wasm32"))))] @@ -1167,6 +1167,33 @@ mod tests { assert!(encoder.config_record().is_some()); } + #[cfg(all(feature = "avif", not(target_arch = "wasm32")))] + #[test] + fn av1_quality_100_preserves_the_exact_zero_quantizer() { + assert_eq!(quantizer(100), 0); + let image: Vec<[u8; 4]> = (0..64 * 48).map(|i| [(i * 13) as u8, (i * 41) as u8, (i * 73) as u8, 255]).collect(); + let cfg = VideoConfig { width: 64, height: 48, fps: 24, quality: 100, speed: 10 }; + let mut actual = Av1Encoder::new(&cfg).unwrap(); + let mut samples = actual.push(&image, 7, true).unwrap(); + samples.extend(actual.finish().unwrap()); + + let (y, u, v) = yuv420(&image, 64, 48).unwrap(); + let y: Vec<u16> = y.into_iter().map(u16::from).collect(); + let u: Vec<u16> = u.into_iter().map(u16::from).collect(); + let v: Vec<u16> = v.into_iter().map(u16::from).collect(); + let frame = craft_video::av1::Frame { y: &y, u: &u, v: &v, y_stride: 64, uv_stride: 32 }; + let mut ec = craft_video::av1::EncoderConfig::new(64, 48, 24, 1); + ec.rate = craft_video::av1::RateControl::ConstantQ(0); + ec.keyint = 120; + let mut exact = craft_video::av1::LargeEncoder::with_exact_quantizer(&ec, 10).unwrap(); + let mut expected = exact.push(&frame, true).unwrap(); + expected.extend(exact.finish().unwrap()); + assert_eq!(samples.len(), 1); + assert_eq!(samples[0].data, expected[0].packet.data); + assert_eq!(samples[0].duration, 7); + assert!(samples[0].key); + } + #[cfg(all(feature = "avif", not(target_arch = "wasm32")))] #[test] fn av1_speed_affects_normal_sized_frames() { From 2f7a797ed86b840e07432d558148c580941be440 Mon Sep 17 00:00:00 2001 From: "Dylan M. Taylor" <dylan@dylanmtaylor.com> Date: Sun, 15 Nov 2026 23:45:45 -0500 Subject: [PATCH 53/61] chore(codecs): pin merged exact AV1 quantizer support --- Cargo.lock | 4 ++-- Cargo.toml | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/Cargo.lock b/Cargo.lock index a61b5d4a4d..8074dddfe0 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -1352,7 +1352,7 @@ dependencies = [ [[package]] name = "craft-media" version = "0.1.0" -source = "git+https://github.com/storytold/craft-libs?rev=f450b5b59131e01d318ad398e8534899ca5a5aad#f450b5b59131e01d318ad398e8534899ca5a5aad" +source = "git+https://github.com/storytold/craft-libs?rev=5c91598ccc86537a779f438d520fa6406c26efe6#5c91598ccc86537a779f438d520fa6406c26efe6" dependencies = [ "thiserror 2.0.21", ] @@ -1510,7 +1510,7 @@ dependencies = [ [[package]] name = "craft-video" version = "0.1.0" -source = "git+https://github.com/storytold/craft-libs?rev=f450b5b59131e01d318ad398e8534899ca5a5aad#f450b5b59131e01d318ad398e8534899ca5a5aad" +source = "git+https://github.com/storytold/craft-libs?rev=5c91598ccc86537a779f438d520fa6406c26efe6#5c91598ccc86537a779f438d520fa6406c26efe6" dependencies = [ "craft-media", "rav1e", diff --git a/Cargo.toml b/Cargo.toml index 09552e6abe..d0d8386488 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -24,7 +24,7 @@ craft-metadata = { git = "https://github.com/storytold/craft-libs", rev = "94777 craft-jpeg = { git = "https://github.com/storytold/craft-libs", rev = "478c50560d3c6fad3d613af2a30b35c3bc9f4c0f" } # AVIF EXIF, alpha quality and BT.2408 HLG levels (craft-libs#1448). craft-image-codecs = { git = "https://github.com/storytold/craft-libs", rev = "478c50560d3c6fad3d613af2a30b35c3bc9f4c0f" } -craft-video = { git = "https://github.com/storytold/craft-libs", rev = "f450b5b59131e01d318ad398e8534899ca5a5aad", features = ["av1", "av1-large-encode", "threads"] } +craft-video = { git = "https://github.com/storytold/craft-libs", rev = "5c91598ccc86537a779f438d520fa6406c26efe6", features = ["av1", "av1-large-encode", "threads"] } # Isolate AVIF threading from the existing PNG/TIFF/WebP shared revision. craft-avif-encode = { package = "craft-image-codecs", git = "https://github.com/storytold/craft-libs", rev = "5ac7c9664c8d54aaf69d1bb826e187686c1a4e1a", default-features = false, features = ["avif", "threads"] } craft-xml = { git = "https://github.com/storytold/craft-libs", rev = "f0f4758c01581d79577b9bf5046c06f4e77b1f18" } From 0466978870fde4b5215eea8e7fa50bd313eec194 Mon Sep 17 00:00:00 2001 From: "Dylan M. Taylor" <dylan@dylanmtaylor.com> Date: Mon, 16 Nov 2026 01:34:37 -0500 Subject: [PATCH 54/61] test(codecs): preserve two-plane JXL fixture and large AV1 coverage --- crates/codecs/src/video.rs | 16 ++++++++++++++++ crates/raw/tests/it/dng.rs | 15 ++++++--------- 2 files changed, 22 insertions(+), 9 deletions(-) diff --git a/crates/codecs/src/video.rs b/crates/codecs/src/video.rs index 35a6b79311..0d2df2962f 100644 --- a/crates/codecs/src/video.rs +++ b/crates/codecs/src/video.rs @@ -1167,6 +1167,22 @@ mod tests { assert!(encoder.config_record().is_some()); } + #[cfg(all(feature = "avif", not(target_arch = "wasm32")))] + #[test] + fn av1_preserves_frame_sizes_above_the_old_area_limit() { + for (width, height) in [(5120, 2160), (4096, 4096)] { + let cfg = VideoConfig { width, height, fps: 30, quality: 60, speed: 10 }; + let mut encoder = Av1Encoder::new(&cfg).unwrap(); + let mut samples = encoder.push(&vec![[80, 120, 180, 255]; width as usize * height as usize], 7, true).unwrap(); + samples.extend(encoder.finish().unwrap()); + assert_eq!(samples.len(), 1, "{width}x{height}"); + assert!(!samples[0].data.is_empty()); + assert_eq!(samples[0].duration, 7); + assert!(samples[0].key); + assert!(encoder.config_record().is_some()); + } + } + #[cfg(all(feature = "avif", not(target_arch = "wasm32")))] #[test] fn av1_quality_100_preserves_the_exact_zero_quantizer() { diff --git a/crates/raw/tests/it/dng.rs b/crates/raw/tests/it/dng.rs index 0f317af3b3..84ef1d29af 100644 --- a/crates/raw/tests/it/dng.rs +++ b/crates/raw/tests/it/dng.rs @@ -805,21 +805,18 @@ fn jpeg_xl_tiles_beyond_their_decode_budget_are_errors() { let (w, h) = (512, 512); let grey: Vec<u16> = (0..w * h).map(|i| ((i % w) * 97 + (i / w) * 31) as u16 & 0x0fff).collect(); let with_alpha: Vec<u16> = grey.iter().flat_map(|&v| [v, 4095 - v]).collect(); - let img = craft_jxl::ImageRef { - width: w as u32, - height: h as u32, - layout: craft_jxl::Layout::GrayAlpha, - samples: craft_jxl::Samples::U16(&with_alpha), - }; - let opts = craft_jxl::EncodeOptions { lossless: true, ..Default::default() }; - let tile = craft_jxl::encode(&img, opts, &craft_jxl::Metadata::default()).unwrap(); + // The public craft-jxl image encoder widens GrayAlpha to RGBA. This budget fixture + // specifically needs two encoded planes, not a four-plane layout mismatch. + let config = jixel::EncodeConfig::default().with_lossless(true); + let tile = jixel::encode_image_gray_alpha_16bit(&with_alpha, w, h, &config).unwrap(); let one = |tile: Vec<u8>| { let mut raw = base_ifd(w, h, 12, 1, true); raw.set(t::COMPRESSION, Value::Short(vec![compression::JPEG_XL])); raw.set_image(ImageData::Tiles { tile_width: w as u32, tile_height: h as u32, tiles: vec![tile] }); dng(raw, ByteOrder::Little) }; - assert!(matches!(decode(&one(tile)), Err(RawError::Corrupt(_)))); + let Err(RawError::Corrupt(error)) = decode(&one(tile)) else { panic!("the extra plane must exceed the tile budget") }; + assert!(!error.contains("colour planes"), "must fail the budget, not the fixture layout: {error}"); assert_eq!(decode(&one(jxl_encode(&grey, w, h, 1, false))).unwrap().data, RawData::U16(grey)); } From 3b0c91f44b5e2e51debbe830844c8a0a4e2f4db9 Mon Sep 17 00:00:00 2001 From: FredApps <153173854+FredApps@users.noreply.github.com> Date: Mon, 16 Nov 2026 07:39:36 +0100 Subject: [PATCH 55/61] Regenerate Flatpak cargo sources for the craft-video and craft-image-codecs pins --- packaging/linux/flatpak/cargo-sources.json | 130 ++++++++++++++++++++- 1 file changed, 125 insertions(+), 5 deletions(-) diff --git a/packaging/linux/flatpak/cargo-sources.json b/packaging/linux/flatpak/cargo-sources.json index 58c13aa3ae..ac13e79301 100644 --- a/packaging/linux/flatpak/cargo-sources.json +++ b/packaging/linux/flatpak/cargo-sources.json @@ -35,6 +35,18 @@ "commit": "478c50560d3c6fad3d613af2a30b35c3bc9f4c0f", "dest": "flatpak-cargo/git/craft-libs-478c505" }, + { + "type": "git", + "url": "https://github.com/storytold/craft-libs", + "commit": "5ac7c9664c8d54aaf69d1bb826e187686c1a4e1a", + "dest": "flatpak-cargo/git/craft-libs-5ac7c96" + }, + { + "type": "git", + "url": "https://github.com/storytold/craft-libs", + "commit": "5c91598ccc86537a779f438d520fa6406c26efe6", + "dest": "flatpak-cargo/git/craft-libs-5c91598" + }, { "type": "git", "url": "https://github.com/storytold/craft-libs", @@ -1747,6 +1759,24 @@ "dest": "cargo/vendor-git/cb31475a7a9d19c00f48b4c43603f2f1a464c6dce15da1d21bba4c653eeba6b2/craft-image-codecs", "dest-filename": ".cargo-checksum.json" }, + { + "type": "shell", + "commands": [ + "mkdir -p \"cargo/vendor-git/9100d311acc530b0286234c55b78dbdc0325d5e30950478c5c7864bfed7a4545\" && cp -r --reflink=auto \"flatpak-cargo/git/craft-libs-5ac7c96/crates/image-codecs\" \"cargo/vendor-git/9100d311acc530b0286234c55b78dbdc0325d5e30950478c5c7864bfed7a4545/craft-image-codecs\"" + ] + }, + { + "type": "inline", + "contents": "[package]\nname = \"craft-image-codecs\"\ndescription = \"Bounded, depth- and metadata-preserving codecs for flat raster image formats\"\nversion = \"0.1.0\"\nedition = \"2024\"\nlicense = \"MIT OR Apache-2.0\"\nrust-version = \"1.95\"\nrepository = \"https://github.com/storytold/craft-libs\"\n\n[lints.rust]\nunsafe_code = \"forbid\"\nunused_workspace_dependencies = \"allow\"\n\n[lints.rust.unexpected_cfgs]\nlevel = \"warn\"\ncheck-cfg = [\"cfg(craft_pdf_unicode_fixtures)\"]\n\n[lints.clippy]\ncognitive_complexity = \"deny\"\ntoo_many_arguments = \"deny\"\nunused_workspace_dependencies = \"allow\"\nwildcard_imports = \"deny\"\ndbg_macro = \"warn\"\ntodo = \"warn\"\n\n[features]\ncorpus = []\ndefault = []\nthreads = [\"ravif?/threading\", \"rav1e?/threading\"]\nsgi = []\nsunraster = []\navif = [\"image/avif\", \"dep:ravif\", \"dep:rav1e\", \"dep:avif-serialize\"]\nheif = [\"dep:craft-heif\"]\navif-decode = [\"dep:craft-video\", \"craft-video/av1-decode\"]\n\n[dependencies]\ncrc32fast = \"1.5\"\nthiserror = \"2\"\npng = \"0.18\"\nhalf = \"2\"\nserde_json = \"1\"\nimage-webp = \"0.2\"\nzune-jpeg = \"0.5\"\nzune-core = \"0.5\"\njpeg-encoder = \"0.6\"\n\n[dependencies.image]\nversion = \"0.25\"\ndefault-features = false\nfeatures = [\"png\", \"jpeg\", \"tiff\", \"gif\", \"bmp\", \"tga\", \"ico\", \"qoi\", \"hdr\"]\n\n[dependencies.tiff]\nversion = \"0.11\"\ndefault-features = false\nfeatures = [\"deflate\", \"fax\", \"jpeg\", \"lzw\"]\n\n[dependencies.exr]\nversion = \"1.73\"\ndefault-features = false\n\n[dependencies.flate2]\nversion = \"1.1.10\"\ndefault-features = false\nfeatures = [\"zlib-rs\", \"runtime_detection\"]\n\n[dependencies.craft-jpeg]\npath = \"crates/jpeg\"\n\n[dependencies.craft-metadata]\npath = \"crates/metadata\"\n\n[dependencies.craft-tiff]\npath = \"crates/tiff\"\n\n[dependencies.zune-jpegxl]\nversion = \"=0.5.2\"\ndefault-features = false\nfeatures = [\"std\"]\n\n[dependencies.craft-heif]\noptional = true\npath = \"crates/heif\"\n\n[dependencies.ravif]\nversion = \"0.13\"\ndefault-features = false\noptional = true\n\n[dependencies.rav1e]\nversion = \"0.8\"\ndefault-features = false\noptional = true\n\n[dependencies.avif-serialize]\nversion = \"0.8\"\noptional = true\n\n[dependencies.hayro-jpeg2000]\nversion = \"=0.3.5\"\ndefault-features = false\nfeatures = [\"std\", \"simd\"]\n\n[target.\"cfg(not(target_arch = \\\"wasm32\\\"))\".dependencies]\nrayon = \"1\"\n\n[target.\"cfg(not(target_arch = \\\"wasm32\\\"))\".dependencies.craft-video]\noptional = true\npath = \"crates/video\"\n\n[target.\"cfg(not(target_arch = \\\"wasm32\\\"))\".dependencies.exr]\nversion = \"1.73\"\ndefault-features = false\nfeatures = [\"rayon\"]\n\n[target.\"cfg(not(target_arch = \\\"wasm32\\\"))\".dev-dependencies.craft-video]\nfeatures = [\"av1-decode\"]\npath = \"crates/video\"\n\n[target.\"cfg(not(target_arch = \\\"wasm32\\\"))\".dev-dependencies.jxl-oxide]\nversion = \"=0.12.6\"\ndefault-features = false\nfeatures = [\"rayon\"]\n\n[dev-dependencies]\nproptest = \"1\"\n\n[dev-dependencies.image]\nversion = \"0.25\"\ndefault-features = false\nfeatures = [\"png\", \"jpeg\", \"tiff\"]\n\n[dev-dependencies.sha2]\nversion = \"0.10\"\ndefault-features = false\nfeatures = [\"std\"]\n\n[dev-dependencies.craft-media-testkit]\npath = \"crates/media-testkit\"\n", + "dest": "cargo/vendor-git/9100d311acc530b0286234c55b78dbdc0325d5e30950478c5c7864bfed7a4545/craft-image-codecs", + "dest-filename": "Cargo.toml" + }, + { + "type": "inline", + "contents": "{\"package\": null, \"files\": {}}", + "dest": "cargo/vendor-git/9100d311acc530b0286234c55b78dbdc0325d5e30950478c5c7864bfed7a4545/craft-image-codecs", + "dest-filename": ".cargo-checksum.json" + }, { "type": "shell", "commands": [ @@ -1768,19 +1798,55 @@ { "type": "shell", "commands": [ - "mkdir -p \"cargo/vendor-git/a51e2c3f46af71f1caed91009f88b4f9982db0c4152c6659d11967a7731b1ccc\" && cp -r --reflink=auto \"flatpak-cargo/git/craft-libs-b77af38/crates/jxl\" \"cargo/vendor-git/a51e2c3f46af71f1caed91009f88b4f9982db0c4152c6659d11967a7731b1ccc/craft-jxl\"" + "mkdir -p \"cargo/vendor-git/9100d311acc530b0286234c55b78dbdc0325d5e30950478c5c7864bfed7a4545\" && cp -r --reflink=auto \"flatpak-cargo/git/craft-libs-5ac7c96/crates/jpeg\" \"cargo/vendor-git/9100d311acc530b0286234c55b78dbdc0325d5e30950478c5c7864bfed7a4545/craft-jpeg\"" ] }, { "type": "inline", - "contents": "[package]\nname = \"craft-jxl\"\ndescription = \"JPEG XL image decoding and encoding with bounded input and allocation tracking.\"\nversion = \"0.1.0\"\nedition = \"2024\"\nlicense = \"MIT OR Apache-2.0\"\nrust-version = \"1.95\"\nrepository = \"https://github.com/storytold/craft-libs\"\n\n[lints.rust]\nunsafe_code = \"forbid\"\nunused_workspace_dependencies = \"allow\"\n\n[lints.rust.unexpected_cfgs]\nlevel = \"warn\"\ncheck-cfg = [\"cfg(craft_pdf_unicode_fixtures)\"]\n\n[lints.clippy]\ncognitive_complexity = \"deny\"\ntoo_many_arguments = \"deny\"\nunused_workspace_dependencies = \"allow\"\nwildcard_imports = \"deny\"\ndbg_macro = \"warn\"\ntodo = \"warn\"\n\n[features]\ndefault = [\"decode\", \"encode\"]\ndecode = [\"dep:jxl-oxide\"]\nencode = [\"dep:jixel\"]\n\n[dependencies]\nthiserror = \"2\"\n\n[dependencies.jxl-oxide]\noptional = true\nversion = \"0.12\"\ndefault-features = false\n\n[dev-dependencies.craft-cms]\npath = \"crates/cms\"\n\n[target.\"cfg(not(target_arch = \\\"wasm32\\\"))\".dependencies.jixel]\noptional = true\nversion = \"=0.3.4\"\n", - "dest": "cargo/vendor-git/a51e2c3f46af71f1caed91009f88b4f9982db0c4152c6659d11967a7731b1ccc/craft-jxl", + "contents": "[package]\nname = \"craft-jpeg\"\ndescription = \"Clean-room JPEG decoder and 8-bit optimized baseline encoder (ITU-T T.81).\"\nversion = \"0.1.0\"\nedition = \"2024\"\nlicense = \"MIT OR Apache-2.0\"\nrust-version = \"1.95\"\nrepository = \"https://github.com/storytold/craft-libs\"\n\n[lints.rust]\nunsafe_code = \"forbid\"\nunused_workspace_dependencies = \"allow\"\n\n[lints.rust.unexpected_cfgs]\nlevel = \"warn\"\ncheck-cfg = [\"cfg(craft_pdf_unicode_fixtures)\"]\n\n[lints.clippy]\ncognitive_complexity = \"deny\"\ntoo_many_arguments = \"deny\"\nunused_workspace_dependencies = \"allow\"\nwildcard_imports = \"deny\"\ndbg_macro = \"warn\"\ntodo = \"warn\"\n\n[dependencies]\nthiserror = \"2\"\n\n[dependencies.rayon]\noptional = true\nversion = \"1\"\n\n[dev-dependencies]\njpeg-encoder = \"0.6\"\nzune-jpeg = \"0.5\"\njpeg-decoder = \"0.3\"\n\n[features]\ndefault = []\nparallel = [\"dep:rayon\"]\n", + "dest": "cargo/vendor-git/9100d311acc530b0286234c55b78dbdc0325d5e30950478c5c7864bfed7a4545/craft-jpeg", "dest-filename": "Cargo.toml" }, { "type": "inline", "contents": "{\"package\": null, \"files\": {}}", - "dest": "cargo/vendor-git/a51e2c3f46af71f1caed91009f88b4f9982db0c4152c6659d11967a7731b1ccc/craft-jxl", + "dest": "cargo/vendor-git/9100d311acc530b0286234c55b78dbdc0325d5e30950478c5c7864bfed7a4545/craft-jpeg", + "dest-filename": ".cargo-checksum.json" + }, + { + "type": "shell", + "commands": [ + "mkdir -p \"cargo/vendor-git/cb31475a7a9d19c00f48b4c43603f2f1a464c6dce15da1d21bba4c653eeba6b2\" && cp -r --reflink=auto \"flatpak-cargo/git/craft-libs-478c505/crates/jxl\" \"cargo/vendor-git/cb31475a7a9d19c00f48b4c43603f2f1a464c6dce15da1d21bba4c653eeba6b2/craft-jxl\"" + ] + }, + { + "type": "inline", + "contents": "[package]\nname = \"craft-jxl\"\ndescription = \"JPEG XL image decoding and encoding with bounded input and allocation tracking.\"\nversion = \"0.1.0\"\nedition = \"2024\"\nlicense = \"MIT OR Apache-2.0\"\nrust-version = \"1.95\"\nrepository = \"https://github.com/storytold/craft-libs\"\n\n[lints.rust]\nunsafe_code = \"forbid\"\nunused_workspace_dependencies = \"allow\"\n\n[lints.rust.unexpected_cfgs]\nlevel = \"warn\"\ncheck-cfg = [\"cfg(craft_pdf_unicode_fixtures)\"]\n\n[lints.clippy]\ncognitive_complexity = \"deny\"\ntoo_many_arguments = \"deny\"\nunused_workspace_dependencies = \"allow\"\nwildcard_imports = \"deny\"\ndbg_macro = \"warn\"\ntodo = \"warn\"\n\n[features]\ndefault = [\"decode\", \"encode\"]\ndecode = [\"dep:jxl-oxide\"]\nencode = [\"dep:jixel\"]\n\n[dependencies]\nthiserror = \"2\"\n\n[dependencies.jxl-oxide]\noptional = true\nversion = \"0.12\"\ndefault-features = false\n\n[dev-dependencies.craft-cms]\npath = \"crates/cms\"\n\n[target.\"cfg(not(target_arch = \\\"wasm32\\\"))\".dependencies.jixel]\noptional = true\nversion = \"=0.3.4\"\n", + "dest": "cargo/vendor-git/cb31475a7a9d19c00f48b4c43603f2f1a464c6dce15da1d21bba4c653eeba6b2/craft-jxl", + "dest-filename": "Cargo.toml" + }, + { + "type": "inline", + "contents": "{\"package\": null, \"files\": {}}", + "dest": "cargo/vendor-git/cb31475a7a9d19c00f48b4c43603f2f1a464c6dce15da1d21bba4c653eeba6b2/craft-jxl", + "dest-filename": ".cargo-checksum.json" + }, + { + "type": "shell", + "commands": [ + "mkdir -p \"cargo/vendor-git/6f5ad8618176b3fc0aac703e6e74df7229b0350b4574c7edbe0bb86c53c1cb6c\" && cp -r --reflink=auto \"flatpak-cargo/git/craft-libs-5c91598/crates/media\" \"cargo/vendor-git/6f5ad8618176b3fc0aac703e6e74df7229b0350b4574c7edbe0bb86c53c1cb6c/craft-media\"" + ] + }, + { + "type": "inline", + "contents": "[package]\nname = \"craft-media\"\ndescription = \"Bit-level I/O, clean-room ISO BMFF (MP4), QuickTime (MOV) and Matroska (MKV, WebM) and MXF demuxers and muxers, and Ogg, AVI and MPEG-TS/PS demuxers.\"\nversion = \"0.1.0\"\nedition = \"2024\"\nlicense = \"MIT OR Apache-2.0\"\nrust-version = \"1.95\"\nrepository = \"https://github.com/storytold/craft-libs\"\n\n[package.metadata.docs.rs]\nall-features = true\n\n[lints.rust]\nunsafe_code = \"forbid\"\nunused_workspace_dependencies = \"allow\"\n\n[lints.rust.unexpected_cfgs]\nlevel = \"warn\"\ncheck-cfg = [\"cfg(craft_pdf_unicode_fixtures)\"]\n\n[lints.clippy]\ncognitive_complexity = \"deny\"\ntoo_many_arguments = \"deny\"\nunused_workspace_dependencies = \"allow\"\nwildcard_imports = \"deny\"\ndbg_macro = \"warn\"\ntodo = \"warn\"\n\n[features]\ndefault = [\"isobmff\"]\nbitstream = []\nisobmff = [\"bitstream\", \"dep:thiserror\"]\nmatroska = []\navi = []\nmxf = [\"dep:chrono\"]\nmpegts = []\nogg = []\nserde = [\"dep:serde\"]\n\n[dependencies.thiserror]\noptional = true\nversion = \"2\"\n\n[dependencies.serde]\noptional = true\nversion = \"1\"\nfeatures = [\"derive\"]\n\n[dependencies.chrono]\noptional = true\nversion = \"0.4.45\"\ndefault-features = false\nfeatures = [\"std\"]\n\n[dev-dependencies]\nproptest = \"1\"\nserde_json = \"1\"\n\n[dev-dependencies.craft-media-testkit]\npath = \"crates/media-testkit\"\n\n[[test]]\nname = \"fuzz\"\nrequired-features = [\"isobmff\"]\n\n[[test]]\nname = \"fuzz_matroska\"\nrequired-features = [\"matroska\"]\n\n[[test]]\nname = \"oracle_avi\"\nrequired-features = [\"avi\"]\n\n[[test]]\nname = \"oracle_avi_mux\"\nrequired-features = [\"avi\"]\n\n[[test]]\nname = \"oracle_demux\"\nrequired-features = [\"isobmff\"]\n\n[[test]]\nname = \"oracle_matroska\"\nrequired-features = [\"matroska\"]\n\n[[test]]\nname = \"oracle_mpegts\"\nrequired-features = [\"mpegts\"]\n\n[[test]]\nname = \"oracle_mux\"\nrequired-features = [\"isobmff\"]\n\n[[test]]\nname = \"oracle_mxf\"\nrequired-features = [\"mxf\"]\n\n[[test]]\nname = \"oracle_ogg\"\nrequired-features = [\"ogg\"]\n\n[[test]]\nname = \"roundtrip\"\nrequired-features = [\"isobmff\"]\n", + "dest": "cargo/vendor-git/6f5ad8618176b3fc0aac703e6e74df7229b0350b4574c7edbe0bb86c53c1cb6c/craft-media", + "dest-filename": "Cargo.toml" + }, + { + "type": "inline", + "contents": "{\"package\": null, \"files\": {}}", + "dest": "cargo/vendor-git/6f5ad8618176b3fc0aac703e6e74df7229b0350b4574c7edbe0bb86c53c1cb6c/craft-media", "dest-filename": ".cargo-checksum.json" }, { @@ -1801,6 +1867,24 @@ "dest": "cargo/vendor-git/cb31475a7a9d19c00f48b4c43603f2f1a464c6dce15da1d21bba4c653eeba6b2/craft-metadata", "dest-filename": ".cargo-checksum.json" }, + { + "type": "shell", + "commands": [ + "mkdir -p \"cargo/vendor-git/9100d311acc530b0286234c55b78dbdc0325d5e30950478c5c7864bfed7a4545\" && cp -r --reflink=auto \"flatpak-cargo/git/craft-libs-5ac7c96/crates/metadata\" \"cargo/vendor-git/9100d311acc530b0286234c55b78dbdc0325d5e30950478c5c7864bfed7a4545/craft-metadata\"" + ] + }, + { + "type": "inline", + "contents": "[package]\nname = \"craft-metadata\"\ndescription = \"Photo metadata: EXIF, IPTC-IIM, XMP packets (read, write, merge) and GPX track logs, the blocks that carry them in JPEG, PNG, WebP, TIFF and CR3 files, and one model they all read into.\"\nversion = \"0.1.0\"\nedition = \"2024\"\nlicense = \"MIT OR Apache-2.0\"\nrust-version = \"1.95\"\nrepository = \"https://github.com/storytold/craft-libs\"\n\n[lints.rust]\nunsafe_code = \"forbid\"\nunused_workspace_dependencies = \"allow\"\n\n[lints.rust.unexpected_cfgs]\nlevel = \"warn\"\ncheck-cfg = [\"cfg(craft_pdf_unicode_fixtures)\"]\n\n[lints.clippy]\ncognitive_complexity = \"deny\"\ntoo_many_arguments = \"deny\"\nunused_workspace_dependencies = \"allow\"\nwildcard_imports = \"deny\"\ndbg_macro = \"warn\"\ntodo = \"warn\"\n\n[dependencies]\nquick-xml = \"0.41\"\n\n[dependencies.craft-tiff]\npath = \"crates/tiff\"\n\n[dependencies.serde]\nversion = \"1\"\nfeatures = [\"derive\"]\n\n[dependencies.chrono]\nversion = \"0.4.45\"\ndefault-features = false\nfeatures = [\"std\"]\n\n[dependencies.brotli-decompressor]\nversion = \"6\"\ndefault-features = false\nfeatures = [\"std\"]\n\n[dev-dependencies]\nproptest = \"1\"\nserde_json = \"1\"\n\n[dev-dependencies.brotli]\nversion = \"9\"\ndefault-features = false\nfeatures = [\"std\"]\n", + "dest": "cargo/vendor-git/9100d311acc530b0286234c55b78dbdc0325d5e30950478c5c7864bfed7a4545/craft-metadata", + "dest-filename": "Cargo.toml" + }, + { + "type": "inline", + "contents": "{\"package\": null, \"files\": {}}", + "dest": "cargo/vendor-git/9100d311acc530b0286234c55b78dbdc0325d5e30950478c5c7864bfed7a4545/craft-metadata", + "dest-filename": ".cargo-checksum.json" + }, { "type": "shell", "commands": [ @@ -1909,6 +1993,24 @@ "dest": "cargo/vendor-git/cb31475a7a9d19c00f48b4c43603f2f1a464c6dce15da1d21bba4c653eeba6b2/craft-tiff", "dest-filename": ".cargo-checksum.json" }, + { + "type": "shell", + "commands": [ + "mkdir -p \"cargo/vendor-git/9100d311acc530b0286234c55b78dbdc0325d5e30950478c5c7864bfed7a4545\" && cp -r --reflink=auto \"flatpak-cargo/git/craft-libs-5ac7c96/crates/tiff\" \"cargo/vendor-git/9100d311acc530b0286234c55b78dbdc0325d5e30950478c5c7864bfed7a4545/craft-tiff\"" + ] + }, + { + "type": "inline", + "contents": "[package]\nname = \"craft-tiff\"\ndescription = \"TIFF and BigTIFF IFD reader and writer: every field type, the Exif/GPS/Interop pointer IFDs, maker-note IFDs, strip and tile layout.\"\nversion = \"0.1.0\"\nedition = \"2024\"\nlicense = \"MIT OR Apache-2.0\"\nrust-version = \"1.95\"\nrepository = \"https://github.com/storytold/craft-libs\"\n\n[lints.rust]\nunsafe_code = \"forbid\"\nunused_workspace_dependencies = \"allow\"\n\n[lints.rust.unexpected_cfgs]\nlevel = \"warn\"\ncheck-cfg = [\"cfg(craft_pdf_unicode_fixtures)\"]\n\n[lints.clippy]\ncognitive_complexity = \"deny\"\ntoo_many_arguments = \"deny\"\nunused_workspace_dependencies = \"allow\"\nwildcard_imports = \"deny\"\ndbg_macro = \"warn\"\ntodo = \"warn\"\n\n[dependencies]\nthiserror = \"2\"\n\n[dependencies.serde]\nversion = \"1\"\nfeatures = [\"derive\"]\n\n[dev-dependencies]\nproptest = \"1\"\n", + "dest": "cargo/vendor-git/9100d311acc530b0286234c55b78dbdc0325d5e30950478c5c7864bfed7a4545/craft-tiff", + "dest-filename": "Cargo.toml" + }, + { + "type": "inline", + "contents": "{\"package\": null, \"files\": {}}", + "dest": "cargo/vendor-git/9100d311acc530b0286234c55b78dbdc0325d5e30950478c5c7864bfed7a4545/craft-tiff", + "dest-filename": ".cargo-checksum.json" + }, { "type": "shell", "commands": [ @@ -1963,6 +2065,24 @@ "dest": "cargo/vendor-git/4765c8f813a43ec0005270c9f4b16bff2eb2e09aeb15e4230bcd10e5bba1c4ba/craft-update", "dest-filename": ".cargo-checksum.json" }, + { + "type": "shell", + "commands": [ + "mkdir -p \"cargo/vendor-git/6f5ad8618176b3fc0aac703e6e74df7229b0350b4574c7edbe0bb86c53c1cb6c\" && cp -r --reflink=auto \"flatpak-cargo/git/craft-libs-5c91598/crates/video\" \"cargo/vendor-git/6f5ad8618176b3fc0aac703e6e74df7229b0350b4574c7edbe0bb86c53c1cb6c/craft-video\"" + ] + }, + { + "type": "inline", + "contents": "[package]\nname = \"craft-video\"\ndescription = \"Clean-room pure-Rust video codecs, one feature per codec: DNxHD/DNxHR, VP8, ProRes, H.264, HEVC, VP9, AV1, MPEG-4 Part 2.\"\nversion = \"0.1.0\"\nedition = \"2024\"\nlicense = \"MIT OR Apache-2.0\"\nrust-version = \"1.95\"\nrepository = \"https://github.com/storytold/craft-libs\"\n\n[package.metadata.docs.rs]\nall-features = true\n\n[lints.rust]\nunsafe_code = \"forbid\"\nunused_workspace_dependencies = \"allow\"\n\n[lints.rust.unexpected_cfgs]\nlevel = \"warn\"\ncheck-cfg = [\"cfg(craft_pdf_unicode_fixtures)\"]\n\n[lints.clippy]\ncognitive_complexity = \"deny\"\ntoo_many_arguments = \"deny\"\nunused_workspace_dependencies = \"allow\"\nwildcard_imports = \"deny\"\ndbg_macro = \"warn\"\ntodo = \"warn\"\n\n[features]\ndnx = []\napv = [\"apv-decode\", \"apv-encode\"]\napv-decode = [\"craft-media/bitstream\"]\napv-encode = [\"craft-media/bitstream\"]\nvp8 = [\"vp8-decode\", \"vp8-encode\"]\nvp8-decode = []\nvp8-encode = []\nmpeg2 = [\"mpeg2-decode\", \"mpeg2-encode\"]\nmpeg2-decode = []\nmpeg2-encode = [\"mpeg2-decode\"]\nmpeg4 = [\"mpeg4-encode\"]\nmpeg4-encode = [\"craft-media/bitstream\"]\nffv1 = []\nprores = [\"craft-media/bitstream\"]\nh264 = [\"h264-decode\", \"h264-encode\"]\nh264-decode = [\"craft-media/bitstream\"]\nh264-encode = [\"craft-media/isobmff\"]\nhevc = [\"hevc-decode\", \"hevc-encode\"]\nhevc-decode = [\"craft-media/bitstream\"]\nhevc-encode = [\"craft-media/isobmff\"]\nvp9 = [\"vp9-decode\", \"vp9-encode\"]\nvp9-decode = [\"craft-media/bitstream\"]\nvp9-encode = [\"craft-media/isobmff\"]\nav1 = [\"av1-decode\", \"av1-encode\"]\nav1-decode = []\nav1-encode = [\"craft-media/isobmff\"]\nav1-large-encode = [\"av1-encode\", \"dep:rav1e\"]\nthreads = [\"dep:rayon\", \"rav1e?/threading\"]\n\n[dependencies]\nthiserror = \"2\"\n\n[dependencies.craft-media]\npath = \"crates/media\"\ndefault-features = false\n\n[dependencies.rayon]\noptional = true\nversion = \"1\"\n\n[target.\"cfg(not(target_arch = \\\"wasm32\\\"))\".dependencies.rav1e]\nversion = \"0.8\"\ndefault-features = false\noptional = true\n\n[dev-dependencies.craft-media-testkit]\npath = \"crates/media-testkit\"\n\n[dev-dependencies.craft-media]\nfeatures = [\"avi\"]\npath = \"crates/media\"\ndefault-features = false\n\n[[test]]\nname = \"dnx\"\nrequired-features = [\"dnx\"]\n\n[[test]]\nname = \"apv\"\nrequired-features = [\"apv\"]\n\n[[test]]\nname = \"vp8\"\nrequired-features = [\"vp8-decode\"]\n\n[[test]]\nname = \"av1_decode\"\nrequired-features = [\"av1-decode\"]\n\n[[test]]\nname = \"h264_decode\"\nrequired-features = [\"h264-decode\"]\n\n[[test]]\nname = \"h264_encode\"\nrequired-features = [\"h264-encode\"]\n\n[[test]]\nname = \"hevc_decode\"\nrequired-features = [\"hevc-decode\"]\n\n[[test]]\nname = \"vp8_encode\"\nrequired-features = [\"vp8\"]\n\n[[test]]\nname = \"vp9_decode\"\nrequired-features = [\"vp9-decode\"]\n\n[[test]]\nname = \"mpeg4_encode\"\nrequired-features = [\"mpeg4-encode\"]\n\n[[test]]\nname = \"mpeg2\"\nrequired-features = [\"mpeg2-decode\"]\n\n[[test]]\nname = \"ffv1\"\nrequired-features = [\"ffv1\"]\n\n[[test]]\nname = \"prores\"\nrequired-features = [\"prores\"]\n\n[[test]]\nname = \"hevc\"\nrequired-features = [\"hevc-encode\"]\n\n[[test]]\nname = \"av1\"\nrequired-features = [\"av1\"]\n\n[[example]]\nname = \"vp8_fuzz\"\nrequired-features = [\"vp8-decode\"]\n\n[[example]]\nname = \"vp8_vp8dec\"\nrequired-features = [\"vp8-decode\"]\n\n[[example]]\nname = \"av1_av1dec\"\nrequired-features = [\"av1-decode\"]\n\n[[example]]\nname = \"h264_h264dec\"\nrequired-features = [\"h264-decode\"]\n\n[[example]]\nname = \"h264_h264enc_bench\"\nrequired-features = [\"h264-encode\"]\ntest = true\n\n[[example]]\nname = \"hevc_hevcdec\"\nrequired-features = [\"hevc-decode\"]\n\n[[example]]\nname = \"vp9_vp9dec\"\nrequired-features = [\"vp9-decode\"]\n", + "dest": "cargo/vendor-git/6f5ad8618176b3fc0aac703e6e74df7229b0350b4574c7edbe0bb86c53c1cb6c/craft-video", + "dest-filename": "Cargo.toml" + }, + { + "type": "inline", + "contents": "{\"package\": null, \"files\": {}}", + "dest": "cargo/vendor-git/6f5ad8618176b3fc0aac703e6e74df7229b0350b4574c7edbe0bb86c53c1cb6c/craft-video", + "dest-filename": ".cargo-checksum.json" + }, { "type": "shell", "commands": [ @@ -10071,7 +10191,7 @@ }, { "type": "inline", - "contents": "[source.vendored-sources]\ndirectory = \"cargo/vendor\"\n\n[source.crates-io]\nreplace-with = \"vendored-sources\"\n\n[source.\"https://github.com/storytold/craft-libs?rev=94777dcf7f8962476e96b049d08d22e25b9330c2\"]\ngit = \"https://github.com/storytold/craft-libs\"\nreplace-with = \"git-vendor-6fd0ceba5f4137be1fe00e9c031f810234e38df6f60195003fed7057c96f0aa1\"\nrev = \"94777dcf7f8962476e96b049d08d22e25b9330c2\"\n\n[source.git-vendor-6fd0ceba5f4137be1fe00e9c031f810234e38df6f60195003fed7057c96f0aa1]\ndirectory = \"cargo/vendor-git/6fd0ceba5f4137be1fe00e9c031f810234e38df6f60195003fed7057c96f0aa1\"\n\n[source.\"https://github.com/storytold/craft-libs?rev=f0f4758c01581d79577b9bf5046c06f4e77b1f18\"]\ngit = \"https://github.com/storytold/craft-libs\"\nreplace-with = \"git-vendor-bc00bd22a20692df38f25839a8568cd55b90e379a41719721bbc0f04fe5e29f7\"\nrev = \"f0f4758c01581d79577b9bf5046c06f4e77b1f18\"\n\n[source.git-vendor-bc00bd22a20692df38f25839a8568cd55b90e379a41719721bbc0f04fe5e29f7]\ndirectory = \"cargo/vendor-git/bc00bd22a20692df38f25839a8568cd55b90e379a41719721bbc0f04fe5e29f7\"\n\n[source.\"https://github.com/storytold/craft-libs?rev=c5a1cbfb5f9049f9270955caffb5bee5997aebf7\"]\ngit = \"https://github.com/storytold/craft-libs\"\nreplace-with = \"git-vendor-11a22760e699d74db2deeccbdb390b343ad010ce425dcb15451f0e14e45ff298\"\nrev = \"c5a1cbfb5f9049f9270955caffb5bee5997aebf7\"\n\n[source.git-vendor-11a22760e699d74db2deeccbdb390b343ad010ce425dcb15451f0e14e45ff298]\ndirectory = \"cargo/vendor-git/11a22760e699d74db2deeccbdb390b343ad010ce425dcb15451f0e14e45ff298\"\n\n[source.\"https://github.com/storytold/craft-libs?rev=9dcbd90c7d16e1a668b3afa057e940e2db328b93\"]\ngit = \"https://github.com/storytold/craft-libs\"\nreplace-with = \"git-vendor-36bf00be069421f8a8a7428c4360efee8b4243207a59d7b566c6f48fc5918f61\"\nrev = \"9dcbd90c7d16e1a668b3afa057e940e2db328b93\"\n\n[source.git-vendor-36bf00be069421f8a8a7428c4360efee8b4243207a59d7b566c6f48fc5918f61]\ndirectory = \"cargo/vendor-git/36bf00be069421f8a8a7428c4360efee8b4243207a59d7b566c6f48fc5918f61\"\n\n[source.\"https://github.com/storytold/craft-libs?rev=b77af389f30bb10de10d8436ca9b39fe94e3bb67\"]\ngit = \"https://github.com/storytold/craft-libs\"\nreplace-with = \"git-vendor-a51e2c3f46af71f1caed91009f88b4f9982db0c4152c6659d11967a7731b1ccc\"\nrev = \"b77af389f30bb10de10d8436ca9b39fe94e3bb67\"\n\n[source.git-vendor-a51e2c3f46af71f1caed91009f88b4f9982db0c4152c6659d11967a7731b1ccc]\ndirectory = \"cargo/vendor-git/a51e2c3f46af71f1caed91009f88b4f9982db0c4152c6659d11967a7731b1ccc\"\n\n[source.\"https://github.com/storytold/craft-libs?rev=478c50560d3c6fad3d613af2a30b35c3bc9f4c0f\"]\ngit = \"https://github.com/storytold/craft-libs\"\nreplace-with = \"git-vendor-cb31475a7a9d19c00f48b4c43603f2f1a464c6dce15da1d21bba4c653eeba6b2\"\nrev = \"478c50560d3c6fad3d613af2a30b35c3bc9f4c0f\"\n\n[source.git-vendor-cb31475a7a9d19c00f48b4c43603f2f1a464c6dce15da1d21bba4c653eeba6b2]\ndirectory = \"cargo/vendor-git/cb31475a7a9d19c00f48b4c43603f2f1a464c6dce15da1d21bba4c653eeba6b2\"\n\n[source.\"https://github.com/storytold/craft-libs?rev=0fd30aeb3e02207d9d4c7c601540d9da45abf8de\"]\ngit = \"https://github.com/storytold/craft-libs\"\nreplace-with = \"git-vendor-fafb086755da4e9bf32b4ac1b53a42a6017167d56ec0071462788465fa35eb30\"\nrev = \"0fd30aeb3e02207d9d4c7c601540d9da45abf8de\"\n\n[source.git-vendor-fafb086755da4e9bf32b4ac1b53a42a6017167d56ec0071462788465fa35eb30]\ndirectory = \"cargo/vendor-git/fafb086755da4e9bf32b4ac1b53a42a6017167d56ec0071462788465fa35eb30\"\n\n[source.\"https://github.com/storytold/craft-libs?rev=6e03f65bf45181db77ba6229716e6624db9eb25b\"]\ngit = \"https://github.com/storytold/craft-libs\"\nreplace-with = \"git-vendor-4765c8f813a43ec0005270c9f4b16bff2eb2e09aeb15e4230bcd10e5bba1c4ba\"\nrev = \"6e03f65bf45181db77ba6229716e6624db9eb25b\"\n\n[source.git-vendor-4765c8f813a43ec0005270c9f4b16bff2eb2e09aeb15e4230bcd10e5bba1c4ba]\ndirectory = \"cargo/vendor-git/4765c8f813a43ec0005270c9f4b16bff2eb2e09aeb15e4230bcd10e5bba1c4ba\"\n\n[source.\"https://github.com/storytold/egui.git?rev=6d518fc799681571963842f95b55a6b68431b15a\"]\ngit = \"https://github.com/storytold/egui\"\nreplace-with = \"git-vendor-11e349eb0774eb3ab9192b38c47d748bf18abba91a0e3952d8f196513da96ee6\"\nrev = \"6d518fc799681571963842f95b55a6b68431b15a\"\n\n[source.git-vendor-11e349eb0774eb3ab9192b38c47d748bf18abba91a0e3952d8f196513da96ee6]\ndirectory = \"cargo/vendor-git/11e349eb0774eb3ab9192b38c47d748bf18abba91a0e3952d8f196513da96ee6\"\n\n[source.\"https://github.com/storytold/winit.git?rev=a517b3846ee8457d84ee4975110bfda6797c44dc\"]\ngit = \"https://github.com/storytold/winit\"\nreplace-with = \"git-vendor-9c7f809a50c4212d761a5b6359c5e4a02fcf86376d330a441c4ce9d112706ee9\"\nrev = \"a517b3846ee8457d84ee4975110bfda6797c44dc\"\n\n[source.git-vendor-9c7f809a50c4212d761a5b6359c5e4a02fcf86376d330a441c4ce9d112706ee9]\ndirectory = \"cargo/vendor-git/9c7f809a50c4212d761a5b6359c5e4a02fcf86376d330a441c4ce9d112706ee9\"\n", + "contents": "[source.vendored-sources]\ndirectory = \"cargo/vendor\"\n\n[source.crates-io]\nreplace-with = \"vendored-sources\"\n\n[source.\"https://github.com/storytold/craft-libs?rev=94777dcf7f8962476e96b049d08d22e25b9330c2\"]\ngit = \"https://github.com/storytold/craft-libs\"\nreplace-with = \"git-vendor-6fd0ceba5f4137be1fe00e9c031f810234e38df6f60195003fed7057c96f0aa1\"\nrev = \"94777dcf7f8962476e96b049d08d22e25b9330c2\"\n\n[source.git-vendor-6fd0ceba5f4137be1fe00e9c031f810234e38df6f60195003fed7057c96f0aa1]\ndirectory = \"cargo/vendor-git/6fd0ceba5f4137be1fe00e9c031f810234e38df6f60195003fed7057c96f0aa1\"\n\n[source.\"https://github.com/storytold/craft-libs?rev=f0f4758c01581d79577b9bf5046c06f4e77b1f18\"]\ngit = \"https://github.com/storytold/craft-libs\"\nreplace-with = \"git-vendor-bc00bd22a20692df38f25839a8568cd55b90e379a41719721bbc0f04fe5e29f7\"\nrev = \"f0f4758c01581d79577b9bf5046c06f4e77b1f18\"\n\n[source.git-vendor-bc00bd22a20692df38f25839a8568cd55b90e379a41719721bbc0f04fe5e29f7]\ndirectory = \"cargo/vendor-git/bc00bd22a20692df38f25839a8568cd55b90e379a41719721bbc0f04fe5e29f7\"\n\n[source.\"https://github.com/storytold/craft-libs?rev=c5a1cbfb5f9049f9270955caffb5bee5997aebf7\"]\ngit = \"https://github.com/storytold/craft-libs\"\nreplace-with = \"git-vendor-11a22760e699d74db2deeccbdb390b343ad010ce425dcb15451f0e14e45ff298\"\nrev = \"c5a1cbfb5f9049f9270955caffb5bee5997aebf7\"\n\n[source.git-vendor-11a22760e699d74db2deeccbdb390b343ad010ce425dcb15451f0e14e45ff298]\ndirectory = \"cargo/vendor-git/11a22760e699d74db2deeccbdb390b343ad010ce425dcb15451f0e14e45ff298\"\n\n[source.\"https://github.com/storytold/craft-libs?rev=9dcbd90c7d16e1a668b3afa057e940e2db328b93\"]\ngit = \"https://github.com/storytold/craft-libs\"\nreplace-with = \"git-vendor-36bf00be069421f8a8a7428c4360efee8b4243207a59d7b566c6f48fc5918f61\"\nrev = \"9dcbd90c7d16e1a668b3afa057e940e2db328b93\"\n\n[source.git-vendor-36bf00be069421f8a8a7428c4360efee8b4243207a59d7b566c6f48fc5918f61]\ndirectory = \"cargo/vendor-git/36bf00be069421f8a8a7428c4360efee8b4243207a59d7b566c6f48fc5918f61\"\n\n[source.\"https://github.com/storytold/craft-libs?rev=b77af389f30bb10de10d8436ca9b39fe94e3bb67\"]\ngit = \"https://github.com/storytold/craft-libs\"\nreplace-with = \"git-vendor-a51e2c3f46af71f1caed91009f88b4f9982db0c4152c6659d11967a7731b1ccc\"\nrev = \"b77af389f30bb10de10d8436ca9b39fe94e3bb67\"\n\n[source.git-vendor-a51e2c3f46af71f1caed91009f88b4f9982db0c4152c6659d11967a7731b1ccc]\ndirectory = \"cargo/vendor-git/a51e2c3f46af71f1caed91009f88b4f9982db0c4152c6659d11967a7731b1ccc\"\n\n[source.\"https://github.com/storytold/craft-libs?rev=478c50560d3c6fad3d613af2a30b35c3bc9f4c0f\"]\ngit = \"https://github.com/storytold/craft-libs\"\nreplace-with = \"git-vendor-cb31475a7a9d19c00f48b4c43603f2f1a464c6dce15da1d21bba4c653eeba6b2\"\nrev = \"478c50560d3c6fad3d613af2a30b35c3bc9f4c0f\"\n\n[source.git-vendor-cb31475a7a9d19c00f48b4c43603f2f1a464c6dce15da1d21bba4c653eeba6b2]\ndirectory = \"cargo/vendor-git/cb31475a7a9d19c00f48b4c43603f2f1a464c6dce15da1d21bba4c653eeba6b2\"\n\n[source.\"https://github.com/storytold/craft-libs?rev=5ac7c9664c8d54aaf69d1bb826e187686c1a4e1a\"]\ngit = \"https://github.com/storytold/craft-libs\"\nreplace-with = \"git-vendor-9100d311acc530b0286234c55b78dbdc0325d5e30950478c5c7864bfed7a4545\"\nrev = \"5ac7c9664c8d54aaf69d1bb826e187686c1a4e1a\"\n\n[source.git-vendor-9100d311acc530b0286234c55b78dbdc0325d5e30950478c5c7864bfed7a4545]\ndirectory = \"cargo/vendor-git/9100d311acc530b0286234c55b78dbdc0325d5e30950478c5c7864bfed7a4545\"\n\n[source.\"https://github.com/storytold/craft-libs?rev=5c91598ccc86537a779f438d520fa6406c26efe6\"]\ngit = \"https://github.com/storytold/craft-libs\"\nreplace-with = \"git-vendor-6f5ad8618176b3fc0aac703e6e74df7229b0350b4574c7edbe0bb86c53c1cb6c\"\nrev = \"5c91598ccc86537a779f438d520fa6406c26efe6\"\n\n[source.git-vendor-6f5ad8618176b3fc0aac703e6e74df7229b0350b4574c7edbe0bb86c53c1cb6c]\ndirectory = \"cargo/vendor-git/6f5ad8618176b3fc0aac703e6e74df7229b0350b4574c7edbe0bb86c53c1cb6c\"\n\n[source.\"https://github.com/storytold/craft-libs?rev=0fd30aeb3e02207d9d4c7c601540d9da45abf8de\"]\ngit = \"https://github.com/storytold/craft-libs\"\nreplace-with = \"git-vendor-fafb086755da4e9bf32b4ac1b53a42a6017167d56ec0071462788465fa35eb30\"\nrev = \"0fd30aeb3e02207d9d4c7c601540d9da45abf8de\"\n\n[source.git-vendor-fafb086755da4e9bf32b4ac1b53a42a6017167d56ec0071462788465fa35eb30]\ndirectory = \"cargo/vendor-git/fafb086755da4e9bf32b4ac1b53a42a6017167d56ec0071462788465fa35eb30\"\n\n[source.\"https://github.com/storytold/craft-libs?rev=6e03f65bf45181db77ba6229716e6624db9eb25b\"]\ngit = \"https://github.com/storytold/craft-libs\"\nreplace-with = \"git-vendor-4765c8f813a43ec0005270c9f4b16bff2eb2e09aeb15e4230bcd10e5bba1c4ba\"\nrev = \"6e03f65bf45181db77ba6229716e6624db9eb25b\"\n\n[source.git-vendor-4765c8f813a43ec0005270c9f4b16bff2eb2e09aeb15e4230bcd10e5bba1c4ba]\ndirectory = \"cargo/vendor-git/4765c8f813a43ec0005270c9f4b16bff2eb2e09aeb15e4230bcd10e5bba1c4ba\"\n\n[source.\"https://github.com/storytold/egui.git?rev=6d518fc799681571963842f95b55a6b68431b15a\"]\ngit = \"https://github.com/storytold/egui\"\nreplace-with = \"git-vendor-11e349eb0774eb3ab9192b38c47d748bf18abba91a0e3952d8f196513da96ee6\"\nrev = \"6d518fc799681571963842f95b55a6b68431b15a\"\n\n[source.git-vendor-11e349eb0774eb3ab9192b38c47d748bf18abba91a0e3952d8f196513da96ee6]\ndirectory = \"cargo/vendor-git/11e349eb0774eb3ab9192b38c47d748bf18abba91a0e3952d8f196513da96ee6\"\n\n[source.\"https://github.com/storytold/winit.git?rev=a517b3846ee8457d84ee4975110bfda6797c44dc\"]\ngit = \"https://github.com/storytold/winit\"\nreplace-with = \"git-vendor-9c7f809a50c4212d761a5b6359c5e4a02fcf86376d330a441c4ce9d112706ee9\"\nrev = \"a517b3846ee8457d84ee4975110bfda6797c44dc\"\n\n[source.git-vendor-9c7f809a50c4212d761a5b6359c5e4a02fcf86376d330a441c4ce9d112706ee9]\ndirectory = \"cargo/vendor-git/9c7f809a50c4212d761a5b6359c5e4a02fcf86376d330a441c4ce9d112706ee9\"\n", "dest": "cargo", "dest-filename": "config" } From 45f887995beb24e58b356e33e6b321e07a120a21 Mon Sep 17 00:00:00 2001 From: FredApps <153173854+FredApps@users.noreply.github.com> Date: Mon, 16 Nov 2026 08:32:38 +0100 Subject: [PATCH 56/61] codecs: test PNG header and decode agree on conflicting Orientation entries --- crates/codecs/src/png_codec.rs | 24 ++++++++++++++++++++++++ 1 file changed, 24 insertions(+) diff --git a/crates/codecs/src/png_codec.rs b/crates/codecs/src/png_codec.rs index 6fe9964c62..fa962002d7 100644 --- a/crates/codecs/src/png_codec.rs +++ b/crates/codecs/src/png_codec.rs @@ -106,6 +106,30 @@ fn rgb_to_xyz_d50_checked(space: &RgbSpace) -> Option<Mat3> { mod tests { use crate::DecodeOptions; + /// An IFD0 with two Orientation entries (1, then 6): `read_header` and `decode` read it with + /// the same reader, so they agree on the orientation. + #[test] + fn header_and_decode_agree_on_conflicting_orientation_entries() { + let image = craft_image_codecs::Image::from_u8(2, 3, craft_image_codecs::ChannelLayout::Gray, vec![0; 6]).unwrap(); + let base = craft_image_codecs::encode(&image, craft_image_codecs::Format::Png, &craft_image_codecs::EncodeOptions::default()).unwrap(); + let mut exif = b"II*\0\x08\0\0\0\x02\0".to_vec(); + for value in [1u16, 6] { + exif.extend_from_slice(&0x0112u16.to_le_bytes()); + exif.extend_from_slice(&3u16.to_le_bytes()); + exif.extend_from_slice(&1u32.to_le_bytes()); + exif.extend_from_slice(&value.to_le_bytes()); + exif.extend_from_slice(&[0, 0]); + } + exif.extend_from_slice(&0u32.to_le_bytes()); + let mut png = base.clone(); + let iend = png.len() - 12; + png.splice(iend..iend, png_chunk(*b"eXIf", &exif)); + let header = crate::read_header(&png).unwrap(); + let decoded = crate::decode(&png, DecodeOptions::default()).unwrap(); + assert_eq!((header.width, header.height), (2, 3)); + assert_eq!(header.orientation, decoded.orientation); + } + #[test] fn exif_orientation_mutation_parity() { let image = craft_image_codecs::Image::from_u8(1, 1, craft_image_codecs::ChannelLayout::Gray, vec![0]).unwrap(); From fd1faf45bbfda7bea0c134f48f048c6301690a4d Mon Sep 17 00:00:00 2001 From: "Dylan M. Taylor" <dylan@dylanmtaylor.com> Date: Mon, 16 Nov 2026 04:51:11 -0500 Subject: [PATCH 57/61] Use established async completion budgets for remaining UI waits --- crates/ui-egui/src/tests/activity.rs | 2 +- crates/ui-egui/src/tests/preview_limit.rs | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/crates/ui-egui/src/tests/activity.rs b/crates/ui-egui/src/tests/activity.rs index f8f32607a2..db6320a4b1 100644 --- a/crates/ui-egui/src/tests/activity.rs +++ b/crates/ui-egui/src/tests/activity.rs @@ -464,7 +464,7 @@ fn merge_dialog_retries_a_failed_preview_when_it_opens_again() { h.app.merge.preview.is_some() || h.app.merge.preview_task.is_some() || h.app.merge.error.is_some(), "the dialog shows a preview, one being made, or why not" ); - assert!(h.step_until(T, |h| h.app.merge.preview_task.is_none())); + assert!(h.step_until(super::ui_settle_timeout(), |h| h.app.merge.preview_task.is_none())); assert!(h.app.merge.preview.is_some(), "{:?}", h.app.merge.error); h.app.ui.dialog = None; h.step(); diff --git a/crates/ui-egui/src/tests/preview_limit.rs b/crates/ui-egui/src/tests/preview_limit.rs index 8d19a71734..248ce781cc 100644 --- a/crates/ui-egui/src/tests/preview_limit.rs +++ b/crates/ui-egui/src/tests/preview_limit.rs @@ -811,7 +811,7 @@ mod in_the_loupe { fn pinch_display_fit_refreshes_main_and_before_after_a_short_pinch() { let (mut h, _) = demo_detail_in([1400.0, 900.0]); h.app.ui.before_after = crate::state::BeforeAfter::SideBySide; - assert!(h.settle(SETTLE)); + assert!(h.settle(super::super::ui_settle_timeout())); let slots = [Slot::Main, Slot::Before]; let keys = slots.map(|slot| h.app.renderer.wanted(slot).unwrap()); let initial_fit = drawn_fit(&h); From 3a616261e3fa64d4676eda97a7129ee661c0b982 Mon Sep 17 00:00:00 2001 From: "Dylan M. Taylor" <dylan@dylanmtaylor.com> Date: Mon, 16 Nov 2026 05:13:38 -0500 Subject: [PATCH 58/61] Allow instrumented preview decoders to finish before reporting failure --- crates/ui-egui/src/tests/activity.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/crates/ui-egui/src/tests/activity.rs b/crates/ui-egui/src/tests/activity.rs index db6320a4b1..bdeaccf4e9 100644 --- a/crates/ui-egui/src/tests/activity.rs +++ b/crates/ui-egui/src/tests/activity.rs @@ -452,7 +452,7 @@ fn merge_dialog_retries_a_failed_preview_when_it_opens_again() { std::fs::rename(&file, &away).unwrap(); crate::merge::open(&mut h.app, "merge.panorama").unwrap(); h.step(); - assert!(h.step_until(T, |h| h.app.merge.preview_task.is_none())); + assert!(h.step_until(super::ui_settle_timeout(), |h| h.app.merge.preview_task.is_none())); assert!(h.app.merge.error.is_some(), "the preview failed"); h.app.ui.dialog = None; h.step(); From b3188d182a17d50a8edaf0cbf5db7e82d88e737e Mon Sep 17 00:00:00 2001 From: "Dylan M. Taylor" <dylan@dylanmtaylor.com> Date: Mon, 16 Nov 2026 06:26:52 -0500 Subject: [PATCH 59/61] docs: prefer shared Craft libraries for reusable features --- AGENTS.md | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/AGENTS.md b/AGENTS.md index 8d0ca31a60..76c593c1d8 100644 --- a/AGENTS.md +++ b/AGENTS.md @@ -229,3 +229,7 @@ evaluates it (`.github/workflows/nix.yml`), so the build may lag behind the work - Don't add or change CI in a feature or fix PR. If the existing workflows can't build or test a change, link an existing craft-common-actions issue or PR, or open a new issue, or a PR only for a small fix that is safe for every app and does not increase CI time. - `ci.yml` is the Linux gate, on every pull request. `ci-windows.yml` adds a Windows leg (clippy and tests of the crates with `cfg(windows)` code) when a pull request changes the paths it lists; add the `full-ci` label to run it on any other pull request. When you add `cfg(windows)` code in a new file, add the file to its `paths` in a CI PR. - Some workflow files here still run their own jobs. Don't add to them. Moving a job into craft-common-actions is its own task, never part of another PR, and the job stays here until a shared workflow runs it. + +## Shared libraries + +Before adding or changing file-format, codec, protocol, or reusable UI code, check `storytold/craft-libs` and its open PRs first; reuse or extend the shared library rather than duplicating it locally, keep app-specific policy and model mapping in the app, and preserve behavior, security/resource limits, attribution, and regression coverage during cutovers. From 9de93337c525bae451f2ad568b8f81195e083838 Mon Sep 17 00:00:00 2001 From: "Dylan M. Taylor" <dylan@dylanmtaylor.com> Date: Mon, 16 Nov 2026 21:58:40 -0500 Subject: [PATCH 60/61] Use shared HEIF metadata and preserve location checks (#4315) --- Cargo.lock | 2 +- Cargo.toml | 2 +- crates/codecs/Cargo.toml | 2 +- crates/engine/src/export/prepare.rs | 5 +- crates/engine/src/tests/export.rs | 160 +++++- crates/engine/src/tests/import.rs | 66 +++ crates/meta/Cargo.toml | 1 + crates/meta/README.md | 11 +- crates/meta/src/heif.rs | 630 +++++++++++++-------- crates/meta/src/lib.rs | 17 + docs/file-format-parity.md | 5 +- docs/target-app-parity.md | 3 +- packaging/linux/flatpak/cargo-sources.json | 16 +- 13 files changed, 666 insertions(+), 254 deletions(-) diff --git a/Cargo.lock b/Cargo.lock index c7412025a1..a5d50e3100 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -1239,7 +1239,7 @@ dependencies = [ [[package]] name = "craft-heif" version = "0.1.0" -source = "git+https://github.com/storytold/craft-libs?rev=9dcbd90c7d16e1a668b3afa057e940e2db328b93#9dcbd90c7d16e1a668b3afa057e940e2db328b93" +source = "git+https://github.com/storytold/craft-libs?rev=4ffa307f1a0a6fbd8897318cc719440ab06e9c63#4ffa307f1a0a6fbd8897318cc719440ab06e9c63" dependencies = [ "heic-rs", "rayon", diff --git a/Cargo.toml b/Cargo.toml index 7e587e5f2a..e6537fecbb 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -69,7 +69,7 @@ lightcraft-ui-egui = { path = "crates/ui-egui" } lightcraft-mcp = { path = "crates/mcp" } lightcraft-fetch = { path = "crates/fetch" } # HEIC/HEIF: the shared decoder (moved from crates/heif; craft-libs#784). -craft-heif = { git = "https://github.com/storytold/craft-libs", rev = "9dcbd90c7d16e1a668b3afa057e940e2db328b93" } +craft-heif = { git = "https://github.com/storytold/craft-libs", rev = "4ffa307f1a0a6fbd8897318cc719440ab06e9c63", default-features = false } lightcraft-segment = { path = "crates/segment" } lightcraft-geocode = { path = "crates/geocode" } lightcraft-slideshow = { path = "crates/slideshow" } diff --git a/crates/codecs/Cargo.toml b/crates/codecs/Cargo.toml index bdb0e5ebce..9fd089a2d9 100644 --- a/crates/codecs/Cargo.toml +++ b/crates/codecs/Cargo.toml @@ -20,7 +20,7 @@ craft-metadata = { workspace = true } craft-tiff = { workspace = true } craft-gif = { workspace = true } craft-psd = { workspace = true } -craft-heif = { workspace = true, optional = true } +craft-heif = { workspace = true, optional = true, features = ["decode"] } serde = { workspace = true } bytemuck = { workspace = true } thiserror = { workspace = true } diff --git a/crates/engine/src/export/prepare.rs b/crates/engine/src/export/prepare.rs index 56cc71a4a7..997ae03e52 100644 --- a/crates/engine/src/export/prepare.rs +++ b/crates/engine/src/export/prepare.rs @@ -249,9 +249,10 @@ impl PreparedExport { .into_iter() .flatten() .any(|value| !value.trim().is_empty()); - if metadata.gps.is_some() || embeds_place_name { + if metadata.gps.is_some() || embeds_place_name || lightcraft_meta::embeds_location(&bytes) { + let instead = if lightcraft_raw::probe(&bytes).is_some() { "JPEG, TIFF or DNG" } else { "JPEG or TIFF" }; return Err(format!( - "{label}: can't remove the location from an original file that embeds GPS or place names; export as JPEG or TIFF, or as DNG for a raw photo" + "{label}: can't remove the location from this original file: it contains GPS or place names, or its location metadata could not be fully checked; export as {instead} instead" )); } } diff --git a/crates/engine/src/tests/export.rs b/crates/engine/src/tests/export.rs index a2719bf010..4eb8faf147 100644 --- a/crates/engine/src/tests/export.rs +++ b/crates/engine/src/tests/export.rs @@ -731,6 +731,23 @@ fn hdr_avif_export_hlg() { assert!(!hdr.bytes.windows(4).any(|w| w == b"clli")); } +/// An exported AVIF's metadata reads back (issue #693: HEIF-family files had no metadata reader). +/// avif-serialize writes the EXIF as an `Exif` item in two extents, its offset field and the TIFF. +#[test] +fn exported_avif_metadata_reads_back() { + use lightcraft_catalog::{Catalog, Photo, PhotoId, Source}; + let mut p = Photo::new(PhotoId(1), Source::Demo { scene: 0 }, "a.jpg", "jpeg", 10, 10, "2026-09-30T00:00:00"); + p.meta.camera = "Synthetic X2".into(); + p.captured = Some("2026-10-12T12:34:56".into()); + let m = crate::export::export_metadata(&p, &Catalog::new(), &ExportOptions::default()).unwrap(); + let img = lightcraft_raster::Rgba8::new(48, 32); + let avif = crate::export::encode_with_metadata(&img, &ExportOptions::from_json(&json!({"format": "avif", "quality": 60})), Some(&m)).unwrap(); + assert_eq!(lightcraft_codecs::sniff(&avif), Some(lightcraft_codecs::Format::Avif)); + let back = lightcraft_meta::extract(&avif); + assert_eq!(back.model.as_deref(), Some("Synthetic X2")); + assert_eq!(back.capture_time.map(|d| d.to_iso()).as_deref(), Some("2026-10-12T12:34:56")); +} + /// "Remove location info" holds for the file-copying formats too: the sidecar and the DNG's /// packet carry no location, and an original that embeds GPS is refused rather than copied. #[test] @@ -774,6 +791,7 @@ fn remove_location_holds_for_original_and_dng_exports() { assert!(lightcraft_meta::extract(&e.bytes).gps.is_some()); let err = export_photo(&mut s, jid, &opts("original", true), 1).err().unwrap(); assert!(err.contains("can't remove the location") && err.contains("export as JPEG"), "{err}"); + assert!(!err.contains("DNG"), "a JPEG can't be exported as DNG: {err}"); let _ = std::fs::remove_dir_all(&dir); } @@ -1000,7 +1018,147 @@ fn remove_location_refuses_a_raw_that_embeds_gps() { s.execute("library.import", &json!({"paths": [raw.to_string_lossy()]})).unwrap(); let id = s.catalog.photos().next().unwrap().id; let err = export_photo(&mut s, id, &ExportOptions::from_json(&json!({"format": "original", "removeLocation": true})), 1).err().unwrap(); - assert!(err.contains("can't remove the location"), "{err}"); + assert!(err.contains("can't remove the location") && err.contains("DNG"), "a raw can go out as DNG: {err}"); + let _ = std::fs::remove_dir_all(&dir); +} + +/// A HEIC whose only GPS is in its thumbnail's EXIF (the pictures have no data: an original's +/// export never decodes it). Item 1 is the photo, 2 its thumbnail, 3 the thumbnail's EXIF, kept in +/// the `meta` box's `idat`. +fn heic_with_gps_in_its_thumbnail() -> Vec<u8> { + let gps = lightcraft_meta::Gps { latitude: 48.85, longitude: 2.35, altitude: None }; + let exif = [&[0u8, 0, 0, 0][..], &lightcraft_meta::write_exif(&lightcraft_meta::Metadata { gps: Some(gps), ..Default::default() })].concat(); + heic_with_metadata_in_its_thumbnail(b"Exif", &exif) +} + +fn heic_with_metadata_in_its_thumbnail(kind: &[u8; 4], payload: &[u8]) -> Vec<u8> { + let bx = |kind: &[u8], body: &[u8]| [&((body.len() + 8) as u32).to_be_bytes()[..], kind, body].concat(); + let full = |kind: &[u8], body: &[u8]| bx(kind, &[&[0u8, 0, 0, 0][..], body].concat()); + let infe = |id: u8, kind: &[u8]| { + let fields = if kind == b"mime" { b"\0application/rdf+xml\0".as_slice() } else { b"\0" }; + bx(b"infe", &[&[2, 0, 0, 0, 0, id, 0, 0][..], kind, fields].concat()) + }; + let iinf = full(b"iinf", &[&[0, 3][..], &infe(1, b"hvc1"), &infe(2, b"hvc1"), &infe(3, kind)].concat()); + let iref = full(b"iref", &[bx(b"thmb", &[0, 2, 0, 1, 0, 1]), bx(b"cdsc", &[0, 3, 0, 1, 0, 2])].concat()); + // `iloc` version 1, 4-byte offsets and lengths: item 3 from `idat` (construction method 1) + let mut iloc = vec![1, 0, 0, 0, 0x44, 0, 0, 1, 0, 3, 0, 1, 0, 0, 0, 1, 0, 0, 0, 0]; + iloc.extend_from_slice(&(payload.len() as u32).to_be_bytes()); + let meta = full(b"meta", &[full(b"pitm", &[0, 1]), iinf, iref, bx(b"iloc", &iloc), bx(b"idat", payload)].concat()); + [bx(b"ftyp", b"heic\0\0\0\0mif1heic"), meta].concat() +} + +/// "Remove location info" refuses an original that embeds GPS anywhere it can be read, here only +/// in a HEIC's thumbnail (#693 review), and doesn't offer DNG for a photo that isn't a raw. +#[test] +fn remove_location_refuses_a_heic_whose_thumbnail_has_gps() { + use lightcraft_catalog::{Op, Photo, Source}; + let dir = temp_dir("export-noloc-heic"); + let path = dir.join("IMG_0003.HEIC"); + std::fs::write(&path, heic_with_gps_in_its_thumbnail()).unwrap(); + let mut s = Session::new().with_fs(); + let id = s.catalog.alloc_photo_id(); + let p = Photo::new(id, Source::File { path: path.to_string_lossy().into() }, "IMG_0003.HEIC", "HEIC", 32, 32, "2026-10-12T00:00:00"); + s.catalog.apply(Op::AddPhoto { photo: Box::new(p) }).unwrap(); + let opts = |remove: bool| ExportOptions::from_json(&json!({"format": "original", "removeLocation": remove})); + assert!(export_photo(&mut s, id, &opts(false), 1).is_ok(), "copied as is when the location may stay"); + let err = export_photo(&mut s, id, &opts(true), 1).err().expect("refused: the thumbnail's EXIF has GPS"); + assert!(err.contains("can't remove the location") && err.contains("export as JPEG or TIFF"), "{err}"); + let _ = std::fs::remove_dir_all(&dir); +} + +/// A listed metadata item with an unreadable placement is not proof that an original has no GPS. +/// Exercise the real file-copy path; these damaged containers do not need a working decoder. +#[test] +fn remove_location_refuses_heic_with_unresolved_iloc() { + use lightcraft_catalog::{Op, Photo, Source}; + let dir = temp_dir("export-noloc-heic-iloc"); + let path = dir.join("Placement.HEIC"); + let mut s = Session::new().with_fs(); + let id = s.catalog.alloc_photo_id(); + let p = Photo::new(id, Source::File { path: path.to_string_lossy().into() }, "Placement.HEIC", "HEIC", 32, 32, "2026-10-12T00:00:00"); + s.catalog.apply(Op::AddPhoto { photo: Box::new(p) }).unwrap(); + let opts = |remove: bool| ExportOptions::from_json(&json!({"format": "original", "removeLocation": remove})); + + let original = heic_with_gps_in_its_thumbnail(); + assert!(lightcraft_meta::embeds_location(&original), "the intact fixture has GPS"); + let kind_at = original.windows(4).position(|w| w == b"iloc").unwrap(); + let body = kind_at + 4; + for damage in ["none", "missing", "version", "field size", "truncated entry"] { + let mut bytes = original.clone(); + match damage { + "missing" => bytes[kind_at..body].copy_from_slice(b"free"), + "version" => bytes[body] = 3, + "field size" => bytes[body + 4] = 0x24, + "truncated entry" => bytes[body + 15] = 2, // two extents declared, only one present + _ => {} + } + std::fs::write(&path, &bytes).unwrap(); + assert_eq!(export_photo(&mut s, id, &opts(false), 1).unwrap().bytes, bytes, "location may stay: {damage}"); + let err = export_photo(&mut s, id, &opts(true), 1).err().expect("unresolved GPS must not be copied"); + assert!(err.contains("can't remove the location") && err.contains("export as JPEG or TIFF"), "{damage}: {err}"); + } + + // Ordinary files without GPS still export, with and without an EXIF item. + for exif in [None, Some(lightcraft_meta::write_exif(&lightcraft_meta::Metadata { model: Some("Synthetic".into()), ..Default::default() }))] { + let mut spec = craft_heif::testdata::Spec::new(32, 32, &|_, _| [0, 0, 0]); + spec.exif = exif; + let bytes = craft_heif::testdata::build(&spec); + std::fs::write(&path, &bytes).unwrap(); + assert_eq!(export_photo(&mut s, id, &opts(true), 1).unwrap().bytes, bytes); + } + let _ = std::fs::remove_dir_all(&dir); +} + +/// A damaged item catalog cannot authorize copying the GPS bytes that `iloc` still references. +#[test] +fn remove_location_refuses_heic_with_incomplete_exif_catalog() { + let original = heic_with_gps_in_its_thumbnail(); + let idat = original.windows(4).position(|w| w == b"idat").unwrap(); + assert!(lightcraft_meta::try_read_exif(&original[idat + 8..]).unwrap().gps.is_some(), "real EXIF payload"); + assert_incomplete_catalog_refused(&original, "exif"); +} + +#[test] +fn remove_location_refuses_heic_with_incomplete_xmp_catalog() { + let gps = + lightcraft_meta::Metadata { gps: Some(lightcraft_meta::Gps { latitude: 48.85, longitude: 2.35, altitude: None }), ..Default::default() }; + let xmp = lightcraft_meta::write_xmp(&gps, None); + assert!(lightcraft_meta::parse_xmp(&xmp).unwrap().metadata.gps.is_some(), "real XMP payload"); + assert_incomplete_catalog_refused(&heic_with_metadata_in_its_thumbnail(b"mime", xmp.as_bytes()), "xmp"); +} + +fn assert_incomplete_catalog_refused(original: &[u8], label: &str) { + use lightcraft_catalog::{Op, Photo, Source}; + let dir = temp_dir(&format!("export-noloc-heic-catalog-{label}")); + let path = dir.join("Catalog.HEIC"); + let mut s = Session::new().with_fs(); + let id = s.catalog.alloc_photo_id(); + let p = Photo::new(id, Source::File { path: path.to_string_lossy().into() }, "Catalog.HEIC", "HEIC", 32, 32, "2026-10-12T00:00:00"); + s.catalog.apply(Op::AddPhoto { photo: Box::new(p) }).unwrap(); + let opts = |remove: bool| ExportOptions::from_json(&json!({"format": "original", "removeLocation": remove})); + let iinf = original.windows(4).position(|w| w == b"iinf").unwrap(); + let infe = original.windows(4).rposition(|w| w == b"infe").unwrap(); + let idat = original.windows(4).position(|w| w == b"idat").unwrap(); + assert!(lightcraft_meta::embeds_location(original), "intact GPS container"); + for damage in ["truncated type", "missing catalog", "unsupported table", "unsupported entry", "unknown entry", "truncated catalog"] { + let mut bytes = original.to_vec(); + match damage { + "truncated type" => bytes[infe - 4..infe].copy_from_slice(&18u32.to_be_bytes()), + "missing catalog" => bytes[iinf..iinf + 4].copy_from_slice(b"free"), + "unsupported table" => bytes[iinf + 4] = 2, + "unsupported entry" => bytes[infe + 4] = 4, + "unknown entry" => bytes[infe..infe + 4].copy_from_slice(b"free"), + "truncated catalog" => bytes[iinf - 4..iinf].copy_from_slice(&u32::MAX.to_be_bytes()), + other => panic!("unknown damage {other}"), + } + assert_eq!(&bytes[idat..], &original[idat..], "GPS bytes retained"); + std::fs::write(&path, &bytes).unwrap(); + assert_eq!(export_photo(&mut s, id, &opts(false), 1).unwrap().bytes, bytes, "location may stay: {damage}"); + let result = export_photo(&mut s, id, &opts(true), 1); + assert!(result.is_err(), "Remove location copied the original with {damage}"); + let err = result.err().unwrap(); + assert!(err.contains("can't remove the location") && err.contains("export as JPEG or TIFF"), "{damage}: {err}"); + } let _ = std::fs::remove_dir_all(&dir); } diff --git a/crates/engine/src/tests/import.rs b/crates/engine/src/tests/import.rs index 4de20ab3ee..632ca16007 100644 --- a/crates/engine/src/tests/import.rs +++ b/crates/engine/src/tests/import.rs @@ -3173,6 +3173,72 @@ fn a_file_arriving_beside_its_raws_stem_reads_its_own_sidecar() { let _ = std::fs::remove_dir_all(&src); } +#[test] +fn heic_exif_reaches_the_catalog_and_all_metadata() { + use craft_heif::testdata::{Spec, build}; + let photo = |x: u32, y: u32| [((x * 7 + y * 13) % 200 + 30) as u16, 110, 150]; + let exif = lightcraft_meta::write_exif(&lightcraft_meta::Metadata { + make: Some("Synthetic".into()), + model: Some("Issue sweep camera".into()), + capture_time: lightcraft_meta::DateTime::parse_iso("2026-10-12T12:34:56"), + ..Default::default() + }); + let bytes = build(&Spec { exif: Some(exif), ..Spec::new(96, 64, &photo) }); + let m = lightcraft_meta::extract(&bytes); + assert_eq!(m.model.as_deref(), Some("Issue sweep camera")); + assert_eq!(m.capture_time.map(|d| d.to_iso()).as_deref(), Some("2026-10-12T12:34:56")); + if !lightcraft_codecs::Format::Heif.can_decode() { + return; // importing needs the decoder; `heic_imports_as_a_normal_photo_or_says_why_not` checks the error + } + let src = temp_dir("heic-exif"); + std::fs::write(src.join("IMG_0002.HEIC"), &bytes).unwrap(); + let mut s = Session::new().with_fs(); + let r = s.execute("library.import", &json!({"paths": [src.to_string_lossy()]})).unwrap(); + assert_eq!(ids(&r, "imported"), 1, "{r}"); + let p = s.catalog.photos().next().unwrap().clone(); + assert_eq!((p.meta.camera.as_str(), p.captured.as_deref()), ("Synthetic Issue sweep camera", Some("2026-10-12T12:34:56"))); + let all = s.execute("photo.allMetadata", &json!({"id": p.id.0})).unwrap(); + assert!(all["exif"].as_array().unwrap().iter().any(|r| r["name"] == "Model" && r["value"] == "Issue sweep camera"), "{all}"); + let _ = std::fs::remove_dir_all(&src); +} + +fn heic_camera_exif(date: &str) -> Vec<u8> { + use craft_tiff::{ByteOrder, IfdBuilder, TiffWriter, Value, tags as t}; + let mut exif = IfdBuilder::new(); + exif.set(t::DATE_TIME_ORIGINAL, Value::Ascii(date.into())); + exif.set(t::OFFSET_TIME_ORIGINAL, Value::Ascii("-05:00".into())); + let mut ifd0 = IfdBuilder::new(); + ifd0.set(t::MAKE, Value::Ascii("Apple".into())); + ifd0.set(t::MODEL, Value::Ascii("iPhone 15 Pro".into())); + ifd0.set(t::ORIENTATION, Value::Short(vec![6])); + ifd0.set_child(t::EXIF_IFD, exif); + TiffWriter::new(ByteOrder::Little, false).write(&[ifd0]).unwrap() +} + +#[test] +fn heic_exif_orientation_does_not_rotate_the_picture_twice() { + use craft_heif::testdata::{Prop, Spec, build}; + let photo = |x: u32, y: u32| [((x * 7 + y * 13) % 200 + 30) as u16, 110, 150]; + for (props, size) in [(vec![], (96, 64)), (vec![Prop::Irot(3)], (64, 96))] { + let plain = build(&Spec { props: props.clone(), ..Spec::new(96, 64, &photo) }); + let bytes = build(&Spec { props, exif: Some(heic_camera_exif("2026:10:18 13:00:00")), ..Spec::new(96, 64, &photo) }); + assert_eq!(lightcraft_meta::extract(&bytes).orientation, Some(lightcraft_geom::Orientation::Rotate90)); + if lightcraft_codecs::Format::Heif.can_decode() { + let header = lightcraft_codecs::read_header(&bytes).unwrap(); + assert_eq!((header.width, header.height, header.orientation), (size.0, size.1, 1)); + let info = crate::files::probe_bytes("rotated.HEIC", &bytes).unwrap(); + assert_eq!((info.width, info.height), size); + let (image, _) = crate::files::load_bytes(&bytes, 96).unwrap(); + let (without_exif, _) = crate::files::load_bytes(&plain, 96).unwrap(); + assert_eq!((image.width, image.height), (size.0 as usize, size.1 as usize)); + assert_eq!(image.data, without_exif.data, "Exif must not turn the decoded pixels again"); + } else { + assert!(crate::files::probe_bytes("rotated.HEIC", &bytes).unwrap_err().contains("isn't included in this build")); + assert!(crate::files::load_bytes(&bytes, 96).unwrap_err().contains("isn't included in this build")); + } + } +} + /// A batch-edit recipe changes the imported photos' actual develop settings (not just an option /// label), renders, is one undo step, and can be saved as a preset that stores only what it names. #[test] diff --git a/crates/meta/Cargo.toml b/crates/meta/Cargo.toml index a000caec95..709e804873 100644 --- a/crates/meta/Cargo.toml +++ b/crates/meta/Cargo.toml @@ -13,6 +13,7 @@ craft-raw = { workspace = true } craft-tiff = { workspace = true } craft-metadata = { workspace = true } craft-psd = { workspace = true } +craft-heif = { workspace = true, features = ["metadata"] } lightcraft-geom = { workspace = true } serde = { workspace = true } chrono = { workspace = true } diff --git a/crates/meta/README.md b/crates/meta/README.md index 0a7f2d8027..c39ef7da1a 100644 --- a/crates/meta/README.md +++ b/crates/meta/README.md @@ -8,12 +8,13 @@ Photo metadata: EXIF, XMP (read + write), IPTC-IIM, and the containers that carr |---|---| | `read_exif(&[u8]) -> Metadata` | TIFF-structured Exif block (whole TIFF/DNG/raw file, or JPEG APP1 payload with/without `Exif\0\0`). `try_read_exif` reports header errors. | | `from_tiff(&Tiff) -> Metadata` | Same, from an already parsed stream (used by `lightcraft-raw`). | -| `embedded(&[u8]) -> Embedded` | Sniffs JPEG / PNG / WebP / TIFF / PSD / PSB and returns the Exif, XMP (+ extended XMP), ICC and IPTC blocks. PSD/PSB EXIF resource 1058 and XMP resource 1060 are read from the bounded image-resource section without decoding pixels. `jpeg_segments`, `png_chunks`, `webp_chunks` are the per-container walkers. | +| `embedded(&[u8]) -> Embedded` | Sniffs JPEG / PNG / WebP / TIFF / PSD / PSB / Fujifilm RAF / Canon CR3 / HEIF (HEIC, AVIF) and returns the Exif, XMP (+ extended XMP), ICC and IPTC blocks. PSD/PSB EXIF resource 1058 and XMP resource 1060 are read from the bounded image-resource section without decoding pixels. `jpeg_segments`, `png_chunks`, `webp_chunks` are the per-container walkers; HEIF gives the primary image's `Exif` and XMP items, read without decoding (`src/heif.rs`). | | `parse_xmp(&str) -> Result<XmpData>` | Metadata + the opaque `lc:settings` JSON + every property (`prefix:name`, structs flattened as `a:b/c:d`). | | `write_xmp(&Metadata, Option<&str>) -> String` | Complete `<?xpacket?>` packet; the second argument is LightCraft's full develop settings JSON. | | `parse_iptc(&[u8]) -> Metadata` | IIM record 2: title (2:5), keywords (2:25), by-line (2:80), copyright (2:116), caption (2:120), date/time created (2:55/2:60). | | `extract(&[u8]) -> Metadata` | Everything for a whole file. Precedence: EXIF → IPTC fills gaps → XMP overrides user fields (rating, label, title, caption, artist, copyright, keywords, GPS) and fills the rest. | | `try_extract(&[u8]) -> Result<Metadata, ExtractError>` | Like `extract`, but reports malformed PSD/PSB headers, image-resource sections, or embedded EXIF/XMP structure (including duplicate EXIF/XMP resources) so callers can fail closed when location absence cannot be established. Other formats remain best-effort. | +| `embeds_location(&[u8]) -> bool` | Whether a file carries GPS anywhere it can be read from (export's "remove location" check): for HEIF every Exif and XMP item, whichever image it describes, with unreadable items and incomplete item catalogs counted as a location; otherwise what `extract` reads. | `Metadata` carries camera (make, model, serial, software), lens (make, model, serial, specification), capture (date-time with UTC offset and milliseconds, exposure time, f-number, ISO incl. extended ISO, focal length and @@ -46,6 +47,7 @@ No panics on malformed input: proptests feed random bytes to every container wal XMP parser; truncation tests cut a sample JPEG at every byte and exercise truncated PSD/PSB headers and image-resource records with hostile declared lengths. PSD/PSB XMP resources require valid UTF-8; trailing NUL padding is trimmed after validation. +The HEIF truncation and byte-damage tests cover bounded box and item walks; the reader walks `iloc` once. ISO capture-time parsing requires a complete clock and consumes every clock and fractional-second character. Invalid XMP capture-time values remain available in the raw property map but are not projected into `Metadata`; a later valid @@ -57,4 +59,9 @@ CIPA DC-008 (Exif 2.32), TIFF 6.0, Adobe DNG 1.7 (tag numbers), ISO 16684-1 / Ad Parts 1–3 (packet, RDF serialisation, standard schemas, JPEG extended XMP), IPTC-IIM 4.2 and the IPTC Photo Metadata Standard, ITU-T T.81 (JPEG markers), ICC.1 (APP2 embedding), PNG Specification 3rd ed. (`eXIf`, `iTXt`), the WebP RIFF container specification, Adobe Photoshop File Format Specification (image resource -blocks). XML parsing: `quick-xml` (MIT). No third-party metadata code was consulted. +blocks), ISO/IEC 14496-12 (ISO base media file format: boxes, `meta`, `iinf`, `iloc`, `iref`, `idat`) and +ISO/IEC 23008-12 (HEIF: items, `pitm`, `cdsc` and `dimg` references, the `Exif` item of annex A). XML parsing: +`quick-xml` (MIT). No third-party metadata reader was consulted (heic-rs's metadata test file, MIT / Apache-2.0, +was glanced at only while looking for sample files; its reader was not read). For a HEIF test, the code of avif-serialize +(BSD-3-Clause, the AVIF writer behind our AVIF export) was read only to learn how it lays out the `Exif` item it +writes; files from Apple ImageIO, libheif and ExifTool were examined as files only. diff --git a/crates/meta/src/heif.rs b/crates/meta/src/heif.rs index ae6523f080..d4ed0f5e3c 100644 --- a/crates/meta/src/heif.rs +++ b/crates/meta/src/heif.rs @@ -1,257 +1,67 @@ -//! HEIF / HEIC / AVIF metadata: the `Exif` and XMP items of the ISO base media file container -//! (box structure from ISO/IEC 14496-12, item model from ISO/IEC 23008-12). -//! -//! HEIC is what iPhones and Macs write. Its pixels need an HEVC decoder (the optional -//! `craft-heif` crate), its metadata does not, so this reader is in every build: a HEIC -//! imports with its capture time, camera and lens whether or not the build can show the picture. -//! -//! The `meta` box holds an item information box (`iinf`, one `infe` per item) naming each item's -//! type, and an item location box (`iloc`) saying where its bytes are: in the file, or in the -//! `idat` box next to it. The `Exif` item is a four-byte offset followed by a TIFF stream; the XMP -//! packet is a `mime` item whose content type is `application/rdf+xml`. The ICC profile is an item -//! *property*, not an item, and is read by the decoder instead. - +//! HEIF, HEIC and AVIF metadata through the shared decoder-independent item reader. use crate::Embedded; +pub use craft_heif::items::is_heif; -const MAX_BOXES: usize = 4096; - -#[derive(Clone, Copy)] -struct BoxRef { - kind: [u8; 4], - body: usize, - end: usize, -} - -fn be16(b: &[u8], at: usize) -> Option<u16> { - let s = b.get(at..at + 2)?; - Some(u16::from_be_bytes([s[0], s[1]])) -} - -fn be32(b: &[u8], at: usize) -> Option<u32> { - let s = b.get(at..at + 4)?; - Some(u32::from_be_bytes([s[0], s[1], s[2], s[3]])) -} - -fn be64(b: &[u8], at: usize) -> Option<u64> { - let s = b.get(at..at + 8)?; - Some(u64::from_be_bytes([s[0], s[1], s[2], s[3], s[4], s[5], s[6], s[7]])) -} - -fn boxes(bytes: &[u8], mut at: usize, end: usize, budget: &mut usize) -> Vec<BoxRef> { - let mut out = Vec::new(); - let end = end.min(bytes.len()); - while at + 8 <= end && *budget > 0 { - *budget -= 1; - let Some(size32) = be32(bytes, at) else { break }; - let Some(kind_slice) = bytes.get(at + 4..at + 8) else { break }; - let mut kind = [0u8; 4]; - kind.copy_from_slice(kind_slice); - let (hdr, box_end) = match size32 { - 0 => (8, end), - 1 => { - let Some(s64) = be64(bytes, at + 8) else { break }; - let Ok(s) = usize::try_from(s64) else { break }; - if s < 16 { - break; - } - (16, at.saturating_add(s).min(end)) - } - s if s >= 8 => (8, at.saturating_add(s as usize).min(end)), - _ => break, - }; - if at + hdr > box_end { - break; - } - out.push(BoxRef { kind, body: at + hdr, end: box_end }); - if box_end <= at { - break; - } - at = box_end; - } - out -} - -/// Brands that declare a still image in the ISO base media container. -const IMAGE_BRANDS: [&[u8]; 12] = [b"heic", b"heix", b"hevc", b"hevx", b"heim", b"heis", b"hevm", b"hevs", b"mif1", b"msf1", b"avif", b"avis"]; - -/// Longest `ftyp` box this reads brands from. -const MAX_FTYP: usize = 4096; -/// Most items one file's `iinf` / `iloc` describes (an iPhone HEIC has a handful). -const MAX_ITEMS: usize = 1024; -/// Most extents one item's bytes are split into. -const MAX_EXTENTS: u16 = 1024; -/// Largest metadata item this returns; a real photo's Exif and XMP are a few hundred kilobytes. -const MAX_ITEM: usize = 32 << 20; - -/// Does this file declare an ISO base media still image (HEIF / HEIC / AVIF)? -pub fn is_heif(bytes: &[u8]) -> bool { - if bytes.get(4..8) != Some(b"ftyp".as_slice()) { - return false; - } - let Some(size) = be32(bytes, 0).map(|v| v as usize) else { - return false; - }; - let end = size.min(bytes.len()).min(MAX_FTYP); - let brand = |at: usize| bytes.get(at..at.saturating_add(4)).is_some_and(|b| IMAGE_BRANDS.contains(&b)); - // the major brand, then (after the minor version) the compatible brands - brand(8) || (16..end).step_by(4).any(brand) -} - -/// The Exif and XMP blocks of a HEIF file. Anything malformed is left out rather than reported: -/// a file whose items can't be located simply has no metadata, as before this reader existed. +/// EXIF and XMP of the primary image, or empty metadata when no readable items exist. pub fn metadata(bytes: &[u8]) -> Embedded { - let mut out = Embedded::default(); - let mut budget = MAX_BOXES; - let Some(meta) = boxes(bytes, 0, bytes.len(), &mut budget).into_iter().find(|b| &b.kind == b"meta") else { - return out; - }; - // `meta` is a FullBox: a version and flags before its children - let (mut items, mut locs, mut idat) = (Vec::new(), Vec::new(), None); - for b in boxes(bytes, meta.body.saturating_add(4), meta.end, &mut budget) { - match &b.kind { - b"iinf" => items = item_infos(bytes, &b, &mut budget), - b"iloc" => locs = item_locations(bytes.get(b.body..b.end).unwrap_or_default()), - b"idat" => idat = bytes.get(b.body..b.end), - _ => {} - } - } - for (id, kind, content_type) in items { - let want_exif = &kind == b"Exif" && out.exif.is_none(); - let want_xmp = &kind == b"mime" && content_type == "application/rdf+xml" && out.xmp.is_none(); - if !want_exif && !want_xmp { - continue; - } - let Some(loc) = locs.iter().find(|l| l.id == id) else { continue }; - let Some(block) = item_bytes(bytes, idat, loc) else { continue }; - if want_exif { - // ISO/IEC 23008-12 A.2.1: a four-byte offset from the end of itself to the TIFF header - let skip = be32(&block, 0).and_then(|v| usize::try_from(v).ok()).and_then(|v| v.checked_add(4)); - out.exif = skip.and_then(|at| block.get(at..)).filter(|b| !b.is_empty()).map(<[u8]>::to_vec); - } else { - out.xmp = Some(String::from_utf8_lossy(&block).trim_end_matches('\0').to_string()); - } - } - out + let (exif, xmp) = craft_heif::items::read(bytes).unwrap_or_default(); + Embedded { exif, xmp, ..Default::default() } } -/// `iinf` → one `(item_ID, item_type, content_type)` per `infe` entry. Entries of version 0 and 1 -/// name no item type and are skipped; HEIF files use version 2 or 3. -fn item_infos(bytes: &[u8], iinf: &BoxRef, budget: &mut usize) -> Vec<(u32, [u8; 4], String)> { - // FullBox version and flags, then a 16- or 32-bit entry count before the `infe` boxes - let version = *bytes.get(iinf.body).unwrap_or(&0); - let entries_at = iinf.body.saturating_add(if version == 0 { 6 } else { 8 }); - let mut out = Vec::new(); - for b in boxes(bytes, entries_at, iinf.end, budget) { - if &b.kind != b"infe" || out.len() >= MAX_ITEMS { - continue; - } - let Some(e) = bytes.get(b.body..b.end) else { continue }; - let (id, kind_at) = match *e.first().unwrap_or(&0) { - 2 => (be16(e, 4).map(u32::from), 8), - 3 => (be32(e, 4), 10), - _ => continue, +/// Whether any HEIF metadata item contains location; uncertain items count as location. +pub(crate) fn embeds_location(bytes: &[u8]) -> Option<bool> { + use craft_heif::items::{Kind, exif_tiff, scan}; + let scan = scan(bytes).ok()?; + if !scan.complete() { + return Some(true); + } + for item in scan { + let bytes = match item.data { + Ok(bytes) => bytes, + Err(_) => return Some(true), }; - let (Some(id), Some(kind)) = (id, e.get(kind_at..kind_at + 4)) else { continue }; - let mut kind4 = [0u8; 4]; - kind4.copy_from_slice(kind); - // the item name, then (for a `mime` item) the content type, both NUL-terminated - let mut strings = e.get(kind_at + 4..).unwrap_or_default().split(|&c| c == 0).skip(1); - let content_type = String::from_utf8_lossy(strings.next().unwrap_or_default()).into_owned(); - out.push((id, kind4, content_type)); - } - out -} - -/// Where one item's bytes are. -struct Loc { - id: u32, - /// 0 = offsets into the file, 1 = into the `idat` box, 2 = another item (not read). - construction: u8, - base: u64, - /// `(offset, length)` per extent, in order. - extents: Vec<(u64, u64)>, -} - -/// `iloc` (payload after the box header) → one [`Loc`] per entry, stopping at the first -/// unreadable one. -fn item_locations(p: &[u8]) -> Vec<Loc> { - let version = *p.first().unwrap_or(&0); - let (Some(sizes), Some(base_index)) = (p.get(4), p.get(5)) else { return Vec::new() }; - let (offset_size, length_size) = ((sizes >> 4) as usize, (sizes & 0xf) as usize); - let (base_size, index_size) = ((base_index >> 4) as usize, if version > 0 { (base_index & 0xf) as usize } else { 0 }); - let (count, mut at) = match version { - 0 | 1 => (be16(p, 6).map(usize::from), 8), - 2 => (be32(p, 6).and_then(|v| usize::try_from(v).ok()), 10), - _ => return Vec::new(), - }; - let mut out = Vec::new(); - for _ in 0..count.unwrap_or(0).min(MAX_ITEMS) { - let (id, after_id) = match version { - 2 => (be32(p, at), at + 4), - _ => (be16(p, at).map(u32::from), at + 2), + let located = match item.kind { + Kind::Exif => match exif_tiff(&bytes) { + Some(tiff) => exif_has_location(tiff), + None => !bytes.is_empty(), + }, + Kind::Xmp => xmp_has_location(&String::from_utf8_lossy(&bytes)), + _ => true, }; - // version 1 and 2 put the construction method in the low nibble of a reserved 16-bit field - let construction = if version == 0 { Some(0) } else { be16(p, after_id).map(|v| (v & 0xf) as u8) }; - let after_method = after_id + if version == 0 { 0 } else { 2 }; - // a data reference index of 0 means this file; an external reference has no bytes here - let external = be16(p, after_method).is_some_and(|v| v != 0); - let base = uint(p, after_method + 2, base_size); - let extent_at = after_method + 2 + base_size; - let (Some(id), Some(construction), Some(base), Some(extent_count)) = (id, construction, base, be16(p, extent_at)) else { - break; - }; - let stride = index_size + offset_size + length_size; - let mut extents = Vec::new(); - let mut e = extent_at + 2; - for _ in 0..extent_count.min(MAX_EXTENTS) { - let (Some(offset), Some(length)) = (uint(p, e + index_size, offset_size), uint(p, e + index_size + offset_size, length_size)) else { - return out; - }; - extents.push((offset, length)); - e += stride; - } - at = e; - if !external { - out.push(Loc { id, construction, base, extents }); + if located { + return Some(true); } } - out + Some(false) } -/// A big-endian unsigned integer of `size` bytes; `size` 0 is the value 0, and the item boxes -/// allow no other width than 4 or 8. -fn uint(b: &[u8], at: usize, size: usize) -> Option<u64> { - match size { - 0 => Some(0), - 4 => be32(b, at).map(u64::from), - 8 => be64(b, at), - _ => None, +/// Any GPS tag counts, not only a complete coordinate pair: the projected [`crate::Metadata`] keeps +/// GPS only when latitude and longitude both read, yet a lone latitude is still a location. A GPS +/// IFD pointer whose directory can't be read counts too, and so does any directory the reader +/// couldn't read in full: an entry past its entry limit can be the GPS pointer. +fn exif_has_location(tiff: &[u8]) -> bool { + use craft_tiff::{ParseOptions, Tiff, tags as t}; + let Ok((parsed, complete)) = Tiff::parse_with_status(tiff, &ParseOptions::default()) else { return true }; + if !complete { + return true; } + let gps = parsed.all_ifds().into_iter().any(|ifd| match &ifd.gps { + Some(gps) => gps.entries.iter().any(|e| e.tag != t::GPS_VERSION_ID), + None => ifd.contains(t::GPS_IFD), + }); + gps || crate::try_read_exif(tiff).map_or(true, |m| crate::has_location(&m)) } -/// An item's bytes, its extents concatenated. `None` when they don't fit the file (or the `idat` -/// box), when the item is built by referencing another one, or when it is implausibly large. -fn item_bytes(bytes: &[u8], idat: Option<&[u8]>, loc: &Loc) -> Option<Vec<u8>> { - let src = match loc.construction { - 0 => bytes, - 1 => idat?, - _ => return None, - }; - let mut out = Vec::new(); - for &(offset, length) in &loc.extents { - let at = loc.base.checked_add(offset)?; - let (start, end) = (usize::try_from(at).ok()?, usize::try_from(at.checked_add(length)?).ok()?); - let extent = src.get(start..end)?; - if out.len().checked_add(extent.len())? > MAX_ITEM { - return None; - } - out.extend_from_slice(extent); - } - (!out.is_empty()).then_some(out) +/// The packet's whole location inventory (IPTC `LocationShown` / `LocationCreated`, GPS +/// properties), not only the fields projected into [`crate::Metadata`]. A packet whose property +/// list was cut short can't prove it has none. +fn xmp_has_location(packet: &str) -> bool { + let Ok(xmp) = crate::xmp::parse_xmp_with(packet, &[]) else { return true }; + xmp.properties_truncated || xmp.has_location_metadata() || crate::parse_xmp(packet).map_or(true, |x| crate::has_location(&x.metadata)) } - #[cfg(test)] -mod tests { +#[allow(clippy::indexing_slicing, clippy::arithmetic_side_effects)] +mod upstream_tests { use super::*; // the whole routing, not just this module: a HEIC must reach the HEIF branch of `embedded` use crate::embedded; @@ -460,3 +270,347 @@ mod tests { assert_eq!(crate::extract(&file).capture_time.map(|d| d.to_iso()).as_deref(), Some("2026-10-18T13:00:00-05:00")); } } + +#[cfg(test)] +#[allow(clippy::arithmetic_side_effects, clippy::indexing_slicing, dead_code)] +mod location_tests { + use craft_heif::items::MAX_ITEM; + fn bx(kind: &[u8; 4], payload: &[u8]) -> Vec<u8> { + let mut v = ((payload.len() + 8) as u32).to_be_bytes().to_vec(); + v.extend_from_slice(kind); + v.extend_from_slice(payload); + v + } + + fn full(kind: &[u8; 4], version: u8, payload: &[u8]) -> Vec<u8> { + bx(kind, &[&[version, 0, 0, 0][..], payload].concat()) + } + + fn put(v: &mut Vec<u8>, x: u64, size: u8) { + match size { + 0 => assert_eq!(x, 0, "a value needs a field"), + 2 => v.extend_from_slice(&(x as u16).to_be_bytes()), + 4 => v.extend_from_slice(&(x as u32).to_be_bytes()), + 8 => v.extend_from_slice(&x.to_be_bytes()), + _ => panic!("no {size}-byte fields"), + } + } + + /// An EXIF item as HEIF stores it: the 4-byte offset, `skip` (which the offset jumps), the TIFF. + fn exif_item(skip: &[u8], tiff: &[u8]) -> Vec<u8> { + [&(skip.len() as u32).to_be_bytes()[..], skip, tiff].concat() + } + + fn tiff_with(model: &str) -> Vec<u8> { + crate::write_exif(&crate::Metadata { model: Some(model.into()), ..Default::default() }) + } + + #[derive(Clone, Copy, PartialEq)] + enum Store { + File, + Idat, + } + + struct Item { + id: u32, + kind: &'static [u8; 4], + /// `mime` items: content type and content encoding. + mime: (&'static str, &'static str), + data: Vec<u8>, + store: Store, + /// Extents the data is split into. + extents: usize, + } + + /// A HEIF file for the tests: `ftyp`, `meta` (`hdlr`, `pitm`, `iinf`, `iref`, `iloc`, `idat`) + /// and `mdat`. + struct Heif { + ftyp: Vec<u8>, + primary: u32, + items: Vec<Item>, + /// `iref` references: type, from, to. + refs: Vec<(&'static [u8; 4], u32, Vec<u32>)>, + /// `iloc` version and its offset, length, base-offset and index field sizes. + iloc: (u8, [u8; 4]), + /// 32-bit item ids: `infe` version 3, `pitm` and `iref` version 1 (`iloc` must be version 2). + wide: bool, + } + + impl Heif { + /// A primary HEVC picture, item 1 (its bytes don't matter here). + fn new() -> Heif { + let picture = Item { id: 1, kind: b"hvc1", mime: ("", ""), data: b"coded picture".to_vec(), store: Store::File, extents: 1 }; + Heif { ftyp: b"heic\0\0\0\0mif1heic".to_vec(), primary: 1, items: vec![picture], refs: Vec::new(), iloc: (1, [4, 4, 0, 0]), wide: false } + } + + fn item(mut self, id: u32, kind: &'static [u8; 4], data: Vec<u8>, store: Store, extents: usize) -> Heif { + self.items.push(Item { id, kind, mime: ("", ""), data, store, extents }); + self + } + + fn xmp(mut self, id: u32, mime: (&'static str, &'static str), data: Vec<u8>) -> Heif { + self.items.push(Item { id, kind: b"mime", mime, data, store: Store::File, extents: 1 }); + self + } + + fn cdsc(self, from: u32, to: &[u32]) -> Heif { + self.iref(b"cdsc", from, to) + } + + fn iref(mut self, kind: &'static [u8; 4], from: u32, to: &[u32]) -> Heif { + self.refs.push((kind, from, to.to_vec())); + self + } + + fn meta(&self, mdat_at: usize) -> Vec<u8> { + let id = |v: &mut Vec<u8>, id: u32| put(v, u64::from(id), if self.wide { 4 } else { 2 }); + let mut hdlr = vec![0u8; 4]; + hdlr.extend_from_slice(b"pict"); + hdlr.extend_from_slice(&[0; 13]); + let mut pitm = Vec::new(); + id(&mut pitm, self.primary); + let mut iinf = Vec::new(); + put(&mut iinf, self.items.len() as u64, if self.wide { 4 } else { 2 }); + for it in &self.items { + let mut e = Vec::new(); + id(&mut e, it.id); + e.extend_from_slice(&[0, 0]); // not protected + e.extend_from_slice(it.kind); + e.push(0); // no name + if it.kind == b"mime" { + e.extend_from_slice(it.mime.0.as_bytes()); + e.push(0); + e.extend_from_slice(it.mime.1.as_bytes()); + e.push(0); + } + iinf.extend(full(b"infe", if self.wide { 3 } else { 2 }, &e)); + } + let mut iref = Vec::new(); + for (kind, from, to) in &self.refs { + let mut r = Vec::new(); + id(&mut r, *from); + put(&mut r, to.len() as u64, 2); + to.iter().for_each(|t| id(&mut r, *t)); + iref.extend(bx(kind, &r)); + } + let (version, [o, l, b, i]) = self.iloc; + let mut iloc = vec![o << 4 | l, b << 4 | i]; + put(&mut iloc, self.items.len() as u64, if version == 2 { 4 } else { 2 }); + let (mut in_file, mut in_idat) = (mdat_at as u64, 0u64); + let mut idat = Vec::new(); + for it in &self.items { + put(&mut iloc, u64::from(it.id), if version == 2 { 4 } else { 2 }); + let at = match it.store { + Store::File => &mut in_file, + Store::Idat => &mut in_idat, + }; + if version > 0 { + put(&mut iloc, if it.store == Store::Idat { 1 } else { 0 }, 2); + } + put(&mut iloc, 0, 2); // this file + let base = if b > 0 { *at } else { 0 }; + put(&mut iloc, base, b); + let chunk = it.data.len().div_ceil(it.extents.max(1)).max(1); + let pieces: Vec<&[u8]> = it.data.chunks(chunk).collect(); + put(&mut iloc, pieces.len() as u64, 2); + for piece in pieces { + if version > 0 { + put(&mut iloc, 0, i); + } + put(&mut iloc, *at - base, o); + put(&mut iloc, piece.len() as u64, l); + *at += piece.len() as u64; + } + if it.store == Store::Idat { + idat.extend_from_slice(&it.data); + } + } + let ref_version = if self.wide { 1 } else { 0 }; + let boxes = [ + full(b"hdlr", 0, &hdlr), + full(b"pitm", ref_version, &pitm), + full(b"iinf", ref_version, &iinf), + full(b"iref", ref_version, &iref), + full(b"iloc", version, &iloc), + bx(b"idat", &idat), + ]; + full(b"meta", 0, &boxes.concat()) + } + + fn build(&self) -> Vec<u8> { + let ftyp = bx(b"ftyp", &self.ftyp); + let mdat_at = ftyp.len() + self.meta(0).len() + 8; + let mdat: Vec<u8> = self.items.iter().filter(|i| i.store == Store::File).flat_map(|i| i.data.iter().copied()).collect(); + [ftyp, self.meta(mdat_at), bx(b"mdat", &mdat)].concat() + } + } + fn tiff_at(latitude: f64) -> Vec<u8> { + crate::write_exif(&crate::Metadata { gps: Some(crate::Gps { latitude, longitude: 2.0, altitude: None }), ..Default::default() }) + } + + /// Export's "remove location" check sees GPS anywhere in a HEIF's metadata, not only in the + /// photo's own first EXIF (#693 review): a thumbnail's EXIF, the primary image's second EXIF + /// item, an XMP item. What it can't read counts as a location, so the original isn't copied + /// out on a guess. + #[test] + fn a_location_anywhere_in_the_metadata_is_seen() { + let plain = tiff_with("Primary"); + let thumb = |h: Heif| h.item(2, b"hvc1", b"thumbnail".to_vec(), Store::File, 1); + // only the thumbnail's EXIF has GPS + let f = thumb(Heif::new()) + .item(10, b"Exif", exif_item(&[], &plain), Store::File, 1) + .item(11, b"Exif", exif_item(&[], &tiff_at(1.0)), Store::File, 1) + .cdsc(10, &[1]) + .cdsc(11, &[2]) + .build(); + assert_eq!(crate::extract(&f).gps, None, "the photo's own EXIF has none"); + assert!(crate::embeds_location(&f), "thumbnail"); + // the primary image's second EXIF item has it + let f = Heif::new() + .item(10, b"Exif", exif_item(&[], &plain), Store::File, 1) + .item(11, b"Exif", exif_item(&[], &tiff_at(1.0)), Store::File, 1) + .cdsc(10, &[1]) + .cdsc(11, &[1]) + .build(); + assert_eq!(crate::extract(&f).gps, None); + assert!(crate::embeds_location(&f), "second EXIF item"); + // a thumbnail's XMP has it + let rdf = ("application/rdf+xml", ""); + let xmp = crate::write_xmp( + &crate::Metadata { gps: Some(crate::Gps { latitude: 1.0, longitude: 2.0, altitude: None }), ..Default::default() }, + None, + ); + let f = thumb(Heif::new()) + .item(10, b"Exif", exif_item(&[], &plain), Store::File, 1) + .cdsc(10, &[1]) + .xmp(20, rdf, xmp.into_bytes()) + .cdsc(20, &[2]) + .build(); + assert!(crate::embeds_location(&f), "thumbnail XMP"); + // no location anywhere + let f = thumb(Heif::new()) + .item(10, b"Exif", exif_item(&[], &plain), Store::File, 1) + .item(11, b"Exif", exif_item(&[], &tiff_with("Thumbnail")), Store::File, 1) + .cdsc(10, &[1]) + .cdsc(11, &[2]) + .build(); + assert!(!crate::embeds_location(&f)); + // unsure counts as yes: a compressed XMP item, an EXIF item cut off by the end of the file, + // one larger than the reader takes, more items than it looks at + let f = Heif::new().xmp(20, ("application/rdf+xml", "deflate"), b"compressed".to_vec()).build(); + assert!(crate::embeds_location(&f), "compressed XMP"); + let mut f = Heif::new().item(10, b"Exif", exif_item(&[], &plain), Store::File, 1).build(); + f.truncate(f.len() - 1); + assert!(crate::embeds_location(&f), "cut off"); + let f = Heif::new().item(10, b"Exif", exif_item(&[], &vec![0; MAX_ITEM]), Store::File, 1).build(); + assert!(crate::embeds_location(&f), "too large"); + let mut h = Heif::new(); + for id in 0..2000 { + h = h.item(10 + id, b"Exif", exif_item(&[], &plain), Store::File, 1); + } + assert!(crate::embeds_location(&h.build()), "too many items"); + // other files: what `extract` reads + assert!(crate::embeds_location(&tiff_at(1.0))); + assert!(!crate::embeds_location(&plain)); + } + /// A GPS IFD with a latitude but no longitude reads as no `Gps`, but it is still a location + /// (#4315 review). + #[test] + fn a_lone_gps_latitude_in_a_thumbnail_is_seen() { + use craft_tiff::{ByteOrder, IfdBuilder, TiffWriter, Value, tags as t}; + let tiff = |gps: Option<IfdBuilder>| { + let mut ifd0 = IfdBuilder::new(); + ifd0.set(t::MODEL, Value::Ascii("Thumbnail".into())); + if let Some(gps) = gps { + ifd0.set_child(t::GPS_IFD, gps); + } + TiffWriter::new(ByteOrder::Little, false).write(&[ifd0]).unwrap_or_default() + }; + let mut latitude = IfdBuilder::new(); + latitude.set(t::GPS_VERSION_ID, Value::Byte(vec![2, 3, 0, 0])); + latitude.set(t::GPS_LATITUDE_REF, Value::Ascii("N".into())); + latitude.set(t::GPS_LATITUDE, Value::Rational(vec![(48, 1), (51, 1), (0, 1)])); + let mut version_only = IfdBuilder::new(); + version_only.set(t::GPS_VERSION_ID, Value::Byte(vec![2, 3, 0, 0])); + for (gps, located) in [(Some(latitude), true), (Some(version_only), false), (None, false)] { + let tiff = tiff(gps); + assert_eq!(crate::read_exif(&tiff).gps, None, "no coordinate pair"); + let f = Heif::new() + .item(2, b"hvc1", b"thumbnail".to_vec(), Store::File, 1) + .item(3, b"Exif", exif_item(&[], &tiff), Store::File, 1) + .cdsc(3, &[2]) + .build(); + assert_eq!(crate::embeds_location(&f), located); + } + } + + /// A GPS pointer the reader never reaches, after its 8,192-entry limit, still counts (#4315 + /// review): an incompletely read EXIF item is a possible location. + #[test] + fn a_gps_pointer_past_the_entry_limit_counts_as_a_location() { + let entries = 8193u32; + let gps_at = 8 + 2 + 12 * entries + 4; + let mut tiff = b"II\x2a\0\x08\0\0\0".to_vec(); + tiff.extend_from_slice(&(entries as u16).to_le_bytes()); + for tag in 1..entries as u16 { + // SHORT, count 1, value 0 + tiff.extend_from_slice(&[&tag.to_le_bytes()[..], &[3, 0, 1, 0, 0, 0, 0, 0, 0, 0]].concat()); + } + tiff.extend_from_slice(&[&34853u16.to_le_bytes()[..], &[4, 0, 1, 0, 0, 0], &gps_at.to_le_bytes()].concat()); + tiff.extend_from_slice(&0u32.to_le_bytes()); + // GPS IFD: GPSLatitudeRef "N", then no next IFD + tiff.extend_from_slice(&[1, 0, 1, 0, 2, 0, 2, 0, 0, 0, b'N', 0, 0, 0, 0, 0, 0, 0]); + let f = Heif::new() + .item(2, b"hvc1", b"thumbnail".to_vec(), Store::File, 1) + .item(3, b"Exif", exif_item(&[], &tiff), Store::File, 1) + .cdsc(3, &[2]) + .build(); + assert!(crate::embeds_location(&f)); + } + + /// An IPTC `LocationShown` place is a location even though it isn't projected into + /// `Metadata`'s city or country (#4315 review). + #[test] + fn an_iptc_location_shown_in_a_thumbnail_is_seen() { + let packet = |inner: &str| { + format!( + r#"<x:xmpmeta xmlns:x="adobe:ns:meta/"><rdf:RDF xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"><rdf:Description rdf:about="" xmlns:Iptc4xmpExt="http://iptc.org/std/Iptc4xmpExt/2008-02-29/" xmlns:dc="http://purl.org/dc/elements/1.1/">{inner}</rdf:Description></rdf:RDF></x:xmpmeta>"# + ) + }; + let shown = packet( + r#"<Iptc4xmpExt:LocationShown><rdf:Bag><rdf:li rdf:parseType="Resource"><Iptc4xmpExt:City>Paris</Iptc4xmpExt:City></rdf:li></rdf:Bag></Iptc4xmpExt:LocationShown>"#, + ); + let plain = packet(r#"<dc:format>image/heic</dc:format>"#); + for (xmp, located) in [(shown, true), (plain, false)] { + assert!(crate::parse_xmp(&xmp).is_ok_and(|x| !crate::has_location(&x.metadata)), "not projected into Metadata"); + let f = Heif::new() + .item(2, b"hvc1", b"thumbnail".to_vec(), Store::File, 1) + .xmp(3, ("application/rdf+xml", ""), xmp.into_bytes()) + .cdsc(3, &[2]) + .build(); + assert_eq!(crate::embeds_location(&f), located); + } + } + + /// Original export checks place names in every metadata item, like GPS coordinates. + #[test] + fn place_names_in_a_thumbnail_are_seen_for_original_export() { + for (metadata, located) in [ + (crate::Metadata { sublocation: Some("Test place".into()), ..Default::default() }, true), + (crate::Metadata { city: Some("Test city".into()), ..Default::default() }, true), + (crate::Metadata { state: Some("Test state".into()), ..Default::default() }, true), + (crate::Metadata { country: Some("Test country".into()), ..Default::default() }, true), + (crate::Metadata { title: Some("A title without location".into()), ..Default::default() }, false), + ] { + let xmp = crate::write_xmp(&metadata, None); + assert!(crate::parse_xmp(&xmp).is_ok()); + let f = Heif::new() + .item(2, b"hvc1", b"thumbnail".to_vec(), Store::File, 1) + .xmp(3, ("application/rdf+xml", ""), xmp.into_bytes()) + .cdsc(3, &[2]) + .build(); + assert!(crate::embedded(&f).xmp.is_none(), "the thumbnail's packet is not the primary image's"); + assert_eq!(crate::embeds_location(&f), located, "{metadata:?}"); + } + } +} diff --git a/crates/meta/src/lib.rs b/crates/meta/src/lib.rs index 71b935c486..03605314a6 100644 --- a/crates/meta/src/lib.rs +++ b/crates/meta/src/lib.rs @@ -407,6 +407,23 @@ pub fn lens_spec_name(spec: [f64; 4]) -> Option<String> { Some(format!("{focal} mm f/{aperture}")) } +/// Does the file embed GPS or a place name anywhere it can be read from? Export's "remove location" +/// asks before copying an original byte for byte. For HEIF, HEIC and AVIF that is any EXIF or XMP +/// item, whichever image it describes (a thumbnail's too), and an item that can't be read counts +/// as a location; for other files, what [`extract`] reads. +pub fn embeds_location(bytes: &[u8]) -> bool { + heif::embeds_location(bytes).unwrap_or_else(|| has_location(&extract(bytes))) +} + +/// Location includes the place names removed by export, as well as GPS coordinates. +fn has_location(metadata: &Metadata) -> bool { + metadata.gps.is_some() + || [metadata.sublocation.as_deref(), metadata.city.as_deref(), metadata.state.as_deref(), metadata.country.as_deref()] + .into_iter() + .flatten() + .any(|value| !value.trim().is_empty()) +} + /// Lenient number parsing used by XMP/IPTC: `"28/10"`, `"2.8"`, `"+0.7"`. #[cfg(test)] pub(crate) fn parse_number(s: &str) -> Option<f64> { diff --git a/docs/file-format-parity.md b/docs/file-format-parity.md index e6f3b33d3f..c739886162 100644 --- a/docs/file-format-parity.md +++ b/docs/file-format-parity.md @@ -19,8 +19,8 @@ import and export formats. Ours come from `crates/codecs/src/sniff.rs`, `crates/ | TIFF | ✅ 8/16/32-bit | ✅ 8/16-bit, LZW/ZIP | ✅ 1–64-bit integer, 16–64-bit float, bilevel, CCITT fax, WhiteIsZero | ✅ 8/16-bit, 32-bit float linear, none / LZW / ZIP | `crates/tiff`, `crates/codecs/src/tiff_codec.rs` | | PNG | ✅ | ✅ | ✅ | ✅ | | | PSD / PSB | ✅ (maximized-compatibility composite) | ✅ (Classic: PSD export, edit-in round trip) | ✅ merged composite | ⬜ (external-editor round trip writes 16-bit TIFF) | `crates/codecs/src/psd.rs` | -| HEIC / HEIF | ✅ | ⬜ (Classic) / HDR only | ✅ in every release build (`craft-heif` from craft-libs, heic-rs) | ⬜ | `heif` feature on by packaging scripts | -| AVIF | ✅ | ✅ (HDR) | ⬜ recognised, not decoded (no permissive pure-Rust AV1 decoder) | ✅ 8/10-bit, PQ HDR | | +| HEIC / HEIF | ✅ | ⬜ (Classic) / HDR only | ✅ in every release build (`craft-heif` from craft-libs, heic-rs) | ⬜ | `heif` feature on by packaging scripts; EXIF and XMP read from the container in every build (`crates/meta/src/heif.rs`, #693) | +| AVIF | ✅ | ✅ (HDR) | ⬜ recognised, not decoded (no permissive pure-Rust AV1 decoder) | ✅ 8/10-bit, PQ HDR | EXIF and XMP read from the container (`crates/meta/src/heif.rs`); exported EXIF reads back | | JPEG XL | ✅ | ✅ | ✅ (`jxl-oxide`) incl. DNG 1.7 JXL tiles | ✅ lossy / lossless, 8/16-bit, PQ HDR (`jixel`, native only; ⬜ web) | `crates/engine/src/tests/export.rs` | | WebP | not in its document types | ⬜ | ✅ | ✅ | beyond target | | GIF, BMP | ⬜ | ⬜ | ✅ | ⬜ | beyond target | @@ -79,5 +79,6 @@ Remaining: **26–47 h** (AVIF decode 8–15 h if a permissive decoder is writte | 2026-10-10 | major | Created from the code and the installed Lightroom's document types | | 2026-10-10 | minor | JPEG XL export (#247): JXL write ✅ (native only), PQ JPEG XL HDR | | 2026-10-12 | minor | Render to DNG: "Rendered DNG" export format (linear 16-bit float DNG of the rendered photo) | +| 2026-10-12 | minor | HEIC / HEIF and AVIF: EXIF and XMP read from the container, without the decoder (#693); statuses unchanged | | 2026-10-12 | minor | Lossy DNG export (JPEG tiles, `dngCompression: "lossy"`); PSD write had already landed (#953), so it leaves the remaining hours | | 2026-10-13 | patch | JPEG write (#1373): Huffman tables made for each image, 12–14 % smaller files at the same pixels; statuses unchanged | diff --git a/docs/target-app-parity.md b/docs/target-app-parity.md index 8198a54bd9..02955c52a9 100644 --- a/docs/target-app-parity.md +++ b/docs/target-app-parity.md @@ -159,7 +159,7 @@ essentials replaces its guessed 45% raw look with 84% × 0.75 (+1 point). |---|---:|---:|---| | Interaction fidelity / UI clarity | ×0.95 | ×0.95 | brush live preview gaps and feathering (#517, #518); crop artefacts and limits (#731, #742, #770, #771); Compare white-balance selector (#743–#745); low-res slider previews (#330); dialogs taller than the window (#781); mouse-wheel scroll (#714) | | Stability on real machines | ×0.92 | ×0.92 | launch and quit crashes or silent startup failures (#250 macOS 12 Intel, #315 Windows Intel GPU, #431 Intel Mac, #260, #462, #783 Linux / Nouveau, #790 Windows installer, fixed in 0.9.1); tests run in CI on Linux x64 and FreeBSD (nightly), not on macOS or Windows (gap 9) | -| File exchange with Lightroom users (mainstream) / opening files people send (essentials) | ×0.92 | ×0.95 | Adobe XMP sidecars change colours (#290), XMP CameraProfile and Upright ignored (#204, #205), catalog import fails (#599), same Light values render differently (#523, #209), no write-back to `.lrcat`; for casual users: CR3 beyond verified bodies, HE NEF open as previews (#473, #556), HEIC trouble (#693) | +| File exchange with Lightroom users (mainstream) / opening files people send (essentials) | ×0.92 | ×0.95 | Adobe XMP sidecars change colours (#290), XMP CameraProfile and Upright ignored (#204, #205), catalog import fails (#599), same Light values render differently (#523, #209), no write-back to `.lrcat`; for casual users: CR3 beyond verified bodies, HE NEF open as previews (#473, #556) | | **Product** | **×0.804** | **×0.830** | | ### Mainstream practitioner: ~51% @@ -318,6 +318,7 @@ P2 items 12–25 h; look tuning, performance, packaging, hardening 25–45 h. | 2026-10-14 | minor | Camera-coverage sweep (#1327): 30 models verified on 40 CC0 files (`coverage_sweep_corpus.rs`, `coverage-sweep.tsv`; `docs/raw/coverage.py` 515 → 545 verified rows); the counts above are not re-measured here. Sensor verification does not establish colour parity (#1277); headline numbers unchanged | | 2026-10-12 | minor | 22 more CR3 bodies verified on one CC0 file each (raw-parity.md): use-weighted share whose camera decodes 85% → 92%, RAW decoding 77% → 83%; full 60.7% → 61.2% (~61%), mainstream depth 72.1% → 74.0% (~49% → ~51%), essentials depth 77.5% → 78.0% (~64% → ~65%) | | 2026-10-12 | minor | 117 Nikon and Fujifilm bodies verified (raw-parity.md): use-weighted share whose camera decodes 85% → 86%, RAW decoding 77% (unchanged); mainstream depth 72.1% → 72.4%, essentials depth 77.5% → 77.6%; headline numbers unchanged | +| 2026-10-12 | minor | File-exchange discount: "HEIC trouble (#693)" is no longer among its reasons (HEIC decodes in release builds since #609 and keeps its EXIF and XMP since #693); the factor (×0.92 / ×0.95) is not re-measured and stays as it is | | 2026-10-11 | minor | EOS R5 Mark II CR3 verified (raw-parity.md): use-weighted share whose camera decodes 84% → 85%, RAW decoding 76% → 77%; full 60.6% → 60.7%, mainstream depth 71.8% → 72.1%, essentials depth 77.4% → 77.5%; the rounded numbers (~61%, ~49%, ~64%) are unchanged | | 2026-10-10 | minor | RAW measured model by model (raw-parity.md): RAW decoding (76%) and colour (35%) are explicit rows of the full sum (59% → 61%); mainstream uses the use-weighted 84% plus a ×0.85 colour discount (51% → 49%); essentials uses 84% × colour 0.75 (63% → 64%); beta ~14 points | | 2026-10-10 | minor | Full number restored to an additive weighted sum over the dimensions (~59%; no new evidence); hours to ~95% for each of the three audiences; beta distance ~16 points | diff --git a/packaging/linux/flatpak/cargo-sources.json b/packaging/linux/flatpak/cargo-sources.json index 2a326941c3..534231be87 100644 --- a/packaging/linux/flatpak/cargo-sources.json +++ b/packaging/linux/flatpak/cargo-sources.json @@ -35,6 +35,12 @@ "commit": "b77af389f30bb10de10d8436ca9b39fe94e3bb67", "dest": "flatpak-cargo/git/craft-libs-b77af38" }, + { + "type": "git", + "url": "https://github.com/storytold/craft-libs", + "commit": "4ffa307f1a0a6fbd8897318cc719440ab06e9c63", + "dest": "flatpak-cargo/git/craft-libs-4ffa307" + }, { "type": "git", "url": "https://github.com/storytold/craft-libs", @@ -1726,19 +1732,19 @@ { "type": "shell", "commands": [ - "mkdir -p \"cargo/vendor-git/36bf00be069421f8a8a7428c4360efee8b4243207a59d7b566c6f48fc5918f61\" && cp -r --reflink=auto \"flatpak-cargo/git/craft-libs-9dcbd90/crates/heif\" \"cargo/vendor-git/36bf00be069421f8a8a7428c4360efee8b4243207a59d7b566c6f48fc5918f61/craft-heif\"" + "mkdir -p \"cargo/vendor-git/ded75ace3b48131a7498b2ad3ce7884b178155a1ef794dda2327c20c2979a816\" && cp -r --reflink=auto \"flatpak-cargo/git/craft-libs-4ffa307/crates/heif\" \"cargo/vendor-git/ded75ace3b48131a7498b2ad3ce7884b178155a1ef794dda2327c20c2979a816/craft-heif\"" ] }, { "type": "inline", - "contents": "[package]\nname = \"craft-heif\"\ndescription = \"Optional HEIF/HEIC still-image decoder: heic-rs for the container and HEVC, libheif-matching colour conversion, panic-guarded.\"\nversion = \"0.1.0\"\nedition = \"2024\"\nlicense = \"MIT OR Apache-2.0\"\nrust-version = \"1.95\"\nrepository = \"https://github.com/storytold/craft-libs\"\n\n[dependencies.heic-rs]\nversion = \"=0.1.4\"\ndefault-features = false\nfeatures = [\"std\"]\noptional = true\n\n[target.\"cfg(not(target_arch = \\\"wasm32\\\"))\".dependencies.heic-rs]\nversion = \"=0.1.4\"\ndefault-features = false\nfeatures = [\"std\", \"parallel\"]\noptional = true\n\n[target.\"cfg(not(target_arch = \\\"wasm32\\\"))\".dependencies.rayon]\noptional = true\nversion = \"1\"\n\n[features]\ndefault = [\"decode\"]\ndecode = [\"dep:heic-rs\", \"dep:rayon\"]\nmetadata = []\ntestdata = []\n\n[lints.rust]\nunsafe_code = \"forbid\"\nunused_workspace_dependencies = \"allow\"\n\n[lints.rust.unexpected_cfgs]\nlevel = \"warn\"\ncheck-cfg = [\"cfg(craft_pdf_unicode_fixtures)\"]\n\n[lints.clippy]\ncognitive_complexity = \"deny\"\ntoo_many_arguments = \"deny\"\nunused_workspace_dependencies = \"allow\"\nwildcard_imports = \"deny\"\ndbg_macro = \"warn\"\ntodo = \"warn\"\n", - "dest": "cargo/vendor-git/36bf00be069421f8a8a7428c4360efee8b4243207a59d7b566c6f48fc5918f61/craft-heif", + "contents": "[package]\nname = \"craft-heif\"\ndescription = \"Optional HEIF/HEIC still-image decoder: heic-rs for the container and HEVC, libheif-matching colour conversion, panic-guarded.\"\nversion = \"0.1.0\"\nedition = \"2024\"\nlicense = \"MIT OR Apache-2.0\"\nrust-version = \"1.95\"\nrepository = \"https://github.com/storytold/craft-libs\"\n\n[dependencies.heic-rs]\nversion = \"=0.1.4\"\ndefault-features = false\nfeatures = [\"std\"]\noptional = true\n\n[target.\"cfg(not(target_arch = \\\"wasm32\\\"))\".dependencies.heic-rs]\nversion = \"=0.1.4\"\ndefault-features = false\nfeatures = [\"std\", \"parallel\"]\noptional = true\n\n[target.\"cfg(not(target_arch = \\\"wasm32\\\"))\".dependencies.rayon]\noptional = true\nversion = \"1\"\n\n[dev-dependencies]\nproptest = \"1\"\n\n[features]\ndefault = [\"decode\"]\ndecode = [\"dep:heic-rs\", \"dep:rayon\"]\nmetadata = []\ntestdata = []\n\n[lints.rust]\nunsafe_code = \"forbid\"\nunused_workspace_dependencies = \"allow\"\n\n[lints.rust.unexpected_cfgs]\nlevel = \"warn\"\ncheck-cfg = [\"cfg(craft_pdf_unicode_fixtures)\"]\n\n[lints.clippy]\ncognitive_complexity = \"deny\"\ntoo_many_arguments = \"deny\"\nunused_workspace_dependencies = \"allow\"\nwildcard_imports = \"deny\"\ndbg_macro = \"warn\"\ntodo = \"warn\"\n", + "dest": "cargo/vendor-git/ded75ace3b48131a7498b2ad3ce7884b178155a1ef794dda2327c20c2979a816/craft-heif", "dest-filename": "Cargo.toml" }, { "type": "inline", "contents": "{\"package\": null, \"files\": {}}", - "dest": "cargo/vendor-git/36bf00be069421f8a8a7428c4360efee8b4243207a59d7b566c6f48fc5918f61/craft-heif", + "dest": "cargo/vendor-git/ded75ace3b48131a7498b2ad3ce7884b178155a1ef794dda2327c20c2979a816/craft-heif", "dest-filename": ".cargo-checksum.json" }, { @@ -10209,7 +10215,7 @@ }, { "type": "inline", - "contents": "[source.vendored-sources]\ndirectory = \"cargo/vendor\"\n\n[source.crates-io]\nreplace-with = \"vendored-sources\"\n\n[source.\"https://github.com/storytold/craft-libs?rev=7f30d664695cd5ce14fc30659d36c3e32f234247\"]\ngit = \"https://github.com/storytold/craft-libs\"\nreplace-with = \"git-vendor-7afa30ca311804d863bbc144ec2c79a3a321ce72c30264402ae2c6af8a05da44\"\nrev = \"7f30d664695cd5ce14fc30659d36c3e32f234247\"\n\n[source.git-vendor-7afa30ca311804d863bbc144ec2c79a3a321ce72c30264402ae2c6af8a05da44]\ndirectory = \"cargo/vendor-git/7afa30ca311804d863bbc144ec2c79a3a321ce72c30264402ae2c6af8a05da44\"\n\n[source.\"https://github.com/storytold/craft-libs?rev=f0f4758c01581d79577b9bf5046c06f4e77b1f18\"]\ngit = \"https://github.com/storytold/craft-libs\"\nreplace-with = \"git-vendor-bc00bd22a20692df38f25839a8568cd55b90e379a41719721bbc0f04fe5e29f7\"\nrev = \"f0f4758c01581d79577b9bf5046c06f4e77b1f18\"\n\n[source.git-vendor-bc00bd22a20692df38f25839a8568cd55b90e379a41719721bbc0f04fe5e29f7]\ndirectory = \"cargo/vendor-git/bc00bd22a20692df38f25839a8568cd55b90e379a41719721bbc0f04fe5e29f7\"\n\n[source.\"https://github.com/storytold/craft-libs?rev=c28356d400aed7575b04ec1551b4665107cfe845\"]\ngit = \"https://github.com/storytold/craft-libs\"\nreplace-with = \"git-vendor-547b31fae2076d587e497f8a6226e18e0bfe27e9014d2bdf3cce7d69262df801\"\nrev = \"c28356d400aed7575b04ec1551b4665107cfe845\"\n\n[source.git-vendor-547b31fae2076d587e497f8a6226e18e0bfe27e9014d2bdf3cce7d69262df801]\ndirectory = \"cargo/vendor-git/547b31fae2076d587e497f8a6226e18e0bfe27e9014d2bdf3cce7d69262df801\"\n\n[source.\"https://github.com/storytold/craft-libs?rev=c5a1cbfb5f9049f9270955caffb5bee5997aebf7\"]\ngit = \"https://github.com/storytold/craft-libs\"\nreplace-with = \"git-vendor-11a22760e699d74db2deeccbdb390b343ad010ce425dcb15451f0e14e45ff298\"\nrev = \"c5a1cbfb5f9049f9270955caffb5bee5997aebf7\"\n\n[source.git-vendor-11a22760e699d74db2deeccbdb390b343ad010ce425dcb15451f0e14e45ff298]\ndirectory = \"cargo/vendor-git/11a22760e699d74db2deeccbdb390b343ad010ce425dcb15451f0e14e45ff298\"\n\n[source.\"https://github.com/storytold/craft-libs?rev=9dcbd90c7d16e1a668b3afa057e940e2db328b93\"]\ngit = \"https://github.com/storytold/craft-libs\"\nreplace-with = \"git-vendor-36bf00be069421f8a8a7428c4360efee8b4243207a59d7b566c6f48fc5918f61\"\nrev = \"9dcbd90c7d16e1a668b3afa057e940e2db328b93\"\n\n[source.git-vendor-36bf00be069421f8a8a7428c4360efee8b4243207a59d7b566c6f48fc5918f61]\ndirectory = \"cargo/vendor-git/36bf00be069421f8a8a7428c4360efee8b4243207a59d7b566c6f48fc5918f61\"\n\n[source.\"https://github.com/storytold/craft-libs?rev=b77af389f30bb10de10d8436ca9b39fe94e3bb67\"]\ngit = \"https://github.com/storytold/craft-libs\"\nreplace-with = \"git-vendor-a51e2c3f46af71f1caed91009f88b4f9982db0c4152c6659d11967a7731b1ccc\"\nrev = \"b77af389f30bb10de10d8436ca9b39fe94e3bb67\"\n\n[source.git-vendor-a51e2c3f46af71f1caed91009f88b4f9982db0c4152c6659d11967a7731b1ccc]\ndirectory = \"cargo/vendor-git/a51e2c3f46af71f1caed91009f88b4f9982db0c4152c6659d11967a7731b1ccc\"\n\n[source.\"https://github.com/storytold/craft-libs?rev=5ac7c9664c8d54aaf69d1bb826e187686c1a4e1a\"]\ngit = \"https://github.com/storytold/craft-libs\"\nreplace-with = \"git-vendor-9100d311acc530b0286234c55b78dbdc0325d5e30950478c5c7864bfed7a4545\"\nrev = \"5ac7c9664c8d54aaf69d1bb826e187686c1a4e1a\"\n\n[source.git-vendor-9100d311acc530b0286234c55b78dbdc0325d5e30950478c5c7864bfed7a4545]\ndirectory = \"cargo/vendor-git/9100d311acc530b0286234c55b78dbdc0325d5e30950478c5c7864bfed7a4545\"\n\n[source.\"https://github.com/storytold/craft-libs?rev=478c50560d3c6fad3d613af2a30b35c3bc9f4c0f\"]\ngit = \"https://github.com/storytold/craft-libs\"\nreplace-with = \"git-vendor-cb31475a7a9d19c00f48b4c43603f2f1a464c6dce15da1d21bba4c653eeba6b2\"\nrev = \"478c50560d3c6fad3d613af2a30b35c3bc9f4c0f\"\n\n[source.git-vendor-cb31475a7a9d19c00f48b4c43603f2f1a464c6dce15da1d21bba4c653eeba6b2]\ndirectory = \"cargo/vendor-git/cb31475a7a9d19c00f48b4c43603f2f1a464c6dce15da1d21bba4c653eeba6b2\"\n\n[source.\"https://github.com/storytold/craft-libs?rev=5c91598ccc86537a779f438d520fa6406c26efe6\"]\ngit = \"https://github.com/storytold/craft-libs\"\nreplace-with = \"git-vendor-6f5ad8618176b3fc0aac703e6e74df7229b0350b4574c7edbe0bb86c53c1cb6c\"\nrev = \"5c91598ccc86537a779f438d520fa6406c26efe6\"\n\n[source.git-vendor-6f5ad8618176b3fc0aac703e6e74df7229b0350b4574c7edbe0bb86c53c1cb6c]\ndirectory = \"cargo/vendor-git/6f5ad8618176b3fc0aac703e6e74df7229b0350b4574c7edbe0bb86c53c1cb6c\"\n\n[source.\"https://github.com/storytold/craft-libs?rev=0fd30aeb3e02207d9d4c7c601540d9da45abf8de\"]\ngit = \"https://github.com/storytold/craft-libs\"\nreplace-with = \"git-vendor-fafb086755da4e9bf32b4ac1b53a42a6017167d56ec0071462788465fa35eb30\"\nrev = \"0fd30aeb3e02207d9d4c7c601540d9da45abf8de\"\n\n[source.git-vendor-fafb086755da4e9bf32b4ac1b53a42a6017167d56ec0071462788465fa35eb30]\ndirectory = \"cargo/vendor-git/fafb086755da4e9bf32b4ac1b53a42a6017167d56ec0071462788465fa35eb30\"\n\n[source.\"https://github.com/storytold/craft-libs?rev=bea6ed1ff031b81df2d64be470485c1ca808847e\"]\ngit = \"https://github.com/storytold/craft-libs\"\nreplace-with = \"git-vendor-32c3b4109a3afdabed8bce488e027fa99fcc1b06e4fbe9ee85802b6b73337040\"\nrev = \"bea6ed1ff031b81df2d64be470485c1ca808847e\"\n\n[source.git-vendor-32c3b4109a3afdabed8bce488e027fa99fcc1b06e4fbe9ee85802b6b73337040]\ndirectory = \"cargo/vendor-git/32c3b4109a3afdabed8bce488e027fa99fcc1b06e4fbe9ee85802b6b73337040\"\n\n[source.\"https://github.com/storytold/craft-libs?rev=16d838105b07965832bb43132880176f299634d5\"]\ngit = \"https://github.com/storytold/craft-libs\"\nreplace-with = \"git-vendor-879b5ad1e55c0c2de1d740528f2a8f8e2ffec953302517957e516331e9525f03\"\nrev = \"16d838105b07965832bb43132880176f299634d5\"\n\n[source.git-vendor-879b5ad1e55c0c2de1d740528f2a8f8e2ffec953302517957e516331e9525f03]\ndirectory = \"cargo/vendor-git/879b5ad1e55c0c2de1d740528f2a8f8e2ffec953302517957e516331e9525f03\"\n\n[source.\"https://github.com/storytold/craft-libs?rev=6e03f65bf45181db77ba6229716e6624db9eb25b\"]\ngit = \"https://github.com/storytold/craft-libs\"\nreplace-with = \"git-vendor-4765c8f813a43ec0005270c9f4b16bff2eb2e09aeb15e4230bcd10e5bba1c4ba\"\nrev = \"6e03f65bf45181db77ba6229716e6624db9eb25b\"\n\n[source.git-vendor-4765c8f813a43ec0005270c9f4b16bff2eb2e09aeb15e4230bcd10e5bba1c4ba]\ndirectory = \"cargo/vendor-git/4765c8f813a43ec0005270c9f4b16bff2eb2e09aeb15e4230bcd10e5bba1c4ba\"\n\n[source.\"https://github.com/storytold/egui.git?rev=6d518fc799681571963842f95b55a6b68431b15a\"]\ngit = \"https://github.com/storytold/egui\"\nreplace-with = \"git-vendor-11e349eb0774eb3ab9192b38c47d748bf18abba91a0e3952d8f196513da96ee6\"\nrev = \"6d518fc799681571963842f95b55a6b68431b15a\"\n\n[source.git-vendor-11e349eb0774eb3ab9192b38c47d748bf18abba91a0e3952d8f196513da96ee6]\ndirectory = \"cargo/vendor-git/11e349eb0774eb3ab9192b38c47d748bf18abba91a0e3952d8f196513da96ee6\"\n\n[source.\"https://github.com/storytold/winit.git?rev=a517b3846ee8457d84ee4975110bfda6797c44dc\"]\ngit = \"https://github.com/storytold/winit\"\nreplace-with = \"git-vendor-9c7f809a50c4212d761a5b6359c5e4a02fcf86376d330a441c4ce9d112706ee9\"\nrev = \"a517b3846ee8457d84ee4975110bfda6797c44dc\"\n\n[source.git-vendor-9c7f809a50c4212d761a5b6359c5e4a02fcf86376d330a441c4ce9d112706ee9]\ndirectory = \"cargo/vendor-git/9c7f809a50c4212d761a5b6359c5e4a02fcf86376d330a441c4ce9d112706ee9\"\n", + "contents": "[source.vendored-sources]\ndirectory = \"cargo/vendor\"\n\n[source.crates-io]\nreplace-with = \"vendored-sources\"\n\n[source.\"https://github.com/storytold/craft-libs?rev=7f30d664695cd5ce14fc30659d36c3e32f234247\"]\ngit = \"https://github.com/storytold/craft-libs\"\nreplace-with = \"git-vendor-7afa30ca311804d863bbc144ec2c79a3a321ce72c30264402ae2c6af8a05da44\"\nrev = \"7f30d664695cd5ce14fc30659d36c3e32f234247\"\n\n[source.git-vendor-7afa30ca311804d863bbc144ec2c79a3a321ce72c30264402ae2c6af8a05da44]\ndirectory = \"cargo/vendor-git/7afa30ca311804d863bbc144ec2c79a3a321ce72c30264402ae2c6af8a05da44\"\n\n[source.\"https://github.com/storytold/craft-libs?rev=f0f4758c01581d79577b9bf5046c06f4e77b1f18\"]\ngit = \"https://github.com/storytold/craft-libs\"\nreplace-with = \"git-vendor-bc00bd22a20692df38f25839a8568cd55b90e379a41719721bbc0f04fe5e29f7\"\nrev = \"f0f4758c01581d79577b9bf5046c06f4e77b1f18\"\n\n[source.git-vendor-bc00bd22a20692df38f25839a8568cd55b90e379a41719721bbc0f04fe5e29f7]\ndirectory = \"cargo/vendor-git/bc00bd22a20692df38f25839a8568cd55b90e379a41719721bbc0f04fe5e29f7\"\n\n[source.\"https://github.com/storytold/craft-libs?rev=c28356d400aed7575b04ec1551b4665107cfe845\"]\ngit = \"https://github.com/storytold/craft-libs\"\nreplace-with = \"git-vendor-547b31fae2076d587e497f8a6226e18e0bfe27e9014d2bdf3cce7d69262df801\"\nrev = \"c28356d400aed7575b04ec1551b4665107cfe845\"\n\n[source.git-vendor-547b31fae2076d587e497f8a6226e18e0bfe27e9014d2bdf3cce7d69262df801]\ndirectory = \"cargo/vendor-git/547b31fae2076d587e497f8a6226e18e0bfe27e9014d2bdf3cce7d69262df801\"\n\n[source.\"https://github.com/storytold/craft-libs?rev=c5a1cbfb5f9049f9270955caffb5bee5997aebf7\"]\ngit = \"https://github.com/storytold/craft-libs\"\nreplace-with = \"git-vendor-11a22760e699d74db2deeccbdb390b343ad010ce425dcb15451f0e14e45ff298\"\nrev = \"c5a1cbfb5f9049f9270955caffb5bee5997aebf7\"\n\n[source.git-vendor-11a22760e699d74db2deeccbdb390b343ad010ce425dcb15451f0e14e45ff298]\ndirectory = \"cargo/vendor-git/11a22760e699d74db2deeccbdb390b343ad010ce425dcb15451f0e14e45ff298\"\n\n[source.\"https://github.com/storytold/craft-libs?rev=9dcbd90c7d16e1a668b3afa057e940e2db328b93\"]\ngit = \"https://github.com/storytold/craft-libs\"\nreplace-with = \"git-vendor-36bf00be069421f8a8a7428c4360efee8b4243207a59d7b566c6f48fc5918f61\"\nrev = \"9dcbd90c7d16e1a668b3afa057e940e2db328b93\"\n\n[source.git-vendor-36bf00be069421f8a8a7428c4360efee8b4243207a59d7b566c6f48fc5918f61]\ndirectory = \"cargo/vendor-git/36bf00be069421f8a8a7428c4360efee8b4243207a59d7b566c6f48fc5918f61\"\n\n[source.\"https://github.com/storytold/craft-libs?rev=b77af389f30bb10de10d8436ca9b39fe94e3bb67\"]\ngit = \"https://github.com/storytold/craft-libs\"\nreplace-with = \"git-vendor-a51e2c3f46af71f1caed91009f88b4f9982db0c4152c6659d11967a7731b1ccc\"\nrev = \"b77af389f30bb10de10d8436ca9b39fe94e3bb67\"\n\n[source.git-vendor-a51e2c3f46af71f1caed91009f88b4f9982db0c4152c6659d11967a7731b1ccc]\ndirectory = \"cargo/vendor-git/a51e2c3f46af71f1caed91009f88b4f9982db0c4152c6659d11967a7731b1ccc\"\n\n[source.\"https://github.com/storytold/craft-libs?rev=4ffa307f1a0a6fbd8897318cc719440ab06e9c63\"]\ngit = \"https://github.com/storytold/craft-libs\"\nreplace-with = \"git-vendor-ded75ace3b48131a7498b2ad3ce7884b178155a1ef794dda2327c20c2979a816\"\nrev = \"4ffa307f1a0a6fbd8897318cc719440ab06e9c63\"\n\n[source.git-vendor-ded75ace3b48131a7498b2ad3ce7884b178155a1ef794dda2327c20c2979a816]\ndirectory = \"cargo/vendor-git/ded75ace3b48131a7498b2ad3ce7884b178155a1ef794dda2327c20c2979a816\"\n\n[source.\"https://github.com/storytold/craft-libs?rev=5ac7c9664c8d54aaf69d1bb826e187686c1a4e1a\"]\ngit = \"https://github.com/storytold/craft-libs\"\nreplace-with = \"git-vendor-9100d311acc530b0286234c55b78dbdc0325d5e30950478c5c7864bfed7a4545\"\nrev = \"5ac7c9664c8d54aaf69d1bb826e187686c1a4e1a\"\n\n[source.git-vendor-9100d311acc530b0286234c55b78dbdc0325d5e30950478c5c7864bfed7a4545]\ndirectory = \"cargo/vendor-git/9100d311acc530b0286234c55b78dbdc0325d5e30950478c5c7864bfed7a4545\"\n\n[source.\"https://github.com/storytold/craft-libs?rev=478c50560d3c6fad3d613af2a30b35c3bc9f4c0f\"]\ngit = \"https://github.com/storytold/craft-libs\"\nreplace-with = \"git-vendor-cb31475a7a9d19c00f48b4c43603f2f1a464c6dce15da1d21bba4c653eeba6b2\"\nrev = \"478c50560d3c6fad3d613af2a30b35c3bc9f4c0f\"\n\n[source.git-vendor-cb31475a7a9d19c00f48b4c43603f2f1a464c6dce15da1d21bba4c653eeba6b2]\ndirectory = \"cargo/vendor-git/cb31475a7a9d19c00f48b4c43603f2f1a464c6dce15da1d21bba4c653eeba6b2\"\n\n[source.\"https://github.com/storytold/craft-libs?rev=5c91598ccc86537a779f438d520fa6406c26efe6\"]\ngit = \"https://github.com/storytold/craft-libs\"\nreplace-with = \"git-vendor-6f5ad8618176b3fc0aac703e6e74df7229b0350b4574c7edbe0bb86c53c1cb6c\"\nrev = \"5c91598ccc86537a779f438d520fa6406c26efe6\"\n\n[source.git-vendor-6f5ad8618176b3fc0aac703e6e74df7229b0350b4574c7edbe0bb86c53c1cb6c]\ndirectory = \"cargo/vendor-git/6f5ad8618176b3fc0aac703e6e74df7229b0350b4574c7edbe0bb86c53c1cb6c\"\n\n[source.\"https://github.com/storytold/craft-libs?rev=0fd30aeb3e02207d9d4c7c601540d9da45abf8de\"]\ngit = \"https://github.com/storytold/craft-libs\"\nreplace-with = \"git-vendor-fafb086755da4e9bf32b4ac1b53a42a6017167d56ec0071462788465fa35eb30\"\nrev = \"0fd30aeb3e02207d9d4c7c601540d9da45abf8de\"\n\n[source.git-vendor-fafb086755da4e9bf32b4ac1b53a42a6017167d56ec0071462788465fa35eb30]\ndirectory = \"cargo/vendor-git/fafb086755da4e9bf32b4ac1b53a42a6017167d56ec0071462788465fa35eb30\"\n\n[source.\"https://github.com/storytold/craft-libs?rev=bea6ed1ff031b81df2d64be470485c1ca808847e\"]\ngit = \"https://github.com/storytold/craft-libs\"\nreplace-with = \"git-vendor-32c3b4109a3afdabed8bce488e027fa99fcc1b06e4fbe9ee85802b6b73337040\"\nrev = \"bea6ed1ff031b81df2d64be470485c1ca808847e\"\n\n[source.git-vendor-32c3b4109a3afdabed8bce488e027fa99fcc1b06e4fbe9ee85802b6b73337040]\ndirectory = \"cargo/vendor-git/32c3b4109a3afdabed8bce488e027fa99fcc1b06e4fbe9ee85802b6b73337040\"\n\n[source.\"https://github.com/storytold/craft-libs?rev=16d838105b07965832bb43132880176f299634d5\"]\ngit = \"https://github.com/storytold/craft-libs\"\nreplace-with = \"git-vendor-879b5ad1e55c0c2de1d740528f2a8f8e2ffec953302517957e516331e9525f03\"\nrev = \"16d838105b07965832bb43132880176f299634d5\"\n\n[source.git-vendor-879b5ad1e55c0c2de1d740528f2a8f8e2ffec953302517957e516331e9525f03]\ndirectory = \"cargo/vendor-git/879b5ad1e55c0c2de1d740528f2a8f8e2ffec953302517957e516331e9525f03\"\n\n[source.\"https://github.com/storytold/craft-libs?rev=6e03f65bf45181db77ba6229716e6624db9eb25b\"]\ngit = \"https://github.com/storytold/craft-libs\"\nreplace-with = \"git-vendor-4765c8f813a43ec0005270c9f4b16bff2eb2e09aeb15e4230bcd10e5bba1c4ba\"\nrev = \"6e03f65bf45181db77ba6229716e6624db9eb25b\"\n\n[source.git-vendor-4765c8f813a43ec0005270c9f4b16bff2eb2e09aeb15e4230bcd10e5bba1c4ba]\ndirectory = \"cargo/vendor-git/4765c8f813a43ec0005270c9f4b16bff2eb2e09aeb15e4230bcd10e5bba1c4ba\"\n\n[source.\"https://github.com/storytold/egui.git?rev=6d518fc799681571963842f95b55a6b68431b15a\"]\ngit = \"https://github.com/storytold/egui\"\nreplace-with = \"git-vendor-11e349eb0774eb3ab9192b38c47d748bf18abba91a0e3952d8f196513da96ee6\"\nrev = \"6d518fc799681571963842f95b55a6b68431b15a\"\n\n[source.git-vendor-11e349eb0774eb3ab9192b38c47d748bf18abba91a0e3952d8f196513da96ee6]\ndirectory = \"cargo/vendor-git/11e349eb0774eb3ab9192b38c47d748bf18abba91a0e3952d8f196513da96ee6\"\n\n[source.\"https://github.com/storytold/winit.git?rev=a517b3846ee8457d84ee4975110bfda6797c44dc\"]\ngit = \"https://github.com/storytold/winit\"\nreplace-with = \"git-vendor-9c7f809a50c4212d761a5b6359c5e4a02fcf86376d330a441c4ce9d112706ee9\"\nrev = \"a517b3846ee8457d84ee4975110bfda6797c44dc\"\n\n[source.git-vendor-9c7f809a50c4212d761a5b6359c5e4a02fcf86376d330a441c4ce9d112706ee9]\ndirectory = \"cargo/vendor-git/9c7f809a50c4212d761a5b6359c5e4a02fcf86376d330a441c4ce9d112706ee9\"\n", "dest": "cargo", "dest-filename": "config" } From 7bb9165c6bc46652db41ef5e19054a2bb017435f Mon Sep 17 00:00:00 2001 From: "Dylan M. Taylor" <dylan@dylanmtaylor.com> Date: Mon, 16 Nov 2026 21:58:44 -0500 Subject: [PATCH 61/61] Delegate TIFF RAW classification to shared codecs (#4311) --- crates/codecs/src/exif.rs | 1 + crates/codecs/src/sniff.rs | 26 +++++++++++++++++++++++++- 2 files changed, 26 insertions(+), 1 deletion(-) diff --git a/crates/codecs/src/exif.rs b/crates/codecs/src/exif.rs index b3e45fef68..79f4d52753 100644 --- a/crates/codecs/src/exif.rs +++ b/crates/codecs/src/exif.rs @@ -57,6 +57,7 @@ impl<'a> Tiff<'a> { Some((v, next)) } /// First value of a SHORT/LONG entry. + #[cfg(test)] pub fn uint(&self, e: &Entry) -> Option<u32> { match e.typ { 3 => self.u16_at(e.value_pos).map(u32::from), diff --git a/crates/codecs/src/sniff.rs b/crates/codecs/src/sniff.rs index 5bc5c40278..181f271038 100644 --- a/crates/codecs/src/sniff.rs +++ b/crates/codecs/src/sniff.rs @@ -1,5 +1,6 @@ //! Format detection from leading bytes. +#[cfg(test)] use crate::exif::Tiff; use serde::{Deserialize, Serialize}; @@ -125,7 +126,7 @@ pub fn sniff(b: &[u8]) -> Option<Format> { return Some(Format::RawTiffLike); } if b.starts_with(b"II*\0") || b.starts_with(b"MM\0*") { - return Some(if tiff_is_raw(b) { Format::RawTiffLike } else { Format::Tiff }); + return Some(if craft_image_codecs::legacy_tiff_raw_hint(b) { Format::RawTiffLike } else { Format::Tiff }); } if b.starts_with(b"II+\0") || b.starts_with(b"MM\0+") { return Some(Format::Tiff); @@ -167,6 +168,7 @@ fn sniff_bmff(b: &[u8]) -> Option<Format> { /// Heuristic camera-raw detection for classic TIFF: DNGVersion, the CR2 signature, CFA/LinearRaw /// photometric or raw-only compressions in IFD0 or its SubIFDs, or a camera Make with 10–16-bit data /// and no ordinary photometric. +#[cfg(test)] fn tiff_is_raw(b: &[u8]) -> bool { if b.len() >= 10 && &b[8..10] == b"CR" { return true; @@ -221,6 +223,28 @@ fn tiff_is_raw(b: &[u8]) -> bool { mod tests { use super::*; + #[test] + fn raw_tiff_classifier_matches_legacy_on_mutations() { + let fixtures: &[&[u8]] = &[ + b"II*\0\x08\0\0\0\x01\0\x12\xc6\x01\0\x04\0\0\0\x01\x04\0\0\0\0\0\0", + b"II*\0\x08\0\0\0\x01\0\x03\x01\x03\0\x01\0\0\0\x09\x80\0\0\0\0\0\0", + b"II*\0\x10\0\0\0CR\x02\0", + ]; + for fixture in fixtures { + for end in 0..=fixture.len() { + let bytes = &fixture[..end]; + assert_eq!(craft_image_codecs::legacy_tiff_raw_hint(bytes), tiff_is_raw(bytes), "truncation {end}"); + for i in 0..bytes.len() { + for value in [0, 255] { + let mut changed = bytes.to_vec(); + changed[i] = value; + assert_eq!(craft_image_codecs::legacy_tiff_raw_hint(&changed), tiff_is_raw(&changed), "byte {i} value {value} length {end}"); + } + } + } + } + } + #[test] fn magic_numbers() { assert_eq!(sniff(b"\xFF\xD8\xFF\xE0\0\x10JFIF"), Some(Format::Jpeg));