summaryrefslogtreecommitdiffstats
path: root/TaSTT_Backplate.shader
diff options
context:
space:
mode:
authoryum <yum.food.vr@gmail.com>2022-10-27 20:03:03 -0700
committeryum <yum.food.vr@gmail.com>2022-10-27 20:03:03 -0700
commitb22bcdebdae5ac3dfee29a85236c10af801b95f7 (patch)
tree400e51ec0f218cb07eb5bef4ed5da1d8e85ed484 /TaSTT_Backplate.shader
parent113f2858016c252b97cac96eab454ee16b2dcda2 (diff)
Change board size
It's now twice as wide and half as tall. * Add small margin to board * Add simple backplate shader
Diffstat (limited to 'TaSTT_Backplate.shader')
-rw-r--r--TaSTT_Backplate.shader59
1 files changed, 59 insertions, 0 deletions
diff --git a/TaSTT_Backplate.shader b/TaSTT_Backplate.shader
new file mode 100644
index 0000000..2ab032a
--- /dev/null
+++ b/TaSTT_Backplate.shader
@@ -0,0 +1,59 @@
+Shader "Unlit/TaSTT_Backplate"
+{
+ Properties
+ {
+ _MainTex ("Texture", 2D) = "black" {}
+ }
+ SubShader
+ {
+ Tags { "RenderType"="Opaque" "Queue"="AlphaTest-1"}
+ LOD 100
+
+ Pass
+ {
+ Blend SrcAlpha OneMinusSrcAlpha
+ Cull Off
+
+ CGPROGRAM
+ #pragma vertex vert
+ #pragma fragment frag
+ #pragma multi_compile
+
+ #include "UnityCG.cginc"
+
+ struct appdata
+ {
+ float4 vertex : POSITION;
+ float2 uv : TEXCOORD0;
+ float3 normal : NORMAL;
+ };
+
+ struct v2f
+ {
+ float2 uv : TEXCOORD0;
+ float4 vertex : SV_POSITION;
+ };
+
+ Texture2D _MainTex;
+ SamplerState sampler_linear_repeat;
+ float4 _MainTex_ST;
+
+ v2f vert (appdata v)
+ {
+ v2f o;
+ o.vertex = UnityObjectToClipPos(v.vertex);
+ o.uv = 1.0 - v.uv;
+ return o;
+ }
+
+ fixed4 frag (v2f i) : SV_Target
+ {
+
+ fixed4 result = _MainTex.Sample(sampler_linear_repeat, i.uv);
+ result.a = 1.0;
+ return result;
+ }
+ ENDCG
+ }
+ }
+}