Resampler< Interpolator, Transform > Class Template Reference

Public Member Functions

Protected Attributes


Detailed Description

template<typename Interpolator, typename Transform>
class Resampler< Interpolator, Transform >

Generic 2D image resampler class. An image is resampled from one sample grid to another using interpolation to obtain the values on the new coordinate grid. Flux is conserved by evaluating the Jacobian at each new grid point.

It is assumed that the new pixels are of the same order or smaller than the original pixels, i.e. we are essentially interpolating, not rebinning onto larger pixels.

The template parameters are the interpolator kernel to use while resampling and the transform from one coordinate system to the new one. Both forward and backward transforms are possible.

Apart from resampling the whole image, there are the possibilities of resampling only one of the coordinates.

We assume that the relevant coordinate pairs are x,y (CCD pixel coordinates) and w,f (wavelength and f-coordinate; The f-co0rdinate is constant along fibers).


Constructor & Destructor Documentation

template<typename Interpolator, typename Transform>
Resampler< Interpolator, Transform >::Resampler ( const Interpolator &  interp,
const Transform &  T 
) [inline]

Member Function Documentation

template<typename Interpolator , typename Transform >
void Resampler< Interpolator, Transform >::resample ( const MArray< float, 2 > &  In,
MArray< float, 2 > &  Out 
) [inline]
template<typename Interpolator , typename Transform >
void Resampler< Interpolator, Transform >::resample_wf ( const MArray< float, 2 > &  In,
MArray< float, 2 > &  Out,
const float  w1,
const float  w2,
const float  f1,
const float  f2 
) [inline]
template<typename Interpolator , typename Transform >
void Resampler< Interpolator, Transform >::resample_xy ( const MArray< float, 2 > &  In,
MArray< float, 2 > &  Out,
const float  w1,
const float  w2,
const float  f1,
const float  f2 
) [inline]
template<typename Interpolator , typename Transform >
void Resampler< Interpolator, Transform >::resample_xy_xf ( const MArray< float, 2 > &  In,
MArray< float, 2 > &  Out,
const float  f1,
const float  f2 
) [inline]
template<typename Interpolator , typename Transform >
void Resampler< Interpolator, Transform >::resample_xf_xy ( const MArray< float, 2 > &  In,
MArray< float, 2 > &  Out,
const float  f1,
const float  f2 
) [inline]

References a, and df.

Referenced by FiberModel::flat_from_data().


Field Documentation

template<typename Interpolator, typename Transform>
const Interpolator& Resampler< Interpolator, Transform >::interp_ [protected]
template<typename Interpolator, typename Transform>
const Transform& Resampler< Interpolator, Transform >::transform_ [protected]

Generated on 4 Nov 2015 for CURE by  doxygen 1.6.1