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 September 2024, 03:37   #1  |  Link
hello_hello
Registered User
 
Join Date: Mar 2011
Posts: 4,892
eac3to and audio gaps

Is there any particular incantation or sacrifice required for the newer versions of eac3to to fix gaps in the audio stream? It used to be automatic. While I'm asking, is there an official eac3to thread here I couldn't find?

I generally use MeGUI's HD Streams Extractor for this sort of thing. The eac3to log file, which was saved to the same folder as the output file, looks like this for MeGUI 2944 and eac3to 3.36. They're running in Wine on Linux but I can't imagine that would matter. I deliberately created an MKV with a large gap in the AAC audio stream (and I inserted a break in the MeGUI command line before pasting it here because horizontal scrolling is annoying).

Code:
eac3to v3.36
command line: "C:\Program Files\MeGUI\tools\eac3to\eac3to.exe" "M:\NVME1\gap.mkv"
1:"M:\NVME2\gap_T1_Video - English.mkv" 2:"M:\NVME2\gap_T2_Audio - English.aac" -progressnumbers
------------------------------------------------------------------------------
MKV, 1 video track, 1 audio track, 0:09:55, 30p /1.001
1: h264/AVC, English, 720p30 /1.001 (16:9)
2: AAC, English, 2.0 channels, 48kHz, 20ms
[v01] Extracting video track number 1...
[a02] Extracting audio track number 2...
[a02] Applying AAC delay...
[a02] A remaining delay of -1ms could not be fixed.
[v01] Muxing video to Matroska...
[a02] Creating file "M:\NVME2\gap_T2_Audio - English.aac"...
[a02] Audio has a gap of 585ms at playtime 0:03:11.  <WARNING>
[a02] Starting 2nd pass...
[a02] Extracting audio track number 2...
[a02] Applying AAC delay...
[a02] A remaining delay of -1ms could not be fixed.
[a02] Realizing AAC gaps...
[a02] Creating file "M:\NVME2\gap_T2_Audio - English.aac"...
Added fps value (30 /1.001) to MKV header.
Video track 1 contains 17798 frames.
eac3to processing took 6 seconds.
Done.
This log file was created using MeGUI 6666.2308 and eac3to 3.352. The eac3to log file playing hide and seek and seemed to find a new hiding place each time I found the old one, but MeGUI seems to be responsible for keeping the dialogue normalization so that's probably not eac3to's fault, and I assume it's not relevant to AAC anyway.

Thanks.

Code:
eac3to v3.52
command line: "C:\Program Files\MeGUI\tools\eac3to\eac3to.exe" "M:\NVME1\gap.mkv"
1:"M:\NVME2\gap_T1_Video - English.mkv" 2:"M:\NVME2\gap_T2_Audio - English.aac" -keepDialnorm -progressnumbers
------------------------------------------------------------------------------
Running in normal mode
Keeping dialnorm
MKV, 1 video track, 1 audio track, 0:09:55, 30p/1.001
1: h264/AVC, English, 720p30/1.001 (16:9)
2: AAC, English, 2.0 channels, 48kHz, dialnorm: 0dB, 20ms
[v01] Extracting video track number 1...
[a02] Extracting audio track number 2...
[a02] Applying AAC delay...
[a02] A remaining delay of -1ms could not be fixed.
[v01] Muxing video to Matroska...
[a02] Creating file "M:\NVME2\gap_T2_Audio - English.aac"...
Added fps value (30/1.001) to MKV header.
Video track 1 contains 17798 frames.
eac3to processing took 6 seconds.
Done.
I just noticed a warning in MeGUI's log file, added after eac3to finished doing it's thing.

