OSDN Git Service

glGetString fix
authorAlexis Hetu <sugoi@google.com>
Tue, 25 Jul 2017 20:04:45 +0000 (16:04 -0400)
committerAlexis Hétu <sugoi@google.com>
Tue, 25 Jul 2017 20:51:32 +0000 (20:51 +0000)
glGetString wasn't returning es3 specific extensions.

Change-Id: Ief89eb448b3e821bfb7919ece97c03976569060c
Reviewed-on: https://swiftshader-review.googlesource.com/10954
Tested-by: Alexis Hétu <sugoi@google.com>
Reviewed-by: Nicolas Capens <nicolascapens@google.com>
src/OpenGL/libGLESv2/Context.cpp

index ed1c366..aa68523 100644 (file)
@@ -4370,6 +4370,14 @@ const GLubyte *Context::getExtensions(GLuint index, GLuint *numExt) const
                        {
                                extensionsCat += std::string(extension) + " ";
                        }
+
+                       if(clientVersion >= 3)
+                       {
+                               for(const char *extension : es3extensions)
+                               {
+                                       extensionsCat += std::string(extension) + " ";
+                               }
+                       }
                }
 
                return (const GLubyte*)extensionsCat.c_str();