summaryrefslogtreecommitdiff
path: root/src/mesa/main
diff options
context:
space:
mode:
authorKristian Høgsberg <krh@bitplanet.net>2010-04-24 16:22:02 -0400
committerKristian Høgsberg <krh@bitplanet.net>2010-04-27 19:28:11 -0400
commit003433989597771bbb4f03cf678f5771c09606fd (patch)
treedd28a3e1cd3ca7e9ec632f669d3924a0ffd546fb /src/mesa/main
parent61d94dd207459e0c42d98c9d6eb7df5eabdfd8a4 (diff)
es: Prefix the get* functions with _es1/2 so they don't conflict
Diffstat (limited to 'src/mesa/main')
-rw-r--r--src/mesa/main/APIspec.xml14
-rw-r--r--src/mesa/main/APIspecutil.py7
-rw-r--r--src/mesa/main/es_generator.py4
-rw-r--r--src/mesa/main/get.h23
4 files changed, 41 insertions, 7 deletions
diff --git a/src/mesa/main/APIspec.xml b/src/mesa/main/APIspec.xml
index 7e77eb74d5..7ed303dab0 100644
--- a/src/mesa/main/APIspec.xml
+++ b/src/mesa/main/APIspec.xml
@@ -3939,15 +3939,15 @@
<function name="PixelStorei" template="PixelStore" gltype="GLint"/>
<function name="ReadPixels" template="ReadPixels"/>
- <function name="GetBooleanv" template="GetState" gltype="GLboolean"/>
+ <function name="GetBooleanv" default_prefix="_es1_" template="GetState" gltype="GLboolean"/>
<function name="GetClipPlanef" template="GetClipPlane" gltype="GLfloat"/>
<function name="GetClipPlanex" template="GetClipPlane" gltype="GLfixed"/>
<function name="GetError" template="GetError"/>
- <function name="GetFloatv" template="GetState" gltype="GLfloat"/>
- <function name="GetFixedv" template="GetState" gltype="GLfixed"/>
- <function name="GetIntegerv" template="GetState" gltype="GLint"/>
+ <function name="GetFloatv" default_prefix="_es1_" template="GetState" gltype="GLfloat"/>
+ <function name="GetFixedv" default_prefix="_es1_" template="GetState" gltype="GLfixed"/>
+ <function name="GetIntegerv" default_prefix="_es1_" template="GetState" gltype="GLint"/>
<function name="GetLightfv" template="GetLight" gltype="GLfloat"/>
<function name="GetLightxv" template="GetLight" gltype="GLfixed"/>
@@ -4173,10 +4173,10 @@
<function name="PixelStorei" template="PixelStore" gltype="GLint"/>
<function name="ReadPixels" template="ReadPixels"/>
- <function name="GetBooleanv" template="GetState" gltype="GLboolean"/>
+ <function name="GetBooleanv" default_prefix="_es2_" template="GetState" gltype="GLboolean"/>
<function name="GetError" template="GetError"/>
- <function name="GetFloatv" template="GetState" gltype="GLfloat"/>
- <function name="GetIntegerv" template="GetState" gltype="GLint"/>
+ <function name="GetFloatv" default_prefix="_es2_" template="GetState" gltype="GLfloat"/>
+ <function name="GetIntegerv" default_prefix="_es2_" template="GetState" gltype="GLint"/>
<function name="GetString" template="GetString"/>
diff --git a/src/mesa/main/APIspecutil.py b/src/mesa/main/APIspecutil.py
index 27a8fe8a6d..9e604bb84b 100644
--- a/src/mesa/main/APIspecutil.py
+++ b/src/mesa/main/APIspecutil.py
@@ -222,6 +222,13 @@ def Parameters(funcname):
return params
+def FunctionPrefix(funcname):
+ """Return function specific prefix."""
+ func = __functions[funcname]
+
+ return func.prefix
+
+
def FindParamIndex(params, paramname):
"""Find the index of a named parameter."""
for i in xrange(len(params)):
diff --git a/src/mesa/main/es_generator.py b/src/mesa/main/es_generator.py
index 1282a1c4f5..8f08a3a6f9 100644
--- a/src/mesa/main/es_generator.py
+++ b/src/mesa/main/es_generator.py
@@ -293,6 +293,7 @@ for funcName in keys:
passthroughFuncName = ""
passthroughDeclarationString = ""
passthroughCallString = ""
+ prefixOverride = None
variables = []
conversionCodeOutgoing = []
conversionCodeIncoming = []
@@ -311,6 +312,9 @@ for funcName in keys:
funcPrefix = "_es_"
aliasprefix = apiutil.AliasPrefix(funcName)
alias = apiutil.ConversionFunction(funcName)
+ prefixOverride = apiutil.FunctionPrefix(funcName)
+ if prefixOverride != "_mesa_":
+ aliasprefix = apiutil.FunctionPrefix(funcName)
if not alias:
# There may still be a Mesa alias for the function
if apiutil.Alias(funcName):
diff --git a/src/mesa/main/get.h b/src/mesa/main/get.h
index cc426fc0f6..47e549e396 100644
--- a/src/mesa/main/get.h
+++ b/src/mesa/main/get.h
@@ -71,4 +71,27 @@ _mesa_GetStringi(GLenum name, GLuint index);
extern GLenum GLAPIENTRY
_mesa_GetError( void );
+
+extern void GLAPIENTRY
+_es1_GetBooleanv( GLenum pname, GLboolean *params );
+
+extern void GLAPIENTRY
+_es1_GetFloatv( GLenum pname, GLfloat *params );
+
+extern void GLAPIENTRY
+_es1_GetIntegerv( GLenum pname, GLint *params );
+
+extern void GLAPIENTRY
+_es1_GetFixedv( GLenum pname, GLfixed *params );
+
+
+extern void GLAPIENTRY
+_es2_GetBooleanv( GLenum pname, GLboolean *params );
+
+extern void GLAPIENTRY
+_es2_GetFloatv( GLenum pname, GLfloat *params );
+
+extern void GLAPIENTRY
+_es2_GetIntegerv( GLenum pname, GLint *params );
+
#endif