Code:
--[Information] [16/09/2024 12:43:15 pm] a02 Creating file "M:\NVME2\gap_T2_Audio - English.aac"...                     
--[Information] [16/09/2024 12:43:21 pm] Added fps value (30/1.001) to MKV header.                                      
--[Information] [16/09/2024 12:43:21 pm] Video track 1 contains 17798 frames.                                           
--[Information] [16/09/2024 12:43:21 pm] eac3to processing took 6 seconds.                                              
--[Information] [16/09/2024 12:43:21 pm] Done.                                                                          
--[Warning] [16/09/2024 12:43:22 pm] [a02] Audio has a gap of 585ms at playtime 0:03:11.  <WARNING>
-[Information] [16/09/2024 12:43:14 pm] Standard error stream
-[Information] [16/09/2024 12:43:22 pm] Postprocessing
-[Information] [16/09/2024 12:43:22 pm] Job completed

Last edited by hello_hello; 16th September 2024 at 06:41.
hello_hello is offline   Reply With Quote
Old 16th September 2024, 09:54   #2  |  Link
tebasuna51
Moderator
 
tebasuna51's Avatar
 
Join Date: Feb 2005
Location: Spain
Posts: 7,071
Quote:
Originally Posted by hello_hello View Post
Is there any particular incantation or sacrifice required for the newer versions of eac3to to fix gaps in the audio stream?
The last reference about the automatic fix gaps was in:
Quote:
v3.36
* 2nd pass for audio gap fixing is auto-disabled for (UHD) Blu-Rays now
But for mkv must work.

Quote:
While I'm asking, is there an official eac3to thread here I couldn't find?
Now madshi let the code for new development to guys than don't want write in Doom9 forums. You can go to https://www.rationalqm.us/board/index.php

Quote:
but MeGUI seems to be responsible for keeping the dialogue normalization so that's probably not eac3to's fault, and I assume it's not relevant to AAC anyway.
Of course it is not relevant for AAC, but now eac3to read a new eac3to.ini to add default parameters, in the 3.52 package that file is:

Quote:
-fast
-keepDialnorm
-progressnumbers
But your log show "normal mode" not "fast mode" like run for me.
Check that eac3to.ini file, maybe it have a parameter "-no2ndpass" to avoid the fix gaps.
__________________
BeHappy, AviSynth audio transcoder.

Last edited by tebasuna51; 18th September 2024 at 12:43.
tebasuna51 is offline   Reply With Quote
Old 16th September 2024, 12:05   #3  |  Link
kalehrl
Registered User
 
Join Date: Feb 2011
Posts: 345
Recently I dealt with a cable capture and I didn't notice a second pass and the resulting eac3to txt log file.
That file used to be present in the past.
These are the contents of eac3to.ini file:
Code:
-fast
-keepDialnorm
-progressnumbers
kalehrl is offline   Reply With Quote
Old 16th September 2024, 14:30   #4  |  Link
hello_hello
Registered User
 
Join Date: Mar 2011
Posts: 4,892
Quote:
Originally Posted by tebasuna51 View Post
The last reference about the automatic fix gaps was in:

But for mkv must work.
Unfortunately there appears not to be a -yes2ndpass type argument to force it.

Quote:
Originally Posted by tebasuna51 View Post
Now madshi let the code for new development to guys than don't want write in Doom9 forums. You can go to https://www.rationalqm.us/eac3to/
It's odd because on paper they seem to be quite normal, yet for some reason they just can't play well with other children....

Quote:
Originally Posted by tebasuna51 View Post
Of course it is not relevant for AAC, but now eac3to read a new eac3to.ini to add default parameters, in the 3.52 package that file is:

But your log show "normal mode" not "fast mode" like run for me.
Check that eac3to.ini file, maybe it have a parameter "-no2ndpass" to avoid the fix gaps.
I had a look at the eac3to_3.52_notes.txt file again but I'd assumed eac3to.ini only supports four or five eac3to arguments and -no2ndpass didn't seem to be one of them.

I've replied to your post in the MeGUI thread.

Cheers.

Last edited by hello_hello; 16th September 2024 at 14:38.
hello_hello is offline   Reply With Quote
Old 17th September 2024, 12:08   #5  |  Link
tebasuna51
Moderator
 
