version 3.3

VRS::ImageCopyOp Class Reference

Monadic image operations. More...

#include <vrs/image/imagecopyop.h>

Inheritance diagram for VRS::ImageCopyOp:

VRS::ImageManipulator VRS::SharedObj VRS::Visitable

List of all members.

Public Types

enum  Operation { CopyImage, CopyLayer, CopyGreyScale, Exchange }

Public Member Functions

 VRS_SERIALIZABLE_CLASS_ENUM (Operation)
 ImageCopyOp (int opType, int srcLayer=0, int dstLayer=0, bool scale=true, bool ignoreROIandLOI=false)
void setOperation (int opType)
int getOperation () const
 Sets/returns the operation type of the copy-operation object.
void setSourceLayer (int srcLayer)
void setDestLayer (int dstLayer)
int getSourceLayer () const
int getDestLayer () const
virtual Imagemanipulate (Image *source, Image *target)
virtual bool operatesInPlace () const
 VRS_TYPEINFO (ImageCopyOp, ImageManipulator)

Static Public Member Functions

static void copyImage (Image *src, Image *dst, bool scale=true, bool ignoreROIandLOI=false)
static void copyLayer (Image *src, Image *dst, int srcLayer, int dstLayer, bool scale=true, bool ignoreROIandLOI=false)
static void copyGreyScale (Image *src, Image *dst, bool scale=true, bool ignoreROIandLOI=false)
static void exchange (Image *src, Image *dst, bool scale=true, bool ignoreROIandLOI=false)


Detailed Description

Monadic image operations.

Member Enumeration Documentation

Enumerator:
CopyImage 
CopyLayer 
CopyGreyScale 
Exchange 


Constructor & Destructor Documentation

VRS::ImageCopyOp::ImageCopyOp ( int  opType,
int  srcLayer = 0,
int  dstLayer = 0,
bool  scale = true,
bool  ignoreROIandLOI = false 
)

A copy-operation object encapsulates one copy operation applied to a source and a target image. The CopyLayer- operation requires the parameter 'srcLayer' and 'dstLayer' which must be one of the values of Image::Layers (e.g. Image::Red, Image::Luminance, ...). The other copy-operations ignore these values. If the source and destination regions have different sizes the source image will be

  • scaled during copying ('scale' == true) to fit into the destination region
  • aligned to the lower-left corner of the destination region without scaling ('scale' == false). By default, the copy operations take care of the OIs and LOIs set for the source and destination image but you can disable this behaviour by setting 'ignoreROIandLOI' to true. The copy-operation object can form part of an operation sequence, e.g., ManipulatorList. All copy operations are accessible also as static methods which can be invoked directly. The Image class contains methods which access the copy operations in a more convienent way.


Member Function Documentation

VRS::ImageCopyOp::VRS_SERIALIZABLE_CLASS_ENUM ( Operation   ) 

void VRS::ImageCopyOp::setOperation ( int  opType  ) 

int VRS::ImageCopyOp::getOperation (  )  const

Sets/returns the operation type of the copy-operation object.

void VRS::ImageCopyOp::setSourceLayer ( int  srcLayer  ) 

void VRS::ImageCopyOp::setDestLayer ( int  dstLayer  ) 

int VRS::ImageCopyOp::getSourceLayer (  )  const

int VRS::ImageCopyOp::getDestLayer (  )  const

Sets/returns the corresponding layer. All but the CopyLayer- operation ignore these values.

virtual Image* VRS::ImageCopyOp::manipulate ( Image srcImage,
Image dstImage 
) [virtual]

The image operation is apply to the source image and the the resulting image is stored in the target image. The handle of the target image is returned.

Implements VRS::ImageManipulator.

virtual bool VRS::ImageCopyOp::operatesInPlace (  )  const [virtual]

See `ImageManipulator'. This manipulator can operate in place.

Reimplemented from VRS::ImageManipulator.

static void VRS::ImageCopyOp::copyImage ( Image src,
Image dst,
bool  scale = true,
bool  ignoreROIandLOI = false 
) [static]

static void VRS::ImageCopyOp::copyLayer ( Image src,
Image dst,
int  srcLayer,
int  dstLayer,
bool  scale = true,
bool  ignoreROIandLOI = false 
) [static]

static void VRS::ImageCopyOp::copyGreyScale ( Image src,
Image dst,
bool  scale = true,
bool  ignoreROIandLOI = false 
) [static]

static void VRS::ImageCopyOp::exchange ( Image src,
Image dst,
bool  scale = true,
bool  ignoreROIandLOI = false 
) [static]

VRS::ImageCopyOp::VRS_TYPEINFO ( ImageCopyOp  ,
ImageManipulator   
)


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

Generated on Mon May 21 06:00:18 2012 by Doxygen 1.5.6
© 2001-2010 Hasso-Plattner-Institut | Impressum | Contact