lwoSurfaceBlockRefObj.h 1.2 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051
  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 lwoSurfaceBlockRefObj.h
  10. * @author drose
  11. * @date 2001-04-24
  12. */
  13. #ifndef LWOSURFACEBLOCKREFOBJ_H
  14. #define LWOSURFACEBLOCKREFOBJ_H
  15. #include "pandatoolbase.h"
  16. #include "lwoChunk.h"
  17. /**
  18. * Specifies a reference object that the texture UV's are to be computed
  19. * relative to.
  20. */
  21. class LwoSurfaceBlockRefObj : public LwoChunk {
  22. public:
  23. std::string _name;
  24. public:
  25. virtual bool read_iff(IffInputFile *in, size_t stop_at);
  26. virtual void write(std::ostream &out, int indent_level = 0) const;
  27. public:
  28. virtual TypeHandle get_type() const {
  29. return get_class_type();
  30. }
  31. virtual TypeHandle force_init_type() {init_type(); return get_class_type();}
  32. static TypeHandle get_class_type() {
  33. return _type_handle;
  34. }
  35. static void init_type() {
  36. LwoChunk::init_type();
  37. register_type(_type_handle, "LwoSurfaceBlockRefObj",
  38. LwoChunk::get_class_type());
  39. }
  40. private:
  41. static TypeHandle _type_handle;
  42. };
  43. #endif