Open CASCADE Technology  6.5.4
 All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Defines
Public Member Functions | Protected Member Functions
Image_DIndexedImage Class Reference

#include <Image_DIndexedImage.hxx>

Inheritance diagram for Image_DIndexedImage:
Inheritance graph
[legend]

Public Member Functions

virtual void Destroy ()
 Image destructor.

 ~Image_DIndexedImage ()
void SetBackgroundPixel (const Aspect_IndexPixel &aPixel)
const Aspect_IndexPixelBackgroundPixel () const
const Aspect_IndexPixelPixel (const Standard_Integer X, const Standard_Integer Y) const
const Aspect_IndexPixeloperator() (const Standard_Integer X, const Standard_Integer Y) const
void SetPixel (const Standard_Integer X, const Standard_Integer Y, const Aspect_IndexPixel &aPixel)
Aspect_IndexPixelMutPixel (const Standard_Integer X, const Standard_Integer Y)
Aspect_IndexPixeloperator() (const Standard_Integer X, const Standard_Integer Y)
void SetRow (const Standard_Integer X, const Standard_Integer Y, const Image_PixelRowOfDIndexedImage &aRow)
void Row (const Standard_Integer X, const Standard_Integer Y, Image_PixelRowOfDIndexedImage &aRow) const
void SwapRow (const Standard_Integer I, const Standard_Integer J)
void SwapCol (const Standard_Integer I, const Standard_Integer J)
void Zoom (const Image_PixelInterpolation &anInterpolation, const Standard_Real aCoefX, const Standard_Real aCoefY)
void Rotate (const Image_PixelInterpolation &anInterpolation, const Quantity_PlaneAngle aAngle)
void Translate (const Image_PixelInterpolation &anInterpolation, const Standard_Real DX, const Standard_Real DY)
void Affine (const Image_PixelInterpolation &anInterpolation, const gp_GTrsf2d &Trsf)
void Affine (const Image_PixelInterpolation &anInterpolation, const gp_Trsf &Trsf)
virtual void InternalDup (const Handle< Image_Image > &anImage)
 Duplicates an Image.

void SetOrigin (const Standard_Integer x, const Standard_Integer y)
 Sets Image origin, for Rotation, copy between image ...
Image origin is on the TOP LEFT . Y axis goes TOP to
DOWN , X axis goes LEFT to RIGHT.

Standard_Integer LowerX () const
 Returns the lower X Image coordinate ( X Origin ).

Standard_Integer UpperX () const
 Returns the upper X Image coordinate
( X Origin + Image width - 1 ).

Standard_Integer Width () const
 Returns the Image width.

Standard_Integer LowerY () const
 Returns the lower Y Image coordinate ( Y Origin ).

Standard_Integer UpperY () const
 Returns the upper Y Image coordinate
( Y Origin + Image height - 1 ).

Standard_Integer Height () const
 Returns the Image height.

void Resize (const Standard_Real XOffset, const Standard_Real XScale, const Standard_Real YOffset, const Standard_Real YScale)
 Resize an Image. Image Pixel are left unchanged at there
absolute positon. Resulting Image can be clipped.
newLowerX = LowerX()*XScale + XOffset
newLowerY = LowerY()*YScale + YOffset
newUpperX = UpperX()*XScale + XOffset
newUpperY = UpperY()*YScale + YOffset
newWidth = Width() *XScale
newHeight = Height()*YScale

virtual Image_TypeOfImage Type () const =0
 Returns the ImageType TOI_ColorImage or TOI_PseudoColorImage

Standard_Boolean isSamePixel (const Standard_Integer X, const Standard_Integer Y, const Handle< Image_Image > &anotherImage, const Standard_Integer anotherX, const Standard_Integer anotherY) const
 Returns True if me->Pixel(X,Y) is equal to
anotherImage->Pixel(anotherX,anotherY)

void Pixel (const Standard_Integer X, const Standard_Integer Y, Aspect_Pixel &aPixel) const
 Get the Image Pixel Value at X,Y coordinate in aPixel.
Warning: aPixel must have the same type than Image Pixel.

void SetPixel (const Standard_Integer X, const Standard_Integer Y, const Aspect_Pixel &aPixel)
 Store aPixel in the Image at X,Y coordinate .
Warning: aPixel must have the same type than Image Pixel.

