Welcome to Doom9's Forum, THE in-place to be for everyone interested in DVD conversion.

Before you start posting please read the forum rules. By posting to this forum you agree to abide by the rules.

 

Go Back   Doom9's Forum > General > Audio encoding

Reply
 
Thread Tools Search this Thread Display Modes
Old 28th March 2008, 08:52   #4041  |  Link
FatChuang
Registered User
 
FatChuang's Avatar
 
Join Date: Feb 2003
Posts: 3
6ch to stereo downmixing mode

Recently I'm trying to downmix a 6ch mlp from DVD-A to stereo wav file for playback with common CDplayer.

eac3to is really a great tool to do so, but I think the downmixed 2ch wav with default "-down2 (Dolby Pro Logic II mode)" sounds a little weird.
Maybe I don't have a Dolby Pro Logic II decoder and thus can't recover the signal properly.

So I wonder if there is a chance to add different downmixing modes as

L = fL + (-3db)C + (-3db)sL + (-3db)LFE
R = fR + (-3db)C + (-3db)sR + (-3db)LFE

or the one used in Surcode MLP encoder:
L = (-6db)fL + (-9db)C + (-12db)sL + (-15db)LFE
R = (-6db)fR + (-9db)C + (-12db)sR + (-15db)LFE

thanks in advance

*note: the original 6ch mlp is grabbed with DVD-AExplorer, all with channel map 0,1,2,3,4,5=fL,fR,C,LFE,sL,sR
FatChuang is offline   Reply With Quote
Old 28th March 2008, 09:38   #4042  |  Link
madshi
Registered Developer
 
Join Date: Sep 2006
Posts: 8,986
Quote:
Originally Posted by azad View Post
Thanks, I'll have a look at it.

Quote:
Originally Posted by shambles View Post
here's an interesting sample: http://www.sendspace.com/file/cydiac

the audio starts as 2.0 but switches to 5.1 at frame 11. eac3to handles the whole thing as 2channel and when decoded, the length is 3 times what it should be

edit, another sample where it switches from 2.0 to 5.1, then to 2.0 and to 5.1 again: http://www.sendspace.com/file/5u7t56
eac3to does not handle such files well, I'm aware of that. But IMO it's not really possible to handle such files perfectly. If the AC3 file begins with 2.0 and then switches to 5.1 then what format should eac3to decode to? A 2.0 WAV file would be incorrect. A 5.1 WAV file would be better but still not really right. Furthermore eac3to would have to know that although it begins as 2.0 it will suddenly become 5.1 later because otherwise eac3to would begin writing a 2.0 WAV file.

Currently I'm not really planning to do anything to solve this problem. eac3to just doesn't like files which are switching essential parameters (like number of channels) in mid stream.

Quote:
Originally Posted by killa_kid View Post
When running "eac3to" in an HD-DVD (and Blu-Ray i assume) directory, with the listing of titles. Is it possible to have stream and bitrate printed somewhere on the line? I use those for a few things I do on my own and would make things a fraction easier
Unfortunately that's not possible without fully parsing every single EVO file which would cost a lot of time. eac3to prints out every bit of information about the audio/video tracks it can gather from the XPL and VTI files. But if the bitrate is not contained in these files (theoretically it could, but practically it rarely is) eac3to simply doesn't know the bitrate. But if the bitrate is contained in the XPL and/or VTI file then eac3to does print it out.

Quote:
Originally Posted by Rectal Prolapse View Post
madshi, what kind of processing or checking is done on AVC streams in eac3to? I'm wondering if eac3to can be used to check AVC video for errors (ie. corruption introduced by a bad rip).
Unfortunately eac3to does only very limited checks on video streams. Just enough to split the video streams into frames, that's it. In order to do reliable corruption checking every frame would have to be fully decoded and the decoder would have to output information about whether there's something wrong or not.

I have just 2 days ago asked the ffmpeg/libav guys to add a "frame contains corruption" flag to their decoders. That would allow eac3to to do what mpeg2repair does - on all video and audio tracks. The ffmpeg/libav guys who replied generally liked the idea. But I'm not sure if anybody is going to actually implement this feature.

Quote:
Originally Posted by BlackJack1 View Post
How to upgrade to newest version? Deleting old folder and create new one unpacking new rar or unpack new rar to old folder overwriting necessary files? Does eac3to writes some info into registry?
Nothing is written to registry at this point in time. You can just delete the old folder and unpack the new zip.

Quote:
Originally Posted by itsancho View Post
hi all & quick q.
after remuxing with TSRemux0020 (just removing some audio & subtitles streams) new *.m2ts file is playing fine with MPC, but 4 eac3to file is damaged.
So, is this caused by TSRemux0020 or...?
Yes and no. The resulting files really do contain discontinuity errors, so IMHO TsRemux does something wrong. BUT the discontinuities are not in the streams you left in the m2ts file, but they are in some other streams. The next eac3to version will check discontinuities only in streams which really contain data. This will fix the problem. (I ran into the same problem.)

Quote:
Originally Posted by FatChuang View Post
Recently I'm trying to downmix a 6ch mlp from DVD-A to stereo wav file for playback with common CDplayer.

eac3to is really a great tool to do so, but I think the downmixed 2ch wav with default "-down2 (Dolby Pro Logic II mode)" sounds a little weird.
Maybe I don't have a Dolby Pro Logic II decoder and thus can't recover the signal properly.

So I wonder if there is a chance to add different downmixing modes as

L = fL + (-3db)C + (-3db)sL + (-3db)LFE
R = fR + (-3db)C + (-3db)sR + (-3db)LFE

or the one used in Surcode MLP encoder:
L = (-6db)fL + (-9db)C + (-12db)sL + (-15db)LFE
R = (-6db)fR + (-9db)C + (-12db)sR + (-15db)LFE

thanks in advance

*note: the original 6ch mlp is grabbed with DVD-AExplorer, all with channel map 0,1,2,3,4,5=fL,fR,C,LFE,sL,sR
Generally adding further mixing modes is not difficult. However, what I don't want to do is this:

(1) add one private mixing mode for the taste of every eac3to user
(2) make the options any more complicated than they already are

Because of that I'm not sure what to do. If there are some "official" and knowingly good mixing modes apart from Dolby Pro Logic II, then I might be willing to support them. Are there?
madshi is offline   Reply With Quote
Old 28th March 2008, 09:51   #4043  |  Link
itsancho
Registered User
 
Join Date: Jan 2004
Location: Sofia, Bulgaria
Posts: 29
madshi, thank you very, very much!
itsancho is offline   Reply With Quote
Old 28th March 2008, 17:12   #4044  |  Link
deathlord
Registered User
 
Join Date: Mar 2008
Posts: 101
Hi

First of all, million thanks to madshi. Without your amazing work I might have given up on HDDVD/BD long ago.


[Edit: Problem solved (see below).]
Now I have a .ts file that gives me some trouble.
When feeding it directly to eac3to, eac3to crashes. So I remuxed it to m2ts using tsRemux. Eac3to crashes on that file aswell. But I was able to demux the video and both audio tracks with xport. The video works ok, but for either of the two eac3 tracks, eac3to says:
Code:
This track is not clean. Processing aborted.
Please clean the track with delaycut and then retry eac3to.
The xport output is:
Code:
xport Transport Stream Demuxer 1.01
program = 1, video channel = 0, audio channel = 1
Program Number = 0 (0x0000), Program Map PID = 31 (0x001f)
Program Number = 1 (0x0001), Program Map PID = 256 (0x0100)
program descriptor = 0x88, 0x04, 0x0f, 0xff, 0x84, 0xfc
program descriptor = 0x05, 0x04, 0x48, 0x44, 0x4d, 0x56
ES descriptor for stream type 0xea = 0x05, 0x05, 0x56, 0x43, 0x2d, 0x31, 0xff
Audio PID = 4352 <0x1100>, type = 0x81
ES descriptor for stream type 0x81 = 0x05, 0x04, 0x41, 0x43, 0x2d, 0x33
ES descriptor for stream type 0x81 = 0x81, 0x03, 0x10, 0xc8, 0x0f
ES descriptor for stream type 0x81 = 0x05, 0x04, 0x41, 0x43, 0x2d, 0x33
ES descriptor for stream type 0x81 = 0x81, 0x03, 0x10, 0xc8, 0x0f
Discontinuity!, pid = 256 <0x0100>, received =  2, expected =  3, at 3649
Audio Bitrate = 112000, Audio Sampling Rate = 48000
Audio Mode = 3/2, bsid = 16, bsmod = 6
First Audio PTS = 0x02e1586e
ts rate =         00d
packets for pid    0 <0x0000> = 55308, first = 1, last = 101329809
packets for pid   31 <0x001f> = 5531, first = 3, last = 101327774
packets for pid  256 <0x0100> = 55308, first = 2, last = 101329810
packets for pid 4097 <0x1001> = 55309, first = 3383, last = 101329811
packets for pid 4113 <0x1011> = 87161097, first = 4, last = 101329939
packets for pid 4352 <0x1100> = 6998759, first = 76, last = 101330065
packets for pid 4353 <0x1101> = 6998759, first = 82, last = 101330071
coded pictures = 0, video fields = 0
Ending audio to video PTS difference = 559902830 ticks, 6221142.555556 milliseco
nds
(Note: Discontinuity!, pid = 256 <0x0100>, received = 2, expected = 3, at 3649)
This happens for both audio tracks, both "at 3649".
Delaycut doesn't help, ... -info gives:
Code:
[Input info]
Bitrate=384
Actual rate=384.000000
Sampling Frec=44100
TotalFrames=10444797
Bytesperframe= 104.4898
Filesize=1091374688
FrameDuration=  2.1769
Framespersecond=459.3750
Duration=06:18:56.972
Channels mode=Single Channel (Mono)
LFE=LFE: Not present
When I run delaycut (v1.3.0.0), it seems to run forever, the filesize keeps growing way over the original size. The logfile stops after a few dozen lines.

A new attemt was remuxing the .ts to .mkv using gdsmux, then remuxing that to .m2ts with tsmuxer. (I can't use tsmuxer directly because it doesn't see the audio tracks.) The xport output then is:
Code:
xport Transport Stream Demuxer 1.01
program = 1, video channel = 0, audio channel = 2
Program Number = 0 (0x0000), Program Map PID = 31 (0x001f)
Program Number = 1 (0x0001), Program Map PID = 256 (0x0100)
program descriptor = 0x88, 0x04, 0x0f, 0xff, 0x84, 0xfc
program descriptor = 0x05, 0x04, 0x48, 0x44, 0x4d, 0x56
ES descriptor for stream type 0x81 = 0x05, 0x04, 0x41, 0x43, 0x2d, 0x33
ES descriptor for stream type 0x81 = 0x0a, 0x04, 0x75, 0x6e, 0x64, 0x00
Audio PID = 4353 <0x1101>, type = 0x81
ES descriptor for stream type 0x81 = 0x05, 0x04, 0x41, 0x43, 0x2d, 0x33
ES descriptor for stream type 0x81 = 0x0a, 0x04, 0x75, 0x6e, 0x64, 0x00
Audio Bitrate = 112000, Audio Sampling Rate = 48000
Audio Mode = 3/2, bsid = 16, bsmod = 6
First Audio PTS = 0x0337f980
ts rate = -2134967296
packets for pid    0 <0x0000> = 22887, first = 1, last = 14134331
packets for pid   31 <0x001f> = 22887, first = 3, last = 14134333
packets for pid  256 <0x0100> = 22887, first = 2, last = 14134332
packets for pid 4097 <0x1001> = 68616, first = 49, last = 14134737
packets for pid 4352 <0x1100> = 6998748, first = 50, last = 14134767
packets for pid 4353 <0x1101> = 6998748, first = 56, last = 14134773
coded pictures = 0, video fields = 0
Ending audio to video PTS difference = 613899805 ticks, 6821108.944444 milliseco
nds
(Note: no more discontinuity)
However, the behaviour of eac3to and delaycut afterwards are the same.
Edit: I have tried both fix and silence options in delaycut, doesn't seem to make a difference.

Any suggestions?
Reripping is unfortunately not an option right now...

Last edited by deathlord; 29th March 2008 at 22:11.
deathlord is offline   Reply With Quote
Old 28th March 2008, 22:25   #4045  |  Link
LessThanJake
Registered User
 
