From b2188ebd3a65430f0bbe24ddb1fd62f3a393f510 Mon Sep 17 00:00:00 2001 From: gocha Date: Fri, 28 Dec 2012 09:19:30 +0000 Subject: [PATCH] 0.9.7: Lua: fix a bug that gui.gdscreenshot() always returns a transparent image. it will always return a complete opaque image from now. --- desmume/src/lua-engine.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/desmume/src/lua-engine.cpp b/desmume/src/lua-engine.cpp index 3f0f0346d..43ec9ef97 100644 --- a/desmume/src/lua-engine.cpp +++ b/desmume/src/lua-engine.cpp @@ -3235,7 +3235,7 @@ DEFINE_LUA_FUNCTION(gui_gdscreenshot, "[whichScreen='both']") { for(int x = curGuiData.xMin; x < curGuiData.xMax; x++) { - *ptr++ = 255 - Src[4*x+3]; + *ptr++ = 0 /* (255 - Src[4*x+3]) / 2 */; // alpha (0-127, 0=opaque, 127=transparent) *ptr++ = Src[4*x+2]; *ptr++ = Src[4*x+1]; *ptr++ = Src[4*x+0];