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

nevcairiel
2nd October 2011, 23:57
Interesting, i didn't expect the second to actually be slower..

Here is another, again use with the other files from the first.

http://files.1f0.de/lavf/LAVVideo-0.36-d3dflags.zip

nevcairiel
3rd October 2011, 00:09
And while we're at it, how about this one?

http://files.1f0.de/lavf/LAVVideo-0.36-moreflags.zip

TheShadowRunner
3rd October 2011, 00:10
Interesting, this LAVVideo-0.36-d3dflags gives me the lowest "GPU Load" on a LAV build, at 72%.
The madVR rendering came back to around 20 ms. It still gives me loads of dropped/delayed/glitches.

And back to CoreAVC CUDA for making sure I'm not crazy, "GPU Load" indeed at 41%

With LAVVideo-0.36-moreflags:

Mwaha, you're onto something,
rendering at 16 ms in madVR, "GPU Load" at 62% !

nevcairiel
3rd October 2011, 00:23
And a new one

http://files.1f0.de/lavf/LAVVideo-0.36-dummyhwnd.zip

Slowly, I'm running out of tricks though..

SamuriHL
3rd October 2011, 00:24
And a new one

http://files.1f0.de/lavf/LAVVideo-0.36-dummyhwnd.zip

Slowly, I'm running out of tricks though..

dummyhwnd? Seriously?? :D LOL!

TheShadowRunner
3rd October 2011, 00:32
With LAVVideo-0.36-dummyhwnd:

"GPU Load" went further down at 56%, madVR rendering stayed around the same as -moreflags at 16-17 ms.
I wonder how CoreAVC does it XD (41% GPU Load, rendering 11ms!)

nand chan
3rd October 2011, 04:13
And a new one

http://files.1f0.de/lavf/LAVVideo-0.36-dummyhwnd.zip

Slowly, I'm running out of tricks though..

Is it not possible to debug or reverse engineer the calls CoreAVC uses so you know what flags it has set, or something?

wanezhiling
3rd October 2011, 05:15
win7 x86
GT240
GeForce 285.38 Driver
PotPlayer & mpc-hc
evr(cp)
tested video:all 1080i hdtv,h264 & mpeg2,30fps


LAV + CUDA(High Quality Processing on)
Memory Used: 240 MB
GPU Load: 80%
Memory Controller Load: 27%
Video Engine Load: 32%
fps:47~53

LAV + CUDA(High Quality Processing off)
Memory Used: 241 MB
GPU Load: 32%
Memory Controller Load: 25%
Video Engine Load: 35%
fps:60

CoreAVC + CUDA (average) + hardware
Memory Used: 245 MB
GPU Load: 35%
Memory Controller Load: 28%
Video Engine Load: 31%
fps:60

Believe me,I tested this on three PCs with same graphic card - GT240.I got the same result.

nevcairiel
3rd October 2011, 08:42
With LAVVideo-0.36-dummyhwnd:

"GPU Load" went further down at 56%, madVR rendering stayed around the same as -moreflags at 16-17 ms.
I wonder how CoreAVC does it XD (41% GPU Load, rendering 11ms!)

Too bad D9 crapped out on me last night again, oh well.

Here is another build. I'm really running out of things to change now, though. :)

http://files.1f0.de/lavf/LAVVideo-0.36-autosched.zip


Believe me,I tested this on three PCs with same graphic card - GT240.I got the same result.
The GT240 is just too slow for HQ processing, is all.

ForceX
3rd October 2011, 09:40
Are these builds supposed to fall back to software decoders if HQ processing is turned on? And break compatibility with older CUDA?

TheShadowRunner
3rd October 2011, 09:43
Hi nev, so I put the -autosched build in the LAVfilters-0.36-cuvid-sync folder from yesterday.
Results: "GPU Load" is at around 60%, madVR rendering still at 16-17ms, that's clearly better than the "public" build so our testing is not going to waste.
Do not hesitate if you have more builds for me to try ;)

ForceX, not at all, we're just trying to find out the source of a CUDA performance difference between CoreAVC and LAV.

dead_screem
3rd October 2011, 10:18
Hi nev, so I put the -autosched build in the LAVfilters-0.36-cuvid-sync folder from yesterday.
Results: "GPU Load" is at around 60%, madVR rendering still at 16-17ms, that's clearly better than the "public" build so our testing is not going to waste.
Do not hesitate if you have more builds for me to try ;)

ForceX, not at all, we're just trying to find out the source of a CUDA performance difference between CoreAVC and LAV.

I noticed that in your settings screenshot you had YV12 enabled while NV12 disabled... would this be related? Because AFAIK NV12 is whats reccomended for use with hardware accel modes (DXVA/CUVID).
I think I also remember reading somewhere on msdn that NV12 is preferred over YV12 in general.

TheShadowRunner
3rd October 2011, 10:36
dead_screem, yes my early tests were using NV12, I've since switched to YV12 so the ouptut is exactly similar to CoreAVC's.
NV12 versus YV12 made virtually no difference in LAV.

I've just tried going back to NV12 with the -autosched build and same, GPU Load/madVR rendering times similar to YV12. (or maybe a tiny tiny bit faster, by a couple percents)

nevcairiel
3rd October 2011, 10:37
http://files.1f0.de/lavf/LAVVideo-0.36-d3dmt.zip

I modified the flags so that it should work with the HQ option as well as without, i hope it doesn't reduce the performance alot again.
I really don't know what else to do differently. Unless there are screws that i don't know that exist, i have turned all i have.

watchman
3rd October 2011, 10:42
Here is another build. I'm really running out of things to change now, though. :)

http://files.1f0.de/lavf/LAVVideo-0.36-autosched.zip


This build has really awesome performance. I'm able to use CUDA on my old 9600 GT to decode some 1080p 60fps benchmark videos, almost without dropped frames in madVR exclusive mode (just 2-3 frame drops sometimes).

Funny thing happened, though. My experience with HQ processing is opposite. There are tons of dropped frames with HQ unchecked and video looks more like slide show :) , but everything is fine and smooth when HQ is checked.

I'm running vista sp2, 9600GT as I mentioned and 270.61 drivers

TheShadowRunner
3rd October 2011, 10:46
(back in YV12)
Hehe it got better again with d3dmt ;)
Rendering is now on the low end of 16ms, it almost stopped madVR's "presentation glitches" completely (only had 2!).
GPU Load still around 60%.

Edit: tried HQ Processing for the fun of it (XP), it's completely fux0red ^^; (crazy artefacts, much slower)

nevcairiel
3rd October 2011, 10:50
This build has really awesome performance. I'm able to use CUDA on my old 9600 GT to decode some 1080p 60fps benchmark videos, almost without dropped frames in madVR exclusive mode (just 2-3 frame drops sometimes).

Funny thing happened, though. My experience with HQ processing is opposite. There are tons of dropped frames with HQ unchecked and video looks more like slide show :) , but everything is fine and smooth when HQ is checked.

I'm running vista sp2, 9600GT as I mentioned and 270.61 drivers

Actually, with the autosched build enabling HQ will probably fallback to software decoding.
Try the latest. :p

The 9600GT is probably not fast enough for 60p decoding



Edit: tried HQ Processing for the fun of it (XP), it's completely fux0red ^^; (crazy artefacts, much slower)
Yeah its known to just fail on XP..

watchman
3rd October 2011, 11:15
Actually, with the autosched build enabling HQ will probably fallback to software decoding.
Try the latest. :p

The 9600GT is probably not fast enough for 60p decoding


Yup, looks like there was the catch. Using d3dmt build, it's slide show with as well as without HQ processing.

Is it possible to keep that feature without affecting changes you did? I think it's really cool to try to use CUDA decoder and if HW is not suitable to decode video fluently, then use fallback to SW decoding.

nevcairiel
3rd October 2011, 11:20
That wasnt a feature. Activating HQ just always resulted in software decoding, because it was broken.

watchman
3rd October 2011, 11:39
That wasnt a feature. Activating HQ just always resulted in software decoding, because it was broken.

So may I change it to feature request, if you think that such a thing is possible without affecting decoder perormance? :) It would be really awesome to have something like this as I think that I'm not the only one who likes smart automatic SW logic. :p

nevcairiel
3rd October 2011, 11:43
(back in YV12)
Hehe it got better again with d3dmt ;)
Rendering is now on the low end of 16ms, it almost stopped madVR's "presentation glitches" completely (only had 2!).
GPU Load still around 60%.

Here is another try, i doubt it does anything, but who knows at this point.

http://files.1f0.de/lavf/LAVVideo-0.36-timerresolution.zip

