]> gitweb.factorcode.org Git - factor.git/commitdiff
core-graphics: set premultiplied-alpha? in make-bitmap-image. Fixes #73
authorSlava Pestov <slava@factorcode.org>
Fri, 9 Sep 2011 06:08:16 +0000 (23:08 -0700)
committerSlava Pestov <slava@factorcode.org>
Fri, 9 Sep 2011 06:08:16 +0000 (23:08 -0700)
basis/core-graphics/core-graphics.factor
basis/images/cocoa/cocoa.factor

index 45a6ddc72b41e6636bfbc8ee53feb2a842e9e496..e64cf2ab2d986dd919f4f4b0d1ec0492e2cf1959 100644 (file)
@@ -155,4 +155,5 @@ PRIVATE>
 : make-bitmap-image ( dim quot -- image )
     '[ <CGBitmapContext> &CGContextRelease @ ] make-memory-bitmap
     ARGB >>component-order
-    ubyte-components >>component-type ; inline
+    ubyte-components >>component-type
+    t >>premultiplied-alpha? ; inline
index c170b0d89705f4bd716fa074aaff76257e4b1078..a308d3f47531c7a74080420a5711cc9199f6aae2 100644 (file)
@@ -57,8 +57,7 @@ PRIVATE>
     image CGImageGetHeight :> h
     { w h } [
         0 0 w h <CGRect> image CGContextDrawImage
-    ] make-bitmap-image
-    t >>premultiplied-alpha? ;
+    ] make-bitmap-image ;
 
 M: ns-image stream>image
     drop stream-contents <CGImage> CGImage>image ;