Ver Fonte

SpriteBatch: забыл добавить hlsl-версию шейдера TriangleBatch

1vanK há 3 anos atrás
pai
commit
f93953c28d
1 ficheiros alterados com 20 adições e 0 exclusões
  1. 20 0
      bin/CoreData/Shaders/HLSL/TriangleBatch.hlsl

+ 20 - 0
bin/CoreData/Shaders/HLSL/TriangleBatch.hlsl

@@ -0,0 +1,20 @@
+#include "Uniforms.hlsl"
+#include "Transform.hlsl"
+
+void VS(float4 iPos : POSITION,
+        float4 iColor : COLOR0,
+        out float4 oColor : COLOR0,
+        out float4 oPos : OUTPOSITION)
+{
+    float4x3 modelMatrix = iModelMatrix;
+    float3 worldPos = GetWorldPos(modelMatrix);
+    oPos = GetClipPos(worldPos);
+
+    oColor = iColor;
+}
+
+void PS(float4 iColor : COLOR0,
+        out float4 oColor : OUTCOLOR0)
+{
+    oColor = iColor;
+}