Panda3D
vertexMembership.I
1 // Filename: vertexMembership.I
2 // Created by: drose (21Jul03)
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 
16 ////////////////////////////////////////////////////////////////////
17 // Function: VertexMembership::Constructor
18 // Access: Public
19 // Description:
20 ////////////////////////////////////////////////////////////////////
21 INLINE VertexMembership::
22 VertexMembership(EggGroup *group, double membership) :
23  _group(group),
24  _membership(membership)
25 {
26 }
27 
28 ////////////////////////////////////////////////////////////////////
29 // Function: VertexMembership::Copy Constructor
30 // Access: Public
31 // Description:
32 ////////////////////////////////////////////////////////////////////
33 INLINE VertexMembership::
34 VertexMembership(const VertexMembership &copy) :
35  _group(copy._group),
36  _membership(copy._membership)
37 {
38 }
39 
40 ////////////////////////////////////////////////////////////////////
41 // Function: VertexMembership::Copy Assignment Operator
42 // Access: Public
43 // Description:
44 ////////////////////////////////////////////////////////////////////
45 INLINE void VertexMembership::
46 operator = (const VertexMembership &copy) {
47  _group = copy._group;
48  _membership = copy._membership;
49 }
50 
51 ////////////////////////////////////////////////////////////////////
52 // Function: VertexMembership::Ordering Operator
53 // Access: Public
54 // Description:
55 ////////////////////////////////////////////////////////////////////
56 INLINE bool VertexMembership::
57 operator < (const VertexMembership &other) const {
58  if (_membership != other._membership) {
59  return _membership < other._membership;
60  }
61  return _group < other._group;
62 }
The main glue of the egg hierarchy, this corresponds to the <Group>, <Instance>, and <Joint> type nod...
Definition: eggGroup.h:36
This class is used to help EggOptchar quantize the membership of one vertex among its various groups...