octave-bug-tracker
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Octave-bug-tracker] [bug #44830] image package: imtransform gives diffe


From: H. G.
Subject: [Octave-bug-tracker] [bug #44830] image package: imtransform gives different numbers on simple rotation
Date: Wed, 15 Apr 2015 09:56:43 +0000
User-agent: Mozilla/5.0 (X11; Ubuntu; Linux x86_64; rv:37.0) Gecko/20100101 Firefox/37.0

Follow-up Comment #2, bug #44830 (project octave):

If I skip the last column of the transformation matrix, and thus run the
following script in Matlab


clear;
M = [0 1 0; 0 1 0; 0 1 0];
a=45;
t = maketform ('affine',[cosd(a) sind(a); -sind(a) cosd(a); 0 0]);
imtrans = imtransform (M,t,'FillValues',0)


Then Matlab gives the following result:


imtrans =

         0         0    0.2426         0
         0    0.4142    0.8787    0.1005
    0.2426    0.8787    0.1716         0
         0    0.1005         0         0


This is the very same result as with the script in my original post. So there
stays a discrepancy between Matlab and Octave here.

Intuitivly I would also expect the result of this 45 degree rotation to be
symmetric. But it's not symmetric in Matlab.

I know from making a different function of the image package more Matlab
compatible, that Matlab sometimes thinks of an image not as numbers on a
dicrete grid, but as 1x1 surfaces tiling the plane. This might give an offsset
of 0.5 to the center of rotation (or might not?). But that's only my wild
speculation. I do not have any more useful clue why the Matlab result is
different in this case.

(As I do NOT have Matlab access at the moment, and for the following months, I
wouldn't like to do further Matlab test in this matter, sorry. It always means
asking a former colleague for help...)


    _______________________________________________________

Reply to this item at:

  <http://savannah.gnu.org/bugs/?44830>

_______________________________________________
  Nachricht gesendet von/durch Savannah
  http://savannah.gnu.org/




reply via email to

[Prev in Thread] Current Thread [Next in Thread]