Generalize SDR white level handling into a color scale

This gives applications better control over how and when light levels are adjusted when working with HDR content and display.
This commit is contained in:
Sam Lantinga
2024-02-05 23:20:43 -08:00
parent 82d89ff4fb
commit d4caef5b89
34 changed files with 3279 additions and 3234 deletions

View File

@@ -967,6 +967,8 @@ SDL3_0.0.0 {
SDL_GetSurfaceColorspace;
SDL_ConvertSurfaceFormatAndColorspace;
SDL_CopyProperties;
SDL_SetRenderColorScale;
SDL_GetRenderColorScale;
# extra symbols go here (don't modify this line)
local: *;
};

View File

@@ -992,3 +992,5 @@
#define SDL_GetSurfaceColorspace SDL_GetSurfaceColorspace_REAL
#define SDL_ConvertSurfaceFormatAndColorspace SDL_ConvertSurfaceFormatAndColorspace_REAL
#define SDL_CopyProperties SDL_CopyProperties_REAL
#define SDL_SetRenderColorScale SDL_SetRenderColorScale_REAL
#define SDL_GetRenderColorScale SDL_GetRenderColorScale_REAL

View File

@@ -1017,3 +1017,5 @@ SDL_DYNAPI_PROC(int,SDL_SetSurfaceColorspace,(SDL_Surface *a, SDL_Colorspace b),
SDL_DYNAPI_PROC(int,SDL_GetSurfaceColorspace,(SDL_Surface *a, SDL_Colorspace *b),(a,b),return)
SDL_DYNAPI_PROC(SDL_Surface*,SDL_ConvertSurfaceFormatAndColorspace,(SDL_Surface *a, Uint32 b, SDL_Colorspace c),(a,b,c),return)
SDL_DYNAPI_PROC(int,SDL_CopyProperties,(SDL_PropertiesID a, SDL_PropertiesID b),(a,b),return)
SDL_DYNAPI_PROC(int,SDL_SetRenderColorScale,(SDL_Renderer *a, float b),(a,b),return)
SDL_DYNAPI_PROC(int,SDL_GetRenderColorScale,(SDL_Renderer *a, float *b),(a,b),return)