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.

This commit is contained in:
gocha 2012-12-28 09:19:30 +00:00
parent 900c6d0a94
commit b2188ebd3a
1 changed files with 1 additions and 1 deletions

View File

@ -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];