IENT / YUView

The Free and Open Source Cross Platform YUV Viewer with an advanced analytics toolset
http://ient.github.io/YUView
Other
1.79k stars 354 forks source link

10 bit playback support for capable devices #443

Open ChristianFeldmann opened 2 years ago

ChristianFeldmann commented 2 years ago

Is your feature request related to a problem? Please describe. Currently, all content in YUV is converted to RGB 8bit (maybe with 8 bit alpha channel) for playback. However, it should be possible to playback 10 bit content using openGL somehow. I did not do any tests on this yet though.

Describe the solution you'd like Switch the central widget to an openGL enabled widget and enable 10 bit playback using native openGL.

Describe alternatives you've considered There are no alternatives as far as I know. Qt does not support this natively in the software based rasterization.

nolyn commented 2 years ago

I did some experiments for OpenGL based playback in #282 (way out of date now). Just getting qt based opengl widget to display something is a bit tricky and required quite some experimentation, so it might still be helpful. If I have some time I can try to update it to the current yuview version. don't think I can do the actual 10bit playback implementation though, I don't think my screen supports it. neither my graphics card I suspect, but didn't check. but i don't have a dedicated one, don't expect the integrated one can do this. A major change for having this playback would be required in how different formats are converted to RGB. I think the raw data would have to be given to the graphics card and the conversion should then take place in a shader on the GPU. The shader would need to be able to handle different formats or different shaders for different formats could be used.

ChristianFeldmann commented 2 years ago

Hi. All help here is much appreciated! So as I understood it, openGL supports some 10 bit RGB formats. That way, we would not have to handle any shaders or other special rendeting stuff. But you are right that we would need more functions to do the conversion from 10 bit YUV to 10 bit RGB.

ChristianFeldmann commented 2 years ago

Thanks for the insight. I also see one of the biggest problems that I don't have equipment to display 10 bit content.

1div0 commented 1 year ago

Slightly related, my awful experience with BB/RH in https://bugzilla.redhat.com/show_bug.cgi?id=1435968

At least you can check X server configuration details for 30 bpp.

BTW 30 bpp mode works even w/ 8 bpc panels using dithering. Check nVIDIA Control Panel.