egnor / pivid

Experimental video code for Linux / Raspberry Pi
MIT License
28 stars 4 forks source link

Avoid blacking out missed frames #11

Open egnor opened 2 years ago

egnor commented 2 years ago

Currently, when pivid overruns a media load buffer, the layer in question goes black for any affected frames.

It would be better to just show the last displayed frame, or the nearest loaded frame, or something like that which would be much less jarring. (Maybe there could be a debug mode where the layer flashes red to make the frame-drop extra obvious for performance tuning.)

This may require a bit of subtlety because currently the script runner and media loader is very eager to drop frames which are "in the past" even if the future frames aren't loaded yet, so it may need some adjustment to keep one around for this purpose.

cc: @aubilenon