Log in

View Full Version : LAV Filters - DirectShow Media Splitter and Decoders


Pages : 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 [199] 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 302 303 304 305 306 307 308 309 310 311 312 313 314 315 316 317 318 319 320 321 322 323 324 325 326 327 328 329 330 331 332 333 334 335 336 337 338 339 340 341 342 343 344 345 346 347 348 349 350 351 352 353 354 355 356 357 358 359 360 361 362 363 364 365 366 367 368 369 370 371 372 373 374 375 376 377 378 379 380 381 382 383 384 385 386 387 388 389 390 391 392 393 394 395 396 397 398 399 400 401 402 403 404 405 406 407 408 409 410 411 412 413 414 415 416 417 418 419 420 421 422 423 424 425 426 427 428 429 430 431 432 433 434 435 436 437 438 439 440 441 442 443 444 445 446 447 448 449 450 451 452 453 454 455 456 457 458 459 460 461 462 463 464 465 466 467 468 469 470 471 472 473 474 475 476 477 478 479 480 481 482 483 484 485 486 487 488 489 490 491 492 493 494 495 496 497 498 499 500 501 502 503 504 505 506 507 508

CruNcher
15th March 2012, 17:56
WOW :)

Thanks that did the trick:)

Currently LAV Video reports that QuickSync is "Available" and "Active" during a video playback and EVR reports that Render Device is ATI Radeon 6450!!!

Am i right when i assume that Deinterlacing is done by ATI atm?

Now that i got this working, may i ask if this is generaly a suggested way of watching 1080p or at least is it any better than DXVA CB? I need DXVA CB cause i am gonna apply postprocessing.

Nobody benched the difference between Virtu and this way yet :) also how different things will work and how they will work together is mostly uknown i would say when doing such things for most also taking things like Aero into account and different stuff running @ different times on the surfaces and what that causes :D in terms of Performance also how for example is specific software reacting to this like capture things :)
In the playback case you have the Asic which sends the data to the CPU/GPU which sends it to the discreet GPU and back to the renderer of course that is implying overhead then compared when you do it in 1 straight way but the Asic is so fast that it might be usefull @ all, especialy if you start to mix different things together on both sides in a efficient way (managing different tasks) :D :)

Kotik
15th March 2012, 18:04
Well the main reason behind that is the fact that DXVA CB with an ATI vga is not something generaly suggested. So i thought QuickSync is then the next best thing considering that i want to apply postprocessing.

nevcairiel
15th March 2012, 18:05
Using QuickSync for decoding and then your dedicated card for display is certainly fine. I would probably also consider software decoding if you have a beefy CPU.

Note that post-processing on interlaced material is not a good idea (unless the first step of that post-processing is deinterlacing)

Kotik
15th March 2012, 18:32
Well my cpu (i3 2105) meter sits @ 7% with DXVA Native and @ 10% with QuickSync on a 1080p H264 video. So thats not a huge diference if u ask me:)

What is funny though is that now i have to keep an eye for shitty drivers by both ATI and Intel:) That sounds interesting, hehe

mindbomb
15th March 2012, 18:58
From what i've seen and heard so far, it seems fine for 24p/25p/50i/60i material on 4000 series and above cards. Some cards seem to also be able to handle 50p and 60p.
Starting with the 7000 series, the speed has increased again and 50p and 60p are fine across the board.


This was 1080p24. Latest official catalyst drivers.
I'm thinking that dxva copyback requires at least uvd 2.2.
"The UVD 2.2 features a re-designed local memory interface" - wikipedia

so that would explain poor performance on the 4850 and 4870, which have uvd 2.0.

nevcairiel
15th March 2012, 19:13
If it doesn't work for you, don't use it. :)
Nothing i can do.

I still stick by my opinion that the renderer queue doesn't indicate a too slow decoder directly.
Check the decoder queue, if thats empty its obvious.

mindbomb
15th March 2012, 22:53
Yea, it's not a big deal, I can manage without hardware acceleration on that computer anyway. It's just that I have been recommending people with amd graphics cards to try out dxva copyback with madvr, but perhaps I should add a warning for people with older cards.

Another thing, with the latest stable nvidia drivers, there is occassional artifacts with vc-1 for vp2 hardware in cuvid.
I assume it is all driver related, so is there one that anyone can recommend?

edit: i found that I had to go back all the way to forceware 275. Someone tell nvidia to fix it in their newer drivers!

FlashGordon
16th March 2012, 00:59
Nev, I have an anamorphic PAL DVD that isn't displayed with the correct AR when LAV splitter and LAV video are used. If I open the full DVD (MS DVD navigator is used) and use libmpeg2 as decoder the AR is correct. If I open either a VOB or the corresponding .IFO, I get the wrong AR with LAV. "Use Stream AR" is checked in LAV Video. Is this expected behavior considering LAV can't access the VIDEO_TS.IFO at the moment?

Pat357
16th March 2012, 02:58
I have a problem with a DVD remux: DXVA doesn't work with that MPEG2 interlaced, neither copy back nor native. CUVID works.
A sample would probably help, I guess.

Edit : what renderer are you using ? (EVR, EVR-CP, MadVR, VMR9, ...)

magic144
16th March 2012, 03:31
@Flash, it's possible that the VIDEO_TS.ifo contains some info that is needed to correctly render the AR of the feature.

also, I was under the impression that LAV wasn't (yet) supposed to work with DVD Video...?

oddball
16th March 2012, 03:39
Any chance of adding RIFF WAVE DTS audio support? Let me clarify that by adding that it is RIFF WAVEfmt in the header. Same goes for some AC3 files I have.

EDIT: Nevermind. I've decided to use bsconvert on them all. BTW that speedup on one particular DTS file still exists. If I bitstream with ffdshow it plays at the correct speed so something in the path of LAV Audio filter does something weird to the stream inccorectly flagging it as 48Khz methinks so the receiever tries to decode it as such.

All very odd. If I can find a way to split the file I will send you a chunk to playback for yourself.

nevcairiel
16th March 2012, 07:27
Like i explained before, when bitstreaming the decoder does not flag a file as anything. Its all in the DTS headers themself. I also explained that when i used ffdshow on that file, i got no playback, but with LAV it was fine. So something is odd in your receiver that somehow combined with ffdshows oddnes makes for working audio again. :d

zmaster
16th March 2012, 11:37
Hello!
Sorry, if has already been reported about it.

When I use the path Programs - LAV Filters - LAV audio Configuration, the window looks like this - http://firepic.org/images/2012-03/16/az9v6wde1s34.png Settings are not available.
When I use the filters manager in the player (to open LAV Audio Decoder settings) - have no problem's - http://firepic.org/images/2012-03/16/gpvm92s293bp.png

WinXP SP3 x86, LAV Filters v0.49, WinXP default theme.

nevcairiel
16th March 2012, 11:38
I tried to reproduce this problem on Windows XP, and everything is fine for me. Cannot reproduce, cannot fix.

roytam1
16th March 2012, 12:17
I tried to reproduce this problem on Windows XP, and everything is fine for me. Cannot reproduce, cannot fix.

rundll32 in localized version of Windows XP will use localized font height, which leads to incomplete showing the property page.

nevcairiel
16th March 2012, 12:28
rundll32 in localized version of Windows XP will use localized font height, which leads to incomplete showing the property page.

If you looked at the screenshot, you would know that this is not the problem. The screen is generally way too small and not just a little bit smaller.
Also, last report i got about this claimed that LAV Video didn't have this problem.

aufkrawall
16th March 2012, 13:15
A sample would probably help, I guess.

Edit : what renderer are you using ? (EVR, EVR-CP, MadVR, VMR9, ...)
Since I tried also DXVA native, I also tried EVR-CP.
The renderer doesn't matter, it's just a decoder issue.

How to provide a sample?
It's a DVD remux, a bit too big to upload.

nevcairiel
16th March 2012, 13:35
Cut a small sample using some tool like DGSplit, check if the problem persists. Should preferably be at least 10 seconds of playback, maybe 20-30MB in size.

zmaster
16th March 2012, 14:03
...last report i got about this claimed that LAV Video didn't have this problem.Yes, the LAV Video Configuration (Programs - LAV Filters - LAV Video Configuration) is displayed correctly.

DragonQ
16th March 2012, 15:46
What he means is that the last person to have a similar problem was having it with the LAV Audio Configuration window (I think) but the LAV Video Configuration window was fine. For you, it's the other way around.

zmaster
16th March 2012, 16:36
Hmm...
I'm trying to say that I have no problems with the «LAV Video Configuration» (and «LAV Splitter Configuration») windows. The my problem only with the «LAV Audio Configuration» window.

MasterNobody
16th March 2012, 17:39
Hmm...
I'm trying to say that I have no problems with the «LAV Video Configuration» (and «LAV Splitter Configuration») windows. The my problem only with the «LAV Audio Configuration» window.
So same as for me. And that was also on Russian Windows XP SP3.

P.S. At work with Russian Windows 7 all is OK.

nevcairiel
16th March 2012, 19:31
Here is a new build that requires some testing to ensure there are no regressions:

http://files.1f0.de/lavf/LAVFilters-0.49-15-g7a6833a.zip

The big change is that i moved all the actual decoding onto a worker thread. This has the advantage that the decoder can continue working while another thread is performing the final changes to the image (like RGB conversion and whatnot).

For now, only the WMV DMO decoder and DXVA2-CB take full advantage of this (and may have gotten a bit more faster again)
The reason only the these decoder uses this properly is because it was much simpler for them because i can freely manage the memory buffers. ;)

The important part is that the behavior should not have changed from 0.49 release to this version. If something is broken that worked in the release version, i need to fix it, so let me know.

CruNcher
16th March 2012, 20:58
There is a major difference :(

MPC-HC trunk (using SPP fast to pressure 1 core fully)

Lav Video DXVA-CB LAVFilters-0.49-yadifmt2.zip = http://img21.imageshack.us/img21/3412/lavvideodxvacbevrbasicn.png
Lav Video DXVA-CB LAVFilters-0.49-15-g7a6833a.zip = http://img24.imageshack.us/img24/3412/lavvideodxvacbevrbasicn.png

also the peaking in the non cb decoder avcodec is still their, and the extreme stucks , heavy decoding drop outs and unsync :( not such issues in this setup http://img40.imageshack.us/img40/8521/mpchc4148andtester4075.png

ForceX
16th March 2012, 21:21
When used with madVR, seeking forward then backward when using CUVID sets all the queues to 0 and makes it impossible to play. Seems to happens with DXVA CB but less frequently.

nevcairiel
16th March 2012, 21:22
Seeking will always set the queues to zero, thats just how seeking works.

Mercury_22
16th March 2012, 21:29
Nev is there a "Pan-scan" feature in FFmpeg that you didn't implemented yet in LAVVideo, but exist in FFD ?[vc1 @ 24383a00] Pan-scan not implemented. Update your FFmpeg version to the new
est one from Git. If the problem still occurs, it means that your file has a fea
ture which has not been implemented.
[vc1 @ 24383a00] get_buffer() failed (-1 0 00000000)

CruNcher
16th March 2012, 21:32
The DXVA-CB decoding overhead is @ 50% now before it was @ 25% something is wrong it doubled @ decoding
native DXVA2 @ Mpeg-2 Decoding is still awesome :) though still the 720p MTV stream crashes

aufkrawall
16th March 2012, 21:36
Seeking in general is bad with this build - often video playback stalls (DXVA CB).

But it fixes the problem with MPEG2.

CruNcher
16th March 2012, 21:42
aufkrawall wouldn't surprise with the higher overhead + the load @ the seek it goes boom ;)

ForceX
16th March 2012, 21:55
Seeking will always set the queues to zero, thats just how seeking works.

I meant it stays at 0 and doesn't play. I thought it might be related to the "Delay playback until render queue is full" option being enabled but it isn't. Trying to seek more or stopping doesn't start playback in MPC-HC.

nevcairiel
16th March 2012, 21:56
Nev is there a "Pan-scan" feature in FFmpeg that you didn't implemented yet in LAVVideo, but exist in FFD ?

ffmpeg/libav do not support Pan-Scan in VC-1, so neither does ffdshow. That message is just a warning, nothing more.
Personally, i have never seen a file that used Pan-Scan, so its more likely that the frame header is broken.

nevcairiel
16th March 2012, 22:09
Here is a new build that fixes the extra cpu load, had one wait condition the wrong way around =p

http://files.1f0.de/lavf/LAVFilters-0.49-17-gd8878bb.zip

nevcairiel
16th March 2012, 22:23
Thats normal, the splitter creates one thread for every pin, and all other filters sit on that thread by default. If ffdshow uses a very expensive filter, it should create a worker thread for that, if it doesn't do that, it'll possibly bottle-neck the decoder.

CruNcher
16th March 2012, 22:30
yep just saw it thouhg it doesn't seem to affect Gabest Decoder @ all @ least there are no massive drop outs though the strangest is that it keeps sync to the audio which lav video is losing also the FPS isn't changing @ the ffdshow osd with lav video but stays @ 23.999 fps with Gabest Decoder it changes continuously (Render FPS) see screenshots :)

nevcairiel
16th March 2012, 22:36
The Gabest decoder implements IQualityControl, with which the renderer can tell the decoder to drop frames to keep sync.
I didn't bother to implement that, because if your system is too slow, you're screwed anyway.

aufkrawall
16th March 2012, 22:37
aufkrawall wouldn't surprise with the higher overhead + the load @ the seek it goes boom ;)
Seems you were right, seeking seems to be fine again with the new build. :)

nevcairiel
16th March 2012, 22:38
There is a bug with madVR and DXVA2-CB that causes playback to break sometimes in the test build, but i don't know why. Suddenly madVR stops accepting frames. I put the question to madshi, see what he can figure out.

Edit:
Nevermind, found the bug, was my fault afterall. :p

