VR-Forces 4.7 Class Documentation
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Groups Pages
diGuyIntrinsicAnimationMap.h
Go to the documentation of this file.
1 /*******************************************************************************
6 
7 
8 
9 #pragma once
10 
11 #include <vlutil/vlString.h>
12 #include <vlutil/vlFilename.h>
13 #include <map>
14 #include <list>
15 
16 #include "vrfutil/lifeformStaticPostures.h"
17 #include "vrfutil/vrfutilDefines.h"
18 #include "vrfutil/diGuyAnimation.h"
19 
26 
27 class DT_DLL_vrfutil DtDiGuyIntrinsicAnimationMap
28 {
29 public:
30 
31  typedef std::list<DtDiGuyAnimationSharedPtr> AnimationList;
32  typedef AnimationList::iterator AnimationListIterator;
33  typedef AnimationList::const_iterator const_AnimationListIterator;
34  typedef DtBoost::shared_ptr<AnimationList> AnimationListSharedPtr;
35 
36  typedef std::map<DtLifeformStaticPosture, AnimationListSharedPtr> IntrinsicAnimationMap;
37  typedef IntrinsicAnimationMap::iterator IntrinsicAnimationMapIterator;
38  typedef IntrinsicAnimationMap::const_iterator const_IntrinsicAnimationMapIterator;
39 
40  typedef std::list<DtLifeformStaticPosture> PostureList;
41  typedef std::map<DtLifeformStaticPosture, PostureList> BackupPostureMap;
42 
43  DtDiGuyIntrinsicAnimationMap();
44 
45  DtDiGuyIntrinsicAnimationMap(const DtFilename& name);
46 
47  DtDiGuyIntrinsicAnimationMap(const DtDiGuyIntrinsicAnimationMap& orig);
48 
49  DtDiGuyIntrinsicAnimationMap& operator=(const DtDiGuyIntrinsicAnimationMap& orig);
50 
51  virtual ~DtDiGuyIntrinsicAnimationMap();
52 
53  virtual void init();
54 
55  virtual DtDiGuyAnimation * findClosestAnimation(DtLifeformStaticPosture,double speed,
56  const DtString & demeanor,bool randomize=true);
57 
58  virtual DtDiGuyAnimation * lookupAnimationByName(const DtString & name);
59  virtual DtDiGuyAnimation * lookupAnimationByName(AnimationListSharedPtr list,const DtString & name);
60 
61  virtual AnimationListSharedPtr lookupAnimationList(DtLifeformStaticPosture post);
62 
63  virtual void addAnimationToList(AnimationListSharedPtr list,DtDiGuyAnimationSharedPtr animation);
64 
65  virtual void addAnimationToMap( DtDiGuyAnimationSharedPtr animation);
66 
67 protected:
68 
69  DtFilename myIntrinsicAnimationMapFile;
70  IntrinsicAnimationMap myIntrinsicAnimationMap;
71  BackupPostureMap myBackupPostures;
72 };

Document ID: Generated on Fri Apr 26 21:53:14 EDT 2019 from SVN revision 197883
Copyright © 2005-2019 VT MAK. All Rights Reserved (www.mak.com)