tebasuna51's Avatar
 
Join Date: Feb 2005
Location: Spain
Posts: 7,071
Maybe we can continue the discussion here because is a problem only related with eac3to and not with MeGUI or HDStreamsExtractor.
If you want use the fix gaps feature you need replace only the eac3to.exe for any version before 3.40.

Using your samples in the MeGUI thread I found the version the introduce the problem:
Quote:
eac3to v3.39
command line: "C:\Portable\eac3to\eac3to.exe" "C:\tmp\1500ms.mkv" 2: "C:\tmp\1500ms.mkv_339.aac" -progressnumbers
------------------------------------------------------------------------------
MKV, 1 video track, 1 audio track, 0:01:18, 50p
1: h264/AVC, English, 1080p50 (16:9)
2: AAC, English, 2.0 channels, 48kHz, dialnorm: -0dB
[a02] Extracting audio track number 2...
[a02] Creating file "C:\tmp\1500ms.mkv_339.aac"...
[a02] Audio has a gap of 1500ms at playtime 0:00:32. <WARNING>
[a02] Starting 2nd pass...
[a02] Extracting audio track number 2...
[a02] Realizing AAC gaps...
[a02] Creating file "C:\tmp\1500ms.mkv_339.aac"...

eac3to v3.40
command line: "C:\Portable\eac3to\eac3to.exe" "C:\tmp\1500ms.mkv" 2: "C:\tmp\1500ms.mkv_340.aac" -progressnumbers
------------------------------------------------------------------------------
Running in normal mode
Removing dialnorm
MKV, 1 video track, 1 audio track, 0:01:18, 50p
1: h264/AVC, English, 1080p50 (16:9)
2: AAC, English, 2.0 channels, 48kHz, dialnorm: -0dB
[a02] Extracting audio track number 2...
[a02] Creating file "C:\tmp\1500ms.mkv_340.aac"...
I don't see any warning about gaps after v3.40

The 1500ms.mkv_340.aac is the same than the No_Gap.mkv_anyV.aac
The gap is ignored but the length is the same because the audio delayed is not cutted.

The 1500ms.mkv_339.aac have more duration than the No_Gap.mkv_anyV.aac
At 32 sec. have 1500 ms of noise. Maybe fill with noise is not correct but at least a warning is desired.

Maybe someone can report the regression in https://www.rationalqm.us/board/index.php
I can't do it.
__________________
BeHappy, AviSynth audio transcoder.

Last edited by tebasuna51; 18th September 2024 at 12:44.
tebasuna51 is offline   Reply With Quote
Old 18th September 2024, 04:48   #6  |  Link
oniiz86
Registered User
 
