Ensure CBR for audio #18
Open
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
NOTE: This is applied ontop of PR #13, which fixes audio/video desync. I'll rebase this as that PR is updated and merged (hopefully.)
As noted in issue #11, I had found that while my now-merged implementation of CBR (constant bit rate) in issue #6 has been working well, I was seeing fluctuations in the audio bit rate.
While our use of the AAC encoder implies it should be generating CBR, I found that
ffmpegsupports the-minrate,-maxrate, and-bufsizeoptions for all encoders. So, this splits our buffer size variables into audio & video versions and sets-minrate,-maxrate, and-bufsizeappropriately to produce a CBR for both audio & video.It has been working correctly in my testing, but I'll want to re-test after #13 is merged.