Join Date: Sep 2007
Posts: 30
Hello,
first off all, thank you for the great tool, but Iīve got two short questions concerning VC1-Streams in Blu-Ray anyway.
As far as I know it is essential to have a good basis for stable frameserving. In the past I always muxed VC1-content to Matroska via dsmux and then a second time with mkvmerge including the right timecode-file. If I got it right, eac3to could do this in one step with EVO-sources since v.2.2.0.

1. Can I simply handle m2ts-sources containing VC1 the same way as shown in the example in the first post?
(eac3to 00001.m2ts movie.mkv) or is it necessary to mux a second time with mkvmerge and the correct timecode?

2. Maybe this is a more general question, if this is undesirable in this thread please ignore it.
HD-DVD comes with a pulldown-flag in VC1. In which case do I have to strip it with "-stripPulldown" ? Is this only for lossless EVO to m2ts conversations?

Thank you.
LTJ

Please apologize my bad english, itīs not my native language.
LessThanJake is offline   Reply With Quote
Old 28th March 2008, 23:42   #4046  |  Link
nautilus7
Registered User
 
nautilus7's Avatar
 
Join Date: Jan 2006
Location: Athens, Greece
Posts: 1,501
1. One time is just fine. Though, you need mkvmerge to mux audio and subs, but without change anything to the video part.

