In what scenario would I get no output to the console? #283
-
So I have 2 components:
|
Beta Was this translation helpful? Give feedback.
Replies: 1 comment 5 replies
-
At first glance, I would say the std::thread is posting events more quickly than what the screen can process. You probably send hundreds of millions of them per seconds, and the screen is processing only a few millions. The screen's loop implementation: FTXUI/src/ftxui/component/screen_interactive.cpp Lines 421 to 448 in 7e5cd23 Works by:
In your example, we stay at step (1) forever, resulting in drawing the at 0 fps. You probably need to replace using namespace std::chrono_literals;
std::this_thread::sleep_for(0.05s); |
Beta Was this translation helpful? Give feedback.
At first glance, I would say the std::thread is posting events more quickly than what the screen can process. You probably send hundreds of millions of them per seconds, and the screen is processing only a few millions.
The screen's loop implementation:
FTXUI/src/ftxui/component/screen_interactive.cpp
Lines 421 to 448 in 7e5cd23