mirror of
https://gitlab.freedesktop.org/pulseaudio/pulseaudio.git
synced 2025-11-06 13:29:56 -05:00
bluetooth: Register an endpoint according to encode or decode support
As we now support codecs other than SBC, we might have codec which does not have an encode or a decode capability. Specifically, in the case of LDAC there isn't a known decoder implementation available. For such a case, we should not register the corresponding endpoint. In case of LDAC, as decoding cannot be supported, we should not register a sink endpoint or vice versa in the other scenario. To do this, we check if encode_buffer or decode_buffer entry for a codec has been set in pa_a2dp_codec and accordingly prevent or allow it's registration. Part-of: <https://gitlab.freedesktop.org/pulseaudio/pulseaudio/-/merge_requests/440>
This commit is contained in:
parent
366bd5615c
commit
ed44fa1856
3 changed files with 54 additions and 20 deletions
|
|
@ -31,6 +31,9 @@ const pa_a2dp_codec *pa_bluetooth_a2dp_codec_iter(unsigned int i);
|
|||
/* Get codec by name */
|
||||
const pa_a2dp_codec *pa_bluetooth_get_a2dp_codec(const char *name);
|
||||
|
||||
/* Check if the given codec can be supported in A2DP_SINK or A2DP_SOURCE */
|
||||
bool pa_bluetooth_a2dp_codec_is_codec_available(const pa_a2dp_codec_id *id, bool is_a2dp_sink);
|
||||
|
||||
/* Initialise GStreamer */
|
||||
void pa_bluetooth_a2dp_codec_gst_init(void);
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue