mirror of
https://gitlab.freedesktop.org/pipewire/pipewire.git
synced 2025-12-16 08:56:45 -05:00
bluez5: Create backend for native HSP support
This commit is contained in:
parent
7711c98123
commit
06a6e11806
4 changed files with 714 additions and 609 deletions
|
|
@ -161,6 +161,7 @@ static inline const char *spa_bt_profile_name (enum spa_bt_profile profile) {
|
|||
}
|
||||
|
||||
struct spa_bt_monitor;
|
||||
struct spa_bt_backend;
|
||||
|
||||
struct spa_bt_adapter {
|
||||
struct spa_list link;
|
||||
|
|
@ -199,6 +200,10 @@ struct spa_bt_device {
|
|||
bool added;
|
||||
};
|
||||
|
||||
struct spa_bt_device *spa_bt_device_find(struct spa_bt_monitor *monitor, const char *path);
|
||||
int spa_bt_device_connect_profile(struct spa_bt_device *device, enum spa_bt_profile profile);
|
||||
int spa_bt_device_check_profiles(struct spa_bt_device *device, bool force);
|
||||
|
||||
enum spa_bt_transport_state {
|
||||
SPA_BT_TRANSPORT_STATE_IDLE,
|
||||
SPA_BT_TRANSPORT_STATE_PENDING,
|
||||
|
|
@ -226,6 +231,7 @@ struct spa_bt_transport_implementation {
|
|||
struct spa_bt_transport {
|
||||
struct spa_list link;
|
||||
struct spa_bt_monitor *monitor;
|
||||
struct spa_bt_backend *backend;
|
||||
char *path;
|
||||
struct spa_bt_device *device;
|
||||
struct spa_list device_link;
|
||||
|
|
@ -245,6 +251,9 @@ struct spa_bt_transport {
|
|||
struct spa_callbacks impl;
|
||||
};
|
||||
|
||||
struct spa_bt_transport *spa_bt_transport_create(struct spa_bt_monitor *monitor, char *path, size_t extra);
|
||||
void spa_bt_transport_free(struct spa_bt_transport *transport);
|
||||
|
||||
#define spa_bt_transport_emit(t,m,v,...) spa_hook_list_call(&(t)->listener_list, \
|
||||
struct spa_bt_transport_events, \
|
||||
m, v, ##__VA_ARGS__)
|
||||
|
|
@ -283,6 +292,12 @@ static inline enum spa_bt_transport_state spa_bt_transport_state_from_string(con
|
|||
}
|
||||
|
||||
|
||||
struct spa_bt_backend *backend_hsp_native_new(struct spa_bt_monitor *monitor,
|
||||
const struct spa_support *support,
|
||||
uint32_t n_support);
|
||||
void backend_hsp_native_free(struct spa_bt_backend *backend);
|
||||
void backend_hsp_native_register_profiles(struct spa_bt_backend *backend);
|
||||
|
||||
#ifdef __cplusplus
|
||||
} /* extern "C" */
|
||||
#endif
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue