16
0
mirror of https://github.com/MaSzyna-EU07/maszyna.git synced 2026-07-19 20:19:18 +02:00

mvp matrices cached separately for each render pass, eliminated duplicate screen width/height variables

This commit is contained in:
tmj-fstate
2017-07-29 00:28:37 +02:00
parent 3a26ccb2fd
commit 4357919272
13 changed files with 322 additions and 216 deletions

View File

@@ -168,7 +168,7 @@ mouse_input::poll() {
auto updaterate { m_updaterate };
if( m_varyingpollrate ) {
updaterate /= std::max( 0.15, 2.0 * glm::length( m_cursorposition - m_commandstartcursor ) / std::max( 1, Global::ScreenHeight ) );
updaterate /= std::max( 0.15, 2.0 * glm::length( m_cursorposition - m_commandstartcursor ) / std::max( 1, Global::iWindowHeight ) );
}
if( m_updateaccumulator < updaterate ) {