Files
SDL/test/testgpu/cube.vert.hlsl
Sam Lantinga a864dcac25 Added support for using the GPU renderer as an offscreen renderer
SDL_CreateGPURenderer() now allows passing in an existing GPU device and passing in a NULL window to create an offscreen renderer.

Also renamed SDL_SetRenderGPUState() to SDL_SetGPURenderState().
2025-10-01 23:32:18 -07:00

16 lines
284 B
HLSL

#include "cube.hlsli"
cbuffer UBO : register(b0, space1)
{
float4x4 ModelViewProj;
};
VSOutput main(VSInput input)
{
VSOutput output;
output.Color = float4(input.Color, 1.0f);
output.Position = mul(ModelViewProj, float4(input.Position, 1.0f));
return output;
}