Home Game Development GLSL Shader r GL_INVALID_OPERATION from glUniform1f error with textureSize

GLSL Shader r GL_INVALID_OPERATION from glUniform1f error with textureSize

0
GLSL Shader r GL_INVALID_OPERATION from glUniform1f error with textureSize

[ad_1]

For debug functions I’ve minimised the shader to the next:

various vec4 v_color;
various vec2 v_texCoords;

uniform sampler2D u_texture;

void most important() {
    // ivec2 dimension = textureSize(u_texture, 0);//throws error if this line is enabled

    gl_FragColor = v_color * texture2D(u_texture, v_texCoords);
}

So do not thoughts what it really does for the time being. With the road commented out it really works wonderful, and different shaders work wonderful, however with the road in I get the errors:

[GLProfiler] Error GL_INVALID_OPERATION from glUniform2f

[GLProfiler] Error GL_INVALID_OPERATION from glUniform1f

[GLProfiler] Error GL_INVALID_OPERATION from glUniformMatrix4fv

[ad_2]

LEAVE A REPLY

Please enter your comment!
Please enter your name here