View Full Version : LAV Filters - DirectShow Media Splitter and Decoders
huhn
30th July 2019, 20:54
openGL is pretty much discontinued and why should a software for windows care about cross platform.
and the whole thing is pretty much a hack anyway.
LigH
31st July 2019, 07:37
The most efficient functions are those which are most hardware dependent, which are only available inside graphic drivers for specific graphic chipset generations. To allow applications some access to them, there are different APIs (Application Programming Interfaces) provided by the drivers; under Windows, they provide usually at least DirectX/Direct3D and OpenGL with extensions, each up to a specific version/generation.
Some APIs are still rather specific to the hardware functions, like Vulkan, which means the programmer of an application still needs to know a lot of unique features of different graphic chipsets and quirks to produce equal results on different hardware. Vulkan is even more specialized in 3D visualizing functions and less relevant for image and video displaying.
Others are more convenient to the application programmer, generalizing the access to hardware specific functions to rather logical programming functions. OpenGL is very generalizing (thus not always most efficient), keeping core functions compatible for a variety of hardware and adding extensions specific to more modern and powerful chipset features. DirectX/Direct3D is somewhere in the middle, providing even partially incompatible generations of function sets (e.g. 3D game engines supporting both a DirectX9 and a DirectX11 render path are almost two separate engines in one).
DirectX is proprietary which means that Microsoft alone can decide how it works. OpenGL is an open standard which means that all the joint member companies have to agree to a common specification how they would support this feature. So if you discover: "Hey, OpenGL now supports a cool feature!", it means the OpenGL standard took its time to standardize this feature which already was available in the graphic chips for a while, and other APIs may have been quicker to create a new proporietary function without much discussion about standards compatible to different hardware as well as different operating systems.
littleD
31st July 2019, 20:02
Not sure what you mean by this.
OpenGL is/was used in eg. Photoshop (and some other tools) for previewing at 10bit. Some pro apps use OpenGL surface to display video as apparently this allows for better control and separation from OS influence. For example Assimilate Scratch uses OpenGL. It allows for color accurate video preview and screen calibration. My understanding is that Direct3D is more tight to OS and harder to control. OpenGL is also cross platform and apparently more efficient. I may be very wrong. Of course old days only pro card had 10bit support for OpenGL surface, but now it's changing.
https://en.wikipedia.org/wiki/Comparison_of_OpenGL_and_Direct3D comparison tab explains it quite well (at least for my limited understanding).Previously with GeForce cards You could only transmit 10 bit/p video through cable during video playback. It was since win 7 sp1. And only in exclusive mode, so no OS interface elements would interfere. Now, after driver change, You can enable 10 bit desktop output, so the whole OS screen, including folders, OS UI, opened images are visible in 30 bit on monitor.
Not sure how Photoshop or Scratch process images internally and why proffesional programs choose opengl but it must be what You said, more control over image. It may be better to handle 30 bit image files in opengl texture instead in directx somehow.
While directx is nice for video playback, it's because having all that DXVA stuff. Including hardware decoding support and convertions. Opengl lacks it. There was even opengl renderer on Windows (in VLC IIRC) but no one was using it, really, as it had less features available. Who knows how opengl controls access to 10 bit video output/10 bit textures, exclusive mode, refresh handling and so on. It probably does not at all otherwise somebody would write specific code for it.
huhn
31st July 2019, 20:13
the 10 "bit" openGL "30" bit hack used in photoshop at least on windows uses the 8 bit a RGBA surface "32 bit". it's not a great solution to say it friendly and there are hardware decoder you can use with openGL.
el Filou
6th August 2019, 19:00
I'm continuing an off-topic discussion started in the MPC-HC thread.I've been thinking about replacing CUVID with NVDEC in LAV, with built-in deinterlacing and either copy-back like today or interop with D3D11, so that it could be efficient like D3D11 native, just with deinterlacing, and potential 12-bit and maybe 4:4:4 support (the latter would likely need renderer support first)If this was implemented, in the "D3D11 interop" scenario would the NVDEC deinterlacing be controllable from madVR (with LAV-madVR integration), or would it be fixed in LAV settings like with CUVID/QuickSync?
I rely a lot on the ability to enable/disable deinterlacing with a keyboard shortcut inside madVR (but of course can't benefit from the efficiency of D3D11 native as it currently doesn't support deinterlacing with it).
nevcairiel
7th August 2019, 01:12
madVR (or any renderer) would have no influence on that setting. If you rely on those shortcuts, you would have to wait for madVR to support deinterlacing with D3D11.
SamuriHL
7th August 2019, 02:12
Nev, would NVDEC have theoretical performance gains over other options? Just trying to wrap my head around the possible benefits of it. It certainly sounds interesting.
ryrynz
7th August 2019, 02:46
I currently plan to update it to 0.4.0 once thats available
Released :)
Hopefully stacks up well vs MPC-BE's internal decoder, big difference in CPU utilization between the two right now.
maxkolonko123
10th August 2019, 12:41
hi guys i run into some issue lately and dont know how come this happened, basically i use mpc hc with lav and madvr but what i noticed when played movie last time that haali splitter overtook lav filters? when i check filter in mpc hc its shows me haali and i never had this before, therefore now when i play 4K movies i dont have video only sound and i think its bcos haali is used insted LAV
how can i fully disable haali splitter or uninstall it and make sure only LAV filters are in use ??
ps.
I use external lav filter and had set them in external filters inside mpc hc to prefer but still haali is coming on insted lav :(
filler56789
10th August 2019, 13:00
......
how can i fully disable haali splitter or uninstall it and make sure only LAV filters are in use ??
There should be an item to uninstall Haali in the "Programs and Features" applet of Windows's Control Panel. But if it doesn't exist, you can always run regsvr32 /u "Path-To\splitter.ax".
el Filou
10th August 2019, 13:52
Alternatively, you can use a tool like DSF/MFT Viewer that conveniently lists all the filters installed and lets you unregister them (or register new ones) with a button: https://bluesky23.yukishigure.com/en/DsfMftViewer.html
TS Doctor is one app that forcefully reinstalls Haali Splitter with each update, and the uninstaller in the Start Menu only uninstalls the 64-bit version and I have to unregister the 32-bit one manually.
maxkolonko123
10th August 2019, 14:22
Thanks guys for the ideas will try it once I finish work.
Can anyone of you have idea how come this even happened? Like I didn't change nothing in my filter neither settings that's why I'm curious why out of nowhere haali is used instead of LAV
manolito
10th August 2019, 15:22
TS Doctor is one app that forcefully reinstalls Haali Splitter with each update, and the uninstaller in the Start Menu only uninstalls the 64-bit version and I have to unregister the 32-bit one manually.
You can prevent TSDoctor to reinstall Haali with each update with a Registry setting.
NoHaaliInstall.reg
Windows Registry Editor Version 5.00
[HKEY_CURRENT_USER\Software\Cypheros\TSDoctor2\Install]
"NoHaaliInstall"=dword:00000001
clsid
10th August 2019, 15:53
Source filters can set themselves as preferred for specific file extensions. This overrides filter merits, and also the preferred external filter list in MPC-HC.
Haali became preferred because your installed that last. Re-installing LAVFilters would make LAV default again.
If you need both installed, then you can use Codec Tweak Tool to change the preferred splitter.
maxkolonko123
10th August 2019, 15:58
The thing is I didn't install haali codecs so either they came with something else or I really don't know what happened, cause I always used only LAV + madvr + mpc-hc and nothing else cause everythins was working perfectly fine thats why I'm so confused how come those haali got "activated" probably I wouldn't notice but I wanted to re-watch a movie in 4k and I had no video and I was like yyyy I'm watched all my movies and everything was fine now nothing has video and the only thing what I notice is different to what it was its the Haali splitter in filters when I checked in mpc hc
clsid
10th August 2019, 16:19
Well, something else has obviously installed Haali. There are plenty multimedia tools that bundle codecs. For example video converters.
maxkolonko123
10th August 2019, 16:41
Ok i think i've sorted it : first thing what i did was to add haali in external filter in mpc-hc then block it and voila everything started working how it should, so then i downloaded DSF/MFT Viewer and unregistered haali from my system.
So now i see all LAV filter are in use the only thing what im not sure was there is " FileSource ( Async ) " but when i click on it its just showd PinInfo so i think this is ok nah?
el Filou
10th August 2019, 23:59
You can prevent TSDoctor to reinstall Haali with each update with a Registry setting.Thanks!! :)
ryrynz
13th August 2019, 10:32
Anything interesting in the ffmpeg update?
VictorLS
14th August 2019, 16:01
Anything interesting
It's a pity as minimum quasi-interlaced h265 (SD and HD) still not supported well.
So I have to write instruction to use ffdshow raw video filter with Avisynth script between LAV Video Decoder and Renderer (i.e. EVR) for that mostly from satellites streams.
VictorLS
14th August 2019, 16:13
i think this is ok?
Yes, it's OK.
clsid
15th August 2019, 15:11
This video crashes LAV Splitter:
https://mega.nz/#!1cUDnIwR!lKzYVG5UouLkYaToXZ9vVd2pLpEnAA-nY3oJuzB_vpE
manolito
15th August 2019, 19:33
DivX in an OGM container...
Kind of unusual. Remux it into an MKV container and you will be fine.
LigH
16th August 2019, 07:25
Not too unusual in ancient Anime societies who liked to combine different video formats with Ogg Vorbis audio when it was just the best patent-free audio codec.
manolito
16th August 2019, 12:10
Not too unusual in ancient Anime societies
Alright, this was before my time...
Did a few more tests with this file, looks like most source filters do not get along with the OGM container. In addition to the LAV splitter FFMS2 and LSMASH also refuse to decode this file. Trying to open it with Handbrake does not give me any audio tracks. Using FFmpeg to repack the file also did not work. Remuxing to MKV did not work at all, remuxing to MP4 produced a file without audio.
What did work was playing the file with VLC, and using MKVToolnix to repack it to MKV also worked (with some warnings about the Japanese chapters).
Cheers
manolito
ryrynz
16th August 2019, 12:28
Remux it
He's submitting a bug report, he knows how to "fix" it.. :)
manolito
16th August 2019, 12:48
Of course he knows how to fix it, but I am not so sure if it is really a bug in LAV Splitter. Since most other source filters also refuse to decode this clip it might well be an issue with this specific file.
clsid
16th August 2019, 13:15
The crash happens in LAV Splitter itself. To be specific in the code that handles the Vorbis audio. The extradata is empty and that isn't handled properly.
File also plays with old gabest splitter.
manolito
16th August 2019, 13:53
But then how do you explain that after remuxing to MKV the LAV Splitter handles the Vorbis audio tracks just fine?
clsid
16th August 2019, 14:12
Sigh. Because this bug is not triggered in that situation. There is probably also bug in FFmpeg's Ogg parsing code. Your comments are not helpful.
manolito
16th August 2019, 14:50
Here is another "not helpful" comment... :devil:
If LAV Splitter and FFmpeg based source filters like FFMS2 and LSMASH all are buggy when it comes to opening OGG files then my conclusion is that the OGG format is obsolete or broken enough so that nobody cares to support it. Remux to MKV... (MP4 also works fine.)
LigH
16th August 2019, 15:32
It is possible that the audio track uses the even more ancient Vorbis ACM codec which is not fully compatible to the output of e.g. oggenc2.
filler56789
16th August 2019, 21:26
Here is another "not helpful" comment... :devil:
If LAV Splitter and FFmpeg based source filters like FFMS2 and LSMASH all are buggy when it comes to opening OGG files then my conclusion is that the OGG format is obsolete or broken enough so that nobody cares to support it. Remux to MKV... (MP4 also works fine.)
You are correct :)
https://hardwarebug.org/2010/03/03/ogg-objections/
clsid
17th August 2019, 15:48
File plays ok with LAV 0.68.1-4, and got broken by FFmpeg update.
richardpl
27th August 2019, 14:49
Looks like nobody care to open bug report on FFmpeg bug tracker.
filler56789
27th August 2019, 16:00
Looks like nobody care to open bug report on FFmpeg bug tracker.
PERHAPS because most people already know there exists a not-very-smart gatekeeper named cehoyos...
Stereodude
29th August 2019, 00:13
Does LAV support Sony's 8-bit (non-standard) HLG mode they implemented in their cameras? The 0.74.1.20 LAV filters baked into MPC-HC 1.8.7 + madVR 0.92.17 don't seem to see it as HDR. It does recognize the BT.2020 or BT.709 color in the MP4 files correctly.
huhn
29th August 2019, 02:05
madVR doesn't support HLG.
filler56789
29th August 2019, 18:34
PERHAPS because most people already know there exists a not-very-smart gatekeeper named cehoyos...
...but I think he deserves to be pestered anyway :devil:
New ticket opened @ trac-dot-ffmpeg-dot-org:
http://trac.ffmpeg.org/ticket/8105
LigH
30th August 2019, 07:16
And it already develops ... also into the opposite direction, though, they believe GPAC flagged the stream like MPEG-2 4:2:2 although it is 4:2:0, should have been multiplexed differently. Anyway, it is an "important" entry.
steakhutzeee
4th September 2019, 06:45
Hello, i use MPC BE with madVR and LAV filters.
Should i disable the internal filters in MPC BE to let LAV Filters work as external filter?
Thanks in advance.
jkauff
4th September 2019, 07:03
Should i disable the internal filters in MPC BE to let LAV Filters work as external filter?
Yes, according to the MPC-BE developers.
ryrynz
4th September 2019, 07:40
It's not a requirement for madVR to work however.
steakhutzeee
4th September 2019, 19:15
Strange, because here https://forum.doom9.org/showthread.php?p=1884050#post1884050 users told me that i don't have to disable them.
ryrynz
4th September 2019, 22:34
You don't have to but maybe LAV can do one or two things with MadVR that the BE internals do not and that was why they suggested it.. Is that still the case though?
steakhutzeee
4th September 2019, 22:46
Well that's why i select lav filters as preferred.
Tried to disable them and in the right click->filters, i see MPC Video/Audio etc.
If i enable them, i see instead LAV Video/Audio/Splitter.
So i think maybe they do that one or two things you mention. I don't know. Or there is more i'm ignoring?
VictorLS
5th September 2019, 18:37
Well that's why i select lav filters as preferred.
I do so too and uncheck internal filters, namely TS and Matroska, H264 and HEVC (they have more priority in MPC-BE over preferred external filters) to achieve LAV Filters be used at all (as you describe tough).
steakhutzeee
5th September 2019, 19:51
I do so too and uncheck internal filters, namely TS and Matroska, H264 and HEVC (they have more priority in MPC-BE over preferred external filters) to achieve LAV Filters be used at all (as you describe tough).
Thank you!
But i have noticed that with matroska, the lav filters start just fine. This do not happens to you?
I found matroska in internal filters-> source filters, and HEVC/H264 in internal filters -> video decoder.
Is this the right way i should do this? Anyway i can't find TS.
VictorLS
5th September 2019, 21:17
But i have noticed that with matroska, the lav filters start just fine. This do not happens to you?
I'm sorry - I don't understand your question exactly - just want to say I prefer use LAV Filters instead of any other splitters/demultiplexers/sources and decoders for all formats I use - containers TS, MKV, MP4 (forget to mention in previous post) and encoded MPEG2, H264, H265, VPx video so I do setting of Sources as in attach below. Btw it's not need in MPC-BE to uncheck any audeo decoders in internal filters in my case - prefer LAV Audio Decoder enough.
I found matroska in internal filters-> source filters, and HEVC/H264 in internal filters -> video decoder. Is this the right way i should do this?
Yes.
steakhutzeee
6th September 2019, 06:33
I'm sorry - I don't understand your question exactly - just want to say I prefer use LAV Filters instead of any other splitters/demultiplexers/sources and decoders for all formats I use - containers TS, MKV, MP4 (forget to mention in previous post) and encoded MPEG2, H264, H265, VPx video so I do setting of Sources as in attach below. Btw it's not need in MPC-BE to uncheck any audeo decoders in internal filters in my case - prefer LAV Audio Decoder enough.
Yes.
Sadly the image you attached is still in pending approval. What i was saying is that in MPC BE if i right click and select "Filters" i can see that i'm using LAV with the files you mentioned, with all internal filters active and lav as preferred.
It was a reply to the fact that you said that lav is not chosen correctly even if selected as preferred with those files.
So i was asking if this was not happening to you. To be sure i disabled the internal filters you mentioned anyway.
vBulletin® v3.8.11, Copyright ©2000-2026, vBulletin Solutions Inc.