]> gitweb.factorcode.org Git - factor.git/commitdiff
images: don't truncate in image-dim.
authorJohn Benediktsson <mrjbq7@gmail.com>
Thu, 1 Nov 2012 23:48:44 +0000 (16:48 -0700)
committerJohn Benediktsson <mrjbq7@gmail.com>
Thu, 1 Nov 2012 23:48:44 +0000 (16:48 -0700)
basis/images/images.factor

index 430f5bee5ebc5f63775022a04c45b524bf3d9036..2d90faf9ada1b754258594d16de28e3e6229c6f1 100644 (file)
@@ -70,7 +70,7 @@ TUPLE: image
 : <image> ( -- image ) image new ; inline
 
 : image-dim ( image -- dim )
-    [ dim>> ] [ 2x?>> ] bi [ [ 2/ ] map ] when ;
+    [ dim>> ] [ 2x?>> ] bi [ [ 2.0 / ] map ] when ;
 
 : has-alpha? ( image -- ? ) component-order>> alpha-channel? ;