[clutter/wip/cogl-winsys-egl: 15/21] cogl-gl.c: remove really_enable_npot hack for OSX
- From: Robert Bragg <rbragg src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [clutter/wip/cogl-winsys-egl: 15/21] cogl-gl.c: remove really_enable_npot hack for OSX
- Date: Tue, 3 May 2011 16:17:04 +0000 (UTC)
commit e9bc679eba43d18d730f2d6817b1af1f3d5a1321
Author: Robert Bragg <robert linux intel com>
Date: Mon Apr 18 17:35:15 2011 +0100
cogl-gl.c: remove really_enable_npot hack for OSX
This is a workaround for a bug on OSX for some radeon hardware that
we can't verify and the referenced bug link is no longer valid.
If this is really still a problem then a new bug should be opened and we
can look at putting the fix in some more appropriate place than
cogl-gl.c
clutter/cogl/cogl/driver/gl/cogl-gl.c | 37 +++-----------------------------
1 files changed, 4 insertions(+), 33 deletions(-)
---
diff --git a/clutter/cogl/cogl/driver/gl/cogl-gl.c b/clutter/cogl/cogl/driver/gl/cogl-gl.c
index b5a3bee..22392de 100644
--- a/clutter/cogl/cogl/driver/gl/cogl-gl.c
+++ b/clutter/cogl/cogl/driver/gl/cogl-gl.c
@@ -34,32 +34,6 @@
#include "cogl-context-private.h"
#include "cogl-feature-private.h"
-#ifdef HAVE_CLUTTER_OSX
-static gboolean
-really_enable_npot (void)
-{
- /* OSX backend + ATI Radeon X1600 + NPOT texture + GL_REPEAT seems to crash
- * http://bugzilla.openedhand.com/show_bug.cgi?id=929
- *
- * Temporary workaround until post 0.8 we rejig the features set up a
- * little to allow the backend to overide.
- */
- const char *gl_renderer;
- const char *env_string;
-
- /* Regardless of hardware, allow user to decide. */
- env_string = g_getenv ("COGL_ENABLE_NPOT");
- if (env_string != NULL)
- return env_string[0] == '1';
-
- gl_renderer = (char*)glGetString (GL_RENDERER);
- if (strstr (gl_renderer, "ATI Radeon X1600") != NULL)
- return FALSE;
-
- return TRUE;
-}
-#endif
-
static gboolean
_cogl_get_gl_version (int *major_out, int *minor_out)
{
@@ -223,13 +197,10 @@ _cogl_gl_update_features (CoglContext *context)
if (COGL_CHECK_GL_VERSION (gl_major, gl_minor, 2, 0) ||
_cogl_check_extension ("GL_ARB_texture_non_power_of_two", gl_extensions))
{
-#ifdef HAVE_CLUTTER_OSX
- if (really_enable_npot ())
-#endif
- flags |= COGL_FEATURE_TEXTURE_NPOT
- | COGL_FEATURE_TEXTURE_NPOT_BASIC
- | COGL_FEATURE_TEXTURE_NPOT_MIPMAP
- | COGL_FEATURE_TEXTURE_NPOT_REPEAT;
+ flags |= COGL_FEATURE_TEXTURE_NPOT
+ | COGL_FEATURE_TEXTURE_NPOT_BASIC
+ | COGL_FEATURE_TEXTURE_NPOT_MIPMAP
+ | COGL_FEATURE_TEXTURE_NPOT_REPEAT;
}
#ifdef GL_YCBCR_MESA
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]