#[repr(C)]pub struct spa_io_position {
pub clock: spa_io_clock,
pub video: spa_io_video_size,
pub offset: i64,
pub state: u32,
pub n_segments: u32,
pub segments: [spa_io_segment; 8],
}
Expand description
The position information adds extra meaning to the raw clock times.
It is set on all nodes in \ref SPA_IO_Position, and the contents of \ref spa_io_position.clock contain the clock updates made by the driving node in the graph in its \ref SPA_IO_Clock. Also, \ref spa_io_position.clock.id will contain the clock id of the driving node in the graph.
The position clock indicates the logical start time of the current graph cycle.
The position information contains 1 or more segments that convert the raw clock times to a stream time. They are sorted based on their start times, and thus the order in which they will activate in the future. This makes it possible to look ahead in the scheduled segments and anticipate the changes in the timeline.
Fields§
§clock: spa_io_clock
< clock position of driver, always valid and read only
video: spa_io_video_size
< size of the video in the current cycle
offset: i64
< an offset to subtract from the clock position to get a running time. This is the time that the state has been in the RUNNING state and the time that should be used to compare the segment start values against.
state: u32
< one of enum spa_io_position_state
n_segments: u32
< number of segments
segments: [spa_io_segment; 8]
< segments
Trait Implementations§
Source§impl Clone for spa_io_position
impl Clone for spa_io_position
Source§fn clone(&self) -> spa_io_position
fn clone(&self) -> spa_io_position
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source
. Read more