Functions
contrib/mul/vimt/vimt_rotate.h File Reference

Rotate an image, using the resampling functions. More...

#include <vimt/vimt_image_2d_of.h>
#include <vil/vil_resample_bilin.h>
#include <vnl/vnl_math.h>
#include <vcl_cmath.h>
#include <vcl_cassert.h>

Go to the source code of this file.

Functions

double calc_theta_mod (double theta, double x)
 Calculate theta in range 0 to x.
template<class sType , class dType >
void vimt_rotate (const vimt_image_2d_of< sType > &src_image, vimt_image_2d_of< dType > &dest_image, double theta_deg)
 Rotate image by angle theta.

Detailed Description

Rotate an image, using the resampling functions.

Author:
Tim Cootes

A front end to the resampling functions that allows an image to be rotated by any angle theta

Definition in file vimt_rotate.h.


Function Documentation

double calc_theta_mod ( double  theta,
double  x 
) [inline]

Calculate theta in range 0 to x.

Definition at line 19 of file vimt_rotate.h.

template<class sType , class dType >
void vimt_rotate ( const vimt_image_2d_of< sType > &  src_image,
vimt_image_2d_of< dType > &  dest_image,
double  theta_deg 
) [inline]

Rotate image by angle theta.

On exit, dest is sized to completely include rotated source. Its world2im() transformation includes that of the src and the rotation (ie world frame is preserved). Note that this currently assumes square pixels. So dest_image.world2im()=rotation*src_image.world2im()

Definition at line 36 of file vimt_rotate.h.