diff options
author | Kenneth Russel <[email protected]> | 2008-07-06 01:03:35 +0000 |
---|---|---|
committer | Kenneth Russel <[email protected]> | 2008-07-06 01:03:35 +0000 |
commit | 9df128e4eae30352d2ff440554ef067eef3ca793 (patch) | |
tree | 6e5b65a30e81998c5e76bf81a75314c4c6adae15 /src/java/com/sun/gluegen/opengl | |
parent | 649888422631e3bec8fa0f60afa99bc690992d71 (diff) |
Fixed Windows-specific problem with locally generated function pointer
typedefs where the calling convention was not specified. Provided new
LocalProcAddressCallingConvention directive to allow developer to
specify the calling convention on a per-function basis; used this in
gl-es1.cfg and gl-es2.cfg. Changed GLEmitter to force the calling
convention of the locally typedefed function pointers for OpenGL
function name unification to GL_APIENTRY, compatible with OpenGL ES 1
and OpenGL ES 2. Changed generated native glue code to #define
GL_APIENTRY appropriately on the desktop. Refactored custom C code.
git-svn-id: file:///usr/local/projects/SUN/JOGL/git-svn/../svn-server-sync/gluegen/branches/JOGL_2_SANDBOX@96 a78bb65f-1512-4460-ba86-f6dc96a7bf27
Diffstat (limited to 'src/java/com/sun/gluegen/opengl')
-rw-r--r-- | src/java/com/sun/gluegen/opengl/GLEmitter.java | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/src/java/com/sun/gluegen/opengl/GLEmitter.java b/src/java/com/sun/gluegen/opengl/GLEmitter.java index b9c4349..ae4d5ec 100644 --- a/src/java/com/sun/gluegen/opengl/GLEmitter.java +++ b/src/java/com/sun/gluegen/opengl/GLEmitter.java @@ -360,6 +360,9 @@ public class GLEmitter extends ProcAddressEmitter iter.remove(); // remove ARB function // make the function being dynamical fetched, due to it's dynamic naming scheme ((GLConfiguration)cfg).addForceProcAddressGen(uniName.getUni()); + // Make sure we produce the right calling convention for + // the typedefed function pointers on Windows + ((GLConfiguration)cfg).addLocalProcAddressCallingConvention(uniName.getUni(), "GL_APIENTRY"); } } } |