Hi Folks
Is there a quick (and dirty) way to create a solid black screen with 50% opacity, to “grey out” whatever is on screen, without making such a graphic and loading it into memory?
I only use textures - no SDL surface.
Cheers
Ed
Hi Folks
Is there a quick (and dirty) way to create a solid black screen with 50% opacity, to “grey out” whatever is on screen, without making such a graphic and loading it into memory?
I only use textures - no SDL surface.
Cheers
Ed
Hi,
I think you would want to load a small black texture
and draw it many times to cover the screen
while setting its transparency to 50%
Jesse "JeZ+Lee"
16BitSoft
Video Game Design Studio
www.16BitSoft.comOn 02/03/2011 10:38 AM, ebyard wrote:
Hi Folks
Is there a quick (and dirty) way to create a solid black screen with
50% opacity, to “grey out” whatever is on screen, without making such
a graphic and loading it into memory?
I only use textures - no SDL surface.Cheers
Ed
SDL mailing list
SDL at lists.libsdl.org
http://lists.libsdl.org/listinfo.cgi/sdl-libsdl.org
Try:
SDL_SetRenderDrawColor(0, 0, 0, 127);
SDL_RenderDrawRect(NULL);
But this will dim the screen rather than gray it. To gray it, use a shade of
gray instead of black.________________________________
From: e_byard@yahoo.co.uk (Edward Byard)
Subject: [SDL] SDL 1.3: creating a 50% opaque black screen…
Hi Folks
Is there a quick (and dirty) way to create a solid black screen with 50%
opacity, to “grey out” whatever is on screen, without making such a graphic and
loading it into memory?
I only use textures - no SDL surface.
Cheers
Ed
Ah great, I’d forgotten about that! Thanks Mason