Boltron
16th March 2012, 23:09
I am having seeking issues with LAVFilters-0.49-17-gd8878bb. Win7 x64 but using all x86 versions. Latest MPC-HC 1.6.1.4150 (happened with slightly older version also). Tested with 3 MKVs all V_MPEG4/ISO/AVC at 23.976 with bitrates from 8-32Mb/sec and DTS/AC3 audio. Using MPC-HC with LAV Splitter/Video/Audio and madVR in Windowed mode with ATI 5670.

Seeking mostly works fine however playback will hang intermittently. Seems to happen more often on 60 sec jumps and not so often on Chapter jumps. It may work fine 10 times in a row but it does hang/freeze. I have no problems with the proper 0.49 version. Playback just stops/freezes, MPC-HC still responsive though, I can click on menu commands. CPU is idle, disk is fine.

nevcairiel
16th March 2012, 23:11
Last for today, this fixes seeking with madVR again:

http://files.1f0.de/lavf/LAVFilters-0.49-19-gd92f96a.zip

Should now hopefully be back to 0.49 behavior, if not better sometimes.

Boltron
16th March 2012, 23:54
With LAVFilters-0.49-19-gd92f96a, my seeking issues are... gone :)

noee
17th March 2012, 01:23
Solid. fwiw, DXVA2_CB is now faster than WMVDmo on VC1 stuff on AMD HD6570/Athlon II. No seeking/playback issues at all with jRiver ROHQ...

CruNcher
17th March 2012, 03:18
The Gabest decoder implements IQualityControl, with which the renderer can tell the decoder to drop frames to keep sync.
I didn't bother to implement that, because if your system is too slow, you're screwed anyway.

Ahh that would explain the difference of Microsofts and Gabest Decoder compared to the others i guess in this scenario, keeping a rather acceptable Playback experience under extreme Pressure :)

Microsoft
Gabest
Cyberlink
Arcsoft

seem to implement it with Gabest (MPC-HC default) and Microsoft showing the best Performance results (latency)

Last for today, this fixes seeking with madVR again:

http://files.1f0.de/lavf/LAVFilters-0.49-19-gd92f96a.zip

Should now hopefully be back to 0.49 behavior, if not better sometimes.


Nice gain it beats Quicksync for Mpeg-2 in both Memory and utilization @ Playback :)

btw i found that this strange peaking @ decoding is only visible with Multithreading @ auto when Multithreading @ 1 (disabled) there is no peaking

The slightly stuck @ Rendering can be experienced with Lav Video under Pressure every 4 seconds
With a Decoder implementing IqualityControl the Experience is much better as the drop outs aren't in such a repeated pattern and it keeps sync :)

CruNcher
17th March 2012, 04:57
Here is a test result :)

Current MPC-HC (user default) = http://img828.imageshack.us/img828/5317/mpchcgabestiquality.png
MPC-HC Lav Video (avcodec) = http://img252.imageshack.us/img252/604/mpchclavvideonoiquality.png
MPC-HC Microsoft DTV = http://img703.imageshack.us/img703/9927/microsoftdtviquality.png

The Playback Stability experience with Gabest Decoder is much much better, keeping the Sync and overall playback no real deceiving drop outs
Microsofts Decoder has some really visual perceivable drop outs, though not as heavy as Lav Video :(

nevcairiel
17th March 2012, 08:08
Found broken playback on this Youtube FLV. http://www.mediafire.com/download.php?2sn8917ki3bftaz


Seems to play just fine in the latest version.

Gleb Egorych
17th March 2012, 10:35
nevcairiel, tried 0.49-19, stop-resume hang bug in Zoom Player appeared again.

nevcairiel
17th March 2012, 11:40
nevcairiel, tried 0.49-19, stop-resume hang bug in Zoom Player appeared again.

I cannot reproduce any problems.
Also, assuming that i remember every bug that was reported over the last year or so is kinda pushing it. Details, exact reproduction steps, or no cookies.

(Not to mention that Zoom Players filter configuration is insanely stupid, i had to turn off its smart play to even get it to use LAV, it ignored any other configuration. Simpler configuration to just force one decoder is too much to ask, eh.)

Gleb Egorych
17th March 2012, 12:29
nevcairiel, sorry,
play a file with LAV Audio decoder loaded (I tried TS with mp2 audio). Press and hold "S" key in Zoom Player (Stop->Resume->Stop in cycle). After a few seconds (actual period varies from time to time) ZP hangs. LAV 0.49 is OK.

nevcairiel
17th March 2012, 12:32
The audio decoder was not touched one bit since 0.49.

I also tried that, with both LAV Video and LAV Audio loaded, and everything was fine.

Gleb Egorych
17th March 2012, 12:42
nevcairiel,
maybe it's video decoder this time. I'll do more tests and report back. At the moment I can say that I had updated complete LAV codec set and experienced several hangs.