View Full Version : command-line frontend for WinAmp AAC+ v2 encoder (upd 2006-05-15)


dimzon
18th November 2005, 11:46
Winamp5.2 AAC+v2 encoder command-line frontend (new version)

http://img247.imageshack.us/img247/4605/dibujodd8ow.gif


Support for AAC-LC encoding via CT encoder
6ch support
support aacPlus HE-AAC High-Bitrate Encoder

Works fine with Winamp 5.2 Release Feb 23 2006 Full (Not Pro) - You does'nt need Winamp Pro in order to encode :cool:

new version contains some bugfix and new switches
********************************************************************
* AACPlus v2 Encoder (using Winamp 5.2 enc_aacplus.dll)
* Source timestamp Sun Feb 26 16:19:37 2006
* Build Feb 26 2006, 16:22:43
********************************************************************
* NOTE! enc_aacplus.dll must be into executable directory
* get it from Winamp 5.2 plugins directory
* tested on Winamp 5.2 Release Feb 23 2006 Full (Not Pro) version)
********************************************************************
Usage:
enc_aacPlus <wav_file> <bitstream_file> [options]
Options:
--cbr <bitrate> - Set bitrate (CBR) to <bitrate> bps. Default is 48000
--nops - Disable Parametric Stereo
--is - Prefer Independed Stereo
--dc - Prefer Dual Channels
--mpeg2aac - Produce MPEG2 AAC isntead of MPEG4 AAC
--lc - Encode LC-AAC instead AAC+ (bitrate up to 320000)
--high - use aacPlusHigh Encoder (bitrate up to 256000, multichannel is not supported)
--mp4box - Wrap result into MPEG4 container (MP4BOX.EXE must be into executable directory)
--rawpcm <rate> <cnt> <bp> - Signal RAW PCM input intead of WAV
<rate> - Samplerate in Hz (32000, 44100 or 48000)
<cnt> - Channels count (1 or 2 or 6)
<bp> - Bit's per sample (8 or 16)
WARNING: this encoder can read and encode data from stdin:
use - as input filename



Get it @ BeHappy Workspace (take look @ my signature)

raquete
18th November 2005, 11:56
dimzon,
this is fantastic. :cool:

thank you so much!

Jalavera
18th November 2005, 12:41
@dimzon: is 6 channel-wav supported as input like in Belight?

Jalavera
18th November 2005, 13:07
ok. Thanks. I understand.

gURuBoOleZ
19th November 2005, 18:07
That's great! I was hoping for it :)
I noticed a problem: the --mp4box command doesn't work on my side. MP4BOX is in the directory; I'm using foobar2000 0.83.
- %d --cbr 32000 --chmode 4 --mpeg4aac => OK
- %d --cbr 32000 --chmode 4 --mpeg4aac --mp4box => doesn't work

I changed the extension (mp4, m4a), but it didn't solve the problem. Any idea?

gURuBoOleZ
21st November 2005, 17:13
Perfect!
Thank you :)

dimzon
21st November 2005, 17:15
Perfect!
Thank you :)
I have found yet another bug - can't encode WAV with length >=7Gb :(
Unfortunally I can't solve this bug right now - my HDD is dead and I lost my source code :(
Shit Happens...

gURuBoOleZ
22nd November 2005, 04:25
I sympathize!
(I lost three HDD in the past)

dimzon
22nd November 2005, 15:31
I sympathize!
(I lost three HDD in the past)
Yesterday,
All those backups seemed a waste of pay.
Now my database has gone away.
Oh I believe in yesterday.

Suddenly,
There's not half the files there used to be,
And there's a deadline hanging over me
The system crashed so suddenly.

I pushed
something wrong
What it was, I could not say.
Now all my data's gone
Аnd I long for yesterday-ay-ay-ay.

WBTCPIP
29th November 2005, 00:45
Hi dimzon,
i hope your great work is not lost forever.

I was hoping to see your encoder with the addition of stdout support!

dimzon
29th November 2005, 11:35
Hi dimzon,
i hope your great work is not lost forever.

I was hoping to see your encoder with the addition of stdout support!
I plan to rewrite it from scratch (original source code is lost) in the future bcz I need 6ch support now ;)

hitbit
5th December 2005, 15:37
Er... how can I enable 6ch mode?

dimzon
5th December 2005, 15:39
Er... how can I enable 6ch mode?
- use supplied enc_aacplus.dll (newer one from latest winamp does'nt work with 6ch)
- use 6ch wav as input

hitbit
5th December 2005, 15:48
But it can OUTPUT 6ch AAC, or it only converts 6ch to Stereo?

dimzon
5th December 2005, 15:49
But it can OUTPUT 6ch AAC
Yes! If You supply 6ch WAV as input you will get 6ch AAC+

buzzqw
6th December 2005, 13:34
Hi Dimzon !

Thanks for you excellent work !

i have a question: what is the bitrate range allowed ?

i tryed several bitrate, but i think that bitrate range are only between 96000 and 128000

thanks for your tips !

BHH

dimzon
6th December 2005, 13:36
Hi Dimzon !

Thanks for you excellent work !

i have a question: what is the bitrate range allowed ?

i tryed several bitrate, but i think that bitrate range are only between 96000 and 128000

thanks for your tips !

BHH
96000-128000 for 6ch
16000-128000 for mono/stereo

buzzqw
6th December 2005, 16:37
YES ! true!

in my test i am using a 6ch wav !

My Kudos Dimzon !

BHH

P.S. While programming ... is possible to correct azid pipe ? (as written in readme.txt azid piping is broken...)

Daijoubu
6th December 2005, 19:04
This new CLI produce ifferent filesize, even with the same enc_aacplus.dll

New: 1946019

* Source timestamp Mon Dec 5 15:12:05 2005
* Build Dec 5 2005, 15:12:44

Old: 1947877

* Source timestamp Fri Nov 18 15:27:54 2005
* Build Nov 18 2005, 15:28:46

Anyhow, keep up the good spirit, love your app :)
Btw, if we don't need 6ch support, should we use the newest dll or stick to the old one? (why is it twice as big too)
Edit: Ah, I see, the dll was packed

dimzon
7th December 2005, 10:08
New: 1946019
Old: 1947877

did you shure you use same channel mode?
new version use PS for bitrates below 48kbps automatically

Daijoubu
8th December 2005, 03:47
Yes, same setting

WBTCPIP
12th December 2005, 23:05
Hi dimzon,
it is a hard work for you to add stdout support?
I need it to use encoded data in my custom application.
You'll make me happy if you can do it!
Thanks!

dimzon
13th December 2005, 09:27
Hi dimzon,
it is a hard work for you to add stdout support?
I need it to use encoded data in my custom application.
You'll make me happy if you can do it!
Thanks!
It's easy to add stdout support (unfortunally no MP4 contaner will be avaluable for stdout). But I'm really too busy now! If you are developer You can join to http://workspaces.gotdotnet.com/behappy and add stdout support yourself...

LoRd_MuldeR
27th December 2005, 16:19
This front-end works great. Thanks for good work, dimzon :)

One question: What about VBR encoding?
Would that be possible with enc_aacplus.dll ???

dimzon
27th December 2005, 16:36
One question: What about VBR encoding?
Would that be possible with enc_aacplus.dll ???
No, it's impossible

LoRd_MuldeR
27th December 2005, 17:39
No, it's impossible

It's a great pity :(

Then you could call the switch "--bitrate" or alike instead of "--cbr"
With "--cbr" I expect something like "--vbr" ...

dimzon
31st January 2006, 19:00
Winamp5.2 AAC+v2 encoder command-line frontend (new version)

http://img247.imageshack.us/img247/4605/dibujodd8ow.gif


Support for AAC-LC encoding via CT encoder
6ch support

enc_aacplus.dll from WinAmp 5.2 beta requed (tested on build 365)

Get it @ BeHappy Workspace (take look @ my signature)

DeathTheSheep
31st January 2006, 21:21
Are there any plans to support the aacPlus HE-AAC High-Bitrate Encoder? (Currently in Winamp 5.2 beta)

PS: I'm not talking about the LC-AAC or the standard HE-AAC, but actually the brand-new HE-AAC high-bitrate encoder.

Peter1234
1st February 2006, 04:59
dimzon,
Thanks for the new command line encoder. I have been able get most of it to work, but I have not figured out how to encode to LC profile. You mention "Support for AAC-LC encoding via CT encoder" but what is the CT encoder? Can you give an example for LC profile?

dimzon
1st February 2006, 11:06
dimzon,
Thanks for the new command line encoder. I have been able get most of it to work, but I have not figured out how to encode to LC profile. You mention "Support for AAC-LC encoding via CT encoder" but what is the CT encoder? Can you give an example for LC profile?
just add --lc option to your command line

Are there any plans to support the aacPlus HE-AAC High-Bitrate Encoder? (Currently in Winamp 5.2 beta)
Unfortunally I have no registered PRO version so I can't do it ...

dimzon
1st February 2006, 11:55
Are there any plans to support the aacPlus HE-AAC High-Bitrate Encoder? (Currently in Winamp 5.2 beta)
Done ;)

support aacPlus HE-AAC High-Bitrate Encoder

Enjoy ;)

shon3i
1st February 2006, 13:52
Can i use ac3 input instead wav

dimzon
1st February 2006, 13:55
Can i use ac3 input instead wav
Yes. You can use pipeline to sent decoded ac3 to utility stdin. You can use BePipe for AC3 decoding. Or just use BeHappy...
For BePipe/BeHappy reference take look @ my signature

shon3i
1st February 2006, 14:27
But how to use 6ch ac3 to covert to He-aac 6ch with 128kbs and mp4 container with accurate information. Comandline please

dimzon
1st February 2006, 14:38
But how to use 6ch ac3 to covert to He-aac 6ch with 128kbs and mp4 container with accurate information. Comandline please
BePipe --script "NicAc3Source(^c:\myfile.ac3^)" | enc_aacplus - c:\myresult.mp4 --cbr 128000 --mpeg4aac --mp4box
Note:

NicAudio.dll must be @ aviSynth plugins folder
mp4box.exe mus be @ enc_aacplus folder

shon3i
1st February 2006, 14:44
OK works thanks dimzon

Peter1234
1st February 2006, 18:22
dimzon,

I can't get LC encoding to work.

just add --lc option to your command line

I tried that but I get the following error message.

Encoder: ACC-LC
Can't create encoder!

My command line is

enc_aacPlus.exe 48KHz.wav out.aac --lc

The other options all seem to work.

dimzon
1st February 2006, 18:24
My command line is
I have not tested LC encoder @ this samplerate. Please, check it @ stereo 44100Hz

Peter1234
1st February 2006, 19:11
dimzon,

Using command line:

enc_aacPlus.exe 44kHz.wav out.aac

works and produces this output

Input file: 44kHz.wav
outputfile: out.aac
Sample Rate: 44100
ChannelCount: 2
Bitrate: 48000
ChannelMode: ParametricStereo
Encoder: AAC + v2 (HE-AAC 2)
Done

Using this command line:

enc_aacPlus.exe 44kHz.wav out.aac --lc

does not work and produces this output

Input file: 44kHz.wav
outputfile: out.aac
Sample Rate: 44100
ChannelCount: 2
Bitrate: 48000
ChannelMode: Stereo
Encoder: AAC-LC
Can't create encoder!

dimzon
1st February 2006, 19:20
Peter1234, wich DLL version does you use?

By the way - I have found some restrictins encoding 6ch 48KHz audio
aacPlus v2 - bitrate must be >=96000 and <=128000
LC - bitrate must be >=160000 and <=320000
aacPlus HE-AAC High-Bitrate Encoder doesn't support 6ch at all

DeathTheSheep
1st February 2006, 19:32
Wow, that was fast! This tool is really awesome. Thanks for coding it, dimzon :)

Is there any way to force PS on or off? On hydrogenaudio, it is said that PS can hurt some samples even at 32kbps but help some samples up to 48kbps! It would really help if there was a way to toggle this on/off for particular files. Thanks!

dimzon
1st February 2006, 19:34
Is there any way to force PS on or off?
I will add this a bit later

Peter1234
1st February 2006, 19:37
dimzon,
dll is from WinAmp 5.13 (just updated). Size is 274 KB (280,576 bytes).

My wav was encoded with Audacity and according to Foobar is

bitrate = 1411
samplerate = 44100
channels = 2
codec = PCM
bitspersample = 16

So I assume the problem is the bitrate of 1411 kbps.

shon3i
1st February 2006, 20:02
I have same problem with high bitrate encoder with behappy and 6ch ac3source. Can't create encoder message but with stereo input works

DeathTheSheep
1st February 2006, 21:59
dll is from WinAmp 5.13
That's probably the problem. You need the .dll from Winamp 5.20[.365] or later in order for it to work ;)

Peter1234
1st February 2006, 23:06
DeathTheSheep,

You need the .dll from Winamp 5.20[.365] or later in order for it to work

WinAmp version 5.13 is the newest free version (Jan. 31, 2006). I think the enc_aacplus.dll is the same in both the free and pro versions? But perhaps I do need the pro version. Does the --lc option work for you?

DeathTheSheep
1st February 2006, 23:09
It works fine fer me ;) ...maybe you haven't heard the latest underground info? *whisperhere (http://download.nullsoft.com/winamp/beta/winamp52_0393_beta_full.exe)whisper*

:D:D

Peter1234
1st February 2006, 23:41
DeathTheSheep,
I did a file compare on the free enc_aacplus.dll version and the pro enc_aacplus.dll version and they are different. When I tried the pro version the --lc option works. Thanks for your help.

dimzon
2nd February 2006, 11:34
I have same problem with high bitrate encoder with behappy and 6ch ac3source. Can't create encoder message but with stereo input works
http://forum.doom9.org/showthread.php?p=778734#post778734

shon3i
2nd February 2006, 17:58
http://forum.doom9.org/showthread.php?p=778734#post778734
I see. Thanks

wammie
16th February 2006, 06:07
It seems this front end cannot be invoked by Exact Audio Copy as an external program. In my attempts, the DOS window opens very quickly and then closes. I have been unable to capture any messages from the DOS box, even with a screen capture, as the window appears only for the briefest moment.

Is there a way to use this program from Exact Audio Copy? I understand the developer would not and should not need to make this compatible with everything else out there, but if anyone knows how to make it work I'd appreciate some help.

dimzon
17th February 2006, 13:50
Winamp5.2 AAC+v2 encoder command-line frontend (new version)

http://img247.imageshack.us/img247/4605/dibujodd8ow.gif


Support for AAC-LC encoding via CT encoder
6ch support
support aacPlus HE-AAC High-Bitrate Encoder

enc_aacplus.dll from WinAmp 5.2 beta requed (tested on build 365)

new version contains some bugfix

Get it @ BeHappy Workspace (take look @ my signature)

Gabriel_Bouvigne
18th February 2006, 09:08
It seems to me that there is no way to choose between channel modes in this version.
--chmode is not parsed.

dimzon
19th February 2006, 12:45
It seems to me that there is no way to choose between channel modes in this version.
--chmode is not parsed.
ParametricStereo will be used for he-aac @ bitrate <=48kbps
JointStereo will be used otherwize

Does anybody need addittional modes? I can add it during next week

Gabriel_Bouvigne
19th February 2006, 22:57
Yes, I saw in the source code that it was using default settings according to the bitrate.
As you provided source code (thanks a lot), I modified it to be able to specify channel modes, so it suits my needs.

dimzon
19th February 2006, 23:08
As you provided source code (thanks a lot), I modified it to be able to specify channel modes, so it suits my needs.
Can You share modified binary and source (to save my time a bit)?

Gabriel_Bouvigne
19th February 2006, 23:53
Well, it's just:

if(0==strcmp("--chmode", argv[i]))
{
nChannelMode=atoi(argv[++i]);
continue;
}

dimzon
26th February 2006, 14:35
new version is out

AAC+ 6-channel encoding up to 213kbps !

shon3i
18th March 2006, 16:56
For Multichannel encoding:

LC 160-320kbps
HE 96-128kbps
HE High 96-213kbps Not working i use 192 kbs and get message

Starting job proba.ac3->proba.aac
Found Audio Stream
Channels=6, BitsPerSample=16, SampleRate=48000Hz
enc_aacPlus.exe - "C:\Documents and Settings\Nenad\Desktop\proba.aac" --cbr 192000 --high --mpeg4aac
Writing RIFF header to encoder's StdIn
Writing PCM data to encoder's StdIn
Error: System.ApplicationException: Abnormal encoder termination -4
at BeHappy.Encoder.encode()
#### Encoder StdOut ####
********************************************************************
* AACPlus v2 Encoder (using Winamp 5.2 enc_aacplus.dll)
* Source timestamp Sun Feb 26 16:19:37 2006
* Build Feb 26 2006, 16:22:43
********************************************************************
* NOTE! enc_aacplus.dll must be into executable directory
* get it from Winamp 5.2 plugins directory
* tested on Winamp 5.2 Release Feb 23 2006 Full (Not Pro) version)
********************************************************************
Input file: -
Output file: C:\Documents and Settings\Nenad\Desktop\proba.aac
SampleRate: 48000
ChannelCount: 6
BitsPerSample: 16
Bitrate: 192000
ChannelMode: Multichannel
Encoder: aacPlusHigh
Can't create encoder!

straycat
19th March 2006, 14:31
It seems this front end cannot be invoked by Exact Audio Copy as an external program. In my attempts, the DOS window opens very quickly and then closes. I have been unable to capture any messages from the DOS box, even with a screen capture, as the window appears only for the briefest moment.

Is there a way to use this program from Exact Audio Copy? I understand the developer would not and should not need to make this compatible with everything else out there, but if anyone knows how to make it work I'd appreciate some help.

I have tried as well to use enc_aacplus.exe in combination with EAC and I failed. Can anyone help?

dimzon
20th March 2006, 06:55
For Multichannel encoding:

LC 160-320kbps
HE 96-128kbps
HE High 96-213kbps Not working i use 192 kbs and get message
It's your mistake ;)

try HE 96-213kbps


HE High (Higth doesn't mean hight bitrate but hight samplerate) doen't supprt 6ch

So You must use HE-AAC (Not HE High) (96-213) or LC-AAC (160-320) for 6ch encoding

shon3i
20th March 2006, 09:31
It's your mistake ;)

try HE 96-213kbps


HE High (Higth doesn't mean hight bitrate but hight samplerate) doen't supprt 6ch

So You must use HE-AAC (Not HE High) (96-213) or LC-AAC (160-320) for 6ch encoding
Yes i know now, i soloved the problem.

dimzon
15th May 2006, 14:36
fresh version is out

Kostarum Rex Persia
15th May 2006, 18:14
Dimzon, where Im can download changelog for 20060515? Give download link, please.

dimzon
15th May 2006, 18:20
Dimzon, where Im can download changelog for 20060515? Give download link, please.

I doesn't maintain changelog for it

shon3i
15th May 2006, 19:06
Just one small bug fixed when used mp4 container and LC-AAC, everything other are same

aiyunyi
18th May 2006, 16:05
Can this cli and enc_aacplus.dll be used alone without winamp?

shon3i
18th May 2006, 16:31
Can this cli and enc_aacplus.dll be used alone without winamp?
Yes of course

aiyunyi
18th May 2006, 16:50
But I couldn't find enc_aacplus.dll, winamp is not installed here.

dimzon
18th May 2006, 17:45
But I couldn't find enc_aacplus.dll, winamp is not installed here.
Install WinAmp, get Your copy of enc_aacPlus.dll and uninstall WinAmp ;)

aiyunyi
19th May 2006, 09:09
surprisingly, i find it in kmplayer!

joynes
27th June 2006, 09:53
When i encode an 44 kHz wave sample with --lc from enc_aacplus.exe the result will be downsampled to 32 KHz. Why is this? Is there some way around?

/regards joynes

shon3i
27th June 2006, 18:40
When i encode an 44 kHz wave sample with --lc from enc_aacplus.exe the result will be downsampled to 32 KHz. Why is this? Is there some way around?

/regards joynes
What is you bitrate

joynes
3rd July 2006, 21:37
What is you bitrate

Hi! sry didnt see your replay earlier.. well my bitrate is 64 Kbps...

/regards joynes

shon3i
3rd July 2006, 21:54
Hi! sry didnt see your replay earlier.. well my bitrate is 64 Kbps...

/regards joynes
That is normal because that is too low bitrate for LC profile (encoder try to prevent how much more artifacts from audio), better than you use HE profile instead

gameplaya15143
4th July 2006, 01:09
dimzon, did you ever figure out how to add the resample option again? Remember your really old frontend could do it. ;)

joynes
4th July 2006, 09:44
That is normal because that is too low bitrate for LC profile (encoder try to prevent how much more artifacts from audio), better than you use HE profile instead

Ok i see :)... but I thought it was a common format for mobiles: 64 kbps/44 Khz Samplerate AAC LC...

i tried with neroAacEnc.exe from Nero digital which could preserve the samplerate. Is this encoder better for this sort of work?

/regards joynes

shon3i
4th July 2006, 12:00
i tried with neroAacEnc.exe from Nero digital which could preserve the samplerate. Is this encoder better for this sort of work?
Yes, but have little whrost quality than ct.

shon3i
27th September 2006, 17:23
New Coding Techologies AAC encoder is released with new version of Winamp 5.3

LC-AAC now have PNS and is optimized for speech, and have down to 8 kbps

http://img231.imageshack.us/img231/9518/ctaacdi4.jpg


HE-AAC and HE-AAC High as optimised only with speech, and aslo have bitrates down to 8kbps, and devs says that encoder have big improvments in low bitrate encoding (I tested at 48kbps and sounds better than old version, maybe now can beat nero :D)

http://img218.imageshack.us/img218/8054/ctaac1uj9.jpg

Stereo mode now can be only Joint Stereo or Parametric Stereo, oterwise can be Mono or multichannel.

This enc_aacplus.exe works good with this new version of enc_aacplus.dll.

