eggVertexPointer.h 1.3 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455
  1. /**
  2. * PANDA 3D SOFTWARE
  3. * Copyright (c) Carnegie Mellon University. All rights reserved.
  4. *
  5. * All use of this software is subject to the terms of the revised BSD
  6. * license. You should have received a copy of this license along
  7. * with this source code in a file named "LICENSE."
  8. *
  9. * @file eggVertexPointer.h
  10. * @author drose
  11. * @date 2001-02-26
  12. */
  13. #ifndef EGGVERTEXPOINTER_H
  14. #define EGGVERTEXPOINTER_H
  15. #include "pandatoolbase.h"
  16. #include "eggSliderPointer.h"
  17. #include "eggGroup.h"
  18. #include "pointerTo.h"
  19. /**
  20. * This stores a pointer back to a <Vertex>, or to a particular pritimive like
  21. * a <Polygon>, representing a morph offset.
  22. */
  23. class EggVertexPointer : public EggSliderPointer {
  24. public:
  25. EggVertexPointer(EggObject *egg_object);
  26. virtual int get_num_frames() const;
  27. virtual double get_frame(int n) const;
  28. virtual bool has_vertices() const;
  29. public:
  30. static TypeHandle get_class_type() {
  31. return _type_handle;
  32. }
  33. static void init_type() {
  34. EggSliderPointer::init_type();
  35. register_type(_type_handle, "EggVertexPointer",
  36. EggSliderPointer::get_class_type());
  37. }
  38. virtual TypeHandle get_type() const {
  39. return get_class_type();
  40. }
  41. virtual TypeHandle force_init_type() {init_type(); return get_class_type();}
  42. private:
  43. static TypeHandle _type_handle;
  44. };
  45. #endif