Начинаю добавлять управление камерой. (Сейчас только её позиция)
This commit is contained in:
@@ -8,10 +8,14 @@
|
||||
#include <memory>
|
||||
|
||||
#define GLM_FORCE_RADIANS
|
||||
#include <mutex>
|
||||
#include <glm/glm.hpp>
|
||||
|
||||
class Camera;
|
||||
class GPU_GarbageCollector;
|
||||
|
||||
#define GET_RENDER_ENGINE static_cast<UwURenderEngine*>(GetWorld()->GetGameInstance().GetCore().GetRenderEngine())
|
||||
|
||||
class UwURenderEngine : public RenderEngineBase
|
||||
{
|
||||
struct QueueFamilyIndices
|
||||
@@ -62,6 +66,8 @@ class UwURenderEngine : public RenderEngineBase
|
||||
CoreInstance& core_;
|
||||
std::shared_ptr<ModelManager> model_manager_;
|
||||
std::shared_ptr<GPU_GarbageCollector> garbage_collector_;
|
||||
std::weak_ptr<Camera> active_camera_;
|
||||
std::mutex m_active_camera_;
|
||||
|
||||
VkInstance instance_ = VK_NULL_HANDLE;
|
||||
VkSurfaceKHR surface_ = VK_NULL_HANDLE;
|
||||
@@ -142,4 +148,6 @@ public:
|
||||
void stop_render() const override;
|
||||
|
||||
std::shared_ptr<ModelManager> GetModelManager() const { return model_manager_; }
|
||||
|
||||
void SetActiveCamera(std::weak_ptr<Camera> camera);
|
||||
};
|
||||
|
||||
Reference in New Issue
Block a user