2. If i got it correctly from madshi have said, you need it to come closer to blu-ray compatibility (it's not all that you need though). If you're muxing to .mkv it isn't something you have to do.

Welcome here!
nautilus7 is offline   Reply With Quote
Old 28th March 2008, 23:45   #4047  |  Link
azad
Registered User
 
azad's Avatar
 
Join Date: May 2002
Location: Germany
Posts: 69
Quote:
Originally Posted by LessThanJake View Post
1. Can I simply handle m2ts-sources containing VC1 the same way as shown in the example in the first post?
(eac3to 00001.m2ts movie.mkv) or is it necessary to mux a second time with mkvmerge and the correct timecode?
If you want the timestamps of the mkv to be rewritten with for example 25fps, then you just have to add the option -speedup behind the filename of the mkv and eac3to takes care of the rest. Using this method you don't have to mux the mkv a second time with mkvmerge and a timecode-file, at least when you only want to adjust the timestamps of the mkv to another framerate.

Last edited by azad; 28th March 2008 at 23:48.
azad is offline   Reply With Quote
Old 29th March 2008, 05:35   #4048  |  Link
IanD
Registered User
 
Join Date: Jun 2003
Location: Australia
Posts: 184
Quote:
Originally Posted by madshi View Post
eac3to does not handle such files well, I'm aware of that. But IMO it's not really possible to handle such files perfectly. If the AC3 file begins with 2.0 and then switches to 5.1 then what format should eac3to decode to? A 2.0 WAV file would be incorrect. A 5.1 WAV file would be better but still not really right. Furthermore eac3to would have to know that although it begins as 2.0 it will suddenly become 5.1 later because otherwise eac3to would begin writing a 2.0 WAV file.
I note that with TrueHD audio, you process as 24 bit and then later go back and determine whether it is actually 24 or 16 bit.

Could you do something similar for these changing AC3 files: that is, assume 6 channel and decode both DD2.0 and DD5.1 to 6 channel, then go back and check if the extra 4 channels are empty?
IanD is offline   Reply With Quote
Old 29th March 2008, 07:51   #4049  |  Link
Tegeril
Registered User
 
Join Date: Dec 2007
Posts: 63
Just so you know Madshi, that German audio track from Mozart - Die Zauberflote encoded just fine with -nero. So I guess libav is to blame. Though I ended up scrapping the encode, because after 230000 frames, I realized I forgot to tell it to deinterlace since it is 1080i content; I used the framecount from evodemux and it was short about 60000 frames; adding a .srt file to my MKV started having WMP asking for xvidcore.dll; and it seemed the audio was out of sync significantly. As in, I couldn't even tell what scene I was hearing because it was nowhere in the vicinity of the video (even at the beginning).

So I scrapped that movie as a conversion entirely

Thanks for continuing to answer my - and others' - questions!
Tegeril is offline   Reply With Quote
Old 29th March 2008, 14:09   #4050  |  Link
Greif
Registered User
 
Join Date: Dec 2006
Location: Ontario, Canada
Posts: 227
are chapters supported in the current build of eac3to?

BTW, madshi, thanks for all the hard work!
Greif is offline   Reply With Quote
Old 29th March 2008, 15:37   #4051  |  Link
LessThanJake
Registered User
 
Join Date: Sep 2007
Posts: 30
Quote:
Originally Posted by azad View Post
If you want the timestamps of the mkv to be rewritten with for example 25fps, then you just have to add the option -speedup behind the filename of the mkv and eac3to takes care of the rest. Using this method you don't have to mux the mkv a second time with mkvmerge and a timecode-file, at least when you only want to adjust the timestamps of the mkv to another framerate.
No, I donīt want to do any framerate conversations. I just want to feel confident that there are timecode-stamps at 23.976 fps, when using eac3to. After using dsmux there are no timestamps at all. Everything is looking good now. Thank you, nautilus7 / azad.

greets
LTJ
LessThanJake is offline   Reply With Quote
Old 29th March 2008, 16:46   #4052  |  Link
madshi
Registered Developer
 
Join Date: Sep 2006
Posts: 8,986
Quote:
Originally Posted by deathlord View Post
Now I have a .ts file that gives me some trouble.
Damaged source files are not really supported by eac3to at all. Of course I could spend time on making them work more or less well. But I prefer spending my time on improving support for clean sources. Personally, I'm trashing any damaged source, anyway.

Quote:
Originally Posted by IanD View Post
I note that with TrueHD audio, you process as 24 bit and then later go back and determine whether it is actually 24 or 16 bit.

Could you do something similar for these changing AC3 files: that is, assume 6 channel and decode both DD2.0 and DD5.1 to 6 channel, then go back and check if the extra 4 channels are empty?
That would be possible, but it would slow down performance. Now the same is true for the TrueHD logic you're mentioning. But for TrueHD eac3to cannot know the bitdepth. So the logic is useful for every single TrueHD track. While with AC3 files the great majority of files doesn't change channel number in the midst of the stream. So slowing down performance just to make one out of a hundred AC3 files work better is not really a good option IMO.

I might make the already existing option "-6" work for AC3 streams sooner or later, if a stereo AC3 file is detected by eac3to to force eac3to to handle the whole file as 5.1. That might do the trick for your situation. But honestly there are more important things I have on my to do list which have a much higher priority for me right now.

Quote:
Originally Posted by Greif View Post
are chapters supported in the current build of eac3to?
Not yet.

Quote:
Originally Posted by LessThanJake View Post
I just want to feel confident that there are timecode-stamps at 23.976 fps, when using eac3to.
eac3to writes very exact 23.976 timecodes (if the source is 23.976). So no need to rewrite the timestamps with mkvtoolnix.
madshi is offline   Reply With Quote
Old 29th March 2008, 17:06   #4053  |  Link
deathlord
Registered User
 
Join Date: Mar 2008
Posts: 101
Quote:
But I prefer spending my time on improving support for clean sources.
I agree. Never mind.
deathlord is offline   Reply With Quote
Old 29th March 2008, 19:57   #4054  |  Link
Wunlow
Registered User
 
Join Date: Apr 2005
Posts: 3
Would it be possible to include DPL-1 or DPL-2 decoding from AC-3 2.0 surround sources? If that would be a huge burden to consider, please disregard. ..I was just thinking it would be nice to have "one stop shopping" for all of my AC-3 needs.
Wunlow is offline   Reply With Quote
Old 29th March 2008, 20:07   #4055  |  Link
madshi
Registered Developer
 
Join Date: Sep 2006
Posts: 8,986
Quote:
Originally Posted by Wunlow View Post
Would it be possible to include DPL-1 or DPL-2 decoding from AC-3 2.0 surround sources?
I don't know how to do that.
madshi is offline   Reply With Quote
Old 29th March 2008, 21:59   #4056  |  Link
killa_kid
Registered User
 
Join Date: Aug 2007
Posts: 39
Quote:
Originally Posted by madshi View Post
Unfortunately that's not possible without fully parsing every single EVO file which would cost a lot of time. eac3to prints out every bit of information about the audio/video tracks it can gather from the XPL and VTI files. But if the bitrate is not contained in these files (theoretically it could, but practically it rarely is) eac3to simply doesn't know the bitrate. But if the bitrate is contained in the XPL and/or VTI file then eac3to does print it out.
I was wondering if that was the case. Thanks for letting me know. I guess I'll just have to deal with a 2 step process in most cases them
killa_kid is offline   Reply With Quote
Old 29th March 2008, 22:19   #4057  |  Link
deathlord
Registered User
 
Join Date: Mar 2008
Posts: 101
It appears file extensions matter for delaycut
Now it worked in eac3to.
Sorry for troubling you.

Quote:
Originally Posted by madshi View Post
I don't know how to do that.
You could probably use cyberlink audio decoder, it works in graphedit. But this decoder is very picky in accepting input (worse than eac3to;-)), so it might not be easy.
deathlord is offline   Reply With Quote
Old 30th March 2008, 02:47   #4058  |  Link
nautilus7
Registered User
 
