ModelResourceEditor.h 1.1 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657
  1. // Copyright (c) 2014-2015, THUNDERBEAST GAMES LLC All rights reserved
  2. // Please see LICENSE.md in repository root for license information
  3. // https://github.com/AtomicGameEngine/AtomicGameEngine
  4. #pragma once
  5. #include <TurboBadger/tb_widgets_common.h>
  6. #include "ResourceEditor.h"
  7. using namespace Atomic;
  8. using namespace tb;
  9. namespace Atomic
  10. {
  11. class Scene;
  12. class Node;
  13. class Camera;
  14. }
  15. namespace AtomicEditor
  16. {
  17. class JSAutocomplete;
  18. class ModelResourceEditor: public ResourceEditor
  19. {
  20. OBJECT(ModelResourceEditor);
  21. public:
  22. ModelResourceEditor(Context* context, const String& fullpath, TBTabContainer* container);
  23. virtual ~ModelResourceEditor();
  24. bool OnEvent(const TBWidgetEvent &ev);
  25. void HandleUpdate(StringHash eventType, VariantMap& eventData);
  26. private:
  27. void MoveCamera(float timeStep);
  28. SharedPtr<Scene> scene_;
  29. SharedPtr<Node> cameraNode_;
  30. //SharedPtr<View3D> view3D_;
  31. SharedPtr<Camera> camera_;
  32. float yaw_;
  33. float pitch_;
  34. TBLayout* layout_;
  35. TBContainer* view3DContainer_;
  36. WeakPtr<Node> modelNode_;
  37. };
  38. }