mirror of
https://github.com/outbackdingo/UltraGrid.git
synced 2026-03-21 22:40:30 +00:00
moved FPS indicator prefix trailing ' ' trim
moved to video_capture.cpp - it is a bit technical and it is nicer to have it there than in the huge main.cpp
This commit is contained in:
@@ -318,10 +318,8 @@ static void *capture_thread(void *arg)
|
||||
struct wait_obj *wait_obj = wait_obj_init();
|
||||
steady_clock::time_point t0 = steady_clock::now();
|
||||
int frames = 0;
|
||||
char *print_fps_prefix = vidcap_get_fps_print_prefix(uv->capture_device) ? strdupa(vidcap_get_fps_print_prefix(uv->capture_device)) : NULL;
|
||||
if (print_fps_prefix && print_fps_prefix[strlen(print_fps_prefix) - 1] == ' ') { // trim trailing ' '
|
||||
print_fps_prefix[strlen(print_fps_prefix) - 1] = '\0';
|
||||
}
|
||||
const char *print_fps_prefix =
|
||||
vidcap_get_fps_print_prefix(uv->capture_device);
|
||||
|
||||
while (!uv->should_exit_capture) {
|
||||
/* Capture and transmit video... */
|
||||
|
||||
Reference in New Issue
Block a user