Blender V5.0
colormanagement_inline.h File Reference

Go to the source code of this file.

Functions

void IMB_colormanagement_get_luminance_coefficients (float r_rgb[3])
float IMB_colormanagement_get_luminance (const float rgb[3])
uchar IMB_colormanagement_get_luminance_byte (const uchar rgb[3])
void IMB_colormanagement_xyz_to_scene_linear (float scene_linear[3], const float xyz[3])
void IMB_colormanagement_scene_linear_to_xyz (float xyz[3], const float scene_linear[3])
void IMB_colormanagement_rec709_to_scene_linear (float scene_linear[3], const float rec709[3])
void IMB_colormanagement_scene_linear_to_rec709 (float rec709[3], const float scene_linear[3])
void IMB_colormanagement_scene_linear_to_srgb_v3 (float srgb[3], const float scene_linear[3])
void IMB_colormanagement_srgb_to_scene_linear_v3 (float scene_linear[3], const float srgb[3])
void IMB_colormanagement_aces_to_scene_linear (float scene_linear[3], const float aces[3])
void IMB_colormanagement_scene_linear_to_aces (float aces[3], const float scene_linear[3])
void IMB_colormanagement_acescg_to_scene_linear (float scene_linear[3], const float acescg[3])
void IMB_colormanagement_scene_linear_to_acescg (float acescg[3], const float scene_linear[3])
void IMB_colormanagement_rec2020_to_scene_linear (float scene_linear[3], const float rec2020[3])
void IMB_colormanagement_scene_linear_to_rec2020 (float rec2020[3], const float scene_linear[3])

Function Documentation

◆ IMB_colormanagement_aces_to_scene_linear()

void IMB_colormanagement_aces_to_scene_linear ( float scene_linear[3],
const float aces[3] )

◆ IMB_colormanagement_acescg_to_scene_linear()

void IMB_colormanagement_acescg_to_scene_linear ( float scene_linear[3],
const float acescg[3] )

◆ IMB_colormanagement_get_luminance()

float IMB_colormanagement_get_luminance ( const float rgb[3])

Convert a float RGB triplet to the correct luminance weighted average.

Gray-scale, or Luma is a distillation of RGB data values down to a weighted average based on the luminance positions of the red, green, and blue primaries. Given that the internal reference space may be arbitrarily set, any effort to glean the luminance coefficients must be aware of the reference space primaries.

See http://wiki.blender.org/index.php/User:Nazg-gul/ColorManagement#Luminance

Definition at line 23 of file colormanagement_inline.h.

References dot_v3v3(), and blender::colorspace::luma_coefficients.

Referenced by BKE_histogram_update_sample_line(), blender::bke::color_to_bool(), blender::bke::color_to_float(), blender::bke::color_to_int(), do_projectpaint_soften(), do_projectpaint_soften_f(), blender::color::get_luminance(), blender::nodes::node_fn_compare_cc::get_multi_function(), image_exr_from_rgb_to_bw(), IMB_color_to_bw(), paint_2d_lift_soften(), RE_texture_evaluate(), rgbtobw_valuefn(), scopes_update_cb(), blender::seq::tonemap_calc_chunk_luminance(), blender::seq::tonemap_rd_photoreceptor(), and ui_draw_but_CURVE().

◆ IMB_colormanagement_get_luminance_byte()

◆ IMB_colormanagement_get_luminance_coefficients()

void IMB_colormanagement_get_luminance_coefficients ( float r_rgb[3])

Definition at line 18 of file colormanagement_inline.h.

References copy_v3_v3(), and blender::colorspace::luma_coefficients.

Referenced by blender::nodes::node_composite_tonemap_cc::ToneMapOperation::compute_average_log_luminance(), blender::nodes::node_composite_tonemap_cc::ToneMapOperation::compute_average_luminance(), blender::nodes::node_composite_tonemap_cc::ToneMapOperation::compute_log_maximum_luminance(), blender::nodes::node_composite_tonemap_cc::ToneMapOperation::compute_log_minimum_luminance(), blender::nodes::node_composite_levels_cc::LevelsOperation::compute_sum(), blender::nodes::node_composite_levels_cc::LevelsOperation::compute_sum_squared_difference(), blender::compositor::ConversionOperation::execute(), blender::nodes::node_composite_tonemap_cc::ToneMapOperation::execute_photoreceptor_cpu(), blender::nodes::node_composite_tonemap_cc::ToneMapOperation::execute_photoreceptor_gpu(), blender::nodes::node_composite_levels_cc::LevelsOperation::execute_single_value(), blender::compositor::get_luminance_coefficients(), blender::nodes::node_shader_rgb_to_bw_cc::gpu_shader_rgbtobw(), blender::imbuf::imb_oiio_write(), blender::nodes::node_composite_colorcorrection_cc::node_build_multi_function(), blender::nodes::node_composite_luma_matte_cc::node_build_multi_function(), blender::nodes::node_composite_rgb_to_bw_cc::node_build_multi_function(), blender::nodes::node_composite_colorcorrection_cc::node_gpu_material(), blender::nodes::node_composite_luma_matte_cc::node_gpu_material(), blender::nodes::node_composite_rgb_to_bw_cc::node_gpu_material(), and blender::ed::vse::sequencer_draw_scopes().

◆ IMB_colormanagement_rec2020_to_scene_linear()

void IMB_colormanagement_rec2020_to_scene_linear ( float scene_linear[3],
const float rec2020[3] )

◆ IMB_colormanagement_rec709_to_scene_linear()

◆ IMB_colormanagement_scene_linear_to_aces()

void IMB_colormanagement_scene_linear_to_aces ( float aces[3],
const float scene_linear[3] )

◆ IMB_colormanagement_scene_linear_to_acescg()

void IMB_colormanagement_scene_linear_to_acescg ( float acescg[3],
const float scene_linear[3] )

◆ IMB_colormanagement_scene_linear_to_rec2020()

void IMB_colormanagement_scene_linear_to_rec2020 ( float rec2020[3],
const float scene_linear[3] )

◆ IMB_colormanagement_scene_linear_to_rec709()

void IMB_colormanagement_scene_linear_to_rec709 ( float rec709[3],
const float scene_linear[3] )

◆ IMB_colormanagement_scene_linear_to_srgb_v3()

◆ IMB_colormanagement_scene_linear_to_xyz()

void IMB_colormanagement_scene_linear_to_xyz ( float xyz[3],
const float scene_linear[3] )

◆ IMB_colormanagement_srgb_to_scene_linear_v3()

◆ IMB_colormanagement_xyz_to_scene_linear()

void IMB_colormanagement_xyz_to_scene_linear ( float scene_linear[3],
const float xyz[3] )

Conversion between scene linear and other color spaces.

Definition at line 39 of file colormanagement_inline.h.

References mul_v3_m3v3(), ptr, and blender::colorspace::xyz_to_scene_linear.

Referenced by Color_from_xyz_d65_to_scene_linear(), IMB_colormanagement_get_whitepoint(), and IMB_colormanagement_wavelength_to_rgb().