io: add support for segment

Move fields from the io_position to io_segment. The segment contains
the mapping between raw clock time and stream time in various
formats. We keep an array of pending segments available in the
io_position field so clients can anticipate changes.

Make looping a flag in the segment instead of a state.

Prepare for segment masters. These will be registered clients that
are responsible for updating parts of the extended segment info.

Add namespace to some defines.
This commit is contained in:
Wim Taymans 2019-08-27 21:36:15 +02:00
parent b356c83d32
commit 7c865f5db0
7 changed files with 137 additions and 80 deletions

View file

@ -880,7 +880,7 @@ static int impl_node_process(void *object)
spa_log_trace_fp(this->log, "%p: send process driver:%p", this, impl->this.node->driver_node);
spa_system_clock_gettime(this->data_system, CLOCK_MONOTONIC, &ts);
n->rt.activation->status = TRIGGERED;
n->rt.activation->status = PW_NODE_ACTIVATION_TRIGGERED;
n->rt.activation->signal_time = SPA_TIMESPEC_TO_NSEC(&ts);
if (spa_system_eventfd_write(this->data_system, this->writefd, 1) < 0)