mirror of
https://github.com/zhenyan121/Cubed.git
synced 2026-04-10 06:14:07 +08:00
feat: enable raw mouse motion
This commit is contained in:
@@ -17,7 +17,7 @@ private:
|
|||||||
float m_yaw = 0.0f;
|
float m_yaw = 0.0f;
|
||||||
float m_pitch = 0.0f;
|
float m_pitch = 0.0f;
|
||||||
|
|
||||||
float m_sensitivity = 0.05f;
|
float m_sensitivity = 0.15f;
|
||||||
|
|
||||||
float m_speed = 5.0f;
|
float m_speed = 5.0f;
|
||||||
|
|
||||||
|
|||||||
@@ -46,7 +46,12 @@ void Window::init() {
|
|||||||
|
|
||||||
|
|
||||||
glfwSetInputMode(m_window, GLFW_CURSOR, GLFW_CURSOR_DISABLED);
|
glfwSetInputMode(m_window, GLFW_CURSOR, GLFW_CURSOR_DISABLED);
|
||||||
|
if (glfwRawMouseMotionSupported()) {
|
||||||
|
glfwSetInputMode(m_window, GLFW_RAW_MOUSE_MOTION, GLFW_TRUE);
|
||||||
|
} else {
|
||||||
|
LOG::warn("Don,t support Raw Mouse Motion");
|
||||||
|
}
|
||||||
|
|
||||||
//update_viewport();
|
//update_viewport();
|
||||||
|
|
||||||
}
|
}
|
||||||
Reference in New Issue
Block a user