View Full Version : LAV Filters - DirectShow Media Splitter and Decoders
Name User
16th June 2013, 01:43
I was using Haali Media Splitter at first, but decided to switch to LAV Filters and noticed when making GIF files with AvsPmod, the file sizes are mostly different.
The smaller sizes with LAV are welcome, but some are bigger. One of the GIFs with Haali is 3.80 MB and the same one with LAV Filters is 5.03 MB.
What causes them to be smaller/bigger with LAV Filters?
ryrynz
16th June 2013, 08:05
Nevcairiel is there any performance improvement to be had with a Haswell based CPU with -march=core-avx2 switches in GCC4.8.1 with LAV?
This article here (http://www.phoronix.com/scan.php?page=article&item=intel_core_avx2&num=1) shows some substantial benefits with some apps.
nevcairiel
16th June 2013, 08:07
All the important code is manually asm optimized in ffmpeg. The difference would be marginal.
Edit:
Did a quick test.
The default build measured an average of 121.19 fps on my choosen sample.
Using -march=core-avx2, the average was 122.71 fps (or 101.2%), hardly worth the custom build, if you ask me.
You can probably get some more speed by adding AVX2 variants of the handwritten ASM code in some situations, though.
petran79
16th June 2013, 16:41
Having two gpus messes up the system...
I have a laptop with an optimus card (nvidia gt555m and intel 3000)
Lav 64 detects cuvid (nvidia gpu light flashes)
It also detects dvxa through intel card. Nvidia light doesnt flash. So lav detects the card but quicksync codec isnt detected
.
for the record, this problem occurs only with Potplayer 64-bit version and LAV Video. Havent tested any other players.
In MPC-HC 64-bit, Intel Quicksync is detected without problems
wanezhiling
17th June 2013, 05:41
Run your PotPlayerMini64.exe in iGPU mode.(go into Nvidia Control Panel to set that.)
ryrynz
17th June 2013, 05:46
Did a quick test.
The default build measured an average of 121.19 fps on my chosen sample.
Using -march=core-avx2, the average was 122.71 fps (or 101.2%), hardly worth the custom build, if you ask me.
Interesting, you were bang on and yes for 1% difference it's not worth it.
You can probably get some more speed by adding AVX2 variants of the handwritten ASM code in some situations, though.
One can hope one of the devs will take an interest in optimizing some code in the future.
Aleksoid1978
17th June 2013, 07:26
nevcairiel
I see you add support for G2M2/G2M3 - but ffmpeg do not support decoding this video.
wanezhiling
17th June 2013, 08:03
About G2M, here is a sample: http://www.sendspace.com/file/ftysdu
blackscreen with lav, fine with offical codec (https://www1.gotomeeting.com/downloads/711919949/C58E664F486384B/null/manualFull/InstallCodec/g2m_codec.exe) :)
Aleksoid1978
17th June 2013, 08:10
About G2M, here is a sample: http://www.sendspace.com/file/ftysdu
blackscreen with lav, fine with offical codec (https://www1.gotomeeting.com/downloads/711919949/C58E664F486384B/null/manualFull/InstallCodec/g2m_codec.exe) :)
Because ffmpeg do not support:
if ((magic & 0xF) != 4) {
av_log(avctx, AV_LOG_ERROR, "G2M2 and G2M3 are not yet supported\n");
return AVERROR(ENOSYS);
}
mecedo
17th June 2013, 09:53
Hi. Can you check this sample:
https://hotfile.com/dl/229086480/56191cb/LAV_error_-_Poklosie_(2012).m2ts.html
I can't manage it. With nvidia GPU it plays without any problems. But on computers with Intel HD Graphics when hardware acceleration is used with LAV Splitter then this movie stutters every second. Changing splitter from LAV Splitter to any other resolves problem.
nevcairiel
17th June 2013, 20:33
I see you add support for G2M2/G2M3 - but ffmpeg do not support decoding this video.
I only copies the FourCCs that ffmpeg recognized for this format, i disable those two again now.
nevcairiel
17th June 2013, 21:00
Hi. Can you check this sample:
https://hotfile.com/dl/229086480/56191cb/LAV_error_-_Poklosie_(2012).m2ts.html
I can't manage it. With nvidia GPU it plays without any problems. But on computers with Intel HD Graphics when hardware acceleration is used with LAV Splitter then this movie stutters every second. Changing splitter from LAV Splitter to any other resolves problem.
I can reproduce the issues, i'll have a look.
Della
17th June 2013, 21:07
Please pardon the newbie type question, but with a new i7 Ivy Bridge, 16gB Ram & SSD build with Nvidia GTX 460 could someone please recommend the best video acceleration method? I'm currently using CUVID, but was wondering if perhaps Intel QuickSync or maybe none would be a better choice.
Thank you.
Della (Dog)
itsonlyjustincase
18th June 2013, 11:40
Depends on what you want to do but overall i'd say QS is the best thing to use
Della
18th June 2013, 12:18
Depends on what you want to do but overall i'd say QS is the best thing to use
Thank you. It's playback quality I am most concerned with, I don't much care about power consumption.
nevcairiel
18th June 2013, 12:19
If you have enough CPU performance, i would use software decoding, its the most reliable and least error prone.
As an alternative, DXVA2 Copy-Back would be my second choice. All others all have some sort of caveats or limitations.
Della
18th June 2013, 12:35
If you have enough CPU performance, i would use software decoding, its the most reliable and least error prone.
As an alternative, DXVA2 Copy-Back would be my second choice. All others all have some sort of caveats or limitations.
Thank you sir, that is exactly what I suspected.
My concern was that one of the other acceleration methods somehow improved quality by allowing playback improvements that software decoding limited because of horsepower.
I'll select NONE for hardware acceleration.
petran79
18th June 2013, 16:23
Run your PotPlayerMini64.exe in iGPU mode.(go into Nvidia Control Panel to set that.)
Same result. Avcodec is active but it reads from nvidia gpu, not intel igpu. Because quicksync is not detected and nvidia light is on. I'd also know from the cpu fan not going active,since there is help from nvidia gpu.
While on mpc hc 64 it reads only from igpu and theres higher cpu load.
nevcairiel
18th June 2013, 16:24
Hi. Can you check this sample:
https://hotfile.com/dl/229086480/56191cb/LAV_error_-_Poklosie_(2012).m2ts.html
I figured out whats wrong with this file, but i'm not sure how to safely fix it without potentially breaking other stuff.
One possible fix would be to turn off the Annex B -> AVC1 conversion. Does anyone still use a broken decoder that can't deal with Annex B H.264 streams?
I'll probably have to think about this for a while. Its a very rare issue, and i don't want to break other stuff by fixing this one file. So don't expect a fix soon, sorry.
wanezhiling
18th June 2013, 16:37
@petran79, whats the result of 32bit player? (PotPlayerMini.exe and mpc-hc.exe)
SeeMoreDigital
18th June 2013, 16:45
I figured out whats wrong with this file, but i'm not sure how to safely fix it without potentially breaking other stuff.
One possible fix would be to turn off the Annex B -> AVC1 conversion. Does anyone still use a broken decoder that can't deal with Annex B H.264 streams?
I'll probably have to think about this for a while. Its a very rare issue, and i don't want to break other stuff by fixing this one file. So don't expect a fix soon, sorry.I've just discovered that if mecedo's .m2ts source is re-muxed into the .MKV container, it plays okay ;)
Soukyuu
18th June 2013, 17:13
What could be the reason for LAV taking longer to jump to certain mkv chapters? For example, a jump to 00:12:20.573 takes <1 second, a jump on the same file to 00:12:20.570 take 1-3 seconds to complete, using the same jumping sequence (e.g.: jumping OP -> partA -> partB)
sneaker_ger
18th June 2013, 17:17
Seeking performance is highly depended on the position of the keyframes. If there's a keyframe at exactly 00:12:20.573, but the preceding one is at 00:12:15.000, the seeking will take way longer for the 570 seek. Look up the keyframe positions to see if this is the case.
DarkSpace
18th June 2013, 17:19
What could be the reason for LAV taking longer to jump to certain mkv chapters? For example, a jump to 00:12:20.573 takes <1 second, a jump on the same file to 00:12:20.570 take 1-3 seconds to complete, using the same jumping sequence (e.g.: jumping OP -> partA -> partB)
That depends on the file, but one possible reason is that there is no seekpoint at the Chapter Point. In this case, I define a seekpoint as a point from where the video and audio streams can be decoded without requiring data from before that point in time. With an AVC Video Stream, this means that at this timecode, there's a Keyframe.
nevcairiel
18th June 2013, 17:28
I've just discovered that if mecedo's .m2ts source is re-muxed into the .MKV container, it plays okay ;)
The problem with the file is that its muxed badly, so remuxing would fix it, indeed.
What could be the reason for LAV taking longer to jump to certain mkv chapters? For example, a jump to 00:12:20.573 takes <1 second, a jump on the same file to 00:12:20.570 take 1-3 seconds to complete, using the same jumping sequence (e.g.: jumping OP -> partA -> partB)
Like the others said, if there is a seek point, it'll seek basically instantly, otherwise it'll seek to the previous seek point and decode from there, depending on the speed of the decoder this can take a bit longer.
So assuming there is a seek point at 00:12:20.573, there obviously isn't going to be one just 3ms before.
SeeMoreDigital
18th June 2013, 18:19
The problem with the file is that its muxed badly, so remuxing would fix it, indeed.
Looks as though TSDoctor is able to repair the .m2ts stream so it can be played with LAV Filters ;)
nevcairiel
18th June 2013, 18:21
Which would indicate its broken, yes? :)
SeeMoreDigital
18th June 2013, 18:26
Which would indicate its broken, yes? :)Actually, I've just noticed that when I installed TSDoctor, it sneakily installed Haali's splitter as well. And it was this splitter that enabled the .m2ts file to be played :scared:
As soon as I removed Haali's splitter, the .m2ts file would not play correctly :mad:
nevcairiel
18th June 2013, 18:28
I can change some knobs in LAV Splitter as well and it will play properly, but i'm somewhat certain that it might break other files instead, or interaction with some decoders, so its all a bit complicated.
I'll keep thinking about it, i put it on my task list so its not forgotten.
Aleksoid1978
19th June 2013, 00:17
nevcairiel
Hi. Can you add support Crop parameters from matroska files in splitter. Set this parameters to VIDEOINFOHEADER->rcSource/rcTarget.
MPC-BE:
http://s019.radikal.ru/i619/1306/50/5ec76d1c9bc6t.jpg (http://radikal.ru/F/s019.radikal.ru/i619/1306/50/5ec76d1c9bc6.png.html)
Video: MPEG4 Video (H264) 854x480 25fps
AM_MEDIA_TYPE:
majortype: MEDIATYPE_Video {73646976-0000-0010-8000-00AA00389B71}
subtype: MEDIASUBTYPE_AVC1 {31435641-0000-0010-8000-00AA00389B71}
formattype: FORMAT_MPEG2_VIDEO {E06D80E3-DB46-11CF-B4D1-00805F6CBBEA}
bFixedSizeSamples: 1
bTemporalCompression: 0
lSampleSize: 1639680
cbFormat: 176
VIDEOINFOHEADER:
rcSource: (70,40)-(600,400)
rcTarget: (70,40)-(600,400)
dwBitRate: 0
dwBitErrorRate: 0
AvgTimePerFrame: 400000
MPC-BE + LAV Source:
http://s53.radikal.ru/i140/1306/ac/8881e2605968t.jpg (http://radikal.ru/F/s53.radikal.ru/i140/1306/ac/8881e2605968.png.html)
Video: MPEG4 Video (H264) 854x480 (137:77) 25fps
AM_MEDIA_TYPE:
majortype: MEDIATYPE_Video {73646976-0000-0010-8000-00AA00389B71}
subtype: MEDIASUBTYPE_AVC1 {31435641-0000-0010-8000-00AA00389B71}
formattype: FORMAT_MPEG2_VIDEO {E06D80E3-DB46-11CF-B4D1-00805F6CBBEA}
bFixedSizeSamples: 0
bTemporalCompression: 1
lSampleSize: 1
cbFormat: 169
VIDEOINFOHEADER:
rcSource: (0,0)-(854,480)
rcTarget: (0,0)-(854,480)
dwBitRate: 0
dwBitErrorRate: 0
AvgTimePerFrame: 400000
sample - http://aleksoid.voserver.net/Sample/cropping_sample.mkv
nevcairiel
19th June 2013, 07:13
Maybe later, not happening soon, too many problems involved to do it properly.
Kinjal
19th June 2013, 07:44
Nevcairiel
Can you please:
1. add support for chapters(cuesheets) in ape/flac/wv?
2. add support for more ID3 tags in MP3?
MPC, Internal filters:
http://light-alloy.ru/temp/mpc-internal_filters.png
MPC, Lav Splitter:
http://light-alloy.ru/temp/mpc-lavsplitter.png
File for test:
http://light-alloy.ru/_nev/02_Theme_Of_SSS.mp3
3. Add support for IDSMResourceBag / IPropertyBag interface, so media players will be able to request and show covers(which could have mimes: image/jpeg, image/jpg, image/png) from mp3/flac/ape (without depending on MediaInfo).
Thanks :)
petran79
19th June 2013, 07:47
@petran79, whats the result of 32bit player? (PotPlayerMini.exe and mpc-hc.exe)
they detect the codec properly (quicksync in LAV Video)
same with mpc hc-64 (quicksync in LAV Video)
but in Potplayer 64 If I set it to Quicksync I get avcodec instead. Quicksync is not detected and Nvidia GPU decodes through avcodec. Same if I set it to software mode. Avcodec and Nvidia are used instead.
cuvid and dvxa codecs are detected properly through Nvidia.
hence I dont know if its a Potplayer 64, LAV 64 or Windows 7 issue
nevcairiel
19th June 2013, 08:23
Nevcairiel
Can you please:
1. add support for chapters(cuesheets) in ape/flac/wv?
2. add support for more ID3 tags in MP3?
3. Add support for IDSMResourceBag / IPropertyBag interface, so media players will be able to request and show covers(which could have mimes: image/jpeg, image/jpg, image/png) from mp3/flac/ape (without depending on MediaInfo).
I put these on my task list, but not sure when i'll get to it.
Nicola
19th June 2013, 15:01
1. Thank you for adding suppost for ordered chapters and segment linking.
2. I found a small issue with one .mkv which uses ordered chapters, plays fine with haali or smplayer; what do you need and where should I post the thing? the 2 feedback link on 1st page don't work (I get a 404).
nevcairiel
19th June 2013, 15:43
I need the file that has problems, or at least the part of the file with the problem. If a smaller part can reproduce the issue properly, that is preferable.
Upload the sample somewhere, DropBox or Google Drive or Sky Drive, or one of the free hosts like MediaFire, and just link it here or PM me the link.
Nicola
19th June 2013, 16:16
OK, I'll see what I can do, slow up here.
Oh, now those 2 links load. gotta check my dns settings.
Nicola
19th June 2013, 16:31
OK, got lucky and the stuff is still on the web.
(links removed)
The glitch happens at the end of the episode, just before the ending theme (1s before the chapter), some frame get repeated fast, and then the ED starts.
Other episodes exibit the same behaviour (just with lav splitter, haali is fine, and smplayer too).
I put there the OP in case you want to check it too.
nevcairiel
19th June 2013, 17:01
Thanks, i'll have a looksie. Sounds odd though, usually with the ED in its own file, there shouldn't be any hiccups. But i'll see whats going on!
Edit:
One thing i know is that it doesn't actually link to the ED, it has its own ED inside the file.
nevcairiel
19th June 2013, 19:14
I managed to fix this specific file by tweaking some values, however i'll have to think about a more generic solution for this specific problem.
The real problem is that the chapter for the ending isn't perfectly on the same timecode as the Cue, so seeking is getting a bit weird there.
Now i tweaked the fuzzy matching for this, so that it'll look for a Cue point within the duration of one frame, because that would end up the same anyway. This file is only 10ms off with its Chapter, and the frames are 41ms, so that works out, but its still only a "fuzzy" solution, so, meh.
I'll put it on my list.
Nicola
19th June 2013, 20:19
It doesn't link to the external ED? mmm, curious, maybe ext ED is used by later eps only?
Nice being on your list, it is a good thing. Thanks.
In any case, you can always check how smplayer handles this.
As soon the next lav is out I'll check all of those pesky files.
(removed the links)
Aleksoid1978
19th June 2013, 23:20
hi nevcairiel
Question - why do you have such an output channel mask:
http://i.imgur.com/KhqHz7R.png
Why is different. I think it's must equal.
I check other audio with different channels - it's happened only with 5.1 input.
DarkSpace
19th June 2013, 23:55
hi nevcairiel
Question - why do you have such an output channel mask:
Why is different. I think it's must equal.
I check other audio with different channels - it's happened only with 5.1 input.
You probably have the Option to convert to standard Channel Layouts enabled in LAV Audio.
kasper93
20th June 2013, 00:35
I found minor bug changing mixer options work instantly, but "status" tab is not updated to reflect changes.
Aleksoid1978
20th June 2013, 00:45
You probably have the Option to convert to standard Channel Layouts enabled in LAV Audio.
No - i enable/disable this options. Do not change. And - 5.1 it's a standard channel layout.
DarkSpace
20th June 2013, 02:09
No - i enable/disable this options. Do not change. And - 5.1 it's a standard channel layout.
Okay, my apologies then. This sounds weird, indeed. Is it specific to ac3 files? Anyway, I believe a sample may help.
Aleksoid1978
20th June 2013, 02:35
Okay, my apologies then. This sounds weird, indeed. Is it specific to ac3 files? Anyway, I believe a sample may help.
Any 5.1 audio. Open any files with 5.1 audio and see channel mask in LAV Audio 'status' tab.
truexfan81
20th June 2013, 07:11
Any 5.1 audio. Open any files with 5.1 audio and see channel mask in LAV Audio 'status' tab.
i love it when i look at my LAV and see it say "bitstreaming" :D
Aleksoid1978
20th June 2013, 07:28
i love it when i look at my LAV and see it say "bitstreaming" :D
What about FLAC/PCM 5.1 :) ???
truexfan81
20th June 2013, 08:17
What about FLAC/PCM 5.1 :) ???
have to use a different decoder for that, with a slight quality loss i can have ffdshow tryouts encode it to ac3 5.1 and bitstream it
receiver is old enough it doesn't have hdmi, so i use toslink
vBulletin® v3.8.11, Copyright ©2000-2026, vBulletin Solutions Inc.