diff options
author | Wolfgang Draxinger <Wolfgang.Draxinger@draxit.de> | 2014-10-07 03:38:55 +0200 |
---|---|---|
committer | Wolfgang Draxinger <Wolfgang.Draxinger@draxit.de> | 2014-10-07 03:38:55 +0200 |
commit | 1e387fc8eee4925616967edd26de0ee416dbce3f (patch) | |
tree | f6be0b844c724d6c4891f325912bb4f3f2f26c4b /samples/OpenGL/texture_distortion_glsl | |
parent | 3ce7214d2300e2769667649625d160dcdc01499c (diff) | |
parent | b62b7bf28ec0069e6f460fa0f07b64a0dba72557 (diff) | |
download | codesamples-1e387fc8eee4925616967edd26de0ee416dbce3f.tar.gz codesamples-1e387fc8eee4925616967edd26de0ee416dbce3f.tar.bz2 |
Merge branch 'master' of git://github.com/datenwolf/codesamples
Diffstat (limited to 'samples/OpenGL/texture_distortion_glsl')
-rw-r--r-- | samples/OpenGL/texture_distortion_glsl/texture_distortion_glsl.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/samples/OpenGL/texture_distortion_glsl/texture_distortion_glsl.c b/samples/OpenGL/texture_distortion_glsl/texture_distortion_glsl.c index 7742746..437dd92 100644 --- a/samples/OpenGL/texture_distortion_glsl/texture_distortion_glsl.c +++ b/samples/OpenGL/texture_distortion_glsl/texture_distortion_glsl.c @@ -43,7 +43,7 @@ static const GLchar *fragment_shader_source = " float ts = gl_TexCoord[0].s;\n" " vec2 mod_texcoord = gl_TexCoord[0].st*vec2(1., 2.) + vec2(0, -0.5 + 0.5*sin(T + 1.5*ts*pi));\n" " if( mod_texcoord.t < 0. || mod_texcoord.t > 1. ) { discard; }\n" -" gl_FragColor = -texture2D(texCMYK, mod_texcoord) + texture2D(texRGB, gl_TexCoord[0].st);\n" +" gl_FragColor.rgb = -texture2D(texCMYK, mod_texcoord).xyz + texture2D(texRGB, gl_TexCoord[0].st).xyz;\n" "}\n\0"; GLuint shaderFragment = 0; |