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 2 of 2

Thread: Shader and texture coordinates computation

  1. #1
    Intern Newbie
    Join Date
    Oct 2010
    Posts
    34

    Shader and texture coordinates computation

    Hello,

    I am discovering that fixed functions concerning textures are not used with shaders...
    I replicated glTexGen using the orange book to test : it works.

    But I have some beginner questions :

    1- Are gl_EyePlane* and gl_ObjectPlane* initialized by glTexGenfv(GL_*, GL_EYE_PLANE, vector) ?
    2- Do I have to send the GLenums used with GlTexEnv and GlTexGen to the shader to know how to manage the texture ?
    3- And a more general question : what are the fixed functions I can use with the shaders ?

    I did not find a simple answer to these questions.
    So I am interested in your advices or good links to read.

    Thanks

  2. #2
    Member Regular Contributor
    Join Date
    Jan 2012
    Location
    Australia
    Posts
    405
    The general trend in shaders is away from any automatically defined variables. I would recommend loading down the lastest glsl specs (http://www.opengl.org/documentation/glsl/) and having a look at what variables are still defined. Other variables may still be defined for legacy reasons but if you are just starting stick to thoses defined in the specs. You have to load all others in uniforms or shared buffers for yourself.

Posting Permissions

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