Function pointer representing a double -> double transfer function that performs either an OETF transfer function, or alternatively an inverse EOTF function (in particular, for SMPTE ST 2084 / PQ).
This function inputs linear light, and outputs gamma encoded light.
See ITU-T H.273 for more information.
Retrieves the Luma coefficients necessary to construct a conversion matrix from an enum constant describing the colorspace.
Definition at line 58 of file csp.c.
Referenced by create_filtergraph(), ff_draw_init2(), ff_fmt_from_frame(), filter_frame(), init(), init_filter(), init_scale_shader(), and tonemap_opencl_init().
Retrieves a complete gamut description from an enum constant describing the color primaries.
Definition at line 90 of file csp.c.
Referenced by create_filtergraph(), ff_fmt_from_frame(), ff_icc_profile_generate(), gamut_from_colorspace(), get_rgb2rgb_matrix(), infer_prim_ref(), libjxl_get_primaries(), libjxl_populate_primaries(), and png_get_chrm().
Detects which enum AVColorPrimaries constant corresponds to the given complete gamut description.
Definition at line 110 of file csp.c.
Referenced by iccdetect_filter_frame(), libjxl_get_primaries(), and populate_avctx_color_fields().
Determine a suitable 'gamma' value to match the supplied AVColorTransferCharacteristic.
See Apple Technical Note TN2257 (https://developer.apple.com/library/mac/technotes/tn2257/_index.html)
This function returns the gamma exponent for the OETF. For example, sRGB is approximated by gamma 2.2, not by gamma 0.45455.
Definition at line 149 of file csp.c.
Referenced by mov_write_gama_tag(), and png_get_gama().
Determine the function needed to apply the given AVColorTransferCharacteristic to linear input.
The function returned should expect a nominal domain and range of [0.0-1.0] values outside of this range maybe valid depending on the chosen characteristic function.
Definition at line 400 of file csp.c.
Referenced by decode_block(), decode_init(), and main().
Returns the ITU EOTF corresponding to a given TRC.
This converts from the signal level [0,1] to the raw output display luminance in nits (cd/m^2). This is done per channel in RGB space, except for AVCOL_TRC_SMPTE428, which assumes CIE XYZ in- and output.
This is also the case for functions like PQ, which are defined over an absolute signal range independent of the target display capabilities.
Definition at line 605 of file csp.c.
Referenced by gamut_from_colorspace(), main(), and sws_test_transfer().
Returns the mathematical inverse of the corresponding EOTF.
Definition at line 631 of file csp.c.
Referenced by gamut_from_colorspace(), main(), and sws_test_transfer().