Logo Search packages:      
Sourcecode: pulseaudio version File versions  Download package

int pa_stream_connect_playback ( pa_stream s,
const char *  dev,
const pa_buffer_attr attr,
pa_stream_flags_t  flags,
const pa_cvolume volume,
pa_stream sync_stream 
)

Connect the stream to a sink. It is strongly recommended to pass NULL in both dev and volume and not to set either PA_STREAM_START_MUTED nor PA_STREAM_START_UNMUTED -- unless these options are directly dependant on user input or configuration. If you follow this rule then the sound server will have the full flexibility to choose the device, volume and mute status automatically, based on server-side policies, heuristics and stored information from previous uses. Also the server may choose to reconfigure audio devices to make other sinks/sources or capabilities available to be able to accept the stream. Before 0.9.20 it was not defined whether the 'volume' parameter was interpreted relative to the sink's current volume or treated as absolute device volume. Since 0.9.20 it is an absolute volume when the sink is in flat volume mode, and relative otherwise, thus making sure the volume passed here has always the same semantics as the volume passed to pa_context_set_sink_input_volume().

Parameters:
s  The stream to connect to a sink
dev  Name of the sink to connect to, or NULL for default
attr  Buffering attributes, or NULL for default
flags  Additional flags, or 0 for default
volume  Initial volume, or NULL for default
sync_stream  Synchronize this stream with the specified one, or NULL for a standalone stream

Definition at line 1210 of file stream.c.

References PA_STREAM_PLAYBACK.

                                {

    pa_assert(s);
    pa_assert(PA_REFCNT_VALUE(s) >= 1);

    return create_stream(PA_STREAM_PLAYBACK, s, dev, attr, flags, volume, sync_stream);
}


Generated by  Doxygen 1.6.0   Back to index