HDK
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
SIM_GuideTimeDep.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  */
7 
8 #ifndef __SIM_GuideTimeDep_h__
9 #define __SIM_GuideTimeDep_h__
10 
11 #include "SIM_API.h"
12 #include "SIM_Guide.h"
13 
14 /// This SIM_Guide subclass is a container for another type of SIM_Guide
15 /// which is provided as a template parameter. Each object causes a new
16 /// SIM_Guide to be generated, and requests are passed on to that contained
17 /// SIM_Guide.
18 template<class GuideBase>
19 class SIM_GuideTimeDep : public GuideBase
20 {
21 public:
22  /// Constructor which takes a const SIM_Data as our owner.
23  explicit SIM_GuideTimeDep(const SIM_Data *owner)
24  : GuideBase(owner)
25  {
26  }
27  /// Constructor which takes an owner, and a flag to pass on to our base.
28  /// This flag is used by SIM_GuideShared.
29  explicit SIM_GuideTimeDep(const SIM_Data *owner,
30  bool displayonce)
31  : GuideBase(owner, displayonce)
32  {
33  }
34  /// Destructor for this class.
36  {
37  }
38 
39 protected:
41  const SIM_RootData &root,
42  UT_DMatrix4 &xform,
43  const SIM_Time &t)
44  {
45  if( t != myTime )
46  {
47  this->clear();
48  myTime = t;
49  }
50 
51  return GuideBase::
52  getGuideGeometrySubclass(root,
53  xform,
54  t);
55  }
56 
57 private:
58  SIM_Time myTime;
59 };
60 
61 #endif
62 
virtual ~SIM_GuideTimeDep()
Destructor for this class.
SIM_GuideTimeDep(const SIM_Data *owner)
Constructor which takes a const SIM_Data as our owner.
virtual GU_ConstDetailHandle getGuideGeometrySubclass(const SIM_RootData &root, UT_DMatrix4 &xform, const SIM_Time &t)
SIM_GuideTimeDep(const SIM_Data *owner, bool displayonce)