File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -2,7 +2,7 @@ cmake_minimum_required(VERSION 3.30)
22project (LLRI2_Experiments)
33
44# Macro for the amount of frames to measure for.
5- add_compile_definitions (FRAME_NUMBERS=50000 )
5+ add_compile_definitions (FRAME_NUMBERS=20000 )
66
77# Libraries
88
Original file line number Diff line number Diff line change @@ -633,6 +633,8 @@ SDL_AppResult SDL_AppIterate(void* appstate) {
633633 return SDL_APP_FAILURE ;
634634 }
635635
636+ SDL_WaitForGPUIdle (myAppState->device );
637+
636638 std::chrono::high_resolution_clock::time_point endTime = std::chrono::high_resolution_clock::now ();
637639 std::chrono::duration<Uint32, std::nano> frameTime = endTime - startTime;
638640 myAppState->frameTimes [myAppState->frameNumber ] = frameTime.count ();
Original file line number Diff line number Diff line change @@ -954,6 +954,8 @@ SDL_AppResult VulkanEngine::Draw() {
954954 return SDL_APP_FAILURE ;
955955 }
956956
957+ vkDeviceWaitIdle (device);
958+
957959 const std::chrono::high_resolution_clock::time_point endTime = std::chrono::high_resolution_clock::now ();
958960 const std::chrono::duration<Uint32, std::nano> frameTime = endTime - startTime;
959961 frameTimes[frameNumber] = frameTime.count ();
You can’t perform that action at this time.
0 commit comments