Skip to content

Commit

Permalink
sdlgpu: Update to latest shadercross ABI
Browse files Browse the repository at this point in the history
  • Loading branch information
flibitijibibo committed Jan 27, 2025
1 parent f6e05fb commit ff2d858
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions mojoshader_sdlgpu.c
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,8 @@ typedef struct SDL_ShaderCross_GraphicsShaderMetadata
Uint32 num_storage_textures; /**< The number of storage textures defined in the shader. */
Uint32 num_storage_buffers; /**< The number of storage buffers defined in the shader. */
Uint32 num_uniform_buffers; /**< The number of uniform buffers defined in the shader. */

SDL_PropertiesID props; /**< A properties ID for extensions. This is allocated and freed by the caller, and should be 0 if no extensions are needed. */
} SDL_ShaderCross_GraphicsShaderMetadata;

typedef struct SDL_ShaderCross_SPIRV_Info
Expand Down Expand Up @@ -529,6 +531,7 @@ static MOJOSHADER_sdlProgram *compile_program(
crossCreateInfo.enable_debug = 0;
crossCreateInfo.name = NULL;
crossCreateInfo.props = 0;
whoCares.props = 0;

program->vertexShader = SDL_ShaderCross_CompileGraphicsShaderFromSPIRV(
ctx->device,
Expand Down Expand Up @@ -569,6 +572,7 @@ static MOJOSHADER_sdlProgram *compile_program(
crossCreateInfo.enable_debug = 0;
crossCreateInfo.name = NULL;
crossCreateInfo.props = 0;
whoCares.props = 0;

program->pixelShader = SDL_ShaderCross_CompileGraphicsShaderFromSPIRV(
ctx->device,
Expand Down

0 comments on commit ff2d858

Please sign in to comment.