render/cm: Add cm_sdr_eotf, sdr_eotf (#1260)

This commit is contained in:
Dominick DiMaggio 2025-10-29 08:54:17 -04:00 committed by GitHub
parent 85bebc0f02
commit c5dbfeff4c
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
2 changed files with 3 additions and 0 deletions

View file

@ -257,6 +257,8 @@ Use `sdrbrightness, B` and `sdrsaturation, S` to control SDR brightness and satu
monitor = eDP-1, 2880x1800@90, 0x0, 1, bitdepth, 10, cm, hdr, sdrbrightness, 1.2, sdrsaturation, 0.98
```
The default transfer function assumed to be in use on an SDR display for sRGB content is defined by `, sdr_eotf, X`. The default (`0`) is to follow `render:cm_sdr_eotf`. This can be changed to piecewise sRGB with `1`, or Gamma 2.2 with `2`.
### VRR
Per-display VRR can be done by adding `, vrr, X` where `X` is the mode from the

View file

@ -517,6 +517,7 @@ _Subcategory `render:`_
| cm_auto_hdr | Auto-switch to HDR in fullscreen when needed. 0 - off, 1 - switch to `cm, hdr`, 2 - switch to `cm, hdredid` | int | 1 |
| new_render_scheduling | Automatically uses triple buffering when needed, improves FPS on underpowered devices. | bool | false |
| non_shader_cm | Enable CM without shader. 0 - disable, 1 - whenever possible, 2 - DS and passthrough only, 3 - don't block DS when non-shader CM isn't available | int | 2 |
| cm_sdr_eotf | Default transfer function for displaying SDR apps. 0 - Treat unspecified as sRGB, 1 - Treat unspecified as Gamma 2.2, 2 - Treat unspecified and sRGB as Gamma 2.2 | int | 0 |
`cm_auto_hdr` requires `--target-colorspace-hint-mode=source` mpv option to work with mpv versions greater than v0.40.0