mirror of
https://github.com/webmproject/libwebp.git
synced 2024-11-19 20:08:28 +01:00
Fix variable names in SharpYuvComputeConversionMatrix
Change-Id: Ia07e71aae42396100a4f50dc104e828239522d77
This commit is contained in:
parent
a3ba6f19e9
commit
2ddaaf0aa5
@ -22,16 +22,16 @@ void SharpYuvComputeConversionMatrix(const SharpYuvColorSpace* yuv_color_space,
|
|||||||
const float kr = yuv_color_space->kr;
|
const float kr = yuv_color_space->kr;
|
||||||
const float kb = yuv_color_space->kb;
|
const float kb = yuv_color_space->kb;
|
||||||
const float kg = 1.0f - kr - kb;
|
const float kg = 1.0f - kr - kb;
|
||||||
const float cr = 0.5f / (1.0f - kb);
|
const float cb = 0.5f / (1.0f - kb);
|
||||||
const float cb = 0.5f / (1.0f - kr);
|
const float cr = 0.5f / (1.0f - kr);
|
||||||
|
|
||||||
const int shift = yuv_color_space->bit_depth - 8;
|
const int shift = yuv_color_space->bit_depth - 8;
|
||||||
|
|
||||||
const float denom = (float)((1 << yuv_color_space->bit_depth) - 1);
|
const float denom = (float)((1 << yuv_color_space->bit_depth) - 1);
|
||||||
float scale_y = 1.0f;
|
float scale_y = 1.0f;
|
||||||
float add_y = 0.0f;
|
float add_y = 0.0f;
|
||||||
float scale_u = cr;
|
float scale_u = cb;
|
||||||
float scale_v = cb;
|
float scale_v = cr;
|
||||||
float add_uv = (float)(128 << shift);
|
float add_uv = (float)(128 << shift);
|
||||||
assert(yuv_color_space->bit_depth >= 8);
|
assert(yuv_color_space->bit_depth >= 8);
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user