Log in

View Full Version : Aften 0.0.8 is out


Pages : [1] 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23

Kurtnoise
2nd July 2006, 18:16
Just found this at HA.org...and it sounds promizing. :)

Aften (http://sourceforge.net/projects/aften) is a simple, open-source, A/52 (AC-3) audio encoder.

The name, Aften, is an acronym for:
A / Fifty-Two ENcoder
It is also Danish and Norwegian for 'evening'.

This program started as a simple cutting-out of the AC3 encoder from FFmpeg, but then I reworked the structure of the encoder a bit. Most of the basic code is still the same though. Here are some of the things I've changed so far.

* Implemented my own wav reader and bitwise file writer
* Converted the fixed-point algorithms to floating-point
* Rearranged the methods and structures
* Added stereo rematrixing (mid/side)
* Added short block MDCT and block switching
* Added VBR encoding mode

Future Plans

* Variable bandwidth
* Channel coupling



Changelog of the last release:
* fixed piped input from FFmpeg
* added support for MPEG channel order remapping
* restructured audio input. enables raw pcm file support.
* bugfixes in MMX/SSE2 code
* stack align hack for x86 MinGW with threads
* API changes
* SIMD and threads usage is shown and is configurable
* screen output gets updated every 200ms to reduce load
* SIMD detection changed to compiler-independent inline assembly, thus nasm/yasm not needed anymore


So, I've made a compile for win32 OS and I added pipeline & 2 switches for CBR and VBR Mode. Could be great if somebody can test multichannel encoding also.

Command Line example for VBR :
aften -q 300 input.wav output.ac3

Command Line example for CBR :
aften -b 256 input.wav output.ac3

Command Line example with pipeline :
aften -q 320 - output.ac3

Wisodev's builds :: http://win32builds.sourceforge.net/aften/index.html
For whose who prefer GUIs instead of command lines, I've made a small one (http://kurtnoise.free.fr/index.php?dir=Aften/&file=AftenGUI-1.4.zip).

vmesquita
3rd July 2006, 06:03
I've tested with a 6-channel WAV produced by BeSweet from an AC3 file and it worked. However I can't tell if the channels were mapped correctly because I don't have a good home theater... :rolleyes:

vmesquita
5th July 2006, 22:39
Did a test using A test file and AC3Filter, and channel mapping is incorrect (relating to BeSweet output). :(

EDIT:
I've tried to fix this in BeSweet using this:

D:\Temp\besweet>BeSweet.exe -core( -input "D:\Temp\besweet\6ch.ac3" -output "D:\Temp\besweet\6ch.wav" -6chwav ) -azid( -o l,c,r,sl,sr,lfe)

However the switch doesn't seem to be working, or maybe the sintax is wrong.

Kurtnoise
6th July 2006, 10:20
Could you test this sample (http://kurtnoise.free.fr/Sample.ac3) please ?

This is not made with BeSweet. It's just for testing channel mapping.

tebasuna51
7th July 2006, 02:36
Could you test this sample (http://kurtnoise.free.fr/Sample.ac3) please ?

This is not made with BeSweet. It's just for testing channel mapping.
The sample seems ok.

SeeMoreDigital
7th July 2006, 14:28
Or you could try this sample (http://82.10.220.174/51_Test_Encodes/AV_Setup_Tests/AC3_6Ch_'Speaker_Test'.7z) :)

danpos
8th July 2006, 17:56
Or you could try this sample (http://82.10.220.174/51_Test_Encodes/AV_Setup_Tests/AC3_6Ch_'Speaker_Test'.7z) :)

Hi there! VMesquita had tried your sample out already (I sent it to him ;) ). BTW, it's a very usefull ac3 5.1 sample for channels mapping tests. Thanks for share it.

See you,

tebasuna51
9th July 2006, 02:49
@Kurtnoise
If you want improve the aften encoder I have two suggestions

1) To make a correct channel remapping we can replace the Int to Float routine at aften.c (line 125):
for(i=0; i<A52_FRAME_SIZE*wf.channels; i++) {
if(i < nr*wf.channels)
fwav[i] = wav[i] / 32768.0;
else
fwav[i] = 0.0;
}
With this new one:
if(wf.channels == 6) {
for(i=0; i<A52_FRAME_SIZE*6; i+=6) {
if(i < nr*6) {
fwav[i] = wav[i] / 32768.0; // FL
fwav[i+1] = wav[i+2] / 32768.0; // C
fwav[i+2] = wav[i+1] / 32768.0; // FR
fwav[i+3] = wav[i+4] / 32768.0; // SL
fwav[i+4] = wav[i+5] / 32768.0; // SR
fwav[i+5] = wav[i+3] / 32768.0; // LFE
}
else
for(j=0; j<6; j++) fwav[i+j] = 0.0;
}
}
else {
for(i=0; i<A52_FRAME_SIZE*wf.channels; i++) {
if(i < nr*wf.channels)
fwav[i] = wav[i] / 32768.0;
else
fwav[i] = 0.0;
}
}


2) New parameters, valid values and default, to be passed to output_frame_header (a52enc.c):

-c 0,1,2 Default: 0 (-3,-4.5,-6 dB) Center Mix Level
-s 0,1,2 Default: 0 (-3,-6,0 dB) Surround Mix Level
-d 0,1,2 Default: 0 (Ignored,Not,Yes) Dolby Surround Mode
-n 0..31 Default: 31 (-0..-31 dB) Dialogue normalization

vmesquita
9th July 2006, 07:12
@tebasuna51
Tested the mod and now the channels are being correctly mapped for BeSweet output :D

Kurtnoise
9th July 2006, 15:29
1) To make a correct channel remapping we can replace the Int to Float routine at aften.c
Yep...done (http://kurtnoise.free.fr/misc/aften_20060709.zip). I'll try to make a build with ICL compiler later. Maybe this should improve the speed.


2) New parameters, valid values and default, to be passed to output_frame_header (a52enc.c):

-c 0,1,2 Default: 0 (-3,-4.5,-6 dB) Center Mix Level
-s 0,1,2 Default: 0 (-3,-6,0 dB) Surround Mix Level
-d 0,1,2 Default: 0 (Ignored,Not,Yes) Dolby Surround Mode
-n 0..31 Default: 31 (-0..-31 dB) Dialogue normalization
mmh...Isn't it more useful for decoder side instead of encoder ?

vmesquita
9th July 2006, 16:13
I did a modification to add 6-WAV support. This can be useful because sometimes we want to change AC3 duration (for framerate conversions) and SoundStretch only support Mono WAVs, while BeSweet built-in SoundTouch doesn't work well in my experience. You can download sources and binary here:
http://www.vmesquita.com/files/aften_6wav.zip

tebasuna51
9th July 2006, 16:53
mmh...Isn't it more useful for decoder side instead of encoder ?
Maybe for Center Mix Level and Surround Mix Level, but this values are taken from BSI when the decoder isn't instructed with another values. At least we can put the default values proposed by Dolby:
// if ((s->acmod & 0x01) && s->acmod != 0x01) bitwriter_writebits(&s->bw, 2, 1); /* XXX -4.5 dB */
if ((s->acmod & 0x01) && s->acmod != 0x01) bitwriter_writebits(&s->bw, 2, 0); // -3 dB (Dolby default)
// if (s->acmod & 0x04) bitwriter_writebits(&s->bw, 2, 1); /* XXX -6 dB */
if (s->acmod & 0x04) bitwriter_writebits(&s->bw, 2, 0); // -3 dB (Dolby default)

The Dolby Surround Mode flag is claimed by many users because, when is played by a hardware decoder, can switch automatically to DPL mode.

The Dialogue Normalization is a important parameter in ac3 encode, you can see:
GUIDE: How To Properly Encode Dolby Digital Audio (AC3) (http://forum.doom9.org/showthread.php?t=56020)

Rockaria
9th July 2006, 21:07
Good to see the Aften is having the correct AC3 channel order from the default wav-format order.
I believe the AC3 decoders are also responsible to restore the original wav-format channel order to play or transcode.
However :
The Dolby Surround Mode flag is claimed by many users because, when is played by a hardware decoder, can switch automatically to DPL mode.
My h/w decoders(& probably many other decoders too) are auto/stereo/surround decoding mode manually selectable.
So as far as the mode is set to auto/surround, it decodes depending on the detected actual stream : AC3, DTS... | 5.1, 2.1,.., DPL II..
For an example, when I set the ac3 out mode in the FFDShow and change the mixer mode, it decodes all the 2.0 ch modes(DPL II, 2.0....) to DPL II mode(forced) automatically.

Probably only when the DD 2.0 contains the DPL mix, the ds meta info is used for some old decoders to be automatic to switch between DPL & STEREO mode.

tebasuna51
10th July 2006, 02:17
At least in this thread: BeSweet + AC3Enc: Tag generated 2.0 AC3 as "surround" if downmix was used (http://forum.doom9.org/showthread.php?t=101890) is claimed the Dolby Surround Mode flag.

I think is easy to implement, without waste resources, and why not?
I make the necessary (I hope) mods to include the four parameters in Aften_mod_sources (http://www.mytempdir.com/794544)

All parameters are optional, also when use:
aften input.wav output.ac3
is encoded CBR with 448 Kb/s for 6 channel wav or 192 Kb/s for other number of channels.

Please, if anybody can compile this sources (I don't have the appropriate compiler) I can test the result. Thanks.

Edit: @vmesquita, I can't access your links. Please use http://www.mytempdir.com/

Rockaria
10th July 2006, 03:28
Indeed, Dolby's doc contains some more :

On most equipment, the consumer can, through the product's user interface, choose the appropriate downmix for their playback system. Certain metadata parameters allow the engineer to select how the stereo downmix is constructed and which downmix is preferred, although the Lt/Rt downmix is usually the default. The downmix modes(preferred/mixed) : Lt/Rt(Yes above : DPL), Lo/Ro(No : simple stereo). If we count the DPL II, I don't know how important this tag is any more.

But I agree, reserving & setting the correct options are not wasting the space and certainly useful for certain decoders or any other uses..

vmesquita
10th July 2006, 04:53
@tebasuna51

EDIT:
I have merged the 6 wav mod with the mods you posted, added the usage to when aften is called with no arguments, and fixed a little typo in your mod. Binary and source:
http://www.mytempdir.com/794693

(I didn't test, I hope it's working correctly)

tebasuna51
10th July 2006, 09:39
@vmesquita
Thanks, but in your .rar the aften.exe is missing.

Kurtnoise
10th July 2006, 10:28
Allright...I patched tebasuna stuff and merged it with the 0.01 version.

Thanks to some improvements posted on the doom9 forum, I have done some work on Aften (http://jbr.homelinux.org/aften) today and released a new version.

http://jbr.homelinux.org/aften/aften-0.01.tar.bz2

* simple configure script
* piped input and output
* corrected 6-channel mapping
* corrected defaults for mix levels
* commandline options
* quiet mode (no console output)
* per-frame or average statistics
* big-endian support (not tested though)

I had PMed Justin to this thread. ;) Download here (http://kurtnoise.free.fr/misc/aften-0.01.zip).

vmesquita
10th July 2006, 12:28
@tebasuna51
Sorry, here is the full package:
http://www.mytempdir.com/795181

tebasuna51
10th July 2006, 18:27
@vmesquita
Thanks for your job, but maybe there are a problem because your aften.exe never finish to encode. Stoped with Ctrl-C, the first part is ok and after a long silence. The parameters are taken ok.

@kurtnoise
Your new version works fine for me. Thanks for the patch.

In firsts tests I detected:
Aften accept any wav type, but only work with 16 bit Int wav's. With 24,32 bit Int or float the resultant ac3 is unusable. With 8 bit Int Aften abort.
Accept also WAVE_FORMAT_EXTENSIBLE (16 bit Int), then the faad output can be used directly with Aften.

Tested also the pipe issue with AviSynth based Bepipe and BeHappy.

Edit: More tests (not important because isn't frequently used)

wav_3chan, acmod used 3 (L,C,R) needed remap [0,2,1], the acmod 4 (L,R,S) is not accesible (remap not needed)

wav_4chan, acmod used 6 (L,R,SL,SR) remap not needed, the acmod 5 (L,C,R,S) is not accesible (needed remap [0,2,1,3])

wav_5chan, acmod used 7 (L,C,R,SL,SR) needed remap [0,2,1,3,4] (without LFE).

Edit 2: Work also with wav > 4GB
Test with wav 4.2 GB, 6 chan, 130 min. encoded in 12 min. in a P IV 2.4GHz

vmesquita
10th July 2006, 22:10
@tebasuna51
Thanks for the test, I'll check this. I have tested with a small 6h wav and Six Waves and it seemed to work fine (with no need for ^C). I'll run more testes to try to reproduce the issue.

tebasuna51
11th July 2006, 12:23
After the test I think Aften is the best free ac3 encoder.

I want compare the options with the old reference encoder Sonic Foundry SoftEncode (in speed Aften is clearly the winner, Softencode need hours to encode a 6 chan 130 min long):

Audio service configuration
There are some more options in SoftEncode
-Audio coding mode: mode 4 (L,R,S) and mode 5 (L,C,R,S)
-Bit stream mode: other than Main audio service. Complete main
-Save frames in Intel byte order
I don't need this options.

Bit Stream
-Copyright bit
-Original bit stream
-Audio production information
Default is ok for me.

Preprocessing
-Input filtering->Digital deemphasis
-Input filtering->DC high-pass filter
-Input filtering->Bandwidth low-pass filter
-Input filtering->LFE low-pass filter
-Surround channel processing->90 degree phase shift
-Surround channel processing->3 dB atenuation
All this utilities can be applied to the wav input before the encoder process.
-Dynamic range compression (DRC):
This info must be generated be the encoder and, I think, is the more important difference between free and commercial encoders at this moment.

Conclusions
To improve Aften encoder there are two priorities for me:
-Generate DRC info. I know is not easy, and out of my knowledge, but I think is important.
-Accept 32 bit Int and Float wav's. If we have a more precise source we lose quality converting to 16 bit Int to be accepted by Aften. I can collaborate with this point if needed.

Questions
About ac3 VBR. Is compatible with avi container and DVD authoring programs?

@Kurtnoise. What is the difference between aften.exe and aften_g.exe in your last pack?

Kurtnoise
11th July 2006, 14:38
What is the difference between aften.exe and aften_g.exe in your last pack?
Honestly, I don't know...I tested both and compared bits-to-bits each results : this is the same. I hope that Justin can access as soon as possible in doom9 forum to give some answers.

Otherwise, you can post some notes here (http://www.hydrogenaudio.org/forums/index.php?showtopic=46088&pid=410652&st=0&#entry410652).

About compatibility for AVI container : I think this is the same thing like mp3 vbr.

Only worries I have come from vbr mode. Some decoders aren't able to decode/play properly this kind of files (at least on windows). With some Dshow filters like AC3 parser + AC3 filter, it works fine though.

raquete
11th July 2006, 18:40
@ Kurtnoise13
have a new aften version in the homepage
http://jbr.homelinux.org/aften/

thanks :goodpost: :goodpost:

@ tebasuna51
After the test I think Aften is the best free ac3 encoder.
good to know. ;)

ot: :stupid:
i don't know command lines.can you(anyone) please do one single "how to" ?

Kurtnoise
12th July 2006, 06:58
iirc, there are no new things in the 0.02 version compared to my 0.01 build. I'll check later because I can't access to the official website right now.

For a "How to", I gave some commands in the 1st post but I'll try to integrate this into BeLight asap.

Mug Funky
12th July 2006, 12:09
this sounds exciting... i missed the thread for a few days, but now i'll be checking regularly :)

About ac3 VBR. Is compatible with avi container and DVD authoring programs?

DVDMaestro spits out VBR (it requires CBR for the duration of each title. DVD in general is probably the same).

avi can probably handle it insofar as it handles VBR mp3 etc (kinda poorly).

about DRC info - i'm sure looking at the source for a dynamics compressor will help :) don't worry too much about the attack/release times used, as i really don't like the ones used by commercial encoders anyway (attack times are way too long usually). just remember the attack should probably vary depending on how much compression is applied - i'm not sure how decoders handle applying the gain. do they do it per block or interpolate the per-block values? my guess is they just gain each block and let the 50% overlap handle it, in which case too sudden a change would give a very strange effect of volume going down in audible increments.

all that stuff is testable though...

k, i hope at least some of that made sense :)

raquete
12th July 2006, 17:37
I'll try to integrate this into BeLight asap.
;) will be wonderful,thanks so much.

raquete
14th July 2006, 04:27
@ Kurtnoise13
I can't access to the official website right now
me too.i'm trying to open the official website for 3 days. :(
something wrong?(maybe you know about or have news)

Kurtnoise
14th July 2006, 10:32
Seems to be ok now... :) So, I uploaded 0.02 (http://kurtnoise.free.fr/misc/aften-0.02.zip). As I said previously, there are nothing new except the name of some switches which are different.


Concerning this into BeLight, my first tests show that it doesn't work properly...:s and I don't know why. I'll check out when I'll have more time.

Kurtnoise
14th July 2006, 18:42
@Tebasuna :
"aften_g" is compiled with debugging symbols. The "g" refers to the gcc option "-g". This makes debugging easier (gdb will give the file, function, and line number of an error), but the binary is larger. The "aften" binary is the same as "aften_g", but the debugging symbols are stripped so the file is smaller.

All in all, for whose who prefer GUIs instead of command lines, I've made a small one (http://kurtnoise.free.fr/misc/AftenGUI-1.0.zip). Drag&Drop is enabled. You can also have some infos by clicking in the Input Files list (Duration, Sampling-Rate, Bitrate, Channels Number). aften.exe must be in the same folder. If you have some suggests, I'm open...;)

raquete
14th July 2006, 20:04
thank you so much for the Gui Kurtnoise13,you're very cool. :cool:

raquete
15th July 2006, 18:28
Kurtnoise13,
selecting the output as "E:/temp" or any other folder,the AftenGui is saving the files in the root of the drive choosed( E:/ )

Ebobtron
16th July 2006, 05:37
Kurtnoise13

using 0.02
I suddenly have found myself working on sound features in avsFilmCutter (http://forum.doom9.org/showthread.php?t=97438) and thought I would say thanks for the find and add my 2 cents.

I encoded a 2:21:29 clip and found the overall quality to be very poor.

I used all default settings and it sounded as if it was dropping bits or the buffer had under run. The time was reported at over 10 hours.

When used with a three minute clip at a CBR of 192,000 the times reported by the player were correct and the sound improved.

Seemed like there was junk in the stream, too. Data fields from the decoder ( AC3Filter ver 1.01a_rc5 ) keep jumping.

Both were 2 channel 16 bit waves at 48000 Hz.

Nice start, sure is easy to use.
Will keep watch.

Thanks again.

Kurtnoise
16th July 2006, 10:06
@Raquete : fixed (http://kurtnoise.free.fr/index.php?dir=Aften/&file=AftenGUI-1.1.zip)...

@Elbotron : yeah, as I said previously, files encoded with vbr mode have some issues during the decoding. an AC3 parser is needed. Or AC3 decoders need to be updated to support vbr...

For the moment, CBR mode is recommended.

raquete
16th July 2006, 10:41
thank you so much . :)

why the AftenGui is not in the first post of the thread?!!!

jruggle
17th July 2006, 23:17
Ok, I can finally reply! :) To answer a few questions...

aften_g is not really different from aften in any significant way. The "aften_g" executable has debugging symbols, where "aften" does not. The size of the binary is larger for aften_g, but it is useful in finding problems in the code.

DRC is something that will be tricky to add. I do wish I had access to a good reference encoder to compare with. Maybe getting some DVD's and making a simple parser would give some clues as to how to calculate it properly.

24/32/float wav files will be supported sometime soon. It won't be that hard...I just have to rework the API a bit.

Filtering...I agree with adding a filter for LFE and DC, but not for bandwidth. That is effectively taken care of by excluding the highest MDCT coefficients. The only advantage I can see is maybe a smoother transition band.

I'm sorry that the site was down for a few days...I was out-of-town and it seems a power flicker reset my web server.

VBR and containers: As mentioned by others, it can be done in AVI the same way as with MP3. Also, I just found a place in the spec where it implies that VBR should be supported in MPEG-TS. There are two sets of bitrate codes for the audio stream descriptor. One set is for exact bit rate, while the other is for bit rate upper limit. I have gotten VBR to "work" in avi, mpeg-ps, mpeg-ts, and matroska. Decoding support will probably still be very limited though. I am really hoping that DVD players will support it. I would guess yes since most of the manufacturers probably paid for a Dolby-certified decoder so they could put the logo on the player. :)

Thanks for the GUI kurtnoise13. I don't have Windows, so could someone post a screenshot somewhere? I'm just curious. :) I might have an old version of Aften I wrote in Java lying around on my computer somewhere. If so, I could easily write a cross-platform GUI for that. For the record, I don't care much for Java when it comes to mathematical stuff because of the lack of unsigned types and pointer control, but it's wonderful for quick-n-easy graphical interfaces...and card games ;).

If I forgot anything or there are any other questions, ask away.

-Justin

jruggle
18th July 2006, 00:08
If someone wants to test this in various decoders, here is an MPEG2-PS file with VBR AC3.

http://jbr.homelinux.org/aften/right_place.mpg

-Justin

Mug Funky
18th July 2006, 04:40
I am really hoping that DVD players will support it. I would guess yes since most of the manufacturers probably paid for a Dolby-certified decoder so they could put the logo on the player

well, that came with paying for the DVD logo... and DVD doesn't support VBR ac3. i'm sure one could hack a DVD to have VBR audio, but i doubt it'd play on anything at all. there are no authoring programs that support it, so one would have to use ifoedit or similar to place the VBR stream into the movie.

it'd be an interesting test though.

raquete
18th July 2006, 05:56
I don't have Windows, so could someone post a screenshot somewhere? I'm just curious.

http://img95.imageshack.us/img95/7818/kurtaftenguito3.png

welcome jruggle ;)

Kurtnoise
18th July 2006, 06:03
why the AftenGui is not in the first post of the thread?!!!
ok..done. :)

