mirror of
https://gitlab.freedesktop.org/pipewire/pipewire.git
synced 2025-11-06 13:30:01 -05:00
port to new API
This commit is contained in:
parent
fcc9639479
commit
f06b991a5a
8 changed files with 201 additions and 149 deletions
|
|
@ -851,38 +851,6 @@ pinos_stream_connect (PinosStream *stream,
|
|||
return TRUE;
|
||||
}
|
||||
|
||||
static void
|
||||
on_ringbuffer (GObject *source_object,
|
||||
GAsyncResult *res,
|
||||
gpointer user_data)
|
||||
{
|
||||
PinosStream *stream = user_data;
|
||||
PinosStreamPrivate *priv = stream->priv;
|
||||
GError *error = NULL;
|
||||
|
||||
g_assert (priv->port == PINOS_PORT (source_object));
|
||||
|
||||
priv->ringbuffer = pinos_port_get_ringbuffer_finish (priv->port,
|
||||
res,
|
||||
&error);
|
||||
if (priv->ringbuffer == NULL)
|
||||
goto no_ringbuffer;
|
||||
|
||||
stream_set_state (stream, PINOS_STREAM_STATE_STREAMING, NULL);
|
||||
g_object_unref (stream);
|
||||
|
||||
return;
|
||||
|
||||
/* ERRORS */
|
||||
no_ringbuffer:
|
||||
{
|
||||
g_warning ("failed to get ringbuffer: %s", error->message);
|
||||
stream_set_state (stream, PINOS_STREAM_STATE_ERROR, error);
|
||||
g_object_unref (stream);
|
||||
return;
|
||||
}
|
||||
}
|
||||
|
||||
static gboolean
|
||||
do_start (PinosStream *stream)
|
||||
{
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue