Hi,
I'm working on something very similar. It basically works exactly as Lorenzo described. You can tell the AudioBridge to forward the audio from the conference room to your machine using a json message like this:
{"request": "rtp_forward",
"room": roomNum,
"host": destinationMachine,
"port": 5000}
Note that Janus forwards the stream with UDP. On the destination computer, you can use gstreamer to create a UDP source for the stream and route it out to your speakers:
gst-launch-1.0 -m udpsrc port=5000 ! "application/x-rtp, media=(string)audio, encoding-name=(string)OPUS, payload=(int)100, rate=16000, channels=(int)1" ! rtpopusdepay ! opusdec ! audioconvert ! audiorate ! audioresample ! alsasink device=plughw:1,0
Where '
plughw:1,0' is the name of your output audio device.
To stream the computer's audio up to Janus you would need to use the Streaming plugin as described in the documentation. Currently I have my computer (in my case a raspberry pi) talk to Janus over curl and make a stream mountpoint. Gstreamer then uses a udpsink to send the stream to Janus. Something like this:
gst-launch-1.0 alsasrc device=plughw:1,0 ! audioconvert ! audioresample ! opusenc ! rtpopuspay ! udpsink host="${JANUS_IP}" port=8005
This command likely wont work, but gives you the general idea. Normally I'm streaming both video and audio, so I tried to modify my current command.
Good luck!!