diff --git a/pipi/codec/gdi.c b/pipi/codec/gdi.c index 7d0cc14..652d6a4 100644 --- a/pipi/codec/gdi.c +++ b/pipi/codec/gdi.c @@ -60,7 +60,7 @@ pipi_image_t *pipi_load_gdi(const char *name) binfo.bmiHeader.biBitCount = 32; binfo.bmiHeader.biCompression = BI_RGB; binfo.bmiHeader.biHeight = - abs(binfo.bmiHeader.biHeight); - if(!GetDIBits(hdc, hbmap, 0, binfo.bmiHeader.biHeight, data, + if(!GetDIBits(hdc, hbmap, 0, abs(binfo.bmiHeader.biHeight), data, &binfo, DIB_RGB_COLORS)) { ReleaseDC(0, hdc);