Khronos Public Bugzilla
Bug 465 - gl.spec entry for ShaderSource is incorrect
Summary: gl.spec entry for ShaderSource is incorrect
Alias: None
Product: OpenGL
Classification: Unclassified
Component: Registry (show other bugs)
Version: 4.1
Hardware: All All
: P3 normal
Target Milestone: ---
Assignee: Jon Leech
QA Contact:
Depends on:
Reported: 2011-04-22 03:38 PDT by Stephan Houben
Modified: 2013-06-13 03:51 PDT (History)
0 users

See Also:


Note You need to log in before you can comment on or make changes to this bug.
Description Stephan Houben 2011-04-22 03:38:59 PDT
gl.spec contains this for ShaderSource

ShaderSource(shader, count, string, length)
        return          void
        param           shader          UInt32 in value
        param           count           SizeI in value
        param           string          CharPointer in array [count]
        param           length          Int32 in array [1]

However, according to the docs:
"If length is a value other than NULL, it points to an array containing
a string length for each of the corresponding elements of

So the array length of [1] is wrong, it should be [count]:

        param           length          Int32 in array [count]
Comment 1 Jon Leech 2013-06-13 03:51:49 PDT
Khronos has moved to a new XML API Registry and headers generated
from that; see

We don't plan to maintain the old .spec files going forward and this
problem can't fixed in the XML because XML doesn't include this
information - it simply uses the C prototype for argument types instead
of the language-independent type syntax in .spec. While we could add
array length information to the XML files, and I'm open to discussing
it if this is something you require and want to migrate to using the
XML files, the existing .spec array length
information is often inaccurate or vague (describing array lengths
as some unknown function of other parameters) and this isn't a simple
thing to actually get right for the entire registry.