fixed windows lastframebegin
This commit is contained in:
parent
b52e8bd236
commit
9b36583e49
2 changed files with 12 additions and 0 deletions
|
|
@ -530,6 +530,9 @@ void WindowVulkan::SetTitle(const std::string_view title) {
|
|||
|
||||
}
|
||||
|
||||
#ifdef CRAFTER_TIMING
|
||||
std::chrono::time_point<std::chrono::high_resolution_clock> framEnd;
|
||||
#endif
|
||||
|
||||
void WindowVulkan::StartUpdate() {
|
||||
lastFrameBegin = std::chrono::high_resolution_clock::now();
|
||||
|
|
@ -545,6 +548,7 @@ void WindowVulkan::StartUpdate() {
|
|||
Render();
|
||||
lastMousePos = currentMousePos;
|
||||
currentFrameTime = {start, start-lastFrameBegin};
|
||||
lastFrameBegin = start;
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -115,6 +115,14 @@
|
|||
"target": "x86_64-w64-mingw32",
|
||||
"march": "x86-64"
|
||||
},
|
||||
{
|
||||
"name": "lib-vulkan-windows-timing",
|
||||
"extends": ["vulkan-windows", "deps-timing"],
|
||||
"type": "library",
|
||||
"target": "x86_64-w64-mingw32",
|
||||
"march": "x86-64",
|
||||
"defines": [{ "name": "CRAFTER_TIMING" }]
|
||||
},
|
||||
{
|
||||
"name": "lib-vulkan-timing",
|
||||
"extends": ["vulkan", "deps-timing"],
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue