Basic Image AlgorithmS Library  2.8.0
 All Classes Namespaces Functions Variables Typedefs Enumerations Enumerator Friends Groups Pages
Public Member Functions | Static Public Member Functions | Protected Member Functions | Protected Attributes | List of all members
BIAS::TextureMapping< InputStorageType, OutputStorageType > Class Template Reference

Maps source pixel to sink pixel given any TextureTransform. More...

#include <Image/TextureMapping.hh>

+ Inheritance diagram for BIAS::TextureMapping< InputStorageType, OutputStorageType >:
+ Collaboration diagram for BIAS::TextureMapping< InputStorageType, OutputStorageType >:

Public Member Functions

virtual int GetBoundingBox (unsigned int srcwidth, unsigned int srcheight, unsigned int sinkwidth, unsigned int sinkheight, int &tlx, int &tly, int &brx, int &bry)
 calculates the bounding box in sink image, where to do the backward mapping. More...
 
int GetJacobian (const HomgPoint2D &sink, Matrix2x2< double > &Jacobian) const
 get jacobian (including concatenated mappings) More...
 
int GetSourceCoordinates (const HomgPoint2D &sink, HomgPoint2D &source) const
 wrapper function to allow the lookup implementation to be shared with other algorithms. More...
 
TextureMapping
< InputStorageType,
OutputStorageType > & 
operator= (const TextureMapping &src)
 required because of const members More...
 
void SetConcatenation (BIAS::BackwardMapping< InputStorageType, OutputStorageType > *pCon)
 avoid intermediate image and concatenate two backward mappings More...
 
void SetPyramidSize (const int newsize)
 sets pyramid size to pyramid and updates if neccessary More...
 
void SetTextureTransform (const TextureTransform &T)
 create clone of your texture tranform and set for mapping More...
 
 TextureMapping ()
 
 TextureMapping (const TextureMapping &src)
 required because assignment is More...
 
virtual void UpdatePyramidSize (const ROI &ROIsink, int srcwidth, int srcheight)
 uses corners of sink roi (and few other sample points) to estimate maximum local scaling (and thus required pyramid level) More...
 
virtual ~TextureMapping ()
 
User interfaces
int Map (const Image< InputStorageType > &src, Image< OutputStorageType > &sink, InterpolationMethod=MapTrilinear, bool newSink=false, double SuperSampling=1.0)
 backward mapping with various interpolations More...
 
int Map (Image< OutputStorageType > &sink)
 use this for subsequent calls to avoid pyramid recalculation when using tri-filtering More...
 
int GetDisplacementMap (Image< float > &dismap, int width, int height)
 precomputes lookup coordinates and computes displacement map int TEXTURE coordinates, according to the size of src (or width,height) More...
 
int GetDisplacementMap (Image< float > &dismap, Image< InputStorageType > &src)
 
int PrepareLookupTableMapping (const Image< InputStorageType > &src, Image< OutputStorageType > &sink, InterpolationMethod method, bool newSink=false)
 precomputes lookup coordinates for accessing src More...
 
int MapWithLookupTable (const Image< InputStorageType > &src, Image< OutputStorageType > &sink, InterpolationMethod method)
 applies precomputed coordinates in src, fast for repeated usages of same mapping function More...
 
int GetLookupTable (const std::string &filename, InterpolationMethod method)
 Returns the LUT generated by PrepareLookupTableMapping() as an file. More...
 
int GetLookupTable (float *lutImageRow, InterpolationMethod method)
 
int GetLookupTableSize (unsigned int &width, unsigned int &channels, InterpolationMethod method)
 returns the size of the current LUT. More...
 
int SetLookupTable (const std::string &filename, InterpolationMethod &method)
 Loads the LUT from a file, replaces the call to PrepareLookupTableMapping(). More...
 
int SetLookupTable (const float *lutImageRow, unsigned int width, InterpolationMethod &method)
 

Static Public Member Functions

static void GenerateTestImage (Image< InputStorageType > &testimage, bool highFrequencyCross=true, InputStorageType dark=5, InputStorageType bright=127, const Matrix3x3< double > &Hinv=Matrix3x3< double >(MatrixIdentity))
 generates a siemens star like test image with lots of different frequencies to test backward mapping More...
 

Protected Member Functions

virtual void BuildPyramid_ (const Image< InputStorageType > &source, bool forceInit=true, int numlayers=-1)
 compute maximum number of pyramid levels needed More...
 
virtual int CalcCoordOffset_ (const Image< OutputStorageType > &sink, const Image< InputStorageType > &source)
 result in offsetX_,offsetY_ More...
 
virtual int ChangeImgSize_ (Image< OutputStorageType > &, const Image< InputStorageType > &)
 
void ClipBoundingBoxToROICorners_ (const BIAS::Image< OutputStorageType > &sink, int &tlx, int &tly, int &brx, int &bry) const
 clip computed region in dest image to roi More...
 
void ClipValue_ (const double &value, OutputStorageType &newvalue)
 clip interpolated value to outputstoragetype and merge old and new value according to alpha More...
 
template<>
void ClipValue_ (const double &value, unsigned char &newvalue)
 
template<>
void ClipValue_ (const double &value, float &newvalue)
 
template<>
void ClipValue_ (const double &value, unsigned char &newvalue)
 
template<>
void ClipValue_ (const double &value, float &newvalue)
 
virtual int GetJacobian_ (const HomgPoint2D &sink, Matrix2x2< double > &Jacobian) const
 analytic jacobian More...
 
virtual int GetSourceCoordinates_ (const HomgPoint2D &sink, HomgPoint2D &source) const
 Reimplementation for Pixel transformation, takes sink and computes coordinates in source. More...
 
geometrical coordinate mapping functions
void ComputeLocalPyramidLayer_ (const HomgPoint2D &p_sink, double &localscale)
 computes pyramid layer for trilinear filtering, e.g. More...
 
pixel-value-mapping worker functions
int MapTri_ (Image< OutputStorageType > &sink)
 map image avoiding aliasing More...
 
int MapTrilinearGreySimple_ (Image< OutputStorageType > &sink)
 fast trilinear grey without special features More...
 
int MapBi_ (const Image< InputStorageType > &source, Image< OutputStorageType > &sink, InterpolationMethod interpolationQuality)
 bilinear, bicubc and nearest neighbor interpolation More...
 
int GetImageValue_ (const double &xsource, const double &ysource, const Image< InputStorageType > &im, unsigned int channel, double &result)
 worker function, which handles bilinear/bicubic interpolation, borders and weights More...
 
int GetTrilinearImageValue_ (const double &xsource, const double &ysource, const double &scale, unsigned int channel, double &result)
 worker function, which handles bilinear/bicubic interpolation, pyramid levels, borders and weights More...
 
int GetAnisotropicImageValue_ (const double &xsource, const double &ysource, Matrix2x2< double > &Jacobian, unsigned int channel, double &thereturnvalue)
 use jacobian of mapping function to do anisotropic antialiasing More...
 

Protected Attributes

bool aliasing_
 set to true if possibility of aliasing is detected during mapping More...
 
BIAS::Image< float > alphaImg_
 has same size as overlap region used for blending More...
 
bool autoPyramidSize_
 pyramid size set by user or computed automatically ? More...
 
double height_
 source image height More...
 
bool incomplete_
 set to true if not every pixel could be computed More...
 
InterpolationMethod interpolationType_
 which interpolation method are we using More...
 
int offsetX_
 needed for newDist More...
 
int offsetY_
 
BackwardMapping
< InputStorageType,
OutputStorageType > * 
pConcatenation_
 
BWM_LUT_Entry_AnisotropicpLUT_Ani_
 NOT IMPLEMENTED (YET ?) More...
 
BWM_LUT_Entry_BicubicpLUT_Bic_
 
BWM_LUT_Entry_BilinearpLUT_Bil_
 
int pLUT_Bil_size
 
BWM_LUT_Entry_NearestpLUT_Nea_
 lookup-tables for precomputed positions in source, same size as dst.PixelCount More...
 
int pLUT_Nea_size
 
BWM_LUT_Entry_TrilinearpLUT_Tri_
 
int pLUT_Tri_size
 
PyramidImage< InputStorageType > pyramid_
 this contains a pyramid of the last source image for anti-aliasing More...
 
unsigned pyramidSize_
 
