[FFmpeg-trac] #2686(avcodec:open): Native AAC encoder collapses at high bitrates on some samples
FFmpeg
trac at avcodec.org
Sun Oct 12 21:09:43 CEST 2014
#2686: Native AAC encoder collapses at high bitrates on some samples
-------------------------------------+-------------------------------------
Reporter: Kamedo2 | Owner:
Type: defect | klaussfreire
Priority: normal | Status: open
Version: git-master | Component: avcodec
Keywords: aac | Resolution:
regression | Blocked By:
Blocking: | Reproduced by developer: 1
Analyzed by developer: 0 |
-------------------------------------+-------------------------------------
Comment (by Kamedo2):
Replying to [comment:318 klaussfreire]:
> I did manage to find a few low-hanging-bugs in ANMR, but, and this is
quaint, fixing them makes ANMR 10x slower.
Is that
{{{
Assertion diff >= 0 && diff <= 120 failed at libavcodec/aacenc.c:399
}}}
? Rare, but it happens on some tracks.
libavcodec/aacenc.c
{{{
/**
* Encode scalefactors.
*/
static void encode_scale_factors(AVCodecContext *avctx, AACEncContext *s,
SingleChannelElement *sce)
{
int off = sce->sf_idx[0], diff;
int i, w;
for (w = 0; w < sce->ics.num_windows; w += sce->ics.group_len[w]) {
for (i = 0; i < sce->ics.max_sfb; i++) {
if (!sce->zeroes[w*16 + i]) {
diff = sce->sf_idx[w*16 + i] - off + SCALE_DIFF_ZERO;
av_assert0(diff >= 0 && diff <= 120);
off = sce->sf_idx[w*16 + i];
put_bits(&s->pb, ff_aac_scalefactor_bits[diff],
ff_aac_scalefactor_code[diff]);
}
}
}
}
}}}
--
Ticket URL: <https://trac.ffmpeg.org/ticket/2686#comment:320>
FFmpeg <https://ffmpeg.org>
FFmpeg issue tracker
More information about the FFmpeg-trac
mailing list