HDR10 in openFrameworks

According to this GLFW issue I suppose it is not possible to reproduce HDR10 content now using OFW

but other than the window, which other changes would be necessary to play a 10 bit video file with shaders in OFW?
Thank you

Hey @dimitre, I’ve been wondering a bit about this kind of stuff lately too. I recently did some quick tests with ofFbo, with float values that ranged outside of the typical range of 0.0 to 1.0. An ofFbo that is allocated with an internal format of GL_RGB16F or GL_RGBA16F did store float values greater than 1.0. And I could also use GL_RGB32F and GL_RGBA32F if I increased the precision of the float in the (fragment) shader file. An ofFbo with an internal format of GL_RGB or GL_RGBA would not store values greater than 1.0.

So, I’m thinking that using a (pingpong) pair of ofFbos that have allocated with the correct internal format would work well for a chain of shaders where you want to process an image (or video) with color values that exceed the typical range (0.0 to 1.0). I try to keep the pingpong simple and just use 2 ofFbos, and swap them as needed with std::swap(). The final rendering in oF (I think) is always in the range from 0.0 to 1.0. But I’m also thinking that there could/should be a way to save this the final ofFbo with its “out of range” values. And I think it might help to use “float” types wherever possible along the way: ofFloatImage; ofFloatColor; ofFloatPixels; etc.

1 Like