Results 1 to 3 of 3

Thread: glGetShaderSource() - didn't get my source code back.

  1. #1
    Junior Member
    Join Date
    Mar 2012
    Location
    Bavaria Germany
    Posts
    12

    glGetShaderSource() - didn't get my source code back.

    Hi, i'm new here on this board so i wanna say hello at first.

    I have some trouble with my shader. I like to compile the shader source and i get some weird things. First when i call the following method GetShaderiv....

    Code :
        GLint state=0;
     
        glCompileShader(*shader);
        glGetShaderiv(*shader, GL_COMPILE_STATUS, &state);
     
        glGetShaderiv(*shader, GL_INFO_LOG_LENGTH, &logLength);

    .. i got a zero in my state. But i didn't get some error messages from the compiler with the GL_INFO_LOG_LENGTH. I have a little trial project with the same code and there i get a '1' in the state.

    So i tried to read my shader source back from my shader and i get a really big string back. But not my shader code just some informations about my project with the project name, and with my name, and a lot of zeros and some other things.

    Code :
        glGetShaderSource(vertexShader, size, &sizei, code);

    Can you help me please with this? I searched on google but i didn't find something and i didn't find something in this message board too.

    Thanks a lot
    krikit

    Maybe some further information i use OpenGL ES 2.0 on my iPad 2.

  2. #2
    Junior Member
    Join Date
    Mar 2012
    Location
    Bavaria Germany
    Posts
    12

    Re: glGetShaderSource() - didn't get my source code back.

    I didn't get something from the shader. The string is the same like before. So I didn't get some wrong source but i didn't get any source code back. Maybe it's important for my question.

  3. #3
    Junior Member
    Join Date
    Mar 2012
    Location
    Bavaria Germany
    Posts
    12

    Re: glGetShaderSource() - didn't get my source code back.

    I've solved the problem.

    htx
    krikit

Similar Threads

  1. Replies: 0
    Last Post: 02-27-2013, 12:26 AM
  2. OpenVG source code
    By chandrasekhar in forum OpenVG and VGU
    Replies: 1
    Last Post: 10-24-2007, 11:04 PM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •