diff --git a/gfx/qcms/src/iccread.rs b/gfx/qcms/src/iccread.rs index 1839c23ec5c6..ff320fe5426b 100644 --- a/gfx/qcms/src/iccread.rs +++ b/gfx/qcms/src/iccread.rs @@ -26,7 +26,7 @@ use std::{ sync::Arc, }; -use crate::transform::{precache_output, set_rgb_colorants}; +use crate::transform::{PrecacheOuput, set_rgb_colorants}; use crate::{matrix::Matrix, s15Fixed16Number, s15Fixed16Number_to_float, Intent, Intent::*}; pub static SUPPORTS_ICCV4: AtomicBool = AtomicBool::new(cfg!(feature = "iccv4-enabled")); @@ -55,9 +55,9 @@ pub struct Profile { pub(crate) mAB: Option>, pub(crate) mBA: Option>, pub(crate) chromaticAdaption: Matrix, - pub(crate) output_table_r: Option>, - pub(crate) output_table_g: Option>, - pub(crate) output_table_b: Option>, + pub(crate) output_table_r: Option>, + pub(crate) output_table_g: Option>, + pub(crate) output_table_b: Option>, } #[derive(Default)] diff --git a/gfx/qcms/src/transform.rs b/gfx/qcms/src/transform.rs index 36f8010bc2c9..82b270ee9691 100644 --- a/gfx/qcms/src/transform.rs +++ b/gfx/qcms/src/transform.rs @@ -62,7 +62,7 @@ pub const FLOATSCALE: f32 = PRECACHE_OUTPUT_SIZE as f32; pub const CLAMPMAXVAL: f32 = ((PRECACHE_OUTPUT_SIZE - 1) as f32) / PRECACHE_OUTPUT_SIZE as f32; #[repr(C)] -pub struct precache_output { +pub struct PrecacheOuput { /* We previously used a count of 65536 here but that seems like more * precision than we actually need. By reducing the size we can * improve startup performance and reduce memory usage. ColorSync on @@ -71,9 +71,9 @@ pub struct precache_output { pub data: [u8; PRECACHE_OUTPUT_SIZE], } -impl Default for precache_output { - fn default() -> precache_output { - precache_output { +impl Default for PrecacheOuput { + fn default() -> PrecacheOuput { + PrecacheOuput { data: [0; PRECACHE_OUTPUT_SIZE], } } @@ -108,9 +108,9 @@ pub struct qcms_transform { pub output_gamma_lut_g_length: usize, pub output_gamma_lut_b_length: usize, pub output_gamma_lut_gray_length: usize, - pub output_table_r: Option>, - pub output_table_g: Option>, - pub output_table_b: Option>, + pub output_table_r: Option>, + pub output_table_g: Option>, + pub output_table_b: Option>, pub transform_fn: transform_fn_t, } @@ -998,8 +998,8 @@ pub unsafe extern "C" fn qcms_transform_data_bgra_out_lut( qcms_transform_data_template_lut::(transform, src, dest, length); } -fn precache_create() -> Arc { - Arc::new(precache_output::default()) +fn precache_create() -> Arc { + Arc::new(PrecacheOuput::default()) } #[no_mangle]