-
Notifications
You must be signed in to change notification settings - Fork 332
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
stdout slow when piped #112
Comments
stdout is line buffered. |
Dont know what do you want to do but maybe this works for you:
|
Thank you both for your fast response! My intention was to spawn omxplayer from nodejs, channel commands to its stdin and read from its output to fetch the current status*. (Maybe a duplicate of #10 ?) @popcornmix 4K seems quite right; cat's output (using Any idea how to go about this, as the 4K-buffer flushes come to infrequent? Thanks again for your time, I am very grateful for the effort you put into omxplayer! *) I looked into following the logfile, but I cannot use that in its current state, as the logfile grows quite fast, and it is hardcoded to go into a newly created ./omxplayer.log file. Maybe I should file an issue for this? |
I think this is another instance where connecting to omxplayer through dbus is the best solution. You should be able to control omxplayer and read back status using that interface. |
Okay, I'll look into that. Thanks. |
When playing a video from the console with the
--stats
parameter, omxplayer sends its status information quite frequently (around 4 to 5 times a second). However, when issueing the same command but to be piped (to a file or named pipe), the intervals between status outputs become rather large (about 6 seconds).Also, time to first output (except for the clear-screen) increases significantly (from around 2 to 8 seconds).
Testcase:
The text was updated successfully, but these errors were encountered: