00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019 #ifndef EGGMORPH_H
00020 #define EGGMORPH_H
00021
00022 #include <pandabase.h>
00023
00024 #include <namable.h>
00025 #include <luse.h>
00026 #include "pset.h"
00027
00028
00029
00030
00031
00032
00033
00034
00035
00036 template<class Parameter>
00037 class EggMorph : public Namable {
00038 public:
00039 INLINE EggMorph(const string &name, const Parameter &offset);
00040 INLINE void set_offset(const Parameter &offset);
00041 INLINE const Parameter &get_offset() const;
00042
00043 INLINE bool operator < (const EggMorph<Parameter> &other) const;
00044 INLINE bool operator == (const EggMorph<Parameter> &other) const;
00045 INLINE bool operator != (const EggMorph<Parameter> &other) const;
00046
00047 private:
00048 Parameter _offset;
00049 };
00050
00051 EXPORT_TEMPLATE_CLASS(EXPCL_PANDAEGG, EXPTP_PANDAEGG, EggMorph<LVector3d>);
00052 EXPORT_TEMPLATE_CLASS(EXPCL_PANDAEGG, EXPTP_PANDAEGG, EggMorph<LVector2d>);
00053 EXPORT_TEMPLATE_CLASS(EXPCL_PANDAEGG, EXPTP_PANDAEGG, EggMorph<LVector4f>);
00054
00055 typedef EggMorph<LVector3d> EggMorphVertex;
00056 typedef EggMorph<LVector3d> EggMorphNormal;
00057 typedef EggMorph<LVector2d> EggMorphTexCoord;
00058 typedef EggMorph<LVector4f> EggMorphColor;
00059
00060 INLINE ostream &operator << (ostream &out, const EggMorphVertex &m);
00061 INLINE ostream &operator << (ostream &out, const EggMorphTexCoord &m);
00062 INLINE ostream &operator << (ostream &out, const EggMorphColor &m);
00063
00064
00065
00066
00067
00068
00069 #include "eggMorph.I"
00070
00071 #endif