Commit d18ed58e authored by Wim Taymans's avatar Wim Taymans

Some more random thoughts

Original commit message from CVS:
Some more random thoughts
parent f330cdb8
The clock
The clock always returns reference time
Element State change
Each element receives the current clock reference time
in the state change function.
An element starts sending buffers with timestamp
reftime + internal counter
After a seek, the element sets internal counters to 0
Bin state change
bin propagates clock time to children
Toplevel bin state change
start time is set to ref time
stream time is thus 0
start time is sent to state change of children
use case 1
filesrc ! mad ! osssink
pipeline PAUSED to PLAYING:
start time = ref time
filesrc state change gets starttime
mad state change gets starttime
osssink state change gets starttime
mad sends buffers with timestamp starttime + internal counter
osssink syncs these samples against the clock with starttime + timestamp
nothing happens
use case 2
{ filesrc ! mad ! queue } ! osssink
let it play for a while
PAUSE the thread
PLAY the thread
thread is not the toplevel bin, use same starttime as when
it first started.
do state change on elements with same starttime
use case 3
filesrc ! mad ! mixer ! osssink
filesrc ! mad !-^
blocking wait
- allocate a new clock entry
- add to list of pending sync waits
- do {
wait on entry
} while (entry != restart)
- free entry/remove from list
async wait
- if no thread, start thread
- alloc a new clock entry
- add to list of pending async waits
- signal thread to restart timeouts
async thread
while (true) {
if (no entry) wait for restart
do {
take first entry
wait on it
} while (entry != restart)
call entry signal function
free entry/remove from list
clock adjust
- loop over sync/async entries
- restart all entries
Required functionality
- get notification of data passing on arbitrary pad
- posibility to drop data
- posibility to change/inspect data
- single shot probe
- filter on events/buffers?
- filter on timestamp?
- filter on types of events?
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment