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

adam777
22nd February 2011, 10:23
DVB apps have their own source filters/splitters. LAV Splitter only works with file based media, or potentially network streaming (some day), but not DVB-T tuner cards.

You say the audio decoder loads, does the audio play properly? If so, whats the problem? :)

Loads, but no audio.

nevcairiel
22nd February 2011, 10:28
One thing you can do is ask the dev how their source filter works. Is it a combined Source/Splitter, or is it a raw source that depends on an external splitter filter?
If its the latter, i might be able to support this behavior at a later stage.

(A raw source filter just captures the raw MPEG-TS stream from the DVB-T card and sends it to a splitter, while a combined filter already demuxes the MPEG stream before sending it off)

bjd
22nd February 2011, 12:56
One thing you can do is ask the dev how their source filter works. Is it a combined Source/Splitter, or is it a raw source that depends on an external splitter filter?

I get no audio from LAV audio when using Mpc-Hc internal Mpeg Splitter to open either .ifo or .vob files. Ffdshow audio works no problem.

It does not seem to matter whether the files in question have no CSS or I use Mpc-Hc or AnyDVD to remove. The splitter passes MEDIATYPE_Audio ok but no sound ?

- Connected to:

CLSID: {E8E73B6B-4CB3-44A4-BE99-4F7BCB96E491}
Filter: LAV Audio Decoder
Pin: XForm In

- Connection media type:

Audio: Dolby AC3 48000Hz stereo 256kbps

AM_MEDIA_TYPE:
majortype: MEDIATYPE_Audio {73647561-0000-0010-8000-00AA00389B71}
subtype: MEDIASUBTYPE_DOLBY_AC3 {E06D802C-DB46-11CF-B4D1-00805F6CBBEA}
formattype: FORMAT_WaveFormatEx {05589F81-C356-11CE-BF01-00AA0055595A}
bFixedSizeSamples: 1
bTemporalCompression: 0
lSampleSize: 1
cbFormat: 18

WAVEFORMATEX:
wFormatTag: 0x2000
nChannels: 2
nSamplesPerSec: 48000
nAvgBytesPerSec: 32000
nBlockAlign: 1024
wBitsPerSample: 0
cbSize: 0 (extra bytes)

nevcairiel
22nd February 2011, 14:12
I get no audio from LAV audio when using Mpc-Hc internal Mpeg Splitter to open either .ifo or .vob files. Ffdshow audio works no problem.


Its probably sending a PES stream instead of proper packages.
This is not supported yet.

Did i mention that the MPC internal splitters are mostly crappy hackjobs that the other filters were forced to adapt to? I don't like doing that. :p

bjd
22nd February 2011, 14:45
Its probably sending a PES stream instead of proper packages.
This is not supported yet.

Did i mention that the MPC internal splitters are mostly crappy hackjobs that the other filters were forced to adapt to? I don't like doing that.

Nev, thanks for the reply, I had a feeling that it would be something like this, especially with an .ifo where I am assuming the data is streamed from the vob by the splitter.

I have looked at the mpc-hc splitter code, and yes there is quite a lot of hacking, but I guess you expect that when someone else takes over a project that they did not start. :rolleyes:

The odd thing is that I have an .ifo which present 24/96 LPCPM rather than .ac3 and the mpc-hc mpeg splitter parses ok to LAV audio and I get audio. But of course that may be just luck that some hack has not effected it as it is not a common DVD audio type.

.vob -> lav splitter -> lav audio of course has no problems. :)

adam777
22nd February 2011, 15:52
One thing you can do is ask the dev how their source filter works. Is it a combined Source/Splitter, or is it a raw source that depends on an external splitter filter?
If its the latter, i might be able to support this behavior at a later stage.

(A raw source filter just captures the raw MPEG-TS stream from the DVB-T card and sends it to a splitter, while a combined filter already demuxes the MPEG stream before sending it off)

OK, will do.
Thank again, Adam.

jmone
23rd February 2011, 11:02
In any case, yes it should be supported by every player. However for proper navigation support, and at a much later stage menu support, the player will have to support it.

The devs at J River (Media Center) are keen to support your work. I've sent you a PM with contact details.

pirlouy
23rd February 2011, 23:27
I just discover this thread. I've tried to search for differences between LAV filters and ffdshow on Google and found nothing interesting.

