|
opensurgsim
|
Delegate to read Octrees from ply files, this is the abstract base class, to let us modify loading by datatype. More...
#include <OctreeNodePlyReaderDelegate.h>
Classes | |
| struct | BoundsData |
| Data Structure to receive the bounds information. More... | |
| struct | DimensionData |
| Data structure to receive the dimension information from the file. More... | |
| struct | SpacingData |
| Data structure to receive the spacing information from the file. More... | |
| struct | VoxelData |
| Data structure to receive the specific voxel information from the file. More... | |
Public Member Functions | |
| OctreeNodePlyReaderDelegateBase () | |
| Constructor. | |
| virtual | ~OctreeNodePlyReaderDelegateBase () |
| Destructor. | |
| bool | registerDelegate (PlyReader *reader) override |
| Registers the delegate with the reader. More... | |
| bool | fileIsAcceptable (const PlyReader &reader) override |
| Check whether the file in the reader can be used with this delegate, this gives the delegate a chance to make sure that all the elements and properties that are required are available in the file encapsulated by the reader. | |
| void * | beginBounds (const std::string &elementName, size_t count) |
| Callback function, begin the processing of the bounds. More... | |
| void * | beginDimension (const std::string &elementName, size_t count) |
| Callback function, begin the processing of the dimension. More... | |
| void * | beginSpacing (const std::string &elementName, size_t count) |
| Callback function, begin the processing of the bounds. More... | |
| virtual void * | beginVoxel (const std::string &elementName, size_t count) |
| Callback function, begin the processing of the voxels. More... | |
| virtual void | processVoxel (const std::string &elementName)=0 |
| Callback function to process one voxel. More... | |
Public Member Functions inherited from SurgSim::DataStructures::PlyReaderDelegate | |
| virtual | ~PlyReaderDelegate () |
| Virtual destructor. | |
Protected Member Functions | |
| virtual void | initializeOctree ()=0 |
| Set up the octree, this is left up to the derived classes. | |
Protected Attributes | |
| struct SurgSim::DataStructures::OctreeNodePlyReaderDelegateBase::BoundsData | m_bounds |
| Eigen::AlignedBox< double, 3 > | m_boundingBox |
| Bounding box, will be initialized from the file. | |
| struct SurgSim::DataStructures::OctreeNodePlyReaderDelegateBase::SpacingData | m_spacing |
| struct SurgSim::DataStructures::OctreeNodePlyReaderDelegateBase::DimensionData | m_dimension |
| struct SurgSim::DataStructures::OctreeNodePlyReaderDelegateBase::VoxelData | m_voxel |
| int | m_numLevels = -1 |
| Calculated number of levels for the octree. | |
| bool | m_haveSpacing |
| bool | m_haveDimensions |
| bool | m_haveBounds |
Delegate to read Octrees from ply files, this is the abstract base class, to let us modify loading by datatype.
| void * SurgSim::DataStructures::OctreeNodePlyReaderDelegateBase::beginBounds | ( | const std::string & | elementName, |
| size_t | count | ||
| ) |
Callback function, begin the processing of the bounds.
| elementName | Name of the element. |
| count | Number of entries. |
| SurgSim::Framework::AssertionFailure | if count != 1, only one bounds entry is expected |
| void * SurgSim::DataStructures::OctreeNodePlyReaderDelegateBase::beginDimension | ( | const std::string & | elementName, |
| size_t | count | ||
| ) |
Callback function, begin the processing of the dimension.
| elementName | Name of the element. |
| count | Number of entries. |
| SurgSim::Framework::AssertionFailure | if count != 1, only one dimesion entry is expected |
| void * SurgSim::DataStructures::OctreeNodePlyReaderDelegateBase::beginSpacing | ( | const std::string & | elementName, |
| size_t | count | ||
| ) |
Callback function, begin the processing of the bounds.
| elementName | Name of the element. |
| count | Number of entries. |
| SurgSim::Framework::AssertionFailure | if count != 1, only one spacing entry is expected |
|
virtual |
Callback function, begin the processing of the voxels.
| elementName | Name of the element. |
| count | Number of bounds entry. |
|
pure virtual |
Callback function to process one voxel.
This is left up to the subclasses, they might have to deal with data specific processing
| elementName | Name of the element. |
Implemented in SurgSim::DataStructures::OctreeNodePlyReaderDelegate< Data >.
|
overridevirtual |
Registers the delegate with the reader.
| [out] | reader | The reader that should be used by the delegate. |
Implements SurgSim::DataStructures::PlyReaderDelegate.
|
protected |
Check wether we actually received the appropriate information, if not we can't initialize the octree
1.8.12