Skip to content
Snippets Groups Projects
Commit 00089526 authored by Thomas Feuvrier's avatar Thomas Feuvrier
Browse files

Ajout de typedef dans la class VectorImage.

parent 8fb83ed2
No related branches found
No related tags found
No related merge requests found
......@@ -26,6 +26,7 @@
#include "otbImageBase.h"
#include "itkDefaultVectorPixelAccessorFunctor.h"
#include "itkDefaultVectorPixelAccessor.h"
#include "itkVectorImageNeighborhoodAccessorFunctor.h"
#include <iostream>
......@@ -43,12 +44,9 @@ class ITK_EXPORT VectorImage : public itk::VectorImage<TPixel, VImageDimension>,
{
public:
typedef TPixel InputPixelType;
/** Standard class typedefs. */
typedef VectorImage Self;
typedef itk::VectorImage<InputPixelType, VImageDimension> Superclass;
typedef itk::VectorImage<TPixel, VImageDimension> Superclass;
typedef itk::SmartPointer<Self> Pointer;
typedef itk::SmartPointer<const Self> ConstPointer;
......@@ -60,6 +58,25 @@ public:
/** Run-time type information (and related methods). */
itkTypeMacro(VectorImage, itk::VectorImage);
/** Pixel typedef support. Used to declare pixel type in filters
* or other operations. */
typedef typename Superclass::PixelType PixelType;
/** Typedef alias for PixelType */
typedef typename Superclass::ValueType ValueType;
/** Internal Pixel representation. Used to maintain a uniform API
* with Image Adaptors and allow to keep a particular internal
* representation of data while showing a different external
* representation. */
typedef typename Superclass::InternalPixelType InternalPixelType;
typedef typename Superclass::IOPixelType IOPixelType;
/** Accessor type that convert data between internal and external
* representations. */
typedef itk::DefaultVectorPixelAccessor< InternalPixelType > AccessorType;
/** Functor to provide a common API between DefaultPixelAccessor and
* DefaultVectorPixelAccessor */
typedef itk::DefaultVectorPixelAccessorFunctor< Self > AccessorFunctorType;
......@@ -68,6 +85,39 @@ public:
typedef itk::VectorImageNeighborhoodAccessorFunctor<
Self > NeighborhoodAccessorFunctorType;
/** Dimension of the image. This constant is used by functions that are
* templated over image type (as opposed to being templated over pixel type
* and dimension) when they need compile time access to the dimension of
* the image. */
itkStaticConstMacro(ImageDimension, unsigned int, VImageDimension);
/** Container used to store pixels in the image. */
typedef typename Superclass::PixelContainer PixelContainer;
/** Index typedef support. An index is used to access pixel values. */
typedef typename Superclass::IndexType IndexType;
/** Offset typedef support. An offset is used to access pixel values. */
typedef typename Superclass::OffsetType OffsetType;
/** Size typedef support. A size is used to define region bounds. */
typedef typename Superclass::SizeType SizeType;
/** Direction typedef support. A matrix of direction cosines. */
typedef typename Superclass::DirectionType DirectionType;
/** Region typedef support. A region is used to specify a subset of an image. */
typedef typename Superclass::RegionType RegionType;
/** Spacing typedef support. Spacing holds the size of a pixel. The
* spacing is the geometric distance between image samples. */
typedef typename Superclass::SpacingType SpacingType;
/** Origin typedef support. The origin is the geometric coordinates
* of the index (0,0). */
typedef typename Superclass::PointType PointType;
/** Get the projection coordinate system of the image. */
virtual std::string GetProjectionRef( void );
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment