Skip to main content

moxcms/conversions/
mod.rs

1/*
2 * // Copyright (c) Radzivon Bartoshyk 2/2025. All rights reserved.
3 * //
4 * // Redistribution and use in source and binary forms, with or without modification,
5 * // are permitted provided that the following conditions are met:
6 * //
7 * // 1.  Redistributions of source code must retain the above copyright notice, this
8 * // list of conditions and the following disclaimer.
9 * //
10 * // 2.  Redistributions in binary form must reproduce the above copyright notice,
11 * // this list of conditions and the following disclaimer in the documentation
12 * // and/or other materials provided with the distribution.
13 * //
14 * // 3.  Neither the name of the copyright holder nor the names of its
15 * // contributors may be used to endorse or promote products derived from
16 * // this software without specific prior written permission.
17 * //
18 * // THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
19 * // AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
20 * // IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
21 * // DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE
22 * // FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
23 * // DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
24 * // SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER
25 * // CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
26 * // OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
27 * // OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
28 */
29#[cfg(all(target_arch = "x86_64", feature = "avx"))]
30mod avx;
31#[cfg(all(target_arch = "x86_64", feature = "avx512"))]
32mod avx512;
33mod bpc;
34mod gray2rgb;
35mod gray2rgb_extended;
36mod interpolator;
37#[cfg(feature = "any_to_any")]
38mod katana;
39mod lut3x3;
40mod lut3x4;
41mod lut4;
42mod lut_transforms;
43mod mab;
44mod mab4x3;
45mod mba3x4;
46#[cfg(feature = "any_to_any")]
47mod md_lut;
48#[cfg(feature = "any_to_any")]
49mod md_luts_factory;
50#[cfg(all(target_arch = "aarch64", feature = "neon"))]
51mod neon;
52mod prelude_lut_xyz_rgb;
53mod reduction;
54mod rgb2gray;
55mod rgb2gray_extended;
56mod rgb_xyz_factory;
57mod rgbxyz;
58mod rgbxyz_fixed;
59mod rgbxyz_float;
60#[cfg(all(any(target_arch = "x86", target_arch = "x86_64"), feature = "sse"))]
61mod sse;
62mod transform_lut3_to_3;
63mod transform_lut3_to_4;
64mod transform_lut4_to_3;
65mod xyz_lab;
66
67#[cfg(feature = "in_place")]
68pub(crate) use gray2rgb::make_gray_to_gray_in_place;
69pub(crate) use gray2rgb::{make_gray_to_unfused, make_gray_to_x};
70#[cfg(feature = "extended_range")]
71pub(crate) use gray2rgb_extended::{make_gray_to_one_trc_extended, make_gray_to_rgb_extended};
72#[cfg(feature = "lut")]
73pub(crate) use lut_transforms::make_lut_transform;
74pub(crate) use reduction::LutBarycentricReduction;
75pub(crate) use rgb_xyz_factory::{RgbXyzFactory, RgbXyzFactoryOpt};
76pub(crate) use rgb2gray::{ToneReproductionRgbToGray, make_rgb_to_gray};
77#[cfg(feature = "extended_range")]
78pub(crate) use rgb2gray_extended::make_rgb_to_gray_extended;
79pub(crate) use rgbxyz::{TransformMatrixShaper, TransformMatrixShaperOptimized};
80#[cfg(feature = "extended_range")]
81pub(crate) use rgbxyz_float::{
82    TransformShaperFloatInOut, TransformShaperRgbFloat, make_rgb_xyz_rgb_transform_float,
83    make_rgb_xyz_rgb_transform_float_in_out,
84};