From what I've read, LAV filters and ffdshow have common points, isn't it ? LAV has splitters, but also decoders like ffdshow. The differences seem to be LAV has splitter whereas ffdshow has post-processing.
Which decoder is recommended ? FFdshow or LAV filters ? What about Haali splitter in comparison (except it is not Open Source) ?

Sorry if I did not understand well.

Virtual_ManPL
24th February 2011, 20:49
You posted in wrong thread man... :rolleyes:

fps
24th February 2011, 23:24
First of all thanks for your work nevcairiel :). It's great to see development in the splitter area.

However, I'm having some trouble with the audio decoder. Whenever I use your audio decoder + splitter to play a H.264/AC3 file I get stuttery playback with madVR. It doesn't change wheter it's FSE mode or windowed mode, there always a lot of dropped and delayed frames.
I have the same problem on 2 different machines, one is a notebook with a Nvidia GPU, the other a standalone pc with a AMD GPU.
If I switch to another audio decoder like ffdshow's one and still use your splitter the problem is gone.
Changing to EVR-CP renderer and keeping the LAV audio decoder + splitter solves the problem, too.

I also noticed another problem with madVR. Whenever I try to switch between audio tracks via the system tray icon of madVR, the player crashes.
This doesn't depend on the audio decoder however, it seems to be just a problem of the combination splitter + madVR.

Setup:
MPCHC 1.5.1.2946
CoreAVC 2.0 (tried ffdshow too)
madVR 0.39
Win7/32

Virtual_ManPL
25th February 2011, 00:06
Could it be related to bug bug #31 (https://github.com/Nevcairiel/LAVFSplitter/issues/#issue/31) ?

fps
25th February 2011, 00:14
I don't really think so, since the bug report states that the problem occurs with EVRCP, but in my case EVRCP is the working renderer.

mindbomb
25th February 2011, 00:16
I just discover this thread. I've tried to search for differences between LAV filters and ffdshow on Google and found nothing interesting.


well, lav audio decoder is alot lighter than installing ffdshow if you just need an audio decoder.

ffdshow can't output true 24 bit pcm, so there is likely to be quality loss for videos with 24 bit flac or truehd audio.

and as for haali splitter, i don't use it because it has problems with dts-hd ma audio with things muxed with mkvmerge 4.4 and older.

robpdotcom
25th February 2011, 01:03
and as for haali splitter, i don't use it because it has problems with dts-hd ma audio with things muxed with mkvmerge 4.4 and older.


That can be fixed using mmg's header editor in a matter of seconds. Just change the default duration of the DTS-HD track to 10666666. No need to remux.

But once forced sub loading in LAV splitter is solved, I probably won't use Haali much either (except for ordered chapters and linked segments, which I imagine is further down the road for LAV).

bjd
25th February 2011, 10:56
I just discover this thread. I've tried to search for differences between LAV filters and ffdshow on Google and found nothing interesting.

LAV Audio seems to handle the various types of LPCM better than ffdshow with the added bonus of proper 24bit output.

fastplayer
25th February 2011, 13:03
I'll also think about full matrix operations to allow stereo downmixing.
AC3, DTS and TrueHD offer native Stereo Downmixing. All other formats need custom matrix processing to get the channels merged. I'll work on that soon.
Is stereo downmixing done automagically by the LAV Audio decoder or do I need to configure MPC-HC in any way?

nevcairiel
25th February 2011, 13:47
It doesn't do any downmixing at all right now. That will be in a future version.

nevcairiel
27th February 2011, 13:46
Good news everyone, i found the bug that caused the error with mpeg-ts durations on files > 4GB (Typically BluRays)

nevcairiel
27th February 2011, 16:05
LAV DirectShow Filters 0.15
LAV Splitter
- Fixed automatic selection of forced subtitle stream if the "Only Forced Subs" mode is active.
- Fixed a bug in file handling that caused file sizes above 4GB to overflow, causing invalid durations to be reported in some files.
- Improved performance on file opening

LAV Audio Decoder
- Enabled the ffmpeg codec parsers, which should improve compatibility with other DirectShow splitters.
- Added a audio channel activity display to the status property page (for debugging channel assignments)

Download: 32-bit (http://files.1f0.de/lavf/LAVFilters-0.15.zip) & 64-bit (http://files.1f0.de/lavf/LAVFilters-0.15-x64.zip)

I was watching some BluRays on the weekend, and it was really annoying to either not have a duration, or having to switch to the MPC-HC Internal Splitter and having all sorts of problems with Audio.. so i just fixed the duration problem. I also improved compatibility between LAV Audio and other splitters by enabling the ffmpeg codec parsers - a job that normally the splitter should do, but you know, most of them are crap.

Oh, and i also found the cause of the Forced subtitles not being enabled properly, and fixed it. As long as the forced flag is properly set on the stream (as indicated by the [forced] after the stream name), it should now always catch on.

I've been on an excourse into video decoding over the last week, but i'll probably put that on ice for a while, as its really alot of fine-tuning to get that working 100%.

So, next up, if time permits, improved BluRay support!

adam777
27th February 2011, 17:15
Hi nevcairiel,
Just tried 0.15, and unfortunately immediately encountered a bug - audio disappear on seek, confirmed with AAC, AC3, DTS.
No problems with 0.14.

On an unrelated issue.
One thing you can do is ask the dev how their source filter works. Is it a combined Source/Splitter, or is it a raw source that depends on an external splitter filter?
If its the latter, i might be able to support this behavior at a later stage.

Here's the DVB application developer's response:

For the audio decoder, PVR is its own splitter/demux, and as nevcairiel on the forum correctly points out, I send just the one required raw PES stream alone

So I suppose that according to that:
Its probably sending a PES stream instead of proper packages.
This is not supported yet.


I'll have to wait patiently.
Thank again :thanks:

nevcairiel
27th February 2011, 17:17
Just tried 0.15, and unfortunately immediately encountered a bug - audio disappear on seek, confirmed with AAC, AC3, DTS.
No problems with 0.14.

Its most likely related to some internal restructuring, i'll look into it.

nevcairiel
27th February 2011, 17:43
LAV DirectShow Filters 0.16
LAV Audio Decoder
- Fixed missing audio after seeks

Download: 32-bit (http://files.1f0.de/lavf/LAVFilters-0.16.zip) & 64-bit (http://files.1f0.de/lavf/LAVFilters-0.16-x64.zip)

I hope this solves the problem.

Ger
27th February 2011, 17:52
Another new problem in 0.15:
Starting playback from a non-zero position (using either of the MPC-HC features "Remember File position" or "Favorites") no longer works.

Tested with a regular avi (xvid/mp3) and MPEG-TS, so I assume all formats are affected.

Maybe something goes wrong with the new "Do not do an initial seek to position 0" code, even though in this case it's not really position 0?

EDIT:
Tried 0.16 now.
Sometimes it works right away.
Sometimes black screen for several seconds, then it suddenly starts.
Sometimes does not work at all (or at least takes long enough for me to give up waiting).

adam777
27th February 2011, 17:53
0.16 solves the missing audio after seek problem.
Thanks for the super-quick reply :)

nevcairiel
27th February 2011, 18:25
LAV DirectShow Filters 0.17
LAV Splitter
- Fixed seeking before starting playback

Download: 32-bit (http://files.1f0.de/lavf/LAVFilters-0.17.zip) & 64-bit (http://files.1f0.de/lavf/LAVFilters-0.17-x64.zip)

It did seem like a good idea when i wrote it. Didn't think the player would dispatch the seek before starting playback. Thats what i get for turning store file position off, because i tested the do-not-start problem.
Thats it for today. Any other regressions, going to have to wait.

Ger
27th February 2011, 19:00
All OK in 0.17. :thanks:

Matching_Mole
27th February 2011, 19:28
I have an issue with LAVaudio filter and Reclock (last version) on Seven.

I use reclock only as Wasapi audio renderer and when LAVaudio filter decode True-HD stream, it sent PCM in IEEE stream. But Reclock give an error message because it can't initialise the WASAPI driver with a such format. I try to configure Reclock in order to change the format to another ones (32bit int, 24 padded to 32, 24bit in,...) but I have always the same error coming from the number of sample (???). Using FFDshow with 32int as format out, no issue but I can't configure LAVaudio filter in the same way, isn't it?

nevcairiel
27th February 2011, 19:43
You need to configure ReClock to one specific output format. Apparently you tried that already, but thats all you have to do really. ReClock will then requant audio to the appriopriate format.
It may also be the combination of sampling rate and sample size. Try to configure reclock to resample the audio into another, standard sample rate, like 48khz or 96khz.

Besides, TrueHD should never send IEEE float, it should rather produce 16-bit int or 24-bit int, as its a lossless codec.

Matching_Mole
27th February 2011, 19:52
Try to configure reclock to resample the audio into another, standard sample rate, like 48khz or 96khz.

Besides, TrueHD should never send IEEE float, it should rather produce 16-bit int or 24-bit int, as its a lossless codec.

I tried also but i didn't work. But I tried with only one specific blu-ray so I will try another one to see if it is due to it.

Thanks for your support!

nevcairiel
27th February 2011, 19:54
Make sure you're not using the MPC-HC Internal mpeg splitter, it does not work with TrueHD and LAV Audio.
Its particularly stupid and broken, and sends it as AC3 data.. <.<

Matching_Mole
27th February 2011, 20:11
Oooh I thought that the parser that you implemented solved this issue. But I was wrong, sorry. So here the reason of my issues.

Today I keep using MPC internal splitter because it can make seamless branching playback. But clearly if you implemented this feaure (maybe with our next implementation of libbluray in your splitter?), I will let down it for yours.

Thanks

nevcairiel
27th February 2011, 20:17
It did solve it for other formats, like some DTS-HD BluRays i had didn't play at all.
However, the MPC-HC splitter doesn't really support TrueHD, its basically a fluke that it detects the stream and sends it as AC3.

robpdotcom
27th February 2011, 20:44
LAV DirectShow Filters 0.15
LAV Splitter
- Fixed automatic selection of forced subtitle stream if the "Only Forced Subs" mode is active.

Big thanks for this, it works great now.:cool:

jmone
27th February 2011, 22:17
Thanks! Nice Update and I can confirm:
1) Duration Bug is fixed on Blu-Ray Items
2) Subs: I think there still may be some fine tuning, eg I just mounted Valkyrie and LavSplitter unnecessarily grabbed Sub Stream #8 (english subs)
3) Seek: I can Chpt Fwd / Back fine, but if I do a seek then I get one static frame from teh new location but the stream will not play (it is like it is paused). See the DirectShow filter info below for both this and #2
4) Audio Filter: Nice new display. One point is that it shows BL and BR (on 5.1 info), should they not be labeled SL / SR (as Back L / Back R are the extra 2 channels from 5.1 to 7.1)

ALso looking forward to your Blu-ray support!

nevcairiel
27th February 2011, 22:22
3) Seek: I can Chpt Fwd / Back fine, but if I do a seek then I get one static frame from teh new location but the stream will not play (it is like it is paused). See the DirectShow filter info below for both this and #2


Does that work with .14?
Does it fix itself after a few seconds?


4) Audio Filter: Nice new display. One point is that it shows BL and BR (on 5.1 info), should they not be labeled SL / SR (as Back L / Back R are the extra 2 channels from 5.1 to 7.1)

I suppose, but it does output them to the correct channels in my 7.1 setup, its just a display thing.

jmone
27th February 2011, 22:24
Filter Graph Info:

Filter 'J. River Audio Renderer'
CLSID: {A4002F8E-510F-442C-8AD3-F9C7B23FB394}
Host:
Input Pin 'In'
Connected to pin 'XForm Out' of filter 'LAV Audio Decoder'
Major type MEDIATYPE_Audio Sub type MEDIASUBTYPE_IEEE_FLOAT, Format type FORMAT_WaveFormatEx

Filter 'madVR'
CLSID: {E1A8B82A-32CE-4B0D-BE0D-AA68C772E423}
Host: c:\users\mum and dad\downloads\madvr\madvr.ax
Input Pin 'Input'
Connected to pin 'Out' of filter 'ffdshow Video Decoder'
Major type MEDIATYPE_Video Sub type MEDIASUBTYPE_YV12, Format type FORMAT_VideoInfo2

Filter 'LAV Audio Decoder'
CLSID: {E8E73B6B-4CB3-44A4-BE99-4F7BCB96E491}
Host: c:\users\mum and dad\downloads\lavfilters\lavaudio.ax
Input Pin 'XForm In'
Connected to pin 'Output' of filter 'J. River Media Proxy Audio'
Major type MEDIATYPE_Audio Sub type MEDIASUBTYPE_DTS, Format type FORMAT_WaveFormatEx
Output Pin 'XForm Out'
Connected to pin 'In' of filter 'J. River Audio Renderer'
Major type MEDIATYPE_Audio Sub type MEDIASUBTYPE_IEEE_FLOAT, Format type FORMAT_WaveFormatEx

Filter 'ffdshow Video Decoder'
CLSID: {04FE9017-F873-410E-871E-AB91661A4EF7}
Host: c:\program files (x86)\ffdshow\ffdshow.ax
Input Pin 'In'
Connected to pin 'Output' of filter 'J. River Media Proxy Video'
Major type MEDIATYPE_Video Sub type MEDIASUBTYPE_H264, Format type FORMAT_MPEG2_VIDEO
Output Pin 'Out'
Connected to pin 'Input' of filter 'madVR'
Major type MEDIATYPE_Video Sub type MEDIASUBTYPE_YV12, Format type FORMAT_VideoInfo2
Input Pin 'In Text'
Connected to pin 'Subtitle' of filter 'LAV Splitter'
Major type Unknown GUID Name: {E487EB08-6B26-4BE9-9DD3-993434D313FD} Sub type Unknown GUID Name: {04EBA53E-9330-436C-9133-553EC87031DC}, Format type Unknown GUID Name: {04EBA53E-9330-436C-9133-553EC87031DC}
Input Pin 'In Text 2'

Filter 'J. River Media Proxy Audio'
CLSID: {A4207487-E7D8-406B-9882-B66370DE2492}
Host:
Input Pin 'Input'
Connected to pin 'Audio' of filter 'LAV Splitter'
Major type MEDIATYPE_Audio Sub type MEDIASUBTYPE_DTS, Format type FORMAT_WaveFormatEx
Output Pin 'Output'
Connected to pin 'XForm In' of filter 'LAV Audio Decoder'
Major type MEDIATYPE_Audio Sub type MEDIASUBTYPE_DTS, Format type FORMAT_WaveFormatEx

Filter 'J. River Media Proxy Video'
CLSID: {A4207487-E7D8-406B-9882-B66370DE2492}
Host:
Input Pin 'Input'
Connected to pin 'Video' of filter 'LAV Splitter'
Major type MEDIATYPE_Video Sub type MEDIASUBTYPE_H264, Format type FORMAT_MPEG2_VIDEO
Output Pin 'Output'
Connected to pin 'In' of filter 'ffdshow Video Decoder'
Major type MEDIATYPE_Video Sub type MEDIASUBTYPE_H264, Format type FORMAT_MPEG2_VIDEO

Filter 'LAV Splitter'
CLSID: {B98D13E7-55DB-4385-A33D-09FD1BA26338}
Host: c:\users\mum and dad\downloads\lavfilters\lavsplitter.ax
Output Pin 'Video'
Connected to pin 'Input' of filter 'J. River Media Proxy Video'
Major type MEDIATYPE_Video Sub type MEDIASUBTYPE_H264, Format type FORMAT_MPEG2_VIDEO
Output Pin 'Audio'
Connected to pin 'Input' of filter 'J. River Media Proxy Audio'
Major type MEDIATYPE_Audio Sub type MEDIASUBTYPE_DTS, Format type FORMAT_WaveFormatEx
Output Pin 'Subtitle'
Connected to pin 'In Text' of filter 'ffdshow Video Decoder'
Major type Unknown GUID Name: {E487EB08-6B26-4BE9-9DD3-993434D313FD} Sub type Unknown GUID Name: {04EBA53E-9330-436C-9133-553EC87031DC}, Format type Unknown GUID Name: {04EBA53E-9330-436C-9133-553EC87031DC}

jmone
27th February 2011, 22:58
Does that work with .14?
Mmmm I did some checking back and forth and it may be the Audio Filter causing the issue. It seems to "sometime" drop the audio causing issues with various Audio Renderer, eg:
- Direct Sound (Speakers): Will continue to play but without sound. Also - I see in the Audio Decoder Properties, that I have full green bars for all 5.1 channels.

- J.River / Reclock: More interesting as these are the Audio Renderers that resample to keep track with Video playback to prevent droped frames. I get stalled video with J.River and while it will play with Recock (sans sound) the player will eventually hang.

Now, not all seeks cause the issue - only some. Some play fine, some seem to drop the Audio.

If I remove just LAV Audio then there is no issue.

Let me know what details you want.

I suppose, but it does output them to the correct channels in my 7.1 setup, its just a display thing.

Correct - just an observation!

jmone
27th February 2011, 23:30
I take it all back! - I had dowloaded and was testing V15 for some reasons. Audio drop outs post a seek are obviouisly fixed in V17 and hence the files now play fine.

Would it be possible to add a V# to the filter info pages? Sorry for the confusion.

Thanks
Nathan

bjd
28th February 2011, 00:21
I was watching some BluRays on the weekend, and it was really annoying to either not have a duration, or having to switch to the MPC-HC Internal Splitter and having all sorts of problems with Audio

the internal splitter is a necessary evil for seamless branching but it does have quite a few other bugs. I try and stick to LAV wherever possible as the graph rebuild on audio change is a necessity with Bluray discs.

no problems with 0.17 so far and my Commando disc now reports 1:30:xx for the main movie ;)

Thanks for all your hard work.

BelowSky
28th February 2011, 01:09
What is the deal with LAV Filter?
Do we expect it support legacy, yet important, stuff like Real Cook Audio and 3GP and AMR out of the box?
I can play them all with FFplay.exe but not with LAV Filter!

nevcairiel
28th February 2011, 07:56
If you use LAV Splitter together with LAV Audio, it should be able to decode all audio that ffmpeg supports (in the containers officially supported by LAV Splitter). If you use other splitters, those formats need to be hooked up properly, and i'll have to do that eventually.

madshi
28th February 2011, 17:06
Just installed the LAV splitter for the first time. I can get it to work in GraphEdit, but not in MPC-HC. Disabling the internal Matroska splitter and renaming Haali isn't good enough, MPC-HC still uses the internal Matroska splitter. Furthermore, when using the "GSpot Codec Information" tool, the LAV Splitter is not listed at all. However, the LAV Audio Decoder and the Haali Media Splitter are both listed.

nevcairiel
28th February 2011, 17:15
In DirectShows eyes, its technically a source filter, and i don't see those in the GSpot codec list at all.

For the MPC-HC issue, i've had people report that they had to properly uninstall Haali to get it to work. I should probably do the same as Haali and register for the extension, forcing my filter to be used once its installed (there can only be one source filter per extension).
I wanted to wait with that until i had config options in the filter for which formats to load, though. Oh well, more on the list of things to finish.

madshi
28th February 2011, 17:22
I think you're right about source filters not being listed in the GSpot codec list. Anyway, I've uninstalled the Haali Media Splitter, uninstalled the LAV splitter, reinstalled the LAV splitter, and MPC-HC does still not use it, although I've "preferred" it and disabled the internal Matroska splitter... :( It does work fine in GraphEdit, though.

fastplayer
28th February 2011, 17:30
Are you sure you've uninstalled Haali "correctly"? Up until the latest version the uninstall procedure was completely broken meaning not uninstalling at all (it removed the files but didn't un-register em). I haven't checked whether it was fixed in the current version although the changelog claims it is...

nevcairiel
28th February 2011, 17:34
Deleting HKEY_CLASSES_ROOT\Media Type\Extensions\.mkv (HKEY_CLASSES_ROOT\WoW6432Node\Media Type\Extensions\.mkv for 32-bit on 64-bit OS) will unlock the source filter selection. As far as my research in the filter graph builder shows, once one is configured there, it uses that one. If it cannot use that one, it fails. MPC-HC catches the failure, and falls back to the internal one in that case.

For the next version, i'll most likely write my GUID in there to solve these problems. If you install it, you better want to use it. :P

Oh, and you didn't install the mpc-hc standalone filters, did you?

madshi
28th February 2011, 17:51
The Haali uninstaller seems to have worked alright. The Haali filters are all gone from the GSpot filter list. Also the registry didn't contain entries for "Media Type\Extensions" for MKV, TS, m2ts and VOB. But *still* MPC-HC wouldn't use the LAV Splitter. So I've manually added entries under "Media Type\Extensions" for LAV Splitter - and now it finally works! :)

The question is for which extensions you will register? For all supported extensions?

nevcairiel
28th February 2011, 17:56
In a perfect world, i would offer an installer with options. I'll see what i can do.

I just noticed something else in MPC-HCs code. LAV Splitter had a relatively low merit (MERIT_NORMAL), and the preferred filter list does not work with source filters, it seems. Once i increased the merit to "MERIT_PREFERRED+4" (Haali is +1), i could actually use it with Haali installed.
MPC-HC outputs quite alot of helpful information about its graph building, sadly only into a debugger console and not a debug log file for everyone to use, but that exposed that shortcoming of the external filter list.

