Remove black pixels at corners of DrawRoundRect rectangles
authorWuzzy <Wuzzy2@mail.ru>
Sun, 20 Jan 2019 21:41:49 +0100
changeset 14655 b055360684bd
parent 14654 c9d2a5a9f6ba
child 14656 1bf3efd9d85d
Remove black pixels at corners of DrawRoundRect rectangles Fixes regression introduced in 8935dcc0e1307f3963d2d21e4f7ce1cca8407579.
hedgewars/uRenderUtils.pas
--- a/hedgewars/uRenderUtils.pas	Sat Jan 19 05:06:33 2019 +0100
+++ b/hedgewars/uRenderUtils.pas	Sun Jan 20 21:41:49 2019 +0100
@@ -46,7 +46,7 @@
 begin
     r:= rect^;
     if Clear then
-        SDL_FillRect(Surface, @r, SDL_MapRGB(Surface^.format, 0, 0, 0));
+        SDL_FillRect(Surface, @r, SDL_MapRGBA(Surface^.format, 0, 0, 0, 0));
 
     BorderColor:= SDL_MapRGB(Surface^.format, BorderColor shr 16, BorderColor shr 8, BorderColor and $FF);
     FillColor:= SDL_MapRGB(Surface^.format, FillColor shr 16, FillColor shr 8, FillColor and $FF);