Medical Imaging Interaction Toolkit  2016.11.0
Medical Imaging Interaction Toolkit
All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Modules Pages
mitkBoundingObject.h
Go to the documentation of this file.
1 /*===================================================================
2 
3 The Medical Imaging Interaction Toolkit (MITK)
4 
5 Copyright (c) German Cancer Research Center,
6 Division of Medical and Biological Informatics.
7 All rights reserved.
8 
9 This software is distributed WITHOUT ANY WARRANTY; without
10 even the implied warranty of MERCHANTABILITY or FITNESS FOR
11 A PARTICULAR PURPOSE.
12 
13 See LICENSE.txt or http://www.mitk.org for details.
14 
15 ===================================================================*/
16 
17 #ifndef BOUNDINGOBJECT_H_HEADER_INCLUDED
18 #define BOUNDINGOBJECT_H_HEADER_INCLUDED
19 
21 #include <mitkSurface.h>
22 
23 namespace mitk
24 {
25  //##Documentation
26  //## @brief superclass of all bounding objects (cylinder, cuboid,...)
27  //##
28  //## Manages generic functions and provides an interface for IsInside()
29  //## calculates a generic bounding box
30  //## @ingroup Data
32  {
33  public:
35 
36  virtual bool IsInside(const mitk::Point3D &p) const = 0;
37 
38  virtual mitk::ScalarType GetVolume();
39  itkGetMacro(Positive, bool);
40  itkSetMacro(Positive, bool);
41  itkBooleanMacro(Positive);
42 
43  //##Documentation
44  //## @brief Sets the Geometry3D of the bounding object to fit the given
45  //## geometry.
46  //##
47  //## The fit is done once, so if the given geometry changes it will
48  //## \em not effect the bounding object.
49  virtual void FitGeometry(BaseGeometry *aGeometry3D);
50 
51  protected:
53  virtual ~BoundingObject();
54 
55  bool WriteXMLData(XMLWriter &xmlWriter);
56 
57  //##Documentation
58  //## \brief If \a true, the Boundingobject describes a positive volume,
59  //## if \a false a negative volume.
60  //##
61  bool m_Positive;
62 
63  private:
65  BoundingObject &operator=(const BoundingObject &);
66  };
67 }
68 #endif /* BOUNDINGOBJECT_H_HEADER_INCLUDED */
Class for storing surfaces (vtkPolyData).
Definition: mitkSurface.h:32
#define MITKDATATYPESEXT_EXPORT
double ScalarType
DataCollection - Class to facilitate loading/accessing structured data.
superclass of all bounding objects (cylinder, cuboid,...)
#define mitkClassMacro(className, SuperClassName)
Definition: mitkCommon.h:44
bool m_Positive
If true, the Boundingobject describes a positive volume, if false a negative volume.
BaseGeometry Describes the geometry of a data object.