From 222c221a1a0a848a1376b348cdfc8e28806857d7 Mon Sep 17 00:00:00 2001 From: Ichitaro Kohara Date: Fri, 18 Feb 2011 13:15:04 +0100 Subject: Fixed to draw texture when loadTexture() is called at first time SW renderer of Stagefright reaches loadTexture() to draw image. The first time loadTexture() is called, it just initializes OGL texture, then returns. Thus, the first time call doesn't draw. This patch fixes to move on to draw stage after the initialization. Change-Id: I3ec1ad68fb8d376a4ad7aefded1c18a002d175c4 --- services/surfaceflinger/TextureManager.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/services/surfaceflinger/TextureManager.cpp b/services/surfaceflinger/TextureManager.cpp index c9a15f5..9e24f90 100644 --- a/services/surfaceflinger/TextureManager.cpp +++ b/services/surfaceflinger/TextureManager.cpp @@ -186,7 +186,7 @@ status_t TextureManager::loadTexture(Texture* texture, if (texture->name == -1UL) { status_t err = initTexture(texture); LOGE_IF(err, "loadTexture failed in initTexture (%s)", strerror(err)); - return err; + if (err != NO_ERROR) return err; } if (texture->target != Texture::TEXTURE_2D) -- cgit v1.1