Browse Source

Removed pointless profiling of displaying the canvas. (Runs on background thread)

David Piuva 5 years ago
parent
commit
431b67450f
3 changed files with 1 additions and 7 deletions
  1. 0 2
      Source/SDK/cube/main.cpp
  2. 1 3
      Source/SDK/sandbox/sandbox.cpp
  3. 0 2
      Source/SDK/terrain/main.cpp

+ 0 - 2
Source/SDK/cube/main.cpp

@@ -161,9 +161,7 @@ int main(int argn, char **argv) {
 		window_drawComponents(window);
 		window_drawComponents(window);
 		printText("Draw GUI: ", (time_getSeconds() - startTime) * 1000.0, " ms\n");
 		printText("Draw GUI: ", (time_getSeconds() - startTime) * 1000.0, " ms\n");
 
 
-		startTime = time_getSeconds();
 		window_showCanvas(window);
 		window_showCanvas(window);
-		printText("Show canvas: ", (time_getSeconds() - startTime) * 1000.0, " ms\n");
 	}
 	}
 }
 }
 
 

+ 1 - 3
Source/SDK/sandbox/sandbox.cpp

@@ -413,9 +413,7 @@ void sandbox_main() {
 			font_printLine(colorBuffer, font_getDefault(), string_combine(U"max ms: ", 1000.0f * lastMaxFrameTime), writer, ColorRgbaI32(255, 255, 255, 255)); writer.y += 20;
 			font_printLine(colorBuffer, font_getDefault(), string_combine(U"max ms: ", 1000.0f * lastMaxFrameTime), writer, ColorRgbaI32(255, 255, 255, 255)); writer.y += 20;
 		}
 		}
 
 
-		startTime = time_getSeconds();
-			window_showCanvas(window);
-		debugText("Show canvas: ", (time_getSeconds() - startTime) * 1000.0, " ms\n");
+		window_showCanvas(window);
 
 
 		double newTime = time_getSeconds();
 		double newTime = time_getSeconds();
 		secondsPerFrame = newTime - frameStartTime;
 		secondsPerFrame = newTime - frameStartTime;

+ 0 - 2
Source/SDK/terrain/main.cpp

@@ -426,9 +426,7 @@ int main(int argn, char **argv) {
 			printText("Show buffers: ", (time_getSeconds() - startTime) * 1000.0, " ms\n");
 			printText("Show buffers: ", (time_getSeconds() - startTime) * 1000.0, " ms\n");
 		}
 		}
 
 
-		startTime = time_getSeconds();
 		window_showCanvas(window);
 		window_showCanvas(window);
-		printText("Show canvas: ", (time_getSeconds() - startTime) * 1000.0, " ms\n\n");
 	}
 	}
 
 
 	printText("\nTerminating the application.\n");
 	printText("\nTerminating the application.\n");