View Full Version : LAV Filters - DirectShow Media Splitter and Decoders
el Filou
23rd October 2020, 19:15
I had already noticed LAV couldn't handle 10-channel audio when I tried testing some stuff with the Audio Creation mode of my X-Fi that allows up to 10 channels of "Multi-Channel Wave", but I figured it was a really niche case and no consumer file would ever use that. The additional two compared to 7.1 were 'Rear Center' and 'Top'. Is that standard in Windows' multi-channel wave layout?
I assume this sample here from Doom doesn't use that and it's rather two or more height channels like in Atmos?
v0lt
25th October 2020, 11:37
AAC ltp decoding issue: sample file (https://drive.google.com/file/d/1kO7ynnZS8AvjlleLRhTCIr2BLLwKIXUH/view?usp=sharing)
Plays ok with VLC.
ffplay 2020-10-21-git-289e964873 cannot play sound correctly.
VLC 3.0.11 plays in stereo.
regiregi22
25th October 2020, 23:12
I have an Intel i9 10900K cpu and an Nvidia 1080 gpu. I am currently the latest MPC-HC version (1.9.8 from clsid2) with LAV video version 0.74.1.75.
Would it be better to use D3D11 or just going directly for software decoding (none)?
Thanks!
Asmodian
26th October 2020, 07:57
I like D3D11 for 4K HEVC but for everything else software is better, even 4K HEVC is fine in software on a 10900K but it does heat up.
clsid
26th October 2020, 16:50
D3D11 is only beneficial if you use madVR or MPCVR. Because those renderers supports D3D11 native mode. With EVR-CP as renderer the best choice is DXVA2 Native (or None for <4K stuff).
regiregi22
26th October 2020, 17:19
D3D11 is only beneficial if you use madVR or MPCVR. Because those renderers supports D3D11 native mode. With EVR-CP as renderer the best choice is DXVA2 Native (or None for <4K stuff).
Thank you!
butterw2
26th October 2020, 17:32
I typically use hwdec on my old machine (intel hd4400 igpu).
However, with 4K30 8bit Hevc, software decoding seems to work better (avoids gpu @100% +frame stuttering).
clsid
26th October 2020, 22:43
Intel hd4400 only has partial acceleration for HEVC, which isn't very good. So with such GPUs you often get better results with CPU decoding.
mark0077
27th October 2020, 15:31
Hi guys. I remember discussing this many years back on this thread, but I'm wondering has anyone come across a way to achieve this with lav audio or some other external filter.
I'm trying to filter out frequencies above a certain frequency from the LFE channel, because many blu-rays I have such as the Dark Knight, have some awfully strange, high frequency content in the LFE channel. AVRs must normally filter this but as I don't have an AVR, I can't get rid of them so the sound flutters/clips (it sounds like that) in some scenes. I actually only have a 2.1 channel system (Outputting as 2.0 to LS50W + it then outputting low frequencies from the 2.0 to a PB16 Ultra sub). I have until now been using LAV Mixing to mix to 2.0 with 0.71 as the mixing level for center/surround, and 1.58 for the LFE Mix level.
I'm now trying again to see is there a way to solve this as other family members noticed the problem last night when I was "showing off" my system. Do you know if LAV Audio would ever have the ability to filter these frequencies out before mixing, as its difficult to filter them after the mix is done. I'm thinking one way would be to send the audio without mixing, to ffdshow raw audio or some other filter, and let it do the filtering (via a convolver maybe) and then mixing to 2.0 after the filtering.
Any inputs welcome. It'd be great if LAV Audio could do it but not sure is there any plans?
VictorLS
31st October 2020, 17:00
Can anyone confirm new H.265 4K SAT channel Mooz 4K (here's my record 20201031-170739_Mooz 4K.ts (56 MB) https://yadi.sk/d/NngfIFAIVyK-hQ ) with LAV Video Decoder 0.74.1-75 (I didn't test earlier versions) as minimum on nVIDIA's videocards GM206 and newer can't be accelerated with DXVA2 (native and copy-back) or gives artifacts in Win7x64? With CUVID hardware acceleration works well. MPC-BE, Cyberlink and MainConcept accelerates via DXVA2 well too.
sneaker_ger
31st October 2020, 19:59
Video
ID : 500 (0x1F4)
Menu ID : 2 (0x2)
Format : HEVC
Format/Info : High Efficiency Video Coding
Format profile : Main 10@L5.1@Main
Codec ID : 36
Duration : 20 h 30 min
Width : 3 840 pixels
Height : 2 160 pixels
Display aspect ratio : 16:9
Frame rate : 25.000 FPS
Color space : YUV
Chroma subsampling : 4:2:0
Bit depth : 8 bits
https://github.com/Nevcairiel/LAVFilters/commit/cac4dcd705de5b908c181cab123e860ad6d18435
nevcairiel
31st October 2020, 20:02
I'll likely have to redesign profile/format selection for proper AV1 support, since it has a lot more supported formats, so maybe support for such streams will come at that point.
VictorLS
31st October 2020, 21:19
sneaker_ger, nevcairiel
Thanks
nevcairiel
6th November 2020, 23:28
A new LAV Filters nightly (0.74.1-87 and newer) is available now with support for AV1 DXVA2/D3D11 decoding.
For those with Intel Tiger Lake mobile CPUs or the lucky few with NVIDIA 30-series cards, if you encounter any issues, do let me know.
Only Profile 0 ("Main") is supported for now, which is 8-bit and 10-bit 4:2:0.
Film Grain is only supported on NVIDIA so far, as they apply it transparently, which is also what I tested on. For Intel (and presumably future AMD), Film Grain will require additional work, unfortunately I don't have such hardware myself (yet).
I have a bit more hardware things to work on, but once that is done I plan on making a new release version.
SamuriHL
7th November 2020, 02:55
Oh that's very exciting. Thanks, nev! Now, where'd I put that nVidia 3080....ohhhhh, right. Damn. :D Looking forward to being able to play some day!
VBB
7th November 2020, 03:11
Thanks for all your hard work, nev!
wanezhiling
7th November 2020, 12:14
A new LAV Filters nightly (0.74.1-87 and newer) is available now with support for AV1 DXVA2/D3D11 decoding.
For those with Intel Tiger Lake mobile CPUs or the lucky few with NVIDIA 30-series cards, if you encounter any issues, do let me know.
Only Profile 0 ("Main") is supported for now, which is 8-bit and 10-bit 4:2:0.
Film Grain is only supported on NVIDIA so far, as they apply it transparently, which is also what I tested on. For Intel (and presumably future AMD), Film Grain will require additional work, unfortunately I don't have such hardware myself (yet).
I have a bit more hardware things to work on, but once that is done I plan on making a new release version.
Not work on Tiger Lake iGPU, auto fallback to sw decoding, and even sw decoder fails too, just blackscreen.
clip (https://mega.nz/file/g5V30QTC#ibTcM6QWnQ7Uq4_LSz0DImO7l_RhbCSAsV_PsvO0pPg) for test
lvqcl
7th November 2020, 12:52
and even sw decoder fails too, just blackscreen.
Do you use 32-bit player?
wanezhiling
7th November 2020, 14:35
Do you use 32-bit player?
No, 64-bit
nevcairiel
7th November 2020, 14:44
Software decoding works just fine here in 64-bit, albeit slowly. Your system is likely just extremely overwhelmed with a 8K video.
It also hardware decodes fine here on my NVIDIA card. As mentioned before, I do not have access to an Intel system, I only had someone test a bit to confirm. The implementation follows the Microsoft specification, so any conforming hardware should work.
Do note that fallback is not guaranteed to work with DXVA2 Native (or possibly D3D11 native, even), as the renderer cannot really be reset from hardware mode back to software mode.
32-bit decoders, on the other hand, are not capable of handling 8K reliably at all. They just often run out of memory.
In general, it would also be a lot more helpful to avoid generic statements like "it doesn't work". Now I don't know if it doesn't work with any video? Or only not with that video, which happens to be 8K and maybe is just too much for a laptop? That means all I can do is guess.
v0lt
7th November 2020, 15:32
@wanezhiling
Perhaps the built-in graphics have limitations on the amount of allocated RAM.
clsid
7th November 2020, 16:26
Here are some more AV1 samples:
https://www.elecard.com/videos
If those also fail, then maybe there is a minimum Intel driver version needed for proper AV1 hardware decode?
ranpha
7th November 2020, 16:34
Playing that clip (https://mega.nz/file/g5V30QTC#ibTcM6QWnQ7Uq4_LSz0DImO7l_RhbCSAsV_PsvO0pPg) with DXVA2/D3D11 native with a RTX 3080 works just fine, but using any form of copy-back decoding methods and the performance goes down the toilet. Maybe because my motherboard only supports PCI-E v3?
nevcairiel
7th November 2020, 16:56
That clip is 8K 10-bit 60 FPS, that comes out to 7680 × 4320 (pixels) x 24 (total bits per pixel in P010) x 60 (fps) -> 47.8 Gbit/s, or 6GB/s
PCIe 3.0 x16 has a single duplex speed of ~16GB/s, so in theory its still enough, but who knows what else is going on. System memory on DDR4 has a speed of 40-50GB/s reading, possibly half that writing. Copy-back needs to go through the system memory, so a lot of bandwidth is being used here.
On top of all that, the copying actually uses CPU resources.
Its hard to say which is really bottlenecking. Maybe the transfer from/to GPU is too slow. Maybe the system memory is an issue. Maybe I'll try to find out. I would assume its either the GPU download or upload, or the combination of the two combined.
Keep in mind that 8K is 4 times as much data as 4K, if anyone was wondering about comparing those numbers.
In general I would say copy-back for 8K is dead. And likely software decoding as well, as these rates are getting out of control.
My Ryzen 5000 is still in the mail, so I can't check PCIe 4.0 yet, but I doubt that'll make a difference. But I'll let myself be surprised!
wanezhiling
7th November 2020, 17:30
@nevcairiel, i tested another three such samples (8k av1 10-bit) downloaded from youtube, same result, auto fallback to sw mode and no image output (blackscreen).
While if downgraded to 4k av1 10-bit (also these clips) ver, sw decoder works fine, hw decoder still doesn't work though.
PS: The movie and TV app plays fine with hw decoding. https://iili.io/FJkdN9.jpg
clsid
7th November 2020, 17:34
Assuming 8k60 copyback is unusable even on the new generation CPUs, maybe it is a good idea to force native mode when user has selected copyback? I know you are not a fan of such workarounds, but this feels like a valid exception.
Siso
8th November 2020, 11:02
A question about software decoding and hardware decoding dxva cp in Win 7, I see no difference, but maybe the more experienced users can point me to the right decoder. My cpu is xeon x5650, the video card is gtx 1050 ti. So in short software or hw decoding?
clsid
8th November 2020, 16:34
All decoders give the same quality.
Siso
8th November 2020, 16:39
All decoders give the same quality.
How about in terms of performance and stability?
VBB
8th November 2020, 20:24
For anything other than HEVC & VP9, I now use software only. madVR times are actually lower that way, and you get the benefit of black bar detection, de-interlacing, and more. Stable as can be, and my CPU is from 2008.
Siso
9th November 2020, 00:19
For anything other than HEVC & VP9, I now use software only. madVR times are actually lower that way, and you get the benefit of black bar detection, de-interlacing, and more. Stable as can be, and my CPU is from 2008.
Thank you for the reply, I'll leave it to software decoding.
mark0077
11th November 2020, 20:27
Guys using the latest nightly LAV Splitter/Video/Audio, I have seen an issue (not specific to this LAV version) with "The World Is Not Enough" Blu-ray. When I play the index.bdmv or the largest m2ts file, when I seek a significant way into the file, the player freezes for possibly a minute. I assume this is the fact that the file has been created without something like keyframes or something like that? Do you know if this is something LAV is behaving correctly with (ie taking this amount of time) or is there a way to make it faster without changing the actual files?
LigH
12th November 2020, 08:52
If the video stream did not have regular frequent keyframes, it would not be Blu-ray compliant and should have been rejected by any serious authoring tool... I would rather wonder about issues with the logical structure. But that's harder to prove.
VictorLS
13th November 2020, 21:56
is there a way to make it faster without changing the actual files?
Try to use MPC-BE's MpegSplitter.ax from standalone_filters-...zip i.e. lastest Beta's can be downloaded from https://cloud.mail.ru/public/V1rp/2iqNDT5Rx/Beta%20(Nightly)/1.5.6 or https://yadi.sk/d/AjAXDDHtHRIELg/Beta%20(Nightly)/1.5.6
doskabouter
15th November 2020, 12:39
I have a problem playing some avi files.
File source splitter perfectly adds a LAV video decoder if used in MPC/graphstudio but the LAV splitter does not add that automatically.
If LAV video decoder is added manually it plays perfectly.
Mediainfo of video:
General
Complete name : <redacted>.avi
Format : AVI
Format/Info : Audio Video Interleave
File size : 24.8 MiB
Duration : 1 min 50 s
Overall bit rate : 1 895 kb/s
Writing library : VirtualDub build 16250/release
Video
ID : 0
Format : Indeo 4
Codec ID : IV50
Codec ID/Info : Intel Indeo Video 5.0 Wavelet
Duration : 1 min 50 s
Bit rate : 1 800 kb/s
Width : 320 pixels
Height : 240 pixels
Display aspect ratio : 4:3
Frame rate : 15.000 FPS
Bits/(Pixel*Frame) : 1.563
Stream size : 23.6 MiB (95%)
Audio
ID : 1
Format : PCM
Format settings : Unsigned
Codec ID : 1
Duration : 1 min 49 s
Bit rate mode : Constant
Bit rate : 88.2 kb/s
Channel(s) : 1 channel
Sampling rate : 11.024 kHz
Bit depth : 8 bits
Stream size : 1.16 MiB (5%)
Alignment : Aligned on interleaves
Interleave, duration : 67 ms (1.00 video frame)
Interleave, preload duration : 500 ms
Is there something I'm missing?
The indeo format is checked in the video formats configuration
Version is 0.74.1
doskabouter
16th November 2020, 21:25
Hi all,
I have an issue with some old IV50 AVI files.
If I open them in MPC they play fine, with a generic filesource -> LAV video decoder and LAV audio decoder.
When opening them in graphstudio, LAV splitter is used, LAV audio decoder is added, but no video decoder.
Manually adding LAV Video decoder and connecting it to the splitter, playback is ok.
Mediainfo of this file:
General
Complete name : <redacted>.avi
Format : AVI
Format/Info : Audio Video Interleave
File size : 24.8 MiB
Duration : 1 min 50 s
Overall bit rate : 1 895 kb/s
Writing library : VirtualDub build 16250/release
Video
ID : 0
Format : Indeo 4
Codec ID : IV50
Codec ID/Info : Intel Indeo Video 5.0 Wavelet
Duration : 1 min 50 s
Bit rate : 1 800 kb/s
Width : 320 pixels
Height : 240 pixels
Display aspect ratio : 4:3
Frame rate : 15.000 FPS
Bits/(Pixel*Frame) : 1.563
Stream size : 23.6 MiB (95%)
Audio
ID : 1
Format : PCM
Format settings : Unsigned
Codec ID : 1
Duration : 1 min 49 s
Bit rate mode : Constant
Bit rate : 88.2 kb/s
Channel(s) : 1 channel
Sampling rate : 11.024 kHz
Bit depth : 8 bits
Stream size : 1.16 MiB (5%)
Alignment : Aligned on interleaves
Interleave, duration : 67 ms (1.00 video frame)
Interleave, preload duration : 500 ms
This all with LAV 0.74.1, and the indeo format checked in the videoformats config of LAV video.
Anyone able to shed a light on this?
mrmojo666
17th November 2020, 14:17
Hi
maybe someone can help me
yestrerday i got a rx5700 xt I see that with the internal win10 videoplayer files are correctly deinterlaced, all the other player that uses lav have broken DXVA deinterlacing, if i use copyback + software deint it works., at the start i thought it was Madvr but even with EVR it's the same ..... anyone have similar experience with that card ?
I noticed that before with rx460 i had more option under driver video custom setting, now there is only brightness.
Already tried with DDU to reset drivers
thank you fro any help
el Filou
17th November 2020, 14:52
Could you try with MPC Video Renderer? https://github.com/Aleksoid1978/VideoRenderer
I've read huhn say in the past that it supports D3D11 video processing, so if you set LAV to D3D11 native decoding it could work. If it does then it looks like AMD didn't bother testing backward compatibility with DXVA2. :(
Dogway
17th November 2020, 19:54
Does LAVFilters support mkv cropping feature? I'm not sure if I'm doing something wrong on mkvtoolnix or MPC-HC.
nevcairiel
17th November 2020, 23:30
No, cropping is not supported, unless its on a codec level.
mrmojo666
18th November 2020, 10:22
Could you try with MPC Video Renderer? https://github.com/Aleksoid1978/VideoRenderer
I've read huhn say in the past that it supports D3D11 video processing, so if you set LAV to D3D11 native decoding it could work. If it does then it looks like AMD didn't bother testing backward compatibility with DXVA2. :(
Thank you for the tip, with mpc-be and mpc-video render deinterlacing works. Lav filter dxva native.
Just I'm not sure that this renderer uses Hw deinterlacing (even if using dxva native should the only way to deinterlace is by HW).
Looks like the problem is in EVR and Madvr implementation :(
huhn
18th November 2020, 10:32
mpcVR can deint with d3d11.
hardware deint is generally broken on NAVI this is nothing new.
in best cases it uses bilinear which is not a deint algo that should ever be used or it is combing.
i mean: https://abload.de/img/amddeint2mji2.jpg
what so ever lavfilter has nothing todo with this.
quietvoid
18th November 2020, 20:07
Hi nevcairiel.
With the new Matroska spec (though it's not implemented in FFmpeg, the code from Plex's patches is available), Dolby Vision metadata can be inserted and decoded from MKV headers.
Would it be possible to parse the HEVC RPU NAL units and make that information available to the renderer (for example, madVR) through the LAV decoder?
HW acceleration might cause issues, though.
I have working code to parse this RPU data (at least for profile 7 files), but I'm not sure if it's feasible for that metadata to be useful.
I think it would be nice if the renderer could have access to pre defined per-frame information about min, max, average luminance and etc.
Just wondering if it's something that would be possible, because I'd be interested in helping to add support.
chros
18th November 2020, 21:01
Sound good quetvoid, thanks, hopefully you can some magic together :)
VictorLS
19th November 2020, 21:18
It seems AC-4 playing still possible with a fork only but what about Dolby E? In Sample Eurovision 2019 Tel Aviv.ts (154 MB) https://yadi.sk/i/j1zj1sqy2myOfw third (Dolby E) audio track plays like loud noise - that patch https://patchwork.ffmpeg.org/project/ffmpeg/patch/20201019081929.1926-2-nicolas.gaullier@cji.paris/ may helps to add Dolby E support in LAV Audio Decoder with adding all possible metadatas described in former NDA's document.
el Filou
19th November 2020, 22:58
Any support for new formats is always nice, but it's not really essential for LAV: Dolby E is a studio format for production, it's not supposed to be broadcast to end users. Just like 4:2:2 or 4:4:4 video isn't either. I'm amazed at how you keep "finding" weird streams like that.
VictorLS
20th November 2020, 00:08
I'm amazed at how you keep "finding" weird streams like that.
I'm just SAT-amateur ;)
Btw I haven't seen 4:4:4 from SAT yet (but hardware acceleration supported by nVIDIA's Turing and Ampere) and I often see 4:2:2 from more than 10 years ago but only newest Intel's GPUs (inside of CPU Tiger Lake or discrete videocard Xe) seems will support it.
aiyunyi
20th November 2020, 15:31
Hi everyone, new to the forum, is there anyway to know how lavfilters store its configuration?
VictorLS
20th November 2020, 17:28
aiyunyi
In registry (appears when although any parameter of LAV Filters' properties is changed once tough) - it's same for x86 and x64 version of LAV Filters so it hurts me sometimes when I need separate (i.e. CUVID Hardware acceleration for x86 in my favorite old version of KMPlayer not supported DXVA2 acceleration with LAV Video Decoder - with other decoders DXVA2 works in that version of KMPlayer just fine and DXVA2 (native) acceleration for x64 in app SmartDVBx64 for HLGtoSDR transformation (http://forum.doom9.org/showthread.php?t=176909) in EVR-CP to watch HLG programs with ~right colors directly from SATs):
[HKEY_CURRENT_USER\Software\LAV\Audio] for LAV Audio Decoder
[HKEY_CURRENT_USER\Software\LAV\Splitter] for LAV Splitter
and finally
[HKEY_CURRENT_USER\Software\LAV\Video] for LAV Video Decoder where I proposed to add key for skipping frames feature http://forum.doom9.org/showthread.php?p=1902404#post1902404 for live software decoding hard streams (like 8K, 4:2:2 etc) on weak processors with well audio.
VictorLS
21st November 2020, 13:26
Any support for new formats is always nice
I agree and I hope this document https://developer.dolby.com/globalassets/professional/dolby-e/dolby-e-high-level-frame-description.pdf with patch https://patchwork.ffmpeg.org/project/ffmpeg/patch/20201019081929.1926-2-nicolas.gaullier@cji.paris/ will help to implement full Dolby E support in LAV Audio Decoder and it'll be very useful for SAT receiving.
vBulletin® v3.8.11, Copyright ©2000-2026, vBulletin Solutions Inc.