https://www.freedesktop.org/wiki/Software/PulseAudio/Documentation/User/Network/RTP/#howtolistentothepulseaudiortpstream
https://www.freedesktop.org/wiki/Software/PulseAudio/Documentation/User/Modules/
https://wiki.archlinux.org/title/PulseAudio/Examples#Using_RTP/UDP_instead_of_native-protocol-tcp
#linux or win 可用其他方法 https://www.cnblogs.com/marklove/p/14406649.html
ffmpeg -f pulse -i alsa_output.pci-0000_00_14.2.iec958-stereo.monitor -codec:a pcm_s16be -ac 2 -ar 48000 -f rtp rtp://192.168.2.103:1900
软件包
extra/pulseaudio-rtp 16.1-1 [已安装]
RTP and RAOP support for PulseAudio
/etc/pulse/default.pa #开机启动配置
pactl list | grep -A2 'monitor' #扫声音源
pactl load-module module-rtp-send source=linux声音源.monitor destination=手机ip port=端口 loop=1
#手动 启动加载 可看是否失败
#必须参数 format=s16be channels=2 rate=48000 对不上手机播放就会不太正常
pactl load-module module-null-sink sink_name=rtp format=s16be channels=2 rate=48000 sink_properties="device.description='RTP'"
pactl load-module module-rtp-send source=rtp.monitor destination=192.168.2.103 port=1900 loop=1
#切换到 rtp 桌面小喇叭自己选择比较好 随时切换 手机 or 喇叭 播放
pactl set-default-sink rtp
手机apk
https://f-droid.org/zh_Hans/packages/me.wenxinwang.pulsedroidrtp/
源码
https://github.com/dront78/PulseDroid
https://github.com/wenxin-wang/PulseDroidRtp/