Dimzon can you implement this new features and remove old, and update BeHappy Dialog (With rounded bitrate)! Please.

Kurtnoise
27th September 2006, 19:18
http://kurtnoise.free.fr/index.php?dir=misc/&file=enc_aacPlus_20060927.zip

I tested at 48kbps and sounds better than old version, maybe now can beat nero
Prove it instead of trolling...

shon3i
27th September 2006, 21:40
Thanks Kurtnoise for build.

Prove it instead of trolling...

IMO CT AAC is always sounds better than Nero especialy in multichannel encoding. My ears proved to me


EDIT: Sorry Kurtnoise but looks like encoder support all stereo modes which means Independet Stereo, Joint Stereo, Dual Channel, Parametric Stereo, but IS and DC is removed from winamp beacuse confuse ppls. So please if you can back --is and --dc switches

shon3i
28th September 2006, 11:07
Here is package who contains enc_aacplus.exe compiled by me, and enc_aacplus.dll, nscrt.dll, and source code.

http://www.box.net/public/n1y5sea9fl

The different from Kurtnoise build is, again it have --dc i --is switches, which means you can use again Independet Stereo and Dual Channel mode.

********************************************************************
* AACPlus v2 Encoder (using Winamp 5.3 enc_aacplus.dll)
* Source timestamp Thu Sep 28 12:03:37 2006
* Build Sep 28 2006, 12:03:42
********************************************************************
* NOTE! enc_aacplus.dll and nscrt.dll must be into executable directory
* get it from Winamp 5.3 plugins directory
*********************************************************************
Usage:
enc_aacPlus <wav_file> <bitstream_file> [options]
Options:
--cbr <bitrate> - Set bitrate (CBR) to <bitrate> bps. Default is 48000
--nops - Disable Parametric Stereo
--is - Prefer Independed Stereo
--dc - Prefer Dual Channels
--mpeg2aac - Produce MPEG2 AAC isntead of MPEG4 AAC
--lc - Encode LC-AAC instead AAC+ (bitrate up to 320000)
--high - use aacPlusHigh Encoder (bitrate up to 256000, multichannel is not supported)
--speech - tune Encoder Engine for Speech
--pns - Enable Perceptual Noise Subsitution
--mp4box - Wrap result into MPEG4 container (MP4BOX.EXE must be into executable directory)
--rawpcm <rate> <cnt> <bp> - Signal RAW PCM input intead of WAV
<rate> - Samplerate in Hz (32000, 44100 or 48000)
<cnt> - Channels count (1 or 2)
<bp> - Bit's per sample (8 or 16)
WARNING: this encoder can read and encode data from stdin:
use - as input filename

shon3i
1st April 2007, 17:57
New enc_aacplus package is out.

http://www.box.net/shared/1u8h68huvi, all files including source


********************************************************************
* AACPlus v2 Encoder (using Winamp 5.33/5.34 enc_aacplus.dll and nscrt.dll)
* Coding Technologies encoder 8.0.3
* Source timestamp Wed Mar 28 18:55:14 2007
* Build Mar 28 2007, 18:57:03
********************************************************************
Usage:
enc_aacPlus <wav_file> <bitstream_file> [options]
Options:
--br - Set bitrate (CBR) to <bitrate> bps. Default is 128000
--ps - Enable Parametric Stereo (bitrates up to 560000)
--is - Independed Stereo, disables Joint Stereo M/S coding
--mono - Encode as Mono
--he - Encode as HE-AAC (bitrate up to 128000)
--lc - Encode as LC-AAC (bitrate up to 320000)
--high - Encode as HE-AAC with High Bitrates
(bitrates up to 256000, multichannel is not supported)
--speech - Tune for Speech
--pns - Enable Perceptual Noise Subsitution (PNS)
--mp4 - Output MPEG4 ISO compilant file .mp4 instead raw .aac
(mp4mux.exe must be in same directory)
--rawpcm <rate> <cnt> <bp> - Signal RAW PCM input intead of WAV
<rate> - Samplerate in Hz (32000, 44100 or 48000)
<cnt> - Channels count (1 or 2)
<bp> - Bit's per sample (8 or 16)
WARNING: this encoder can read and encode data from stdin:
use - as input filename

Kurtnoise
1st April 2007, 18:08
Where does mp4mux come from ?

shon3i
1st April 2007, 19:00
Where does mp4mux come from ?
Ateme beta test, original filename is mp4muxer.exe.

gameplaya15143
3rd April 2007, 23:49
:( still no option to set the output samplerate?

SealTooGreat
4th April 2007, 05:03
Ateme beta test, original filename is mp4muxer.exe.
Is it Ateme's mp4muxer?!...or it's opensource?!

shon3i
4th April 2007, 16:27
:( still no option to set the output samplerate?
Did you mean resamle option for LC-AAC audio?

I realy don't know why you need that option, coz bandwith will be same. For everything under 96kbps better to encode as mono if LC-AAC used, or use Nero encoder, because is better optimised from 64-96kbps range.

Is it Ateme's mp4muxer?!...or it's opensource?!I relly don't know, maybe is nero muxer, but app is not opensource, and i use it from package who is linked on net, ateme 1.0.1.28 ;)

Kurtnoise
4th April 2007, 18:13
yeah...thanks to share something completely illegal.

Jongan
10th April 2007, 13:48
Try this tools www.tinymp4.com, and leave some suggestions.

tebasuna51
10th April 2007, 18:04
Try this tools www.tinymp4.com, and leave some suggestions.
3GPP Encoder with 3 cbr stereo encoder options:
- 64 Kb/s HE-AAC
- 48 Kb/s HE-AAC
- 24 Kb/s HE-AAC + PS
Can't be compared with CT aacPlus encoder.
Tinymp4 is a player, tagger, multiformat stereo decoder, ... but here speak only about encoder.

@shon3i
To avoid the problem about the legality of mp4muxer use, maybe we can preserve the old option
--mp4box
and add now, instead --mp4:
--mp4muxer

Then legal owners of mp4muxer can use it, and the rest of users continue with the free mp4box. Enc_aacplus only need send the job to mp4box or mp4muxer with the appropriate parameters.

BTW, when change the parameters all app using the tool must be changed. At least BeHappy and MEGUI must be changed to use this new version. Maybe the old parameters must be maintained for compatibility, like:

--br, --cbr
--he, --nops

shon3i
10th April 2007, 20:15
To avoid the problem about the legalityThat is true, but this package is 3 years on internet, and probably many ppl's have it, aslo there is not any eula in package, so i don't care of any rights.

Then legal owners of mp4muxer can use it, and the rest of users continue with the free mp4box. Enc_aacplus only need send the job to mp4box or mp4muxer with the appropriate parameters.That isn't problem, but i don't wont back to mp4box, because is over 1mb, and i haved much problem's with mp4box mp4's files http://forum.doom9.org/showthread.php?t=111224, not only with my standalone, aslo with winamp and foobar, now for example 6ch mp4aac in foobar 0.9.4.2 have some troubles, muxed with mp4box.

Nero, Winamp, mp4UI, mp4muxer, muxers don't have these problems.

I will go round mp4box until not solove this problems.

BTW, when change the parameters all app using the tool must be changed. At least BeHappy and MEGUI must be changed to use this new version. Maybe the old parameters must be maintained for compatibility, like:

--br, --cbr
--he, --nops

--cbr, can be added as alias, but --nops don't have sense coz --ps is now used for PS encoding.

I will update BeHappy package ASAP, so there is not problem, i realy don't care about MeGUI, because that is 10 minutes job to change switches. I know that MeGUI devs don't love CT AAC because it totality illegal, and don't have much capabillities as nero encoder.

gameplaya15143
11th April 2007, 00:04
Did you mean resamle option for LC-AAC audio?No, I mean like what was available with dimzon's first version of the frontend (which was lost way back when his hdd died). For example, input could be 44100hz stereo, and the output could be set to 24kbps 16khz HE+PS ;)

I don't know if it is even still possible with a newer version of enc_aacplus.dll, I just know that old frontend does it just fine with an old version of the encoder dll.

The link for the old frontend was (which still seems to be working) http://www.crapshack.com/aacenc.zip



I've never had any playback issues using mp4box and winamp (using ct in_mp4.dll not the nullsoft one)

Jongan
17th April 2007, 06:02
Not really,Tinymp4 is also a aacPlus encoder, it use DirectShow to decode multiformat and use 3GPP encoder to build aacPlus stream. And use Tinymp4 any other format except mp4 to be converted to mp4. Please take a look of this,Thanks.


3GPP Encoder with 3 cbr stereo encoder options:
- 64 Kb/s HE-AAC
- 48 Kb/s HE-AAC
- 24 Kb/s HE-AAC + PS
Can't be compared with CT aacPlus encoder.
Tinymp4 is a player, tagger, multiformat stereo decoder, ... but here speak only about encoder.

@shon3i
To avoid the problem about the legality of mp4muxer use, maybe we can preserve the old option
--mp4box
and add now, instead --mp4:
--mp4muxer

Then legal owners of mp4muxer can use it, and the rest of users continue with the free mp4box. Enc_aacplus only need send the job to mp4box or mp4muxer with the appropriate parameters.

BTW, when change the parameters all app using the tool must be changed. At least BeHappy and MEGUI must be changed to use this new version. Maybe the old parameters must be maintained for compatibility, like:

--br, --cbr
--he, --nops

tebasuna51
17th April 2007, 09:27
Not really,Tinymp4 is also a aacPlus encoder, it use DirectShow to decode multiformat...
Ok I say:
"Tinymp4 is a player, tagger, multiformat stereo decoder,..."
but DirectShow isn't the better way to control the decode step.
and use 3GPP encoder to build aacPlus stream.
And I say:
"3GPP Encoder with 3 cbr stereo encoder options:
- 64 Kb/s HE-AAC
- 48 Kb/s HE-AAC
- 24 Kb/s HE-AAC + PS"
Can't be compared with CT aacPlus encoder with bitrates until 320 Kb/s and multichannel options. About the quality you can see the tests in Hydrogenaudio Forums, 3GPP is below CT and Nero encoders.

Jongan
18th April 2007, 05:42
Oh, I see, Thanks.
Ok I say:
"Tinymp4 is a player, tagger, multiformat stereo decoder,..."
but DirectShow isn't the better way to control the decode step.

And I say:
"3GPP Encoder with 3 cbr stereo encoder options:
- 64 Kb/s HE-AAC
- 48 Kb/s HE-AAC
- 24 Kb/s HE-AAC + PS"
Can't be compared with CT aacPlus encoder with bitrates until 320 Kb/s and multichannel options. About the quality you can see the tests in Hydrogenaudio Forums, 3GPP is below CT and Nero encoders.

SealTooGreat
30th June 2007, 11:25
That isn't problem, but i don't wont back to mp4box, because is over 1mb, and i haved much problem's with mp4box mp4's files http://forum.doom9.org/showthread.php?t=111224, not only with my standalone, aslo with winamp and foobar, now for example 6ch mp4aac in foobar 0.9.4.2 have some troubles, muxed with mp4box.

Nero, Winamp, mp4UI, mp4muxer, muxers don't have these problems.


Use "-isma" in mp4box's cmd line. It will add tracks (0D & BIFS), like mp4UI/Winamp does by default.

montython
24th November 2007, 11:32
I guess BeHappy version given below includes an updated version of this command-line interface to enc_aacplus.dll of WinAmp.
http://forum.doom9.org/showthread.php?p=1055997#post1055997

****************************************
* AACPlus v2 Encoder (using Winamp 5.33/5.34 enc_aacplus.dll and nscrt.dll)
* Coding Technologies encoder 8.0.3
* Source timestamp Sun Aug 12 16:42:07 2007
* Build Aug 12 2007, 16:44:37
****************************************

Is this one compatible with enc_aacplus.dll (v8.1.0) included in WinAmp 5.5? It seems to be working, anyone had any problems?

tebasuna51
24th November 2007, 13:29
Is this one compatible with enc_aacplus.dll (v8.1.0) included in WinAmp 5.5? It seems to be working, anyone had any problems?

Seems work fine with enc_aacplus.dll (565.760 bytes 2007-10-10) included in winamp55_full_emusic-7plus until 320 Kb/s.

dimzon
29th January 2008, 14:00
Hi 2 all
Where is the latest source of this tool?

Kurtnoise
29th January 2008, 21:42
http://kurtnoise.free.fr/index.php?dir=misc/&file=enc_aacPlus_src.zip

tebasuna51
30th January 2008, 01:30
Here is the last shon3i source file with mods added to BeHappy (parameters and selection of mp4 muxer), there are also a bug corrected by me:
enc_aacPlus_last (http://www.savefile.com/files/1348886)

tebasuna51
5th February 2008, 18:25
There are a new enc_aacPlus Home (http://www.codeplex.com/aacPlusCLI) created by Dimzon.

Actually have the last patched shon3i version, because is the working version with BeHappy, but any sugestion are welcome if other syntax is needed.

Kurtnoise
8th October 2009, 14:43
How to create a patch from this website ?


coz I've made an update to support mp4 output from the libmp4v2.dll (http://www.unite-video.com/phpbb/viewtopic.php?p=90100#90100)...

dimzon
8th October 2009, 14:55
How to create a patch from this website ?


coz I've made an update to support mp4 output from the libmp4v2.dll (http://www.unite-video.com/phpbb/viewtopic.php?p=90100#90100)...
1) register on Codeplex: http://www.codeplex.com/
2) send me your codeplex login
3) I will add you to http://aacpluscli.codeplex.com/ developers

Kurtnoise
8th October 2009, 15:14
Oo you're still alive dude ?!!

my Codeplex login : Kurtnoise

:)

