From f8f5ad72ef2942621d78e37f03ac7aee270e2cc6 Mon Sep 17 00:00:00 2001 From: Carsten Haitzler Date: Fri, 21 Oct 2011 10:03:17 +0000 Subject: [PATCH] note on detecting texture alloc fail. need to percolate that back SVN revision: 64250 --- .../evas/src/modules/engines/gl_common/evas_gl_texture.c | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/legacy/evas/src/modules/engines/gl_common/evas_gl_texture.c b/legacy/evas/src/modules/engines/gl_common/evas_gl_texture.c index 0c12d7d61a..e995b3a3ad 100644 --- a/legacy/evas/src/modules/engines/gl_common/evas_gl_texture.c +++ b/legacy/evas/src/modules/engines/gl_common/evas_gl_texture.c @@ -109,8 +109,16 @@ _tex_format_index(GLuint format) static void _tex_2d(int intfmt, int w, int h, int fmt, int type) { + int intfmtret = -1; glTexImage2D(GL_TEXTURE_2D, 0, intfmt, w, h, 0, fmt, type, NULL); GLERR(__FUNCTION__, __FILE__, __LINE__, ""); + glGetTexLevelParameteriv(GL_TEXTURE_2D, 0, + GL_TEXTURE_INTERNAL_FORMAT, &intfmtret); + if (intfmtret != intfmt) + { + ERR("Fail tex alloc %ix%i", w, h); +// XXX send async err to evas + } } static void