]> git.imager.perl.org - imager.git/commitdiff
[rt #84963] Imager::Color::rgba() now returns integer samples
authorTony Cook <tony@develop-help.com>
Tue, 21 May 2013 10:22:59 +0000 (20:22 +1000)
committerTony Cook <tony@develop-help.com>
Tue, 21 May 2013 10:22:59 +0000 (20:22 +1000)
Changes
Imager.xs

diff --git a/Changes b/Changes
index 11a887a200dd180d86b1e91ac3d55a12af498d33..ad9817b51e0544f80a53a83476d4deea8e74ebac 100644 (file)
--- a/Changes
+++ b/Changes
@@ -14,6 +14,10 @@ Imager release history.  Older releases can be found in Changes.old
 
    https://rt.cpan.org/Ticket/Display.html?id=74540
 
+ - Imager::Color's rgba() method now returns it's values as integers
+   instead of floating point. (IV instead of NV).
+   https://rt.cpan.org/Ticket/Display.html?id=69243 (partial)
+
 Imager 0.96 - 19 May 2013
 ===========
 
index f0b6c4d9cf4ee90126e8ff14935d1cad8cf8b740..7a3346ea3d71505d8d39a286ffcf57e14361b234 100644 (file)
--- a/Imager.xs
+++ b/Imager.xs
@@ -954,10 +954,10 @@ ICL_rgba(cl)
              Imager::Color     cl
            PPCODE:
                EXTEND(SP, 4);
-               PUSHs(sv_2mortal(newSVnv(cl->rgba.r)));
-               PUSHs(sv_2mortal(newSVnv(cl->rgba.g)));
-               PUSHs(sv_2mortal(newSVnv(cl->rgba.b)));
-               PUSHs(sv_2mortal(newSVnv(cl->rgba.a)));
+               PUSHs(sv_2mortal(newSViv(cl->rgba.r)));
+               PUSHs(sv_2mortal(newSViv(cl->rgba.g)));
+               PUSHs(sv_2mortal(newSViv(cl->rgba.b)));
+               PUSHs(sv_2mortal(newSViv(cl->rgba.a)));
 
 Imager::Color
 i_hsv_to_rgb(c)