diff options
Diffstat (limited to 'src')
-rw-r--r-- | src/fps.c | 4 | ||||
-rw-r--r-- | src/fps.h | 4 | ||||
-rw-r--r-- | src/main.c | 2 |
3 files changed, 6 insertions, 4 deletions
@@ -36,7 +36,7 @@ int fps_setup(void) } -void fps_print(til_fb_t *fb) +void fps_fprint(til_fb_t *fb, FILE *out) { #ifdef __WIN32__ @@ -47,7 +47,7 @@ void fps_print(til_fb_t *fb) return; til_fb_get_put_pages_count(fb, &n); - printf("FPS: %u\n", n); + fprintf(out, "FPS: %u\n", n); print_fps = 0; #endif @@ -1,9 +1,11 @@ #ifndef _FPS_H #define _FPS_H +#include <stdio.h> + #include "til_fb.h" int fps_setup(void); -void fps_print(til_fb_t *fb); +void fps_fprint(til_fb_t *fb, FILE *out); #endif @@ -398,7 +398,7 @@ int main(int argc, const char *argv[]) if (til_fb_flip(rototiller.fb) < 0) break; - fps_print(rototiller.fb); + fps_fprint(rototiller.fb, stderr); } pthread_cancel(rototiller.thread); |