On 21 October 2013 21:20, Rico Schüller kgbricola@web.de wrote:
As wgl.h is a bit out of date, it still uses the GL_MIRROR_CLAMP_TO_EDGE_ATI instead of GL_MIRROR_CLAMP_TO_EDGE (which is only available in headers for OpenGL 4.4).
The wine/wgl.h header is generated from the GL .spec files by dlls/opengl32/make_opengl, so in principle all you'd have to do would be to run that script to get the new constant. Unfortunately Khronos seems to have decided to no longer update the .spec files, since there are shiny new XML files now.
On 21.10.2013 21:51, Henri Verbeet wrote:
On 21 October 2013 21:20, Rico Schüller kgbricola@web.de wrote:
As wgl.h is a bit out of date, it still uses the GL_MIRROR_CLAMP_TO_EDGE_ATI instead of GL_MIRROR_CLAMP_TO_EDGE (which is only available in headers for OpenGL 4.4).
The wine/wgl.h header is generated from the GL .spec files by dlls/opengl32/make_opengl, so in principle all you'd have to do would be to run that script to get the new constant. Unfortunately Khronos seems to have decided to no longer update the .spec files, since there are shiny new XML files now.
Well, I did a small update for the script (it may need some improvements...). Please see the attached patch for make_opengl. I have several questions to this: 1. Is it the correct way to just change the script or do we prefer another way? 2. Is it fine to use XML::Simple as a dependency? 3. Do we need to support gles functions and enums? 4. Why was $pseudo_to_opengl used in the script?
Cheers Rico
On 26 October 2013 22:23, Rico Schüller kgbricola@web.de wrote:
Well, I did a small update for the script (it may need some improvements...). Please see the attached patch for make_opengl. I have several questions to this:
I didn't review the code very closely, but at first sight it looks like you have a couple of unrelated and whitespace only changes that should probably be in separate patches. I think there are also e.g. some comments that should be updated / removed. I can try to answer some of the questions, but ultimately it's up to Alexandre.
- Is it the correct way to just change the script or do we prefer
another way?
Seems fine to me. Although it's a bit annoying that Khronos doesn't seem to want to make any guarantees about the stability of the XML format.
- Is it fine to use XML::Simple as a dependency?
I think so, but I also think it's common to just put things like "use XML::Simple;" at the top of the file.
- Do we need to support gles functions and enums?
Not initially, but we may want to in the future.
- Why was $pseudo_to_opengl used in the script?
For mapping type. E.g. in gl.spec, ClearColor() takes 4 parameters of "ColorF", which is mapped to GLfloat in gl.tm. In the XML files that information is available as the "group" attribute, but we don't need it for our purposes. (See also https://cvs.khronos.org/svn/repos/ogl/trunk/doc/registry/public/api/readme.p...)