Version: 9.12.0
ImageComposer_CropOperator Class Reference

Implementation of the cropping operator. More...

#include <ImageComposer_CropOperator.h>

Inheritance diagram for ImageComposer_CropOperator:
Inheritance graph

Public Member Functions

 ImageComposer_CropOperator ()
 Constructor. More...
 
virtual ~ImageComposer_CropOperator ()
 
virtual QString name () const
 Return name of the operator. More...
 
virtual ImageComposer_Image process (const QVariant &theObj1, const QVariant &theObj2) const
 Perform the composing of images. More...
 
- Public Member Functions inherited from ImageComposer_Operator
 ImageComposer_Operator ()
 Constructor. More...
 
virtual ~ImageComposer_Operator ()
 Destructor. More...
 
void getArgs (QColor &theBackground) const
 Get operator arguments. More...
 
void setArgs (const QColor &theBackground)
 Set operator arguments. More...
 
QByteArray getBinArgs () const
 Get the operator's arguments in the form of a binary array. More...
 
void setBinArgs (const QByteArray &)
 Set the operator's arguments in the form of a binary array. More...
 
QStringList dumpArgsToPython (QString &theArrayName) const
 Dumps arguments of operator to python script representation. More...
 

Static Public Member Functions

static QString Type ()
 

Protected Member Functions

virtual QRectF calcResultBoundingRect (const QVariant &theObj1, const QVariant &theObj2) const
 Calculate bounding rectangle for the result image. More...
 
virtual void drawResult (QPainter &thePainter, const QVariant &theObj1, const QVariant &theObj2) const
 Draw result image using the given painter. More...
 
- Protected Member Functions inherited from ImageComposer_Operator
virtual void storeArgs (QDataStream &theStream) const
 Store the operator's arguments to the stream. More...
 
virtual void restoreArgs (QDataStream &theStream)
 Restore the operator's arguments from the stream. More...
 

Friends

class ImageComposerTests_TestOperators
 

Detailed Description

Implementation of the cropping operator.

Constructor & Destructor Documentation

◆ ImageComposer_CropOperator()

ImageComposer_CropOperator::ImageComposer_CropOperator ( )

Constructor.

◆ ~ImageComposer_CropOperator()

ImageComposer_CropOperator::~ImageComposer_CropOperator ( )
virtual

Member Function Documentation

◆ calcResultBoundingRect()

QRectF ImageComposer_CropOperator::calcResultBoundingRect ( const QVariant &  theObj1,
const QVariant &  theObj2 
) const
protectedvirtual

Calculate bounding rectangle for the result image.

Parameters
theObj1first object to calculate
theObj2second object to calculate
Returns
calculated bounding rectangle

Implements ImageComposer_Operator.

◆ drawResult()

void ImageComposer_CropOperator::drawResult ( QPainter &  thePainter,
const QVariant &  theObj1,
const QVariant &  theObj2 
) const
protectedvirtual

Draw result image using the given painter.

Parameters
thePainterthe painter on the result image
theObj1the first object to compose
theObj2the second object to compose

Implements ImageComposer_Operator.

References ImageComposer_Image::boundingRect(), and ImageComposer_Image::draw().

◆ name()

QString ImageComposer_CropOperator::name ( ) const
virtual

Return name of the operator.

Returns
name of the operator

Implements ImageComposer_Operator.

References Type().

◆ process()

ImageComposer_Image ImageComposer_CropOperator::process ( const QVariant &  theObj1,
const QVariant &  theObj2 
) const
virtual

Perform the composing of images.

Parameters
theObj1the first object to compose
theObj2the second object to compose
Returns
the result image

Reimplemented from ImageComposer_Operator.

References ImageComposer_Operator::process(), and ImageComposer_Image::transform().

◆ Type()

static QString ImageComposer_CropOperator::Type ( )
inlinestatic

Friends And Related Function Documentation

◆ ImageComposerTests_TestOperators

friend class ImageComposerTests_TestOperators
friend

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