Panda3D
 All Classes Functions Variables Enumerations
eggSAnimData.h
1 // Filename: eggSAnimData.h
2 // Created by: drose (19Feb99)
3 //
4 ////////////////////////////////////////////////////////////////////
5 //
6 // PANDA 3D SOFTWARE
7 // Copyright (c) Carnegie Mellon University. All rights reserved.
8 //
9 // All use of this software is subject to the terms of the revised BSD
10 // license. You should have received a copy of this license along
11 // with this source code in a file named "LICENSE."
12 //
13 ////////////////////////////////////////////////////////////////////
14 
15 #ifndef EGGSANIMDATA_H
16 #define EGGSANIMDATA_H
17 
18 #include "pandabase.h"
19 
20 #include "eggAnimData.h"
21 
22 ////////////////////////////////////////////////////////////////////
23 // Class : EggSAnimData
24 // Description : Corresponding to an <S$Anim> entry, this stores a
25 // single column of numbers, for instance for a morph
26 // target, or as one column in an EggXfmSAnim.
27 ////////////////////////////////////////////////////////////////////
28 class EXPCL_PANDAEGG EggSAnimData : public EggAnimData {
29 PUBLISHED:
30  INLINE EggSAnimData(const string &name = "");
31  INLINE EggSAnimData(const EggSAnimData &copy);
32  INLINE EggSAnimData &operator = (const EggSAnimData &copy);
33 
34  INLINE int get_num_rows() const;
35  INLINE double get_value(int row) const;
36  INLINE void set_value(int row, double value);
37 
38  void optimize();
39 
40  virtual void write(ostream &out, int indent_level) const;
41 
42 public:
43 
44  static TypeHandle get_class_type() {
45  return _type_handle;
46  }
47  static void init_type() {
48  EggAnimData::init_type();
49  register_type(_type_handle, "EggSAnimData",
50  EggAnimData::get_class_type());
51  }
52  virtual TypeHandle get_type() const {
53  return get_class_type();
54  }
55  virtual TypeHandle force_init_type() {init_type(); return get_class_type();}
56 
57 private:
58  static TypeHandle _type_handle;
59 };
60 
61 #include "eggSAnimData.I"
62 
63 #endif
64 
Corresponding to an &lt;S$Anim&gt; entry, this stores a single column of numbers, for instance for a morph ...
Definition: eggSAnimData.h:28
A base class for EggSAnimData and EggXfmAnimData, which contain rows and columns of numbers...
Definition: eggAnimData.h:32
TypeHandle is the identifier used to differentiate C++ class types.
Definition: typeHandle.h:85