summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorbball <bball@octorok.org>2009-01-29 11:04:43 -0800
committerbball <bball@octorok.org>2009-01-29 11:04:43 -0800
commit7e91df967dbca3fde9697ac4f53f70d498f9e371 (patch)
tree68bd45718f2639c61f8244c135ba678bd3afa27d
parentfae9cc04c10572bdb687a0207a20c85ea1aa51b1 (diff)
downloadvdr-plugin-yaepghd-7e91df967dbca3fde9697ac4f53f70d498f9e371.tar.gz
vdr-plugin-yaepghd-7e91df967dbca3fde9697ac4f53f70d498f9e371.tar.bz2
- Added (int) casts for compile time error.
-rw-r--r--yaepghd.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/yaepghd.c b/yaepghd.c
index 6303023..c0e2f96 100644
--- a/yaepghd.c
+++ b/yaepghd.c
@@ -562,9 +562,9 @@ cYaepgTheme::LoadImage(char *Filename)
const Magick::PixelPacket *pix = images[0].getConstPixels(0, 0, w, h);
for (int iy = 0; iy < h; ++iy) {
for (int ix = 0; ix < w; ++ix) {
- tColor col = (~(pix->opacity * 255 / MaxRGB) << 24) |
- ((pix->red * 255 / MaxRGB) << 16) |
- ((pix->green * 255 / MaxRGB) << 8) |
+ tColor col = (~(int)(pix->opacity * 255 / MaxRGB) << 24) |
+ ((int)(pix->red * 255 / MaxRGB) << 16) |
+ ((int)(pix->green * 255 / MaxRGB) << 8) |
(pix->blue * 255 / MaxRGB);
bmp->DrawPixel(ix, iy, col);
++pix;