Color Space Conversion Module¶
Color Space Conversion Module
-
jpegenc.subblocks.color_converters.rgb2ycbcr.
rgb2ycbcr
¶ Color Space Conversion module
This module is used to transform the rgb input to an other representation called YCbCr. The input interface is the RGB and the output is the Ycbcr. The inputs and outputs are parallel.
- Inputs:
- Red, Green, Blue, data_valid clock, reset
- Outputs:
- Y, Cb ,Cr, data_valid
- Parameters:
- num_fractional_bits
-
class
jpegenc.subblocks.color_converters.rgb2ycbcr.
ColorSpace
(red=0, green=0, blue=0)¶ Color Space Conversion Class
It is used to derive the integer coefficients and as a software reference for the conversion
-
_set_jfif_coefs
()¶ The YCbCr special constants
The JFIF YCbCr conversion requires “special” constants defined by the standard. The constants are describe in a Wikipedia page: https://en.wikipedia.org/wiki/YCbCr
-
get_jfif_ycbcr
()¶ RGB to YCbCr Conversion. Used as software reference.
-
get_jfif_ycbcr_int_coef
(precision_factor=0)¶ Generate the integer (fixed-point) coefficients
-