--- a/lib/Panotools/Script/Line/Image.pm
+++ b/lib/Panotools/Script/Line/Image.pm
@@ -382,7 +382,7 @@
     }
 
     my $matrix = rollpitchyaw2matrix
-                   (deg2rad ($self->{r}), deg2rad ($self->{p}), deg2rad ($self->{y}));
+                   (deg2rad ($self->r), deg2rad ($self->p), deg2rad ($self->y));
 
     multiply ($matrix, $point);
 }