View Full Version : LAV Filters - DirectShow Media Splitter and Decoders
ajp_anton
24th January 2012, 01:08
I have done a lot of tests with Windows Xp - Catalyst 11.2 - Radeon 3650, you can find here. (http://forum.doom9.org/showthread.php?t=159486) Look at the second system results.
That's why I asked ajp_anton about drivers version and OS.
Maybe after almost a year of my last try with 3650, I could try again under Win 7 system with latest Catalysts 11.12
Sorry for the late answer, been busy.
It was a very long time ago.
I found this post (http://forum.doom9.org/showthread.php?p=1397440#post1397440). I think I used Windows Server 2003 64-bit back then, no idea about drivers.
I have a newer OS now, but still the same hardware. Can't get DXVA working at all now though, and I don't really care since it's my server computer.
Mr.White
24th January 2012, 01:29
LAV Audio can decode DTS-WAV, if you trick it into being used for raw PCM. With LAV Splitter, it should be used, with other splitters, probably not.
MPC-HC, LAV Splitter, ReClock (wasapi) = Bitstreaming
But if LAV Audio is set to Prefer MPC-HC crash!
dts_wav (http://www.haringetliv.nu/pub/temp/dts_wav.jpg)
NikosD
24th January 2012, 08:39
Sorry for the late answer, been busy.
It was a very long time ago.
I found this post (http://forum.doom9.org/showthread.php?p=1397440#post1397440). I think I used Windows Server 2003 64-bit back then, no idea about drivers.
I have a newer OS now, but still the same hardware. Can't get DXVA working at all now though, and I don't really care since it's my server computer.
Well, things are getting a little worse for HD 3300.
It seems that it doesn't even have a UVD+. It has UVD, which was the first generation inside HD 2000 series.
From the OS version used (Windows Server 2003) combined with UVD, I think there is no chance at all to play HW accelerated L5.1-Ref 16-1080p clips in that system.
The only way to actually see such clips played in your system, is with a software decoder.
In my opinion, your media player/decoder made a fall back to software mode and you didn't notice.
If your newer version of Windows Server is 2008 SP1, you could try the modified Win 7 drivers, which install the whole Catalyst suite on Server 2008.
Anyway, I did my little research for UVD+ with newer system and drivers here (http://forum.doom9.org/showpost.php?p=1553048&postcount=8409)
PeQuE
24th January 2012, 09:14
OK. I guess im in over my head here then. I bitstream HD audio on my movies and the codec section in MediaPortal is set to LAV audio and it works perfect. I have no clue how to set how the dts-wav file should be played.
I asume you're trying to play dts-wav file using MyMusic section of MediaPortal... If that's the case, then you're probably using internal BASS Player engine. I can play dts-wav files and they bitstream perfectly. Please check that:
- You've got volume at 100%
- You are not using crossfading.
- You don't need to, but I recomend you to install Asio4all (http://www.asio4all.com/), and configure MediaPortal to use it for MyMusic.
Sorry for the offtopic, nev...
alegend
24th January 2012, 11:04
alegend,
Do you have .2559 intel HD Graphics driver installed? If so - try downgrading to 15.22.50.64.2509 (8.15.10.2509)...
HEY!!! This one really worked!!!
I downgraded to that .2509 driver and it works like a charm!
Big thx!
Pat357
24th January 2012, 12:01
with my laptop (radeon 4850 mobility) and a normal 24fps movie, present queue hovers between 3/4 and 0/4 all the time. its fine for a few secs, but then drops down to zero for a few seconds and so forth.
is there any chance of improving the speed? (coreavc is faster)
or are my gpus simply too slow?
In which mode do you set Coreavc when you compare it to Lav DXVA-copy-back ?
Is coreavc DXVA mode ? Then it would not work which MadVR, and probably switch to SW mode.
ajp_anton
24th January 2012, 12:21
Well, things are getting a little worse for HD 3300.
It seems that it doesn't even have a UVD+. It has UVD, which was the first generation inside HD 2000 series.
From the OS version used (Windows Server 2003) combined with UVD, I think there is no chance at all to play HW accelerated L5.1-Ref 16-1080p clips in that system.
The only way to actually see such clips played in your system, is with a software decoder.
In my opinion, your media player/decoder made a fall back to software mode and you didn't notice.
If your newer version of Windows Server is 2008 SP1, you could try the modified Win 7 drivers, which install the whole Catalyst suite on Server 2008.
Anyway, I did my little research for UVD+ with newer system and drivers here (http://forum.doom9.org/showpost.php?p=1553048&postcount=8409)I'm 100% sure DXVA was used. The MPC-HC DXVA decoder showed heavy artifacting with the default amount of video RAM (only using the onboard 128MB) while software always worked, but with 256MB video RAM it worked.
Why would you think it only has UVD? The UVD series is pretty much what defined the integrated series since they didn't really improve the performance. HD2000 was UVD, HD3000 was UVD+ and HD4000 was UVD2.
nevcairiel
24th January 2012, 12:23
UVD+ is indeed present in the HD3000 series, however AMD never made a big distinction between UVD and UVD+, they marketed it as pure UVD. Only with UVD2, they started naming it differently.
NikosD
24th January 2012, 12:52
Why would you think it only has UVD? The UVD series is pretty much what defined the integrated series since they didn't really improve the performance. HD2000 was UVD, HD3000 was UVD+ and HD4000 was UVD2.
UVD+ is indeed present in the HD3000 series, however AMD never made a big distinction between UVD and UVD+, they marketed it as pure UVD. Only with UVD2, they started naming it differently.
As I wrote to my first post, HD 3000 series should all have UVD+.
But Radeon HD 3300 and HD 3200 are IGPs paired with AMD 790GX Chipset and AMD 780G Chipset.
Well, Wikipedia says net UVD and not UVD+ for both IGPs.
So it seems it's not the same like the other HD 3000 series cards, probably because HD 3200 and HD 3300 aren't "real" cards.
According to Tom's Hardware, 780G and 790GX chipsets have both UVD 1.0 and only 785G has UVD 2.0.
But of course because UVD+ was also being marketed as simply UVD, that means that could have and should have UVD+. Or UVD 1.0.
As I have written before, even UVD 2.2 inside HD 4000 series is different than UVD 2.2 inside HD 5000 series, which is different than UVD 2.2 inside HD 6700 series.
In my opinion the REAL DIFFERENCE between UVD, UVD+, UVD2, UVD2.2(HD 4000), UVD2.2(HD 5000), UVD2.2(HD 6700), UVD 3(HD 6000), UVD 3? (HD 7000) is the way that ATI/AMD supports the hardware by exposing certain features through drivers/BIOS of a hardware which more or less the same.
If you know what I mean ;)
And that last point ajp_anton means, that maybe you could actually play 1080p L5.1 Ref 16 files, with suitable drivers/OS/BIOS (Graphics card), even in hardware (UVD/UVD+) that it's not supposed to play such files "officially".
Check this (http://www.agile-news.com/news-323468-Photo:-no-fear-of-4K-x-2K!-Fire-whirlwind-2-HD6570-2G-Daniel-Edition-hardware-solution-2160p!.html) out and try to explain it.
How is it possible for UVD3 to accelerate 4K x 2K video files with 238Mbps bitrate and 14% CPU usage and the same card cannot play 1080p60 ???
ajp_anton
24th January 2012, 13:16
Oh well, I don't care what it has, when the fact is that 1080p 16ref worked on my 790GX =).
NikosD
24th January 2012, 13:24
Sure, but you should care two times why it's not working now, if it worked sometime ago.
It looks like MPEG-2 VLD support.
It was a time that it worked in HD 4000 series with a registry hack, but then stopped and never reappeared.
UVD features are like ghosts, afterall :scared:
CruNcher
24th January 2012, 16:37
In my opinion the REAL DIFFERENCE between UVD, UVD+, UVD2, UVD2.2(HD 4000), UVD2.2(HD 5000), UVD2.2(HD 6700), UVD 3(HD 6000), UVD 3? (HD 7000) is the way that ATI/AMD supports the hardware by exposing certain features through drivers/BIOS of a hardware which more or less the same.
It is most likely partly a programmable architecture same as Nvidia and Intel have and microcodes get updated via the Drivers (firmware), in terms of GPU Hardware Asics people shouldn't think anymore in the old terms of full fixed things (it would be much to unflexible) ;)
Though obviously somewhere are limits but even those limits can be workedarround see Nvidias Mpeg-2 fix via the Shader ;)
NikosD
24th January 2012, 17:07
Agree.
ATI put a fast ASIC inside from the beginning and started to play with features and names with the help of drivers and firmware/BIOS.
I know about ATI HD 3000 that supports MPEG2_IDCT in GPU shaders, not in UVD+.
What do you mean about Nvidia fix for MPEG2?
nevcairiel
24th January 2012, 17:30
NVIDIA fixed MPEG-2 with CUDA, saying "with shaders" is incorrect.
Their hardware MPEG-2 decoder had a bug in earlier generations (a hardware bug), so with some driver they just implemented a new MPEG-2 decoder in CUDA which didn't have the bug, but still runs plenty fast.
CruNcher
24th January 2012, 17:30
There is a decoding problem for certain bitstreams in everything pre VP4 and Nvidia fixes it by using the Shaders for Decoding instead the VPx it's a design bug most probably that couldn't get fixed :). Donald was the first implementing this workarround via the Shaders later Nvidia implemented it in the Drivers directly.
@Nev
just for testing could you implement Arcsofts and Cyberlinks VC-1 GUIDs in the .wmv parser part, they both work fine with .ts but with .wmv Arcsoft don't get the DXVA connection on the used GUID though Cyberlinks decoder doesn't even connect ;)
PS: It seems you need some special bit somewhere GUID alone doesn't seem enough :(
clsid
24th January 2012, 17:40
Here (http://hobring.esero.net/saf/samples/dtswav_test.zip).A crash happens in avcodec-lav-53.dll when DCA is disabled in LAV Audio. Interestingly enough, LAV Audio is part of the graph. Crash happens when pressing play in GraphStudio. Also, it does not connect to ffdshow. Could you make it output a normal mediatype as well?
nevcairiel
24th January 2012, 17:45
A crash happens in avcodec-lav-53.dll when DCA is disabled in LAV Audio. Interestingly enough, LAV Audio is part of the graph. Crash happens when pressing play in GraphStudio.
I changed it so that DTS-in-WAV detection is now disabled when the DTS codec is disabled, this should avoid the crash, but will of course only output garbage.
The problem with DTS-in-WAV is that the splitter does not know that its DTS, it'll claim its normal 16-bit PCM. Only LAV Audio will try to figure it out...
ajp_anton
24th January 2012, 17:51
Sure, but you should care two times why it's not working now, if it worked sometime ago.Like I said, it's a server computer, never used for video playback. I don't have any media players or decoders installed, and video memory is back to only using the onboard 128MB. I can't even remember why I did test it back then.
CruNcher
24th January 2012, 18:21
Nah this seems not easy todo seems only PowerDVD 11 (default) and Potplayer (using either Arcsoft or Cyberlinks Decoder and their VC-1 Adapter filter with Microsofts parser) are capable of this ( .wmv VC-1 AP playback via DXVA2 no copy back on Intel Quicksync) currently even with Av Splitters connection tricks it endsup in a black screen on MPC-HC with most streams else its switching to YUY2 input and consumes much more CPU then both solutions above, so for MPC-HC only Quicksync works (reliable ffdshow-quicksync or lav video quicksync) in this .wmv VC-1 AP case though with a lot higher CPU consumption :P
hoborg
24th January 2012, 18:40
I changed it so that DTS-in-WAV detection is now disabled when the DTS codec is disabled, this should avoid the crash, but will of course only output garbage.
The problem with DTS-in-WAV is that the splitter does not know that its DTS, it'll claim its normal 16-bit PCM. Only LAV Audio will try to figure it out...
But did you tried to bitstream it?
nevcairiel
24th January 2012, 19:37
Here is a "release candidate" of the next version.
Its basically feature complete for what i wanted to do, just hoping no severe bugs are still in there.
x86: http://files.1f0.de/lavf/LAVFilters-0.45-rc.zip
x64: http://files.1f0.de/lavf/LAVFilters-0.45-rc-x64.zip
New since 0.44 is the DXVA2 decoder.
Its known to work pretty well, however its not really all that super fast on ATI hardware. On older models, like HD3000 and older, it'll most likely be unusable.
DXVA2 is currently only available in "copy back" mode, which means it needs to copy the video frame back from the GPU to the CPU, which is the reason for the low performance. "Native" DXVA2 is planned for a later version.
I'm mostly interested in bugs with the DXVA2 decoder, or regressions since 0.44.
RBG
24th January 2012, 21:05
nevcairiel
Mpeg-4 ASP acceleration is back... Man, you've made my day. :thanks:
nevcairiel
24th January 2012, 21:06
I would however not recommend using it, it bugs out on some files, seems to be related to bitstream packing or something in that area. Its off by default for that reason.
NikosD
24th January 2012, 21:27
Perfect decoding for every clip I tried H.264/VC-1/WMV3 in DXVA2 copy frame mode.
Same "slow" speed for Radeon (6)750 as with Lav 0.44 DXVA2 copy frame.
We have to wait for direct DXVA2 implementation.
I have also Deinterlacing for DXVA VC-1 even with VMR renderer in DXVA checker.
Is VMR renderer capable of Deinterlacing with decent quality ?
Because I think that HW Deinterlacing is not supported in LAV for ATI (I didn't see an option).
Maybe the drivers are involved and do Vector adaptive deinterlacing regardless of decoder/renderer.
One "bug" only.
You have kept version 0.44 for all your filters (splitter, audio, video)
I don't have VP4 right now to check, but did you implement MPEG4 ASP for VP4/VP5 and UVD3 in DXVA2 copy frame or just NVCUDVID for Nvidia HW only?
nevcairiel
24th January 2012, 21:30
I have also Deinterlacing for DXVA VC-1 even with VMR renderer in DXVA checker.
Is VMR renderer capable of Deinterlacing with decent quality ?
Because I think that HW Deinterlacing is not supported in LAV for ATI (I didn't see an option).
If you use VMR or EVR, it'll do hardware deinterlacing through the driver.
One "bug" only.
You have kept version 0.44 for all your filters (splitter, audio, video)
Its not 0.45 yet. :p
I don't have VP4 right now to check, but did you implement MPEG4 ASP for VP4/VP5 and UVD3 in DXVA2 copy frame or just NVCUDVID for Nvidia HW only?
Only in CUVID mode. I might do DXVA later, if i get bored enough.
Gser
24th January 2012, 21:34
DXVA2 is currently only available in "copy back" mode, which means it needs to copy the video frame back from the GPU to the CPU, which is the reason for the low performance. Does this mean I could use LAVF to deinterlace my videos threw DXVA2 in avisynth? MadVR for instance deinterlaces threw DXVA2, it just doesn't return the frames.
nevcairiel
24th January 2012, 21:37
Does this mean I could use LAVF to deinterlace my videos threw DXVA2 in avisynth? MadVR for instance deinterlaces threw DXVA2, it just doesn't return the frames.
Its only decoding with DXVA2, not deinterlacing.
Deinterlacing uses another surface type as render target, downloading from that is incredibly slow (~5fps) for ATI, so its not worth it.
clsid
24th January 2012, 21:38
Perhaps the DTS-in-WAV detection could be moved from decoder to splitter? Those files can successfully be parsed by for example AC3File, allowing any DTS decoder to be used.
nevcairiel
24th January 2012, 21:42
Perhaps the DTS-in-WAV detection could be moved from decoder to splitter?
You're welcome to write a patch.
There is a reason its like this. If it would be trivial to change, it would've been done already.
Thunderbolt8
24th January 2012, 21:54
"Native" DXVA2 is planned for a later version.looking forward ;)
Mangix
25th January 2012, 02:08
LAV Audio's FLAC decoder fails when i use reclock's accept bitstream formats. reclock falsely believes that lav audio is sending a bitstreamed format... mpc-hc's built-in FLAC decoder works fine.
CruNcher
25th January 2012, 03:25
@Nev
http://git.1f0.de/gitweb?p=ffmpeg.git;a=commit;h=fe15af222b118ac350c7e0b2178b85ff364f4b7e <-finally, good that Reimar pushed it through :) 1 line that can change so much ;)
hmm this should be in 0.45 RC1 shouldn't it, if it should it seems to fail for dshow :( ?
hmm that lav splitter also shows 0.44 in its version number ?
File Version = 0.44.0.0
boyumeow
25th January 2012, 04:56
...
hmm that lav splitter also shows 0.44 in its version number ?
File Version = 0.44.0.0
I believe this should be nev answer.
...
Its not 0.45 yet. :p
...
Aleksoid1978
25th January 2012, 05:23
Here is a "release candidate" of the next version.
Its basically feature complete for what i wanted to do, just hoping no severe bugs are still in there.
x86: http://files.1f0.de/lavf/LAVFilters-0.45-rc.zip
x64: http://files.1f0.de/lavf/LAVFilters-0.45-rc-x64.zip
New since 0.44 is the DXVA2 decoder.
Its known to work pretty well, however its not really all that super fast on ATI hardware. On older models, like HD3000 and older, it'll most likely be unusable.
DXVA2 is currently only available in "copy back" mode, which means it needs to copy the video frame back from the GPU to the CPU, which is the reason for the low performance. "Native" DXVA2 is planned for a later version.
I'm mostly interested in bugs with the DXVA2 decoder, or regressions since 0.44.
Very bad work in DXVA mode with H.264 interlaced and MBAFF on Intel HD. If need - i can upload a problem sample. Progressive H.264 - work good.
Aleksoid1978
25th January 2012, 05:55
Also - i have sample what play in DXVA with artefacts in MPC-HC and in LAV with DXVA mode. Play fine with CUDA and other DXVA decoder like Microsoft or Cyberlink.
dead_screem
25th January 2012, 06:59
ok, minor bug, DXVA2 shows as "Available" on XP.
Also in CUVID certain VC-1 interlaced files drop frames alot, used to work fine. And with CUVID adaptive deinterlacing in a certain vc-1 sample you might have the sample already "Slicies VC-1 NTSC 1080i 29.97 Bilder.ts". in the bottom half of the screen several of the horizontal white lines disappear completely.
(also CUVID+YADIF=very slow framerate, like 7fps on my 9800GTX, but this may be expected?)
Aleksoid1978
25th January 2012, 07:21
Another bug - Indeo3 http://aleksoid.tosei.ru/Test/Sample/indeo30.avi playback is choppy with LAV, ffdshow - playback is ok.
nevcairiel
25th January 2012, 07:48
LAV Audio's FLAC decoder fails when i use reclock's accept bitstream formats. reclock falsely believes that lav audio is sending a bitstreamed format... mpc-hc's built-in FLAC decoder works fine.
Thats a ReClock bug, nothing that can be done.
Enable MPC-HCs Audio Switcher, it'll prevent this from happening.
And with CUVID adaptive deinterlacing in a certain vc-1 sample you might have the sample already "Slicies VC-1 NTSC 1080i 29.97 Bilder.ts". in the bottom half of the screen several of the horizontal white lines disappear completely.
The highest quality deinterlacer is not available on Windows XP (which i guess from your previous comment you're using).
Enabling it caused severe image degredation for alot of people, so i opted to just completely disable it for an overall better experience.
hmm this should be in 0.45 RC1 shouldn't it, if it should it seems to fail for dshow :( ?
Its not in the build i posted, will be in release.
nevcairiel
25th January 2012, 08:30
Another bug - Indeo3 http://aleksoid.tosei.ru/Test/Sample/indeo30.avi playback is choppy with LAV, ffdshow - playback is ok.
Fixed, was a bug in libav.
nixties
25th January 2012, 08:49
With DXVA2 MPEG2 still artefacts - Sample (http://www.mediafire.com/download.php?79f42499cc12964), Full file (http://www.mediafire.com/download.php?e2v8eva8780a2lk)
NikosD
25th January 2012, 09:05
@nev
Is it possible to implement a Multi-threaded CPU decoding of VC1-/WMV3 ?
Because if for some reason the DXVA is not working or doesn't exist at all for VC-1/WMV3, the next option is a single threaded CPU decoding which is very slow, especially for VC-1 which is an advanced video format and the most difficult to decode after H.264 of course.
I have tried a lot of decoding implementations - none of them is Multi-threaded.
Is there a particular reason or difficulty ?
madshi
25th January 2012, 09:33
The MS software VC-1 decoder is multithreaded, I think?
nevcairiel
25th January 2012, 09:45
Is it possible to implement a Multi-threaded CPU decoding of VC1-/WMV3 ?
Possible, sure, but for a complex format like VC-1, its a bit out of my skill set. I'm not nearly advanced enough in video decoding itself to be able to do that. Maybe some day someone will do it in ffmpeg/libav.
The MS software VC-1 decoder is multithreaded, I think?
I'm not sure, but at least it always was fast enough to decode 1080p even on my old Core2Duo
madshi
25th January 2012, 10:04
The only thing I have problems with on my development PC is interlaced VC-1 (when using software decoding). But I think it's not the decoding (MS decoder) itself which is too slow, I think the MS decoder tries to deinterlace internally and I've found no way to turn that off.
NikosD
25th January 2012, 10:56
The MS software VC-1 decoder is multithreaded, I think?
The so called "multi-threaded" MS VC-1 decoder, although it seems that is filling both 2 cores at my Core2Duo, it actually has the decoding performance of the single-threaded FFmpeg/ LAV/ PotPlayer and every other single-threaded decoder out there.
So no, we can forget MS "multi-threaded" VC-1 decoder.
I'm not sure, but at least it always was fast enough to decode 1080p even on my old Core2Duo
No, unfortunately it's not.
Try to play 1080/60p clip like Devil_may_cry_gameplay.wmv (ftp://helpedia.com/pub/multimedia/x264/testvideos/2010%20-%2009%20-%20DXVA%20benchmarks%20-%20Avivo%20vs%20PureVideo%20vs%20Clear%20Video/) on every Core2Duo you want.
You will never see 60fps, unless you use DXVA.
Possible, sure, but for a complex format like VC-1, its a bit out of my skill set. I'm not nearly advanced enough in video decoding itself to be able to do that. Maybe some day someone will do it in ffmpeg/libav.
I see.
italospain
25th January 2012, 11:09
The only thing I have problems with on my development PC is interlaced VC-1 (when using software decoding). But I think it's not the decoding (MS decoder) itself which is too slow, I think the MS decoder tries to deinterlace internally and I've found no way to turn that off.
You can try wmv PowerToy.
You can disable there the internal deinterlacer.
Mosley
25th January 2012, 13:44
I recently reported HERE (http://sourceforge.net/apps/trac/mpc-hc/ticket/1970)a bug involving (in part) LAV splitter. Have you ever experienced a similar problem with blu-rays using MPC-HC or another player?
madshi
25th January 2012, 13:47
The so called "multi-threaded" MS VC-1 decoder, although it seems that is filling both 2 cores at my Core2Duo, it actually has the decoding performance of the single-threaded FFmpeg/ LAV/ PotPlayer and every other single-threaded decoder out there.
The MS VC-1 decoder is noticeably faster on my PC than the ffmpeg VC-1 decoder.
You can try wmv PowerToy.
You can disable there the internal deinterlacer.
Cool, thanks!
nevcairiel
25th January 2012, 13:49
I recently reported HERE (http://sourceforge.net/apps/trac/mpc-hc/ticket/1970)a bug involving (in part) LAV splitter. Have you ever experienced a similar problem with blu-rays using MPC-HC or another player?
Bit-streaming of E-AC3 (DDPlus) from Blu-rays is not supported at this time, and possibly never will be.
That one demo disc you mention in the ticket is the *only* known disc to actually use that type of audio, no real world movie ever used it to my knowledge.
NikosD
25th January 2012, 14:48
I would however not recommend using it, it bugs out on some files, seems to be related to bitstream packing or something in that area. Its off by default for that reason.
You mean you have to deal with new bugs that appeared during the integration of your LAV CUVID, or the bugs you mention were always there from the beginning even in LAV CUVID ?
Maybe a hardware's bug like MPEG2 ?
vBulletin® v3.8.11, Copyright ©2000-2025, vBulletin Solutions Inc.