adding and integrating ImGuizmo
This commit is contained in:
@@ -0,0 +1,20 @@
|
||||
#include "game_panel.hpp"
|
||||
|
||||
#include <imgui.h>
|
||||
|
||||
void GamePanel::onUpdate(const sophia::FrameInfo&) {
|
||||
syncSceneView(context, sceneViews, view, isShown());
|
||||
|
||||
if (!context.hasScene()) {
|
||||
ImGui::TextDisabled("No scene open");
|
||||
return;
|
||||
}
|
||||
|
||||
const ImVec2 origin = ImGui::GetCursorScreenPos();
|
||||
ui.image(target);
|
||||
|
||||
if (!context.getScene().getActiveCamera()) {
|
||||
ImGui::SetCursorScreenPos(ImVec2(origin.x + 8.0f, origin.y + 8.0f));
|
||||
ImGui::TextDisabled("The scene has no active camera");
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user