TpBluetoothAudioDevice 类
V0.2.1TpExtUtils
2025-11-14
介绍
本机蓝牙连接蓝牙音频设备并播放音频
基础信息
| 头文件: | include <TpBluetoothAudioDevice.h> |
|---|---|
| Cmake: | None |
| 发布版本: | V0.2.1 |
| 继承类: | |
| 派生类: |
Public 类型
enum TpBluetoothAudioDevice::TpAudioProfileType
| 名称 | 值 | 描述 |
|---|---|---|
| TP_PROFILE_AUDIO_SOURCE | 0 | |
| TP_PROFILE_AUDIO_SINK | 1 | |
| TP_PROFILE_AUDIO_HEADSET | 2 |
Public 成员函数
| TpBluetoothAudioDevice(const TpString &local, const TpBluetoothDevice &other) | ||
|---|---|---|
| TpBluetoothAudioDevice(const TpString &local, const TpBluetoothAddress &address) | ||
| ~TpBluetoothAudioDevice() | ||
| connectToDevice() | 连接到蓝牙多媒体设备 | |
| disconnectDevice() | 和蓝牙多媒体设备断开连接 | |
| TpString | getDevice() | 获取连接的设备名 |
成员函数说明
TpBluetoothAudioDevice::TpBluetoothAudioDevice(const TpString &local, const TpBluetoothDevice &other)
暂无注释...
TpBluetoothAudioDevice::TpBluetoothAudioDevice(const TpString &local, const TpBluetoothAddress &address)
暂无注释...
TpBluetoothAudioDevice::~TpBluetoothAudioDevice()
暂无注释...
int TpBluetoothAudioDevice::connectToDevice()
连接到蓝牙多媒体设备...
连接到蓝牙多媒体设备
返回值:
int TpBluetoothAudioDevice::disconnectDevice()
和蓝牙多媒体设备断开连接...
和蓝牙多媒体设备断开连接
返回值:
TpString TpBluetoothAudioDevice::getDevice()
获取连接的设备名...
获取连接的设备名
返回值:
