version 3.3

VRS::ImageRegionOp Class Reference

Image region operations. More...

#include <vrs/image/imageregionop.h>

Inheritance diagram for VRS::ImageRegionOp:

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

List of all members.

Public Types

enum  Operation { Flip, Blur, Mosaic }

Public Member Functions

 VRS_SERIALIZABLE_CLASS_ENUM (Operation)
 ImageRegionOp (int opType, int value1, int value2)
void setOperation (int opType)
int getOperation () const
 Sets/returns the operation type of the pixel-operation object.
void setValue (int valueNo, int value)
int getValue (int valueNo) const
virtual Imagemanipulate (Image *source, Image *target)
virtual bool operatesInPlace () const
 VRS_TYPEINFO (ImageRegionOp, ImageManipulator)

Static Public Member Functions

static void flip (Image *srcImage, Image *dstImage, int flipX, int flipY)
static void blur (Image *srcI, Image *dstI, int sizeX, int sizeY)
 Replaces the pixel value by the average pixel value of its neighborhood.
static void mosaic (Image *srcI, Image *dstI, int sizeX, int sizeY)


Detailed Description

Image region operations.

Member Enumeration Documentation

Enumerator:
Flip 
Blur 
Mosaic 


Constructor & Destructor Documentation

VRS::ImageRegionOp::ImageRegionOp ( int  opType,
int  value1,
int  value2 
)

A region-operation object encapsulate one region-operation applied to a source image. Most operation types require two parameters, which can be set separately. The region-operation object can form part of an operation seuquence, e.g., ManipulatorList. All operations are accessible also as static methods which can be invoked directly. The Image class contains methods which access the region oerations in a more convienent way.


Member Function Documentation

VRS::ImageRegionOp::VRS_SERIALIZABLE_CLASS_ENUM ( Operation   ) 

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

int VRS::ImageRegionOp::getOperation (  )  const

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

void VRS::ImageRegionOp::setValue ( int  valueNo,
int  value 
)

int VRS::ImageRegionOp::getValue ( int  valueNo  )  const

Sets/returns the parameter value used by the operation. The parameters are defined as follows for the operations: flip: 2 parameter, horizontal flag, vertical flag blur: 2 parameter, size x, size y mosaic: 2 parameter, size x, size y grey-scale: no parameter

virtual Image* VRS::ImageRegionOp::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::ImageRegionOp::operatesInPlace (  )  const [virtual]

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

Reimplemented from VRS::ImageManipulator.

static void VRS::ImageRegionOp::flip ( Image srcImage,
Image dstImage,
int  flipX,
int  flipY 
) [static]

If flipX is set, the image is flipped horizontally. If flipY is set, the image is flipped vertically.

static void VRS::ImageRegionOp::blur ( Image srcI,
Image dstI,
int  sizeX,
int  sizeY 
) [static]

Replaces the pixel value by the average pixel value of its neighborhood.

static void VRS::ImageRegionOp::mosaic ( Image srcI,
Image dstI,
int  sizeX,
int  sizeY 
) [static]

Tiles the image into blocks of sizeX x sizeY. Replaces the pixel value within a block by the average pixel value in the block.

VRS::ImageRegionOp::VRS_TYPEINFO ( ImageRegionOp  ,
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