From 8f3783da0994703e9fe6fcfc666d194c9eb00865 Mon Sep 17 00:00:00 2001 From: Johannes Schickel Date: Fri, 11 Dec 2015 23:51:21 +0100 Subject: OPENGL: Add functionality to query OpenGL functions on runtime. This can and will be used for future extension usage support. Tizen changes have been untested. --- backends/platform/tizen/graphics.cpp | 4 ++++ backends/platform/tizen/graphics.h | 2 ++ 2 files changed, 6 insertions(+) (limited to 'backends/platform/tizen') diff --git a/backends/platform/tizen/graphics.cpp b/backends/platform/tizen/graphics.cpp index 759c4e519d..971be460d8 100644 --- a/backends/platform/tizen/graphics.cpp +++ b/backends/platform/tizen/graphics.cpp @@ -206,3 +206,7 @@ bool TizenGraphicsManager::loadVideoMode(uint requestedWidth, uint requestedHeig void TizenGraphicsManager::refreshScreen() { eglSwapBuffers(_eglDisplay, _eglSurface); } + +void *TizenGraphicsManager::getProcAddress(const char *name) const { + return eglGetProcAddress(name); +} diff --git a/backends/platform/tizen/graphics.h b/backends/platform/tizen/graphics.h index 1522d66bbe..1798b078d8 100644 --- a/backends/platform/tizen/graphics.h +++ b/backends/platform/tizen/graphics.h @@ -63,6 +63,8 @@ protected: void refreshScreen(); + void *getProcAddress(const char *name) const; + const Graphics::Font *getFontOSD(); private: -- cgit v1.2.3 From d6d3e17d53754acedce0b1706e73f929d29b5eb8 Mon Sep 17 00:00:00 2001 From: Johannes Schickel Date: Sat, 12 Dec 2015 22:08:33 +0100 Subject: OPENGL: Allow runtime specification of OpenGL mode. Formerly, we required that the OpenGL mode was fixed at compile time. Now we allow the code to work with whatever it is given at runtime. It is still possible to force a context type on compile time. --- backends/platform/tizen/graphics.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'backends/platform/tizen') diff --git a/backends/platform/tizen/graphics.cpp b/backends/platform/tizen/graphics.cpp index 971be460d8..caa18c556f 100644 --- a/backends/platform/tizen/graphics.cpp +++ b/backends/platform/tizen/graphics.cpp @@ -59,7 +59,7 @@ result TizenGraphicsManager::Construct() { // We default to RGB565 and RGBA5551 which is closest to the actual output // mode we setup. - notifyContextCreate(Graphics::PixelFormat(2, 5, 6, 5, 0, 11, 5, 0, 0), Graphics::PixelFormat(2, 5, 5, 5, 1, 11, 6, 1, 0)); + notifyContextCreate(Graphics::PixelFormat(2, 5, 6, 5, 0, 11, 5, 0, 0), Graphics::PixelFormat(2, 5, 5, 5, 1, 11, 6, 1, 0), OpenGL::kContextGLES); // Tell our size. int x, y, width, height; -- cgit v1.2.3 From af727afe0ceb66eaf51985ceceb2ac842b3358ee Mon Sep 17 00:00:00 2001 From: Johannes Schickel Date: Fri, 18 Dec 2015 21:14:48 +0100 Subject: OPENGL: Simplify context type setting. --- backends/platform/tizen/graphics.cpp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'backends/platform/tizen') diff --git a/backends/platform/tizen/graphics.cpp b/backends/platform/tizen/graphics.cpp index caa18c556f..61dbfc38fb 100644 --- a/backends/platform/tizen/graphics.cpp +++ b/backends/platform/tizen/graphics.cpp @@ -56,10 +56,11 @@ result TizenGraphicsManager::Construct() { loadEgl(); // Notify the OpenGL code about our context. + setContextType(OpenGL::kContextGLES); // We default to RGB565 and RGBA5551 which is closest to the actual output // mode we setup. - notifyContextCreate(Graphics::PixelFormat(2, 5, 6, 5, 0, 11, 5, 0, 0), Graphics::PixelFormat(2, 5, 5, 5, 1, 11, 6, 1, 0), OpenGL::kContextGLES); + notifyContextCreate(Graphics::PixelFormat(2, 5, 6, 5, 0, 11, 5, 0, 0), Graphics::PixelFormat(2, 5, 5, 5, 1, 11, 6, 1, 0)); // Tell our size. int x, y, width, height; -- cgit v1.2.3