aboutsummaryrefslogtreecommitdiffstats
path: root/LibOVR/Src/CAPI/Shaders/Distortion_ps.psh
diff options
context:
space:
mode:
authorSven Gothel <[email protected]>2014-06-19 17:08:45 +0200
committerSven Gothel <[email protected]>2014-06-19 17:08:45 +0200
commit33385ba1bb04682cef372adb0cd9f63b1fe55ca7 (patch)
tree30858bcf355f78b0e69c0f9a17d2fd28e7ed926a /LibOVR/Src/CAPI/Shaders/Distortion_ps.psh
parentd9a584844a60542519d813b5dc1a62428f14a0ae (diff)
Merge OculusSDK 0.3.2 Windows Source Code
Diffstat (limited to 'LibOVR/Src/CAPI/Shaders/Distortion_ps.psh')
-rw-r--r--LibOVR/Src/CAPI/Shaders/Distortion_ps.psh9
1 files changed, 9 insertions, 0 deletions
diff --git a/LibOVR/Src/CAPI/Shaders/Distortion_ps.psh b/LibOVR/Src/CAPI/Shaders/Distortion_ps.psh
new file mode 100644
index 0000000..3e8b87f
--- /dev/null
+++ b/LibOVR/Src/CAPI/Shaders/Distortion_ps.psh
@@ -0,0 +1,9 @@
+Texture2D Texture : register(t0);
+SamplerState Linear : register(s0);
+
+float4 main(in float4 oPosition : SV_Position, in float4 oColor : COLOR,
+ in float3 oTexCoord0 : TEXCOORD0) : SV_Target
+{
+ float3 Result = Texture.SampleLevel(Linear, oTexCoord0.xy, 0.0).rgb;
+ return float4(Result.r * oColor.r, Result.g * oColor.g, Result.b * oColor.b, 1.0);
+}