I don't have Windows, so could someone post a screenshot somewhere? I'm just curious.
Welcome on Doom9 Justin :) . Here is a screenshot (http://img215.imageshack.us/img215/1711/captureah1.png).(edit: oups, raquete is faster than me.) I plan to make a new GUI with GTK later...;)


Radiohead is good...:D Your mpg file works fine with mplayer and some other directshow players (MPC, TCMP).

dimzon
18th July 2006, 14:56
Hmm. A will add this encoder to BeHappy ASAP

ADD:
Some 128*96 logo variations ;)
http://img405.imageshack.us/img405/3250/aftenlogosmallzc7.png

http://img405.imageshack.us/img405/6537/aftenlogosmall1vl3.png

http://img76.imageshack.us/img76/3128/aftenlogosmall2vw1.png

dimzon
19th July 2006, 01:09
Now BeHappy support it ;)
http://img232.imageshack.us/img232/274/aftenam4.png

Warning! I have no time to test it so try and report

tebasuna51
19th July 2006, 13:15
@jruggle, welcome to the forum and thanks for your answers to my questions.

In your web I read:
"Future Plans
...
More testing & better support for multi-channel
..."
Then maybe are you interested in full remapping (not only for 6 chan), with something like that (aften.c, line 333):
// Correct Channel mapping for all ch streams
int remap = 0; // 0 not needed
if(status->acmod==3 || status->acmod==5 || status->acmod==7) {
remap = 1; // needed for this acmod
channelmap(ch) ((int []){ 0, 2, 1, 4, 5, 3 })[ch] // for 6 chan. (Syntax ??)
// { 0, 2, 1, 3, 4, x } // for < 6 chan.
if(wf.channels != 6) {
channelmap(3)=3;
channelmap(4)=4;
}
}
while(nr > 0) {
if(remap == 1) {
int j;
for(i=0; i<A52_FRAME_SIZE*wf.channels; i+=wf.channels) {
if(i < nr*wf.channels) {
for(j=0; j<wf.channels; j++) {
fwav[i+j] = wav[i+channelmap(j)] / 32768.0;
}
} else {
for(j=0; j<wf.channels; j++)
fwav[i+j] = 0.0;
}
}
} else {
...
Now work also for ac3 5.0 (without LFE)

daphy
19th July 2006, 14:00
Is there any Dolby EX support (with more than 6 channels) planed :)

jruggle
20th July 2006, 01:14
Is there any Dolby EX support (with more than 6 channels) planed :)
I don't know much about Dolby EX, but from what I gather on the website and from the specs, the extra rear-center information is matrixed into the left and right surround channels and is extracted by a Dolby EX capable decoder. The only thing the AC-3 format does in this regard is flag the stream as containing a Dolby EX stream. This can be done with the alternate bit stream syntax, which is not currently supported by Aften. I'll put that on my TODO list though.

