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 > Capturing and Editing Video > New and alternative a/v containers

Reply
 
Thread Tools Search this Thread Display Modes
Old 25th March 2015, 08:57   #18821  |  Link
omarank
Registered User
 
Join Date: Nov 2011
Posts: 187
Quote:
Originally Posted by nevcairiel View Post
The next nightly of LAV will feature the libdcadec DTS decoder.
It supports full bitexact DTS-HD decoding of up to 96/24, as well as much broader support for DTS extensions than the ffmpeg decoder.
Hi, I tried the new DTS decoder using the latest nightly build and it works perfectly. Thanks Nevcairiel for this great addition to LAV and also to the developer of the libcadec decoder.

I found that the new DTS decoder also doesn't low-pass the LFE channel of DTS MA streams at 120 Hz, like the Arcsoft decoder. Will you be considering to add an option to low pass the LFE channel of DTS MA streams, especially when they are downmixed to stereo and LFE is included in the mix?
omarank is offline   Reply With Quote
Old 25th March 2015, 09:02   #18822  |  Link
kalston
Registered User
 
Join Date: May 2011
Posts: 164
Just installed the nightly build, will try it when I get back home this afternoon
kalston is offline   Reply With Quote
Old 25th March 2015, 09:35   #18823  |  Link
JohnLai
Registered User
 
Join Date: Mar 2008
Posts: 448
Quote:
Originally Posted by Asmodian View Post
DXVA native leaves the decoded video in the GPU's memory. Getting it into the system memory is the "copy-back". DXVA Native cannot work with Avisynth/Staxrip.
NikoD gonna be sad about this

How about quicksync native mode? Current lavfilter quicksync implementation still using copyback.

Developer of handbrake is able to get quicksync decoding natively.
Possible for implementation?
JohnLai is offline   Reply With Quote
Old 25th March 2015, 09:37   #18824  |  Link
nevcairiel
Registered Developer
 
Join Date: Mar 2010
Location: Hamburg/Germany
Posts: 10,342
If you want to use QuickSync without copy-back for decoding+encoding, you need to implement this in one fixed pipeline. You cannot use DirectShow for that.
__________________
LAV Filters - open source ffmpeg based media splitter and decoders
nevcairiel is offline   Reply With Quote
Old 25th March 2015, 09:48   #18825  |  Link
NikosD
Registered User
 
Join Date: Aug 2010
Location: Athens, Greece
Posts: 2,901
If QS decoder from Eric Gur, which is using MSDK, wasn't implemented with a copy-back mechanism and kept everything in GPU's memory, couldn't be used inside LAV Video and combined with an MSDK HW encoder ?
__________________
Win 10 x64 (19042.572) - Core i5-2400 - Radeon RX 470 (20.10.1)
HEVC decoding benchmarks
H.264 DXVA Benchmarks for all
NikosD is offline   Reply With Quote
Old 25th March 2015, 10:01   #18826  |  Link
Liandri
Registered User
 
Join Date: Aug 2012
Posts: 15
Quote:
Originally Posted by Arm3nian View Post
1. Your computer is not the only thing connected to speakers. Cable/satellite box, bluray player, basically anything that isn't a computer or professional gear doesn't have capabilities like down mixing or up mixing to 2.1, only traditional formats like stereo or 5.1.
2. You can't use lav or directshow filters with every program. Watching videos on the internet, games, applications, might not support 2.1.
..
Even if software supports upmixing or downmixing to 2.1, everything else will sound terrible if the system doesn't already have bass management.
I don't undertstand your point. My PC is the only thing that is connected to both speakers and headphones, and I'm not planning to change that in years to come. And I'm not requiring that all the sound will come with proper bass. In fact, my 2.1 system work fine with any software, I just tend to watch video content mostly with my headphones for unrelated reasons.

You say that everything sounds bad on a system when user made a wrong purchase? And that nobody should care because it all would sound terrible anyway? Then how come I find it all sounds perfectly fine? Videos, music, youtube, games and other stuff without directshow etc. I was not complaining that something sounds bad, I was asking for a feature to additionally improve experience on my system. In fact, previously I was using LAV Audio for some time without realizing it doesn't do this. AC3filter and 2 other video players (ironically both of which are banned on this forum) can do that for me, so I guess I'll live with it not being part of LAV Audio feature set.

If something should not be a job for a software then why not provide a hardware requirements for it? Remove an option for mixing into mono and stereo, say that user should buy 5.1 system for optimal experience instead, because why not? What's all the fuss about DXVA decoding when we should all just buy a better CPU?

Still, I found explanation and advice from Telion fair so I may aswell try that.

I'm sorry to sound harsh, I appreciate all the replies, but I just don't understand why you should have such an attitude. A PC is never a perfect (still best of course) platform and everyone should only be grateful if something can be improved or added through software.
Liandri is offline   Reply With Quote
Old 25th March 2015, 10:03   #18827  |  Link
nevcairiel
Registered Developer
 
Join Date: Mar 2010
Location: Hamburg/Germany
Posts: 10,342
Quote:
Originally Posted by NikosD View Post
If QS decoder from Eric Gur, which is using MSDK, wasn't implemented with a copy-back mechanism and kept everything in GPU's memory, couldn't be used inside LAV Video and combined with an MSDK HW encoder ?
No, DirectShow doesn't support anything other than software video buffers or DXVA2-Native buffers. If you want anything special like this, gotta implement it yourself without DirectShow - which is probably going to be easier anyway.
__________________
LAV Filters - open source ffmpeg based media splitter and decoders

Last edited by nevcairiel; 25th March 2015 at 10:06.
nevcairiel is offline   Reply With Quote
Old 25th March 2015, 10:14   #18828  |  Link
NikosD
Registered User
 
Join Date: Aug 2010
Location: Athens, Greece
Posts: 2,901
For the record, I didn't said to JohnLai to write to this thread about that matter, because more or less I had the same opinion about it like you, but thanks for the clarification.

I have proposed to rigaya, the developer of QSVEncC, to convert his encoder to a transcoder, implementing the decoder in HW too, from the first time that I got involved with his app.

Only one fixed pipeline solution implemented with MSDK has a large possibility to become a real app, like HandBrake and QSTranscode.
__________________
Win 10 x64 (19042.572) - Core i5-2400 - Radeon RX 470 (20.10.1)
HEVC decoding benchmarks
H.264 DXVA Benchmarks for all
NikosD is offline   Reply With Quote
Old 25th March 2015, 11:16   #18829  |  Link
e-t172
Registered User
 
Join Date: Jan 2008
Posts: 589
Quote:
Originally Posted by omarank View Post
I found that the new DTS decoder also doesn't low-pass the LFE channel of DTS MA streams at 120 Hz, like the Arcsoft decoder. Will you be considering to add an option to low pass the LFE channel of DTS MA streams, especially when they are downmixed to stereo and LFE is included in the mix?
I second this. Leaving LFE untouched is generally a bad idea, because everyone expects it to be low-passed, and sometimes production houses make mistakes and leave high frequency content in the LFE channel, which goes unnoticed because even their own monitoring systems remove it on playback. In fact I believe someone reported this sort of issue at some point in this thread some time ago, where it was fought LAV Audio was corrupting audio, while it was in fact caused by high-frequency garbage in the source LFE channel.
e-t172 is offline   Reply With Quote
Old 25th March 2015, 11:37   #18830  |  Link
madshi
Registered Developer
 
Join Date: Sep 2006
Posts: 9,140
I'm confused. Isn't lossless decoding supposed to be lossless? Why would we suddenly want the DTS decoder to "process" the LFE channel?
madshi is offline   Reply With Quote
Old 25th March 2015, 12:18   #18831  |  Link
andyvt
Registered User
 
Join Date: Jan 2010
Posts: 265
Quote:
Originally Posted by NikosD View Post
If QS decoder from Eric Gur, which is using MSDK, wasn't implemented with a copy-back mechanism and kept everything in GPU's memory, couldn't be used inside LAV Video and combined with an MSDK HW encoder ?
There are sample filters in the MSDK which demonstrate how to leverage QS to transcode content via DirectShow. It should be relatively easy to modify the decoder with Eric's format-a-bitstream code and make it robust enough for production use.

That said, I don't think that DirectShow is the best place to transcode. It works OK if the application doesn't need to support editing, but once that is requirement it is more difficult to keep everything sync'd properly than in an application where the pipeline is entirely self managed.
__________________
babgvant.com
Missing Remote
andyvt is offline   Reply With Quote
Old 25th March 2015, 12:22   #18832  |  Link
kalston
Registered User
 
Join Date: May 2011
Posts: 164
And are you guys sure the ArcSoft DTS decoder applied a 120hz low-pass filter for that matter? This reminds me of what I posted before: https://www.doom9.org/showthread.php...31#post1702731 (check the following replies, nev said that the distortion was barely audible when he applied a filter which would contradict omarank)

Last edited by kalston; 25th March 2015 at 12:26.
kalston is offline   Reply With Quote
Old 25th March 2015, 12:26   #18833  |  Link
nevcairiel
Registered Developer
 
Join Date: Mar 2010
Location: Hamburg/Germany
Posts: 10,342
The point is that neither the ArcSoft decoder, nor libdcadec, apply a low-pass, but some users would like to have one to avoid distortions from badly authored LFE channels.
You wouldn't hear those distortions if you use an actual subwoofer, as they are simply incapable of playing those frequencies, but if you mix into stereo (including the LFE), you will hear them.

Its not something libdcadec should do, but something further down in the processing. Not sure I want LAV to be that part, though.
__________________
LAV Filters - open source ffmpeg based media splitter and decoders

Last edited by nevcairiel; 25th March 2015 at 12:28.
nevcairiel is offline   Reply With Quote
Old 25th March 2015, 12:26   #18834  |  Link
QBhd
QB the Slayer
 
QBhd's Avatar
 
Join Date: Feb 2011
Location: Toronto
Posts: 697
Quote:
Originally Posted by madshi View Post
I'm confused. Isn't lossless decoding supposed to be lossless? Why would we suddenly want the DTS decoder to "process" the LFE channel?
Agreed....

QB
__________________
QBhd is offline   Reply With Quote
Old 25th March 2015, 12:59   #18835  |  Link
FireFreak111
Registered User
 
Join Date: Apr 2014
Posts: 48
New DTS-HD MA decoder is amazing. Works perfectly, sounds great. Based on the source code we know its proper lossless, as is passed down the chain.

For quality output to the Windows mixer, which does all its mixing in 32 bit float since Vista, should we output 32 bit float the whole way? Like send it from LAV to Reclock and then to the Audio engine (effects, etc in the windows pipeline) as a 32 bit float? Mathematical perfection?
FireFreak111 is offline   Reply With Quote
Old 25th March 2015, 13:34   #18836  |  Link
kalston
Registered User
 
Join Date: May 2011
Posts: 164
Quote:
Originally Posted by FireFreak111 View Post
New DTS-HD MA decoder is amazing. Works perfectly, sounds great. Based on the source code we know its proper lossless, as is passed down the chain.

For quality output to the Windows mixer, which does all its mixing in 32 bit float since Vista, should we output 32 bit float the whole way? Like send it from LAV to Reclock and then to the Audio engine (effects, etc in the windows pipeline) as a 32 bit float? Mathematical perfection?
It doesn't matter at all in this case, the only difference is whether LAV or Windows (or Reclock etc.) raises the bit depth. LAV simply decodes the audio and outputs it as is (and DTS-HD is always 16 or 24bit afaik)

Last edited by kalston; 25th March 2015 at 13:38.
kalston is offline   Reply With Quote
Old 25th March 2015, 14:22   #18837  |  Link
e-t172
Registered User
 
Join Date: Jan 2008
Posts: 589
Quote:
Originally Posted by madshi View Post
I'm confused. Isn't lossless decoding supposed to be lossless? Why would we suddenly want the DTS decoder to "process" the LFE channel?
Well, it's... complicated. Genelec (manufacturer of pro audio equipment that's used in production houses) has a good write-up on the subject. Looking at the table in that article, you can see it's kind of a mess. Table note (1) is especially interesting:

Quote:
In the DTS-HD codec only [DTS-HD Master Audio™ (lossless) and DTS-HD High Resolution Audio™ (lossy)] the DTS-HD decoder applies a low-pass filter at 100 Hz (-3 dB) with a 60 dB/octave roll-off onto the LFE channel.
That seems to indicate that a DTS-HD MA decoder that does not lowpass LFE is not doing the right thing.

The problem is, this is all very theoretical. In practice, one should always lowpass LFE, because the presence of high frequency content in the LFE channel is pretty much guaranteed to be a mistake on the production side. On the production side, no-one in their right mind would knowingly put >120Hz content in LFE because the playback of such content would be completely unpredictable - some playback systems will remove it, some won't.

But the real problem arises if the production house lowpasses LFE in their monitoring systems (which, presumably, some do without even knowing it), which means that if high frequency content accidentally gets thrown into the LFE channel, the production house won't notice it, and it won't be noticed in most playback systems because subwoofers can't reproduce it. So most people won't notice it, but some people will, especially if they have systems that are configured to downmix LFE into full-range (L/R) channels without any lowpass filter. These people will hear a different sound compared to what the production people heard, which is bad, because they're not getting the intended sound and the spurious high frequency content in the LFE channel is likely to be garbage (remember, the production house likely didn't notice it's there) and degrade audio quality. This is the reason why Genelec bass management systems have a redirect feature to check for this, but I'm not sure it's used in actual production workflows.

Said differently, the crux of the problem is that high-frequency content in the LFE channel is kinda like what us programmers would call undefined behavior: no-one really knows what will happen to it, so it's better not to have it at all to enforce consistency. kalston above found the previous post I was referring to where we found that some material contained high-frequency garbage in the LFE channel, which led to audible issues after downmixing to full-range channels. Having a LFE lowpass option in LAV would be useful to prevent such issues.

Last edited by e-t172; 25th March 2015 at 14:42.
e-t172 is offline   Reply With Quote
Old 25th March 2015, 15:07   #18838  |  Link
madshi
Registered Developer
 
Join Date: Sep 2006
Posts: 9,140
Quote:
Originally Posted by e-t172 View Post
Well, it's... complicated. Genelec (manufacturer of pro audio equipment that's used in production houses) has a good write-up on the subject. Looking at the table in that article, you can see it's kind of a mess. Table note (1) is especially interesting:

That seems to indicate that a DTS-HD MA decoder that does not lowpass LFE is not doing the right thing.

The problem is, this is all very theoretical. In practice, one should always lowpass LFE, because the presence of high frequency content in the LFE channel is pretty much guaranteed to be a mistake on the production side. On the production side, no-one in their right mind would knowingly put >120Hz content in LFE because the playback of such content would be completely unpredictable - some playback systems will remove it, some won't.

But the real problem arises if the production house lowpasses LFE in their monitoring systems (which, presumably, some do without even knowing it), which means that if high frequency content accidentally gets thrown into the LFE channel, the production house won't notice it, and it won't be noticed in most playback systems because subwoofers can't reproduce it. So most people won't notice it, but some people will, especially if they have systems that are configured to downmix LFE into full-range (L/R) channels without any lowpass filter. These people will hear a different sound compared to what the production people heard, which is bad, because they're not getting the intended sound and the spurious high frequency content in the LFE channel is likely to be garbage (remember, the production house likely didn't notice it's there) and degrade audio quality. This is the reason why Genelec bass management systems have a redirect feature to check for this, but I'm not sure it's used in actual production workflows.
Ok, but it still doesn't make *any* sense to me whatsoever that DTS-MA tracks would need the LFE channel to be filtered, while TrueHD or PCM tracks would not. I would very much like dcadec to stay perfectly lossless. If filtering is needed, it should be done outside of the decoder implementation, and not be limited to DTS-MA, but apply to all audio sources (which need it). I don't care what Genelec says, we developers should think logically, and if DTS-MA needs filtering, then so does TrueHD. Makes no sense to treat them differently, considering that I've often seen TrueHD and DTS-MA tracks decode to the same data, when comparing tracks from different Blu-Ray releases.
madshi is offline   Reply With Quote
Old 25th March 2015, 15:11   #18839  |  Link
kalston
Registered User
 
Join Date: May 2011
Posts: 164
I just setup a low-pass filter for the sub in JRiver (100hz and 48 db/octave because that's the highest value available in JRiver from what I've seen) and it completely gets rid of the distortion in the sample I posted, as expected.

I also found another occurrence on Star Wars Return of the Jedi blu-ray (big explosion at 01:55:42) but it's more much subtle there. Still seems to be some garbage in the LFE channel. I could probably find other examples (but again, much more subtle than the sample I posted where it's really awful) but it's nice to finally understand what it is. I've learned something today I think I could even find some True HD tracks where I noticed a similar issue.

edit : oh and the new DTS-HD decoder works perfectly as far as I can tell

edit 2 : The Dark Knight has a TrueHD track and I also found a couple spots (yes, I have a good memory like that) where there is some "LFE garbage". Guess that means they had a low-pass filter in the production studio like e-t172 explained.

Last edited by kalston; 25th March 2015 at 15:49.
kalston is offline   Reply With Quote
Old 25th March 2015, 15:28   #18840  |  Link
nevcairiel
Registered Developer
 
Join Date: Mar 2010
Location: Hamburg/Germany
Posts: 10,342
Quote:
Originally Posted by madshi View Post
Ok, but it still doesn't make *any* sense to me whatsoever that DTS-MA tracks would need the LFE channel to be filtered, while TrueHD or PCM tracks would not.
The link he posted has a summary on the situation for all common audio codecs, and indeed both TrueHD and DTS-HD MA are flagged as including a full bandwidth channel for LFE, while the lossy codecs are band-limited.

The real problem is with other lossless formats. You have no idea what source a FLAC originally came from, for example.
__________________
LAV Filters - open source ffmpeg based media splitter and decoders

Last edited by nevcairiel; 25th March 2015 at 15:45.
nevcairiel is offline   Reply With Quote
Reply

Tags
decoders, directshow, filters, splitter

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 16:52.


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