PipeWire 0.3.77
Loading...
Searching...
No Matches
spa_io_clock Struct Reference

Absolute time reporting. More...

#include <spa/node/io.h>

Data Fields

uint32_t flags
 clock flags More...
 
uint32_t id
 unique clock id, set by application More...
 
uint64_t nsec
 time in nanoseconds against monotonic clock More...
 
struct spa_fraction rate
 rate for position/duration/delay More...
 
uint64_t position
 current position More...
 
uint64_t duration
 duration of current cycle More...
 
int64_t delay
 delay between position and hardware, positive for capture, negative for playback More...
 
double rate_diff
 rate difference between clock and monotonic time More...
 
uint64_t next_nsec
 estimated next wakeup time in nanoseconds More...
 
struct spa_fraction target_rate
 target rate of next cycle More...
 
uint64_t target_duration
 target duration of next cycle More...
 
uint32_t target_seq
 seq counter. More...
 
uint32_t padding [3]
 

Detailed Description

Absolute time reporting.

Nodes that can report clocking information will receive this io block. The application sets the id. This is usually set as part of the position information but can also be set separately.

The clock counts the elapsed time according to the clock provider since the provider was last started.

Field Documentation

◆ flags

uint32_t spa_io_clock::flags

clock flags

◆ id

uint32_t spa_io_clock::id

unique clock id, set by application

◆ nsec

uint64_t spa_io_clock::nsec

time in nanoseconds against monotonic clock

◆ rate

struct spa_fraction spa_io_clock::rate

rate for position/duration/delay

◆ position

uint64_t spa_io_clock::position

current position

◆ duration

uint64_t spa_io_clock::duration

duration of current cycle

Examples
audio-dsp-filter.c, and audio-dsp-src.c.

◆ delay

int64_t spa_io_clock::delay

delay between position and hardware, positive for capture, negative for playback

◆ rate_diff

double spa_io_clock::rate_diff

rate difference between clock and monotonic time

◆ next_nsec

uint64_t spa_io_clock::next_nsec

estimated next wakeup time in nanoseconds

◆ target_rate

struct spa_fraction spa_io_clock::target_rate

target rate of next cycle

◆ target_duration

uint64_t spa_io_clock::target_duration

target duration of next cycle

◆ target_seq

uint32_t spa_io_clock::target_seq

seq counter.

must be equal at start and end of read and lower bit must be 0

◆ padding

uint32_t spa_io_clock::padding[3]

The documentation for this struct was generated from the following file: