Skip to content
This repository was archived by the owner on Aug 16, 2021. It is now read-only.

Commit 6537fba

Browse files
author
lonelydevil
authored
Changed line count
Also changed max_frames(MAX_FRAMES_IN_FLIGHT in original tutorial) to 2 to get better performance.
1 parent 2cb9c5d commit 6537fba

File tree

1 file changed

+8
-8
lines changed

1 file changed

+8
-8
lines changed

main.c

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -570,7 +570,7 @@ int main(int argc,char **argv){
570570
printf("render pass created.\n");
571571
//
572572
//
573-
//pipeline creation part line_573 to line_931
573+
//pipeline creation part line_573 to line_933
574574
//
575575
//load shader
576576
//
@@ -931,7 +931,7 @@ int main(int argc,char **argv){
931931
printf("vertex shader binaries released.\n");
932932
//
933933
//
934-
//framebuffer creation line_932 to line_963
934+
//framebuffer creation line_934 to line_965
935935
//
936936
//create framebuffer
937937
//
@@ -963,7 +963,7 @@ int main(int argc,char **argv){
963963
}
964964
//
965965
//
966-
//command buffer creation line_964 to line_997
966+
//command buffer creation line_966 to line_999
967967
//
968968
//create command pool
969969
//
@@ -997,7 +997,7 @@ int main(int argc,char **argv){
997997
printf("command buffers allocated.\n");
998998
//
999999
//
1000-
//render preparation line998 to line1058
1000+
//render preparation line1000 to line1060
10011001
//
10021002
VkCommandBufferBeginInfo
10031003
cmd_buff_begin_infos[swap_image_count];
@@ -1058,9 +1058,9 @@ int main(int argc,char **argv){
10581058
}
10591059
//
10601060
//
1061-
//semaphores and fences creation part line_1059 to line_1099
1061+
//semaphores and fences creation part line_1061 to line_1101
10621062
//
1063-
uint32_t max_frames=swap_image_count;
1063+
uint32_t max_frames=2;
10641064
VkSemaphore
10651065
semps_img_avl[max_frames];
10661066
VkSemaphore
@@ -1099,7 +1099,7 @@ int main(int argc,char **argv){
10991099
}
11001100
//
11011101
//
1102-
//main present part line_1100 to line_1193
1102+
//main present part line_1102 to line_1195
11031103
//
11041104
printf("\n");
11051105
while(!glfwWindowShouldClose(window)){
@@ -1193,7 +1193,7 @@ int main(int argc,char **argv){
11931193
printf("command buffers finished.\n");
11941194
//
11951195
//
1196-
//destroy everything line_1194 to line_1270
1196+
//destroy everything line_1196 to line_1272
11971197
//
11981198
//free command buffer
11991199
//

0 commit comments

Comments
 (0)