mirror of
https://github.com/libsdl-org/SDL.git
synced 2025-06-05 15:03:43 +00:00
Removed unused YCbCr_matrix from Vulkan shaders
This commit is contained in:
parent
039144350c
commit
bf853823a2
6 changed files with 297 additions and 329 deletions
|
@ -193,8 +193,6 @@ typedef struct
|
|||
float tonemap_factor1;
|
||||
float tonemap_factor2;
|
||||
float sdr_white_point;
|
||||
|
||||
float YCbCr_matrix[16];
|
||||
} PixelShaderConstants;
|
||||
|
||||
/* Per-vertex data */
|
||||
|
@ -238,7 +236,6 @@ typedef struct
|
|||
int width;
|
||||
int height;
|
||||
VULKAN_Shader shader;
|
||||
const float *YCbCr_matrix;
|
||||
|
||||
#if SDL_HAVE_YUV
|
||||
/* Object passed to VkImageView and VkSampler for doing Ycbcr -> RGB conversion */
|
||||
|
@ -3170,8 +3167,6 @@ static void VULKAN_SetupShaderConstants(SDL_Renderer *renderer, const SDL_Render
|
|||
constants->color_scale = cmd->data.draw.color_scale;
|
||||
|
||||
if (texture) {
|
||||
VULKAN_TextureData *textureData = (VULKAN_TextureData *)texture->driverdata;
|
||||
|
||||
switch (texture->format) {
|
||||
case SDL_PIXELFORMAT_YV12:
|
||||
case SDL_PIXELFORMAT_IYUV:
|
||||
|
@ -3207,10 +3202,6 @@ static void VULKAN_SetupShaderConstants(SDL_Renderer *renderer, const SDL_Render
|
|||
constants->tonemap_factor1 = (output_headroom / (texture->HDR_headroom * texture->HDR_headroom));
|
||||
constants->tonemap_factor2 = (1.0f / output_headroom);
|
||||
}
|
||||
|
||||
if (textureData->YCbCr_matrix) {
|
||||
SDL_memcpy(constants->YCbCr_matrix, textureData->YCbCr_matrix, sizeof(constants->YCbCr_matrix));
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue