Output has values beyond tv range
Closed this issue · 2 comments
Hi,
Is it expected to give values < 16 and > 235 when input is in tv range? For example:
ColorBars(pixel_type="yv12")
AddGrain(800, seed=0) # even AddGrain(2, seed=0) gives values < 16 and > 235
ColorYUV(analyze=true)
Also shouldn't the output be visible the same for the following:
ColorBars(pixel_type="yv12")
ConvertBits(32, fulls=false, fulld=true)
AddGrain(800, seed=0)
ConvertBits(8, fulls=true, fulld=false)
Coloryuv(analyze=true)
ColorBars(pixel_type="yv12")
ConvertBits(32, fulld=false)
AddGrain(800, seed=0)
ConvertBits(8)
Coloryuv(analyze=true)
ColorBars(pixel_type="yv12")
AddGrain(800, seed=0)
Coloryuv(analyze=true)
Integer outputs are clamped only so that they stay in 0 to (2^bitdepth - 1) range. So yes, orig_pixel +/- random_number can reach out of valid TV range.
2.) First two: They are not the same, random scatter is relatively smaller in the 8 bit world when stretched to limited range.
I suppose the second and the third example is the most similar but they are still different because of rounding and internal precision.
2.) First two: They are not the same, random scatter is relatively smaller in the 8 bit world when stretched to limited range.
I suppose the second and the third example is the most similar but they are still different because of rounding and internal precision.
So it's normal that the second and the third example have same average luma but the first one is overall darker (lower average luma) even after full->limited conversion?
https://images2.imgbox.com/a5/df/OlPcMiI7_o.png
https://images2.imgbox.com/94/6b/TJXzH4St_o.png
https://images2.imgbox.com/2b/f8/yxc6u8uM_o.png