summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRaoul Hecky <raoul.hecky@gmail.com>2014-06-17 22:15:21 +0200
committerRaoul Hecky <raoul.hecky@gmail.com>2014-06-17 22:19:26 +0200
commitb1c9ef04cea949d6cdbc30217e40bea08473ae91 (patch)
tree949b0c548396c0bf142ed781188d3a2407e1d62d
parent77c54f7a60a1f78d82f018177a13d007ab072cb9 (diff)
evas_gl: add more matching formats to make cocoa_gl happydevs/raoul/macos_port
-rw-r--r--src/modules/evas/engines/gl_common/evas_gl_texture.c5
1 files changed, 4 insertions, 1 deletions
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 224b7dccad..2740c8fa40 100644
--- a/src/modules/evas/engines/gl_common/evas_gl_texture.c
+++ b/src/modules/evas/engines/gl_common/evas_gl_texture.c
@@ -77,6 +77,7 @@ static const struct {
77 { EINA_FALSE, EINA_TRUE, EVAS_COLORSPACE_RGBA8_ETC2_EAC, &etc2_rgba_fmt, &etc2_rgba_fmt } 77 { EINA_FALSE, EINA_TRUE, EVAS_COLORSPACE_RGBA8_ETC2_EAC, &etc2_rgba_fmt, &etc2_rgba_fmt }
78}; 78};
79 79
80static const GLenum matching_rgb[] = { GL_RGB4, GL_RGB8, GL_RGB12, GL_RGB16, 0x0 };
80static const GLenum matching_rgba[] = { GL_RGBA4, GL_RGBA8, GL_RGBA12, GL_RGBA16, 0x0 }; 81static const GLenum matching_rgba[] = { GL_RGBA4, GL_RGBA8, GL_RGBA12, GL_RGBA16, 0x0 };
81static const GLenum matching_alpha[] = { GL_ALPHA4, GL_ALPHA8, GL_ALPHA12, GL_ALPHA16, 0x0 }; 82static const GLenum matching_alpha[] = { GL_ALPHA4, GL_ALPHA8, GL_ALPHA12, GL_ALPHA16, 0x0 };
82static const GLenum matching_luminance[] = { GL_LUMINANCE4, GL_LUMINANCE8, GL_LUMINANCE12, GL_LUMINANCE16, 0x0 }; 83static const GLenum matching_luminance[] = { GL_LUMINANCE4, GL_LUMINANCE8, GL_LUMINANCE12, GL_LUMINANCE16, 0x0 };
@@ -86,8 +87,10 @@ static const struct {
86 GLenum master; 87 GLenum master;
87 const GLenum *matching; 88 const GLenum *matching;
88} matching_fmt[] = { 89} matching_fmt[] = {
90 { GL_RGB, matching_rgb },
89 { GL_RGBA, matching_rgba }, 91 { GL_RGBA, matching_rgba },
90 { GL_ALPHA, matching_alpha }, 92 { GL_ALPHA, matching_alpha },
93 { GL_ALPHA4, matching_alpha },
91 { GL_LUMINANCE, matching_luminance }, 94 { GL_LUMINANCE, matching_luminance },
92 { GL_LUMINANCE_ALPHA, matching_luminance_alpha } 95 { GL_LUMINANCE_ALPHA, matching_luminance_alpha }
93}; 96};
@@ -252,7 +255,7 @@ _tex_2d(Evas_Engine_GL_Context *gc, int intfmt, int w, int h, int fmt, int type)
252 GL_TEXTURE_INTERNAL_FORMAT, &intfmtret); 255 GL_TEXTURE_INTERNAL_FORMAT, &intfmtret);
253 if (!_evas_gl_texture_match(intfmt, intfmtret)) 256 if (!_evas_gl_texture_match(intfmt, intfmtret))
254 { 257 {
255 ERR("Fail tex alloc %ix%i", w, h); 258 ERR("Fail tex alloc %ix%i, intfmt: %X intfmtret: %X", w, h, intfmt, intfmtret);
256 // XXX send async err to evas 259 // XXX send async err to evas
257 return EINA_FALSE; 260 return EINA_FALSE;
258 } 261 }