dimzon
8th October 2009, 15:18
Oo you're still alive dude ?!!

my Codeplex login : Kurtnoise

:)
added ;)

I'm stilll alife but too busy IRL to support it myself...

Kurtnoise
8th October 2009, 17:25
http://pastebin.com/f3d54f2ec

tebasuna51
9th October 2009, 03:11
Hello, Dimzon!

http://pastebin.com/f3d54f2ec
With:
+ // just to be sure that we have the correct mode
+ for(i=0,dot=NULL;strOutputFileName[i];i++)
+ {
+ if (strOutputFileName[i] == '.')
+ dot = strOutputFileName + i;
+ }
+ if (dot) {
+ switch (*(int*)dot) {
+ case '4pm.': case '4PM.': case '4pM.': case '4Pm.':
+ case 'a4m.': case 'A4M.': case 'a4M.': case 'A4m.':
+ mp4mode = 1;
+ }
+ }
I think the parameter --mp4 don't have sense, the extension controls the mode. For me OK, but we can delete the parameter.

Then, with the libmp4v2.dll, the enc_aacplus.dll make the mp4 container automatically based, I supose, only in the file extension.

If shon3i is reading this please say your opinion about the change. Do you still need the MP4MUX.exe to obtain your mp4 files?

Kurtnoise
9th October 2009, 06:46
I think the parameter --mp4 don't have sense, the extension controls the mode. For me OK, but we can delete the parameter.

I added this to control the output format through megui...that's all. You're free to add it or not.



In addition, if you use Visual Studio 2008 or higher, you can compile a SSE/SSE2 build easily.

shon3i
9th October 2009, 09:23
If shon3i is reading this please say your opinion about the change. Do you still need the MP4MUX.exe to obtain your mp4 files?Since libmp4v2.dll create 100% mp4 compilant files i don't see reason to keep both mp4mux and mp4box. mp4box is anyway huge filesize for this small encoder.

tebasuna51
9th October 2009, 12:55
Since libmp4v2.dll create 100% mp4 compilant files i don't see reason to keep both mp4mux and mp4box. mp4box is anyway huge filesize for this small encoder.
Ok, then I modify BeHappy to use also libmp4v2.dll without
mp4mux and mp4box.

And use the same enc_aacPlus.exe for MeGUI and BeHappy.

I added this to control the output format through megui...that's all. You're free to add it or not.
But MeGUI need the --mp4 parameter?
If we send a filename with extension .mp4, we need the --mp4 parameter? I think is ignored.
If we send a filename with .aac extension and --mp4 parameter, what create enc_aacPlus?

tebasuna51
10th October 2009, 02:08
@Kurtnoise
I think there are a bug in your patch.
This:
@@ -475,23 +476,18 @@
{
const char* codecSection[] = {"audio_aacplus","audio_aac","audio_aacplushigh"};
FILE * tmp = fopen(szTempName,"wt");
- fprintf(tmp, "[%s]\nsamplerate=%i\nchannelmode=%i\nbitrate=%i\nv2enable=1\nbitstream=%i\nsignallingmode=0\nspeech=0\npns=0\n", codecSection[nType] , nSampleRate, nChannelMode, nBitrate, bMPEG4AAC?5:0, bSpeech?1:0, bPNS?1:0);
+ fprintf(tmp, "[audio%s_aac%s]\nsamplerate=%u\nchannelmode=%u\nbitrate=%u\nv2enable=1\nbitstream=%i\nsignallingmode=0\nspeech=0\npns=0\n",
+ mp4mode?"_mp4":"",2==nChannelMode||nBitrate>256000||nSampleRate<32000?"":nBitrate>128000?"plushigh":"plus", nSampleRate, nChannelMode, nBitrate, bMPEG4AAC?5:0, bSpeech?1:0, bPNS?1:0);
fclose(tmp);
- const unsigned int codecFourCC[] = {mmioFOURCC('A','A','C','P'), mmioFOURCC('A','A','C','r'), mmioFOURCC('A','A','C','H')};
- unsigned int outt= codecFourCC[nType];
+ unsigned int outt = 0;
+ if (2==nChannelMode||nBitrate>256000||nSampleRate<32000)
+ outt = mp4mode ? mmioFOURCC('M','4','A',' ') : mmioFOURCC('A','A','C','r');
+ else if (nBitrate>128000)
+ outt = mp4mode ? mmioFOURCC('M','4','A','H') : mmioFOURCC('A','A','C','H');
+ else
+ outt = mp4mode ? mmioFOURCC('M','4','A','+') : mmioFOURCC('A','A','C','P');
encoder=createAudio3(nChannelCount,nSampleRate, nBitsPerSample ,mmioFOURCC('P','C','M',' '),&outt,szTempName);
DeleteFile(szTempName);
...
Make many errors like:
"Can't create encoder!"
Whit this work fine for me:
@@ -475,23 +476,18 @@
{
const char* codecSection[] = {"audio_aacplus","audio_aac","audio_aacplushigh"};
FILE * tmp = fopen(szTempName,"wt");
- fprintf(tmp, "[%s]\nsamplerate=%i\nchannelmode=%i\nbitrate=%i\nv2enable=1\nbitstream=%i\nsignallingmode=0\nspeech=0\npns=0\n", codecSection[nType] , nSampleRate, nChannelMode, nBitrate, bMPEG4AAC?5:0, bSpeech?1:0, bPNS?1:0);
+ fprintf(tmp, "[audio%s_aac%s]\nsamplerate=%u\nchannelmode=%u\nbitrate=%u\nv2enable=1\nbitstream=%i\nsignallingmode=0\nspeech=%i\npns=%i\n",
+ mp4mode?"_mp4":"",1==nType?"":2==nType?"plushigh":"plus", nSampleRate, nChannelMode, nBitrate, bMPEG4AAC?5:0, bSpeech?1:0, bPNS?1:0);
fclose(tmp);
- const unsigned int codecFourCC[] = {mmioFOURCC('A','A','C','P'), mmioFOURCC('A','A','C','r'), mmioFOURCC('A','A','C','H')};
- unsigned int outt= codecFourCC[nType];
+ unsigned int outt = 0;
+ if (1==nType)
+ outt = mp4mode ? mmioFOURCC('M','4','A',' ') : mmioFOURCC('A','A','C','r');
+ else if (2==nType)
+ outt = mp4mode ? mmioFOURCC('M','4','A','H') : mmioFOURCC('A','A','C','H');
+ else
+ outt = mp4mode ? mmioFOURCC('M','4','A','+') : mmioFOURCC('A','A','C','P');
encoder=createAudio3(nChannelCount,nSampleRate, nBitsPerSample ,mmioFOURCC('P','C','M',' '),&outt,szTempName);
DeleteFile(szTempName);
...

tebasuna51
10th October 2009, 03:00
Upload the source code to CodePlex (Change set 34537)
I have only Visual Studio Express 2005

@Kurtnoise, you are now coordinator in the project, if you agree with the source code you can compile it and upload the new release.

Thanks

Kurtnoise
10th October 2009, 17:36
http://aacpluscli.codeplex.com/Release/ProjectReleases.aspx?ReleaseId=34241#ReleaseFiles

Kurtnoise
10th October 2009, 17:36
I think there are a bug in your patch.

because not the same sources...:rolleyes:

tebasuna51
11th October 2009, 00:04
Thanks, I need change BeHappy to use the new release.

tebasuna51
12th October 2009, 11:13
New BeHappy version and full release (http://forum.doom9.org/showthread.php?p=1333836#post1333836) to support the new enc_aacplus

roozhou
15th October 2009, 12:10
Hi Kurtnoise,

Two suggestions:

1) You'd better mention it if you borrow my code.
2) I don't think SSE/SSE2 build would give you any benefit except making it inexecutable on some CPUs (e.g. K7).

Kurtnoise
15th October 2009, 13:00
1) You'd better mention it if you borrow my code.
what do you mean by that ? except output files extension checking, it's not the same code. Maybe it's you that borrowed dimzon code ? I don't see any header license...


2) I don't think SSE/SSE2 build would give you any benefit except making it inexecutable on some CPUs (e.g. K7).
SSE2 build is slightly faster on my machine.

roozhou
15th October 2009, 13:38
what do you mean by that ? except output files extension checking, it's not the same code.

That's it. I added mp4 output and extension checking in July(see logs on sf.net) and you added it in October.

Kurtnoise
15th October 2009, 16:40
Funny that you quote only this part...:rolleyes:

Anyway, I replaced your code now.