Skip to content

dev分支下的ImGuizmo代码 #7

Description

@hebohang

在 EditorLayer.cpp 中的第 507 行:

		  if (ImGui::ImageButton((void*)m_TransTexture->GetRendererID(), ImVec2(m_PlayBarTexture->GetWidth(), m_PlayBarTexture->GetHeight()), ImVec2(0, 1), ImVec2(1, 0), 0.0f, ImVec4(0.0f, 0.0f, 0.0f, 0.0f), m_GizmoType == 0 ? ImVec4(1.0f, 1.0f, 0.0f, 0.9f) : ImVec4(1.0f, 1.0f, 0.0f, 0.5f)))
		  {
			m_GizmoType = 0;
		  }	 

m_GizmoType = 0 应该改换成 ImGuizmo::OPERATION::TRANSLATE,否则更高版本的 ImGuizmo 会有问题。

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

BugSomething isn't working

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions