summaryrefslogtreecommitdiff
path: root/render/image.c
diff options
context:
space:
mode:
Diffstat (limited to 'render/image.c')
-rw-r--r--render/image.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/render/image.c b/render/image.c
index 09d94f17..10aa9b13 100644
--- a/render/image.c
+++ b/render/image.c
@@ -133,10 +133,10 @@ void RrImageDraw(RrPixel32 *target, RrTextureRGBA *rgba,
/* keep the ratio */
dw = area->width;
- dh = (int)(dw * ((double)sh / sw));
+ dh = (gint)(dw * ((gdouble)sh / sw));
if (dh > area->height) {
dh = area->height;
- dw = (int)(dh * ((double)sw / sh));
+ dw = (gint)(dh * ((gdouble)sw / sh));
}
if (sw != dw || sh != dh) {