Skip to content

Commit

Permalink
only render picking scene on click
Browse files Browse the repository at this point in the history
  • Loading branch information
Astral-C committed Sep 3, 2024
1 parent 7a77ac4 commit 43ae196
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/UStarForgeContext.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -394,8 +394,8 @@ void UStarForgeContext::Render(float deltaTime) {
cursorPos = ImGui::GetCursorScreenPos();
ImGui::Image(reinterpret_cast<void*>(static_cast<uintptr_t>(mViewTex)), winSize, {0.0f, 1.0f}, {1.0f, 0.0f});

J3D::Picking::RenderPickingScene(view, projection, packets);
if(ImGui::IsItemClicked(0) && !ImGuizmo::IsOver()){
J3D::Picking::RenderPickingScene(view, projection, packets);
ImVec2 mousePos = ImGui::GetMousePos();

ImVec2 pickPos = {
Expand Down

0 comments on commit 43ae196

Please sign in to comment.