Isis 3 Programmer Reference
Isis::ProcessByBrick::ProcessCubeInPlaceFunctor< T > Class Template Reference

Process a cube in place (one input/zero output or zero input/one output or one cube that acts both as input and output). More...

Inheritance diagram for Isis::ProcessByBrick::ProcessCubeInPlaceFunctor< T >:
Inheritance graph
Collaboration diagram for Isis::ProcessByBrick::ProcessCubeInPlaceFunctor< T >:
Collaboration graph

Public Member Functions

 ProcessCubeInPlaceFunctor (Cube *cube, const Brick *templateBrick, bool readInput, bool writeOutput, const T &processingFunctor)
 Construct a ProcessCubeInPlaceFunctor.
 
 ProcessCubeInPlaceFunctor (const ProcessCubeInPlaceFunctor &other)
 Copy construction of these objects is fully supported.
 
virtual ~ProcessCubeInPlaceFunctor ()
 Destructor.
 
void * operator() (const int &brickPosition) const
 Do the work for one position in a cube.
 
ProcessCubeInPlaceFunctoroperator= (const ProcessCubeInPlaceFunctor &rhs)
 Assignment of these objects is fully supported.
 

Private Attributes

Cubem_cube
 The cube we're I/O'ing on.
 
const Brickm_templateBrick
 A brick with the right dimensions, pixel type, etc. for processing.
 
bool m_readInput
 Should we read from the cube before processing.
 
bool m_writeOutput
 Should we write to the output cube after processing.
 
const T & m_processingFunctor
 The functor which does the work/arbitrary calculations.
 

Detailed Description

template<typename T>
class Isis::ProcessByBrick::ProcessCubeInPlaceFunctor< T >

Process a cube in place (one input/zero output or zero input/one output or one cube that acts both as input and output).

Given a ProcessIterator position, this runs the functor passed into ProcessCubeInPlace with the appropriate data.

This functor is a helper for the ProcessCubeInPlace() public method. This is designed to be passed into QtConcurrent::mapped to operate over a cube.

Author
2012-02-22 Steven Lambright

Definition at line 323 of file ProcessByBrick.h.

Constructor & Destructor Documentation

◆ ProcessCubeInPlaceFunctor() [1/2]

template<typename T >
Isis::ProcessByBrick::ProcessCubeInPlaceFunctor< T >::ProcessCubeInPlaceFunctor ( Cube * cube,
const Brick * templateBrick,
bool readInput,
bool writeOutput,
const T & processingFunctor )
inline

Construct a ProcessCubeInPlaceFunctor.

This doesn't take ownership of the passed in pointers but expects them to not be deleted.

Parameters
cubeThe input (or output) cube we're processing
templateBrickA brick initialized for use with the processingFunctor
readInputTrue if we should read the cube into the brick before calling the processingFunctor.
writeOutputTrue if we should write the resulting brick from the processingFunctor into the cube
processingFunctorThe functor supplied to ProcessCubeInPlace() which actually does the work/ calculations.

Definition at line 341 of file ProcessByBrick.h.

◆ ProcessCubeInPlaceFunctor() [2/2]

template<typename T >
Isis::ProcessByBrick::ProcessCubeInPlaceFunctor< T >::ProcessCubeInPlaceFunctor ( const ProcessCubeInPlaceFunctor< T > & other)
inline

Copy construction of these objects is fully supported.

Parameters
otherThe functor to copy

Definition at line 358 of file ProcessByBrick.h.

◆ ~ProcessCubeInPlaceFunctor()

Member Function Documentation

◆ operator()()

◆ operator=()

Member Data Documentation

◆ m_cube

◆ m_processingFunctor

template<typename T >
const T& Isis::ProcessByBrick::ProcessCubeInPlaceFunctor< T >::m_processingFunctor
private

The functor which does the work/arbitrary calculations.

Definition at line 429 of file ProcessByBrick.h.

Referenced by Isis::ProcessByBrick::ProcessCubeInPlaceFunctor< T >::operator()(), and Isis::ProcessByBrick::ProcessCubeInPlaceFunctor< T >::operator=().

◆ m_readInput

template<typename T >
bool Isis::ProcessByBrick::ProcessCubeInPlaceFunctor< T >::m_readInput
private

Should we read from the cube before processing.

Definition at line 424 of file ProcessByBrick.h.

Referenced by Isis::ProcessByBrick::ProcessCubeInPlaceFunctor< T >::operator()(), and Isis::ProcessByBrick::ProcessCubeInPlaceFunctor< T >::operator=().

◆ m_templateBrick

◆ m_writeOutput

template<typename T >
bool Isis::ProcessByBrick::ProcessCubeInPlaceFunctor< T >::m_writeOutput
private

Should we write to the output cube after processing.

Definition at line 426 of file ProcessByBrick.h.

Referenced by Isis::ProcessByBrick::ProcessCubeInPlaceFunctor< T >::operator()(), and Isis::ProcessByBrick::ProcessCubeInPlaceFunctor< T >::operator=().


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