summaryrefslogtreecommitdiff
path: root/main.c
diff options
context:
space:
mode:
authorpommicket <pommicket@gmail.com>2023-07-18 13:59:44 -0400
committerpommicket <pommicket@gmail.com>2023-07-19 19:02:27 -0400
commitbe5dab846e38420961a68ff4503a48e2bd8bdf6b (patch)
tree351daf84a8ffdc93939edf554d51a6d90f22ffbc /main.c
parent533345302e16ff8b485cc719d6bf8c1f5d043445 (diff)
multiple font textuers
Diffstat (limited to 'main.c')
-rw-r--r--main.c15
1 files changed, 6 insertions, 9 deletions
diff --git a/main.c b/main.c
index 371ddee..526eeb2 100644
--- a/main.c
+++ b/main.c
@@ -47,6 +47,10 @@ FUTURE FEATURES:
#define ONE_SOURCE 1
#endif
+#if PROFILE
+ #define PROFILE_FRAME 1
+#endif
+
#if ONE_SOURCE
#include "util.c"
@@ -88,13 +92,6 @@ FUTURE FEATURES:
#endif // ONE_SOURCE
-#if PROFILE
-#define PROFILE_TIME(var) double var = time_get_seconds();
-#else
-#define PROFILE_TIME(var)
-#endif
-
-
static Rect message_box_rect(Ted *ted) {
Font *font = ted->font;
const Settings *settings = ted_active_settings(ted);
@@ -1121,7 +1118,7 @@ int main(int argc, char **argv) {
#endif
double frame_end_noswap = time_get_seconds();
- #if PROFILE
+ #if PROFILE_FRAME
{
print("Frame (noswap): %.1f ms\n", (frame_end_noswap - frame_start) * 1000);
}
@@ -1164,7 +1161,7 @@ int main(int argc, char **argv) {
assert(glGetError() == 0);
- #if PROFILE
+ #if PROFILE_FRAME
{
print("Frame: %.1f ms\n", (frame_end - frame_start) * 1000);
}