SpiecsEngine
 
Loading...
Searching...
No Matches

◆ PanSpeed()

std::pair< float, float > Spices::MeshController::PanSpeed ( ) const
private

Definition at line 71 of file MeshController.cpp.

72 {
73 const float x = std::min(m_ViewportWidth / 1000.0f, 2.4f); // max = 2.4f
74 float xFactor = 0.0366f * (x * x) - 0.1778f * x + 0.3021f;
75
76 const float y = std::min(m_ViewportHeight / 1000.0f, 2.4f); // max = 2.4f
77 float yFactor = 0.0366f * (y * y) - 0.1778f * y + 0.3021f;
78
79 return { xFactor, yFactor };
80 }

References m_ViewportHeight, and m_ViewportWidth.

Referenced by MousePan().