mirror of
				https://github.com/nicbarker/clay.git
				synced 2025-11-04 00:26:17 +00:00 
			
		
		
		
	[Renderers/SDL3] Enable sdl3 alpha blending (#261)
This commit is contained in:
		
							parent
							
								
									c73dffbb6f
								
							
						
					
					
						commit
						a62ee15758
					
				| 
						 | 
					@ -153,6 +153,7 @@ static void SDL_Clay_RenderClayCommands(Clay_SDL3RendererData *rendererData, Cla
 | 
				
			||||||
        switch (rcmd->commandType) {
 | 
					        switch (rcmd->commandType) {
 | 
				
			||||||
            case CLAY_RENDER_COMMAND_TYPE_RECTANGLE: {
 | 
					            case CLAY_RENDER_COMMAND_TYPE_RECTANGLE: {
 | 
				
			||||||
                Clay_RectangleRenderData *config = &rcmd->renderData.rectangle;
 | 
					                Clay_RectangleRenderData *config = &rcmd->renderData.rectangle;
 | 
				
			||||||
 | 
					                SDL_SetRenderDrawBlendMode(rendererData->renderer, SDL_BLENDMODE_BLEND);
 | 
				
			||||||
                SDL_SetRenderDrawColor(rendererData->renderer, config->backgroundColor.r, config->backgroundColor.g, config->backgroundColor.b, config->backgroundColor.a);
 | 
					                SDL_SetRenderDrawColor(rendererData->renderer, config->backgroundColor.r, config->backgroundColor.g, config->backgroundColor.b, config->backgroundColor.a);
 | 
				
			||||||
                if (config->cornerRadius.topLeft > 0) {
 | 
					                if (config->cornerRadius.topLeft > 0) {
 | 
				
			||||||
                    SDL_Clay_RenderFillRoundedRect(rendererData, rect, config->cornerRadius.topLeft, config->backgroundColor);
 | 
					                    SDL_Clay_RenderFillRoundedRect(rendererData, rect, config->cornerRadius.topLeft, config->backgroundColor);
 | 
				
			||||||
| 
						 | 
					
 | 
				
			||||||
		Loading…
	
		Reference in a new issue