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. |
6th August 2022, 00:44 | #141 | Link | |
Moderator
Join Date: Feb 2005
Location: Spain
Posts: 6,915
|
Quote:
There are filters like 'night mode' than can do the job on the fly over any codec. For that ffmpeg not need at all create those unnecesary DRC metadata.
__________________
BeHappy, AviSynth audio transcoder. |
|
7th August 2022, 16:17 | #142 | Link |
Registered User
Join Date: Feb 2020
Posts: 541
|
Yes, but there is no way to tell that before decoding, okay? The metadata is not there, which means you should decode always to 24 bits. The variant of TrueHD called MLP does have such metadata.
Last edited by Balling; 8th August 2022 at 00:03. |
11th August 2022, 01:09 | #143 | Link | |
Registered User
Join Date: Mar 2014
Location: Hungary
Posts: 115
|
Quote:
Code:
deew 2.6.0: - changed default DRC to music_light, which is closer to the missing none preset: https://forum.doom9.org/showpost.php?p=1972689&postcount=136 - fixed DRC option not being applied for stereo TrueHD encodes - colorized argparse's help a little bit - renamed -t/--threads to -in/--instances to be more accurate, since one DEE instance can use 2 threads. see -h for more info |
|
12th August 2022, 11:31 | #144 | Link | |
Moderator
Join Date: Feb 2005
Location: Spain
Posts: 6,915
|
Quote:
Each frame have 6 Audio Blocks (point 5.2 in pdf) and for each Audio Block there are the DRC values (7.7): "The bit code of ‘0000 0000’ indicates 0 dB (unity) gain" You must replace by 0's in each Audio Block in each audio frame, the problem is locate these bits. You must know the size of bsi (5.3) and the audblk syntax (5.4.3)
__________________
BeHappy, AviSynth audio transcoder. |
|
16th August 2022, 00:05 | #147 | Link | |
Registered User
Join Date: Apr 2022
Posts: 28
|
Quote:
I don't understand enough about how .sh scripts work to properly re-write it for Windows (bc I don't know what it's doing most of the time) but I was able to somewhat successfully run this under msys2 in Windows with some re-writes. The access to out.txt is still throwing "safe_fopen: CreateFileW failed: 2" errors, but it does seem to work. With the "| tee" to out.txt still included in the thd/dts functions, it was halting the encode after a few seconds (a few minutes of output). Without them, it finishes the encode, although the time-left function is now buggered. Code:
frame= 0 fps=0.0 q=-1.0 size= 285755kB time=00:05:52.67 bitrate=6637.6kbits/ safe_fopen: CreateFileW failed: 2 safe_fopen: CreateFileW failed: 2 safe_fopen: CreateFileW failed: 2 frame= 0 fps=0.0 q=-1.0 Lsize= 296962kB time=00:05:53.69 bitrate=6878.0kbits/s speed=4.94x Terminating EasyAudioEncoder... Terminated Required ??? folder structure: Code:
\\AudioTool\audiotool.sh \\AudioTool\audiotool.win.sh \\AudioTool\Codecs\367b3d4-3654-windows-x86\aac_decoder.dll snip \\AudioTool\Codecs\367b3d4-3654-windows-x86\wmv3_decoder.dll \\AudioTool\Codecs\ffmpeg.exe \\AudioTool\Codecs\ffprobe.exe \\AudioTool\Encoder\eae-license.txt \\AudioTool\Encoder\EasyAudioEncoder.exe \\AudioTool\Encoder\ffmpeg.exe \\AudioTool\Encoder\ffprobe.exe \\AudioTool\Encoder\Windows\avcodec-58.dll \\AudioTool\Encoder\Windows\avfilter-7.dll \\AudioTool\Encoder\Windows\avformat-58.dll \\AudioTool\Encoder\Windows\avutil-56.dll \\AudioTool\Encoder\Windows\cyggcc_s-1.dll \\AudioTool\Encoder\Windows\cygwin1.dll \\AudioTool\Encoder\Windows\fmt.dll \\AudioTool\Encoder\Windows\Plex Transcoder.exe \\AudioTool\Encoder\Windows\swresample-3.dll \\AudioTool\Encoder\Windows\swscale-5.dll \\AudioTool\ffmpeg.exe \\AudioTool\ffprobe.exe \\AudioTool\README.md |
|
16th August 2022, 02:21 | #148 | Link | |||
Registered User
Join Date: Apr 2022
Posts: 28
|
PSA to anyone using Plex Transcoder/EasyAudioEncoder - Plex's ffmpeg implementation / DCA decoder are not decoding DTS-HD MA 7.1. If I were a betting man, I would bet they're decoding the core DTS 5.1 audio. I can double check to confirm with a "known" decode of the core DTS track using eac3to and then comparing the PCM data, but given that EAE seems to be applying some unwanted DRC, I doubt I'll bother. My university copy of Audition 2015.2 still seems to work even though it complains about a serial number.
Q:\AudioTool\Encoder\Windows>"Plex Transcoder.exe" -c:v:0 h264 -c:a:0 dca -noaccurate_seek -analyzeduration 20000000 -probesize 20000000 -i "Q:\AudioTool\Hawaiian.Vacation.2011.mkv" -c:a pcm_s24le -vn -sn -avoid_negative_ts disabled -hide_banner -start_at_zero -stats -v debug "Q:\AudioTool\Hawaiian.Vacation.2011.out.mkv" Code:
Splitting the commandline. Reading option '-c:v:0' ... matched as option 'c' (codec name) with argument 'h264'. Reading option '-c:a:0' ... matched as option 'c' (codec name) with argument 'dca'. Reading option '-noaccurate_seek' ...Rescanning for external libs: 'Q:/AudioTool/Codecs/367b3d4-3654-windows-x86/' Loading external lib Q Error loading external lib: The specified module could not be found. Loading external lib /AudioTool/Codecs/367b3d4-3654-windows-x86/aac_decoder.dll /snip/ Loading external lib /AudioTool/Codecs/367b3d4-3654-windows-x86/wmv3_decoder.dll matched as option 'accurate_seek' (enable/disable accurate seeking with -ss) with argument 0. Reading option '-analyzeduration' ... matched as AVOption 'analyzeduration' with argument '20000000'. Reading option '-probesize' ... matched as AVOption 'probesize' with argument '20000000'. Reading option '-i' ... matched as input url with argument 'Q:\AudioTool\Hawaiian.Vacation.2011.mkv'. Reading option '-c:a' ... matched as option 'c' (codec name) with argument 'pcm_s24le'. Reading option '-vn' ... matched as option 'vn' (disable video) with argument '1'. Reading option '-sn' ... matched as option 'sn' (disable subtitle) with argument '1'. Reading option '-avoid_negative_ts' ... matched as AVOption 'avoid_negative_ts' with argument 'disabled'. Reading option '-hide_banner' ... matched as option 'hide_banner' (do not show program banner) with argument '1'. Reading option '-start_at_zero' ... matched as option 'start_at_zero' (shift input timestamps to start at 0 when using copyts) with argument '1'. Reading option '-stats' ... matched as option 'stats' (print progress report during encoding) with argument '1'. Reading option '-v' ... matched as option 'v' (set logging level) with argument 'debug'. Reading option 'Q:\AudioTool\Hawaiian.Vacation.2011.out.mkv' ... matched as output url. Finished splitting the commandline. Parsing a group of options: global . Applying option hide_banner (do not show program banner) with argument 1. Applying option start_at_zero (shift input timestamps to start at 0 when using copyts) with argument 1. Applying option stats (print progress report during encoding) with argument 1. Applying option v (set logging level) with argument debug. Successfully parsed a group of options. Parsing a group of options: input url Q:\AudioTool\Hawaiian.Vacation.2011.mkv. Applying option c:v:0 (codec name) with argument h264. Applying option c:a:0 (codec name) with argument dca. Applying option noaccurate_seek (enable/disable accurate seeking with -ss) with argument 0. Successfully parsed a group of options. Opening an input file: Q:\AudioTool\Hawaiian.Vacation.2011.mkv. [NULL @ 0081ec00] Opening 'Q:\AudioTool\Hawaiian.Vacation.2011.mkv' for reading [file @ 00812cc0] Setting default whitelist 'file,crypto' [matroska,webm @ 0081ec00] Format matroska,webm probed with size=2048 and score=100 st:0 removing common factor 1000000 from timebase st:1 removing common factor 1000000 from timebase st:2 removing common factor 1000000 from timebase st:3 removing common factor 1000000 from timebase st:4 removing common factor 1000000 from timebase st:5 removing common factor 1000000 from timebase [matroska,webm @ 0081ec00] Before avformat_find_stream_info() pos: 6676 bytes read:35388 seeks:2 nb_streams:6 [h264 @ 00827100] nal_unit_type: 7(SPS), nal_ref_idc: 3 snip [h264 @ 00827100] ct_type:0 pic_struct:0 Last message repeated 1 times [matroska,webm @ 0081ec00] All info found [matroska,webm @ 0081ec00] After avformat_find_stream_info() pos: 1476424 bytes read:1505136 seeks:2 frames:163 Input #0, matroska,webm, from 'Q:\AudioTool\Hawaiian.Vacation.2011.mkv': Metadata: title : Hawaiian Vacation (2011) encoder : libebml v1.3.0 + libmatroska v1.4.1 creation_time : 2014-08-18T18:18:23.000000Z Duration: 00:05:53.73, start: 0.000000, bitrate: 30402 kb/s Chapter #0:0: start 0.000000, end 161.453000 Metadata: title : 00:00:00.000 Chapter #0:1: start 161.453000, end 248.832000 Metadata: title : 00:02:41.453 Chapter #0:2: start 248.832000, end 353.728000 Metadata: title : 00:04:08.832 Stream #0:0, 25, 1/1000: Video: h264 (High), 1 reference frame, yuv420p(tv, bt709, progressive, left), 1920x1080 (1920x1088) blah blah Metadata: title : MPEG-4 AVC Video / 24884 kbps / 1080p / 23,976 fps / 16:9 / High Profile 4.1 BPS : 24664310 BPS-eng : 24664310 DURATION : 00:05:53.687000000 snip Stream #0:1(eng), 102, 1/1000: Audio: dts (DTS-HD MA), 48000 Hz, 7.1, s32p (24 bit), 1536 kb/s (default) Metadata: title : English / DTS-HD Master Audio / 7.1 / 48 kHz / 5370 kbps / 24-bit (DTS Core: 5.1 / 48 kHz / 1509 kbps / 24-bit) BPS : 5372315 BPS-eng : 5372315 DURATION : 00:05:53.696000000 snip Stream #0:2(eng), 33, 1/1000: Audio: ac3, 48000 Hz, stereo, s16p, 320 kb/s Metadata: title : Commentary / Dolby Digital Audio / 2.0 / 48 kHz / 320 kbps snip Stream #0:3(eng), 2, 1/1000: Subtitle: hdmv_pgs_subtitle, 1920x1080 blah blah blah more subtitles Successfully opened the file. Parsing a group of options: output url Q:\AudioTool\Hawaiian.Vacation.2011.out.mkv. Applying option c:a (codec name) with argument pcm_s24le. Applying option vn (disable video) with argument 1. Applying option sn (disable subtitle) with argument 1. Successfully parsed a group of options. Opening an output file: Q:\AudioTool\Hawaiian.Vacation.2011.out.mkv. File 'Q:\AudioTool\Hawaiian.Vacation.2011.out.mkv' already exists. Overwrite ? [y/N] y [file @ 038e06c0] Setting default whitelist 'file,crypto' Successfully opened the file. Stream mapping: Stream #0:1 -> #0:0 (dts (dca) -> pcm_s24le (native)) Press [q] to stop, [?] for help cur_dts is invalid st:0 (0) [init:0 i_done:0 finish:0] (this is harmless if it occurs once at the start per stream) Last message repeated 1 times detected 24 logical cores [graph_0_in_0_1 @ 0083e340] Setting 'time_base' to value '1/48000' [graph_0_in_0_1 @ 0083e340] Setting 'sample_rate' to value '48000' [graph_0_in_0_1 @ 0083e340] Setting 'sample_fmt' to value 'fltp' [graph_0_in_0_1 @ 0083e340] tb:1/48000 samplefmt:fltp samplerate:48000 chlayout:0x60f [format_out_0_0 @ 0083e600] Setting 'sample_fmts' to value 's32' [auto_resampler_0 @ 0083d980] Setting 'output_sample_bits' to value '24' [format_out_0_0 @ 0083e600] auto-inserting filter 'auto_resampler_0' between the filter 'Parsed_anull_0' and the filter 'format_out_0_0' [AVFilterGraph @ 0397ffc0] query_formats: 4 queried, 6 merged, 3 already done, 0 delayed [auto_resampler_0 @ 0083d980] [SWR @ 02d7a340] Using fltp internally between filters [auto_resampler_0 @ 0083d980] ch:6 chl:5.1(side) fmt:fltp r:48000Hz -> ch:6 chl:5.1(side) fmt:s32 r:48000Hz Output #0, matroska, to 'Q:\AudioTool\Hawaiian.Vacation.2011.out.mkv': Metadata: blah blah Stream #0:0(eng), 0, 1/1000: Audio: pcm_s24le ([1][0][0][0] / 0x0001), 48000 Hz, 5.1(side), s32, 6912 kb/s (default) Metadata: blah I noticed when I ran the same AudioEncoder.sh script with -v debug: "Plex Transcoder.exe" -c:v:0 h264 -c:a:0 dca -noaccurate_seek -analyzeduration 20000000 -probesize 20000000 -i "Q:\AudioTool\Hawaiian.Vacation.2011.mkv" -filter_complex "[0:a:0] aresample=async=1:ocl='7.1':rematrix_maxval=60.000000dB:osr=48000[0]" -map [0] -metadata:s:a title="EAC3 7.1 from DTS" -metadata:s:a language=eng -c:a eac3_eae -b:a 1280k -vn -sn -avoid_negative_ts disabled -hide_banner -start_at_zero -stats -v debug "Q:\AudioTool\Hawaiian.Vacation.2011.out.mkv" Quote:
Quote:
Code:
Q:\AudioTool\Encoder\Windows>"Plex Transcoder.exe" -codecs ffmpeg version 1.6-367b3d4c85-1 Copyright (c) 2000-2019 the FFmpeg developers D.A.LS dts DCA (DTS Coherent Acoustics) (decoders: dca ) libavutil 56. 26.100 / 56. 26.100 libavcodec 58. 52.100 / 58. 52.100 libavformat 58. 27.104 / 58. 27.104 libavfilter 7. 49.100 / 7. 49.100 libswscale 5. 4.100 / 5. 4.100 libswresample 3. 4.100 / 3. 4.100 Quote:
I almost have this running under Windows natively, but it halts on: Code:
[eac3_eae @ 02764cc0] got broken frame from EAE Audio encoding failed Code:
SETLOCAL SET EAE_ROOT=Q:\AudioTool\Encoder SET FFMPEG_EXTERNAL_LIBS=Q:/AudioTool/Codecs/367b3d4-3654-windows-x86/ SET X_PLEX_TOKEN=xxxxxxxxxxxxxxxxxxxx Code:
Q:\AudioTool\Encoder>EasyAudioEncoder.exe Dolby, Dolby Digital, Dolby Digital Plus, Dolby TrueHD and the double D symbol are trademarks of Dolby Laboratories. safe_fopen: CreateFileW failed: 2 safe_fopen: CreateFileW failed: 2 safe_fopen: CreateFileW failed: 2 ad infinitum |
|||
16th August 2022, 02:32 | #149 | Link | |
Registered User
Join Date: Apr 2022
Posts: 28
|
Quote:
Perhaps they should focus on basic A/V functionality, like AV1 support and proper DTS-HD MA decoding, before they add more u$ele$$ feature$ like TIDAL, vidja, and "free" shovelware from the media conglomerates wish I'd never paid them a dime... |
|
16th August 2022, 03:45 | #150 | Link |
Registered User
Join Date: Apr 2022
Posts: 28
|
Yep. It's only decoding the core. I found a creative way to "force" a test,
It goes without saying that there are vuvuzelas on this, so turn your speakers down: DIDNEYWORL.mkv
Code:
Audio #1 ID : 2 Format : DTS XLL Format/Info : Digital Theater Systems Commercial name : DTS-HD Master Audio Codec ID : A_DTS Duration : 15s 595ms Bit rate mode : VBR Bit rate : 4433 Kbps Channel(s) : 8 channel Channel layout : C L R LFE Lb Rb Lss Rss Sampling rate : 48.0 KHz Frame rate : 93.750 fps (512 SPF) Bit depth : 24 bit Compression mode : Lossless Stream size : 8.24 MiB (28%) Title : Inverted Vuvuzela Test Language : English Default : Yes Forced : No Audio #2 ID : 3 Format : DTS Format/Info : Digital Theater Systems Codec ID : A_DTS Duration : 15s 595ms Bit rate mode : CBR Bit rate : 1509 Kbps Channel(s) : 6 channel Channel layout : C L R Ls Rs LFE Sampling rate : 48.0 KHz Frame rate : 93.750 fps (512 SPF) Compression mode : Lossy Stream size : 2.81 MiB (10%) Title : Extracted DTS Core Language : English Default : Yes Forced : No Audio #3 ID : 4 Format : E-AC-3 Format/Info : Enhanced AC-3 Commercial name : Dolby Digital Plus Codec ID : A_EAC3 Duration : 15s 616ms Bit rate mode : CBR Bit rate : 1024 Kbps Channel(s) : 8 channel Channel layout : L R C LFE Ls Rs Lb Rb Sampling rate : 48.0 KHz Frame rate : 31.250 fps (1536 SPF) Bit depth : 32 bit Compression mode : Lossy Stream size : 1.91 MiB (7%) Title : EAC3 7.1 from DTS (Plex/EAE) Language : English Service kind : Complete Main Default : Yes Forced : No Audio #4 ID : 5 Format : FLAC Format/Info : Free Lossless Audio Codec Codec ID : A_FLAC Duration : 15s 595ms Bit rate mode : VBR Bit rate : 5416 Kbps Channel(s) : 8 channel Channel layout : L R C LFE Lb Rb Ls Rs Sampling rate : 48.0 KHz Frame rate : 11.735 fps (4090 SPF) Bit depth : 24 bit Compression mode : Lossless Stream size : 10.1 MiB (35%) Title : eac3to.exe DIDNEYVOOVINVF.dtshd DIDNEYVOOVINVF.dtshd_.flac -progressnumbers -log=UsEac3To.log Writing library : libFLAC 1.2.1 (UTC 2007-09-17) Language : English Default : Yes Forced : No Audio #5 ID : 6 Format : E-AC-3 Format/Info : Enhanced AC-3 Commercial name : Dolby Digital Plus Codec ID : A_EAC3 Duration : 15s 648ms Bit rate mode : CBR Bit rate : 1024 Kbps Channel(s) : 8 channel Channel layout : L R C LFE Ls Rs Lb Rb Sampling rate : 48.0 KHz Frame rate : 31.250 fps (1536 SPF) Compression mode : Lossy Stream size : 1.91 MiB (7%) Title : eac3to -0,1,2,3,6,7,4,5 FLAC -> E-AC-3 (Adobe Audition 2015.2) Language : English Service kind : Complete Main Default : Yes Forced : No |
16th August 2022, 09:37 | #151 | Link | |
Moderator
Join Date: Feb 2005
Location: Spain
Posts: 6,915
|
Quote:
1) Decode it to wav/wavs (w64 not needed because it is short) 2) Encode it to codec to test 3) Decode it with the decoder to test and see (*) the output in an audio editor or listen it in the player to test (*) The order and images must be like:
__________________
BeHappy, AviSynth audio transcoder. |
|
16th August 2022, 12:51 | #152 | Link |
Life's clearer in 4K UHD
Join Date: Jun 2003
Location: Notts, UK
Posts: 12,227
|
Perhaps the DTS talk should be split off into its own topic...
__________________
| I've been testing hardware media playback devices and software A/V encoders and decoders since 2001 | My Network Layout & A/V Gear |
|
17th August 2022, 14:34 | #155 | Link | |
Registered User
Join Date: Jul 2022
Location: UK
Posts: 4
|
Quote:
Shame about Plex's encoder doing the weird DRC effect though, it's the ONE thing stopping me being able to create perfect results in the project I was working on. If anyone's actually able to figure out why it's doing that and how to stop it, I'd be eternally grateful. Regarding the DTS decoding issues, the Plex encoder is ancient so I transcode to FLAC then let EAE convert it to EAC3 to avoid issues like the DTS one you're hitting here. It doesn't even support MP3! |
|
18th August 2022, 02:06 | #157 | Link | ||||
Registered User
Join Date: Apr 2022
Posts: 28
|
Quote:
Quote:
But uh, yeah, Plex devs confirmed that they do not decode anything other than DCA 5.1 core audio from any DTS streams (for legal reasons? of all things...) so it is still worth noting as a PSA for anyone using EAE to encode E-AC-3. Like you mentioned, you can still get around it by just feeding it 7.1 FLAC or PCM instead. Quote:
Quote:
Last edited by BuccoBruce; 18th August 2022 at 02:09. |
||||
19th August 2022, 04:59 | #158 | Link |
Registered User
Join Date: Feb 2020
Posts: 541
|
BTW, wanted to paste docx (ETSI insider) documentaion of EAC3. It is very nice, docx from which public pdf was done. https://www.upload.ee/files/14428160...cdocx.zip.html
|
19th August 2022, 07:44 | #159 | Link | |
Registered User
Join Date: Feb 2020
Posts: 541
|
Quote:
you need to SET EAE_ROOT to something like your user folder and create 8 folders there (it will not do mkdir for you). After that you need to lauch EasyAudioEncoder.exe and it must see its license file (key, that is, not GPL 2.0 license text) online keygen from plex itself is here: https://github.com/pabloromeo/cluste...ent-1216753569 After you got the .exe or ELF file, you should launch it, after that transcoder.exe will work like ffmpeg.exe. Last edited by Balling; 19th August 2022 at 09:51. |
|
19th August 2022, 09:43 | #160 | Link | |
Registered User
Join Date: Feb 2020
Posts: 541
|
"And as I mentioned before, I paid for Plex Pass, which may have allowed me EasyAudioEncoder for 7.1 transcoding when playing on Plex (existence of EasyAudioEncoder and license file). BUT, I don't know that 100%, I actually suspect it is included with the free version"
It is not included, no, but you can just download it on the direct link (do not forget to activate it) or open any sdr video with .thd inside for plex do it for you. E.g. (do not forget to apt-get install xq): Quote:
Last edited by Balling; 19th August 2022 at 10:03. |
|
Tags |
eac3 |
Thread Tools | Search this Thread |
Display Modes | |
|
|