IGSTK
igstkBoxObject.h
Go to the documentation of this file.
1 /*=========================================================================
2 
3  Program: Image Guided Surgery Software Toolkit
4  Module: $RCSfile: igstkBoxObject.h,v $
5  Language: C++
6  Date: $Date: 2008-02-11 01:41:50 $
7  Version: $Revision: 1.5 $
8 
9  Copyright (c) ISC Insight Software Consortium. All rights reserved.
10  See IGSTKCopyright.txt or http://www.igstk.org/copyright.htm for details.
11 
12  This software is distributed WITHOUT ANY WARRANTY; without even
13  the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
14  PURPOSE. See the above copyright notices for more information.
15 
16 =========================================================================*/
17 
18 #ifndef __igstkBoxObject_h
19 #define __igstkBoxObject_h
20 
21 #include "igstkMacros.h"
22 #include "igstkSpatialObject.h"
23 #include <itkGroupSpatialObject.h>
24 #include <itkFixedArray.h>
25 
26 namespace igstk
27 {
28 
39 class BoxObject
40 : public SpatialObject
41 {
42 
43 public:
44 
47 
48 public:
49 
51  typedef itk::FixedArray<double,3> ArrayType;
52 
54  void SetSize(double x, double y, double z);
55 
57  igstkSetMacro( Size , ArrayType );
58 
60  igstkGetMacro( Size , ArrayType );
61 
63  double GetSizeX() const;
64 
66  double GetSizeY() const;
67 
69  double GetSizeZ() const;
70 
71 protected:
72 
73  BoxObject( void );
74  ~BoxObject( void );
75 
76  BoxObject(const Self&); //purposely not implemented
77  void operator=(const Self&); //purposely not implemented
78 
80  virtual void PrintSelf( std::ostream& os, itk::Indent indent ) const;
81 
82 private:
83 
85  typedef itk::GroupSpatialObject<3> BoxSpatialObjectType;
86 
87  BoxSpatialObjectType::Pointer m_BoxSpatialObject;
88  ArrayType m_Size;
89 
90 };
91 
92 } // end namespace igstk
93 
94 #endif // __igstkBoxObject_h
#define igstkGetMacro(name, type)
Get built-in type.
Definition: igstkMacros.h:105
This class represents a Box object.
Geometrical abstraction of physical objects present in the surgical scene.
double GetSizeY() const
Get size of the Y axis.
Base class for all the IGSTK classes.
Definition: igstkObject.h:40
#define igstkStandardClassTraitsMacro(classname, superclassname)
Convenience macro for traits of a non-templated class.
Definition: igstkMacros.h:275
defines standard system-wide macros, constants, and other common parameters in the IGSTK Library...
double GetSizeX() const
Get size of the X axis.
void operator=(const Self &)
virtual void PrintSelf(std::ostream &os, itk::Indent indent) const
Print object information.
double GetSizeZ() const
Get size of the Z axis.
virtual void SetSize(ArrayType _arg)
Set the size given an array.
#define igstkSetMacro(name, type)
Set built-in type.
Definition: igstkMacros.h:93