Simplest SDL setup to experiment with 10 bit monitor?

I’m new to SDL. My goal is very simple color and shape manipulations for a monitor calibration project, an HDR10 monitor that is.

I’m reasonably confident SDL can drive HDR10 on a platform with the appropriate support, but I can’t seem to figure out the right setup and SDL calls to get there.

A few questions:

  1. What needs to be present on a given platform for SDL to be able to drive HDR10?
  2. How does one configure 10 bit color depth in SDL? I’ve experimented with SDL_PIXELFORMAT_ARGB2101010 but still seem to end up with 8 bit color depth. Even if I were successful in configuring a window’s display mode for 10 bit depth it seems that other parts of the SDL API are limited to 8 bit depth (e.g. SDL_Color). How are these reconciled?
  3. How might one produce PQ10 or full HDR10 using SDL? What is a barebones outline of the necessary SDL primitives and calls?

Thank you for any help on this.

1 Like