ITK
5.0.0
Insight Segmentation and Registration Toolkit
|
#include <itkCuberilleImageToMeshFilter.h>
This filter uses the 'cuberille' method to convert an implicit surface (image) to a mesh.
The 'cuberille' model was proposed over 30 years ago [1,2]. A basic summary of the algorithm is as follows: step over all pixels, for each pixel determine if it lies on the surface, center a cube on the surface pixel, create quadrilateral faces aligned with the cube (taking care of neighbouring pixels also on the surface), use a gradient descent based method to project cube vertices to iso-surface [3].
(Required) IsoSurfaceValue: specifies the value of the iso-surface for which to generate the mesh. Pixels equal to or greater than this value are considered to lie on the surface or inside the resultant mesh.
(Optional) GenerateTriangleFaces: specifies whether triangle or quadrilateral faces should be generated. The default is to generate triangle faces.
(Optional) ProjectVerticesToIsoSurface: specifies whether the vertices should be projected onto the iso-surface. If projection is disabled, the resultant mesh exhibits the traditional blocky features. Projection takes roughly half of the algorithm time. The default is to project the vertices.
(Optional) ProjectVertexSurfaceDistanceThreshold: specifies the threshold for the 'distance' from iso-surface during vertex projection. Note that the distance is actually measured in pixel value units (not space). The smaller this value, the closer the vertices will be to the iso-surface. Small values result in longer convergence time (i.e. slower). Values are clamped to the range [0.0, max pixel value]. The default value is 0.5.
(Optional) ProjectVertexStepLength: specifies the threshold for the step length during vertex projection. The smaller this value, the more likely the vertices will end up closer to the surface. Small values cause the projection to take longer to converge. Values are clamped to the range [0.0, large]. The default value is max spacing * 0.25 (expressed in physical space).
(Optional) ProjectVertexStepLengthRelaxationFactor: specifies the step length relaxation factor during vertex projection. The step length is multiplied by this factor each iteration to allow convergence. Values are clamped to the range [0.0, 1.0].The default value is 0.95.
(Optional) ProjectVertexMaximumNumberOfSteps: specifies the maximum number of steps used during vertex projection. The default value is 50.
This implementation was taken from the Insight Journal: http://hdl.handle.net/10380/3186
Definition at line 114 of file itkCuberilleImageToMeshFilter.h.
Classes | |
class | VertexLookupMap |
class | VertexLookupNode |
Public Types | |
using | CellIdentifier = typename OutputMeshType::CellIdentifier |
using | CellInterfaceType = CellInterface< OutputPixelType, CellTraits > |
using | CellsContainer = typename OutputMeshType::CellsContainer |
using | CellsContainerPointer = typename OutputMeshType::CellsContainerPointer |
using | CellTraits = typename OutputMeshType::CellTraits |
using | ConstPointer = SmartPointer< const Self > |
using | GradientFilterPointer = typename GradientFilterType::Pointer |
using | GradientFilterType = GradientImageFilter< InputImageType > |
using | GradientImagePointer = typename GradientImageType::Pointer |
using | GradientImageType = typename GradientFilterType::OutputImageType |
using | GradientInterpolatorPointer = typename GradientInterpolatorType::Pointer |
using | GradientInterpolatorType = itk::VectorLinearInterpolateImageFunction< GradientImageType > |
using | GradientPixelType = typename GradientFilterType::OutputPixelType |
using | IndexType = typename InputImageType::IndexType |
using | InputImageConstPointer = typename InputImageType::ConstPointer |
using | InputImageIteratorType = ConstShapedNeighborhoodIterator< InputImageType > |
using | InputImagePointer = typename InputImageType::Pointer |
using | InputImageType = TInputImage |
using | InputPixelType = typename InputImageType::PixelType |
using | InterpolatorOutputType = typename InterpolatorType::OutputType |
using | InterpolatorPointer = typename InterpolatorType::Pointer |
using | InterpolatorType = TInterpolator |
using | OutputMeshPointer = typename OutputMeshType::Pointer |
using | OutputMeshTraits = typename OutputMeshType::MeshTraits |
using | OutputMeshType = TOutputMesh |
using | OutputPixelType = typename OutputMeshTraits::PixelType |
using | OutputPointType = typename OutputMeshType::PointType |
using | Pointer = SmartPointer< Self > |
using | PointIdentifier = typename OutputMeshType::PointIdentifier |
using | PointsContainer = typename OutputMeshType::PointsContainer |
using | PointsContainerPointer = typename OutputMeshType::PointsContainerPointer |
using | PointType = typename OutputMeshType::PointType |
using | QuadrilateralAutoPointer = typename QuadrilateralCellType::SelfAutoPointer |
using | QuadrilateralCellAutoPointer = typename QuadrilateralCellType::CellAutoPointer |
using | QuadrilateralCellType = QuadrilateralCell< CellInterfaceType > |
using | Self = CuberilleImageToMeshFilter |
using | SizeType = typename InputImageType::SizeType |
using | SpacingType = typename InputImageType::SpacingType |
using | SpacingValueType = typename InputImageType::SpacingValueType |
using | Superclass = ImageToMeshFilter< TInputImage, TOutputMesh > |
using | TriangleAutoPointer = typename TriangleCellType::SelfAutoPointer |
using | TriangleCellAutoPointer = typename TriangleCellType::CellAutoPointer |
using | TriangleCellType = TriangleCell< CellInterfaceType > |
Public Types inherited from itk::ImageToMeshFilter< TInputImage, TOutputMesh > | |
using | ConstPointer = SmartPointer< const Self > |
using | DataObjectPointerArraySizeType = ProcessObject::DataObjectPointerArraySizeType |
using | InputImageConstPointer = typename InputImageType::ConstPointer |
using | InputImagePixelType = typename InputImageType::PixelType |
using | InputImagePointer = typename InputImageType::Pointer |
using | InputImageRegionType = typename InputImageType::RegionType |
using | InputImageType = TInputImage |
using | OutputMeshPointer = typename OutputMeshType::Pointer |
using | OutputMeshType = TOutputMesh |
using | Pointer = SmartPointer< Self > |
using | Self = ImageToMeshFilter |
using | Superclass = MeshSource< TOutputMesh > |
Public Types inherited from itk::MeshSource< TOutputMesh > | |
using | ConstPointer = SmartPointer< const Self > |
using | DataObjectIdentifierType = Superclass::DataObjectIdentifierType |
using | DataObjectPointer = DataObject::Pointer |
using | OutputMeshPointer = typename OutputMeshType::Pointer |
using | OutputMeshType = TOutputMesh |
using | Pointer = SmartPointer< Self > |
using | Self = MeshSource |
using | Superclass = ProcessObject |
using | DataObjectPointerArraySizeType = ProcessObject::DataObjectPointerArraySizeType |
Public Types inherited from itk::ProcessObject | |
using | ConstPointer = SmartPointer< const Self > |
using | DataObjectIdentifierType = DataObject::DataObjectIdentifierType |
using | DataObjectPointer = DataObject::Pointer |
using | DataObjectPointerArray = std::vector< DataObjectPointer > |
using | DataObjectPointerArraySizeType = DataObjectPointerArray::size_type |
using | MultiThreaderType = MultiThreaderBase |
using | NameArray = std::vector< DataObjectIdentifierType > |
using | Pointer = SmartPointer< Self > |
using | Self = ProcessObject |
using | Superclass = Object |
Public Types inherited from itk::Object | |
using | ConstPointer = SmartPointer< const Self > |
using | Pointer = SmartPointer< Self > |
using | Self = Object |
using | Superclass = LightObject |
Public Types inherited from itk::LightObject | |
using | ConstPointer = SmartPointer< const Self > |
using | Pointer = SmartPointer< Self > |
using | Self = LightObject |
Static Public Member Functions | |
static Pointer | New () |
Static Public Member Functions inherited from itk::MeshSource< TOutputMesh > | |
static Pointer | New () |
Static Public Member Functions inherited from itk::Object | |
static bool | GetGlobalWarningDisplay () |
static void | GlobalWarningDisplayOff () |
static void | GlobalWarningDisplayOn () |
static Pointer | New () |
static void | SetGlobalWarningDisplay (bool flag) |
Static Public Member Functions inherited from itk::LightObject | |
static void | BreakOnError () |
static Pointer | New () |
Private Types | |
using | VertexLookupMapType = VertexLookupMap< OutputMeshType > |
Private Member Functions | |
void | AddQuadFace (CellIdentifier &id, PointIdentifier f[4], OutputMeshType *mesh) |
void | AddVertex (PointIdentifier &id, IndexType index, const InputImageType *image, OutputMeshType *mesh) |
void | ComputeGradientImage () |
IndexType | GetVertexLookupIndex (unsigned int vertex, IndexType index) |
void | ProjectVertexToIsoSurface (PointType &vertex) |
void | SetVerticesFromFace (unsigned int face, bool *vertexHasQuad) |
Additional Inherited Members | |
Protected Attributes inherited from itk::ProcessObject | |
TimeStamp | m_OutputInformationMTime |
bool | m_Updating |
Protected Attributes inherited from itk::LightObject | |
std::atomic< int > | m_ReferenceCount |
using itk::CuberilleImageToMeshFilter< TInputImage, TOutputMesh, TInterpolator >::CellIdentifier = typename OutputMeshType::CellIdentifier |
Definition at line 143 of file itkCuberilleImageToMeshFilter.h.
using itk::CuberilleImageToMeshFilter< TInputImage, TOutputMesh, TInterpolator >::CellInterfaceType = CellInterface<OutputPixelType, CellTraits> |
Definition at line 144 of file itkCuberilleImageToMeshFilter.h.
using itk::CuberilleImageToMeshFilter< TInputImage, TOutputMesh, TInterpolator >::CellsContainer = typename OutputMeshType::CellsContainer |
Definition at line 141 of file itkCuberilleImageToMeshFilter.h.
using itk::CuberilleImageToMeshFilter< TInputImage, TOutputMesh, TInterpolator >::CellsContainerPointer = typename OutputMeshType::CellsContainerPointer |
Definition at line 140 of file itkCuberilleImageToMeshFilter.h.
using itk::CuberilleImageToMeshFilter< TInputImage, TOutputMesh, TInterpolator >::CellTraits = typename OutputMeshType::CellTraits |
Definition at line 137 of file itkCuberilleImageToMeshFilter.h.
using itk::CuberilleImageToMeshFilter< TInputImage, TOutputMesh, TInterpolator >::ConstPointer = SmartPointer<const Self> |
Definition at line 123 of file itkCuberilleImageToMeshFilter.h.
using itk::CuberilleImageToMeshFilter< TInputImage, TOutputMesh, TInterpolator >::GradientFilterPointer = typename GradientFilterType::Pointer |
Definition at line 173 of file itkCuberilleImageToMeshFilter.h.
using itk::CuberilleImageToMeshFilter< TInputImage, TOutputMesh, TInterpolator >::GradientFilterType = GradientImageFilter< InputImageType > |
Definition at line 171 of file itkCuberilleImageToMeshFilter.h.
using itk::CuberilleImageToMeshFilter< TInputImage, TOutputMesh, TInterpolator >::GradientImagePointer = typename GradientImageType::Pointer |
Definition at line 175 of file itkCuberilleImageToMeshFilter.h.
using itk::CuberilleImageToMeshFilter< TInputImage, TOutputMesh, TInterpolator >::GradientImageType = typename GradientFilterType::OutputImageType |
Definition at line 174 of file itkCuberilleImageToMeshFilter.h.
using itk::CuberilleImageToMeshFilter< TInputImage, TOutputMesh, TInterpolator >::GradientInterpolatorPointer = typename GradientInterpolatorType::Pointer |
Definition at line 178 of file itkCuberilleImageToMeshFilter.h.
using itk::CuberilleImageToMeshFilter< TInputImage, TOutputMesh, TInterpolator >::GradientInterpolatorType = itk::VectorLinearInterpolateImageFunction< GradientImageType > |
Definition at line 177 of file itkCuberilleImageToMeshFilter.h.
using itk::CuberilleImageToMeshFilter< TInputImage, TOutputMesh, TInterpolator >::GradientPixelType = typename GradientFilterType::OutputPixelType |
Definition at line 176 of file itkCuberilleImageToMeshFilter.h.
using itk::CuberilleImageToMeshFilter< TInputImage, TOutputMesh, TInterpolator >::IndexType = typename InputImageType::IndexType |
Definition at line 159 of file itkCuberilleImageToMeshFilter.h.
using itk::CuberilleImageToMeshFilter< TInputImage, TOutputMesh, TInterpolator >::InputImageConstPointer = typename InputImageType::ConstPointer |
Definition at line 154 of file itkCuberilleImageToMeshFilter.h.
using itk::CuberilleImageToMeshFilter< TInputImage, TOutputMesh, TInterpolator >::InputImageIteratorType = ConstShapedNeighborhoodIterator< InputImageType > |
Other convenient type alias.
Definition at line 167 of file itkCuberilleImageToMeshFilter.h.
using itk::CuberilleImageToMeshFilter< TInputImage, TOutputMesh, TInterpolator >::InputImagePointer = typename InputImageType::Pointer |
Definition at line 153 of file itkCuberilleImageToMeshFilter.h.
using itk::CuberilleImageToMeshFilter< TInputImage, TOutputMesh, TInterpolator >::InputImageType = TInputImage |
Definition at line 152 of file itkCuberilleImageToMeshFilter.h.
using itk::CuberilleImageToMeshFilter< TInputImage, TOutputMesh, TInterpolator >::InputPixelType = typename InputImageType::PixelType |
Definition at line 155 of file itkCuberilleImageToMeshFilter.h.
using itk::CuberilleImageToMeshFilter< TInputImage, TOutputMesh, TInterpolator >::InterpolatorOutputType = typename InterpolatorType::OutputType |
Definition at line 164 of file itkCuberilleImageToMeshFilter.h.
using itk::CuberilleImageToMeshFilter< TInputImage, TOutputMesh, TInterpolator >::InterpolatorPointer = typename InterpolatorType::Pointer |
Definition at line 163 of file itkCuberilleImageToMeshFilter.h.
using itk::CuberilleImageToMeshFilter< TInputImage, TOutputMesh, TInterpolator >::InterpolatorType = TInterpolator |
Definition at line 162 of file itkCuberilleImageToMeshFilter.h.
using itk::CuberilleImageToMeshFilter< TInputImage, TOutputMesh, TInterpolator >::OutputMeshPointer = typename OutputMeshType::Pointer |
Definition at line 133 of file itkCuberilleImageToMeshFilter.h.
using itk::CuberilleImageToMeshFilter< TInputImage, TOutputMesh, TInterpolator >::OutputMeshTraits = typename OutputMeshType::MeshTraits |
Definition at line 134 of file itkCuberilleImageToMeshFilter.h.
using itk::CuberilleImageToMeshFilter< TInputImage, TOutputMesh, TInterpolator >::OutputMeshType = TOutputMesh |
Some convenient type alias.
Definition at line 132 of file itkCuberilleImageToMeshFilter.h.
using itk::CuberilleImageToMeshFilter< TInputImage, TOutputMesh, TInterpolator >::OutputPixelType = typename OutputMeshTraits::PixelType |
Definition at line 136 of file itkCuberilleImageToMeshFilter.h.
using itk::CuberilleImageToMeshFilter< TInputImage, TOutputMesh, TInterpolator >::OutputPointType = typename OutputMeshType::PointType |
Definition at line 135 of file itkCuberilleImageToMeshFilter.h.
using itk::CuberilleImageToMeshFilter< TInputImage, TOutputMesh, TInterpolator >::Pointer = SmartPointer<Self> |
Definition at line 122 of file itkCuberilleImageToMeshFilter.h.
using itk::CuberilleImageToMeshFilter< TInputImage, TOutputMesh, TInterpolator >::PointIdentifier = typename OutputMeshType::PointIdentifier |
Definition at line 142 of file itkCuberilleImageToMeshFilter.h.
using itk::CuberilleImageToMeshFilter< TInputImage, TOutputMesh, TInterpolator >::PointsContainer = typename OutputMeshType::PointsContainer |
Definition at line 139 of file itkCuberilleImageToMeshFilter.h.
using itk::CuberilleImageToMeshFilter< TInputImage, TOutputMesh, TInterpolator >::PointsContainerPointer = typename OutputMeshType::PointsContainerPointer |
Definition at line 138 of file itkCuberilleImageToMeshFilter.h.
using itk::CuberilleImageToMeshFilter< TInputImage, TOutputMesh, TInterpolator >::PointType = typename OutputMeshType::PointType |
Definition at line 160 of file itkCuberilleImageToMeshFilter.h.
using itk::CuberilleImageToMeshFilter< TInputImage, TOutputMesh, TInterpolator >::QuadrilateralAutoPointer = typename QuadrilateralCellType::SelfAutoPointer |
Definition at line 149 of file itkCuberilleImageToMeshFilter.h.
using itk::CuberilleImageToMeshFilter< TInputImage, TOutputMesh, TInterpolator >::QuadrilateralCellAutoPointer = typename QuadrilateralCellType::CellAutoPointer |
Definition at line 150 of file itkCuberilleImageToMeshFilter.h.
using itk::CuberilleImageToMeshFilter< TInputImage, TOutputMesh, TInterpolator >::QuadrilateralCellType = QuadrilateralCell<CellInterfaceType> |
Definition at line 148 of file itkCuberilleImageToMeshFilter.h.
using itk::CuberilleImageToMeshFilter< TInputImage, TOutputMesh, TInterpolator >::Self = CuberilleImageToMeshFilter |
Standard "Self" type alias.
Definition at line 120 of file itkCuberilleImageToMeshFilter.h.
using itk::CuberilleImageToMeshFilter< TInputImage, TOutputMesh, TInterpolator >::SizeType = typename InputImageType::SizeType |
Definition at line 156 of file itkCuberilleImageToMeshFilter.h.
using itk::CuberilleImageToMeshFilter< TInputImage, TOutputMesh, TInterpolator >::SpacingType = typename InputImageType::SpacingType |
Definition at line 157 of file itkCuberilleImageToMeshFilter.h.
using itk::CuberilleImageToMeshFilter< TInputImage, TOutputMesh, TInterpolator >::SpacingValueType = typename InputImageType::SpacingValueType |
Definition at line 158 of file itkCuberilleImageToMeshFilter.h.
using itk::CuberilleImageToMeshFilter< TInputImage, TOutputMesh, TInterpolator >::Superclass = ImageToMeshFilter< TInputImage, TOutputMesh > |
Definition at line 121 of file itkCuberilleImageToMeshFilter.h.
using itk::CuberilleImageToMeshFilter< TInputImage, TOutputMesh, TInterpolator >::TriangleAutoPointer = typename TriangleCellType::SelfAutoPointer |
Definition at line 146 of file itkCuberilleImageToMeshFilter.h.
using itk::CuberilleImageToMeshFilter< TInputImage, TOutputMesh, TInterpolator >::TriangleCellAutoPointer = typename TriangleCellType::CellAutoPointer |
Definition at line 147 of file itkCuberilleImageToMeshFilter.h.
using itk::CuberilleImageToMeshFilter< TInputImage, TOutputMesh, TInterpolator >::TriangleCellType = TriangleCell<CellInterfaceType> |
Definition at line 145 of file itkCuberilleImageToMeshFilter.h.
|
private |
Some convenient type alias.
Definition at line 334 of file itkCuberilleImageToMeshFilter.h.
|
protected |
|
overrideprotected |
|
inlineprivate |
Add quadrilateral face to the given mesh. Increments cell identifier.
|
inlineprivate |
Add a vertex to the given mesh. Increments point identifier.
|
inlineprivate |
Private functions to implement the algorithm. Compute gradient image.
|
virtual |
Create an object from an instance, potentially deferring to a factory. This method allows you to create an instance of an object that is exactly the same type as the referring object. This is useful in cases where an object has been cast back to a base class.
Reimplemented from itk::MeshSource< TOutputMesh >.
|
overrideprotectedvirtual |
This method causes the filter to generate its output.
Reimplemented from itk::ProcessObject.
|
inlineoverrideprotectedvirtual |
Prepare the output
Reimplemented from itk::ImageToMeshFilter< TInputImage, TOutputMesh >.
Definition at line 250 of file itkCuberilleImageToMeshFilter.h.
|
virtual |
Get/Set whether triangle or quadrilateral faces should be generated. True = triangle faces, False = quadrilateral faces. Default = true (triangle faces).
|
virtual |
Get/Set whether triangle or quadrilateral faces should be generated. True = triangle faces, False = quadrilateral faces. Default = true (triangle faces).
|
virtual |
Get/Set whether triangle or quadrilateral faces should be generated. True = triangle faces, False = quadrilateral faces. Default = true (triangle faces).
|
virtual |
Get/Set interpolate function.
|
virtual |
Get/Set the iso-surface value. This parameter specifies the value of the iso-surface for which to generate the mesh. Pixels equal to or less than this value are considered on the surface or inside the resultant mesh.
|
virtual |
Run-time type information (and related methods).
Reimplemented from itk::ImageToMeshFilter< TInputImage, TOutputMesh >.
|
virtual |
Get/Set the maximum number of steps used during vertex projection. Default = 50.
|
virtual |
Get/Set the the initial step length for vertex projection. Values are clamped to the range [0.0, large]. Default = max spacing * 0.25 (expressed in physical space).
|
virtual |
Get/Set the step length relaxation factor during vertex projection. The step length is multiplied by this factor each iteration to allow convergence. Values are clamped to the range [0.0, 1.0]. Default = 0.95.
|
virtual |
Get/Set the threshold for the "distance" from iso-surface during vertex projection. Note that the distance is actually measured in pixel value units (not space). The smaller this value, the closer the vertices will be to the iso-surface. Small values result in longer convergence time (i.e. slower). Values are clamped to the range [0.0, max pixel value]. Default = 0.5.
|
virtual |
Get/Set whether the vertices should be project to the iso-surface. Default = true.
|
inlineprivate |
Get the vertex lookup index from the given index and vertex number.
|
static |
Method for creation through the object factory.
|
overrideprotectedvirtual |
Methods invoked by Print() to print information about the object including superclasses. Typically not called by the user (use Print() instead) but used in the hierarchical print process to combine the output of several classes.
Reimplemented from itk::MeshSource< TOutputMesh >.
|
inlineprivate |
Project vertex to the iso-surface by stepping along normal.
|
virtual |
Get/Set whether the vertices should be project to the iso-surface. Default = true.
|
virtual |
Get/Set whether the vertices should be project to the iso-surface. Default = true.
|
virtual |
Get/Set whether triangle or quadrilateral faces should be generated. True = triangle faces, False = quadrilateral faces. Default = true (triangle faces).
|
virtual |
|
virtual |
Get/Set interpolate function.
|
virtual |
Get/Set the iso-surface value. This parameter specifies the value of the iso-surface for which to generate the mesh. Pixels equal to or less than this value are considered on the surface or inside the resultant mesh.
|
virtual |
Get/Set the maximum number of steps used during vertex projection. Default = 50.
|
virtual |
Get/Set the the initial step length for vertex projection. Values are clamped to the range [0.0, large]. Default = max spacing * 0.25 (expressed in physical space).
|
virtual |
Get/Set the step length relaxation factor during vertex projection. The step length is multiplied by this factor each iteration to allow convergence. Values are clamped to the range [0.0, 1.0]. Default = 0.95.
|
virtual |
Get/Set the threshold for the "distance" from iso-surface during vertex projection. Note that the distance is actually measured in pixel value units (not space). The smaller this value, the closer the vertices will be to the iso-surface. Small values result in longer convergence time (i.e. slower). Values are clamped to the range [0.0, max pixel value]. Default = 0.5.
|
virtual |
Get/Set whether the vertices should be project to the iso-surface. Default = true.
|
inlineprivate |
Set a flag activating each vertex for the given face.
|
private |
Definition at line 360 of file itkCuberilleImageToMeshFilter.h.
|
private |
Definition at line 358 of file itkCuberilleImageToMeshFilter.h.
|
private |
Definition at line 357 of file itkCuberilleImageToMeshFilter.h.
|
private |
Definition at line 356 of file itkCuberilleImageToMeshFilter.h.
|
private |
Definition at line 359 of file itkCuberilleImageToMeshFilter.h.
|
private |
Definition at line 365 of file itkCuberilleImageToMeshFilter.h.
|
private |
Definition at line 363 of file itkCuberilleImageToMeshFilter.h.
|
private |
Definition at line 364 of file itkCuberilleImageToMeshFilter.h.
|
private |
Definition at line 362 of file itkCuberilleImageToMeshFilter.h.
|
private |
Definition at line 361 of file itkCuberilleImageToMeshFilter.h.