SceneImporter.h 1.3 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748
  1. //
  2. // Copyright (c) 2014-2015, THUNDERBEAST GAMES LLC All rights reserved
  3. // LICENSE: Atomic Game Engine Editor and Tools EULA
  4. // Please see LICENSE_ATOMIC_EDITOR_AND_TOOLS.md in repository root for
  5. // license information: https://github.com/AtomicGameEngine/AtomicGameEngine
  6. //
  7. #pragma once
  8. #include "AssetImporter.h"
  9. namespace ToolCore
  10. {
  11. class SceneImporter : public AssetImporter
  12. {
  13. OBJECT(SceneImporter);
  14. public:
  15. /// Construct.
  16. SceneImporter(Context* context, Asset *asset);
  17. virtual ~SceneImporter();
  18. virtual void SetDefaults();
  19. /// Set the scene camera's rotation
  20. void SetSceneCamRotation(const Quaternion& rotation) { sceneCamRotation_ = rotation; }
  21. /// Set the scene camera's position
  22. void SetSceneCamPosition(const Vector3& position) { sceneCamPosition_ = position; }
  23. /// Get the scene camera's rotation
  24. const Quaternion& GetSceneCamRotation() const { return sceneCamRotation_; }
  25. /// Get the scene camera's position
  26. const Vector3& GetSceneCamPosition() const { return sceneCamPosition_; }
  27. protected:
  28. bool Import();
  29. virtual bool LoadSettingsInternal(JSONValue& jsonRoot);
  30. virtual bool SaveSettingsInternal(JSONValue& jsonRoot);
  31. Quaternion sceneCamRotation_;
  32. Vector3 sceneCamPosition_;
  33. };
  34. }