mirror of
https://gitlab.freedesktop.org/pipewire/wireplumber.git
synced 2025-12-24 22:30:03 +01:00
Running audioconvert in merge+split mode is the only way to make this work with the adapter, since the adapter does not support passing multiple channels on a single port right now, and if it does at some point, it will be without a mixing node on the port, which means we will not be able to mix multiple audioconvert nodes on the same adapter. In the future we need to consider writing a lighter volume node with multiple channels support to replace audioconvert. The new linking algorithm now takes into account the channel positions and makes sure to link the correct channels together. Also, it avoids passing the port proxies inside the GVariants, thus making the algorithm a bit more generic and easier to unit test.
32 lines
769 B
C
32 lines
769 B
C
/* WirePlumber
|
|
*
|
|
* Copyright © 2019 Collabora Ltd.
|
|
* @author Julian Bouzas <julian.bouzas@collabora.com>
|
|
*
|
|
* SPDX-License-Identifier: MIT
|
|
*/
|
|
|
|
#ifndef __WIREPLUMBER_AUDIO_CONVERT_H__
|
|
#define __WIREPLUMBER_AUDIO_CONVERT_H__
|
|
|
|
#include <gio/gio.h>
|
|
#include <wp/wp.h>
|
|
|
|
#include "stream.h"
|
|
|
|
G_BEGIN_DECLS
|
|
|
|
struct spa_audio_info_raw format;
|
|
|
|
#define WP_TYPE_AUDIO_CONVERT (wp_audio_convert_get_type ())
|
|
G_DECLARE_FINAL_TYPE (WpAudioConvert, wp_audio_convert, WP, AUDIO_CONVERT,
|
|
WpAudioStream)
|
|
|
|
void wp_audio_convert_new (WpEndpoint *endpoint, guint stream_id,
|
|
const char *stream_name, enum pw_direction direction,
|
|
WpAudioStream *target, const struct spa_audio_info_raw *format,
|
|
GAsyncReadyCallback callback, gpointer user_data);
|
|
|
|
G_END_DECLS
|
|
|
|
#endif
|