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

Po
5th August 2011, 12:13
Playback of realmedia works pretty good now with LAV Filters.

RealVideo inside Matroska does not yet play smooth though. Hopefully that can be fixed in LAV Video. Here is a sample:
http://www.mediafire.com/?xau5day9pj8rub1

LAV Splitter also don't output video.

roytam1
5th August 2011, 12:37
LAV Splitter also don't output video.

Please try the video4 build some posts before.

Po
5th August 2011, 13:01
Have latest build, thanks anyway.

Actually it connects only to ffdshow video. Can anyone confirm?

roytam1
5th August 2011, 13:36
Have latest build, thanks anyway.

Actually it connects only to ffdshow video. Can anyone confirm?

Did you configure LAV Video and enable RV10-30 and RV40?

Po
5th August 2011, 16:06
Oh, i'm sorry i forgot about that. Is that mandatory?

Already have enabled MPC-HC internal Real Video decoder and have system registered also AverMedia decoder for Real video,
but neither connect with LAV Splitter.

Did i miss something?

bjd
5th August 2011, 17:14
What about Output format of LAV Audio?
It is still useful to have integer/float selection, or even Output frequency conversion (96kHz -> 48kHz etc.)

If you are using the default Vista/W7 audio renderers, then no, you should always send 32fp wherever possible because that is what the mixer handles and unlike XP's Kmixer, integer is converted to float first by the mixer (so no point converting float to int on the audio decoder).

IMHO it is best to send the decoded audio untouched to ReClock via Kernel Streaming/WASAPI and configure ReClock depending on personal needs/preferences (Sample rate/Bit Depth) and avoid other renderers.

If you need speaker matrix mixing insert FFDshow's audio processor in between the decoder and renderer.

nevcairiel
5th August 2011, 20:22
Oh, i'm sorry i forgot about that. Is that mandatory?

Already have enabled MPC-HC internal Real Video decoder and have system registered also AverMedia decoder for Real video,
but neither connect with LAV Splitter.

Did i miss something?

There is a small bug right now which blocks usage of the mpc decoder, maybe affecting others as well.

Po
6th August 2011, 08:41
That explains it.

By the way a big "Thank you" for your work, it filled a lot of gaps for Windows users,
and of course all the people that test, suggest and push things further here.

zerowalker
6th August 2011, 09:49
If you are using the default Vista/W7 audio renderers, then no, you should always send 32fp wherever possible because that is what the mixer handles and unlike XP's Kmixer, integer is converted to float first by the mixer (so no point converting float to int on the audio decoder).

IMHO it is best to send the decoded audio untouched to ReClock via Kernel Streaming/WASAPI and configure ReClock depending on personal needs/preferences (Sample rate/Bit Depth) and avoid other renderers.

If you need speaker matrix mixing insert FFDshow's audio processor in between the decoder and renderer.

How can i do this on zoom player;O?

Virtual_ManPL
6th August 2011, 10:51
@ nevcairiel - thank you for your hard work, now especially on video decoder which supports 10bit h.264 ;)
next renderer or player ? :p

bjd
7th August 2011, 09:54
How can i do this on zoom player;O?

Download and install ReClock and then select it in ZoomPlayer under Options/Setup -> Audio/Video.

By Default ZoomPlayer uses the Default Direct Sound Device so 32bit float for lossy audio is the best use in Visa/Win7

zerowalker
7th August 2011, 11:36
tried it, worked i guess, but i got lag, from when i start the movie, or more like a slight delay.
it was very irritating as it happened when i skipped som secs here and there, so in the end i stopped using it:S
ty for telling though;D!

CruNcher
8th August 2011, 09:10
Nev i try to get .wmv with AP working with Lav Cuvid and .wmv with WMV3 with Microsofts DMO Decoder but somehow it seems even with lower merit lav splitter always forces a connection and so if i open the WMV3 it uses MPC Video Decoder low merrit and the lav splitter chain instead of the WMV ASF reader + WMVvideo DMO Decoder chain :(
My idea was that WMVVideo Decoder DMO doesn't support Lav Splitter and would fallback to the WMV ASF reader if that is higher prioritized if Lav Cuvid fails and fallsback to WMVVideo Decoder but it doesn't :(
Though this is getting me confused i have already a very complex chain but i guess this isn't doable what i want without hardcoding it (Splitter needs to switch for 2 different WMV/VC-1 Profiles)


subtype: Unknown GUID Name {41564D57-0000-0010-8000-00AA00389B71}
biCompression: WMVA

Lav Splitter->Lav Cuvid (works)
WMV ASF Reader->WMVideo Decoder DMO (doesnt work DXVA)

Unknown GUID Name {33564D57-0000-0010-8000-00AA00389B71}
biCompression: WMV3

WMV ASF Reader->WMVideo Decoder DMO (works DXVA)
Lav Splitter->Lav Cuvid (doesn't work)
Lav Splitter->WMVideo Decoder DMO (doesn't work)

Funny thing Lav Splitter connects only for WMV1 and 2 streams to WMVideo Decoder DMO but result is a black screen anyways

Every WMV3 works in the combination of Lav Splitter->Arcsoft Video Decoder (DXVA) but there it gets unsync @ playback and seeking

nevcairiel
8th August 2011, 10:51
Source filters don't dynamically change like that, it just isn't designed to work like that in directshow. The source filter is created first, then its pins are connected, and so on. It can only remove a filter again if there is absolutely no filter that wants to connect.

I suggest simply using the WM ASF Reader for all wmv files.

clsid
8th August 2011, 11:28
@CruNcher
WM ASF Reader is only partially registered on some systems. I dunno why. Run regsvr32 qasf.dll and WM ASF Reader will load by default in MPC if you give LAV Splitter a low merit.

CruNcher
8th August 2011, 12:09
Thx nev for clearing this so indeed it would be needed to hardcode it for optimal usability @ least for XP, also thx clsid though i found a workarround now with Arcsofts Framework (it's quiet good for WMV) it doesn't colide with Lav Cuvid and Lav Splitter like the WMV ASF Reader (Arcsofts ASF Reader) also it supports 2x fast forward that the WMV ASF Reader doesn't :) Lav Cuvid currently decodes the VC-1 inside .ts .mkv and arcsofts framework the whole .asf part (including DXVA for WMVA that Microsofts own Decoder doesn't support) with DXVA that works perfect combined and doesn't need any code changes to MPC-HC :)


Here is the result for WMV3 DXVA:
http://img641.imageshack.us/img641/3820/wmv3dxvavp4xp.png

VC-1 LAVCuvid interlaced

http://img820.imageshack.us/img820/8813/vc1interlacedlavcuvidts.png

most importantly it doesn't collide with each other :)

Blight
8th August 2011, 13:25
IAMExtendedSeeking exports chapters.


Thanks!

nevcairiel
9th August 2011, 07:51
Playback of realmedia works pretty good now with LAV Filters.

RealVideo inside Matroska does not yet play smooth though. Hopefully that can be fixed in LAV Video. Here is a sample:
http://www.mediafire.com/?xau5day9pj8rub1

That file is just muxed wrong. It contains the same broken timestamps the ffmpeg demuxer used to output from RM files - in addition, it also contains a wrong FPS field in the header. It specifys the file is 30fps, but in fact its 25fps, which makes the backup calculations break.

Broken file, not much to see here.

roytam1
9th August 2011, 08:41
Killer sample still kills.
http://roy.orz.hm/samples/rv40_weighted_mc.rmvb

Even though the NextPlayer rmdec.c patch (MPlayer's approach) is applied, this sample is still choppy.
Hope someone will rewrite whole libavformat RealMedia demuxer sometime.

Midzuki
9th August 2011, 09:12
Killer sample still kills.
http://roy.orz.hm/samples/rv40_weighted_mc.rmvb.

That's interesting, LAV Splitter sends the RV stream to "nowhere". :confused:

EDIT: My bad :o , LAV Splitter was NOT designed to use RealPlayer DLLs. :stupid:

BTW, feature request for the next revision: in the "Input formats" tab, add two checkboxes, "Select All" && "Select None". :devil:

nevcairiel
9th August 2011, 09:32
Killer sample still kills.
http://roy.orz.hm/samples/rv40_weighted_mc.rmvb

Even though the NextPlayer rmdec.c patch (MPlayer's approach) is applied, this sample is still choppy.
Hope someone will rewrite whole libavformat RealMedia demuxer sometime.

I fixed that sample now, well at least kind of.

mindbomb
9th August 2011, 09:51
so, i just noticed you no longer need to use frame time correction when using dxva for VC-1 with either arcsoft or cyberlink video decoders with evr cp.

nevcairiel
9th August 2011, 09:54
You shouldn't need Frame Time Correction with any VC-1 decoder with LAV Splitter - if you do, thats a bug, and you should let me know which decoder needs it.
This is assuming you have the VC-1 timestamp option set to "Auto"

roytam1
9th August 2011, 12:18
I fixed that sample now, well at least kind of.

It works. Thanks.


Another issue is that, playing RV20+SVT clips resulting reduced in half of width: (it encodes in half width but plays in full width, i.e. PAR=2:1)
http://roy.orz.hm/samples/rv20_svt_cook_640x352_realproducer_plus_8.51.rm

nevcairiel
9th August 2011, 12:54
Another issue is that, playing RV20+SVT clips resulting reduced in half of width: (it encodes in half width but plays in full width, i.e. PAR=2:1)
http://roy.orz.hm/samples/rv20_svt_cook_640x352_realproducer_plus_8.51.rm

That file plays properly as 640x352 for me.

roytam1
9th August 2011, 13:28
That file plays properly as 640x352 for me.

It doesn't work for XP default video renderer.
http://i.imgur.com/TXNz8.png

tetsuo55
9th August 2011, 14:45
Is anyone compiling nightly builds? I'd like to throw my RMVB library at the new demuxing code.

roytam1
9th August 2011, 14:57
Is anyone compiling nightly builds? I'd like to throw my RMVB library at the new demuxing code.

http://www.mediafire.com/file/ib54aqhng20bd1k/lavf-my110809-3.7z

With Kostya's RV patches applied:
https://lists.libav.org/pipermail/libav-devel/2011-August/009245.html
http://inoshishi.dlinkddns.com/0001-Add-weighted-motion-compensation-for-RV4.patch

tetsuo55
9th August 2011, 15:00
thanks

SamuriHL
9th August 2011, 15:18
Is anyone compiling nightly builds? I'd like to throw my RMVB library at the new demuxing code.

http://www.mediafire.com/?23o4y56b3anlnwn

Latest code built into an installer.

roytam1
9th August 2011, 15:23
Is anyone compiling nightly builds? I'd like to throw my RMVB library at the new demuxing code.

And there is no new demuxing code, rmdec patch (ideas from MPlayer) is only a workaround, not an ultimate fix.

Shark007
9th August 2011, 15:54
http://www.mediafire.com/?23o4y56b3anlnwn

Latest code built into an installer.

Thanks. your time is appreciated.

AmshTemp
9th August 2011, 18:29
All rv, all play fine with ffplay

This one doesn't play. It just stuck at 00:00
http://www.mediafire.com/?b2k14g6f0y06b08

and this one show the first frame of video
http://www.mediafire.com/?16k66c41bdh78jc

roytam1
10th August 2011, 02:13
All rv, all play fine with ffplay

This one doesn't play. It just stuck at 00:00
http://www.mediafire.com/?b2k14g6f0y06b08

and this one show the first frame of video
http://www.mediafire.com/?16k66c41bdh78jc

6.rm is too short that even RealPlayer itself can't play correctly.
7.rm has a broken timeline, RealPlayer play till 1:09 and seekbar doesn't work. Did you capture it correctly?

Sebastiii
10th August 2011, 10:06
Hi :)

I would like to know if there is different ffmpeg git source (i use git://git.1f0.de/ffmpeg.git and for 1f0.de libbluray too) but when i compile lavsplitter, all av*.dll are not the same size from ZIP.
I have try to compil on both PC and i have the same size but different from ZIP.
All compil was done.
My result is that LAV Video (my build didn't work well and crash Graphstudio).
Thanks :)

Hi :) Resolved using MSYS from Xhmikosr :
http://xhmikosr.1f0.de/tools/MSYS_MinGW_GCC_461_x86-x64_Full.7z
:thanks:

clsid
10th August 2011, 14:22
Can you add an option to LAV Splitter to (only) use the original FourCC in its output mediatype? Currently there are a few situations were using the generic mediatype of the format causes problems. This happens with formats that have vendor specific variants that differ from the general a/v format. For example MJPEG. The Microsoft decoder (which is used by default on Win7) fails to properly decode such variants. LAV Video and ffdshow do it properly, but those do not get used by default when the generic mediatype is used. Hence my option suggestion.

nevcairiel
10th August 2011, 14:52
Such an option doesn't make much sense, tbh. Only very few codecs have actually a format override, because it was applied to fix some files. If there is some specific format that requires a specific fourcc, its easier to fix those cases.

Edit:
Just changed MJPEG to providing two media types, one with the original and one with the default fourcc.
However, the video you gave me earlier is still upside down, because the MS MJPEG codec does not connect to the MJVP fourcc, not even when using the MS AVI Splitter (it doesnt play at all there).

Weirdo
10th August 2011, 18:17
Any chance support for the .mxf (http://en.wikipedia.org/wiki/Material_Exchange_Format) container format (used by Panasonic P2 and others) could be added to the splitter?

nevcairiel
10th August 2011, 18:26
Any chance support for the .mxf (http://en.wikipedia.org/wiki/Material_Exchange_Format) container format (used by Panasonic P2 and others) could be added to the splitter?

MXF should work already, i don't see why it wouldn't.

clsid
10th August 2011, 18:27
Lots of updates today. Good work!

AmshTemp
10th August 2011, 18:28
6.rm is too short that even RealPlayer itself can't play correctly.
7.rm has a broken timeline, RealPlayer play till 1:09 and seekbar doesn't work. Did you capture it correctly?


No, the samples are from http://samples.mplayerhq.hu
These two are the only remaining samples ffplay managed to play but lav couldn't.
I'm looking for transparency between ffplay and lav.

Weirdo
10th August 2011, 18:45
MXF should work already, i don't see why it wouldn't.I try to open .mxf P2 video files, but MPC-HC 'cannot render the file'. I have a DVC-Pro HD (used by Panasonic P2 files) directshow decoder installed - an editing application I have uses this decoder, but is not smart enough to load the corresponding .mxf audio file.

edit: seems a bit complicated, since there are 22 video and 88 audio .mxf files on the same P2 card folder.

2nd edit: : I could upload a complete p2 card folder with a couple of clips if it'd help. I remember in the past (before LAV) mpc-hc playing these files, I now just can't figure out how.

clsid
11th August 2011, 03:33
Is it normal that AYUV output has much higher CPU usage than YV12 or RGB32 for Hi10P 4:4:4 playback?
The green line in the stats graph in MPC goes haywire here with AYUV. CPU usage is around 25-30% on my i7 2600K with BBB444p10.mkv.

betaking
11th August 2011, 07:40
Is anyone compiling nightly builds? thanks?

madshi
11th August 2011, 07:53
Is it normal that AYUV output has much higher CPU usage than YV12 or RGB32 for Hi10P 4:4:4 playback?
The green line in the stats graph in MPC goes haywire here with AYUV. CPU usage is around 25-30% on my i7 2600K with BBB444p10.mkv.
Which renderer are you using? If it's not madVR then LAV Video needs to dither the video down to 8bit. I suppose the bitdepth downconversion likely consumes more CPU than the reordering of the data for AYUV output. At least that's what I would expect. It's also possible that swscale might be less efficient for dithering 10bit down to 8bit for 4:4:4 data?

Underground78
11th August 2011, 08:48
Is anyone compiling nightly builds? thanks?

LAVFilters-x86-git-fc7d418c13c0.7z (http://www.mediafire.com/?nv51696jut4o06v)

nevcairiel
11th August 2011, 09:15
Is it normal that AYUV output has much higher CPU usage than YV12 or RGB32 for Hi10P 4:4:4 playback?
The green line in the stats graph in MPC goes haywire here with AYUV. CPU usage is around 25-30% on my i7 2600K with BBB444p10.mkv.

AYUV output uses a "slow" algorithm, because its not a format natively supported by swscale.

Its a two step process, due to the requirement for dithering:
- Convert the 4:4:4 10bit to 4:4:4 8bit using swscale dithering
- Manually reorder the bytes to fit the AYUV layout, in pure C code, no optimizations yet

I haven't actually compared performance yet, but its certainly possible that this two step operation is much slower then using a one-step operation like YV12 or RGB32, which are natively supported by swscale.

roytam1
11th August 2011, 09:26
AYUV output uses a "slow" algorithm, because its not a format natively supported by swscale.

Its a two step process, due to the requirement for dithering:
- Convert the 4:4:4 10bit to 4:4:4 8bit using swscale dithering
- Manually reorder the bytes to fit the AYUV layout, in pure C code, no optimizations yet

I haven't actually compared performance yet, but its certainly possible that this two step operation is much slower then using a one-step operation like YV12 or RGB32, which are natively supported by swscale.

In ConvertToAYUV():
*idst++ = v[i] + (u[i] << 8) + (y[i] << 16) + (0xff << 24);


maybe using bitwise OR is faster than addition(+)? (since they aren't overlap)

zerowalker
11th August 2011, 09:38
Does it still stutter for you guys when you play AVI Files?
I does for me when i cut an MKV file with Direct Stream into an AVI file, and then play it, it stutter about all the time.
Maybe itīs a bug or unstable with that scenario, so thought it would be nice to tell about it:)
Keep up the Work Near Carrier, and i tried the Nightly Build by Underground aswell;)

betaking
11th August 2011, 10:15
LAVFilters-x86-git-fc7d418c13c0.7z (http://www.mediafire.com/?nv51696jut4o06v)

thanks!