open_iA 2023.02
A tool for the visual analysis and processing of volumetric datasets, with a focus on industrial computed tomography.
Loading...
Searching...
No Matches
Public Member Functions | Static Public Attributes | Protected Member Functions | Protected Attributes | List of all members
iA3DColoredPolyObjectVis Class Referenceabstract

#include <iA3DColoredPolyObjectVis.h>

Inheritance diagram for iA3DColoredPolyObjectVis:
[legend]
Collaboration diagram for iA3DColoredPolyObjectVis:
[legend]

Public Member Functions

 iA3DColoredPolyObjectVis (vtkTable *objectTable, QSharedPointer< QMap< uint, uint > > columnMapping, QColor const &neutralColor)
 
IndexType allPointCount () const
 Get the number of points in all objects.
 
double const * bounds () override
 
QSharedPointer< iA3DObjectActorcreateActor (vtkRenderer *ren) override
 create "actor" class for visualizing this data collection
 
QSharedPointer< iA3DPolyObjectActorcreatePolyActor (vtkRenderer *ren)
 same as createActor, but retrieve derived class more specific for visualizing a 3D colored poly data object; use this if you need to access methods from the iA3DPolyObjectActor class which are not available through the iA3DObjectActor interface.
 
virtual std::vector< vtkSmartPointer< vtkPolyData > > extractSelectedObjects (QColor c=QColor()) const =0
 extract one mesh per selected object
 
IndexType finalAllPointCount () const
 Get the number of points in all final objects.
 
virtual IndexType finalObjectPointCount (IndexType objIdx) const
 Get the number of points representing a given final object.
 
virtual IndexType finalObjectStartPointIdx (IndexType objIdx) const
 Get the index of the first point of a given final object.
 
virtual vtkPolyData * finalPolyData ()=0
 
virtual IndexType objectPointCount (IndexType objIdx) const
 Get the number of points representing a given object.
 
virtual IndexType objectStartPointIdx (IndexType objIdx) const
 Get the index of the first point of a given object.
 
virtual vtkPolyData * polyData ()=0
 
std::vector< size_t > const & selection () const
 
void setColor (QColor const &color)
 
void setContextOpacity (int contextAlpha)
 
void setLookupTable (QSharedPointer< iALookupTable > lut, size_t paramIndex)
 
virtual void setSelection (std::vector< size_t > const &sortedSelInds, bool selectionActive)
 
void setSelectionOpacity (int selectionAlpha)
 
void updateColorSelectionRendering ()
 
virtual QString visualizationStatistics () const =0
 
void renderSelection (std::vector< size_t > const &sortedSelInds, int classID, QColor const &classColor, QStandardItem *activeClassItem) override
 "legacy" methods for various selection/coloring options, specific to FeatureScout module
 
void renderSingle (IndexType selectedObjID, int classID, QColor const &classColors, QStandardItem *activeClassItem) override
 
void multiClassRendering (QList< QColor > const &colors, QStandardItem *rootItem, double alpha) override
 
void renderOrientationDistribution (vtkImageData *oi) override
 
void renderLengthDistribution (vtkColorTransferFunction *ctFun, vtkFloatArray *extents, double halfInc, int filterID, double const *range) override
 
- Public Member Functions inherited from iA3DObjectVis
 iA3DObjectVis (vtkTable *objectTable, QSharedPointer< QMap< uint, uint > > columnMapping)
 
virtual ~iA3DObjectVis ()
 
virtual double const * bounds ()=0
 
virtual QSharedPointer< iA3DObjectActorcreateActor (vtkRenderer *ren)=0
 
virtual void multiClassRendering (QList< QColor > const &classColors, QStandardItem *rootItem, double alpha)=0
 
virtual void renderLengthDistribution (vtkColorTransferFunction *cTFun, vtkFloatArray *extents, double halfInc, int filterID, double const *range)=0
 
virtual void renderOrientationDistribution (vtkImageData *oi)=0
 
virtual void renderSelection (std::vector< size_t > const &sortedSelInds, int classID, QColor const &classColor, QStandardItem *activeClassItem)=0
 
virtual void renderSingle (IndexType selectedObjID, int classID, QColor const &classColor, QStandardItem *activeClassItem)=0
 

Static Public Attributes

static const int DefaultContextOpacity = 8
 
static const int DefaultSelectionOpacity = 128
 
- Static Public Attributes inherited from iA3DObjectVis
static const QColor SelectedColor
 

Protected Member Functions

void setObjectColor (IndexType objIdx, QColor const &qcolor)
 Set an object to a specified color.
 
void setupColors ()
 Set up the array of colors for each object.
 
void setupOriginalIds ()
 Set up the mapping from object parts to object IDs.
 
- Protected Member Functions inherited from iA3DObjectVis
QColor getLengthColor (vtkColorTransferFunction *ctFun, IndexType objID) const
 
QColor getOrientationColor (vtkImageData *oi, IndexType objID) const
 

Protected Attributes

QColor m_baseColor
 
vtkSmartPointer< vtkUnsignedCharArray > m_colors
 
int m_contextAlpha
 
std::vector< size_t > m_selection
 
int m_selectionAlpha
 
QColor m_selectionColor
 
- Protected Attributes inherited from iA3DObjectVis
QSharedPointer< QMap< uint, uint > > m_columnMapping
 
vtkTable * m_objectTable
 

Additional Inherited Members

- Public Types inherited from iA3DObjectVis
typedef vtkIdType IndexType
 the type used for indices into the data table.
 
- Signals inherited from iA3DObjectVis
void dataChanged ()
 
void renderRequired ()
 

Constructor & Destructor Documentation

◆ iA3DColoredPolyObjectVis()

iA3DColoredPolyObjectVis::iA3DColoredPolyObjectVis ( vtkTable *  objectTable,
QSharedPointer< QMap< uint, uint > >  columnMapping,
QColor const &  neutralColor 
)

Member Function Documentation

◆ allPointCount()

iA3DColoredPolyObjectVis::IndexType iA3DColoredPolyObjectVis::allPointCount ( ) const

Get the number of points in all objects.

Returns
the number of points in all objects, i.e. the sum of objectPointCount over all object indices.

◆ bounds()

double const * iA3DColoredPolyObjectVis::bounds ( )
overridevirtual

Implements iA3DObjectVis.

Reimplemented in iA3DEllipseObjectVis.

◆ createActor()

QSharedPointer< iA3DObjectActor > iA3DColoredPolyObjectVis::createActor ( vtkRenderer *  ren)
overridevirtual

create "actor" class for visualizing this data collection

Implements iA3DObjectVis.

◆ createPolyActor()

QSharedPointer< iA3DPolyObjectActor > iA3DColoredPolyObjectVis::createPolyActor ( vtkRenderer *  ren)

same as createActor, but retrieve derived class more specific for visualizing a 3D colored poly data object; use this if you need to access methods from the iA3DPolyObjectActor class which are not available through the iA3DObjectActor interface.

◆ extractSelectedObjects()

virtual std::vector< vtkSmartPointer< vtkPolyData > > iA3DColoredPolyObjectVis::extractSelectedObjects ( QColor  c = QColor()) const
pure virtual

extract one mesh per selected object

Implemented in iA3DCylinderObjectVis, iA3DEllipseObjectVis, and iA3DLineObjectVis.

◆ finalAllPointCount()

iA3DColoredPolyObjectVis::IndexType iA3DColoredPolyObjectVis::finalAllPointCount ( ) const

Get the number of points in all final objects.

Returns
the number of points in all objects, i.e. the sum of objectPointCount over all object indices.

◆ finalObjectPointCount()

iA3DColoredPolyObjectVis::IndexType iA3DColoredPolyObjectVis::finalObjectPointCount ( IndexType  objIdx) const
virtual

Get the number of points representing a given final object.

Parameters
objIdxthe index of the object.
Returns
the number of points in the final object.

Reimplemented in iA3DCylinderObjectVis.

◆ finalObjectStartPointIdx()

iA3DColoredPolyObjectVis::IndexType iA3DColoredPolyObjectVis::finalObjectStartPointIdx ( IndexType  objIdx) const
virtual

Get the index of the first point of a given final object.

Parameters
objIdxthe index of the object.
Returns
the index of the first point in the final object.

Reimplemented in iA3DCylinderObjectVis.

◆ finalPolyData()

virtual vtkPolyData * iA3DColoredPolyObjectVis::finalPolyData ( )
pure virtual

◆ multiClassRendering()

void iA3DColoredPolyObjectVis::multiClassRendering ( QList< QColor > const &  colors,
QStandardItem *  rootItem,
double  alpha 
)
overridevirtual

Implements iA3DObjectVis.

◆ objectPointCount()

iA3DColoredPolyObjectVis::IndexType iA3DColoredPolyObjectVis::objectPointCount ( IndexType  objIdx) const
virtual

