demos: Use the assembler to embed HLSL sources.

This commit is contained in:
Henri Verbeet
2024-12-20 19:23:46 +01:00
parent 4227858cfe
commit fb4b150f27
Notes: Henri Verbeet 2025-01-13 16:45:58 +01:00
Approved-by: Henri Verbeet (@hverbeet)
Approved-by: Giovanni Mascellani (@giomasce)
Merge-Request: https://gitlab.winehq.org/wine/vkd3d/-/merge_requests/1337
8 changed files with 133 additions and 88 deletions

20
demos/triangle.hlsl Normal file
View File

@@ -0,0 +1,20 @@
struct ps_in
{
float4 position : SV_POSITION;
float4 colour : COLOR;
};
struct ps_in vs_main(float4 position : POSITION, float4 colour : COLOR)
{
struct ps_in o;
o.position = position;
o.colour = colour;
return o;
}
float4 ps_main(struct ps_in i) : SV_TARGET
{
return i.colour;
}