diff --git a/Cargo.lock b/Cargo.lock index eece1108db..8d379e69f8 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -1279,13 +1279,15 @@ dependencies = [ "futures", "glam", "graphene-hash", + "half", "image", "kurbo", "log", "lyon_geom", - "no-std-types", "node-macro", + "num-derive", "num-traits", + "num_enum", "parley", "petgraph", "polycool", @@ -2540,7 +2542,6 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "37bfe73dc8ec21f54d181e5a60554327ec3f1c600c455a75ccbfc65d2106a6c4" dependencies = [ "bytemuck", - "libm", "serde_core", ] @@ -4635,25 +4636,6 @@ dependencies = [ "libc", ] -[[package]] -name = "no-std-types" -version = "0.0.0" -dependencies = [ - "bytemuck", - "core-types", - "dyn-any", - "glam", - "graphene-hash", - "half", - "log", - "num-derive", - "num-traits", - "num_enum", - "serde", - "tsify", - "wasm-bindgen", -] - [[package]] name = "node-docs" version = "0.0.0" @@ -4673,7 +4655,6 @@ dependencies = [ "convert_case 0.12.0", "core-types", "indoc", - "no-std-types", "proc-macro-crate", "proc-macro-error2", "proc-macro2", @@ -5824,7 +5805,6 @@ dependencies = [ "graphene-resource", "image", "ndarray", - "no-std-types", "node-macro", "num_enum", "rand", diff --git a/Cargo.toml b/Cargo.toml index 854fbcd595..2d7e8f5430 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -89,7 +89,6 @@ graphene-application-io = { path = "node-graph/libraries/application-io" } graphene-resource = { path = "node-graph/libraries/resources" } graphene-animation = { path = "node-graph/libraries/animation" } core-types = { path = "node-graph/libraries/core-types" } -no-std-types = { path = "node-graph/libraries/no-std-types" } raster-types = { path = "node-graph/libraries/raster-types" } vector-types = { path = "node-graph/libraries/vector-types" } graphic-types = { path = "node-graph/libraries/graphic-types" } @@ -210,7 +209,7 @@ color = "0.3" rand = { version = "0.9", default-features = false, features = ["std_rng"] } rand_chacha = "0.9" glam = { version = "0.33", default-features = false, features = [ - "nostd-libm", + "std", "scalar-math", "bytemuck", "debug-glam-assert", @@ -236,7 +235,7 @@ pretty_assertions = "1.4" fern = { version = "0.7", features = ["colored"] } num_enum = { version = "0.7", default-features = false } num-derive = "0.4" -num-traits = { version = "0.2", default-features = false, features = ["libm"] } +num-traits = "0.2" tsify = { version = "0.5", default-features = false, features = ["js"] } syn = { version = "2.0", default-features = false, features = [ "full", @@ -282,7 +281,6 @@ zip = { version = "8", default-features = false } opt-level = 1 [profile.dev.package] -no-std-types = { opt-level = 1 } core-types= { opt-level = 1 } interpreted-executor = { opt-level = 1 } # This is a mitigation for https://github.com/rustwasm/wasm-pack/issues/981 which is needed because the node_registry function is too large graphite-proc-macros = { opt-level = 1 } diff --git a/node-graph/libraries/core-types/Cargo.toml b/node-graph/libraries/core-types/Cargo.toml index 11ab3340b4..0697f399c4 100644 --- a/node-graph/libraries/core-types/Cargo.toml +++ b/node-graph/libraries/core-types/Cargo.toml @@ -16,15 +16,13 @@ workspace = true [features] default = ["serde"] -serde = ["dep:serde"] -nightly = [] +serde = ["dep:serde", "glam/serde", "half/serde"] type_id_logging = [] dealloc_nodes = [] -wasm = ["tsify", "wasm-bindgen", "no-std-types/wasm"] +wasm = ["tsify", "wasm-bindgen"] [dependencies] # Local dependencies -no-std-types = { workspace = true } graphene-hash = { workspace = true, features = ["derive"] } # Workspace dependencies @@ -33,6 +31,9 @@ bitflags = { workspace = true } bytemuck = { workspace = true } node-macro = { workspace = true } num-traits = { workspace = true } +num-derive = { workspace = true } +num_enum = { workspace = true, features = ["std"] } +half = { workspace = true, features = ["std"] } rand = { workspace = true } glam = { workspace = true } serde_json = { workspace = true } diff --git a/node-graph/libraries/no-std-types/src/blending.rs b/node-graph/libraries/core-types/src/blending.rs similarity index 98% rename from node-graph/libraries/no-std-types/src/blending.rs rename to node-graph/libraries/core-types/src/blending.rs index 085c5746b9..1a77ed3264 100644 --- a/node-graph/libraries/no-std-types/src/blending.rs +++ b/node-graph/libraries/core-types/src/blending.rs @@ -4,7 +4,8 @@ use num_enum::{FromPrimitive, IntoPrimitive}; #[repr(i32)] #[cfg_attr(feature = "wasm", derive(tsify::Tsify))] -#[derive(Debug, Default, Clone, Copy, Eq, PartialEq, Hash, dyn_any::DynAny, serde::Serialize, serde::Deserialize, graphene_hash::CacheHash, FromPrimitive, IntoPrimitive)] +#[derive(dyn_any::DynAny, graphene_hash::CacheHash, Debug, Default, Clone, Copy, Eq, PartialEq, Hash, FromPrimitive, IntoPrimitive)] +#[cfg_attr(feature = "serde", derive(serde::Serialize, serde::Deserialize))] pub enum BlendMode { // Basic group #[default] diff --git a/node-graph/libraries/no-std-types/src/choice_type.rs b/node-graph/libraries/core-types/src/choice_type.rs similarity index 100% rename from node-graph/libraries/no-std-types/src/choice_type.rs rename to node-graph/libraries/core-types/src/choice_type.rs diff --git a/node-graph/libraries/no-std-types/src/color/color_traits.rs b/node-graph/libraries/core-types/src/color/color_traits.rs similarity index 100% rename from node-graph/libraries/no-std-types/src/color/color_traits.rs rename to node-graph/libraries/core-types/src/color/color_traits.rs diff --git a/node-graph/libraries/no-std-types/src/color/color_types.rs b/node-graph/libraries/core-types/src/color/color_types.rs similarity index 98% rename from node-graph/libraries/no-std-types/src/color/color_types.rs rename to node-graph/libraries/core-types/src/color/color_types.rs index 44ef7b4946..a01f6e1f75 100644 --- a/node-graph/libraries/no-std-types/src/color/color_types.rs +++ b/node-graph/libraries/core-types/src/color/color_types.rs @@ -7,7 +7,8 @@ use glam::Vec4; use half::f16; #[repr(C)] -#[derive(Default, Clone, Copy, PartialEq, Pod, Zeroable, Debug, dyn_any::DynAny, serde::Serialize, serde::Deserialize)] +#[derive(Default, Clone, Copy, PartialEq, Pod, Zeroable, Debug, dyn_any::DynAny)] +#[cfg_attr(feature = "serde", derive(serde::Serialize, serde::Deserialize))] pub struct RGBA16F { red: f16, green: f16, @@ -81,7 +82,8 @@ impl Pixel for RGBA16F {} /// the linear-light [`Color`] type. Convert via [`From for Color`] and [`From for SRGBA8`]. #[repr(C)] #[cfg_attr(feature = "wasm", derive(tsify::Tsify), tsify(from_wasm_abi))] -#[derive(Debug, Default, Clone, Copy, PartialEq, Eq, Hash, Pod, Zeroable, dyn_any::DynAny, serde::Serialize, serde::Deserialize, graphene_hash::CacheHash)] +#[derive(dyn_any::DynAny, graphene_hash::CacheHash, Debug, Default, Clone, Copy, PartialEq, Eq, Hash, Pod, Zeroable)] +#[cfg_attr(feature = "serde", derive(serde::Serialize, serde::Deserialize))] pub struct SRGBA8 { pub red: u8, pub green: u8, @@ -202,7 +204,8 @@ impl From for Color { #[repr(C)] #[cfg_attr(feature = "wasm", derive(tsify::Tsify))] -#[derive(Debug, Default, Clone, Copy, PartialEq, Pod, Zeroable, dyn_any::DynAny, serde::Serialize, serde::Deserialize)] +#[derive(dyn_any::DynAny, Debug, Default, Clone, Copy, PartialEq, Pod, Zeroable)] +#[cfg_attr(feature = "serde", derive(serde::Serialize, serde::Deserialize))] pub struct Luma(pub f32); impl Luminance for Luma { @@ -249,6 +252,7 @@ pub struct Color { impl Eq for Color {} // TODO: Eventually remove this document upgrade code +#[cfg(feature = "serde")] impl serde::Serialize for Color { fn serialize(&self, serializer: S) -> Result { use serde::ser::SerializeStruct; @@ -265,6 +269,7 @@ impl serde::Serialize for Color { } // TODO: Eventually remove this document upgrade code +#[cfg(feature = "serde")] impl<'de> serde::Deserialize<'de> for Color { fn deserialize>(deserializer: D) -> Result { // Documents from before the linear-storage migration lack the `linear` marker and stored gamma-encoded floats; convert them on load. diff --git a/node-graph/libraries/no-std-types/src/color/component_blend.rs b/node-graph/libraries/core-types/src/color/component_blend.rs similarity index 100% rename from node-graph/libraries/no-std-types/src/color/component_blend.rs rename to node-graph/libraries/core-types/src/color/component_blend.rs diff --git a/node-graph/libraries/no-std-types/src/color/discrete_srgb.rs b/node-graph/libraries/core-types/src/color/discrete_srgb.rs similarity index 100% rename from node-graph/libraries/no-std-types/src/color/discrete_srgb.rs rename to node-graph/libraries/core-types/src/color/discrete_srgb.rs diff --git a/node-graph/libraries/no-std-types/src/color/mod.rs b/node-graph/libraries/core-types/src/color/mod.rs similarity index 100% rename from node-graph/libraries/no-std-types/src/color/mod.rs rename to node-graph/libraries/core-types/src/color/mod.rs diff --git a/node-graph/libraries/no-std-types/src/color/transfer.rs b/node-graph/libraries/core-types/src/color/transfer.rs similarity index 100% rename from node-graph/libraries/no-std-types/src/color/transfer.rs rename to node-graph/libraries/core-types/src/color/transfer.rs diff --git a/node-graph/libraries/core-types/src/context.rs b/node-graph/libraries/core-types/src/context.rs index 8eccf1a8bd..21ad0be80f 100644 --- a/node-graph/libraries/core-types/src/context.rs +++ b/node-graph/libraries/core-types/src/context.rs @@ -1,7 +1,6 @@ use crate::runtime::{Generations, SourceId}; use crate::transform::Footprint; use glam::DVec2; -pub use no_std_types::context::{ArcCtx, Ctx}; use std::any::Any; use std::borrow::Borrow; use std::collections::BTreeSet; @@ -9,6 +8,15 @@ use std::hash::{Hash, Hasher}; use std::panic::Location; use std::sync::Arc; +pub trait Ctx: Clone + Send {} + +impl Ctx for Option {} +impl Ctx for &T {} +impl Ctx for () {} + +pub trait ArcCtx: Send + Sync {} +impl Ctx for Arc {} + // ============== // EXTRACT TRAITS // ============== diff --git a/node-graph/libraries/core-types/src/lib.rs b/node-graph/libraries/core-types/src/lib.rs index bee055494c..e8531118d6 100644 --- a/node-graph/libraries/core-types/src/lib.rs +++ b/node-graph/libraries/core-types/src/lib.rs @@ -1,6 +1,9 @@ extern crate log; +pub mod blending; pub mod bounds; +pub mod choice_type; +pub mod color; pub mod consts; pub mod context; pub mod generic; @@ -34,10 +37,6 @@ pub use list::{ ATTR_LETTER_TILT, ATTR_LINE_HEIGHT, ATTR_LOCATION, ATTR_MAX_HEIGHT, ATTR_MAX_WIDTH, ATTR_NAME, ATTR_OPACITY, ATTR_OPACITY_FILL, ATTR_START, ATTR_TEXT_ALIGN, ATTR_TRANSFORM, ATTR_TYPE, }; pub use memo::MemoHash; -pub use no_std_types::AsU32; -pub use no_std_types::blending; -pub use no_std_types::choice_type; -pub use no_std_types::color; pub use num_traits; pub use poll::{Finality, Interrupt, LazyInput, NodeError, Poll, PollInput, Status}; pub use runtime::{Generations, RuntimeHandle, SourceId}; @@ -165,3 +164,12 @@ impl From

for ParameterRef { } } } + +pub trait AsU32 { + fn as_u32(&self) -> u32; +} +impl AsU32 for u32 { + fn as_u32(&self) -> u32 { + *self + } +} diff --git a/node-graph/libraries/core-types/src/misc.rs b/node-graph/libraries/core-types/src/misc.rs index 7a80158348..4d4a08f3f2 100644 --- a/node-graph/libraries/core-types/src/misc.rs +++ b/node-graph/libraries/core-types/src/misc.rs @@ -90,8 +90,8 @@ struct LegacyTable { } // TODO: Eventually remove this document upgrade code -pub fn migrate_to_color<'de, D: serde::Deserializer<'de>>(deserializer: D) -> Result { - use no_std_types::color::Color; +pub fn migrate_to_color<'de, D: serde::Deserializer<'de>>(deserializer: D) -> Result { + use crate::color::Color; use serde::Deserialize; #[cfg_attr(feature = "serde", derive(serde::Deserialize))] diff --git a/node-graph/libraries/graphene-hash/Cargo.toml b/node-graph/libraries/graphene-hash/Cargo.toml index 36c59e8b8c..ce340fd439 100644 --- a/node-graph/libraries/graphene-hash/Cargo.toml +++ b/node-graph/libraries/graphene-hash/Cargo.toml @@ -15,11 +15,9 @@ publish.workspace = true workspace = true [features] -default = ["std"] -std = ["dep:kurbo"] derive = ["graphene-hash-derive"] [dependencies] graphene-hash-derive = { path = "derive", optional = true } glam = { workspace = true } -kurbo = { workspace = true, optional = true } +kurbo = { workspace = true } diff --git a/node-graph/libraries/graphene-hash/src/lib.rs b/node-graph/libraries/graphene-hash/src/lib.rs index 0e0acc8876..ad63840e4b 100644 --- a/node-graph/libraries/graphene-hash/src/lib.rs +++ b/node-graph/libraries/graphene-hash/src/lib.rs @@ -1,8 +1,3 @@ -#![cfg_attr(not(feature = "std"), no_std)] - -#[cfg(feature = "std")] -extern crate std; - #[cfg(feature = "derive")] pub use graphene_hash_derive::CacheHash; @@ -66,7 +61,6 @@ impl_via_hash! { glam::BVec2, glam::BVec3, glam::BVec4, } -#[cfg(feature = "std")] impl_via_hash! { String, } @@ -154,7 +148,6 @@ impl_glam_array! { } // kurbo path types: hash each element's verb and point coordinates via to_bits(). -#[cfg(feature = "std")] impl CacheHash for kurbo::Point { #[inline] fn cache_hash(&self, state: &mut H) { @@ -163,7 +156,6 @@ impl CacheHash for kurbo::Point { } } -#[cfg(feature = "std")] impl CacheHash for kurbo::PathEl { fn cache_hash(&self, state: &mut H) { core::hash::Hash::hash(&core::mem::discriminant(self), state); @@ -183,7 +175,6 @@ impl CacheHash for kurbo::PathEl { } } -#[cfg(feature = "std")] impl CacheHash for kurbo::BezPath { #[inline] fn cache_hash(&self, state: &mut H) { @@ -224,7 +215,6 @@ impl CacheHash for [T; N] { } } -#[cfg(feature = "std")] impl CacheHash for Vec { #[inline] fn cache_hash(&self, state: &mut H) { @@ -232,7 +222,6 @@ impl CacheHash for Vec { } } -#[cfg(feature = "std")] impl CacheHash for std::collections::BTreeSet { #[inline] fn cache_hash(&self, state: &mut H) { @@ -243,7 +232,6 @@ impl CacheHash for std::collections::BTreeSet { } } -#[cfg(feature = "std")] impl CacheHash for Box { #[inline] fn cache_hash(&self, state: &mut H) { @@ -251,7 +239,6 @@ impl CacheHash for Box { } } -#[cfg(feature = "std")] impl CacheHash for std::sync::Arc { #[inline] fn cache_hash(&self, state: &mut H) { diff --git a/node-graph/libraries/no-std-types/Cargo.toml b/node-graph/libraries/no-std-types/Cargo.toml deleted file mode 100644 index 62a25214f5..0000000000 --- a/node-graph/libraries/no-std-types/Cargo.toml +++ /dev/null @@ -1,40 +0,0 @@ -[package] -name = "no-std-types" -description = "Color, blending, and context types for Graphene" -version.workspace = true -license.workspace = true -authors.workspace = true -edition.workspace = true -repository.workspace = true -readme.workspace = true -homepage.workspace = true -rust-version.workspace = true -publish.workspace = true - -[features] -wasm = ["tsify", "wasm-bindgen"] - -[dependencies] -# Local dependencies -dyn-any = { workspace = true } -graphene-hash = { workspace = true } - -# Workspace dependencies -bytemuck = { workspace = true } -glam = { workspace = true, features = ["debug-glam-assert", "std", "serde"] } -half = { workspace = true, features = ["std", "serde"] } -num-derive = { workspace = true } -num-traits = { workspace = true, features = ["std"] } -num_enum = { workspace = true, features = ["std"] } -serde = { workspace = true } -log = { workspace = true } - -# Workspace wasm dependencies -tsify = { workspace = true, optional = true } -wasm-bindgen = { workspace = true, optional = true } - -[dev-dependencies] -core-types = { workspace = true } - -[package.metadata.cargo-shear] -ignored = ["core-types"] diff --git a/node-graph/libraries/no-std-types/src/context.rs b/node-graph/libraries/no-std-types/src/context.rs deleted file mode 100644 index c31da181c4..0000000000 --- a/node-graph/libraries/no-std-types/src/context.rs +++ /dev/null @@ -1,8 +0,0 @@ -pub trait Ctx: Clone + Send {} - -impl Ctx for Option {} -impl Ctx for &T {} -impl Ctx for () {} - -pub trait ArcCtx: Send + Sync {} -impl Ctx for std::sync::Arc {} diff --git a/node-graph/libraries/no-std-types/src/lib.rs b/node-graph/libraries/no-std-types/src/lib.rs deleted file mode 100644 index 4fd7af22e1..0000000000 --- a/node-graph/libraries/no-std-types/src/lib.rs +++ /dev/null @@ -1,16 +0,0 @@ -pub mod blending; -pub mod choice_type; -pub mod color; -pub mod context; - -pub use context::Ctx; -pub use glam; - -pub trait AsU32 { - fn as_u32(&self) -> u32; -} -impl AsU32 for u32 { - fn as_u32(&self) -> u32 { - *self - } -} diff --git a/node-graph/libraries/raster-types/src/lib.rs b/node-graph/libraries/raster-types/src/lib.rs index c29e9cb847..02413ecf22 100644 --- a/node-graph/libraries/raster-types/src/lib.rs +++ b/node-graph/libraries/raster-types/src/lib.rs @@ -5,7 +5,7 @@ pub mod raster_types; pub use image::{Image, ImageError}; pub use raster_types::*; -// Re-export color types from no-std-types +// Re-export color types from core-types pub use core_types::color::*; /// as to not yet rename all references diff --git a/node-graph/node-macro/Cargo.toml b/node-graph/node-macro/Cargo.toml index 01be4d2781..1b859545a3 100644 --- a/node-graph/node-macro/Cargo.toml +++ b/node-graph/node-macro/Cargo.toml @@ -29,4 +29,3 @@ proc-macro-error2 = "2" [dev-dependencies] core-types = { workspace = true } -no-std-types = { workspace = true } diff --git a/node-graph/node-macro/src/derive_choice_type.rs b/node-graph/node-macro/src/derive_choice_type.rs index 4f4dc2c52b..fa5223d0d6 100644 --- a/node-graph/node-macro/src/derive_choice_type.rs +++ b/node-graph/node-macro/src/derive_choice_type.rs @@ -110,12 +110,8 @@ fn derive_enum(enum_attributes: &[Attribute], name: Ident, input: syn::DataEnum) .collect(); let crate_name = { - let crate_name = proc_macro_crate::crate_name("no-std-types").or_else(|_e| proc_macro_crate::crate_name("core-types")).map_err(|e| { - syn::Error::new( - Span::call_site(), - format!("Failed to find location of 'no-std-types' or 'core-types'. Make sure it is imported as a dependency: {e}"), - ) - })?; + let crate_name = proc_macro_crate::crate_name("core-types") + .map_err(|e| syn::Error::new(Span::call_site(), format!("Failed to find location of 'core-types'. Make sure it is imported as a dependency: {e}")))?; match crate_name { proc_macro_crate::FoundCrate::Itself => quote!(crate), proc_macro_crate::FoundCrate::Name(name) => { diff --git a/node-graph/nodes/raster/Cargo.toml b/node-graph/nodes/raster/Cargo.toml index da09d8ebd3..3f9e6d56d9 100644 --- a/node-graph/nodes/raster/Cargo.toml +++ b/node-graph/nodes/raster/Cargo.toml @@ -27,7 +27,6 @@ wasm = [ [dependencies] # Local dependencies -no-std-types = { workspace = true } node-macro = { workspace = true } dyn-any = { workspace = true } core-types = { workspace = true } diff --git a/node-graph/nodes/raster/src/adjust.rs b/node-graph/nodes/raster/src/adjust.rs index 4105b0f47e..d0625fee9a 100644 --- a/node-graph/nodes/raster/src/adjust.rs +++ b/node-graph/nodes/raster/src/adjust.rs @@ -1,4 +1,4 @@ -use no_std_types::color::Color; +use core_types::color::Color; use raster_types::{CPU, Raster}; use vector_types::Gradient; diff --git a/node-graph/nodes/raster/src/adjustments.rs b/node-graph/nodes/raster/src/adjustments.rs index 72488b4be6..c7e7b6508b 100644 --- a/node-graph/nodes/raster/src/adjustments.rs +++ b/node-graph/nodes/raster/src/adjustments.rs @@ -3,13 +3,14 @@ use crate::adjust::Adjust; use crate::color_lookup_table::{LutCache, LutParseError}; use core::fmt::Debug; +use core_types::color::Color; +use core_types::color::{linear_to_srgb, set_luminosity, srgb_to_linear}; +use core_types::context::Ctx; use core_types::list::{Item, List}; use core_types::transfer_curve::{TransferCurve, TransferCurveEvaluator}; use glam::DVec2; use glam::Vec3; use graphene_resource::Resource; -use no_std_types::color::{Color, linear_to_srgb, set_luminosity, srgb_to_linear}; -use no_std_types::context::Ctx; use num_enum::{FromPrimitive, IntoPrimitive}; use raster_types::{CPU, Image, Raster}; use vector_types::Gradient; diff --git a/node-graph/nodes/raster/src/blending_nodes.rs b/node-graph/nodes/raster/src/blending_nodes.rs index 20d1a75cba..1be51ba643 100644 --- a/node-graph/nodes/raster/src/blending_nodes.rs +++ b/node-graph/nodes/raster/src/blending_nodes.rs @@ -1,12 +1,12 @@ use crate::adjust::Adjust; +use core_types::Ctx; +use core_types::blending::BlendMode; +use core_types::color::Color; use core_types::list::Item; -use no_std_types::Ctx; -use no_std_types::blending::BlendMode; -use no_std_types::color::Color; use raster_types::{CPU, Raster}; use vector_types::Gradient; -pub use no_std_types::blending::{apply_blend_mode, blend_colors}; +pub use core_types::blending::{apply_blend_mode, blend_colors}; /// Mixes the over color onto the under color by a blend mode and opacity, as if they were stacked layers. #[node_macro::node(category("Color"), icon("NodeMixColors"), version(2))] diff --git a/node-graph/nodes/raster/src/color_lookup_table.rs b/node-graph/nodes/raster/src/color_lookup_table.rs index c90a647e3a..06362d32d7 100644 --- a/node-graph/nodes/raster/src/color_lookup_table.rs +++ b/node-graph/nodes/raster/src/color_lookup_table.rs @@ -7,8 +7,8 @@ mod format_icc; mod format_look; use crate::adjustments::{SRGB_TO_XYZ_D50, WHITE_XYZ_D50, XYZ_D50_TO_SRGB, multiply_matrix}; +use core_types::color::{linear_to_srgb, srgb_to_linear}; use graphene_resource::{Resource, ResourceHash}; -use no_std_types::color::{linear_to_srgb, srgb_to_linear}; use std::sync::{Arc, Mutex, PoisonError}; pub const LUT_FILE_EXTENSIONS: &[&str] = &["cube", "3dl", "look", "csp", "icc", "icm"];