2023-04-03 11:04:31 +08:00

51 lines
888 B
Plaintext

Shader "BF/PostEffect/BlitCopy"
{
Properties
{
_MainTex("MainTex", 2D) = "white"{}
}
SubShader
{
CGINCLUDE
#include "UnityCG.cginc"
sampler2D _MainTex;
struct a2v
{
float4 pos : POSITION;
half2 uv : TEXCOORD0;
};
struct v2f
{
float4 pos : SV_POSITION;
half2 uv : TEXCOORD0;
};
v2f vert(a2v v)
{
v2f o;
o.pos = UnityObjectToClipPos(v.pos);
o.uv = v.uv;
return o;
}
fixed4 frag(v2f f) : SV_TARGET
{
fixed4 o;
o = tex2D(_MainTex, f.uv);
return o;
}
ENDCG
Pass
{
CGPROGRAM
#pragma vertex vert
#pragma fragment frag
ENDCG
}
}
}