DAEOptimizer.h 896 B

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849
  1. #ifndef DAEOPTIMIZER_H_
  2. #define DAEOPTIMIZER_H_
  3. #include "DAEUtil.h"
  4. namespace gameplay
  5. {
  6. /**
  7. * The DAEOptimizer optimizes a COLLADA dom.
  8. */
  9. class DAEOptimizer
  10. {
  11. public:
  12. /**
  13. * Constructor.
  14. */
  15. DAEOptimizer(domCOLLADA* dom);
  16. /**
  17. * Destructor.
  18. */
  19. ~DAEOptimizer(void);
  20. /**
  21. * Combines all of the animations that target the node and all of its child nodes into a new animation with the given ID.
  22. *
  23. * @param nodeId The ID of the node.
  24. * @param animationId The ID of the new animation to create.
  25. */
  26. void combineAnimations(const std::string& nodeId, const std::string& animationId);
  27. private:
  28. /**
  29. * Deletes all of the empty animations in the dom.
  30. */
  31. void deleteEmptyAnimations();
  32. private:
  33. domCOLLADA* _dom;
  34. std::string _inputPath;
  35. };
  36. }
  37. #endif