Panda3D
 All Classes Functions Variables Enumerations
eggVertexAux.h
1 // Filename: eggVertexAux.h
2 // Created by: jenes (15Nov11)
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 EGGVERTEXAUX_H
16 #define EGGVERTEXAUX_H
17 
18 #include "pandabase.h"
19 
20 #include "eggMorphList.h"
21 #include "eggNamedObject.h"
22 
23 #include "luse.h"
24 
25 ////////////////////////////////////////////////////////////////////
26 // Class : EggVertexAux
27 // Description : The set of named auxiliary data that may or may not
28 // be assigned to a vertex. Panda will import this data
29 // and create a custom column for it in the vertex data,
30 // but will not otherwise interpret it. Presumably, a
31 // shader will process the data later.
32 ////////////////////////////////////////////////////////////////////
33 class EXPCL_PANDAEGG EggVertexAux : public EggNamedObject {
34 PUBLISHED:
35  EggVertexAux(const string &name, const LVecBase4d &aux);
36  EggVertexAux(const EggVertexAux &copy);
37  EggVertexAux &operator = (const EggVertexAux &copy);
38  virtual ~EggVertexAux();
39 
40  INLINE void set_name(const string &name);
41 
42  INLINE const LVecBase4d &get_aux() const;
43  INLINE void set_aux(const LVecBase4d &aux);
44 
45  static PT(EggVertexAux) make_average(const EggVertexAux *first,
46  const EggVertexAux *second);
47 
48  void write(ostream &out, int indent_level) const;
49  int compare_to(const EggVertexAux &other) const;
50 
51 private:
52  LVecBase4d _aux;
53 
54 public:
55  static TypeHandle get_class_type() {
56  return _type_handle;
57  }
58  static void init_type() {
59  EggNamedObject::init_type();
60  register_type(_type_handle, "EggVertexAux",
61  EggNamedObject::get_class_type());
62  }
63  virtual TypeHandle get_type() const {
64  return get_class_type();
65  }
66  virtual TypeHandle force_init_type() {init_type(); return get_class_type();}
67 
68 private:
69  static TypeHandle _type_handle;
70 };
71 
72 #include "eggVertexAux.I"
73 
74 #endif
75 
This is the base class for all three-component vectors and points.
Definition: lvecBase4.h:1661
The set of named auxiliary data that may or may not be assigned to a vertex.
Definition: eggVertexAux.h:33
This is a fairly low-level base class–any egg object that has a name.
An STL function object class, this is intended to be used on any ordered collection of class objects ...
Definition: stl_compares.h:79
TypeHandle is the identifier used to differentiate C++ class types.
Definition: typeHandle.h:85