ArcGIS Procedural Runtime  3.2.10650
BoundingBox.h
1 /*
2  COPYRIGHT (c) 2012-2024 Esri R&D Center Zurich
3  TRADE SECRETS: ESRI PROPRIETARY AND CONFIDENTIAL
4  Unpublished material - all rights reserved under the
5  Copyright Laws of the United States and applicable international
6  laws, treaties, and conventions.
7 
8  For additional information, contact:
9  Environmental Systems Research Institute, Inc.
10  Attn: Contracts and Legal Services Department
11  380 New York Street
12  Redlands, California, 92373
13  USA
14 
15  email: contracts@esri.com
16 */
17 
18 #ifndef PRTX_BOUNDINGBOX_H_
19 #define PRTX_BOUNDINGBOX_H_
20 
21 #include "prtx/prtx.h"
22 #include "prtx/Types.h"
23 
24 
25 #ifdef _MSC_VER
26 # pragma warning(push)
27 # pragma warning (disable : 4251) // 'identifier' : class 'type' needs to have dll-interface to be used by clients of class 'type2'
28 # pragma warning (disable : 4275) // non DLL-interface classkey 'identifier' used as base for DLL-interface classkey 'identifier'
29 #endif
30 
31 
32 namespace prtx {
33 
34 
38 class PRTX_EXPORTS_API BoundingBox {
39 public:
40 
44  BoundingBox();
45 
49  BoundingBox(const DoubleVector& extMin, const DoubleVector& extMax);
50 
54  BoundingBox(const double* extMin, const double* extMax);
55 
56  virtual ~BoundingBox();
57 
61  void reset();
62 
66  void add(const BoundingBox& bbox);
67 
71  void add(const double& x, const double& y, const double& z);
72 
76  void translate(const DoubleVector& t);
77 
81  const DoubleVector& getMin() const;
82 
86  const DoubleVector& getMax() const;
87 
91  DoubleVector getMinMax() const;
92 
96  DoubleVector getCenter() const;
97 
101  DoubleVector getCenterBottom() const;
102 
106  void getSize(prtx::DoubleVector& s) const;
107 
111  double getDiameter() const;
112 
116  bool isModified() const;
117 
118 protected:
119  DoubleVector mExtMin, mExtMax;
120 };
121 
122 
123 } /* namespace prtx */
124 
125 
126 #ifdef _MSC_VER
127 # pragma warning(pop)
128 #endif
129 
130 
131 #endif /* PRTX_BOUNDINGBOX_H_ */
Definition: BoundingBox.h:38
std::vector< double > DoubleVector
vector of double
Definition: Types.h:32
The Procedural Runtime eXtension namespace. The prtx namespace contains the tools to extend the Proce...
Definition: AnnotationBuilder.h:35