Panda3D
nurbsVertex.h
1 // Filename: nurbsVertex.h
2 // Created by: drose (03Dec02)
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 NURBSVERTEX_H
16 #define NURBSVERTEX_H
17 
18 #include "pandabase.h"
19 #include "luse.h"
20 #include "nodePath.h"
21 #include "pmap.h"
22 
23 ////////////////////////////////////////////////////////////////////
24 // Class : NurbsVertex
25 // Description : This represents a single control vertex in a
26 // NurbsEvaluator. It may be relative to a particular
27 // coordinate space; or its coordinate space may be
28 // unspecified.
29 //
30 // This is not related to NurbsCurve, CubicCurveseg or
31 // any of the ParametricCurve-derived objects in this
32 // module. It is a completely parallel implementation
33 // of NURBS curves, and will probably eventually replace
34 // the whole ParametricCurve class hierarchy.
35 ////////////////////////////////////////////////////////////////////
36 class EXPCL_PANDA_PARAMETRICS NurbsVertex {
37 public:
38  INLINE NurbsVertex();
39  INLINE NurbsVertex(const NurbsVertex &copy);
40  INLINE void operator = (const NurbsVertex &copy);
41  INLINE ~NurbsVertex();
42 
43  INLINE void set_vertex(const LVecBase4 &vertex);
44  INLINE const LVecBase4 &get_vertex() const;
45 
46  INLINE void set_space(const NodePath &space);
47  INLINE void set_space(const string &space);
48  INLINE NodePath get_space(const NodePath &rel_to) const;
49 
50  void set_extended_vertex(int d, PN_stdfloat value);
51  PN_stdfloat get_extended_vertex(int d) const;
52 
53 private:
54  LVecBase4 _vertex;
55  NodePath _space;
56  string _space_path;
58  Extended _extended;
59 };
60 
61 #include "nurbsVertex.I"
62 
63 #endif
64 
This represents a single control vertex in a NurbsEvaluator.
Definition: nurbsVertex.h:36
This is the base class for all three-component vectors and points.
Definition: lvecBase4.h:111
NodePath is the fundamental system for disambiguating instances, and also provides a higher-level int...
Definition: nodePath.h:165