Part of the Khronos Group

The Industry's Foundation for High Performance Graphics

from games to virtual reality, mobile phones to supercomputers

Results 1 to 2 of 2

Thread: Distinction between (default UB) uniform locations and uniform indices

  1. #1
    Junior Member Newbie
    Join Date
    Mar 2013

    Distinction between (default UB) uniform locations and uniform indices

    Why is there additional notion of uniform locations and why does the API not use the uniform index of the uniforms
    in the default UB to address them - which would then be consistent for both the named UBs' Us and the default UB's

  2. #2
    Senior Member OpenGL Lord
    Join Date
    May 2009
    Because 3D Labs wanted it that way.

    I would suspect that their logic was that uniform locations could be byte offsets into internal structures or memory address or some such. That is, the location could be some data which is related to the location of the uniform's data.

    The index is just an identifier for a particular uniform.

    At this point, it's clear that 3D Labs's reasoning was simply not practical. Otherwise, it wouldn't be possible to have this specification. But that was the original idea. So now we're stuck with this two identifier system: one for setting the data and one for querying info about it.

Posting Permissions

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