Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Error messages show wrong line number #21

Closed
medakk opened this issue May 17, 2018 · 2 comments
Closed

Error messages show wrong line number #21

medakk opened this issue May 17, 2018 · 2 comments
Labels

Comments

@medakk
Copy link

medakk commented May 17, 2018

The line number mentioned in the error is not the same line where the error actually is.

Example:

#ifdef GL_ES
precision mediump float;
#endif

#define PI 3.14159265359

void main() {
    vec2 st = gl_FragCoord.xy/iResolution.xy;
    vec2 origin = vec2(0.5, 0.5);
    vec2 d = distance(st, origin);

    float r = d;

    float g = r;
    float b = r;

    vec3 color = vec3(r, g, b);

    gl_FragColor = vec4(color,1.0);
}

Error:

Shader failed to compile

Line 97: '=' : dimension mismatch
Line 97: '=' : cannot convert from 'mediump float' to 'mediump 2-component vector of float'
Line 99: '=' : dimension mismatch
Line 99: '=' : cannot convert from 'mediump 2-component vector of float' to 'mediump float'

image

@stevensona stevensona added the bug label May 22, 2018
@Malacath-92
Copy link
Collaborator

Is this fixed for you in the most recent version?

@medakk
Copy link
Author

medakk commented Jul 3, 2018

Yes, it works now.

Thanks!

@medakk medakk closed this as completed Jul 3, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

3 participants