diff options
| author | jpbruyere <jp.bruyere@hotmail.com> | 2015-10-21 22:00:20 +0200 |
|---|---|---|
| committer | jpbruyere <jp.bruyere@hotmail.com> | 2015-10-21 22:00:20 +0200 |
| commit | 8099f1775b6d9083e04b2f39700c2e90a0724aca (patch) | |
| tree | a145c7f1ec8aeb4aade2ffae4e2c50771ef9ec86 /src/OpenGL/GLBackend/ClipShader.cs | |
| parent | f31ffd683210c50b777dce4e76d0d9912ca925a8 (diff) | |
glbackend tests, copy first try from hg reposglbackend
Diffstat (limited to 'src/OpenGL/GLBackend/ClipShader.cs')
| -rw-r--r-- | src/OpenGL/GLBackend/ClipShader.cs | 40 |
1 files changed, 40 insertions, 0 deletions
diff --git a/src/OpenGL/GLBackend/ClipShader.cs b/src/OpenGL/GLBackend/ClipShader.cs new file mode 100644 index 00000000..a805716c --- /dev/null +++ b/src/OpenGL/GLBackend/ClipShader.cs @@ -0,0 +1,40 @@ +using System; +using OpenTK.Graphics.OpenGL; + +namespace go.GLBackend +{ + public class ClipShader : Shader + { + public ClipShader () + { + vertSource = @" + #version 130 + + precision highp float; + + uniform mat4 projection_matrix; + uniform mat4 modelview_matrix; + + in vec2 in_position; + + void main(void) + { + gl_Position = projection_matrix * modelview_matrix * vec4(in_position,0, 1); + }"; + + fragSource = @" + #version 130 + precision highp float; + + out vec4 out_frag_color; + + void main(void) + { + out_frag_color = vec4(1.0,1.0,1.0,1.0); + }"; + + Compile (); + } + } +} + |