Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

移除了onCursorPos函数中对m_mouse_x和 m_mouse_y的判断 #371

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

sorvon
Copy link
Contributor

@sorvon sorvon commented Oct 13, 2022

这里if (m_mouse_x >= 0.0f && m_mouse_y >= 0.0f)的限制会导致在editor_mode下使用右键旋转相机时,鼠标向左(或向上)移动一定距离后就无法继续向左(或向上)旋转相机了。

@hyv1001 hyv1001 self-assigned this Oct 21, 2022
Copy link

@zDagwood zDagwood left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

直接移除鼠标操作限制,会引入鼠标在界面外操作引起的意外情况出现。且仍然无法满足无限旋转的需求(鼠标位置仍然受屏幕限制)。想要实现无限旋转,可以考虑记录每帧的位移delta,把鼠标固定在某一位置

@sorvon
Copy link
Contributor Author

sorvon commented Oct 21, 2022

直接移除鼠标操作限制,会引入鼠标在界面外操作引起的意外情况出现。且仍然无法满足无限旋转的需求(鼠标位置仍然受屏幕限制)。想要实现无限旋转,可以考虑记录每帧的位移delta,把鼠标固定在某一位置

  • 左右不受限制了吧?上下是因为锁了相机角度。
  • 鼠标在界面外操作引起的意外情况具体有哪些?

@zDagwood
Copy link

直接移除鼠标操作限制,会引入鼠标在界面外操作引起的意外情况出现。且仍然无法满足无限旋转的需求(鼠标位置仍然受屏幕限制)。想要实现无限旋转,可以考虑记录每帧的位移delta,把鼠标固定在某一位置

  • 左右不受限制了吧?上下是因为锁了相机角度。
  • 鼠标在界面外操作引起的意外情况具体有哪些?

.左右仍然受屏幕大小限制
.比如意外的响应了其他界面或者应用的MouseMove或者MouseUp事件

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants