summaryrefslogtreecommitdiffstats
path: root/ui/surface/accelerated_surface_transformer_win.hlsl
diff options
context:
space:
mode:
Diffstat (limited to 'ui/surface/accelerated_surface_transformer_win.hlsl')
-rw-r--r--ui/surface/accelerated_surface_transformer_win.hlsl28
1 files changed, 28 insertions, 0 deletions
diff --git a/ui/surface/accelerated_surface_transformer_win.hlsl b/ui/surface/accelerated_surface_transformer_win.hlsl
new file mode 100644
index 0000000..0bd6fda
--- /dev/null
+++ b/ui/surface/accelerated_surface_transformer_win.hlsl
@@ -0,0 +1,28 @@
+// Copyright (c) 2012 The Chromium Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+// @gyp_namespace(ui_surface)
+// Compiles into C++ as 'accelerated_surface_transformer_win_hlsl_compiled.h'
+
+struct Vertex {
+ float4 position : POSITION;
+ float2 texCoord : TEXCOORD0;
+};
+
+texture t;
+sampler s;
+
+// @gyp_compile(vs_2_0, vsOneTexture)
+//
+// Passes a position and texture coordinate to the pixel shader.
+Vertex vsOneTexture(Vertex input) {
+ return input;
+};
+
+// @gyp_compile(ps_2_0, psOneTexture)
+//
+// Samples a texture at the given texture coordinate and returns the result.
+float4 psOneTexture(float2 texCoord : TEXCOORD0) : COLOR0 {
+ return tex2D(s, texCoord);
+};