Struct pipewire_sys::pw_client_node_events
source · #[repr(C)]pub struct pw_client_node_events {Show 13 fields
pub version: u32,
pub transport: Option<unsafe extern "C" fn(data: *mut c_void, readfd: c_int, writefd: c_int, mem_id: u32, offset: u32, size: u32) -> c_int>,
pub set_param: Option<unsafe extern "C" fn(data: *mut c_void, id: u32, flags: u32, param: *const spa_pod) -> c_int>,
pub set_io: Option<unsafe extern "C" fn(data: *mut c_void, id: u32, mem_id: u32, offset: u32, size: u32) -> c_int>,
pub event: Option<unsafe extern "C" fn(data: *mut c_void, event: *const spa_event) -> c_int>,
pub command: Option<unsafe extern "C" fn(data: *mut c_void, command: *const spa_command) -> c_int>,
pub add_port: Option<unsafe extern "C" fn(data: *mut c_void, direction: spa_direction, port_id: u32, props: *const spa_dict) -> c_int>,
pub remove_port: Option<unsafe extern "C" fn(data: *mut c_void, direction: spa_direction, port_id: u32) -> c_int>,
pub port_set_param: Option<unsafe extern "C" fn(data: *mut c_void, direction: spa_direction, port_id: u32, id: u32, flags: u32, param: *const spa_pod) -> c_int>,
pub port_use_buffers: Option<unsafe extern "C" fn(data: *mut c_void, direction: spa_direction, port_id: u32, mix_id: u32, flags: u32, n_buffers: u32, buffers: *mut pw_client_node_buffer) -> c_int>,
pub port_set_io: Option<unsafe extern "C" fn(data: *mut c_void, direction: spa_direction, port_id: u32, mix_id: u32, id: u32, mem_id: u32, offset: u32, size: u32) -> c_int>,
pub set_activation: Option<unsafe extern "C" fn(data: *mut c_void, node_id: u32, signalfd: c_int, mem_id: u32, offset: u32, size: u32) -> c_int>,
pub port_set_mix_info: Option<unsafe extern "C" fn(data: *mut c_void, direction: spa_direction, port_id: u32, mix_id: u32, peer_id: u32, props: *const spa_dict) -> c_int>,
}
Expand description
\ref pw_client_node events
Fields§
§version: u32
§transport: Option<unsafe extern "C" fn(data: *mut c_void, readfd: c_int, writefd: c_int, mem_id: u32, offset: u32, size: u32) -> c_int>
Notify of a new transport area
The transport area is used to signal the client and the server.
\param readfd fd for signal data can be read \param writefd fd for signal data can be written \param mem_id id for activation memory \param offset offset of activation memory \param size size of activation memory
set_param: Option<unsafe extern "C" fn(data: *mut c_void, id: u32, flags: u32, param: *const spa_pod) -> c_int>
Notify of a property change
When the server configures the properties on the node this event is sent
\param id the id of the parameter \param flags parameter flags \param param the param to set
set_io: Option<unsafe extern "C" fn(data: *mut c_void, id: u32, mem_id: u32, offset: u32, size: u32) -> c_int>
Configure an IO area for the client
IO areas are identified with an id and are used to exchange state between client and server
\param id the id of the io area \param mem_id the id of the memory to use \param offset offset of io area in memory \param size size of the io area
event: Option<unsafe extern "C" fn(data: *mut c_void, event: *const spa_event) -> c_int>
Receive an event from the client node \param event the received event
command: Option<unsafe extern "C" fn(data: *mut c_void, command: *const spa_command) -> c_int>
Notify of a new node command
\param command the command
add_port: Option<unsafe extern "C" fn(data: *mut c_void, direction: spa_direction, port_id: u32, props: *const spa_dict) -> c_int>
A new port was added to the node
The server can at any time add a port to the node when there are free ports available.
\param direction the direction of the port \param port_id the new port id \param props extra properties
remove_port: Option<unsafe extern "C" fn(data: *mut c_void, direction: spa_direction, port_id: u32) -> c_int>
A port was removed from the node
\param direction a port direction \param port_id the remove port id
port_set_param: Option<unsafe extern "C" fn(data: *mut c_void, direction: spa_direction, port_id: u32, id: u32, flags: u32, param: *const spa_pod) -> c_int>
A parameter was configured on the port
\param direction a port direction \param port_id the port id \param id the id of the parameter \param flags flags used when setting the param \param param the new param
port_use_buffers: Option<unsafe extern "C" fn(data: *mut c_void, direction: spa_direction, port_id: u32, mix_id: u32, flags: u32, n_buffers: u32, buffers: *mut pw_client_node_buffer) -> c_int>
Notify the port of buffers
\param direction a port direction \param port_id the port id \param mix_id the mixer port id \param n_buffer the number of buffers \param buffers and array of buffer descriptions
port_set_io: Option<unsafe extern "C" fn(data: *mut c_void, direction: spa_direction, port_id: u32, mix_id: u32, id: u32, mem_id: u32, offset: u32, size: u32) -> c_int>
Configure the io area with \a id of \a port_id.
\param direction the direction of the port \param port_id the port id \param mix_id the mixer port id \param id the id of the io area to set \param mem_id the id of the memory to use \param offset offset of io area in memory \param size size of the io area
set_activation: Option<unsafe extern "C" fn(data: *mut c_void, node_id: u32, signalfd: c_int, mem_id: u32, offset: u32, size: u32) -> c_int>
Notify the activation record of the next node to trigger
\param node_id the peer node id \param signalfd the fd to wake up the peer \param mem_id the mem id of the memory \param the offset in \a mem_id to map \param the size of \a mem_id to map
port_set_mix_info: Option<unsafe extern "C" fn(data: *mut c_void, direction: spa_direction, port_id: u32, mix_id: u32, peer_id: u32, props: *const spa_dict) -> c_int>
Notify about the peer of mix_id
\param direction the direction of the port \param port_id the port id \param mix_id the mix id \param peer_id the id of the peer port \param props extra properties
Since version 4:1
Trait Implementations§
source§impl Clone for pw_client_node_events
impl Clone for pw_client_node_events
source§fn clone(&self) -> pw_client_node_events
fn clone(&self) -> pw_client_node_events
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source
. Read more