bool rangeChecked_
 The interpolated value is computed in double; if clipped value is not specialized for your output storage type (e.g. More...
 
ROI ROI_
 the roi of the last source image More...
 
double superSampling_
 if larger than 1, super resolution is active More...
 
TextureTransformT_
 Textures for backward mapping: Run over sink and compute source. More...
 
double width_
 source image width More...
 

Detailed Description

template<class InputStorageType, class OutputStorageType>
class BIAS::TextureMapping< InputStorageType, OutputStorageType >

Maps source pixel to sink pixel given any TextureTransform.

Author
koeser
Date
2008
Examples:
ExampleAlignment.cpp.

Definition at line 43 of file TextureMapping.hh.

Constructor & Destructor Documentation

template<class InputStorageType , class OutputStorageType >
TextureMapping::~TextureMapping ( )
virtual

Definition at line 34 of file TextureMapping.cpp.

template<class InputStorageType , class OutputStorageType >
TextureMapping::TextureMapping ( )

Definition at line 41 of file TextureMapping.cpp.

template<class InputStorageType , class OutputStorageType >
TextureMapping::TextureMapping ( const TextureMapping< InputStorageType, OutputStorageType > &  src)

required because assignment is

Author
Jan Woetzel

Definition at line 49 of file TextureMapping.cpp.

Member Function Documentation

template<class InputStorageType, class OutputStorageType >
void BIAS::BackwardMapping< InputStorageType, OutputStorageType >::BuildPyramid_ ( const Image< InputStorageType > &  source,
bool  forceInit = true,
int  numlayers = -1 
)
protectedvirtualinherited

compute maximum number of pyramid levels needed

Definition at line 219 of file BackwardMapping.cpp.

References BIAS::ImageBase::GetHeight(), and BIAS::ImageBase::GetWidth().

template<class InputStorageType, class OutputStorageType>
int BIAS::BackwardMapping< InputStorageType, OutputStorageType >::CalcCoordOffset_ ( const Image< OutputStorageType > &  sink,
const Image< InputStorageType > &  source 
)
protectedvirtualinherited

result in offsetX_,offsetY_

Definition at line 1042 of file BackwardMapping.cpp.

References BIAS::ImageBase::GetHeight(), and BIAS::ImageBase::GetWidth().

template<class InputStorageType, class OutputStorageType>
int BIAS::BackwardMapping< InputStorageType, OutputStorageType >::ChangeImgSize_ ( Image< OutputStorageType > &  sink,
const Image< InputStorageType > &  source 
)
protectedvirtualinherited
template<class InputStorageType , class OutputStorageType>
void BIAS::BackwardMapping< InputStorageType, OutputStorageType >::ClipBoundingBoxToROICorners_ ( const BIAS::Image< OutputStorageType > &  sink,
int &  tlx,
int &  tly,
int &  brx,
int &  bry 
) const
protectedinherited

clip computed region in dest image to roi

Definition at line 1026 of file BackwardMapping.cpp.

References BIAS::ImageBase::GetROICorners().

template<class InputStorageType , class OutputStorageType>
void BIAS::BackwardMapping< InputStorageType, OutputStorageType >::ClipValue_ ( const double &  value,
OutputStorageType &  newvalue 
)
inlineprotectedinherited

clip interpolated value to outputstoragetype and merge old and new value according to alpha

This function must be inplemented for diferent template types rather than for derived classes, e.g. if bicubic interpolation estimates the grey value 257.8 for an unsinged char image, this is rounded and clipped here to 255.0 since this is the maximum allowed uchar.

Definition at line 598 of file BackwardMapping.hh.

template<>
void BIAS::BackwardMapping< unsigned char, unsigned char >::ClipValue_ ( const double &  value,
unsigned char &  newvalue 
)
inlineprotectedinherited

Definition at line 613 of file BackwardMapping.hh.

template<>
void BIAS::BackwardMapping< float, float >::ClipValue_ ( const double &  value,
float &  newvalue 
)
inlineprotectedinherited

Definition at line 622 of file BackwardMapping.hh.

template<>
void BIAS::BackwardMapping< float, unsigned char >::ClipValue_ ( const double &  value,
unsigned char &  newvalue 
)
inlineprotectedinherited

Definition at line 629 of file BackwardMapping.hh.

template<>
void BIAS::BackwardMapping< unsigned char, float >::ClipValue_ ( const double &  value,
float &  newvalue 
)
inlineprotectedinherited

Definition at line 638 of file BackwardMapping.hh.

template<class InputStorageType, class OutputStorageType>
void BIAS::BackwardMapping< InputStorageType, OutputStorageType >::ComputeLocalPyramidLayer_ ( const HomgPoint2D p_sink,
double &  localscale 
)
inlineprotectedinherited

computes pyramid layer for trilinear filtering, e.g.

localscale 0.5 means best resolution and second best are averaged

Definition at line 366 of file BackwardMapping.hh.

template<class InputStorageType, class OutputStorageType >
void BIAS::BackwardMapping< InputStorageType, OutputStorageType >::GenerateTestImage ( Image< InputStorageType > &  testimage,
bool  highFrequencyCross = true,
InputStorageType  dark = 5,
InputStorageType  bright = 127,
const Matrix3x3< double > &  Hinv = Matrix3x3<double>(MatrixIdentity) 
)
staticinherited

generates a siemens star like test image with lots of different frequencies to test backward mapping

Parameters
testimageinitialized image of user defined size which will be filled
highFrequencyCrossgenerates an additional high frequency line
darkblack image value, e.g. close to 0
darkwhite image value, e.g. close to 255
Hinvhomography to transform pattern (if desired)
Author
koeser 10/2007
Examples:
ExampleHomographyMapping.cpp.

Definition at line 2004 of file BackwardMapping.cpp.

References BIAS::ImageBase::GetChannelCount(), BIAS::ImageBase::GetHeight(), BIAS::Image< StorageType >::GetImageDataArray(), BIAS::ImageBase::GetWidth(), BIAS::Image< StorageType >::Init(), and BIAS::ImageBase::IsEmpty().

template<class InputStorageType , class OutputStorageType >
int BIAS::BackwardMapping< InputStorageType, OutputStorageType >::GetAnisotropicImageValue_ ( const double &  xsource,
const double &  ysource,
Matrix2x2< double > &  Jacobian,
unsigned int  channel,
double &  thereturnvalue 
)
protectedinherited

use jacobian of mapping function to do anisotropic antialiasing

Definition at line 978 of file BackwardMapping.cpp.

References BIAS::Matrix2x2< T >::EigenvalueDecomposition(), and BIAS::Matrix< T >::GetSystemMatrix().

template<class InputStorageType, class OutputStorageType>
virtual int BIAS::TextureMapping< InputStorageType, OutputStorageType >::GetBoundingBox ( unsigned int  ,
unsigned int  ,
unsigned int  sinkwidth,
unsigned int  sinkheight,
int &  tlx,
int &  tly,
int &  brx,
int &  bry 
)
inlinevirtual

calculates the bounding box in sink image, where to do the backward mapping.

The resulting coordinates can be negative ! The br position is the first pixel outside the region(as for a ROI). Implement this in a derived class for speeding up calculation.

Reimplemented from BIAS::BackwardMapping< InputStorageType, OutputStorageType >.

Definition at line 68 of file TextureMapping.hh.

References BIAS::HomgPoint2D.

template<class InputStorageType , class OutputStorageType >
int BIAS::BackwardMapping< InputStorageType, OutputStorageType >::GetDisplacementMap ( Image< float > &  dismap,
int  width,
int  height 
)
inherited

precomputes lookup coordinates and computes displacement map int TEXTURE coordinates, according to the size of src (or width,height)

Definition at line 1125 of file BackwardMapping.cpp.

template<class InputStorageType, class OutputStorageType >
int BIAS::BackwardMapping< InputStorageType, OutputStorageType >::GetDisplacementMap ( Image< float > &  dismap,
Image< InputStorageType > &  src 
)
inherited
template<class InputStorageType, class OutputStorageType >
int BIAS::BackwardMapping< InputStorageType, OutputStorageType >::GetImageValue_ ( const double &  xsource,
const double &  ysource,
const Image< InputStorageType > &  im,
unsigned int  channel,
double &  result 
)
inlineprotectedinherited
template<class InputStorageType, class OutputStorageType>
int BIAS::BackwardMapping< InputStorageType, OutputStorageType >::GetJacobian ( const HomgPoint2D sink,
Matrix2x2< double > &  Jacobian 
) const
inlineinherited

get jacobian (including concatenated mappings)

Definition at line 302 of file BackwardMapping.hh.

template<class InputStorageType , class OutputStorageType >
int TextureMapping::GetJacobian_ ( const HomgPoint2D sink,
Matrix2x2< double > &  Jacobian 
) const
protectedvirtual

analytic jacobian

Reimplemented from BIAS::BackwardMapping< InputStorageType, OutputStorageType >.

Definition at line 74 of file TextureMapping.cpp.

template<class InputStorageType , class OutputStorageType >
int BIAS::BackwardMapping< InputStorageType, OutputStorageType >::GetLookupTable ( const std::string &  filename,
InterpolationMethod  method 
)
inherited

Returns the LUT generated by PrepareLookupTableMapping() as an file.

Definition at line 1241 of file BackwardMapping.cpp.

References BIAS::MapBilinear, BIAS::MapNearestNeighbor, and BIAS::MapTrilinear.

template<class InputStorageType , class OutputStorageType >
int BIAS::BackwardMapping< InputStorageType, OutputStorageType >::GetLookupTable ( float *  lutImageRow,
InterpolationMethod  method 
)
inherited
template<class InputStorageType , class OutputStorageType >
int BIAS::BackwardMapping< InputStorageType, OutputStorageType >::GetLookupTableSize ( unsigned int &  width,
unsigned int &  channels,
InterpolationMethod  method 
)
inherited

returns the size of the current LUT.

Returns
-1 if the current InterpolationMethod has no LUT!

Definition at line 1195 of file BackwardMapping.cpp.

References BIAS::MapBilinear, BIAS::MapNearestNeighbor, and BIAS::MapTrilinear.

template<class InputStorageType, class OutputStorageType>
int BIAS::BackwardMapping< InputStorageType, OutputStorageType >::GetSourceCoordinates ( const HomgPoint2D sink,
HomgPoint2D source 
) const
inlineinherited

wrapper function to allow the lookup implementation to be shared with other algorithms.

Attention
Do not reimplement this method in any child class implement into GetSourceCoordinates_().

Definition at line 272 of file BackwardMapping.hh.

Referenced by BIAS::RectificationViaProjectionMappingBase< InputStorageType, OutputStorageType >::Disp2Depth().

template<class InputStorageType , class OutputStorageType >
int TextureMapping::GetSourceCoordinates_ ( const HomgPoint2D sink,
HomgPoint2D source 
) const
protectedvirtual

Reimplementation for Pixel transformation, takes sink and computes coordinates in source.

Reimplemented from BIAS::BackwardMapping< InputStorageType, OutputStorageType >.

Definition at line 67 of file TextureMapping.cpp.

template<class InputStorageType , class OutputStorageType >
int BIAS::BackwardMapping< InputStorageType, OutputStorageType >::GetTrilinearImageValue_ ( const double &  xsource,
const double &  ysource,
const double &  scale,
unsigned int  channel,
double &  result 
)
protectedinherited

worker function, which handles bilinear/bicubic interpolation, pyramid levels, borders and weights

Definition at line 913 of file BackwardMapping.cpp.

template<class InputStorageType, class OutputStorageType>
int BIAS::BackwardMapping< InputStorageType, OutputStorageType >::Map ( const Image< InputStorageType > &  src,
Image< OutputStorageType > &  sink,
InterpolationMethod  interpolationQuality = MapTrilinear,
bool  newSink = false,
double  SuperSampling = 1.0 
)
inherited

backward mapping with various interpolations

Sink must be initialized with correct size and background color for invalid pixels. This way you can call it several times to create a panorama from several source images. For each pixel in sink, GetSourceCoordinates is called and the value in source interpolated.

Parameters
newSink,iftrue a new sink image is created that is large enough to hold the old sink and the new mapped src img.
SuperSamplingif > 1.0, intermediate image with isotropically enlarged width and height (by factor SuperSampling) is created and downsampled for the final image (most useful for nonlinear mappings)
Returns
0 on success, >0 means notification(such as 1 = not all pixels could be computed), -1 means failure

Definition at line 257 of file BackwardMapping.cpp.

References BIAS::ImageBase::GetChannelCount(), BIAS::ImageBase::GetColorModel(), BIAS::ImageBase::GetHeight(), BIAS::ImageBase::GetROI(), BIAS::ImageBase::GetWidth(), BIAS::ImageBase::IsEmpty(), BIAS::ImageBase::IsPlanar(), BIAS::BackwardMapping< InputStorageType, OutputStorageType >::Map(), BIAS::MapAnisotropic, BIAS::MapBicubic, BIAS::MapBilinear, BIAS::MapNearestNeighbor, BIAS::MapTrilinear, BIAS::AffineMapping< InputStorageType, OutputStorageType >::SetAffineTransformation(), and BIAS::ImageBase::SetZero().

Referenced by BIAS::ImageBlender::BlendImages(), BIAS::PMDImageProc::FitDepthTo2DImageHomogr_(), BIAS::PMDImageProc::FitDepthTo2DImageKOnly_(), and BIAS::BackwardMapping< InputStorageType, OutputStorageType >::Map().

template<class InputStorageType, class OutputStorageType>
int BIAS::BackwardMapping< InputStorageType, OutputStorageType >::Map ( Image< OutputStorageType > &  sink)
inherited

use this for subsequent calls to avoid pyramid recalculation when using tri-filtering

Definition at line 362 of file BackwardMapping.cpp.

References BIAS::MapTrilinear.

template<class InputStorageType, class OutputStorageType>
int BIAS::BackwardMapping< InputStorageType, OutputStorageType >::MapBi_ ( const Image< InputStorageType > &  source,
Image< OutputStorageType > &  sink,
InterpolationMethod  interpolationQuality 
)
protectedinherited
template<class InputStorageType , class OutputStorageType>
int BIAS::BackwardMapping< InputStorageType, OutputStorageType >::MapTri_ ( Image< OutputStorageType > &  sink)
protectedinherited

map image avoiding aliasing

This is almost correct regarding the sampling theorem, because it uses trilinear or anisotropic filtering over a pyramid. The local sampling frequency is estimated by analyzing the jacobian of the homography as a R^2->R^2 mapping. This is very slow. If possible, bicubic interpolation is done in the image, at borders (high pyramid levels) only bilinear.
In auto mode pyramid size is checked

Author
koeser 04/2005

Definition at line 527 of file BackwardMapping.cpp.

References BIAS::Image< StorageType >::FillImageWithConstValue(), BIAS::ImageBase::GetChannelCount(), BIAS::ImageBase::GetHeight(), BIAS::Image< StorageType >::GetImageDataArray(), BIAS::ImageBase::GetWidth(), BIAS::MapTrilinear, BIAS::ROI::Resize(), and BIAS::ROI::SetCorners().

template<class InputStorageType , class OutputStorageType>
int BIAS::BackwardMapping< InputStorageType, OutputStorageType >::MapTrilinearGreySimple_ ( Image< OutputStorageType > &  sink)
protectedinherited
template<class InputStorageType, class OutputStorageType>
int BIAS::BackwardMapping< InputStorageType, OutputStorageType >::MapWithLookupTable ( const Image< InputStorageType > &  src,
Image< OutputStorageType > &  sink,
InterpolationMethod  method 
)
inherited
template<class InputStorageType , class OutputStorageType >
TextureMapping< InputStorageType, OutputStorageType > & TextureMapping::operator= ( const TextureMapping< InputStorageType, OutputStorageType > &  src)

required because of const members

Author
Jan Woetzel

Definition at line 58 of file TextureMapping.cpp.

References BIAS::TextureTransform::Clone(), and BIAS::TextureMapping< InputStorageType, OutputStorageType >::T_.

template<class InputStorageType, class OutputStorageType>
int BIAS::BackwardMapping< InputStorageType, OutputStorageType >::PrepareLookupTableMapping ( const Image< InputStorageType > &  src,
Image< OutputStorageType > &  sink,
InterpolationMethod  method,
bool  newSink = false 
)
inherited
template<class InputStorageType, class OutputStorageType>
void BIAS::BackwardMapping< InputStorageType, OutputStorageType >::SetConcatenation ( BIAS::BackwardMapping< InputStorageType, OutputStorageType > *  pCon)
inlineinherited

avoid intermediate image and concatenate two backward mappings

Imagine that the source image is transformed with pcon into the intermediate image, which is then transformed by this into the sink

Definition at line 319 of file BackwardMapping.hh.

template<class InputStorageType , class OutputStorageType >
int BIAS::BackwardMapping< InputStorageType, OutputStorageType >::SetLookupTable ( const std::string &  filename,
InterpolationMethod method 
)
inherited

Loads the LUT from a file, replaces the call to PrepareLookupTableMapping().

Returns
the interpolation type in the parameter named method stored in the passed file.

Definition at line 1387 of file BackwardMapping.cpp.

template<class InputStorageType , class OutputStorageType >
int BIAS::BackwardMapping< InputStorageType, OutputStorageType >::SetLookupTable ( const float *  lutImageRow,
unsigned int  width,
InterpolationMethod method 
)
inherited
template<class InputStorageType , class OutputStorageType >
void BIAS::BackwardMapping< InputStorageType, OutputStorageType >::SetPyramidSize ( const int  newsize)
inherited

sets pyramid size to pyramid and updates if neccessary

Definition at line 194 of file BackwardMapping.cpp.

template<class InputStorageType, class OutputStorageType>
void BIAS::TextureMapping< InputStorageType, OutputStorageType >::SetTextureTransform ( const TextureTransform T)
inline

create clone of your texture tranform and set for mapping

Definition at line 62 of file TextureMapping.hh.

References BIAS::TextureTransform::Clone().

template<class InputStorageType , class OutputStorageType >
void BIAS::BackwardMapping< InputStorageType, OutputStorageType >::UpdatePyramidSize ( const ROI ROIsink,
int  srcwidth,
int  srcheight 
)
virtualinherited

uses corners of sink roi (and few other sample points) to estimate maximum local scaling (and thus required pyramid level)

Definition at line 99 of file BackwardMapping.cpp.

References BIAS::ROI::GetCorners(), and BIAS::Random::GetUniformDistributed().

Member Data Documentation

template<class InputStorageType, class OutputStorageType>
bool BIAS::BackwardMapping< InputStorageType, OutputStorageType >::aliasing_
protectedinherited

set to true if possibility of aliasing is detected during mapping

Definition at line 509 of file BackwardMapping.hh.

template<class InputStorageType, class OutputStorageType>
BIAS::Image<float> BIAS::BackwardMapping< InputStorageType, OutputStorageType >::alphaImg_
protectedinherited

has same size as overlap region used for blending

Definition at line 538 of file BackwardMapping.hh.

template<class InputStorageType, class OutputStorageType>
bool BIAS::BackwardMapping< InputStorageType, OutputStorageType >::autoPyramidSize_
protectedinherited

pyramid size set by user or computed automatically ?

Definition at line 491 of file BackwardMapping.hh.

template<class InputStorageType, class OutputStorageType>
double BIAS::BackwardMapping< InputStorageType, OutputStorageType >::height_
protectedinherited

source image height

Definition at line 535 of file BackwardMapping.hh.

template<class InputStorageType, class OutputStorageType>
bool BIAS::BackwardMapping< InputStorageType, OutputStorageType >::incomplete_
protectedinherited

set to true if not every pixel could be computed

Definition at line 512 of file BackwardMapping.hh.

template<class InputStorageType, class OutputStorageType>
InterpolationMethod BIAS::BackwardMapping< InputStorageType, OutputStorageType >::interpolationType_
protectedinherited

which interpolation method are we using

Definition at line 495 of file BackwardMapping.hh.

template<class InputStorageType, class OutputStorageType>
int BIAS::BackwardMapping< InputStorageType, OutputStorageType >::offsetX_
protectedinherited

needed for newDist

Definition at line 529 of file BackwardMapping.hh.

template<class InputStorageType, class OutputStorageType>
int BIAS::BackwardMapping< InputStorageType, OutputStorageType >::offsetY_
protectedinherited

Definition at line 529 of file BackwardMapping.hh.

template<class InputStorageType, class OutputStorageType>
BackwardMapping<InputStorageType, OutputStorageType>* BIAS::BackwardMapping< InputStorageType, OutputStorageType >::pConcatenation_
protectedinherited

Definition at line 540 of file BackwardMapping.hh.

template<class InputStorageType, class OutputStorageType>
BWM_LUT_Entry_Anisotropic* BIAS::BackwardMapping< InputStorageType, OutputStorageType >::pLUT_Ani_
protectedinherited

NOT IMPLEMENTED (YET ?)

Definition at line 525 of file BackwardMapping.hh.

template<class InputStorageType, class OutputStorageType>
BWM_LUT_Entry_Bicubic* BIAS::BackwardMapping< InputStorageType, OutputStorageType >::pLUT_Bic_
protectedinherited

Definition at line 526 of file BackwardMapping.hh.

template<class InputStorageType, class OutputStorageType>
BWM_LUT_Entry_Bilinear* BIAS::BackwardMapping< InputStorageType, OutputStorageType >::pLUT_Bil_
protectedinherited

Definition at line 517 of file BackwardMapping.hh.

template<class InputStorageType, class OutputStorageType>
int BIAS::BackwardMapping< InputStorageType, OutputStorageType >::pLUT_Bil_size
protectedinherited

Definition at line 521 of file BackwardMapping.hh.

template<class InputStorageType, class OutputStorageType>
BWM_LUT_Entry_Nearest* BIAS::BackwardMapping< InputStorageType, OutputStorageType >::pLUT_Nea_
protectedinherited

lookup-tables for precomputed positions in source, same size as dst.PixelCount

Definition at line 516 of file BackwardMapping.hh.

template<class InputStorageType, class OutputStorageType>
int BIAS::BackwardMapping< InputStorageType, OutputStorageType >::pLUT_Nea_size
protectedinherited

Definition at line 520 of file BackwardMapping.hh.

template<class InputStorageType, class OutputStorageType>
BWM_LUT_Entry_Trilinear* BIAS::BackwardMapping< InputStorageType, OutputStorageType >::pLUT_Tri_
protectedinherited

Definition at line 518 of file BackwardMapping.hh.

template<class InputStorageType, class OutputStorageType>
int BIAS::BackwardMapping< InputStorageType, OutputStorageType >::pLUT_Tri_size
protectedinherited

Definition at line 522 of file BackwardMapping.hh.

template<class InputStorageType, class OutputStorageType>
PyramidImage<InputStorageType> BIAS::BackwardMapping< InputStorageType, OutputStorageType >::pyramid_
protectedinherited

this contains a pyramid of the last source image for anti-aliasing

Definition at line 486 of file BackwardMapping.hh.

template<class InputStorageType, class OutputStorageType>
unsigned BIAS::BackwardMapping< InputStorageType, OutputStorageType >::pyramidSize_
protectedinherited

Definition at line 492 of file BackwardMapping.hh.

template<class InputStorageType, class OutputStorageType>
bool BIAS::BackwardMapping< InputStorageType, OutputStorageType >::rangeChecked_
protectedinherited

The interpolated value is computed in double; if clipped value is not specialized for your output storage type (e.g.

ushort), this boolean indicates that the generic conversion (e.g. double->ushort) could have introduced artefacts (65536.0 -> 1).

Definition at line 505 of file BackwardMapping.hh.

template<class InputStorageType, class OutputStorageType>
ROI BIAS::BackwardMapping< InputStorageType, OutputStorageType >::ROI_
protectedinherited

the roi of the last source image

Definition at line 488 of file BackwardMapping.hh.

template<class InputStorageType, class OutputStorageType>
double BIAS::BackwardMapping< InputStorageType, OutputStorageType >::superSampling_
protectedinherited

if larger than 1, super resolution is active

Definition at line 498 of file BackwardMapping.hh.

template<class InputStorageType, class OutputStorageType>
TextureTransform* BIAS::TextureMapping< InputStorageType, OutputStorageType >::T_
protected

Textures for backward mapping: Run over sink and compute source.

Definition at line 115 of file TextureMapping.hh.

Referenced by BIAS::TextureMapping< InputStorageType, OutputStorageType >::operator=().

template<class InputStorageType, class OutputStorageType>
double BIAS::BackwardMapping< InputStorageType, OutputStorageType >::width_
protectedinherited

source image width

Definition at line 532 of file BackwardMapping.hh.


The documentation for this class was generated from the following files: