We are currently migrating Bugzilla to GitHub issues.
Any changes made to the bug tracker now will be lost, so please do not post new bugs or make changes to them.
When we're done, all bug URLs will redirect to their equivalent location on the new bug tracker.

Bug 2630

Summary: Loss of Window Focus Changes Alpha Blending of Textures
Product: SDL Reporter: Robert <robert.perkel>
Component: renderAssignee: Sam Lantinga <slouken>
Status: NEW --- QA Contact: Sam Lantinga <slouken>
Severity: normal    
Priority: P2    
Version: 2.0.3   
Hardware: x86_64   
OS: Windows 8   

Description Robert 2014-07-07 01:52:23 UTC
When the window is created SDL_WINDOW_FULLSCREEN_DESKTOP, and focus is lost and restored any alpha blending is lost on the texture.

Here is the object's constructor that sets the alpha blend:

Bubble(SDL_Point pt, int radi, Uint32 format, SDL_Color clr, SDL_Renderer* render)
	{
		Circle* circle = new Circle();
		circle->Set_Radi(radi);
		circle->Set_X(pt.x);
		circle->Set_Y(pt.y);
		area.x = pt.x;
		area.y = pt.y;
		prec_area = circle;
		Img = RenderCircle_Fill(radi, clr, format, render); //Draws a circle
		SDL_SetTextureAlphaMod(Img, 100); //This works until loss of focus
		Recalibrate();
		popped = false;
		alive = true;
		up = rand() % 15 + 5;
	}
To my knowledge, any texture works with this issue. When in fullscreen, use Alt + tab to see the issue.