21 #ifndef mia_2d_deformer_hh 22 #define mia_2d_deformer_hh 61 std::shared_ptr<T2DInterpolator<T> > interp(m_ipfac.
create(image.
data()));
64 C2DFVectorfield::const_iterator v = m_vf.
begin();
66 for (
size_t y = 0; y < image.
get_size().
y; ++y)
67 for (
size_t x = 0; x < image.
get_size().
x; ++x, ++r, ++v) {
68 *r = (*interp)(
C2DFVector(x - v->x, y - v->y));
83 std::shared_ptr<T2DInterpolator<T> > interp(m_ipfac.
create(image.
data()));
86 C2DFVectorfield::const_iterator v = m_vf.
begin();
88 for (
size_t y = 0; y < image.
get_size().
y; ++y)
89 for (
size_t x = 0; x < image.
get_size().
x; ++x, ++r, ++v) {
90 *r = (*interp)(
C2DFVector(x - v->x, y - v->y));
T2DInterpolator< T > * create(const T2DDatafield< T > &src) const __attribute__((warn_unused_result))
C2DImage::Pointer P2DImage
Shared pointer representation of the 2D Image.
const_iterator begin() const
const_iterator begin() const
forwarding function to access the underlying T2DDatafield
base class for all filer type functors.
This is the template version of a 2D image that is used for holding real data.
#define NS_MIA_BEGIN
conveniance define to start the mia namespace
a 2D field of floating point single accuracy 2D vectors
The factory to create an interpolator from some input data.
T2DVector< float > C2DFVector
float valued 2D vector
const T2DDatafield< T > & data() const
get direct access to the data field
const C2DBounds & get_size() const
#define NS_MIA_END
conveniance define to end the mia namespace