diff options
Diffstat (limited to 'src/ui/paint.c')
-rw-r--r-- | src/ui/paint.c | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/src/ui/paint.c b/src/ui/paint.c index d0a4a579..9c6711f1 100644 --- a/src/ui/paint.c +++ b/src/ui/paint.c | |||
@@ -31,13 +31,14 @@ iLocalDef SDL_Renderer *renderer_Paint_(const iPaint *d) { | |||
31 | 31 | ||
32 | static void setColor_Paint_(const iPaint *d, int color) { | 32 | static void setColor_Paint_(const iPaint *d, int color) { |
33 | const iColor clr = get_Color(color & mask_ColorId); | 33 | const iColor clr = get_Color(color & mask_ColorId); |
34 | SDL_SetRenderDrawColor(renderer_Paint_(d), clr.r, clr.g, clr.b, clr.a); | 34 | SDL_SetRenderDrawColor(renderer_Paint_(d), clr.r, clr.g, clr.b, clr.a * d->alpha / 255); |
35 | } | 35 | } |
36 | 36 | ||
37 | void init_Paint(iPaint *d) { | 37 | void init_Paint(iPaint *d) { |
38 | d->dst = get_Window(); | 38 | d->dst = get_Window(); |
39 | d->setTarget = NULL; | 39 | d->setTarget = NULL; |
40 | d->oldTarget = NULL; | 40 | d->oldTarget = NULL; |
41 | d->alpha = 255; | ||
41 | } | 42 | } |
42 | 43 | ||
43 | void beginTarget_Paint(iPaint *d, SDL_Texture *target) { | 44 | void beginTarget_Paint(iPaint *d, SDL_Texture *target) { |