void Pixel (const Standard_Integer X, const Standard_Integer Y, Image_PixelAddress &aPixel) const
 Get the Image Pixel Value at X,Y coordinate in aPixel.
Warning: aPixel must have the same type than Image Pixel.

void SetPixel (const Standard_Integer X, const Standard_Integer Y, const Image_PixelAddress &aPixel)
 Store aPixel in the Image at X,Y coordinate .
Warning: aPixel must have the same type than Image Pixel.

void Transpose (const Image_FlipType aType)
 Transpose an Image( flipping across horizontal axis or
vertical axis, or across diagonal... )
This geometric transformation preserves all Image Pixels.
We don't need to interpolate pixels .
Warning : Image size change during Transpose.

void Clip (const Standard_Integer X, const Standard_Integer Y, const Standard_Integer Width, const Standard_Integer Height)
 Extract a SubImage starting at coordinate X,Y
to (X+Width-1),(Y+Height-1).
Warning : the Image size and origin change, new origin
is X,Y ; new size is Width,Height.

void Shift (const Standard_Integer XShifth, const Standard_Integer YShift)
 Translate an Image XShift pixel Right, YShift Down .
Shift parameter are Integer value.

void Fill (const Handle< Image_Image > &SrcImage)
 Fill me with SrcImage. SrcImage pixel are copied starting
at SrcImage->LowerX(),SrcImage->LowerY() in MyPixelField.
SrcImage Pixel are clipped outside <me>.

void Fill (const Handle< Image_Image > &SrcImage, const Standard_Integer SrcX, const Standard_Integer SrcY, const Standard_Integer SrcWidth, const Standard_Integer SrcHeight, const Standard_Integer X, const Standard_Integer Y)
 Fill me with a SubImage of SrcImage starting from
SrcX, SrcY to (SrcX+SrcWidth-1),(SrcY+SrcHeight-1) in
Src Image coordinate. SrcImage SubImage pixels are copied
starting at X,Y in MyPixelField.
SrcImage Pixel are clipped outside <me>.

void FillRect (const Aspect_IndexPixel &aPixel, const Standard_Integer X, const Standard_Integer Y, const Standard_Integer Width, const Standard_Integer Height)
void DrawRect (const Aspect_IndexPixel &aPixel, const Standard_Integer X, const Standard_Integer Y, const Standard_Integer Width, const Standard_Integer Height)
void DrawLine (const Aspect_IndexPixel &aPixel, const Standard_Integer X1, const Standard_Integer Y1, const Standard_Integer X2, const Standard_Integer Y2)
void Clear ()
 Fill the entire Image with the BackgroundPixel.

void Dump () const
 Debug

Protected Member Functions

 Image_DIndexedImage (const Standard_Integer x, const Standard_Integer y, const Standard_Integer dx, const Standard_Integer dy, const Aspect_IndexPixel &BackPixel)

Constructor & Destructor Documentation


Member Function Documentation

Implements Image_Image.

Implements Image_Image.

virtual void Image_DIndexedImage::Destroy ( ) [virtual]

Reimplemented from Image_Image.

void Image_DIndexedImage::Dump ( ) const [virtual]

Implements Image_Image.

void Image_DIndexedImage::Fill ( const Handle< Image_Image > &  SrcImage) [virtual]

Implements Image_Image.

Implements Image_Image.

Implements Image_Image.

virtual void Image_DIndexedImage::InternalDup ( const Handle< Image_Image > &  anImage) [virtual]

Implements Image_Image.

Implements Image_Image.

Implements Image_Image.

Implements Image_Image.

const Aspect_IndexPixel& Image_DIndexedImage::operator() ( const Standard_Integer  X,
const Standard_Integer  Y 
) const [inline]
Aspect_IndexPixel& Image_DIndexedImage::operator() ( const Standard_Integer  X,
const Standard_Integer  Y 
) [inline]

Implements Image_Image.

Implements Image_Image.

Implements Image_Image.

Implements Image_Image.

Implements Image_Image.

Implements Image_Image.

Implements Image_Image.

Implements Image_Image.

virtual Image_TypeOfImage Image_DIndexedImage::Type ( ) const [pure virtual]

Implements Image_Image.

Implemented in Image_PseudoColorImage.

Implements Image_Image.

Implements Image_Image.

Implements Image_Image.


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