test-shader: Fix the edge-detect shader
cogl_text_coord_in in a array to access the texture units. In this case we want to sample texture unit 0, where the texture is.
This commit is contained in:
parent
38e527a3cf
commit
b922ac6059
@ -144,7 +144,7 @@ static ShaderSource shaders[]=
|
|||||||
FRAGMENT_SHADER_VARS
|
FRAGMENT_SHADER_VARS
|
||||||
"float get_avg_rel(sampler2D texB, float dx, float dy)"
|
"float get_avg_rel(sampler2D texB, float dx, float dy)"
|
||||||
"{"
|
"{"
|
||||||
" vec4 colorB = texture2D (texB, cogl_tex_coord_in.st + vec2(dx, dy));"
|
" vec4 colorB = texture2D (texB, cogl_tex_coord_in[0].st + vec2(dx, dy));"
|
||||||
" return (colorB.r + colorB.g + colorB.b) / 3.0;"
|
" return (colorB.r + colorB.g + colorB.b) / 3.0;"
|
||||||
"}"
|
"}"
|
||||||
FRAGMENT_SHADER_BEGIN
|
FRAGMENT_SHADER_BEGIN
|
||||||
|
Loading…
x
Reference in New Issue
Block a user