#include <itkOctree.h>
Represent a 3D Image with an Octree data structure.
Parameterized on Pixel type of the image, number of colors in color table, and a Mapping function, derived from itk::FunctionBase
Definition at line 128 of file itkOctree.h.
Public Types | |
using | ImageType = Image<TPixel, 3> |
using | ImageTypePointer = typename ImageType::Pointer |
using | Pointer = SmartPointer<Self> |
using | Self = Octree |
using | Superclass = OctreeBase |
![]() | |
using | OctreeEnum = OctreeEnums::Octree |
using | Pointer = SmartPointer<Self> |
using | Self = OctreeBase |
![]() | |
using | ConstPointer = SmartPointer<const Self> |
using | Pointer = SmartPointer<Self> |
using | Self = Object |
using | Superclass = LightObject |
![]() | |
using | ConstPointer = SmartPointer<const Self> |
using | Pointer = SmartPointer<Self> |
using | Self = LightObject |
Public Member Functions | |
void | BuildFromBuffer (const void *frombuffer, const unsigned int xsize, const unsigned int ysize, const unsigned int zsize) override |
void | BuildFromImage (Image< TPixel, 3 > *fromImage) |
virtual::itk::LightObject::Pointer | CreateAnother () const |
const OctreeNodeBranch * | GetColorTable () const override |
int | GetColorTableSize () const override |
unsigned int | GetDepth () override |
ImageTypePointer | GetImage () |
const char * | GetNameOfClass () const override |
OctreeNode * | GetTree () override |
int | GetValue (const unsigned int Dim0, const unsigned int Dim1, const unsigned int Dim2) |
unsigned int | GetWidth () override |
Octree () | |
void | SetColor (unsigned int color) |
void | SetDepth (unsigned int depth) override |
void | SetTree (OctreeNodeBranch *branch) |
void | SetTrueDims (const unsigned int Dim0, const unsigned int Dim1, const unsigned int Dim2) |
void | SetWidth (unsigned int width) override |
~Octree () override | |
![]() | |
unsigned long | AddObserver (const EventObject &event, Command *cmd) const |
unsigned long | AddObserver (const EventObject &event, std::function< void(const EventObject &)> function) const |
virtual void | DebugOff () const |
virtual void | DebugOn () const |
Command * | GetCommand (unsigned long tag) |
bool | GetDebug () const |
MetaDataDictionary & | GetMetaDataDictionary () |
const MetaDataDictionary & | GetMetaDataDictionary () const |
virtual ModifiedTimeType | GetMTime () const |
virtual const TimeStamp & | GetTimeStamp () const |
bool | HasObserver (const EventObject &event) const |
void | InvokeEvent (const EventObject &) |
void | InvokeEvent (const EventObject &) const |
virtual void | Modified () const |
void | Register () const override |
void | RemoveAllObservers () |
void | RemoveObserver (unsigned long tag) const |
void | SetDebug (bool debugFlag) const |
void | SetReferenceCount (int) override |
void | UnRegister () const noexcept override |
void | SetMetaDataDictionary (const MetaDataDictionary &rhs) |
void | SetMetaDataDictionary (MetaDataDictionary &&rrhs) |
virtual void | SetObjectName (std::string _arg) |
virtual const std::string & | GetObjectName () const |
![]() | |
Pointer | Clone () const |
virtual void | Delete () |
virtual int | GetReferenceCount () const |
void | Print (std::ostream &os, Indent indent=0) const |
Static Public Member Functions | |
static Pointer | New () |
![]() | |
static bool | GetGlobalWarningDisplay () |
static void | GlobalWarningDisplayOff () |
static void | GlobalWarningDisplayOn () |
static Pointer | New () |
static void | SetGlobalWarningDisplay (bool val) |
![]() | |
static void | BreakOnError () |
static Pointer | New () |
Private Member Functions | |
OctreeNodeBranch * | maskToOctree (const TPixel *Mask, unsigned int width, unsigned int x, unsigned int y, unsigned int z, unsigned int xsize, unsigned int ysize, unsigned int zsize) |
Private Attributes | |
OctreeNodeBranch | m_ColorTable [ColorTableSize] |
unsigned int | m_Depth { 0 } |
MappingFunctionType | m_MappingFunction {} |
OctreeEnum | m_Plane { OctreeEnum::UNKNOWN_PLANE } |
OctreeNode | m_Tree {} |
unsigned int | m_TrueDims [3] {} |
unsigned int | m_Width { 0 } |
Additional Inherited Members | |
![]() | |
Object () | |
bool | PrintObservers (std::ostream &os, Indent indent) const |
void | PrintSelf (std::ostream &os, Indent indent) const override |
virtual void | SetTimeStamp (const TimeStamp &timeStamp) |
~Object () override | |
![]() | |
virtual LightObject::Pointer | InternalClone () const |
LightObject () | |
virtual void | PrintHeader (std::ostream &os, Indent indent) const |
virtual void | PrintTrailer (std::ostream &os, Indent indent) const |
virtual | ~LightObject () |
![]() | |
std::atomic< int > | m_ReferenceCount {} |
using itk::Octree< TPixel, ColorTableSize, MappingFunctionType >::ImageType = Image<TPixel, 3> |
Definition at line 137 of file itkOctree.h.
using itk::Octree< TPixel, ColorTableSize, MappingFunctionType >::ImageTypePointer = typename ImageType::Pointer |
Definition at line 138 of file itkOctree.h.
using itk::Octree< TPixel, ColorTableSize, MappingFunctionType >::Pointer = SmartPointer<Self> |
Definition at line 136 of file itkOctree.h.
using itk::Octree< TPixel, ColorTableSize, MappingFunctionType >::Self = Octree |
Standard class type aliases.
Definition at line 134 of file itkOctree.h.
using itk::Octree< TPixel, ColorTableSize, MappingFunctionType >::Superclass = OctreeBase |
Definition at line 135 of file itkOctree.h.
itk::Octree< TPixel, ColorTableSize, MappingFunctionType >::Octree | ( | ) |
Referenced by GetNameOfClass().
|
override |
|
overridevirtual |
Build an Octree from an Image's pixel buffer.
Method needed for ImageIO class, which has no handle on image, just the pixel buffer.
Implements itk::OctreeBase.
void itk::Octree< TPixel, ColorTableSize, MappingFunctionType >::BuildFromImage | ( | Image< TPixel, 3 > * | fromImage | ) |
|
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::Object.
|
overridevirtual |
Get the ColorTable Pointer
Returns color table pointer for this tree.
Each Octree has an array of OctreeNodeBranch whose size = the number of color table entries. Each Node in the Octree points either to 8 sub-nodes, or into the ColorTable; The color table isn't actually used to hold data; it simply provides a range of unique addresses that are distinct from the address of any valid subtree.
Implements itk::OctreeBase.
|
overridevirtual |
Get the size of the Color Table
Implements itk::OctreeBase.
|
overridevirtual |
Get tree depth.
Depth represents x, for the smallest 2^x >= largest image dimension
Implements itk::OctreeBase.
ImageTypePointer itk::Octree< TPixel, ColorTableSize, MappingFunctionType >::GetImage | ( | ) |
|
overridevirtual |
|
overridevirtual |
Implements itk::OctreeBase.
int itk::Octree< TPixel, ColorTableSize, MappingFunctionType >::GetValue | ( | const unsigned int | Dim0, |
const unsigned int | Dim1, | ||
const unsigned int | Dim2 ) |
|
overridevirtual |
Get tree width.
Width == smallest 2^x >= largest image dimension i.e. 2^Depth == Width
Implements itk::OctreeBase.
|
private |
|
static |
Method for creation through the object factory.
|
inline |
Definition at line 161 of file itkOctree.h.
References m_Tree.
|
overridevirtual |
Set the depth, e.g. when reading tree from a file.
Implements itk::OctreeBase.
|
inline |
Definition at line 166 of file itkOctree.h.
References m_Tree.
void itk::Octree< TPixel, ColorTableSize, MappingFunctionType >::SetTrueDims | ( | const unsigned int | Dim0, |
const unsigned int | Dim1, | ||
const unsigned int | Dim2 ) |
|
overridevirtual |
Set width, e.g. when reading from a file.
Implements itk::OctreeBase.
|
private |
Definition at line 228 of file itkOctree.h.
|
private |
Definition at line 226 of file itkOctree.h.
|
private |
Definition at line 230 of file itkOctree.h.
|
private |
Definition at line 220 of file itkOctree.h.
|
private |
Definition at line 229 of file itkOctree.h.
Referenced by SetColor(), and SetTree().
|
private |
Definition at line 227 of file itkOctree.h.
|
private |
Definition at line 224 of file itkOctree.h.