Blight
3rd October 2011, 12:03
User report:
Using LAV Video decoder, Video artifacts seen when playing the sample file (see below) with the CUVID decoder disabled.
No artifacts with CUVID decoder enabled.

Description:
Look closely at about 3 seconds into the video when the video shows the laptop keyboard in use.

Sample:
http://www.sendspace.com/file/kx3uwi

nevcairiel
3rd October 2011, 12:19
User report:
Using LAV Video decoder, Video artifacts seen when playing the sample file (see below) with the CUVID decoder disabled.
No artifacts with CUVID decoder enabled.

Description:
Look closely at about 3 seconds into the video when the video shows the laptop keyboard in use.

Sample:
http://www.sendspace.com/file/kx3uwi

Thanks, i reported the problem to ffmpeg, its their thing to deal with now.
For reference: http://ffmpeg.org/trac/ffmpeg/ticket/528

wanezhiling
3rd October 2011, 13:06
The GT240 is just too slow for HQ processing, is all.

:eek:
What?too slow...I can’t believe my eyes...
HQ processing performed excellently on my 8600gt and gt230m...
The gt240 is slower than 8600gt and gt230m???...God...:eek:

nevcairiel
3rd October 2011, 13:09
You see it for yourself, without HQ its the same performance as CoreAVC, but if you enable it, its too slow - obviously the GPU is just not fast enough,

TheShadowRunner
3rd October 2011, 13:30
Nev, with -timerresolution it's slightly worse, "GPU Load" around 70%, madVR rendering 18 ms.

wanezhiling
3rd October 2011, 13:33
...
gt240...:mad:

Chuck it in the bin!!!

clsid
3rd October 2011, 14:44
Since HQ is known to b0rk on XP and since afaik nobody has ever claimed it working on XP, wouldn't it be better to disable it completely on XP?

Would it be possible to set the default state of HQ option based on some GPU details? Then it could be disabled by default for older and low-end cards. I don't know what info can easily be retrieved in the filter, but I was thinking about for example VP version and clock speed.

nevcairiel
3rd October 2011, 14:50
VP version is not available, but its also irrelevant, as the HQ options purely depends on the 3D speed of the card.
What is available is the number of CUDA cores, which is some kind of measure that could be used.

But anyhow, I have alot more other things to do, such thins are only annoying without a real world benefit for most users. :p
The main problem is that those settings are not specific to the CUVID decoder, but instead will apply to all future hardware decoders (if there is some HQ mode that can be used)

wanezhiling
3rd October 2011, 15:29
the HQ options purely depends on the 3D speed of the card.
What is available is the number of CUDA cores, which is some kind of measure that could be used.


The 3D speed of gt240 is much faster than 8600gt/gt130m,and gt240 has 96 CUDA cores,8600gt/gt130m has only 32.

ForceX
3rd October 2011, 16:20
:eek:
What?too slow...I can’t believe my eyes...
HQ processing performed excellently on my 8600gt and gt230m...
The gt240 is slower than 8600gt and gt230m???...God...:eek:
You can play 1080i 30 FPS content using the same settings as GT240 as in your 8600gt? 84% load is high but it should still give good playback in the gt240.

JarrettH
3rd October 2011, 18:49
The GT240 is a really good card. Was there a good direct replacement for it?

I mean single fan, low power, quiet

nevcairiel
3rd October 2011, 19:52
Nev, with -timerresolution it's slightly worse, "GPU Load" around 70%, madVR rendering 18 ms.

Another set of tests.

The first build is what i made on changes so far and commited to the repository, just to make sure it didn't get worse again.

The second adjusts another screw that i didn't try yet.

http://files.1f0.de/lavf/LAVVideo-0.36-git.zip

http://files.1f0.de/lavf/LAVVideo-0.36-delay4.zip

TheShadowRunner
3rd October 2011, 21:29
...and the results!

With -git, "GPU Load" is around 60% and madVR rendering at 17~ms. "Presentation glitches" still happen.
that's already better than previous public build, great.

With -delay4, "GPU Load" decreased further, now about 55%. Rendering times still 17ish ms, presentation glitches happen no more, not a single one!
Best build so far ;)

Mixer73
4th October 2011, 00:15
The 3D speed of gt240 is much faster than 8600gt/gt130m,and gt240 has 96 CUDA cores,8600gt/gt130m has only 32.

Does the GT240 have more power saving functions than the 8600GT? Is clocking down a problem?

Also Nev I had struggled to get perfect playback on my system so I clean formatted and have almost nothing installed now, just PotPlayer and Lav Filters, and I gotta say this is a really elegant product for someone who wants to have as little installed as possible.

Much kudos. Especially as its not even a version 1 yet ;)

wanezhiling
4th October 2011, 00:53
Nev,maybe I should lend you my gt240. :p

wanezhiling
4th October 2011, 00:57
Does the GT240 have more power saving functions than the 8600GT? Is clocking down a problem?


No...

"The GT240 is just too slow for HQ processing, is all.":rolleyes:

Mark_A_W
4th October 2011, 01:37
So, here is a quick test build of a new feature i implemented.
Specifically, this enables LAV Audio to convert between sample formats, which means that if you had issues with float audio before, you can now make it convert that to integer, by simply disabling float.

Note that i do not recommend turning off any output formats unless either your hardware or another DirectShow component does not work properly otherwise.
Specifically, there is no advantage in outputting audio that was decoded as 16-bit integer in any higher format, so disabling it will not increase quality at all!

Anyhow, here is the build:

http://files.1f0.de/lavf/LAVFilters-0.36-pcm.zip


Thanks - this will be useful for me, as Convolver Filter only accepts 16 bit or 32 bit float (not 24 bit).

Adding channel delay would completely remove my need for ffdshow audio!

Cheers

Mark

asasadad_1
4th October 2011, 02:41
deinterlacing in LAV seems slightly worse than CoreAVC.

http://i56.tinypic.com/5ul2bn.jpg

nevcairiel
4th October 2011, 06:46
Looks like a mbaff file that wasn't properly detected as actually being interlaced. Try checking the "force deinterlacing" option. I can only imagine that the "Aggressive" checkbox does something similar to the force option.
I also didn't think CoreAVC was actually deinterlacing itself, isn't it just flagging the interlace flags to the renderer to handle it?

dead_screem
4th October 2011, 06:51
I also didn't think CoreAVC was actually deinterlacing itself, isn't it just flagging the interlace flags to the renderer to handle it?

CoreAVC has a few deinterlacing options. Weave, Single field, Bob and Hardware. The "Hardware" setting is what passes the Direct Show flags on to the renderer.

nevcairiel
4th October 2011, 06:58
Thats what i thought. Weave, Single field and Bob aren't worth calling deinterlacing, anyway.
I imagine that the "Aggressive" mode will then force those flags on all frames, no matter if the decoder indicates interlaced or not.

dead_screem
4th October 2011, 07:02
Thats what i thought. Weave, Single field and Bob aren't worth calling deinterlacing, anyway.
I imagine that the "Aggressive" mode will then force those flags on all frames, no matter if the decoder indicates interlaced or not.

from the help,

Aggressive - in addition to SEI messages and POC numbers, assume the source is interlaced if any interlaced coding tools are used (MBAFF, PAFF)

So I guess even if the stream is flagged MBAFF progressive, this will force CoreAVC to assume MBAFF interlaced. While normal progressive content is unaffected.

nevcairiel
4th October 2011, 07:03
I see. I suppose thats a safer way then forcing it on everything.

asasadad_1
4th October 2011, 09:01
I enable "force deinterlacing" option,doesn't seem better.


http://i51.tinypic.com/dvkdua.jpg

nevcairiel
4th October 2011, 09:20
Can you upload a sample of that?

asasadad_1
4th October 2011, 11:08
Can you upload a sample of that?

that sample is posted by wanezhiling A few pages before.
http://www.gokuai.com/f/ulI9o5384F7MUe3D


http://i56.tinypic.com/o109ko.jpg

pankov
4th October 2011, 11:21
asasadad_1,
the sample plays perfectly fine here.

what's your video card?

betaking
4th October 2011, 11:44
asasadad_1,
the sample plays perfectly fine here.

what's your video card?

plays perfectly fine too!

asasadad_1
4th October 2011, 11:58
asasadad_1,
the sample plays perfectly fine here.

what's your video card?

I played that sample in mpc-hc,paused-play-go to-frame(3118, 59.940),how about the image?
btw,my video card is Geforce 8500GT,but no problem with CoreAVC.

http://i55.tinypic.com/2dcg9ky.jpg