|class||otb::ShiftScaleImageAdaptor< TImage, TOutputPixelType >|
|class||otb::Accessor::ShiftScalePixelAccessor< TPixelType, TExternalType >|
|class||otb::VectorImageToASImageAdaptor< TImage >|
|class||otb::Accessor::VectorImageToASPixelAccessor< T >|
Image Adaptors are an implementation of the Adaptor Design Pattern. They are designed to present an image of a particular type as being an image of a different type. Adaptors perform simple operations on pixel values for which is not easy to justify the use of an image filter.
One of the principal tasks of ImageAdaptors is to perform casting.
For example: you have an image whose pixels are of type
unsigned char and you need to feed this image in a process that expects pixels of type
double. You have the option of using and ImageFilter that convert the input
unsigned char image into another of pixel type
double. However this filter will allocate memory for this second image and will need to be executed. Image Adaptors allows you to simulating that you have made the conversion but will avoid the overhead in memory. There is however a penalty in performance.
The mechanism used by image adaptors is to provide a simple function that will be used by ImageIterator (see Image Iterators) to convert the value of a pixel, in a pixel-by-pixel basis.