Join Date: Oct 2019
Posts: 66
@tebasuna51 I was just curious is there any particular reason why you can't get in touch with the eac3to development team? I believe you were "dennis" over there at the DG Tools support forum & had reported a major bug with eac3to "Still decodes 7.1 EAC3 streams as 5.1 ignoring the depending frames with the extra channels. Maybe fix with updated libav dll's (ffmpeg can't create 7.1 eac3 but decode it fine)." when they initially took over eac3to development?
oniiz86 is offline   Reply With Quote
Old 18th September 2024, 08:18   #7  |  Link
tebasuna51
Moderator
 
tebasuna51's Avatar
 
Join Date: Feb 2005
Location: Spain
Posts: 7,071
Quote:
Originally Posted by oniiz86 View Post
@tebasuna51 I was just curious is there any particular reason why you can't get in touch with the eac3to development team? I believe you were "dennis" over there at the DG Tools support forum...
The user "dennis" was canceled in that forum.
__________________
BeHappy, AviSynth audio transcoder.
tebasuna51 is offline   Reply With Quote
Old 18th September 2024, 11:35   #8  |  Link
oniiz86
Registered User
 
Join Date: Oct 2019
Posts: 66
Quote:
Originally Posted by tebasuna51 View Post
The user "dennis" was canceled in that forum.
Yes I noticed that your contributions to that forum have been removed, what I don't understand is why there was nastiness from the admin & Curly, you've always had a very helpful & positive demeanor about you?
oniiz86 is offline   Reply With Quote
Old 18th September 2024, 12:54   #9  |  Link
tebasuna51
Moderator
 
tebasuna51's Avatar
 
Join Date: Feb 2005
Location: Spain
Posts: 7,071
That admin, Curly, Rocky, Donald and eac3to_mod here, etc., are the same person with different nicks and personalities.
__________________
BeHappy, AviSynth audio transcoder.
tebasuna51 is offline   Reply With Quote
Old 19th September 2024, 06:40   #10  |  Link
hello_hello
Registered User
 
Join Date: Mar 2011
Posts: 4,892
Quote:
Originally Posted by tebasuna51 View Post
That admin, Curly, Rocky, Donald and eac3to_mod here, etc., are the same person with different nicks and personalities.
I suspected as much. Those different personalities appear to be the only ones left posting in that forum. It's obvious just looking at many of the threads that posts have been edited or removed. I don't think it's worth dealing with that sort of nonsense just to report a bug in software I rarely use, especially after the number of times I had to deal with that person's nonsense here, so I think I'll take a pass and hopefully they'll discover the problem themselves eventually.
hello_hello is offline   Reply With Quote
Old 19th September 2024, 06:58   #11  |  Link
j7n
Registered User
 
j7n's Avatar
 
Join Date: Apr 2006
Posts: 150
I thought they were DG's family members who had inherited the business. I'd keep using the version that treated the gaps as you wanted.
j7n is offline   Reply With Quote
Old 19th September 2024, 06:59   #12  |  Link
oniiz86
Registered User
 
Join Date: Oct 2019
Posts: 66
@hello_hello I had informed them of this issue over at the DG Tools forum & I was given permission by Curly regarding his response on the gap detection situation,
"The gap detection (not the seamless branching variety) was causing serious problems with seamless branching and other scenarios. That's why madshi had disabled it for UHD/bluray. After discussing things with him we decided to remove it entirely. eac3to is a highly complex application developed over many years, adding things that were not intended at the beginning and things that came along with new technologies (kudos to madshi). It has become quite difficult to maintain, especially for a stooge who did not create the original version and does not fully understand its detailed design. My intent was simply to extend its life to cover UHD/bluray in a more robust way."
oniiz86 is offline   Reply With Quote
Old 19th September 2024, 09:40   #13  |  Link
tebasuna51
Moderator
 
tebasuna51's Avatar
 
Join Date: Feb 2005
Location: Spain
Posts: 7,071
Quote:
Originally Posted by j7n View Post
... I'd keep using the version that treated the gaps as you wanted.
Yes, we can keep a old version to use it when need fix gaps (rarely).
But new versions can manage eac3 audio better, frequently used now.
__________________
BeHappy, AviSynth audio transcoder.
tebasuna51 is offline   Reply With Quote
Old 19th September 2024, 12:59   #14  |  Link
GeoffreyA
Registered User
 
Join Date: Jun 2024
Location: South Africa
Posts: 46
I know this is somewhat off the topic, but if I may ask quickly: for decoding DTS-HD MA, TrueHD, and AC3, downmixing to stereo, and piping to qaac, is there benefit to using eac3to instead of FFmpeg? In the old days, I used to use Azid to downmix and normalise AC3; and coming back to encoding years later, I went onto FFmpeg and haven't had cause for complaint.

Last edited by GeoffreyA; 19th September 2024 at 13:02.
GeoffreyA is offline   Reply With Quote
Old 20th September 2024, 07:25   #15  |  Link
Bandits
Registered User
 
Join Date: Feb 2015
Posts: 44
Quote:
Originally Posted by oniiz86 View Post
@hello_hello I had informed them of this issue over at the DG Tools forum & I was given permission by Curly regarding his response on the gap detection situation,
"The gap detection (not the seamless branching variety) was causing serious problems with seamless branching and other scenarios. That's why madshi had disabled it for UHD/bluray. After discussing things with him we decided to remove it entirely. eac3to is a highly complex application developed over many years, adding things that were not intended at the beginning and things that came along with new technologies (kudos to madshi). It has become quite difficult to maintain, especially for a stooge who did not create the original version and does not fully understand its detailed design. My intent was simply to extend its life to cover UHD/bluray in a more robust way."
It would be great if the 3.36 source that was given to DG was opened up to everyone. I still use 3.34 for 99% of my work. I only had one bug that I was hoping to be fixed, but the project is way too far down a rabbit hole now.
__________________
Blu-Ray Ripper 0.112c/0.21a
Bandits is offline   Reply With Quote
Old 20th September 2024, 09:51   #16  |  Link
tebasuna51
Moderator
 
tebasuna51's Avatar
 
Join Date: Feb 2005
Location: Spain
Posts: 7,071
Quote:
Originally Posted by GeoffreyA View Post
I know this is somewhat off the topic, but if I may ask quickly: for decoding DTS-HD MA, TrueHD, and AC3, downmixing to stereo, and piping to qaac, is there benefit to using eac3to instead of FFmpeg?...
eac3to was created to manage eac3 audio from EVO containers, after that to manage BD sources and still can be usefull to manage that with sources with many mpls, m2ts, etc.
It can solve gaps/overlaps, delays, edit, normalize, remove DN, etc. not posible or easy to manage with ffmpeg.

Of course to decode audio eac3to use old ffmpeg libraries clearly out to date, and can encode only to flac (that can be updated) and old NeroAacEnc/Aften to encode.
For that simple purpose I recommend use ffmpeg.

I use UsEac3to like GUI to analyze the container (if eac3to can't do it the button .../INF uses ffmpeg) and after use eac3to or ffmpeg (button A/V Recode).

There are others GUI's for ffmpeg and the command line can be used, not always easy.
__________________
BeHappy, AviSynth audio transcoder.
tebasuna51 is offline   Reply With Quote
Old 20th September 2024, 10:48   #17  |  Link
GeoffreyA
Registered User
 
Join Date: Jun 2024
Location: South Africa
Posts: 46
Thanks, tebasuna51. Your explanation helps me understand eac3to better: it appears to be a more specialised tool but, on the negative side, is not maintained much and is using out-of-date libraries. I gave it a try some time ago but am more at home with FFmpeg. Also, I am not doing anything particularly intricate. Mainly, decoding audio from BD sources, downmixing, and encoding with qaac. I am letting qaac normalise, since it streamlines the process. The only headache is the classic low-dialogue problem and whether to use or not to use loudnorm (or even LoRd_MuldeR's dynaudnorm).
GeoffreyA is offline   Reply With Quote
Old 23rd September 2024, 06:58   #18  |  Link
hello_hello
Registered User
 
Join Date: Mar 2011
Posts: 4,892
It kinda made me smile when I read this:

https://www.rationalqm.us/board/view...p=21085#p21085

My question is how was this MKV made and why does it have 1500 ms of missing audio? Shouldn't the pathology be fixed at the source?

EDIT: Now I see that the file was intentionally created with the large gap. Shoot yourself in the foot and then expect someone to jump through hoops to apply first aid?


Imagine if I'd posted a bug report without providing a sample to illustrate the problem. There's no way to win......
hello_hello is offline   Reply With Quote
Old 26th September 2024, 13:43   #19  |  Link
tormento
Acid fr0g
 
tormento's Avatar
 
Join Date: May 2002
Location: Italy
Posts: 2,704
It would be really nice for eac3to to support ALAC format, as it's free source since some years.

It's lossless, widely available, splittable when in MKV containers (FLAC can't) and has noclick/gaps options to customize.
__________________
@turment on Telegram
tormento is offline   Reply With Quote
Reply

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 00:59.


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