diff --git a/tools/emulator/opengl/system/GLESv2_enc/GL2Encoder.cpp b/tools/emulator/opengl/system/GLESv2_enc/GL2Encoder.cpp index b0a2e722c..bdb9a429d 100644 --- a/tools/emulator/opengl/system/GLESv2_enc/GL2Encoder.cpp +++ b/tools/emulator/opengl/system/GLESv2_enc/GL2Encoder.cpp @@ -26,6 +26,7 @@ GL2Encoder::GL2Encoder(IOStream *stream) : gl2_encoder_context_t(stream) m_glGetVertexAttribfv_enc = set_glGetVertexAttribfv(s_glGetVertexAttribfv); m_glGetVertexAttribPointerv = set_glGetVertexAttribPointerv(s_glGetVertexAttribPointerv); set_glShaderSource(s_glShaderSource); + set_glFinish(s_glFinish); } GL2Encoder::~GL2Encoder() @@ -335,3 +336,10 @@ void GL2Encoder::s_glShaderSource(void *self, GLuint shader, GLsizei count, cons ctx->glShaderString(ctx, shader, str, len + 1); delete str; } + +void GL2Encoder::s_glFinish(void *self) +{ + GL2Encoder *ctx = (GL2Encoder *)self; + ctx->glFinishRoundTrip(self); +} + diff --git a/tools/emulator/opengl/system/GLESv2_enc/GL2Encoder.h b/tools/emulator/opengl/system/GLESv2_enc/GL2Encoder.h index 47a9ab314..59a910029 100644 --- a/tools/emulator/opengl/system/GLESv2_enc/GL2Encoder.h +++ b/tools/emulator/opengl/system/GLESv2_enc/GL2Encoder.h @@ -92,5 +92,7 @@ private: static void s_glGetVertexAttribPointerv(void *self, GLuint index, GLenum pname, GLvoid **pointer); static void s_glShaderSource(void *self, GLuint shader, GLsizei count, const GLstr *string, const GLint *length); + + static void s_glFinish(void *self); }; #endif diff --git a/tools/emulator/opengl/system/GLESv2_enc/gl2.attrib b/tools/emulator/opengl/system/GLESv2_enc/gl2.attrib index fca7d61d1..c7244051a 100644 --- a/tools/emulator/opengl/system/GLESv2_enc/gl2.attrib +++ b/tools/emulator/opengl/system/GLESv2_enc/gl2.attrib @@ -547,3 +547,8 @@ glGetCompressedTextureFormats glShaderString len string len flag custom_decoder + +glFinishRoundTrip + flag custom_decoder + flag not_api + diff --git a/tools/emulator/opengl/system/GLESv2_enc/gl2.in b/tools/emulator/opengl/system/GLESv2_enc/gl2.in index af18cf0b9..14b9d1987 100644 --- a/tools/emulator/opengl/system/GLESv2_enc/gl2.in +++ b/tools/emulator/opengl/system/GLESv2_enc/gl2.in @@ -211,5 +211,4 @@ GL_ENTRY(void, glDrawElementsOffset, GLenum mode, GLsizei count, GLenum type, GL GL_ENTRY(void, glDrawElementsData, GLenum mode, GLsizei count, GLenum type, void *data, GLuint datalen) GL_ENTRY(void, glGetCompressedTextureFormats, int count, GLint *formats) GL_ENTRY(void, glShaderString, GLuint shader, GLstr string, GLsizei len) - - +GL_ENTRY(int, glFinishRoundTrip, void)