RDK Resources
[*RDK Preferred*]
Code Management Facility
RDK Forums
[RDK Conferences]
RDK Support
Archives
Papers & Presentations Archive
Prototype :
void pw_init(int *argc, char **argv[])
Parameter :
argc - Pointer to argc
argv - Ponter to argv
Return Val :
Void
Description :
It will initialize Pipewire system,parse and modify any parameters given by argc and argv.
This will load and configure the right modules and setup logging and other tasks.
Debug environment variable : export PIPEWIRE_DEBUG
Prototype :
struct pw_main_loop *pw_main_loop_new(const struct spa_dict *props)
Parameter :
props - Pointer to properties of spa dictionary
Return Val :
It will return newly allocated mail loop pointer
Description :
The mainloop is an abstraction of a big poll loop, waiting for events to occur and things to do. Most of the PipeWire work will actually be performed in the context of this loop.
Prototype :
struct pw_stream* pw_stream_new_simple ( struct pw_loop * loop,
const char * name,
struct pw_properties * props,
const struct pw_stream_events * events,
void * data
)
Parameter :
loop - a Loop to use
name - a stream media name
props - stream properties, ownership is taken
events - stream events
data - data passed to events
Return Val :
This will return a created stream object
Description :
This will create a stream object with different properties to make it a Camera Video Capture stream
Prototype :
int pw_stream_connect ( struct pw_stream * stream,
enum pw_direction direction,
uint32_t target_id,
enum pw_stream_flags flags,
const struct spa_pod ** params,
uint32_t n_params
)
Parameter :
stream - a Stream
direction - the stream direction
target_id - the target object id to connect to or PW_ID_ANY to let the manager select a target.
flags - stream flags
params - an array with params. The params should ideally contain supported formats.
n_params - number of items in params
Return Val :
If will return success or failure of stream connect
0 - Success <0 - Error
Description :
It will start to connect the stream, You should connect to the process event and use pw_stream_dequeue_buffer() to get the latest metadata and data.