Commit Graph

8 Commits

Author SHA1 Message Date
Rostislav Pehlivanov
e9299df7a6 aacenc: partially revert previous commits to set options via a profile
It didn't work out because of the exceptions that needed to be made
for the "-1" cases and was overall more confusing that just manually
checking and setting options for each profile.
2015-10-17 03:17:27 +01:00
Rostislav Pehlivanov
0f4334df45 aacenc: add support for changing options based on a profile
This commit adds the ability for a profile to set the default
options, as well as for the user to override such options
by simply stating them in the command line while still keeping
the same profile, as long as those options are still permitted by
the profile.

Example: setting the profile to aac_low (the default) will turn
PNS and IS on. They can be disabled by -aac_pns 0 and -aac_is 0,
respectively. Turning on -aac_pred 1 will cause the profile to be
elevated to aac_main, as long as no options forbidding aac_main
have been entered (like AAC-LTP, which will be pushed soon).

A useful feature is that by setting the profile to mpeg2_aac_low,
all MPEG4 features will be disabled and if the user tries to enable
them then the program will exit with an error. This profile is
signalled with the same bitstream as aac_low (MPEG4) but some devices
and decoders will fail if any MPEG4 features have been enabled.
2015-10-12 16:57:56 +01:00
Rostislav Pehlivanov
b3deaece87 aacenc: add support for encoding 7.1 channel audio
This commit implements support for 7.1 channel audio. There's no
more predefined bitstream channel mappings so going beyond 8 channels
(and 7 channels exactly) will require programmable channel elements,
which is already underway.
2015-10-12 15:53:17 +01:00
Michael Niedermayer
0c7ceb1e0a avcodec/aacenctab: Make aac_maxval_cb const
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2015-09-23 12:46:52 +02:00
Claudio Freire
b01f3ddad3 AAC encoder: simplify and speed up find_min_book
Trivial change to simplify the small but hot
find_min_book function. The new form is easier to
understand and faster.
2015-09-23 02:33:40 -03:00
Rostislav Pehlivanov
139c2f93fd aacenctab: add tns_min_sfb[] to the encoder tables header
Needed for following commits. Contains the starting sfb for
every samplerate and window type.

Signed-off-by: Rostislav Pehlivanov <atomnuker@gmail.com>
2015-09-01 06:30:08 +01:00
Timothy Gu
15ebc7787c aacenctab: Add missing ff_ prefixes
Signed-off-by: Rostislav Pehlivanov <atomnuker@gmail.com>
Reviewed-by: Ganesh Ajjanagadde <gajjanag@mit.edu>
2015-08-22 04:30:15 +01:00
Rostislav Pehlivanov
c47c781e83 aacenc: Move local encoder specific tables to a separate file
This commit moves any tables specific to the encoder from aacenc
and aaccoder to a separate file called 'aacenctab.c/.h'.
This was done as a clean up attempt as the encoder was filled with
tables pasted in between functions which made it confusing to follow
and track where each table and definition had been used.
This commit solves this by simply exporting the smaller tables out to
the aacenctab.h while the larger ones are compiled using aacenctab.c
and are referenced from the header file.

Signed-off-by: Claudio Freire <klaussfreire@gmail.com>
2015-08-07 03:58:07 -03:00