olivebot/test/testpyaudio.py
xszyou c99ee0cc5a 今天星期三
+ 修复连接数字人之前产生大量ws信息问题;
+ 增加数字人(ue、live2d、xuniren)通讯接口:实时日志;
+ 更新数字人(ue、live2d、xuniren)通讯接口:音频推送。
2023-07-26 18:11:52 +08:00

6 lines
197 B
Python

import pyaudio
audio = pyaudio.PyAudio()
for i in range(audio.get_device_count()):
devInfo = audio.get_device_info_by_index(i)
if devInfo['hostApi'] == 0:
print(devInfo)