Allow fl_draw_image() with negative L parameter for Mac OS - continued.

git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3-porting@11260 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
This commit is contained in:
Manolo Gouy 2016-03-01 21:10:16 +00:00
parent 9c77129a28
commit 2072fcd698

View File

@ -95,6 +95,7 @@ static void innards(const uchar *buf, int X, int Y, int W, int H,
CGDataProviderRelease(src);
// draw the image into the destination context
if (img) {
CGContextSaveGState(gc);
CGContextTranslateCTM(gc, X, Y);
if (linedelta < 0) {
CGContextTranslateCTM(gc, 0, H-1);
@ -106,6 +107,7 @@ static void innards(const uchar *buf, int X, int Y, int W, int H,
}
((Fl_Quartz_Graphics_Driver*)fl_graphics_driver)->draw_CGImage(img, 0,0,W,H, 0,0,W,H);
CGImageRelease(img);
CGContextRestoreGState(gc);
}
}