Closed age88 closed 1 year ago
TV->PC range conversion is part of the YUV->RGB conversion process. Of course chroma upscaling needs to happen before you can convert to RGB
In my opinion for a high quality video output the process should be TVtoPC range->chroma upscaling->YUVtoRGB..... like madvr or the internal resizers in vapoursynth. It would be nice to have this operations chain if it's not hard to achieve :-)
Well I don't really care about your opinion.
Sorry I don't mean mpv has not yet a very good quality output
I think he just means that if you can't prove that it makes a difference, then it's not a problem. basically, I think they want some firm numbers for your claims.
The limited range is compressed compared to full range and a resizer can do some rounding error , when a resizer is used for a full range picture it is the more precise it can be. Another reason is that if a limited range picture is upscaled some values could go outside the legal range and after the tv->pc conversion that values will be clipped, the effect is more visible artifacts
http://i.imgur.com/MOMTC1M.jpg http://i.imgur.com/Ng8EXUW.jpg This example is in rgb just for semplicty
At the end it isn't a high boost quality but it give more smooth and precise results
Why don't you give actual screenshots of what you think is wrong? Those two shots and your explanation still make no sense.
Okay, I think what you're trying to say is that mpv does this, allegedly:
Chroma Upscaling -> Limited (TV) Levels to Full (PC) Levels -> YUV to RGB Conversion
While it should be doing this instead, because it would be "better":
Limited (TV) Levels to Full (PC) Levels -> Chroma Upscaling -> YUV to RGB Conversion
Maybe you should make some screenshots that actually illustrate this? Because I don't really get how your examples apply here either..
Edit:
you = OP
There's no reason to allege. There's a diagram with every step of way from decoded frame to displayed frame: https://github.com/mpv-player/mpv/wiki/Video-output---shader-stage-diagram
Look at the hsb color picker, I've used bicubic for the chroma upscaling and no additional processing.
Chroma upscaling->levels->rgb conversion : less satured
levels->chroma upscaling->rgb conversion : more vivid
Interesting... The deviation in saturation is always the same, i.e. slightly higher?
Yes from my quick test the saturation is always slightly higher but not on the whole image,even in the two last picture that I've posted the color picker return me the exact value on some different part of that frame
like madvr or the internal resizers in vapoursynth
Do you have links to show they are actually doing so? (madVR isn't open-source, is it?)
The limited range is compressed compared to full range and a resizer can do some rounding error, when a resizer is used for a full range picture it is the more precise it can be.
The precision difference is insignificant as long as you are not using an integer fbo-format
.
Another reason is that if a limited range picture is upscaled some values could go outside the legal range and after the tv->pc conversion that values will be clipped.
If you stretch YUV early, similar things can still happen: values can go below zero or beyong 255 (if 8 bit). Hence this is not a good argument.
I see some people writing format conversion functions like this: https://github.com/HomeOfVapourSynthEvolution/mvsfunc/blob/413e23f6cae7e4dfbd539e04d9ef79405d5bdec2/mvsfunc.py#L453-L468 If I understood correctly, the operation order is chroma upscaling -> matrix conversion (YUV->RGB) -> depth conversion, which is the way that mpv is doing.
When I use vo=opengl it seems to my eyes that mpv does chroma upscaling before the tv to pc range conversion. If so is it possible to fix this?