mouse fix
This commit is contained in:
parent
337cf1e43b
commit
ef199b180e
4 changed files with 20 additions and 6 deletions
|
|
@ -598,6 +598,8 @@ void Window::Update() {
|
|||
vblank = duration_cast<std::chrono::milliseconds>(startTime - frameEnd);
|
||||
#endif
|
||||
|
||||
mouseDelta = {currentMousePos.x-lastMousePos.x, currentMousePos.y-lastMousePos.y};
|
||||
|
||||
#ifdef CRAFTER_TIMING
|
||||
auto renderStart = std::chrono::high_resolution_clock::now();
|
||||
renderTimings.clear();
|
||||
|
|
@ -608,6 +610,8 @@ void Window::Update() {
|
|||
totalRender = renderEnd - renderStart;
|
||||
#endif
|
||||
|
||||
lastMousePos = currentMousePos;
|
||||
|
||||
#ifdef CRAFTER_TIMING
|
||||
frameEnd = std::chrono::high_resolution_clock::now();
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue