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

Thread: What is "application-defined clip distance"?

  1. #1
    Intern Contributor
    Join Date
    Dec 2010
    Posts
    57

    What is "application-defined clip distance"?

    I ran accross this symbolic constant in the glGet() spec:
    "GL_MAX_CLIP_DISTANCES
    params returns one value, the maximum number of application-defined clipping distances. The value must be at least 8. symbolic constant that "

    "GL_MAX_CLIP_DISTANCES" I cannot find explained in any documentation online.

    Does anyone know what it is or what a clip distance is exactly?

  2. #2
    Advanced Member Frequent Contributor
    Join Date
    Mar 2009
    Location
    Karachi, Pakistan
    Posts
    810

    Re: What is "application-defined clip distance"?

    It means that you can define at max 8 clipping planes in your applications.
    Regards,
    Mobeen

  3. #3
    Senior Member OpenGL Pro Aleksandar's Avatar
    Join Date
    Jul 2009
    Posts
    1,214

    Re: What is "application-defined clip distance"?

    How comes that you haven't found explanation for the GL_MAX_CLIP_DISTANCES?

    Quote Originally Posted by OpenGL Shadin Language 3rd Ed. pg.242
    GL_MAX_CLIP_DISTANCES Defines the number of clip distances that are available per program. The minimum legal value is 8.
    The user clipping is an extremely useful feature. gl_ClipDistance[i] - are values written by vertex shader in order to determine the distance from the clipping plane. The value itself is not important but the sign of that value.

  4. #4
    Intern Contributor
    Join Date
    Dec 2010
    Posts
    57

    Re: What is "application-defined clip distance"?

    Thank you Aleksander I did not know about the gl_ClipDistance[] built-in variable.
    All I knew was that the near & far clip planes were a result of setting up a projection matrix.

Posting Permissions

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