summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRafael Antognolli <rafael.antognolli@intel.com>2013-11-26 11:41:54 -0200
committerRafael Antognolli <rafael.antognolli@intel.com>2013-11-26 11:49:13 -0200
commit87385b05c3117aa8d46fd4029bfdeadf3444a7b9 (patch)
tree955293ebf742b742916acaf799972cfa7434382f
parent05d2701474def6cf20c00472889553d78b4de19a (diff)
Revert "evas: allow fuzziness on the texture format returned by GL."
This reverts commit 2b5b3438e82a9a1bb4086864660942d3c1ddc113. Breaks gl engines when using GLES + EGL.
-rw-r--r--ChangeLog4
-rw-r--r--NEWS1
-rw-r--r--src/modules/evas/engines/gl_common/evas_gl_texture.c38
3 files changed, 1 insertions, 42 deletions
diff --git a/ChangeLog b/ChangeLog
index 95ee2abef..ec1db15bc 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -7,10 +7,6 @@
* ecore anim: Fixed animator not working problem when source_set is
changed back and forth very fast.
-2013-11-26 Cedric Bail
-
- * Evas: Allow fuzziness on the texture format returned by GL.
-
2013-11-25 Tom Hacohen
* Evas textblock: Fixed wrapping of lines ending with whites.
diff --git a/NEWS b/NEWS
index e5a8bbe65..856e3f45d 100644
--- a/NEWS
+++ b/NEWS
@@ -228,7 +228,6 @@ Improvements:
- Use mmap/munmap for image data allocation on system that have mmap.
- Add iterator for walking child of smart objects, table and a box.
- Use Eina_Spinlock for Evas_ScaleCache, Evas_Async_Events and Image_Entry.
- - Allow fuzziness on the texture format returned by GL.
* Ecore:
- Use Eina_Spinlock for Ecore_Thread.
* Ecore_Con:
diff --git a/src/modules/evas/engines/gl_common/evas_gl_texture.c b/src/modules/evas/engines/gl_common/evas_gl_texture.c
index 95cb3a494..1cacce354 100644
--- a/src/modules/evas/engines/gl_common/evas_gl_texture.c
+++ b/src/modules/evas/engines/gl_common/evas_gl_texture.c
@@ -54,42 +54,6 @@ static const struct {
#endif
};
-static const GLenum matching_rgba[] = { GL_RGBA4, GL_RGBA8, GL_RGBA12, GL_RGBA16, 0x0 };
-static const GLenum matching_alpha[] = { GL_ALPHA4, GL_ALPHA8, GL_ALPHA12, GL_ALPHA16, 0x0 };
-static const GLenum matching_luminance[] = { GL_LUMINANCE4, GL_LUMINANCE8, GL_LUMINANCE12, GL_LUMINANCE16, 0x0 };
-static const GLenum matching_luminance_alpha[] = { GL_LUMINANCE4_ALPHA4, GL_LUMINANCE8_ALPHA8, GL_LUMINANCE12_ALPHA12, GL_LUMINANCE16_ALPHA16, 0x0 };
-
-static const struct {
- GLenum master;
- const GLenum *matching;
-} matching_fmt[] = {
- { GL_RGBA, matching_rgba },
- { GL_ALPHA, matching_alpha },
- { GL_LUMINANCE, matching_luminance },
- { GL_LUMINANCE_ALPHA, matching_luminance_alpha }
-};
-
-static Eina_Bool
-_evas_gl_texture_match(GLenum intfmt, GLenum intfmtret)
-{
- unsigned int i;
-
- if (intfmt == intfmtret) return EINA_TRUE;
-
- for (i = 0; i < sizeof (matching_fmt) / sizeof (matching_fmt[0]); i++)
- if (matching_fmt[i].master == intfmt)
- {
- unsigned int j;
-
- for (j = 0; matching_fmt[i].matching[j] != 0x0; j++)
- if (matching_fmt[i].matching[j] == intfmtret)
- return EINA_TRUE;
- return EINA_FALSE;
- }
-
- return EINA_FALSE;
-}
-
static int
_evas_gl_texture_search_format(Eina_Bool alpha, Eina_Bool bgra)
{
@@ -197,7 +161,7 @@ _tex_2d(Evas_Engine_GL_Context *gc, int intfmt, int w, int h, int fmt, int type)
glGetTexLevelParameteriv(GL_TEXTURE_2D, 0,
GL_TEXTURE_INTERNAL_FORMAT, &intfmtret);
- if (!_evas_gl_texture_match(intfmt, intfmtret))
+ if (intfmtret != intfmt)
{
ERR("Fail tex alloc %ix%i", w, h);
// XXX send async err to evas