use super::*;
#[derive(Clone, Copy, Data, Debug, PartialEq)]
pub struct BloomConfig3D {
#[get(type(copy))]
pub(crate) enabled: bool,
#[get(type(copy))]
pub(crate) threshold: f32,
#[get(type(copy))]
pub(crate) soft_knee: f32,
#[get(type(copy))]
pub(crate) intensity: f32,
#[get(type(copy))]
pub(crate) mip_count: usize,
}
#[derive(Clone, Copy, Data, Debug, PartialEq)]
pub struct AutoExposureConfig3D {
#[get(type(copy))]
pub(crate) enabled: bool,
#[get(type(copy))]
pub(crate) min_log_lum: f32,
#[get(type(copy))]
pub(crate) max_log_lum: f32,
#[get(type(copy))]
pub(crate) target_key_value: f32,
#[get(type(copy))]
pub(crate) adapt_speed_up: f32,
#[get(type(copy))]
pub(crate) adapt_speed_down: f32,
#[get(type(copy))]
pub(crate) min_exposure: f32,
#[get(type(copy))]
pub(crate) max_exposure: f32,
}
#[derive(Clone, Copy, Data, Debug, PartialEq)]
pub struct ColorGradingConfig3D {
#[get(type(copy))]
pub(crate) exposure_ev: f32,
#[get(type(copy))]
pub(crate) contrast: f32,
#[get(type(copy))]
pub(crate) saturation: f32,
#[get(type(copy))]
pub(crate) lift: Vec3,
#[get(type(copy))]
pub(crate) gamma: Vec3,
#[get(type(copy))]
pub(crate) gain: Vec3,
#[get(type(copy))]
pub(crate) temperature: f32,
#[get(type(copy))]
pub(crate) tint: f32,
}
#[derive(Clone, Copy, Data, Debug, PartialEq)]
pub struct PostFxConfig3D {
#[get(type(copy))]
pub(crate) bloom: BloomConfig3D,
#[get(type(copy))]
pub(crate) auto_exposure: AutoExposureConfig3D,
#[get(type(copy))]
pub(crate) color_grading: ColorGradingConfig3D,
#[get(type(copy))]
pub(crate) vignette_intensity: f32,
#[get(type(copy))]
pub(crate) vignette_smoothness: f32,
#[get(type(copy))]
pub(crate) chromatic_aberration: f32,
#[get(type(copy))]
pub(crate) tone_mapper: ToneMapOperator3D,
#[get(type(copy))]
pub(crate) fxaa_enabled: bool,
}
#[derive(Clone, Data, Debug, PartialEq)]
pub struct BloomMipBuffer3D {
#[get(type(copy))]
pub(crate) width: usize,
#[get(type(copy))]
pub(crate) height: usize,
pub(crate) pixels: Vec<[f32; 3]>,
}
#[derive(Clone, Data, Debug, PartialEq)]
pub struct PostFxPipeline3D {
#[get(type(copy))]
pub(crate) width: usize,
#[get(type(copy))]
pub(crate) height: usize,
#[get(type(copy))]
pub(crate) config: PostFxConfig3D,
#[get(type(copy))]
pub(crate) adapted_exposure: f32,
#[get(type(copy))]
pub(crate) adapted_avg_luminance: f32,
#[get(type(copy))]
pub(crate) last_bloom_input_energy: f32,
#[get(type(copy))]
pub(crate) last_bloom_output_energy: f32,
#[get(pub(crate))]
#[get_mut(pub(crate))]
#[set(pub(crate))]
pub(crate) histogram_bins: [u32; POSTFX_HISTOGRAM_BINS],
#[get(pub(crate))]
#[get_mut(pub(crate))]
#[set(pub(crate))]
pub(crate) bloom_mips: Vec<BloomMipBuffer3D>,
#[get(pub(crate))]
#[get_mut(pub(crate))]
#[set(pub(crate))]
pub(crate) graded_srgb: Vec<[f32; 3]>,
#[get(pub(crate))]
#[get_mut(pub(crate))]
#[set(pub(crate))]
pub(crate) luma_buffer: Vec<f32>,
#[get(pub(crate))]
#[get_mut(pub(crate))]
#[set(pub(crate))]
pub(crate) output_rgba8: Vec<u8>,
}