aboutsummaryrefslogtreecommitdiff
path: root/demo/Shaders/imguiVS.hlsl
diff options
context:
space:
mode:
Diffstat (limited to 'demo/Shaders/imguiVS.hlsl')
-rw-r--r--demo/Shaders/imguiVS.hlsl31
1 files changed, 31 insertions, 0 deletions
diff --git a/demo/Shaders/imguiVS.hlsl b/demo/Shaders/imguiVS.hlsl
new file mode 100644
index 0000000..6116ee1
--- /dev/null
+++ b/demo/Shaders/imguiVS.hlsl
@@ -0,0 +1,31 @@
+
+cbuffer params : register(b0)
+{
+ float4x4 transform;
+};
+
+struct Input
+{
+ float2 position : POSITION;
+ float2 texCoord : TEXCOORD;
+ float4 color : COLOR;
+};
+
+struct Output
+{
+ float4 position : SV_POSITION;
+ float2 texCoord : TEXCOORD;
+ float4 color : COLOR;
+};
+
+Output imguiVS(Input input, uint instance : SV_InstanceID)
+{
+ Output output;
+
+ output.position = mul(float4(input.position, 0.f, 1.f), transform);
+
+ output.texCoord = input.texCoord.xy; // float2(input.texCoord.x, 1.f - input.texCoord.y);
+ output.color = input.color;
+
+ return output;
+} \ No newline at end of file