DGtal 1.4.0
|
#include <DGtal/io/viewers/Viewer3D.h>
Public Member Functions | |
~TextureImage () | |
the mode of representation of the image | |
TextureImage (const TextureImage &img) | |
Copy constructor (needed due to myTabImage) | |
template<typename TImageType , typename TFunctor > | |
TextureImage (const TImageType &image, const TFunctor &aFunctor, ImageDirection normalDir=zDirection, double xBottomLeft=0.0, double yBottomLeft=0.0, double zBottomLeft=0.0, TextureMode aMode=GrayScaleMode) | |
void | updateImageOrientation (ImageDirection normalDir, double xBottomLeft, double yBottomLeft, double zBottomLeft) |
void | updateImage3DEmbedding (RealPoint aPoint1, RealPoint aPoint2, RealPoint aPoint3, RealPoint aPoint4) |
template<typename TImageType , typename TFunctor > | |
void | updateImageDataAndParam (const TImageType &image, const TFunctor &aFunctor, double xTranslation=0.0, double yTranslation=0.0, double zTranslation=0.0) |
std::string | className () const |
Data Fields | |
RealPoint | point1 |
RealPoint | point2 |
RealPoint | point3 |
RealPoint | point4 |
ImageDirection | myDirection |
unsigned int | myImageWidth |
direction of the image (x, y or z axe) | |
unsigned int | myImageHeight |
the width of the image | |
unsigned int * | myTabImage |
the height of the image | |
bool | myDrawDomain |
for each pixel of the image, color or height ? | |
unsigned int | myIndexDomain |
true if the draw have a domain | |
TextureMode | myMode |
index of the image domain if exist | |
Private Member Functions | |
TextureImage () | |
Used to display an image as a textured quad image.
Definition at line 565 of file Viewer3D.h.
|
inline |
the mode of representation of the image
Destructor
Definition at line 587 of file Viewer3D.h.
References DGtal::Viewer3D< TSpace, TKSpace >::TextureImage::myTabImage.
|
inline |
Copy constructor (needed due to myTabImage)
img | the image |
Definition at line 596 of file Viewer3D.h.
References DGtal::Viewer3D< TSpace, TKSpace >::TextureImage::myTabImage.
|
inline |
Constructor that fills image parameters from std image (image buffer, dimensions, vertex coordinates, orientation)
TImageType | the type of the image given for the constructor (should follow the CConstImage concept). |
TFunctor | the functor type (should follow the CUnaryFunctor concept with image value type as input type and unsigned int as output type). |
image | the source image. |
aFunctor | a functor to transform input values to the output displayed values. |
normalDir | the direction of normal vector of the image plane (xDirection, yDirection or zDirection (default)) . |
xBottomLeft | the x coordinate of bottom left image point (default 0). |
yBottomLeft | the x coordinate of bottom left image point (default 0). |
zBottomLeft | the x coordinate of bottom left image point (default 0). |
aMode | the mode of representation (default GrayScaleMode). |
Definition at line 642 of file Viewer3D.h.
References DGtal::Viewer3D< TSpace, TKSpace >::BOOST_CONCEPT_ASSERT(), DGtal::Viewer3D< TSpace, TKSpace >::TextureImage::myDirection, DGtal::Viewer3D< TSpace, TKSpace >::TextureImage::myDrawDomain, DGtal::Viewer3D< TSpace, TKSpace >::TextureImage::myImageHeight, DGtal::Viewer3D< TSpace, TKSpace >::TextureImage::myImageWidth, DGtal::Viewer3D< TSpace, TKSpace >::TextureImage::myMode, DGtal::Viewer3D< TSpace, TKSpace >::TextureImage::myTabImage, DGtal::Viewer3D< TSpace, TKSpace >::TextureImage::updateImageDataAndParam(), and DGtal::Viewer3D< TSpace, TKSpace >::TextureImage::updateImageOrientation().
|
inlineprivate |
std::string DGtal::Viewer3D< TSpace, TKSpace >::TextureImage::className | ( | ) | const |
return the class name to implement the CDrawableWithViewer3D concept.
|
inline |
Update the embedding of the image by updating the image 3D vertex.
aPoint1 | the first image point (lower bound point) |
aPoint2 | the second image point (upper bound point in first dimension and lower in the second dimentsion) |
aPoint3 | the third image point (upper bound point in first second dimentsion) |
aPoint4 | the fourth image point (lower bound point in first dimension and upper in the second dimentsion) |
Definition at line 680 of file Viewer3D.h.
References DGtal::Viewer3D< TSpace, TKSpace >::TextureImage::myDirection, DGtal::Viewer3D< TSpace, TKSpace >::TextureImage::point1, DGtal::Viewer3D< TSpace, TKSpace >::TextureImage::point2, DGtal::Viewer3D< TSpace, TKSpace >::TextureImage::point3, DGtal::Viewer3D< TSpace, TKSpace >::TextureImage::point4, and DGtal::Viewer3D< TSpace, TKSpace >::undefDirection.
|
inline |
Update the image parameters from std image (image buffer, vertex coordinates) The new image should be with same dimension than the original.
TImageType | the type of the image given for the constructor (should follow the CConstImage concept). |
TFunctor | the functor type (should follow the CUnaryFunctor concept with image value type as input type and unsigned int as output type). |
image | the source image. |
aFunctor | a functor to transform input values to the output displayed values. |
xTranslation | the image translation in the x direction (default 0). |
yTranslation | the image translation in the y direction (default 0). |
zTranslation | the image translation in the z direction (default 0). |
Definition at line 706 of file Viewer3D.h.
References DGtal::Viewer3D< TSpace, TKSpace >::BOOST_CONCEPT_ASSERT(), DGtal::Viewer3D< TSpace, TKSpace >::TextureImage::myImageHeight, DGtal::Viewer3D< TSpace, TKSpace >::TextureImage::myImageWidth, DGtal::Viewer3D< TSpace, TKSpace >::TextureImage::myTabImage, DGtal::Viewer3D< TSpace, TKSpace >::TextureImage::point1, DGtal::Viewer3D< TSpace, TKSpace >::TextureImage::point2, DGtal::Viewer3D< TSpace, TKSpace >::TextureImage::point3, and DGtal::Viewer3D< TSpace, TKSpace >::TextureImage::point4.
Referenced by DGtal::Viewer3D< TSpace, TKSpace >::TextureImage::TextureImage().
void DGtal::Viewer3D< TSpace, TKSpace >::TextureImage::updateImageOrientation | ( | ImageDirection | normalDir, |
double | xBottomLeft, | ||
double | yBottomLeft, | ||
double | zBottomLeft ) |
Update the image direction from a specific normal direction (Viewer3D::xDirection, Viewer3D::yDirection or Viewer3D::zDirection) and image position from the botton left point.
normalDir | give a predifined normal orientation can be (Viewer3D::xDirection, Viewer3D::yDirection or Viewer3D::zDirection) |
xBottomLeft | the x coordinate of bottom left image point. |
yBottomLeft | the x coordinate of bottom left image point. |
zBottomLeft | the x coordinate of bottom left image point. |
Referenced by DGtal::Viewer3D< TSpace, TKSpace >::TextureImage::TextureImage().
ImageDirection DGtal::Viewer3D< TSpace, TKSpace >::TextureImage::myDirection |
bool DGtal::Viewer3D< TSpace, TKSpace >::TextureImage::myDrawDomain |
for each pixel of the image, color or height ?
Definition at line 580 of file Viewer3D.h.
Referenced by DGtal::Viewer3D< TSpace, TKSpace >::TextureImage::TextureImage().
unsigned int DGtal::Viewer3D< TSpace, TKSpace >::TextureImage::myImageHeight |
the width of the image
Definition at line 576 of file Viewer3D.h.
Referenced by DGtal::Viewer3D< TSpace, TKSpace >::GLTextureImage::GLTextureImage(), DGtal::Viewer3D< TSpace, TKSpace >::TextureImage::TextureImage(), and DGtal::Viewer3D< TSpace, TKSpace >::TextureImage::updateImageDataAndParam().
unsigned int DGtal::Viewer3D< TSpace, TKSpace >::TextureImage::myImageWidth |
direction of the image (x, y or z axe)
Definition at line 575 of file Viewer3D.h.
Referenced by DGtal::Viewer3D< TSpace, TKSpace >::GLTextureImage::GLTextureImage(), DGtal::Viewer3D< TSpace, TKSpace >::TextureImage::TextureImage(), and DGtal::Viewer3D< TSpace, TKSpace >::TextureImage::updateImageDataAndParam().
unsigned int DGtal::Viewer3D< TSpace, TKSpace >::TextureImage::myIndexDomain |
true if the draw have a domain
Definition at line 581 of file Viewer3D.h.
TextureMode DGtal::Viewer3D< TSpace, TKSpace >::TextureImage::myMode |
index of the image domain if exist
Definition at line 582 of file Viewer3D.h.
Referenced by DGtal::Viewer3D< TSpace, TKSpace >::GLTextureImage::GLTextureImage(), and DGtal::Viewer3D< TSpace, TKSpace >::TextureImage::TextureImage().
unsigned int* DGtal::Viewer3D< TSpace, TKSpace >::TextureImage::myTabImage |
the height of the image
Definition at line 578 of file Viewer3D.h.
Referenced by DGtal::Viewer3D< TSpace, TKSpace >::GLTextureImage::GLTextureImage(), DGtal::Viewer3D< TSpace, TKSpace >::TextureImage::TextureImage(), DGtal::Viewer3D< TSpace, TKSpace >::TextureImage::TextureImage(), DGtal::Viewer3D< TSpace, TKSpace >::TextureImage::updateImageDataAndParam(), and DGtal::Viewer3D< TSpace, TKSpace >::TextureImage::~TextureImage().
RealPoint DGtal::Viewer3D< TSpace, TKSpace >::TextureImage::point1 |
RealPoint DGtal::Viewer3D< TSpace, TKSpace >::TextureImage::point2 |
RealPoint DGtal::Viewer3D< TSpace, TKSpace >::TextureImage::point3 |
RealPoint DGtal::Viewer3D< TSpace, TKSpace >::TextureImage::point4 |