Cleaned up and commented version.
This commit is contained in:
@@ -0,0 +1,40 @@
|
||||
Shader "Hidden/GazeOverlay"
|
||||
{
|
||||
SubShader
|
||||
{
|
||||
Tags { "RenderType" = "Opaque" "RenderPipeline" = "UniversalPipeline" }
|
||||
pass
|
||||
{
|
||||
Name "GazeOverlayPass"
|
||||
ZTest Always
|
||||
ZWrite Off
|
||||
Blend SrcAlpha OneMinusSrcAlpha
|
||||
|
||||
HLSLPROGRAM
|
||||
#pragma vertex VertFullScreenTriangle
|
||||
#pragma fragment frag
|
||||
|
||||
|
||||
#include "Packages/com.unity.render-pipelines.universal/ShaderLibrary/Core.hlsl"
|
||||
|
||||
struct Varyings
|
||||
{
|
||||
float4 positionHCS : SV_POSITION;
|
||||
float2 texcoord : TEXCOORD0;
|
||||
};
|
||||
|
||||
Varyings VertFullScreenTriangle (uint vertexID : SV_VERTEXID)
|
||||
{
|
||||
Varyings o;
|
||||
o.positionHCS = GetFullScreenTriangleVertexPosition(vertexID);
|
||||
o.texcoord = GetFullScreenTriangleTexCoord(vertexID);
|
||||
return o;
|
||||
}
|
||||
|
||||
#include "GazeOverlayPass.hlsl"
|
||||
|
||||
ENDHLSL
|
||||
}
|
||||
}
|
||||
FallBack Off
|
||||
}
|
||||
Reference in New Issue
Block a user