Move fps_counter to screen

The FPS counter specifically count frames from the screen video buffer,
so it is specific to the screen.
This commit is contained in:
Romain Vimont
2021-05-16 18:26:20 +02:00
parent f19c455110
commit e604e8a752
6 changed files with 48 additions and 34 deletions

View File

@@ -150,6 +150,10 @@ fps_counter_interrupt(struct fps_counter *counter) {
void
fps_counter_join(struct fps_counter *counter) {
if (counter->thread_started) {
// interrupted must be set by the thread calling join(), so no need to
// lock for the assertion
assert(counter->interrupted);
sc_thread_join(&counter->thread, NULL);
}
}