From: Michael Niedermayer <michael@niedermayer.cc>
To: FFmpeg development discussions and patches <ffmpeg-devel@ffmpeg.org>
Subject: Re: [FFmpeg-devel] [PATCH 1/8] aacdec: move from scalefactor ranged arrays to flat arrays
Date: Thu, 16 May 2024 20:30:02 +0200
Message-ID: <20240516183002.GP6420@pb2> (raw)
In-Reply-To: <20240516100818.246162-2-dev@lynne.ee>
[-- Attachment #1.1: Type: text/plain, Size: 2549 bytes --]
On Thu, May 16, 2024 at 12:08:11PM +0200, Lynne via ffmpeg-devel wrote:
> AAC uses an unconventional system to send scalefactors
> (the volume+quantization value for each band).
> Each window is split into either 1 or 8 blocks (long vs short),
> and transformed separately from one another, with the coefficients
> for each being also completely independent. The scalefactors
> slightly increase from 64 (long) to 128 (short) to accomodate
> better per-block-per-band volume for each window.
>
> To reduce overhead, the codec signals scalefactor sizes in an obtuse way,
> where each group's scalefactor types are sent via a variable length decoding,
> with a range.
> But our decoder was written in a way where those ranges were carried through
> the entire decoder, and to actually read them you had to use the range.
>
> Instead of having a dedicated array with a range for each scalefactor,
> just let the decoder directly index each scalefactor.
>
> This also switches the form of quantized scalefactors to the format
> the spec uses, where for intensity stereo and regular, scalefactors
> are stored in a scalefactor - 100 form, rather than as-is.
>
> USAC gets rid of the complex scalefactor handling. This commit permits
> for code sharing between both.
> ---
> libavcodec/aac/Makefile | 3 +-
> libavcodec/aac/aacdec.c | 100 ++++++++++++---------------
> libavcodec/aac/aacdec.h | 5 +-
> libavcodec/aac/aacdec_dsp_template.c | 95 ++++++++++---------------
> 4 files changed, 85 insertions(+), 118 deletions(-)
>
> diff --git a/libavcodec/aac/Makefile b/libavcodec/aac/Makefile
> index c3e525d373..8b0bfff3e5 100644
> --- a/libavcodec/aac/Makefile
> +++ b/libavcodec/aac/Makefile
> @@ -2,6 +2,7 @@ clean::
> $(RM) $(CLEANSUFFIXES:%=libavcodec/aac/%)
>
> OBJS-$(CONFIG_AAC_DECODER) += aac/aacdec.o aac/aacdec_tab.o \
> - aac/aacdec_float.o
> + aac/aacdec_float.o aac/aacdec_usac.o \
> + aac/aacdec_ac.o
AR libavcodec/libavcodec.a
ar: libavcodec/aac/aacdec_ac.o: No such file or directory
make: *** [ffbuild/library.mak:38: libavcodec/libavcodec.a] Error 1
[...]
--
Michael GnuPG fingerprint: 9FF2128B147EF6730BADF133611EC787040B0FAB
In fact, the RIAA has been known to suggest that students drop out
of college or go to community college in order to be able to afford
settlements. -- The RIAA
[-- Attachment #1.2: signature.asc --]
[-- Type: application/pgp-signature, Size: 195 bytes --]
[-- Attachment #2: Type: text/plain, Size: 251 bytes --]
_______________________________________________
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
https://ffmpeg.org/mailman/listinfo/ffmpeg-devel
To unsubscribe, visit link above, or email
ffmpeg-devel-request@ffmpeg.org with subject "unsubscribe".
next prev parent reply other threads:[~2024-05-16 18:30 UTC|newest]
Thread overview: 13+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-05-16 10:08 [FFmpeg-devel] [PATCH 0/8] aacdec: add a native xHE-AAC decoder Lynne via ffmpeg-devel
2024-05-16 10:08 ` [FFmpeg-devel] [PATCH 1/8] aacdec: move from scalefactor ranged arrays to flat arrays Lynne via ffmpeg-devel
2024-05-16 18:30 ` Michael Niedermayer [this message]
2024-05-16 18:46 ` Lynne via ffmpeg-devel
2024-05-16 10:08 ` [FFmpeg-devel] [PATCH 2/8] aacdec: expose channel layout related functions Lynne via ffmpeg-devel
2024-05-16 10:08 ` [FFmpeg-devel] [PATCH 3/8] aacdec: expose decode_tns Lynne via ffmpeg-devel
2024-05-16 10:08 ` [FFmpeg-devel] [PATCH 4/8] aacdec_dsp: implement 768-point transform and windowing Lynne via ffmpeg-devel
2024-05-16 10:08 ` [FFmpeg-devel] [PATCH 5/8] aactab: add deemphasis tables for USAC Lynne via ffmpeg-devel
2024-05-16 10:08 ` [FFmpeg-devel] [PATCH 6/8] aactab: add tables for the new USAC arithmetic coder Lynne via ffmpeg-devel
2024-05-16 10:08 ` [FFmpeg-devel] [PATCH 7/8] aactab: add new scalefactor offset tables for 96/768pt windows Lynne via ffmpeg-devel
2024-05-16 10:08 ` [FFmpeg-devel] [PATCH 8/8] aacdec: add a decoder for AAC USAC (xHE-AAC) Lynne via ffmpeg-devel
2024-05-16 10:26 ` Andreas Rheinhardt
2024-05-16 15:00 ` Lynne via ffmpeg-devel
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20240516183002.GP6420@pb2 \
--to=michael@niedermayer.cc \
--cc=ffmpeg-devel@ffmpeg.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Git Inbox Mirror of the ffmpeg-devel mailing list - see https://ffmpeg.org/mailman/listinfo/ffmpeg-devel
This inbox may be cloned and mirrored by anyone:
git clone --mirror https://master.gitmailbox.com/ffmpegdev/0 ffmpegdev/git/0.git
# If you have public-inbox 1.1+ installed, you may
# initialize and index your mirror using the following commands:
public-inbox-init -V2 ffmpegdev ffmpegdev/ https://master.gitmailbox.com/ffmpegdev \
ffmpegdev@gitmailbox.com
public-inbox-index ffmpegdev
Example config snippet for mirrors.
AGPL code for this site: git clone https://public-inbox.org/public-inbox.git