Steve on Image Processing with MATLAB

Image processing concepts, algorithms, and MATLAB

Note

Steve on Image Processing with MATLAB has been archived and will not be updated.

Use makehgtform for 3-D rotation

Developer Mike G. read my recent post about three-dimensional image rotation and suggested that users might want to use the MATLAB function makehgtform to construct the affine transform matrix. It has some convenient syntaxes.

As an alternative to the code I posted, Mike says you could do something like this:

  T = makehgtform('translate',blob_center,...
                   'yrotate',pi/8,...
                   'translate',-blob_center);
  T = T';

(The transposition step is necessary to satisfy the convention used in the Image Processing Toolbox functions.)

Thanks, Mike - I didn't know about that one.

|
  • print

Comments

To leave a comment, please click here to sign in to your MathWorks Account or create a new one.