nautilus7's Avatar
 
Join Date: Jan 2006
Location: Athens, Greece
Posts: 1,501
I get the error message below with this m2ts file.

Code:
eac3to v2.35
command line: eac3to 00000.m2ts
------------------------------------------------------------------------------
This track is not clean. Processing aborted.
Please clean the track with delaycut and then retry eac3to.
M2TS, 1 video track
1: h264/AVC, 1080i60 /1.001 (16:9)
Since it's .m2ts, i don't think delaycut can do anything...
nautilus7 is offline   Reply With Quote
Old 30th March 2008, 13:29   #4059  |  Link
madshi
Registered Developer
 
Join Date: Sep 2006
Posts: 8,986
Quote:
Originally Posted by azad View Post
eac3to seems to read out the wrong audiotrack using m2ts files.

Take a look at this:

Code:
C:\HD Assets>C:\eac3to\eac3to.exe E:\BDMV\STREAM\00001.m2ts 1: "F:\filename.mkv" 4: "F:\filename.dts" -768 -speedup
M2TS, 1 video track, 4 audio tracks
1: h264/AVC, 1080p24 /1.001 (16:9)
2: DTS Master Audio, 5.1 channels, 24 bits, 48khz
3: DTS, 5.1 channels, 24 bits, 768kbit/s, 48khz
4: DTS, 5.1 channels, 24 bits, 768kbit/s, 48khz
5: AC3, 2.0 channels, 224kbit/s, 48khz, dialnorm: -27dB
Extracting primary video track...
Extracting audio track number 4...
Decoding with DirectShow (Sonic Audio Decoder)...
Muxing video to Matroska...
Find sync word: 7ffe8001
Find sync extension: 3f
DirectShow reports 2.0 channels, 24 bits, 48khz
Applying PAL speedup...
The channel modder was started with incorrect parameters.
The channel modder didn't receive the format information.
The channel modder didn't receive the format information.
The channel modder didn't receive the format information.
As you can see, actually I wanted to extract track 4, DTS 5.1. But eac3to extracted track 5
I've tested this with the sample you uploaded. It works for me!! eac3to does extract the right track. I think that the Sonic decoder doesn't work properly on your PC. It outputs 2.0 only although the DTS track is 5.1. This is the cause of the problem. Please try "eac3to -test". What does that say?
madshi is offline   Reply With Quote
Old 30th March 2008, 13:32   #4060  |  Link
madshi
Registered Developer
 
Join Date: Sep 2006
Posts: 8,986
Quote:
Originally Posted by nautilus7 View Post
I get the error message below with this m2ts file.

Code:
eac3to v2.35
command line: eac3to 00000.m2ts
------------------------------------------------------------------------------
This track is not clean. Processing aborted.
Please clean the track with delaycut and then retry eac3to.
M2TS, 1 video track
1: h264/AVC, 1080i60 /1.001 (16:9)
Since it's .m2ts, i don't think delaycut can do anything...
Maybe I could add support for demuxing damaged streams without doing any other processing on them besides demuxing. But that's not high on priority list. The source file seems to be damaged. And my main concern are clean source files.
madshi is offline   Reply With Quote
Reply

Tags
eac3to

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT +1. The time now is 05:17.


Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2017, vBulletin Solutions Inc.