Get the number of points representing a given object.

Parameters
objIdxthe index of the object.
Returns
the number of points in the object.

Reimplemented in iA3DEllipseObjectVis, and iA3DLineObjectVis.

◆ objectStartPointIdx()

iA3DColoredPolyObjectVis::IndexType iA3DColoredPolyObjectVis::objectStartPointIdx ( IndexType  objIdx) const
virtual

Get the index of the first point of a given object.

Parameters
objIdxthe index of the object.
Returns
the index of the first point in the object.

Reimplemented in iA3DEllipseObjectVis, and iA3DLineObjectVis.

◆ polyData()

virtual vtkPolyData * iA3DColoredPolyObjectVis::polyData ( )
pure virtual

◆ renderLengthDistribution()

void iA3DColoredPolyObjectVis::renderLengthDistribution ( vtkColorTransferFunction *  ctFun,
vtkFloatArray *  extents,
double  halfInc,
int  filterID,
double const *  range 
)
overridevirtual

Implements iA3DObjectVis.

◆ renderOrientationDistribution()

void iA3DColoredPolyObjectVis::renderOrientationDistribution ( vtkImageData *  oi)
overridevirtual

Implements iA3DObjectVis.

◆ renderSelection()

void iA3DColoredPolyObjectVis::renderSelection ( std::vector< size_t > const &  sortedSelInds,
int  classID,
QColor const &  classColor,
QStandardItem *  activeClassItem 
)
overridevirtual

"legacy" methods for various selection/coloring options, specific to FeatureScout module

Implements iA3DObjectVis.

◆ renderSingle()

void iA3DColoredPolyObjectVis::renderSingle ( IndexType  selectedObjID,
int  classID,
QColor const &  classColors,
QStandardItem *  activeClassItem 
)
overridevirtual

Implements iA3DObjectVis.

◆ selection()

std::vector< size_t > const & iA3DColoredPolyObjectVis::selection ( ) const

◆ setColor()

void iA3DColoredPolyObjectVis::setColor ( QColor const &  color)

◆ setContextOpacity()

void iA3DColoredPolyObjectVis::setContextOpacity ( int  contextAlpha)

◆ setLookupTable()

void iA3DColoredPolyObjectVis::setLookupTable ( QSharedPointer< iALookupTable lut,
size_t  paramIndex 
)

◆ setObjectColor()

void iA3DColoredPolyObjectVis::setObjectColor ( IndexType  objIdx,
QColor const &  qcolor 
)
protected

Set an object to a specified color.

Parameters
objIdxindex of the object.
qcolornew color of the object.

◆ setSelection()

void iA3DColoredPolyObjectVis::setSelection ( std::vector< size_t > const &  sortedSelInds,
bool  selectionActive 
)
virtual

Reimplemented in iA3DCylinderObjectVis.

◆ setSelectionOpacity()

void iA3DColoredPolyObjectVis::setSelectionOpacity ( int  selectionAlpha)

◆ setupColors()

void iA3DColoredPolyObjectVis::setupColors ( )
protected

Set up the array of colors for each object.

◆ setupOriginalIds()

void iA3DColoredPolyObjectVis::setupOriginalIds ( )
protected

Set up the mapping from object parts to object IDs.

◆ updateColorSelectionRendering()

void iA3DColoredPolyObjectVis::updateColorSelectionRendering ( )

◆ visualizationStatistics()

virtual QString iA3DColoredPolyObjectVis::visualizationStatistics ( ) const
pure virtual

Member Data Documentation

◆ DefaultContextOpacity

const int iA3DColoredPolyObjectVis::DefaultContextOpacity = 8
static

◆ DefaultSelectionOpacity

const int iA3DColoredPolyObjectVis::DefaultSelectionOpacity = 128
static

◆ m_baseColor

QColor iA3DColoredPolyObjectVis::m_baseColor
protected

◆ m_colors

vtkSmartPointer<vtkUnsignedCharArray> iA3DColoredPolyObjectVis::m_colors
protected

◆ m_contextAlpha

int iA3DColoredPolyObjectVis::m_contextAlpha
protected

◆ m_selection

std::vector<size_t> iA3DColoredPolyObjectVis::m_selection
protected

◆ m_selectionAlpha

int iA3DColoredPolyObjectVis::m_selectionAlpha
protected

◆ m_selectionColor

QColor iA3DColoredPolyObjectVis::m_selectionColor
protected

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