On 16 October 2012 11:17, Ian Romanick <span dir="ltr"><<a href="mailto:idr@freedesktop.org" target="_blank">idr@freedesktop.org</a>></span> wrote:<br><div class="gmail_quote"><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
From: Ian Romanick <<a href="mailto:ian.d.romanick@intel.com">ian.d.romanick@intel.com</a>><br>
<br>
This test actually depends on FEATURE_ES1 because<br>
_mesa_create_exec_table_es1 doesn't exist without it.<br></blockquote><div><br>Reviewed-by: Paul Berry <<a href="mailto:stereotype441@gmail.com">stereotype441@gmail.com</a>><br> </div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
<br>
Signed-off-by: Ian Romanick <<a href="mailto:ian.d.romanick@intel.com">ian.d.romanick@intel.com</a>><br>
Cc: Paul Berry <<a href="mailto:stereotype441@gmail.com">stereotype441@gmail.com</a>><br>
---<br>
src/mesa/main/tests/dispatch_sanity.cpp | 207 ++++++++++++++++++++++++++++++++<br>
1 file changed, 207 insertions(+)<br>
<br>
diff --git a/src/mesa/main/tests/dispatch_sanity.cpp b/src/mesa/main/tests/dispatch_sanity.cpp<br>
index a1d0223..b4de515 100644<br>
--- a/src/mesa/main/tests/dispatch_sanity.cpp<br>
+++ b/src/mesa/main/tests/dispatch_sanity.cpp<br>
@@ -74,6 +74,11 @@ struct function {<br>
<br>
extern const struct function gles2_functions_possible[];<br>
<br>
+#if FEATURE_ES1<br>
+extern "C" _glapi_table *_mesa_create_exec_table_es1(void);<br>
+extern const struct function gles11_functions_possible[];<br>
+#endif /* FEATURE_ES1 */<br>
+<br>
class DispatchSanity_test : public ::testing::Test {<br>
public:<br>
virtual void SetUp();<br>
@@ -138,6 +143,14 @@ TEST_F(DispatchSanity_test, GLES2)<br>
validate_functions((_glapi_proc *) ctx.Exec, gles2_functions_possible);<br>
}<br>
<br>
+#if FEATURE_ES1<br>
+TEST_F(DispatchSanity_test, GLES11)<br>
+{<br>
+ _glapi_proc *exec = (_glapi_proc *) _mesa_create_exec_table_es1();<br>
+ validate_functions(exec, gles11_functions_possible);<br>
+}<br>
+#endif /* FEATURE_ES1 */<br>
+<br>
const struct function gles2_functions_possible[] = {<br>
{ "glActiveTexture", _gloffset_ActiveTextureARB },<br>
{ "glAttachShader", -1 },<br>
@@ -304,3 +317,197 @@ const struct function gles2_functions_possible[] = {<br>
{ "glViewport", _gloffset_Viewport },<br>
{ NULL, -1 }<br>
};<br>
+<br>
+#if FEATURE_ES1<br>
+const struct function gles11_functions_possible[] = {<br>
+ { "glActiveTexture", _gloffset_ActiveTextureARB },<br>
+ { "glAlphaFunc", _gloffset_AlphaFunc },<br>
+ { "glAlphaFuncx", -1 },<br>
+ { "glBindBuffer", -1 },<br>
+ { "glBindFramebufferOES", -1 },<br>
+ { "glBindRenderbufferOES", -1 },<br>
+ { "glBindTexture", _gloffset_BindTexture },<br>
+ { "glBlendEquationOES", _gloffset_BlendEquation },<br>
+ { "glBlendEquationSeparateOES", -1 },<br>
+ { "glBlendFunc", _gloffset_BlendFunc },<br>
+ { "glBlendFuncSeparateOES", -1 },<br>
+ { "glBufferData", -1 },<br>
+ { "glBufferSubData", -1 },<br>
+ { "glCheckFramebufferStatusOES", -1 },<br>
+ { "glClear", _gloffset_Clear },<br>
+ { "glClearColor", _gloffset_ClearColor },<br>
+ { "glClearColorx", -1 },<br>
+ { "glClearDepthf", -1 },<br>
+ { "glClearDepthx", -1 },<br>
+ { "glClearStencil", _gloffset_ClearStencil },<br>
+ { "glClientActiveTexture", _gloffset_ClientActiveTextureARB },<br>
+ { "glClipPlanef", -1 },<br>
+ { "glClipPlanex", -1 },<br>
+ { "glColor4f", _gloffset_Color4f },<br>
+ { "glColor4ub", _gloffset_Color4ub },<br>
+ { "glColor4x", -1 },<br>
+ { "glColorMask", _gloffset_ColorMask },<br>
+ { "glColorPointer", _gloffset_ColorPointer },<br>
+ { "glCompressedTexImage2D", -1 },<br>
+ { "glCompressedTexSubImage2D", -1 },<br>
+ { "glCopyTexImage2D", _gloffset_CopyTexImage2D },<br>
+ { "glCopyTexSubImage2D", _gloffset_CopyTexSubImage2D },<br>
+ { "glCullFace", _gloffset_CullFace },<br>
+ { "glDeleteBuffers", -1 },<br>
+ { "glDeleteFramebuffersOES", -1 },<br>
+ { "glDeleteRenderbuffersOES", -1 },<br>
+ { "glDeleteTextures", _gloffset_DeleteTextures },<br>
+ { "glDepthFunc", _gloffset_DepthFunc },<br>
+ { "glDepthMask", _gloffset_DepthMask },<br>
+ { "glDepthRangef", -1 },<br>
+ { "glDepthRangex", -1 },<br>
+ { "glDisable", _gloffset_Disable },<br>
+ { "glDisableClientState", _gloffset_DisableClientState },<br>
+ { "glDrawArrays", _gloffset_DrawArrays },<br>
+ { "glDrawElements", _gloffset_DrawElements },<br>
+ { "glDrawTexfOES", -1 },<br>
+ { "glDrawTexfvOES", -1 },<br>
+ { "glDrawTexiOES", -1 },<br>
+ { "glDrawTexivOES", -1 },<br>
+ { "glDrawTexsOES", -1 },<br>
+ { "glDrawTexsvOES", -1 },<br>
+ { "glDrawTexxOES", -1 },<br>
+ { "glDrawTexxvOES", -1 },<br>
+ { "glEGLImageTargetRenderbufferStorageOES", -1 },<br>
+ { "glEGLImageTargetTexture2DOES", -1 },<br>
+ { "glEnable", _gloffset_Enable },<br>
+ { "glEnableClientState", _gloffset_EnableClientState },<br>
+ { "glFinish", _gloffset_Finish },<br>
+ { "glFlush", _gloffset_Flush },<br>
+ { "glFogf", _gloffset_Fogf },<br>
+ { "glFogfv", _gloffset_Fogfv },<br>
+ { "glFogx", -1 },<br>
+ { "glFogxv", -1 },<br>
+ { "glFramebufferRenderbufferOES", -1 },<br>
+ { "glFramebufferTexture2DOES", -1 },<br>
+ { "glFrontFace", _gloffset_FrontFace },<br>
+ { "glFrustumf", -1 },<br>
+ { "glFrustumx", -1 },<br>
+ { "glGenBuffers", -1 },<br>
+ { "glGenFramebuffersOES", -1 },<br>
+ { "glGenRenderbuffersOES", -1 },<br>
+ { "glGenTextures", _gloffset_GenTextures },<br>
+ { "glGenerateMipmapOES", -1 },<br>
+ { "glGetBooleanv", _gloffset_GetBooleanv },<br>
+ { "glGetBufferParameteriv", -1 },<br>
+ { "glGetBufferPointervOES", -1 },<br>
+ { "glGetClipPlanef", -1 },<br>
+ { "glGetClipPlanex", -1 },<br>
+ { "glGetError", _gloffset_GetError },<br>
+ { "glGetFixedv", -1 },<br>
+ { "glGetFloatv", _gloffset_GetFloatv },<br>
+ { "glGetFramebufferAttachmentParameterivOES", -1 },<br>
+ { "glGetIntegerv", _gloffset_GetIntegerv },<br>
+ { "glGetLightfv", _gloffset_GetLightfv },<br>
+ { "glGetLightxv", -1 },<br>
+ { "glGetMaterialfv", _gloffset_GetMaterialfv },<br>
+ { "glGetMaterialxv", -1 },<br>
+ { "glGetPointerv", _gloffset_GetPointerv },<br>
+ { "glGetRenderbufferParameterivOES", -1 },<br>
+ { "glGetString", _gloffset_GetString },<br>
+ { "glGetTexEnvfv", _gloffset_GetTexEnvfv },<br>
+ { "glGetTexEnviv", _gloffset_GetTexEnviv },<br>
+ { "glGetTexEnvxv", -1 },<br>
+ { "glGetTexGenfvOES", _gloffset_GetTexGenfv },<br>
+ { "glGetTexGenivOES", _gloffset_GetTexGeniv },<br>
+ { "glGetTexGenxvOES", -1 },<br>
+ { "glGetTexParameterfv", _gloffset_GetTexParameterfv },<br>
+ { "glGetTexParameteriv", _gloffset_GetTexParameteriv },<br>
+ { "glGetTexParameterxv", -1 },<br>
+ { "glHint", _gloffset_Hint },<br>
+ { "glIsBuffer", -1 },<br>
+ { "glIsEnabled", _gloffset_IsEnabled },<br>
+ { "glIsFramebufferOES", -1 },<br>
+ { "glIsRenderbufferOES", -1 },<br>
+ { "glIsTexture", _gloffset_IsTexture },<br>
+ { "glLightModelf", _gloffset_LightModelf },<br>
+ { "glLightModelfv", _gloffset_LightModelfv },<br>
+ { "glLightModelx", -1 },<br>
+ { "glLightModelxv", -1 },<br>
+ { "glLightf", _gloffset_Lightf },<br>
+ { "glLightfv", _gloffset_Lightfv },<br>
+ { "glLightx", -1 },<br>
+ { "glLightxv", -1 },<br>
+ { "glLineWidth", _gloffset_LineWidth },<br>
+ { "glLineWidthx", -1 },<br>
+ { "glLoadIdentity", _gloffset_LoadIdentity },<br>
+ { "glLoadMatrixf", _gloffset_LoadMatrixf },<br>
+ { "glLoadMatrixx", -1 },<br>
+ { "glLogicOp", _gloffset_LogicOp },<br>
+ { "glMapBufferOES", -1 },<br>
+ { "glMaterialf", _gloffset_Materialf },<br>
+ { "glMaterialfv", _gloffset_Materialfv },<br>
+ { "glMaterialx", -1 },<br>
+ { "glMaterialxv", -1 },<br>
+ { "glMatrixMode", _gloffset_MatrixMode },<br>
+ { "glMultMatrixf", _gloffset_MultMatrixf },<br>
+ { "glMultMatrixx", -1 },<br>
+ { "glMultiDrawArraysEXT", -1 },<br>
+ { "glMultiDrawElementsEXT", -1 },<br>
+ { "glMultiTexCoord4f", _gloffset_MultiTexCoord4fARB },<br>
+ { "glMultiTexCoord4x", -1 },<br>
+ { "glNormal3f", _gloffset_Normal3f },<br>
+ { "glNormal3x", -1 },<br>
+ { "glNormalPointer", _gloffset_NormalPointer },<br>
+ { "glOrthof", -1 },<br>
+ { "glOrthox", -1 },<br>
+ { "glPixelStorei", _gloffset_PixelStorei },<br>
+ { "glPointParameterf", -1 },<br>
+ { "glPointParameterfv", -1 },<br>
+ { "glPointParameterx", -1 },<br>
+ { "glPointParameterxv", -1 },<br>
+ { "glPointSize", _gloffset_PointSize },<br>
+ { "glPointSizePointerOES", -1 },<br>
+ { "glPointSizex", -1 },<br>
+ { "glPolygonOffset", _gloffset_PolygonOffset },<br>
+ { "glPolygonOffsetx", -1 },<br>
+ { "glPopMatrix", _gloffset_PopMatrix },<br>
+ { "glPushMatrix", _gloffset_PushMatrix },<br>
+ { "glQueryMatrixxOES", -1 },<br>
+ { "glReadPixels", _gloffset_ReadPixels },<br>
+ { "glRenderbufferStorageOES", -1 },<br>
+ { "glRotatef", _gloffset_Rotatef },<br>
+ { "glRotatex", -1 },<br>
+ { "glSampleCoverage", -1 },<br>
+ { "glSampleCoveragex", -1 },<br>
+ { "glScalef", _gloffset_Scalef },<br>
+ { "glScalex", -1 },<br>
+ { "glScissor", _gloffset_Scissor },<br>
+ { "glShadeModel", _gloffset_ShadeModel },<br>
+ { "glStencilFunc", _gloffset_StencilFunc },<br>
+ { "glStencilMask", _gloffset_StencilMask },<br>
+ { "glStencilOp", _gloffset_StencilOp },<br>
+ { "glTexCoordPointer", _gloffset_TexCoordPointer },<br>
+ { "glTexEnvf", _gloffset_TexEnvf },<br>
+ { "glTexEnvfv", _gloffset_TexEnvfv },<br>
+ { "glTexEnvi", _gloffset_TexEnvi },<br>
+ { "glTexEnviv", _gloffset_TexEnviv },<br>
+ { "glTexEnvx", -1 },<br>
+ { "glTexEnvxv", -1 },<br>
+ { "glTexGenfOES", _gloffset_TexGenf },<br>
+ { "glTexGenfvOES", _gloffset_TexGenfv },<br>
+ { "glTexGeniOES", _gloffset_TexGeni },<br>
+ { "glTexGenivOES", _gloffset_TexGeniv },<br>
+ { "glTexGenxOES", -1 },<br>
+ { "glTexGenxvOES", -1 },<br>
+ { "glTexImage2D", _gloffset_TexImage2D },<br>
+ { "glTexParameterf", _gloffset_TexParameterf },<br>
+ { "glTexParameterfv", _gloffset_TexParameterfv },<br>
+ { "glTexParameteri", _gloffset_TexParameteri },<br>
+ { "glTexParameteriv", _gloffset_TexParameteriv },<br>
+ { "glTexParameterx", -1 },<br>
+ { "glTexParameterxv", -1 },<br>
+ { "glTexSubImage2D", _gloffset_TexSubImage2D },<br>
+ { "glTranslatef", _gloffset_Translatef },<br>
+ { "glTranslatex", -1 },<br>
+ { "glUnmapBufferOES", -1 },<br>
+ { "glVertexPointer", _gloffset_VertexPointer },<br>
+ { "glViewport", _gloffset_Viewport },<br>
+ { NULL, -1 }<br>
+};<br>
+#endif /* FEATURE_ES1 */<br>
<span class="HOEnZb"><font color="#888888">--<br>
1.7.11.4<br>
<br>
</font></span></blockquote></div><br>