mirror of
https://gitlab.freedesktop.org/pipewire/pipewire.git
synced 2025-11-05 13:30:02 -05:00
node: Add ParamBegin/End
Use these commands to mark the begin and end of a series of Param enumerations and configuration, like when doing format negotiation. The idea is that the device can remain open while we do this. Use this in adapter when negotiating a format.
This commit is contained in:
parent
ccfe439786
commit
4e7be858e4
8 changed files with 55 additions and 10 deletions
|
|
@ -33,14 +33,22 @@ extern "C" {
|
|||
|
||||
/* object id of SPA_TYPE_COMMAND_Node */
|
||||
enum spa_node_command {
|
||||
SPA_NODE_COMMAND_Suspend,
|
||||
SPA_NODE_COMMAND_Pause,
|
||||
SPA_NODE_COMMAND_Start,
|
||||
SPA_NODE_COMMAND_Suspend, /**< suspend a node, this removes all configured
|
||||
* formats and closes any devices */
|
||||
SPA_NODE_COMMAND_Pause, /**< pause a node. this makes it stop emiting
|
||||
* scheduling events */
|
||||
SPA_NODE_COMMAND_Start, /**< start a node, this makes it start emiting
|
||||
* scheduling events */
|
||||
SPA_NODE_COMMAND_Enable,
|
||||
SPA_NODE_COMMAND_Disable,
|
||||
SPA_NODE_COMMAND_Flush,
|
||||
SPA_NODE_COMMAND_Drain,
|
||||
SPA_NODE_COMMAND_Marker,
|
||||
SPA_NODE_COMMAND_ParamBegin, /**< begin a set of parameter enumerations or
|
||||
* configuration that require the device to
|
||||
* remain opened, like query formats and then
|
||||
* set a format */
|
||||
SPA_NODE_COMMAND_ParamEnd, /**< end a transaction */
|
||||
};
|
||||
|
||||
#define SPA_NODE_COMMAND_ID(cmd) SPA_COMMAND_ID(cmd, SPA_TYPE_COMMAND_Node)
|
||||
|
|
|
|||
|
|
@ -79,6 +79,8 @@ static const struct spa_type_info spa_type_node_command_id[] = {
|
|||
{ SPA_NODE_COMMAND_Flush, SPA_TYPE_Int, SPA_TYPE_INFO_NODE_COMMAND_BASE "Flush", NULL },
|
||||
{ SPA_NODE_COMMAND_Drain, SPA_TYPE_Int, SPA_TYPE_INFO_NODE_COMMAND_BASE "Drain", NULL },
|
||||
{ SPA_NODE_COMMAND_Marker, SPA_TYPE_Int, SPA_TYPE_INFO_NODE_COMMAND_BASE "Marker", NULL },
|
||||
{ SPA_NODE_COMMAND_ParamBegin, SPA_TYPE_Int, SPA_TYPE_INFO_NODE_COMMAND_BASE "ParamBegin", NULL },
|
||||
{ SPA_NODE_COMMAND_ParamEnd, SPA_TYPE_Int, SPA_TYPE_INFO_NODE_COMMAND_BASE "ParamEnd", NULL },
|
||||
{ 0, 0, NULL, NULL },
|
||||
};
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue