HDK
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
SIM_PointTree.h
Go to the documentation of this file.
1 /*
2  * PROPRIETARY INFORMATION. This software is proprietary to
3  * Side Effects Software Inc., and is not to be reproduced,
4  * transmitted, or disclosed in any way without written permission.
5  *
6  * NAME: SIM_PointTree.h ( SIM Library, C++)
7  *
8  * COMMENTS:
9  * This class builds a GEO_PointTree of the given Geometry
10  * as an alternative representation, allowing one to cache
11  * this useful structure.
12  */
13 
14 #ifndef __SIM_PointTree_H__
15 #define __SIM_PointTree_H__
16 
17 #include "SIM_API.h"
18 
19 #include "SIM_Data.h"
20 #include "SIM_DataUtils.h"
21 
22 #include "SIM_Utils.h"
23 
24 class GEO_PointTree;
25 
26 /// This class holds a GEO_PointTree which people can query.
27 /// The pointtree refers to the point numbers of the SIM_Geometry
28 /// this is an alternative represenation of.
29 /// This caches the point positions in the SIM_Geometry's space,
30 /// so are independent of SIM_Geometry's transform.
32 {
33 public:
34  /// Get the tree
35  GEO_PointTree *getTree() const;
36 
37 protected:
38  explicit SIM_PointTree(const SIM_DataFactory *factory);
39  virtual ~SIM_PointTree();
40 
41  /// Overrides to properly implement this class as a SIM_Data.
42  /// This object is meant to be updated from the object's geometry at
43  /// each frame, so we only implement skeleton save, and load methods.
44  virtual void initializeSubclass();
45  virtual int64 getMemorySizeSubclass() const;
46  virtual bool getIsAlternateRepresentationSubclass() const;
47  virtual void initAlternateRepresentationSubclass(const SIM_Data &);
48 
49 private:
50  GEO_PointTree *myTree;
51 
53 
55  SIM_Data,
56  "Point Tree",
58 };
59 
60 #endif
#define DECLARE_STANDARD_GETCASTTOTYPE()
Definition: SIM_DataUtils.h:45
virtual bool getIsAlternateRepresentationSubclass() const
virtual int64 getMemorySizeSubclass() const
#define DECLARE_DATAFACTORY(DataClass, SuperClass, Description, DopParms)
Definition: SIM_DataUtils.h:58
long long int64
Definition: SYS_Types.h:107
#define SIM_API
Definition: SIM_API.h:10
virtual void initAlternateRepresentationSubclass(const SIM_Data &)
static const SIM_DopDescription * getEmptyDopDescription()
A DOP description that says not to create an automatic DOP.
virtual void initializeSubclass()