-Justin

jruggle
20th July 2006, 01:26
@jruggle, welcome to the forum and thanks for your answers to my questions.

In your web I read:
"Future Plans
...
More testing & better support for multi-channel
..."
Then maybe are you interested in full remapping (not only for 6 chan), with something like that (aften.c, line 333):

Thank you. I definitely want to support both standard wav channel remapping and also wav_format_extensible. I'll try to get this done tomorrow or Saturday, along with 32/24/float wav support...otherwise it might not be for a week or two.

-Justin

daphy
20th July 2006, 06:32
I don't know much about Dolby EX, but from what I gather on the website and from the specs, the extra rear-center information is matrixed into the left and right surround channels and is extracted by a Dolby EX capable decoder. The only thing the AC-3 format does in this regard is flag the stream as containing a Dolby EX stream. This can be done with the alternate bit stream syntax, which is not currently supported by Aften. I'll put that on my TODO list though.

-Justin

Seams to me that Aften could be the first free encoder that could do more than 6 channels :thanks:

jruggle
20th July 2006, 08:13
Hello,
Aften 0.03 has been released.
http://jbr.homelinux.org/aften/

Aften now supports 8/16/24/32/float/double for wav input.
Also, I added a more complete channel remapping.

I don't have a lot of multi-channel wav files to test with, so just let me know if I broke anything.

