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 16th August 2010, 09:21   #10441  |  Link
madshi
Registered Developer
 
Join Date: Sep 2006
Posts: 9,137
Quote:
Originally Posted by jj666 View Post
However, I found that demuxing a .DTSHD file introduced a 21ms delay to the file.

I verified by demuxing the original WAV, demuxing the encoded WAV with DTS Stream Player (both matched perfectly) and demuxing with EAC3TO (+21ms added). Waveforms were checked with Adobe Audition.

FYI, before EAC3TO added this functionality, I was demuxing the .DTSHD files with TSMUXER, TSMUXER mentioned "bad frame found, resycning stream" - this also introduced the same +21ms delay.
I think the delay is probably caused by the encoder. The "demuxing" (= removal of added DTS-HD header structure) should not have any effect on the audio data or the delay.
madshi is offline   Reply With Quote
Old 16th August 2010, 12:36   #10442  |  Link
Thunderbolt8
Registered User
 
Join Date: Sep 2006
Posts: 2,171
yes, seems like it. did a waveform comparison of the center channel of

blu-ray source -> flac -> wavs and
blu-ray source -> demuxed dtsma -> flac -> wavs

and both are exactly the same with no delay.
Thunderbolt8 is offline   Reply With Quote
Old 16th August 2010, 12:45   #10443  |  Link
tebasuna51
Moderator
 
tebasuna51's Avatar
 
Join Date: Feb 2005
Location: Spain
Posts: 5,702
Thanks madshi.

Very good fixes.
__________________
BeHappy, AviSynth audio transcoder, in Doom9 forums. NicAudio, BassAudio, audio decoders.
tebasuna51 is offline   Reply With Quote
Old 16th August 2010, 12:46   #10444  |  Link
madshi
Registered Developer
 
Join Date: Sep 2006
Posts: 9,137
Pleasure...
madshi is offline   Reply With Quote
Old 16th August 2010, 14:14   #10445  |  Link
ACrowley
Registered User
 
Join Date: Apr 2006
Posts: 1,008
* added reading support for DTS tracks with additional DTS-HD header

Thank you A restore/add additional DTSHD Header Function would complete it
ACrowley is offline   Reply With Quote
Old 16th August 2010, 15:20   #10446  |  Link
madshi
Registered Developer
 
Join Date: Sep 2006
Posts: 9,137
Quote:
Originally Posted by ACrowley View Post
A restore/add additional DTSHD Header Function would complete it
Not going to happen, at least not anytime soon. There's no specification about how the headers need to look like and there are lot of fields in there that need to be filled (e.g. sampling rate etc). I'm not going to write guessed headers. That would only open up a can of worms. A lot of follow up bugs would probably show up, and I neither have the fun nor the time to spend week after week trying to do all the necessary bugfixes...
madshi is offline   Reply With Quote
Old 16th August 2010, 16:54   #10447  |  Link
AnryV
Registered User
 
Join Date: Jun 2007
Posts: 42
Quote:
Originally Posted by madshi View Post
I've checked this and all decoders output the same volume - even libav which definitely doesn't do dialnorm processing for DTS when eac3to removes it from the headers. I believe that the volume was already changed (hard coded) by the DTS encoder. And I believe that ArcSoft totally ignores the dialnorm when decoding.

One key information is that decoding the track with ArcSoft and Sonic decoders output bit perfect identically results. Which means that decoding should be lossless which would not be the case if dialnorm processing was active.


eac3to -test
eac3to (v3.22) is installed
Nero Audio Decoder (Nero 7) works fine
ArcSoft DTS Decoder (1.1.0.1) works fine
Sonic Audio Decoder (4.3.0.169) works fine
Haali Matroska Muxer (2009-01-11) is installed
Nero AAC Encoder (1.3.3.0) is installed
Surcode DTS Encoder (1.0.29.0) is installed
MkvToolnix (2.9.9.0, release version) is installed
AnryV is offline   Reply With Quote
Old 16th August 2010, 17:01   #10448  |  Link
jj666
Registered User
 
Join Date: May 2003
Posts: 153
Quote:
Originally Posted by Thunderbolt8 View Post
yes, seems like it. did a waveform comparison of the center channel of

blu-ray source -> flac -> wavs and
blu-ray source -> demuxed dtsma -> flac -> wavs

and both are exactly the same with no delay.
That right, but that wasn't anything at all to do with my question.

Cheers,

-jj-
jj666 is offline   Reply With Quote
Old 16th August 2010, 17:06   #10449  |  Link
jj666
Registered User
 
Join Date: May 2003
Posts: 153
Quote:
Originally Posted by madshi View Post
I think the delay is probably caused by the encoder. The "demuxing" (= removal of added DTS-HD header structure) should not have any effect on the audio data or the delay.
Process:
- I demuxed a two channel .WAV and encoded to DTS-HD MA.
- Demuxing (or rather splitting the outputted .DTSHD) to individual .WAVs with DTS StreamPlayer results in an identical to
original source file when compared to original in Adobe Audition.
- Demuxing (or rather splitting the outputted .DTSHD) to individual .WAVs with EAC3TO results in an file with +21ms delay when compared to original in Adobe Audition.

Cheers,

-jj-

Last edited by jj666; 16th August 2010 at 17:10.
jj666 is offline   Reply With Quote
Old 16th August 2010, 17:11   #10450  |  Link
madshi
Registered Developer
 
Join Date: Sep 2006
Posts: 9,137
Quote:
Originally Posted by AnryV View Post
You're right, my fault, must have made a mistake when testing. I've now done some more checks. The problem is that whenever I try to manipulate the DTS-HD headers, the ArcSoft DTS decoder seems to ignore the DTS-HD information. I guess that there's a CRC somewhere in the headers which I'd need to update, but I don't know where it is nor how to update it. So it seems that my hands are tied here.

Ergo: If you have a DTS-HD track with dialnorm in it, ArcSoft will honor the dialnorm, while Sonic ignores it. Nothing I can do about it, it seems. Fortunately DTS tracks with dialnorm in it seem to be pretty rare...
madshi is offline   Reply With Quote
Old 16th August 2010, 17:15   #10451  |  Link
madshi
Registered Developer
 
Join Date: Sep 2006
Posts: 9,137
Quote:
Originally Posted by jj666 View Post
Process:
- I demuxed a two channel .WAV and encoded to DTS-HD MA.
- Demuxing (or rather splitting the outputted .DTSHD) to individual .WAVs with DTS StreamPlayer results in an identical to
original source file when compared to original in Adobe Audition.
- Demuxing (or rather splitting the outputted .DTSHD) to individual .WAVs with EAC3TO results in an file with +21ms delay when compared to original in Adobe Audition.
Then I can only guess that there's additional information in the DTSHD header which tells the decoder to cut off 21ms from the beginning of the track. 21ms should be exactly 2 DTS frames. Or maybe the DTS StreamPlayer always cuts off 2 DTS frames? I've no idea. What I can say is that eac3to is not doing anything fancy, it just strips of the DTSHD header and feeds the DTS frames to the ArcSoft decoder. As far as I can see, eac3to is doing exactly the right thing.

Of course I could add extra processing to eac3to to always ignore the first 2 DTS frames when there's a DTSHD header, but then who guarantees us that it's always 2 frames? Maybe sometimes it's only 1 frame or 3 frames?
madshi is offline   Reply With Quote
Old 16th August 2010, 17:21   #10452  |  Link
jj666
Registered User
 
Join Date: May 2003
Posts: 153
In my experience encoding LPCM (2.0 and 5.1) to DTS-HD MA, it's always 21ms (as mentioned in the past, I demuxed first with TSMUXER to remove header, then processed with EAC3TO). That's probably around 100 encodings and all waveform checked with Adobe Audition (and 21ms removed after with EAC3TO).

That's my experience, but like you said there may be certain circumstances where this is different. I would humbly request that the 21ms be automatically removed to save me a step in my process, but that's up to you :-) What I can say is that I will report back if I ever see sync issues different to 21ms :-)

Cheers,

-jj-
jj666 is offline   Reply With Quote
Old 16th August 2010, 17:33   #10453  |  Link
madshi
Registered Developer
 
Join Date: Sep 2006
Posts: 9,137
Ok, so should I only ignore the first 2 frames when there's a DTSHD header? When there's no such header, I should not cut off 2 frames?

Can you please try "eac3to source.dts dest.wavs -21ms" to check whether the WAV files are then perfectly identical to the DTS StreamPlayer output?
madshi is offline   Reply With Quote
Old 16th August 2010, 20:01   #10454  |  Link
jj666
Registered User
 
Join Date: May 2003
Posts: 153
Hello Madshi,

Thanks for your quick reply. Yes, its less than a millisecond out. I took the liberty of making some samples for you:-

DTS-HD (60mb): http://www.mediafire.com/?49x9zs9up9uhvh9
DTS StreamPlayer demuxed left channel (30mb): http://www.mediafire.com/?gfmwkaa4pqhmea4
EAC3TO -21ms demuxed left channel (30mb): http://www.mediafire.com/?88484ugdeiehbzz
EAC3TO demuxed left channel (30mb): http://www.mediafire.com/?36y5labf5uqw1vf

Audition (same file order):



Let me know in case you need any more info. As mentioned, this sync issue does not apply to a straightforward demux from a Blu-ray, it's only happening where the DTS-HD contains the header information.

Cheers,

-jj-
jj666 is offline   Reply With Quote
Old 16th August 2010, 20:28   #10455  |  Link
Thunderbolt8
Registered User
 
Join Date: Sep 2006
Posts: 2,171
is there possibly a very small bug with the red colour of "the format of the source file could not be detected"?

doesnt seem to appear normally, but I did "eac3to movie.htm movie.srt > moviefinal.srt" (basically I accidently used eac3to command instead of srtmaker.exe, that small file to combine OCR'ed subs (timestamps + spoken text)) and then after that sentence above, the path "X:\" also had that red background colour and every line after as well.

srtmaker.exe in order to reproduce: http://www.mediafire.com/?zzqihdc5p11bkjn

Last edited by Thunderbolt8; 16th August 2010 at 20:31.
Thunderbolt8 is offline   Reply With Quote
Old 16th August 2010, 23:20   #10456  |  Link
rapscallion
NY Frame of Mind
 
rapscallion's Avatar
 
Join Date: Dec 2005
Location: L.I.,NY
Posts: 586
Re Nero ac3 drc removal and libav questions

Quote:
Originally Posted by Abradoks View Post
Here they are.
SNR:
out.10N.nero.L.wav 27.386 dB
out.10N.libav.L.wav 27.411 dB
out.10S.nero.L.wav 5.5173 dB
out.10S.libav.L.wav 27.398 dB
tartak wrote on another forum, that with nero decoder DRC is only partially ignored: volume increasing still applies, while attenuation is ignored.
Goal is to decode Dolby/TrueHd 5.1 to wavs.

From several previous posts, it was stated that Nero decoder doesn't handle drc removal properly. An example was given, as a comparison to libav, that the snr was substantially different. Is this really true and, if so, why was their no problem all the time that this was considered a "fine" decoder.
(still is in madshi's first post of the thread)

No other user has mentioned problems with either the audio quality or the snr of Nero since the beginning of this thread 3 years ago.
A google search doesn't reveal the CompAudio program used to measure the outputs. Anyone know where to find it or does it go by a different name ?

When using Nero (in eac3to_more gui) the dialog box states that drc is being disabled, however when using libav no such msg. Is libav removing drc or not ?

Separate curiousity question :

Blue Thunder contains both a ac3 and THD track. Why is it that the THD track is 16bit (24 bit padded) and yet the ac3 track is 24 bit (eac3to reduces from 64 to 24)? Logic would indicate that it should be just the opposite.

When decoding these tracks to wavs, the HD tracks result in ~600mb files and the ac3 tracks to ~900mb files. Again, seems like it should be just the opposite or is the size the resullt of the different bit depths.

This is starting to make my head hurt !
__________________
"Talk to me Goose"
rapscallion is offline   Reply With Quote
Old 17th August 2010, 00:35   #10457  |  Link
Thunderbolt8
Registered User
 
Join Date: Sep 2006
Posts: 2,171
there was some talk that lossy tracks dont have a real bitdepth or something like that, so just ignore the 24-bit.
Thunderbolt8 is offline   Reply With Quote
Old 17th August 2010, 01:07   #10458  |  Link
rik1138
Registered User
 
Join Date: Mar 2008
Location: LA
Posts: 602
Quote:
Originally Posted by Thunderbolt8 View Post
well, I dont have a HD receiver yet, so I wouldnt know if I needed it but if I had to redo something then I'd like to have done that by the time I have that kind of receiver, thats why I ask.
It only affects DTS-HD files created by the DTS Encoder (before they've been used on a Blu-ray disc). If you are only demuxing from existing discs, it has no affect on you.

Madshi- Thanks so much for adding this! Saves me the hassle of having to remove the headers when I need to convert files!
rik1138 is offline   Reply With Quote
Old 17th August 2010, 01:47   #10459  |  Link
Abradoks
Registered User
 
Join Date: Mar 2008
Posts: 71
Quote:
Originally Posted by rapscallion View Post
No other user has mentioned problems with either the audio quality or the snr of Nero since the beginning of this thread 3 years ago.
madshi has already tried to fix it.
Quote:
Originally Posted by rapscallion View Post
A google search doesn't reveal the CompAudio program used to measure the outputs. Anyone know where to find it or does it go by a different name ?
Actually first link in google. It's part of AFsp package.
BTW, you can use any other tool to compute SNR.
Quote:
Originally Posted by rapscallion View Post
Is libav removing drc or not ?
Yes, it doesn't apply DRC by default.
Abradoks is offline   Reply With Quote
Old 17th August 2010, 22:16   #10460  |  Link
rapscallion
NY Frame of Mind
 
rapscallion's Avatar
 
Join Date: Dec 2005
Location: L.I.,NY
Posts: 586
Quote:
Originally Posted by Abradoks View Post
madshi has already tried to fix it.
Yes, I saw his post but didn't think it was an eac3to issue, but a Nero issue.
Isn't it the Nero decoder that's removing/disabling drc?

Or am I misunderstanding how the decoder processes the stream to wavs ?

Quote:
Originally Posted by Abradoks View Post
Actually first link in google. It's part of AFsp package.
BTW, you can use any other tool to compute SNR.
Thanks, however I actually saw that link but didn't see anywhere to download the file, just an explanation of what it does. Am I missing something ?
Quote:
Originally Posted by Abradoks View Post
Yes, it doesn't apply DRC by default.
By "apply" do you mean it removes it when decoding an ac3 track? Because that's what I'm looking for the decoder to do.
__________________
"Talk to me Goose"

Last edited by rapscallion; 17th August 2010 at 22:21.
rapscallion 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 22:46.


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