View Full Version : LAV Filters - DirectShow Media Splitter and Decoders
SamuriHL
9th March 2011, 19:20
Thanks, guys. Not sure if I'll get to play with this today or not. Been in training for work the past 2 days and as a result i'm playing catchup. This will be one of those 10 hour + days with not a lot of free time. But I definitely want to get this working if possible so I'll be looking at this asap.
robpdotcom
9th March 2011, 19:43
I have a VC-1 MKV of my Dark Knight BluRay that i created some time back for testing, and its working fine with Cyberlink. (of course thats progressive content)
The GUID thing shouldn't be needed with LAV Splitter.
With hardware decoding, i have to turn on MPC-HCs Frame Time Correction, though.
Small world, I always use Dark Knight for testing VC-1 playback as well.
I just tried enabling MPC-HC's Frame Time Correction, and it works beautifully - thanks for the tip. :thanks:
EDIT: Just tested with interlaced VC-1, and it works for that too. Really big thanks.
Plutotype
9th March 2011, 20:51
Hi,
0.18 tested, everything works ok.
What I would like to have on the splitter in the future:
- the possibility to downmix 7.1 to 5.1 or stereo PCM ( maybe too consumer oriented feature, but helpful in limited surround or stereo speaker setups )
- bitstreaming support - from that what I know, internal decoding to PCM 24/96 with Reclock gives the best A/V sync results ( because audio follows video clock already in the PC ). I do not have a hd receiver at home ( thanks also to Newcairel!:) ), but maybe somebody can share his experiences when bistreaming and using external receiver to decode the streams. What I would like to know is, if there is no A/V sync issue as mentioned here (http://forum.doom9.org/showthread.php?p=1471510#post1471510)
Thanks
Pluto
nevcairiel
9th March 2011, 20:53
Both of these are already planned. Downmixing in the audio decoder, of course, and bitstreaming in the splitter. :)
Not sure when i'll be able to do those, though.
SamuriHL
9th March 2011, 21:10
Come on, do bitstreaming. you know you wanna. :D
fastplayer
9th March 2011, 21:18
Both of these are already planned. Downmixing in the audio decoder, of course, and bitstreaming in the splitter. :)
Not sure when i'll be able to do those, though.
Maybe you could add a "planned features" section to your 1st post in this thread. This way you don't have to repeat yourself over and over again. Oh, and don't forget the mandatory "When it's done!" :D
SamuriHL
9th March 2011, 21:20
Maybe you could add a "planned features" section to your 1st post in this thread. This way you don't have to repeat yourself over and over again. Oh, and don't forget the mandatory "When it's done!" :D
Febru....oh, wait. :D
nevcairiel
9th March 2011, 21:37
I added a small section to my second post, but i also wrote a post on my new blog about plans, a bit more detailed (mostly about BD support), but again no time frames.
http://1f0.de/2011/03/lav-filters-0-18-future-plans/
All hail the default wordpress skin, and my few hours old blog. :P
fastplayer
9th March 2011, 21:48
A blog? That's even better, of course! :thanks:
nevcairiel
9th March 2011, 21:53
I just setup the thing a few hours ago, wonder how long i'll keep posting there %)
jmone
9th March 2011, 22:03
Well I just linked to your blog for the JR Media Center devs to see what your plans are (as per my PM did you contact them, they are keen to discuss what player support you may need for this)
adam777
9th March 2011, 22:03
Any idea regarding where, in terms of importance, pes streams rank?
nevcairiel
9th March 2011, 22:05
Well I just linked to your blog for the JR Media Center devs to see what your plans are (as per my PM did you contact them, they are keen to discuss what player support you may need for this)
I didnt contact them yet, i've been busy with work and out of town the last few days, but stuff is cooling down now, and i should manage to get all that done soon.
I also don't have a concrete interface yet, but that should come up in the next days/week too.
Any idea regarding where, in terms of importance, pes streams rank?
Its not that big of a project, i should be able to get it done somewhere in between.
jmone
9th March 2011, 22:34
Dumb Q - when upgrading can just update (eg copy over) the files, or should I run the uninstall / install bat files each time?
nevcairiel
9th March 2011, 22:39
Most of the time you can just copy the new version over, but some things, like the Merit change in 0.18, require you to re-register the filter. Same goes when adding new formats to either the splitter or decoder.. In general, its always safer to just re-register it. -- btw, uninstalling is usually never required, just running install again is fine. :)
jmone
9th March 2011, 23:02
Thanks - I'd also replug for the idea of adding the version number in the Filter pages (like other filters) so we know what we are loading (would have saved me looking foolish testing the wrong version!)
nevcairiel
9th March 2011, 23:04
Thanks - I'd also replug for the idea of adding the version number in the Filter pages (like other filters) so we know what we are loading (would have saved me looking foolish testing the wrong version!)
But where is the fun in that! :)
I'll try to remember to add that.
pankov
9th March 2011, 23:16
Guys,
does anybody know how I can check the file version of .ax files on Windows 7?
In Windows XP it was as simple as clicking properties in Windows Explorer but this doesn't work in Win 7 for .ax files. On other hand it does work for .dll files and .exe files.
Any ideas why is that? Am I messing something up?
SamuriHL
9th March 2011, 23:18
See previous comment above yours. Nev was lazy. :D
pankov
9th March 2011, 23:21
Well, it's not only that.
Try checking the same on other .ax files - it won't work. At least it doesn't for me.
If I rename the same file to .dll it will show it's version.
Of course for LAV filters it's an empty field but at least there is a field "Product version", while on .ax files there is no such field.
:(
SamuriHL
9th March 2011, 23:26
Seems to be a Win7 issue.
mindbomb
9th March 2011, 23:29
I still need frame time correction with the cyberlink vc-1 decoder from powerdvd 10, using mpc hc, and lav splitter .18, all 32 bit.
note the disparity between ftc off and on with this sample:
http://www.mediafire.com/?89rtj5yxn9hrkz1
i dont really mind using ftc, so its not a big deal.
also, this change of merit for lav splitter, what does it mean practically for users?
LAV Audio Decoder
- Fixed a bug that caused sample durations to be calculated wrong, causing playback glitches
Thanks very much, I didn't encouter the previous playback problems after some quick testing :).
mindbomb
10th March 2011, 02:26
Sorry, maybe I'm a little thick here...if I add the PDVD decoder to my external filters in MPC-HC, it will do DXVA? Hmm. That has some serious potential on my bedroom HTPC that doesn't have a lot of native power but has an nVidia 450 in it. I may have to check that out. Thanks!
not only will it do DXVA with newer cards, it does DXVA for vc-1 with cards as old as the geforce 6600gt.
for h264 and mpeg 2, i prefer the microsoft dtv-dvd video decoder that comes with win 7 though.
SamuriHL
10th March 2011, 03:00
not only will it do DXVA with newer cards, it does DXVA for vc-1 with cards as old as the geforce 6600gt.
for h264 and mpeg 2, i prefer the microsoft dtv-dvd video decoder that comes with win 7 though.
I'll have to play around with it all when I get a chance. For my main machine, not a problem as I use software decoding. But for that machine, I need some DXVA going on. I'll figure it out.
boyumeow
10th March 2011, 04:26
@mindbomb, higher merit for lav splitter than other splitter (e.g. haali). Thanks.
SamuriHL
10th March 2011, 05:19
Small world, I always use Dark Knight for testing VC-1 playback as well.
I just tried enabling MPC-HC's Frame Time Correction, and it works beautifully - thanks for the tip. :thanks:
EDIT: Just tested with interlaced VC-1, and it works for that too. Really big thanks.
Where is the frame time correction setting? Thanks!
Edit - found it. Rendered settings.
adam777
10th March 2011, 07:43
Any idea regarding where, in terms of importance, pes streams rank?
Its not that big of a project, i should be able to get it done somewhere in between.
:thanks:
nevcairiel
10th March 2011, 07:53
I still need frame time correction with the cyberlink vc-1 decoder from powerdvd 10, using mpc hc, and lav splitter .18, all 32 bit.
note the disparity between ftc off and on with this sample:
http://www.mediafire.com/?89rtj5yxn9hrkz1
i dont really mind using ftc, so its not a big deal.
My testing showed that in Software decoding mode, its fine without FTC, but if i enable DXVA, i need FTC again. Thats so weird!
In any case, I'm not sure if i can solve that, apparently DXVA screws with the timestamps for some reason, so running with FTC might be the easiest solution.
clsid
10th March 2011, 13:17
Could you perhaps implement a "Automatic FTC" in MPC-HC? The idea is as follows:
- Let the renderer enumerate the filters/pins
- check if a VC-1 mediatype is present, and if so check if there is a combination of source filter and decoder that needs FTC, and if so enable FTC
- Remove the manual FTC option
pirlouy
10th March 2011, 18:47
I had reported a bug with LAV and MPC seekbar with old MPEG, but I've just noticed it seems to be a MPC-HC bug, since madVR seekbar works well ! :eek:
leeperry
11th March 2011, 01:02
I've tried 0.18 in PotP....now it's very hard to get it to freeze for a few secs, it's really really rare. OTOH, if I uncheck "keyframe seeking" it very often never starts and I have to kill PotP. Also, seeking often makes very short audio glitches(that never occurs w/ HMS), and when reading MKV(h264+1.5mbit DTS) from a 6X DVD-R, sometimes when seeking I get the audio but the video never catches up. I'll wait for you to add log options.
nevcairiel
11th March 2011, 08:08
At least there is progress, right? :D
nevcairiel
11th March 2011, 18:57
I've been trying to figure out why ffdshow stops displaying subs after a while when used with LAV Splitter, but i have hit a wall. I was using a MKV with embedded VOB subs, and it did seem like every time there was a period of no subs being displayed (no talking), afterwards ffdshow would stop showing them, while the MPC-HC renderer happily continues. With the Gabest MKV Splitter, it works just fine.
What really puzzles me, however, is this: I used a Tee and a Dump filter and wrote the subtitle output of both the Gabest Splitter and of LAV Splitter into a file, including timestamps, flags and everything, and its perfectly identical. Unless ffdshow somehow has special handling when dealing with the Gabest MKV splitter, i don't know what the hell is going on.
I'll probably enhance the Dump filter somewhat to also write down commands like Flush and NewSegment, but i doubt that those are going over the stream mid-playback.
If anyone has any insight in ffdshow sub rendering, now is the time to speak up!
bjd
11th March 2011, 20:21
Yes I have noticed that on some files but the vobsubs tend to look awful so am going to convert to .srt and remux. :)
nevcairiel
11th March 2011, 22:21
I applied some change which fixed the issue for me. A quick outline what i think was/is the problem:
In the mass of audio/video packets in the stream, subtitles only happen very "rarely", and thus i cannot handle them the same as audio/video. Its safe to assume that audio and video packets will always be constantly present, and if i don't see audio for a while, i better look further ahead until i find some, or playback might not be fluid. The problem with subtitles is, that i don't know when the next subtitle will be shown, so i don't know if i have to look ahead to find one. It appears that sometimes (or actually, most of the time), subtitles are not muxed into the file perfectly, so they are "too late". Previously, i had a buffer of around 100 packets which will be read from the file, and cached in RAM until the decoder has time to look at them. Increasing the size of this buffer to 1000 packets also greatly increases the look-ahead in the file, and thus the chance of finding the subtitle packet.
This change also has some positive side-effects on playback over a slow or unstable network connection, or bad optical media, as alot more data is being cached, it can more easily deal with short connection losses or reading errors.
The only downside is that it'll of course use more RAM, as you might've guessed somewhere in the range of 10x the amount as before. However, this is about the same amount of cache now that the MPC-HC internal splitters use (and previously i wondered why they had such a big cache), so its not that much. Before the change, MPC-HC was at around 90MB with LAV Splitter for me, afterwards, on a 1080p VC-1 MKV (directly remuxed from BluRay, high bitrate), its at around 150, the same area where the MPC-HC internal splitter is at.
Anyway, my guess is that no-one would've even noticed, if i hadn't told you. So nothing to see here, move along!
jmone
11th March 2011, 22:45
I've been trying to figure out why ffdshow stops displaying subs after a while when used with LAV Splitter...
Funny - I had the opposite issue with FFDSHOW stopping displaying the subs with MKV rips using Haali Splitter (you had to delect then reslect the subs over and over)! I did post in the FFDSHOW Thread asking if anyone else had seen this but did not get a response. I've had no probs with LAV!
bjd
11th March 2011, 23:54
This change also has some positive side-effects on playback over a slow or unstable network connection, or bad optical media, as alot more data is being cached, it can more easily deal with short connection losses or reading errors.
@Nevcairel I would imagine once you get the seamless branching in bluray working in LAV, you would probably had to have done something along these lines anyway, but I could be wrong.
The latest filters seems to work better than ever btw, and the audio filter now works with the mpc-hc .ifo stream filter :)
keep up the good work
nevcairiel
12th March 2011, 00:10
Funny - I had the opposite issue with FFDSHOW stopping displaying the subs with MKV rips using Haali Splitter (you had to delect then reslect the subs over and over)! I did post in the FFDSHOW Thread asking if anyone else had seen this but did not get a response. I've had no probs with LAV!
I still wonder why it only happend with ffdshow. It must be a bug on their end, but sending the subs earlier seems to work around it, for some arcane reason.
Subtitles are such a messed up situation in general <.<
SamuriHL
12th March 2011, 00:14
I still wonder why it only happend with ffdshow. It must be a bug on their end, but sending the subs earlier seems to work around it, for some arcane reason.
Subtitles are such a messed up situation in general <.<
No kidding. It's something I hope that can get sorted out. Subs are a major pain.
bjd
12th March 2011, 00:38
Subtitles are such a messed up situation in general
They are, but your splitter handles them as well as anything.
jmone
12th March 2011, 01:00
It seems to be certain combos of what subs, how they are muxed, which splitter and FFDSHOW - it is a real PITA. I (like many others) just want forced subs to appear in the lang of choice automagically just like the commercial players do with discs.
jmone
12th March 2011, 01:15
nevcairiel, got a test file for you to have a look at if you can - http://www.megaupload.com/?d=D0HBS7O3 (it is a 10sec 25mbps 1080/50p H.264/MEPG-4 AVC High@L4.2 camcorder file that has been re-encoded with PowerDirector9). The original files play fine, but when editied / re-encoded with PD9 I "think" Cyberlink write the video header out oddly as I get no video when using the LAV or Haali Splitter but it works fine with MPC (tsMuxeR also does not recognise the Video Stream but eac3to is fine). My current "fix" to make these files LAV friendly is to demux with eac3to and remux with tsMuxeR to "fix" the container (if that is what is wrong).
Thanks
Nathan
jmone
12th March 2011, 01:28
LAVAudio decoder Qs: Great filter and pretty well does all I need (as I just want to decode to LPCM - I DSP in other filters) with the excpetion of DTS-MA. Are there any plans to support decoding the full HD stream (instead of the Core), or can we have an option to hit the Arcsoft HD audio decoder for just this (eg if we have it registered as a filter http://forum.doom9.org/showthread.php?t=154070&page=5 or even if it is possible like madshi does it in via the api in eac3to ) from your filter as I'm having issues trying to selectivly load the audio filters for just DTS-MA.
nevcairiel
12th March 2011, 08:29
nevcairiel, got a test file for you to have a look at if you can - http://www.megaupload.com/?d=D0HBS7O3 (it is a 10sec 25mbps 1080/50p H.264/MEPG-4 AVC High@L4.2 camcorder file that has been re-encoded with PowerDirector9). The original files play fine, but when editied / re-encoded with PD9 I "think" Cyberlink write the video header out oddly as I get no video when using the LAV or Haali Splitter but it works fine with MPC (tsMuxeR also does not recognise the Video Stream but eac3to is fine). My current "fix" to make these files LAV friendly is to demux with eac3to and remux with tsMuxeR to "fix" the container (if that is what is wrong).
Thanks
Nathan
I briefly looked at the sample, and my first guess is that it failed to properly mux the H264 in Annex B format, that is with the SPS/PPS headers interleaved in the video stream, and as a result the decoders do not find them. I currently do not have any code that can "fix" such cases, maybe reporting the file to ffmpeg roundup has some more success, as it may still be something else, or they can somehow add a better handling for this in the h264 decoder/parser.
LAVAudio decoder Qs: Great filter and pretty well does all I need (as I just want to decode to LPCM - I DSP in other filters) with the excpetion of DTS-MA. Are there any plans to support decoding the full HD stream (instead of the Core), or can we have an option to hit the Arcsoft HD audio decoder for just this (eg if we have it registered as a filter http://forum.doom9.org/showthread.php?t=154070&page=5 or even if it is possible like madshi does it in via the api in eac3to ) from your filter as I'm having issues trying to selectivly load the audio filters for just DTS-MA.
Decoding DTS-HD MA will be supported when/if ffmpeg supports it, which i don't think anyone is working on, because the spec isn't what i would call freely available.
Sadly, the decoder does not get told which profile the DTS audio is, until it starts decoding, so the only solution right now would be to decode all DTS with the ArcSoft decoder. The splitter knows however, so maybe i can add an option in there to disable the "default" DTS Media Type when a HD extension is detected, and only send the DTS2 Media Type, which the ArcSoft decoder uses, but LAV Audio doesn't.
I'll ponder on that solution some.
Plutotype
12th March 2011, 09:39
Regarding last posts about the splitter:
1. How can I assign keyboard shortcuts to switch between audiostreams handled by the LAVsplitter in MPC-HC?
2. Would it be possible to make splitter displaying DTS-HD streams in MPC-HC filters page more exact?
Currently its like this: dca, 48000 Hz, 5.1, fp32, 1536 kb/s
Requested: dtshd, 48000 Hz, 5.1, fp32, 1536 kb/s
Requested: dts, 48000 Hz, 5.1, fp32, 1536 kb/s
True HD streams show truehd, LPCM shows pcm-bluray, ac3 is ac3.
I know that the blu-ray has to contain further description ( some encodes are fine, include also language ), but is there any way to somehow differ DTS audio streams from DTS-HD in the generic filter description as mentioned above?
3. Is it by design, that by every truehd stream there is additional ac3 ( probably core ) as separate stream to choose in the splitter ( filter page )? This is a good feature, i want to be sure, that its just like i assume.
Thanks
nevcairiel
12th March 2011, 09:51
Regarding last posts about the splitter:
1. How can I assign keyboard shortcuts to switch between audiostreams handled by the LAVsplitter in MPC-HC?
I dunno, that would be something to ask the MPC-HC devs.
2. Would it be possible to make splitter displaying DTS-HD streams in MPC-HC filters page more exact?
The next version will do that, i actually added that just yesterday, funny that you would ask now.
Btw, dca is short for "DTS Coherent Acoustics", the proper name of the format, in the consumer world DTS is mostly just used as a shorthand. :)
3. Is it by design, that by every truehd stream there is additional ac3 ( probably core ) as separate stream to choose in the splitter ( filter page )? This is a good feature, i want to be sure, that its just like i assume.
Yes thats by design, its the AC3 stream muxed into the TrueHD stream for backwards compatibility on BluRays. Should only show up on BluRays, not in MKVs or anything else.
jmone
12th March 2011, 09:54
I briefly looked at the sample, and my first guess is that it failed to properly mux the H264 in Annex B format, that is with the SPS/PPS headers interleaved in the video stream, and as a result the decoders do not find them. I currently do not have any code that can "fix" such cases, maybe reporting the file to ffmpeg roundup has some more success, as it may still be something else, or they can somehow add a better handling for this in the h264 decoder/parser.
Thanks - I don't see it as the splitters job to fix poorly muxed stuff so I'll keep reporting it back to Cyberlink to fix their PD9 muxer.
Decoding DTS-HD MA will be supported when/if ffmpeg supports it, which i don't think anyone is working on, because the spec isn't what i would call freely available.
That is my understanding as well.
Sadly, the decoder does not get told which profile the DTS audio is, until it starts decoding, so the only solution right now would be to decode all DTS with the ArcSoft decoder. The splitter knows however, so maybe i can add an option in there to disable the "default" DTS Media Type when a HD extension is detected, and only send the DTS2 Media Type, which the ArcSoft decoder uses, but LAV Audio doesn't.
I'll ponder on that solution some.
This is a big one as many user here all chasing the "best" possible video and audio output. The only solution I see at present (till there is a DTS-HD freeware decoder) is for the muxer or audio decoder to call the Arcsoft HD Audio decoder. Hope you can think of something "clever" with this as Blu-ray content seems to favour this flavour of Audio Encoding....
Thanks
Nathan
bjd
12th March 2011, 10:21
@jmone what is exactly the issue you have with the Arcsoft decoder ?
It is a reference DTS decoder and decodes any type of DTS you throw at it (DTS, HR, MA and 96/24).
Just to clarify the situaion with TrueHD, The bluray spec requires .m2ts files have to carry an ac3 track with the TrueHD. HD-DVD .evo's don't have this requirement. Mkvs muxed with mkvtoolnix cannot mux the combined truehd/ac3 stream but the Solveig MKV muxer can.
nevcairiel
12th March 2011, 10:25
Just to clarify the situaion with TrueHD, The bluray spec requires .m2ts files have to carry an ac3 track with the TrueHD. HD-DVD .evo's don't have this requirement. Mkvs muxed with mkvtoolnix cannot mux the combined truehd/ac3 stream but the Solveig MKV muxer can.
I tried to find some easy way to tag these streams somehow, so you know its the sub-stream of the TrueHD track, but no luck yet.
vBulletin® v3.8.11, Copyright ©2000-2026, vBulletin Solutions Inc.