Thanks,
Justin

Kurtnoise
20th July 2006, 08:27
Great :)...A build (http://kurtnoise.free.fr/misc/aften-0.03.zip) for testing.

Rockaria
20th July 2006, 08:56
Wow, very fast integrations!!!!:eek:

-Dynamic range compression (DRC):
...
-Surround channel processing->90 degree phase shift
-Surround channel processing->3 dB atenuation
AFAIK, there are three places to enable the DRC : DD encoding time, DD decoding time and decoded PCM DRC solutions(AC3filter..)
I am not sure how much these DD encoding/decoding time DRC(film, music, speech...) are related : actual range alteration in encoding time or just setting the desired DRC option tag info. I hope somebody put some clarification on this...

In addition to the discrete DD 5.1 encoding, the DPL (II) encoding also might be very useful to some multi-platform users.
The (old commercial) softEncode generated perfect 90 deg shifted surrounds when I tested. So if this ffmpeg lib(or anyhow) supports this routine, I believe it can even (invert) matrix mix the DPL II PCM for any destinations : DD2.0, WAV, STDOUT...

It will also complete the purpose of the surrounds-90deg-shifts and the DS mode meta tag for the play/encoding time DPL(II) downmix.
a) play time DPL(II) downmix : the stream contains original multi channel(DD5.1)
- the encoder performs the 90 deg shift(s) on S or SL/SR
- the player performs simple stereo(Lo/Ro), DPL(Lt/Rt), DPL II downmix for a DPL(II)/stereo only-receiver.
- the player simple stereo mixer performs simple stereo downmix(Lo/Ro) for a stereo receiver.
- the player DPL downmix performs invert on S : Lt = (L, 0.707(C, LFE), -0.707S), Rt = (R, 0.707(C, LFE), 0.707S)
- the player DPL II downmix performs invert on SurroundCoefs : Lt = (L, 0.707(C, LFE), -(0.866Ls, 0.5Rs), Rt = (R, 0.707(C, LFE), (0.866Rs, 0.5Ls))
b) encoding time DPL(II) downmix : the encoder also performs the required downmix to 2ch PCM

Well, I have been looking for a 90 deg phase shift(all-pass filter) plugin for avisynth with no success. Hope Aften is going to include it for a FULL Dolby support..:)