I'll look into actually fixing this in MPC-HC as well, so one can change the merit of source filters through the filter list.
Edit: That code is unnecessarily complex. I'll do that another day.

madshi
28th February 2011, 18:19
In a perfect world, i would offer an installer with options. I'll see what i can do.
How about shipping one simple "*.reg" file per extension? Then users can simply double click the reg files for those extensions they want to have registered? Or maybe a reg file + a bat file, so installation with admin rights is easier. You could put all that stuff into a separate folder, e.g. with the name "register file extensions".

I just noticed something else in MPC-HCs code. LAV Splitter had a relatively low merit (MERIT_NORMAL), and the preferred filter list does not work with source filters, it seems. Once i increased the merit to "MERIT_PREFERRED+4" (Haali is +1), i could actually use it with Haali installed.
MPC-HC outputs quite alot of helpful information about its graph building, sadly only into a debugger console and not a debug log file for everyone to use, but that exposed that shortcoming of the external filter list.

I'll look into actually fixing this in MPC-HC as well, so one can change the merit of source filters through the filter list.
Edit: That code is unnecessarily complex. I'll do that another day.
Well, that would be great, if you could fix that (sooner or later)!

madshi
1st March 2011, 18:02
I'm having some trouble with the audio decoder. Whenever I use your audio decoder + splitter to play a H.264/AC3 file I get stuttery playback with madVR. It doesn't change wheter it's FSE mode or windowed mode, there always a lot of dropped and delayed frames.
I have the same problem on 2 different machines, one is a notebook with a Nvidia GPU, the other a standalone pc with a AMD GPU.
If I switch to another audio decoder like ffdshow's one and still use your splitter the problem is gone.
Changing to EVR-CP renderer and keeping the LAV audio decoder + splitter solves the problem, too.
I've got a log from fps and I can see something interesting in it:

Tick: 00002444, RefClock->GetTime: 3519569852084, QueryPerformanceCounter: 571647010293
Tick: 00002510, RefClock->GetTime: 3519569857084, QueryPerformanceCounter: 571647118339
Tick: 00002627, RefClock->GetTime: 3519571853125, QueryPerformanceCounter: 571647307563
Tick: 00002630, RefClock->GetTime: 3519571853125, QueryPerformanceCounter: 571647312334
Tick: 00002659, RefClock->GetTime: 3519571853125, QueryPerformanceCounter: 571647359537
Tick: 00002694, RefClock->GetTime: 3519571853125, QueryPerformanceCounter: 571647416523
Tick: 00002777, RefClock->GetTime: 3519573471042, QueryPerformanceCounter: 571647551683
Tick: 00002779, RefClock->GetTime: 3519573491042, QueryPerformanceCounter: 571647555613
Tick: 00002799, RefClock->GetTime: 3519573691042, QueryPerformanceCounter: 571647586867
Tick: 00002827, RefClock->GetTime: 3519573888542, QueryPerformanceCounter: 571647632097
Tick: 00002877, RefClock->GetTime: 3519573888542, QueryPerformanceCounter: 571647713443
Tick: 00002960, RefClock->GetTime: 3519574871459, QueryPerformanceCounter: 571647848364
Tick: 00002993, RefClock->GetTime: 3519574871459, QueryPerformanceCounter: 571647901939
Tick: 00003059, RefClock->GetTime: 3519576298959, QueryPerformanceCounter: 571648010260
As you probably know, the DirectShow reference clock is usually provided by the audio renderer. On fps' PC, with LAV Splitter -> LAV Audio Decoder -> madVR it seems that the reference clock is behaving very bad. E.g. in one case (see above) the reference clock doesn't progress *at all* for 70ms. This is the reason why madVR's rendering gets all screwed up. I don't have logs from fps when using a different audio decoder, so I can't say how different that would be. But I can say that on my PC I can't reproduce the problem. With LAV Audio Decoder my reference clock is progressive smoothly.

I don't really know how an audio decoder can stop the reference clock from moving forward, but I guess it's possible. E.g. I could imagine if the audio decoder is outputting nothing for 70ms, and then outputting a few MBs of audio data in one big chunk, that might explain the problem. How large are your LAV Audio Decoder output buffers? It might help to make sure that your decoder outputs data constantly, instead of collecting decoded audio data and then sending it in big chunks.