-
Notifications
You must be signed in to change notification settings - Fork 280
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Opus codec ignores bitrate settings #41
Comments
I can confirm this issue is present with all of Linux, Windows, and Android versions of jitsi. If someone can point me to the involved parts of the code I may be able to at least have a look at what is going wrong here. |
We initialize the encoder here: https://github.com/jitsi/libjitsi/blob/master/src/org/jitsi/impl/neomedia/codec/audio/opus/JNIEncoder.java#L246 |
Did someone already enable debug log and check if the used value is correct in the following output? logger.debug(
"Encoder settings: audio bandwidth " + bw + ", bitrate "
+ Opus.encoder_get_bitrate(encoder) + ", DTX "
+ Opus.encoder_get_dtx(encoder) + ", FEC "
+ Opus.encoder_get_inband_fec(encoder)); |
Yes, I checked that and it was correct. |
Ok so its strange because you can see the log information tries to ask Opus itself to report the bitrate. Jitsi cannot do more than to ask for the bitrate in setup and then check if it has been set. If the codec itself ignores the request somehow we cannot know at the moment Im afraid. It would need some more testing of the used Opus lib and whats going wrong there. |
Boris, I also wrote you a mail...
Can it be that this function runs after the initial setup, thereby limiting the encoder to 40kbps as the user wrote? Im sorry I icant test this, I have no Java environment here |
Absolutely, this looks like its the problem! Thank you for posting it (I have not received an email from you). I just pushed a fix. Unfortunately because of this issue I haven't tested it with Jitsi, and I don't know when it will land there. |
You are welcome. By the way I dont get the point of having maxaveragebitrate and bitrate in this code. Why is this necessary? |
maxaveragebitrate comes from the remote side. We honor it by not exceeding it, but we shouldn't increase our sending bitrate just because the remote side reported that they can handle it. In practice, if the remote side is Jitsi, maxaveragebitrate isn't included. |
Can I already test this in nightly? |
Not in the Jitsi nightlies. As Boris said, this will take quite some time. |
http://lists.jitsi.org/pipermail/users/2014-June/007435.html
I've tried to stream audio to a SIP Account with the opus codec. Setting: 128 Kpbs.
I've started the connection and it works, but the upstream was only at 40 Kbps and not at 128 Kbps like configured.
(Issue migrated from https://trac.jitsi.org/ticket/1293)
![image](https://cloud.githubusercontent.com/assets/4939753/7005028/1be33292-dc74-11e4-8e1f-0a876ef6bf31.png)
The text was updated successfully, but these errors were encountered: