Part of the Khronos Group
OpenGL.org

The Industry's Foundation for High Performance Graphics

from games to virtual reality, mobile phones to supercomputers

Results 1 to 10 of 10

Thread: Standard Error Information

  1. #1
    Super Moderator Regular Contributor
    Join Date
    Jul 2001
    Posts
    401

    Standard Error Information

    Is the result always formatted the same way from GetInfoLog. I really need the line and row position where the actuall error occurs in a compilation

  2. #2
    Intern Contributor
    Join Date
    Sep 2001
    Location
    Marlboro MA
    Posts
    90

    Re: Standard Error Information

    The contents of the InfoLog are implementation dependent.

    But at least two implementations (ATI and 3DLabs) follow a convention of:

    prefixstring:__FILE__:__LINE__:'tokenstring':messa gestring

    For example, a vertex shader of:

    Code :
    #error "This is a test"
    void main ( void ) { gl_Position=ftransform(); }
    infolog will contain:

    Code :
    ERROR: 0:1 '' : This is a test
    -mr. bill

  3. #3
    Super Moderator Regular Contributor
    Join Date
    Jul 2001
    Posts
    401

    Re: Standard Error Information

    Ok. Thanx !

    Have you seen what NVidia uses ?

  4. #4
    Junior Member Regular Contributor
    Join Date
    Sep 2002
    Location
    Germany
    Posts
    205

    Re: Standard Error Information

    What is __FILE__? Does it resolve to the shader object ID?

  5. #5
    Advanced Member Frequent Contributor
    Join Date
    Nov 2002
    Location
    Latvia
    Posts
    626

    Re: Standard Error Information

    I really recomend you to use 3Dlabs GLSLvalidate tool, very handy (though locks file ) & you can forget about runtime errorlogs.

  6. #6
    Junior Member Newbie
    Join Date
    Oct 2002
    Location
    Atlanta
    Posts
    20

    Re: Standard Error Information

    GLSLValidate.exe also takes command line parameters.

    You can use /v <vertex shader> or /f <fragment shader>

    ex: 'glslvalidate.exe /v shader.vert'

    This will check the shader just like the GUI does, but instead of reporting the errors, it stores them all in log files.

    They are vertex.log and fragment.log respectively.

  7. #7
    Administrator Regular Contributor
    Join Date
    Aug 2001
    Location
    NVIDIA, Fort Collins, CO, USA
    Posts
    184

    Re: Standard Error Information

    Originally posted by Anitox:
    GLSLValidate.exe also takes command line parameters.

    You can use /v <vertex shader> or /f <fragment shader>

    ex: 'glslvalidate.exe /v shader.vert'

    This will check the shader just like the GUI does, but instead of reporting the errors, it stores them all in log files.

    They are vertex.log and fragment.log respectively.
    Right! Just to add to that, glslvalidate.exe will aso return error codes. Thus you could use it in a batch script, if you want.

    Barthold

  8. #8
    Super Moderator Regular Contributor
    Join Date
    Jul 2001
    Posts
    401

    Re: Standard Error Information

    I am really looking for the runtime info as i want to validate if a certain script really is a glsl script or not.

    Is there a BNF for GLSL ? or simillar

  9. #9
    Super Moderator Regular Contributor
    Join Date
    Jul 2001
    Posts
    401

    Re: Standard Error Information

    Is there a way to tell to tell if a shader run in HW7SW by a query to the shader..

  10. #10
    Junior Member Newbie
    Join Date
    Aug 2005
    Posts
    2

    Re: Standard Error Information

    Looks like nVidia's InfoLog format is different from ATI & 3Dlabs. They put the line number within parenthesis at the beginning. eg,

    (line number) : <error message>

Posting Permissions

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