demos/triangle: Add a demo program.

This commit is contained in:
Henri Verbeet
2016-10-13 13:50:36 +02:00
parent 6cbe8626c2
commit fa5b972371
13 changed files with 1525 additions and 11 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;
}