Medical Imaging Interaction Toolkit
2016.11.0
Medical Imaging Interaction Toolkit
|
Base class of all mappers, Vtk as well as OpenGL mappers. More...
#include <mitkMapper.h>
Classes | |
class | BaseLocalStorage |
Base class for mapper specific rendering ressources. More... | |
Public Types | |
typedef Mapper | Self |
typedef itk::Object | Superclass |
typedef itk::SmartPointer< Self > | Pointer |
typedef itk::SmartPointer< const Self > | ConstPointer |
Public Member Functions | |
virtual std::vector< std::string > | GetClassHierarchy () const |
virtual const char * | GetClassName () const |
virtual void | SetDataNode (DataNode *_arg) |
Set the DataNode containing the data to map. More... | |
virtual DataNode * | GetDataNode () const |
Get the DataNode containing the data to map. Method only returns valid DataNode Pointer if the mapper belongs to a data node. Otherwise, the returned DataNode Pointer might be invalid. More... | |
BaseData * | GetData () const |
Get the data to map. More... | |
virtual bool | GetColor (float rgb[3], BaseRenderer *renderer, const char *name="color") const |
Convenience access method for color properties (instances of ColorProperty) More... | |
virtual bool | GetVisibility (bool &visible, BaseRenderer *renderer, const char *name="visible") const |
Convenience access method for visibility properties (instances of BoolProperty) More... | |
virtual bool | GetOpacity (float &opacity, BaseRenderer *renderer, const char *name="opacity") const |
Convenience access method for opacity properties (instances of FloatProperty) More... | |
virtual bool | GetLevelWindow (LevelWindow &levelWindow, BaseRenderer *renderer, const char *name="levelwindow") const |
Convenience access method for color properties (instances of LevelWindoProperty) More... | |
virtual bool | IsVisible (BaseRenderer *renderer, const char *name="visible") const |
Convenience access method for visibility properties (instances of BoolProperty). Return value is the visibility. Default is visible==true, i.e., true is returned even if the property (propertyKey) is not found. More... | |
virtual bool | IsVtkBased () const =0 |
Returns whether this is an vtk-based mapper. More... | |
virtual void | Update (BaseRenderer *renderer) |
Calls the time step of the input data for the specified renderer and checks whether the time step is valid and calls method GenerateDataForRenderer() More... | |
virtual void | MitkRender (mitk::BaseRenderer *renderer, mitk::VtkPropRenderer::RenderType type)=0 |
Responsible for calling the appropriate render functions. To be implemented in sub-classes. More... | |
virtual void | ApplyColorAndOpacityProperties (mitk::BaseRenderer *renderer, vtkActor *actor=nullptr)=0 |
Apply specific color and opacity properties read from the PropertyList. Reimplemented in GLmapper (does not use the actor) and the VtkMapper class. The function is called by the individual mapper (mostly in the ApplyProperties() or ApplyAllProperties() method). More... | |
int | GetTimestep () const |
Returns the current time step as calculated from the renderer. More... | |
virtual bool | IsLODEnabled (BaseRenderer *) const |
Static Public Member Functions | |
static const char * | GetStaticNameOfClass () |
static void | SetDefaultProperties (DataNode *node, BaseRenderer *renderer=nullptr, bool overwrite=false) |
Set default values of properties used by this mapper to node. More... | |
Protected Member Functions | |
Mapper () | |
explicit constructor which disallows implicit conversions More... | |
virtual | ~Mapper () |
virtual destructor in order to derive from this class More... | |
virtual void | GenerateData () |
Generate the data needed for rendering (independent of a specific renderer) More... | |
virtual void | GenerateDataForRenderer (BaseRenderer *) |
Generate the data needed for rendering into renderer. More... | |
virtual void | CalculateTimeStep (BaseRenderer *renderer) |
Updates the time step, which is sometimes needed in subclasses. More... | |
virtual void | ResetMapper (BaseRenderer *) |
Reset the mapper (i.e., make sure that nothing is displayed) if no valid data is present. In most cases the reimplemented function disables the according actors (toggling visibility off) More... | |
virtual OverlayManager * | GetOverlayManager () const |
Protected Attributes | |
mitk::DataNode * | m_DataNode |
Base class of all mappers, Vtk as well as OpenGL mappers.
By the help of mappers, the input data is transformed to tangible primitives, such as surfaces, points, lines, etc. This is the base class of all mappers, Vtk as well as OpenGL mappers. Subclasses of mitk::Mapper control the creation of rendering primitives that interface to the graphics library (e.g., OpenGL, vtk).
Definition at line 54 of file mitkMapper.h.
typedef itk::SmartPointer<const Self> mitk::Mapper::ConstPointer |
Definition at line 57 of file mitkMapper.h.
typedef itk::SmartPointer<Self> mitk::Mapper::Pointer |
Definition at line 57 of file mitkMapper.h.
typedef Mapper mitk::Mapper::Self |
Definition at line 57 of file mitkMapper.h.
typedef itk::Object mitk::Mapper::Superclass |
Definition at line 57 of file mitkMapper.h.
|
explicitprotected |
explicit constructor which disallows implicit conversions
Definition at line 23 of file mitkMapper.cpp.
|
protectedvirtual |
virtual destructor in order to derive from this class
Definition at line 27 of file mitkMapper.cpp.
|
pure virtual |
Apply specific color and opacity properties read from the PropertyList. Reimplemented in GLmapper (does not use the actor) and the VtkMapper class. The function is called by the individual mapper (mostly in the ApplyProperties() or ApplyAllProperties() method).
Implemented in mitk::VtkMapper, mitk::EnhancedPointSetVtkMapper3D, mitk::BoundingShapeVtkMapper2D, mitk::GLMapper, mitk::VtkGLMapperWrapper, mitk::SimulationVtkMapper2D, mitk::SimulationVtkMapper3D, mitk::PlanarFigureVtkMapper3D, and mitk::BoundingShapeVtkMapper3D.
|
protectedvirtual |
Updates the time step, which is sometimes needed in subclasses.
Definition at line 84 of file mitkMapper.cpp.
References mitk::BaseRenderer::GetTimeStep().
Referenced by mitk::SurfaceVtkMapper2D::Update().
|
inlineprotectedvirtual |
Generate the data needed for rendering (independent of a specific renderer)
Definition at line 167 of file mitkMapper.h.
|
inlineprotectedvirtual |
Generate the data needed for rendering into renderer.
Reimplemented in mitk::DoseImageVtkMapper2D, mitk::ImageVtkMapper2D, mitk::PointSetVtkMapper2D, mitk::RegEvaluationMapper2D, mitk::LabelSetImageVtkMapper2D, mitk::SurfaceVtkMapper2D, mitk::CompositeMapper, mitk::PlaneGeometryDataVtkMapper3D, mitk::PointSetVtkMapper3D, mitk::GPUVolumeMapper3D, mitk::SurfaceVtkMapper3D, mitk::PlaneGeometryDataMapper2D, mitk::FiberBundleMapper2D, mitk::EnhancedPointSetVtkMapper3D, mitk::ContourModelMapper3D, mitk::ConnectomicsNetworkMapper3D, mitk::ContourModelMapper2D, mitk::ContourModelSetMapper3D, mitk::OdfVtkMapper2D< TPixelType, NrOdfDirections >, mitk::OdfVtkMapper2D< float, QBALL_ODFSIZE >, mitk::VectorImageVtkGlyphMapper3D, mitk::MeshVtkMapper3D, mitk::SplineVtkMapper3D, mitk::UnstructuredGridMapper2D, mitk::UnstructuredGridVtkMapper3D, mitk::TubeGraphVtkMapper3D, mitk::FiberBundleThreadMonitorMapper3D, mitk::SimulationVtkMapper3D, mitk::ContourVtkMapper3D, mitk::SimulationVtkMapper2D, mitk::ContourSetVtkMapper3D, mitk::FiberBundleMapper3D, mitk::MITKRegistrationWrapperMapperBase, mitk::VtkGLMapperWrapper, mitk::BoundingShapeVtkMapper3D, and mitk::TbssImageMapper.
Definition at line 169 of file mitkMapper.h.
|
inlinevirtual |
Reimplemented in mitk::ImageVtkMapper2D, mitk::PointSetVtkMapper2D, mitk::PlaneGeometryDataVtkMapper3D, mitk::PointSetVtkMapper3D, mitk::SurfaceVtkMapper3D, mitk::SurfaceVtkMapper2D, mitk::VtkMapper, and mitk::PlaneGeometryDataMapper2D.
Definition at line 57 of file mitkMapper.h.
|
virtual |
|
virtual |
Convenience access method for color properties (instances of ColorProperty)
Definition at line 41 of file mitkMapper.cpp.
References mitk::DataNode::GetColor().
mitk::BaseData * mitk::Mapper::GetData | ( | ) | const |
Get the data to map.
Returns the mitk::BaseData object associated with this mapper.
Definition at line 31 of file mitkMapper.cpp.
|
virtual |
Get the DataNode containing the data to map. Method only returns valid DataNode Pointer if the mapper belongs to a data node. Otherwise, the returned DataNode Pointer might be invalid.
Reimplemented in mitk::VtkGLMapperWrapper.
Definition at line 36 of file mitkMapper.cpp.
Referenced by mitk::SurfaceVtkMapper2D::ApplyAllProperties(), mitk::UnstructuredGridMapper2D::GenerateDataForRenderer(), mitk::PlaneGeometryDataMapper2D::GenerateDataForRenderer(), mitk::PlaneGeometryDataVtkMapper3D::GenerateDataForRenderer(), mitk::SurfaceVtkMapper2D::GenerateDataForRenderer(), mitk::VectorImageMapper2D::GetInput(), mitk::UnstructuredGridVtkMapper3D::GetInput(), mitk::MeshVtkMapper3D::GetInput(), mitk::GPUVolumeMapper3D::GetInput(), mitk::SurfaceVtkMapper2D::GetInput(), mitk::EnhancedPointSetVtkMapper3D::GetInput(), mitk::SurfaceVtkMapper3D::GetInput(), mitk::PointSetVtkMapper3D::GetInput(), mitk::PlaneGeometryDataVtkMapper3D::GetInput(), mitk::PointSetVtkMapper2D::GetInput(), mitk::PlaneGeometryDataVtkMapper3D::GetVtkProp(), mitk::PlaneGeometryDataVtkMapper3D::ProcessNode(), mitk::SurfaceVtkMapper2D::Update(), and mitk::PlaneGeometryDataVtkMapper3D::UpdateVtkTransform().
|
virtual |
Convenience access method for color properties (instances of LevelWindoProperty)
Definition at line 68 of file mitkMapper.cpp.
References mitk::DataNode::GetLevelWindow().
|
virtual |
Convenience access method for opacity properties (instances of FloatProperty)
Definition at line 59 of file mitkMapper.cpp.
References mitk::DataNode::GetOpacity().
|
protectedvirtual |
Definition at line 160 of file mitkMapper.cpp.
|
inlinestatic |
Definition at line 57 of file mitkMapper.h.
|
inline |
Returns the current time step as calculated from the renderer.
Definition at line 152 of file mitkMapper.h.
Referenced by mitk::UnstructuredGridMapper2D::GenerateDataForRenderer(), mitk::PlaneGeometryDataVtkMapper3D::GenerateDataForRenderer(), mitk::SurfaceVtkMapper2D::GenerateDataForRenderer(), and mitk::PlaneGeometryDataVtkMapper3D::UpdateVtkTransform().
|
virtual |
Convenience access method for visibility properties (instances of BoolProperty)
Definition at line 50 of file mitkMapper.cpp.
References mitk::DataNode::GetVisibility().
|
inlinevirtual |
Returns true if this Mapper currently allows for Level-of-Detail rendering. This reflects whether this Mapper currently invokes StartEvent, EndEvent, and ProgressEvent on BaseRenderer.
Reimplemented in mitk::CompositeMapper, mitk::OdfVtkMapper2D< TPixelType, NrOdfDirections >, mitk::OdfVtkMapper2D< float, QBALL_ODFSIZE >, and mitk::GPUVolumeMapper3D.
Definition at line 156 of file mitkMapper.h.
|
virtual |
Convenience access method for visibility properties (instances of BoolProperty). Return value is the visibility. Default is visible==true, i.e., true is returned even if the property (propertyKey) is not found.
Thus, the return value has a different meaning than in the GetVisibility method!
Definition at line 77 of file mitkMapper.cpp.
|
pure virtual |
Returns whether this is an vtk-based mapper.
Implemented in mitk::GLMapper, and mitk::VtkMapper.
|
pure virtual |
Responsible for calling the appropriate render functions. To be implemented in sub-classes.
Implemented in mitk::VtkMapper, mitk::GLMapper, and mitk::VtkGLMapperWrapper.
Referenced by mitk::VtkPropRenderer::Render().
|
inlineprotectedvirtual |
Reset the mapper (i.e., make sure that nothing is displayed) if no valid data is present. In most cases the reimplemented function disables the according actors (toggling visibility off)
To be implemented in sub-classes.
Reimplemented in mitk::PointSetVtkMapper2D, mitk::SurfaceVtkMapper2D, mitk::PointSetVtkMapper3D, mitk::SurfaceVtkMapper3D, mitk::MeshVtkMapper3D, mitk::UnstructuredGridVtkMapper3D, and mitk::GizmoMapper2D.
Definition at line 179 of file mitkMapper.h.
|
virtual |
Set the DataNode containing the data to map.
Reimplemented in mitk::CompositeMapper, and mitk::VtkGLMapperWrapper.
Referenced by mitk::CoreObjectFactory::CreateMapper(), and mitk::DataNode::SetMapper().
|
static |
Set default values of properties used by this mapper to node.
node | The node for which the properties are set |
overwrite | overwrite existing properties (default: false) |
renderer | defines which property list of node is used (default: NULL, i.e. default property list) |
Definition at line 153 of file mitkMapper.cpp.
References mitk::DataNode::AddProperty(), mitk::BoolProperty::New(), mitk::IntProperty::New(), and mitk::StringProperty::New().
Referenced by mitk::TubeGraphObjectFactory::SetDefaultProperties(), and mitk::SurfaceVtkMapper2D::SetDefaultProperties().
|
virtual |
Calls the time step of the input data for the specified renderer and checks whether the time step is valid and calls method GenerateDataForRenderer()
Reimplemented in mitk::SurfaceVtkMapper2D, mitk::DoseImageVtkMapper2D, mitk::ImageVtkMapper2D, mitk::CompositeMapper, mitk::OdfVtkMapper2D< TPixelType, NrOdfDirections >, mitk::OdfVtkMapper2D< float, QBALL_ODFSIZE >, mitk::RegEvaluationMapper2D, mitk::LabelSetImageVtkMapper2D, mitk::VtkGLMapperWrapper, mitk::FiberBundleMapper2D, mitk::ContourModelSetMapper3D, mitk::ContourModelMapper3D, and mitk::ContourModelMapper2D.
Definition at line 96 of file mitkMapper.cpp.
References mitk::DataNode::GetData(), mitk::BaseData::GetTimeGeometry(), and mitk::TimeGeometry::IsValidTimeStep().
|
protected |
Definition at line 182 of file mitkMapper.h.
Referenced by mitk::CompositeMapper::SetDataNode().