Unsatisfactory audio quality for music / ability to show video from file


I’m building webinar application based on the openvidu-mvc-node tutorial. Main purpose is for videoconferencing and screen sharing. So far I really like how OpenVidu is working!

However I came across to issues:

  1. When I stream desktop audio content that is more than just speech (it is most noticeable with low volume music) the quality of audio is not that great. Is there anything I can do to force better quality? I used OpenVidu Server configuration parameters to force higher max bitrates or made publisher resolution option higher but it does not have any effect. It sounds almost like a lower frequency for audio is used. Is it defined anywhere and could it be changed?

  2. I would like to pass a video from a file on my server to my publisher and have it shown to all subscribed at the same time - is it something that can be done in OpenVidu?

Many thanks!

Did some more digging and no matter what I do the audio stream seems to be capped at around 50kbps.

  1. The parameters to tweak the max and min bandwidth are only for video tracks. Audio quality will basically depend on what the client decides to capture and send. If its quality could be increased, it woud be in principle done somehow on the client side.
  2. Yes, you can in fact do this very easily with the new IP Cameras feature of 2.12.0. When running this REST Operation (https://openvidu.io/docs/reference-docs/REST-API/#post-apisessionsltsession_idgtconnection) in parameter rtspUri instead of an rtsp URL use a file URI like this: file:///opt/videos/myVideo.mp4

Take into account that the video file must be in the Kurento machine. You cannot use an http url there, must be a local path to the file.


Awesome, many thanks! I will look into the client side for audio.

Sorry, to clarify - would that be client side of the publisher or subscriber?

Publisher always. Try for example researching the audio constraints when creating the MediaStream: https://developer.mozilla.org/en-US/docs/Web/API/MediaTrackConstraints

Maybe there’s somthing you can play with there.


@bigmatt Did you have any audio quality improvements for music? If there are improvements then can you explain what changes did you do?

@bigmatt I also have this problem but basically it is when multiple speakers speaking (parallel streams), with audio quality degrading. We are using audio only so video is not even our concern. How can we prevent the audio quality from degrading (user input is high quality) by forcing the audio bitrate?