View Full Version : LAV Filters - DirectShow Media Splitter and Decoders
bjd
29th January 2011, 13:44
Excellent work
Couple of tests
===========
1) MP3/DTS/AC3/AAC file
Mpc-hc -> internal splitter -> lavc audio -> Reclock
Reclock identifies 32fp as expected - Sounds Great
2) Dark Knight Bluray (TrueHd test)
Mpc-hc -> lavf Splitter -> lavc audio -> Reclock
Reclock identifes 24bit PCM - Sounds Great
3) Dark Knight Bluray (TrueHd test)
Mpc-hc -> internal Splitter -> lavc audio -> Reclock
Reclock identifes 32fp - No Sound
Presumably lavc can't handle interleaved Truehd/ac3 ?
Plutotype
29th January 2011, 13:55
Hi,
Thanks for your work newcairiel and I think, finally we have somebody, who is able to work on splitter and audio decoder paralelly. In the world of multiple types of audiostreams, this was necessary to fix connections between them and the splitter.
After first testing, when LAVCaudio preffered, it works an ALL samples I had in my library, but will test more later. Its also available to have Arcsoft and LAVCaudio decoders combined, so where Arsocft does not connect, LAVCaudio works flawlessly ( LPCM ).
With LAVsplitter and LAVCaudio the old LPCM mono stream issue is gone link (http://sourceforge.net/apps/trac/mpc-hc/ticket/71).
Many thanks again
Peter
nevcairiel
29th January 2011, 14:27
Excellent work
Couple of tests
===========
3) Dark Knight Bluray (TrueHd test)
Mpc-hc -> internal Splitter -> lavc audio -> Reclock
Reclock identifes 32fp - No Sound
Presumably lavc can't handle interleaved Truehd/ac3 ?
The MPC-HC internal MPEG Splitter sends an AC3 media type for TrueHD streams. Guess i need to add some tricks to make it detect that its actually TrueHD and not AC3 thats coming in there.
Or i just fix the MPC-HC mpeg splitter.
On another note, i noticed that avcodec enables DRC by default. So it would seem that AC3 and DTS actually have DRC going on for them in this version of LAVCAudio. It'll be off, or configurable, in the next version.
Personally, i failed to notice the difference, but only tried on my dev PC which has a limited link to my audio system. Need to try on my HTPC with full 7.1 LPCM hookup.
bjd
29th January 2011, 15:34
Nev,
The DRC thing is interesting. I use the Arcsoft decoder for DTS, but have only ever come accross one DRC'd DTS and it was only set to -4db compared to the normal -27-29db you get with AC3.
The fact is, that your 32fp output from lavc is far superior to the 32fp liba52 output from Ffdshow.
liba52 is far quieter and sounds compressed by comparison. libavcodec levels in ffdshow are similar but output is limited to 16int when no DRC. However the DRC is noticable between lavc and ffdshow when comparing DRC ac3
Superb
29th January 2011, 16:12
@nevcairiel: Amazing work. I keep reading this thread and following development, and I'm really impressed by all the contribution you give. Thank you.
Ger
29th January 2011, 19:19
Great work. LATM samples from Norway, Denmark, New Zealand, Portugal and UK all play fine. :)
Noticed a problem with LATM 5.1/2.0 audio track switching though. I don't know if you downloaded the Danish sample I mentioned earlier in the thread "The_Gift_-_DR_HD_-_2009-12-23.ts". It used to be on a MediaPortal server, but the link is dead now. Let me know if you need it and I can upload it somewhere else.
The 5.1 track in this sample used to sound like a power tool with Monogram AAC, but plays fine now with LAVCAudio. The problem occurs if I try to switch to the stereo track (which used to work with Monogram). After switching it goes silent, and right-clicking in the MPC-HC video frame produces an "Unspecified error" dialog. I also noticed that LAVCAudio connects to AC3Filter with this sample, I guess because it's 5.1 rather than stereo like the other LATM samples, feeding PCM float to AC3Filter. Maybe the error is related to that?
nevcairiel
29th January 2011, 19:24
That it adds AC3Filter in there is weird, but i might know why it happens, i could use the sample to verify though.
Ger
29th January 2011, 20:10
The_Gift_-_DR_HD_-_2009-12-23.ts (http://www.multiupload.com/O17QVRTW8N)
BTW, I was using MPC-HC r2897.
nevcairiel
29th January 2011, 20:18
Hm i cannot reproduce any problems with switching. It does hang for half a second on switch, but then just plays.
I'll install AC3Filter and see what happens.
Ger
29th January 2011, 21:16
Weird. I just tried the opposite, uninstalling AC3Filter. The first attempt to play that sample after uninstalling AC3Filter (1.63b Full) made MPC-HC hang. Second attempt LAVFSplitter connected to Monogram AAC (producing power tool sound), even though both LAVFSplitter and LAVCAudio are set to "prefer" in MPC-HC.
LAVFSplitter just doesn't want to connect to LAVCAudio with this sample when I don't have AC3Filter installed. After reinstalling AC3Filter it's back to the original behavior.
nevcairiel
29th January 2011, 22:13
Connection between LAVFSplitter and LAVCAudio should always work. Its more likely that LAVCAudio and your sound renderer refuse to connect, and therefore the graphbuilder chooses another filter.
Are you using ReClock, the MPC-HC renderer, or the default windows renderer?
Did you try with other files, like AC3 or "normal" AAC, which also decode to 32-bit float, and say a Vorbis file (or a PCM file), which decodes to 16-bit int, for comparison?
Edit:
It would appear i cannot get MPC-HCs own audio renderer to accept float input. It'll always try to use your favorite renderer, and as long as it can build a decoder chain to get there, thats what it will do.
If it cannot get it to do that, it'll switch to another renderer, and choose the codecs freely.
At least i know how to test the automatic sample format chooser for the next version now.. =)
Ger
29th January 2011, 23:52
Think you're on to something there.
I use the System Default renderer (more info about that below).
It's definitely related to 5.1 vs. 2.0. If I uninstall AC3Filter I can switch between the 5.1 and 2.0 tracks in that sample, and the 5.1 track loads Monogram and the 2.0 track loads LAVCAudio.
With lavcaudio set to "prefer":
AC3 2.0 track: LAVCAudio loads (alone) and sounds good.
AC3 5.1 track: Highest merit AC3 decoder is used. Internal, ffdshow etc. LAVCAudio is not loaded at all.
I'll just include some more info in case it helps (this is all with The Gift sample):
With AC3Filter installed:
LAVFSplitter -> LAVCAudio -> AC3Filter -> Audio Switcher -> Default DirectSound Device - CLSID : {79376820-07D0-11CF-A24D-0020AFD79767}
Without AC3Filter:
LAVFSplitter -> Monogram AAC decoder -> Audio Switcher -> Default DirectSound Device - CLSID : {79376820-07D0-11CF-A24D-0020AFD79767}
Default DirectSound Device should be Speakers on Realtek ALC 885 HDAUDIO. Configured for stereo (tried changing to 5.1, even though I don't have enough speakers, but no change in behavior).
Not using custom mapping in MPC-HC audio switcher.
Tried "DirectSound: AMD HDMI Output" (which I use regularly for my TV), and it also goes straight to Monogram AAC (when AC3Filter isn't installed), like the Realtek DS default.
Tried Speakers (without the DirectSound prefix), and lavcaudio now loads, but no audible result (silence).
The only audiorenderer option in MPC-HC that produces proper sound for me without AC3Filter is "Default WaveOut Device - CLSID : {E30629D1-27E5-11CE-875D-00608CB78066}".
So summarized, I guess LAVCAudio is happy to accept 2.0 tracks, but doeesn't want 5.1 tracks when used with with any of my DirectSound renderers. With non-DS renderers the results are mixed.
If you want me to copy/paste the pin info from a particular place in the chain, with or without AC3Filter installed, let me know.
nevcairiel
30th January 2011, 00:04
The output pin of AC3Filter in the default setup would be helpful, and possibly also of Monogram without AC3Filter.
I see two posibilities there: Either its giving up because of the float data, or its giving up because of the multi-channel data when you have only stereo. I hope the data will give me some more pointers.
Which OS are you on? The default mixer in Win7 seems to be plenty smart and deals with all i throw at it, so not easy to solve such riddles =P
In any case, the next version will have a property page where you can disable certain sample formats, which would at least help to debug one of these possibilities. I wrote some code for automatic detection as well, but who knows if the audio renderers are really honest about their answers. ;)
Ger
30th January 2011, 00:33
I'm using Win7 Ultimate 64-bit.
All players/filters used are 32-bit though.
AC3Filter Output pin with my normal settings, which is to downmix to stereo:
Filter : AC3Filter - CLSID : {A753A1EC-973E-4718-AF8E-A3F554D45C44}
- Connected to:
CLSID: {18C16B08-6497-420E-AD14-22D21C2CEAB7}
Filter: Audio Switcher
Pin: Audio
- Connection media type:
Audio: PCM 48000Hz stereo 1536kbps
AM_MEDIA_TYPE:
majortype: MEDIATYPE_Audio {73647561-0000-0010-8000-00AA00389B71}
subtype: MEDIASUBTYPE_PCM {00000001-0000-0010-8000-00AA00389B71}
formattype: FORMAT_WaveFormatEx {05589F81-C356-11CE-BF01-00AA0055595A}
bFixedSizeSamples: 1
bTemporalCompression: 0
lSampleSize: 1
cbFormat: 18
WAVEFORMATEX:
wFormatTag: 0x0001
nChannels: 2
nSamplesPerSec: 48000
nAvgBytesPerSec: 192000
nBlockAlign: 4
wBitsPerSample: 16
cbSize: 0 (extra bytes)
pbFormat:
0000: 01 00 02 00 80 bb 00 00 00 ee 02 00 04 00 10 00 ....€»...î......
0010: 00 00 ..
- Enumerated media type 0:
Set as the current media type
AC3Filter downmixing disabled. Set to output "as is". This does not change the situation/graph/result at all AFAICT. I can still hear the audio just fine.
Filter : AC3Filter - CLSID : {A753A1EC-973E-4718-AF8E-A3F554D45C44}
- Connected to:
CLSID: {18C16B08-6497-420E-AD14-22D21C2CEAB7}
Filter: Audio Switcher
Pin: Audio
- Connection media type:
Audio: WAVE_FORMAT_EXTENSIBLE 48000Hz 6ch 4608kbps
AM_MEDIA_TYPE:
majortype: MEDIATYPE_Audio {73647561-0000-0010-8000-00AA00389B71}
subtype: MEDIASUBTYPE_PCM {00000001-0000-0010-8000-00AA00389B71}
formattype: FORMAT_WaveFormatEx {05589F81-C356-11CE-BF01-00AA0055595A}
bFixedSizeSamples: 1
bTemporalCompression: 0
lSampleSize: 1
cbFormat: 40
WAVEFORMATEX:
wFormatTag: 0xfffe
nChannels: 6
nSamplesPerSec: 48000
nAvgBytesPerSec: 576000
nBlockAlign: 12
wBitsPerSample: 16
cbSize: 22 (extra bytes)
WAVEFORMATEXTENSIBLE:
wValidBitsPerSample: 16
dwChannelMask: 0x0000003f
SubFormat: {00000001-0000-0010-8000-00AA00389B71}
pbFormat:
0000: fe ff 06 00 80 bb 00 00 00 ca 08 00 0c 00 10 00 þÿ..€»...Ê......
0010: 16 00 10 00 3f 00 00 00 01 00 00 00 00 00 10 00 ....?...........
0020: 80 00 00 aa 00 38 9b 71 €..ª.8›q
- Enumerated media type 0:
Set as the current media type
- Enumerated media type 1:
Audio: PCM 48000Hz 6ch 4608kbps
AM_MEDIA_TYPE:
majortype: MEDIATYPE_Audio {73647561-0000-0010-8000-00AA00389B71}
subtype: MEDIASUBTYPE_PCM {00000001-0000-0010-8000-00AA00389B71}
formattype: FORMAT_WaveFormatEx {05589F81-C356-11CE-BF01-00AA0055595A}
bFixedSizeSamples: 1
bTemporalCompression: 0
lSampleSize: 1
cbFormat: 18
WAVEFORMATEX:
wFormatTag: 0x0001
nChannels: 6
nSamplesPerSec: 48000
nAvgBytesPerSec: 576000
nBlockAlign: 12
wBitsPerSample: 16
cbSize: 0 (extra bytes)
pbFormat:
0000: 01 00 06 00 80 bb 00 00 00 ca 08 00 0c 00 10 00 ....€»...Ê......
0010: 00 00 ..
Monogram AAC decoder output pin (no channel mixing) when AC3Filter is not installed and LAVCAudio is not loaded. I can hear the audio weakly in the background, but an annoying noise on top of that is far more powerful:
Filter : MONOGRAM AAC Decoder - CLSID : {3FC3DBBF-9D37-4CE0-8689-653FE8BAB9B3}
- Connected to:
CLSID: {18C16B08-6497-420E-AD14-22D21C2CEAB7}
Filter: Audio Switcher
Pin: Audio
- Connection media type:
Audio: WAVE_FORMAT_EXTENSIBLE 48000Hz 6ch 4608kbps
AM_MEDIA_TYPE:
majortype: MEDIATYPE_Audio {73647561-0000-0010-8000-00AA00389B71}
subtype: MEDIASUBTYPE_PCM {00000001-0000-0010-8000-00AA00389B71}
formattype: FORMAT_WaveFormatEx {05589F81-C356-11CE-BF01-00AA0055595A}
bFixedSizeSamples: 1
bTemporalCompression: 0
lSampleSize: 1
cbFormat: 40
WAVEFORMATEX:
wFormatTag: 0xfffe
nChannels: 6
nSamplesPerSec: 48000
nAvgBytesPerSec: 576000
nBlockAlign: 12
wBitsPerSample: 16
cbSize: 22 (extra bytes)
WAVEFORMATEXTENSIBLE:
wValidBitsPerSample: 16
dwChannelMask: 0x0000003f
SubFormat: {00000001-0000-0010-8000-00AA00389B71}
pbFormat:
0000: fe ff 06 00 80 bb 00 00 00 ca 08 00 0c 00 10 00 þÿ..€»...Ê......
0010: 16 00 10 00 3f 00 00 00 01 00 00 00 00 00 10 00 ....?...........
0020: 80 00 00 aa 00 38 9b 71 €..ª.8›q
- Enumerated media type 0:
Set as the current media type
Setting Monogram to downmix to stereo does not change that audio/noise.
nevcairiel
30th January 2011, 00:37
Thanks. All the working filters are outputting 16bit integer, while i throw 32-bit float data at the renderer.
One last test, can you set the sample format in AC3Filter to "AS IS" as well (or PCM Float for that matter), and see if it stops working completly, or rather, falls back to Monogram?
I'll have probing code in the future, as well as manual toggles to disable formats, which should fix it then.
Ger
30th January 2011, 00:59
I just noticed that and was actually just about to post the pin info. There is no as is option in the format drop-down, so this is with the three AC3Filter main tab output format options set to as is for channels, as is for rate, and PCM Float for format. SPDIF unchecked.
The audio still works/sounds just fine.
Filter : AC3Filter - CLSID : {A753A1EC-973E-4718-AF8E-A3F554D45C44}
- Connected to:
CLSID: {18C16B08-6497-420E-AD14-22D21C2CEAB7}
Filter: Audio Switcher
Pin: Audio
- Connection media type:
Audio: WAVE_FORMAT_EXTENSIBLE 48000Hz 6ch 9216kbps
AM_MEDIA_TYPE:
majortype: MEDIATYPE_Audio {73647561-0000-0010-8000-00AA00389B71}
subtype: MEDIASUBTYPE_PCM {00000001-0000-0010-8000-00AA00389B71}
formattype: FORMAT_WaveFormatEx {05589F81-C356-11CE-BF01-00AA0055595A}
bFixedSizeSamples: 1
bTemporalCompression: 0
lSampleSize: 1
cbFormat: 40
WAVEFORMATEX:
wFormatTag: 0xfffe
nChannels: 6
nSamplesPerSec: 48000
nAvgBytesPerSec: 1152000
nBlockAlign: 24
wBitsPerSample: 32
cbSize: 22 (extra bytes)
WAVEFORMATEXTENSIBLE:
wValidBitsPerSample: 32
dwChannelMask: 0x0000003f
SubFormat: {00000003-0000-0010-8000-00AA00389B71}
pbFormat:
0000: fe ff 06 00 80 bb 00 00 00 94 11 00 18 00 20 00 þÿ..€»...”.... .
0010: 16 00 20 00 3f 00 00 00 03 00 00 00 00 00 10 00 .. .?...........
0020: 80 00 00 aa 00 38 9b 71 €..ª.8›q
- Enumerated media type 0:
Set as the current media type
- Enumerated media type 1:
Audio: IEEE Float 48000Hz 6ch 9216kbps
AM_MEDIA_TYPE:
majortype: MEDIATYPE_Audio {73647561-0000-0010-8000-00AA00389B71}
subtype: MEDIASUBTYPE_PCM {00000001-0000-0010-8000-00AA00389B71}
formattype: FORMAT_WaveFormatEx {05589F81-C356-11CE-BF01-00AA0055595A}
bFixedSizeSamples: 1
bTemporalCompression: 0
lSampleSize: 1
cbFormat: 18
WAVEFORMATEX:
wFormatTag: 0x0003
nChannels: 6
nSamplesPerSec: 48000
nAvgBytesPerSec: 1152000
nBlockAlign: 24
wBitsPerSample: 32
cbSize: 0 (extra bytes)
pbFormat:
0000: 03 00 06 00 80 bb 00 00 00 94 11 00 18 00 20 00 ....€»...”.... .
0010: 00 00 ..
nevcairiel
30th January 2011, 01:04
Interesting. Its still sending a MEDIASUBTYPE_PCM and then marks it as float with the format tag.
I'll run some tests with that.
nevcairiel
30th January 2011, 01:56
I looked into that, and it looks like ffdshow is using the same output type that i'm using, so huh.
In any case, i fixed a bug earlier that would always result in wrong channel assignment in the first media type. Maybe that caused it already.
Here is a quick test build with that fixed:
http://files.1f0.de/lavf/LAVCAudio-0.13-debug1.zip
With that build, my media type looks suspiciously similar to what you posted in the last post, except that my subtype is MEDIASUBTYPE_IEEE_FLOAT instead of PCM - otherwise identical.
Maybe that was already it. Who knows! Just need to rule it out.
I currently have my realtek onboard card turned off, going to activate it tomorrow to see if there is any difference when using it.
But zzzzzz now.
PS:
that build also has DRC turned off :D
bjd
30th January 2011, 01:57
On another note, i noticed that avcodec enables DRC by default. So it would seem that AC3 and DTS actually have DRC going on for them in this version of LAVCAudio.
Already looking forward to the next version.
I have been testing the splitter and the audio filter further today. The audio filter seems to do its job just about perfectly and is amazing for a week's work.
With regard to the splitter, I have noticed that when splitting an .mkv file with AC3 if ffdshow audio is invoked, the file never starts playing. Moving the seek bar on solves this. This could be an ffdshow bug or a slight incompatibility as replacing ffdshow with lavcaudio solves this......all the more reason for getting rid of the DRC in the next version :)
Ger
30th January 2011, 03:33
I looked into that, and it looks like ffdshow is using the same output type that i'm using, so huh.
In any case, i fixed a bug earlier that would always result in wrong channel assignment in the first media type. Maybe that caused it already.
Here is a quick test build with that fixed:
http://files.1f0.de/lavf/LAVCAudio-0.13-debug1.zip
With that build, my media type looks suspiciously similar to what you posted in the last post, except that my subtype is MEDIASUBTYPE_IEEE_FLOAT instead of PCM - otherwise identical.
Maybe that was already it. Who knows! Just need to rule it out.
I currently have my realtek onboard card turned off, going to activate it tomorrow to see if there is any difference when using it.
But zzzzzz now.
You can forget about that Realtek option, because you've already fixed it. :)
This build works perfectly with absolutely everything I've thrown at it so far.
When AC3Filter is installed it stays out of the graph and LAVCAudio handles all the audio decoding stuff alone. When AC3Filter is not installed LAVCAudio still loads and handles everything just fine. So everything works as expected in all cases. Switching from 5.1 to 2.0 and back also works fine with that same sample. AC3 5.1 is also fine now.
PS:
that build also has DRC turned off :D
I actually rather like DRC, so I'll probably enable it when it becomes optional. I don't have very impressive audio hardware, and I'm not a big fan of perceived loudness jumps. Especially when people are sleeping. ;)
PS. This is not a problem for me or anyone else who knows how to set a decoders merit or use a player that can prefer it like MPC-HC, but can you control the merit it gets when registering it in the .ax itself, or does it have to be set externally afterwards? If you control it, maybe you should increase the merit. Because if I don't change the merit or set it to "prefer" LAVCAudio seems to come after Monogram, ffdshow etc. Or maybe LAVFSplitter can prioritize LAVCAudio regardless of merit, unless that is considered bad behavior?
Anyway, thanks again. Amazing work. :thanks:
Ger
30th January 2011, 04:09
With regard to the splitter, I have noticed that when splitting an .mkv file with AC3 if ffdshow audio is invoked, the file never starts playing. Moving the seek bar on solves this.
Can't reproduce here with a random mkv with 5.1 AC3. LAVFSplitter 0.13 and ffdshow r3751. 32-bit versions. Maybe it only happens to some files?
I have a similar issue with a tiny minority of AVIs with XviD/MP3 though. In my case the elapsed time is ticking away, but there is a black screen and no audio until I seek. Only happens when starting from the very beginning of the file and I very rarely encounter such files. I have many files encoded by the same guy, and only a few are affected. Don't think my particular issue is related to audio/ffdshow though. It has also been present in all old LAVFSplitter betas AFAIR, I just never prioritized reporting it.
bjd
3rd February 2011, 14:47
Here is a quick test build with that fixed:
http://files.1f0.de/lavf/LAVCAudio-0.13-debug1.zip
No DRC :thanks::thanks:
I can finally de-prioritise ffdshow. I am not sure what ffdshow does with the audio signal, but every format I throw at the new audio decoder sounds purer.
I have been using the splitter/decoder all week and have yet to find an .avi/.mkv it has a problem with.
nevcairiel
3rd February 2011, 15:22
PS. This is not a problem for me or anyone else who knows how to set a decoders merit or use a player that can prefer it like MPC-HC, but can you control the merit it gets when registering it in the .ax itself, or does it have to be set externally afterwards? If you control it, maybe you should increase the merit. Because if I don't change the merit or set it to "prefer" LAVCAudio seems to come after Monogram, ffdshow etc. Or maybe LAVFSplitter can prioritize LAVCAudio regardless of merit, unless that is considered bad behavior?
Configuring the merit from within the decoder is possible, however on Vista/7 it requires that the process is launched with administrative rights - and who does that with their media player.
I will increase the merit so its higher on the preferred list, and once i start supplying a installer, i might as well add an option inside there to choose it at install time.
LAVFSplitter does not decide which filters it connects to. I could, however, add an option to LAVFSplitter to disable the "normal" media types, which would result in LAVFSplitter only ever connecting to LAVCAudio, and never anything else :rolleyes:
-------------
While the forums were down, i've been mostly polishing it and fixing bugs. Right now i'm still working on the config panel, which will allow you to configure DRC, as well as disable certain sample formats (mostly for debugging). Not sure what else needs to be configurable in the audio decoder. I'm not yet ready to do re-matrixing, although for maximum quality those options should be present in the decoder, as some formats include matrix informations, especially how to do a stereo downmix, for example - and that information is lost when letting someone else do the downmixing.
Mercury_22
3rd February 2011, 16:39
Channels for 7.1 LPCM are wrong mapped : side (surround) channels are output to rear speakers and vice versa
If you need test files here are some http://forum.doom9.org/showthread.php?p=1333032#post1333032
Also when using LAVCAudio the playback it's NOT as smooth as when using MPC-HC's decoders (watch the green line in stats) !
nevcairiel
3rd February 2011, 16:43
The renderer stats have nothing to do with the audio decoder.
Also, does this only affect LPCM 7.1 and not other 7.1 sources?
Mercury_22
3rd February 2011, 16:47
The renderer stats have nothing to do with the audio decoder.
Also, does this only affect LPCM 7.1 and not other 7.1 sources?
Just the LPCM but I can't test DTS-HD or E-AC3 7.1 due to the limitations (only 5.1) of the ffmpeg
EDIT I'm using xhmikosr's latest builds http://xhmikosr.1f0.de/index.php?folder=bGF2ZnNwbGl0dGVy
nevcairiel
3rd February 2011, 18:36
It turns out, TrueHD is actually wrong, and i used that to setup the channel assignment matrix. TrueHD is now special cased, and all 7.0/7.1 formats should hopefully be fine.
I couldn't test with any other 7.1 formats yet (besides TrueHD and LPCM), as i have none. I got my hands on some FLAC trac, which seems to be fine as well now, but the file seemed bugged to begin with, so i'll not use it as any reference.
Virtual_ManPL
3rd February 2011, 21:31
@ nevcairiel - can you reopen bug #23 (https://github.com/Nevcairiel/LAVFSplitter/issues/closed#issue/23) ? Because I accidentally close it
mindbomb
3rd February 2011, 22:54
I have a lavfsplitter issue. maybe bjd experienced this also with the dark knight, but when i tried playing a m2ts with vc-1 video and truehd audio, the player reported the file length at 5 mins instead of 2 and a half hours. It was able to play the first 5 minutes normally, and then the video continued to play while the seek bar was maxed out. with mpc's internal filter and lavcaudio, there is no sound and 32 float as bjd said.
nevcairiel
3rd February 2011, 22:56
Is the file actually longer that you tried to open? Or is it one of those seamless branching BluRays that are split into hundred small pieces? :d
Plutotype
3rd February 2011, 23:15
I experience the issue with a wrong lenght of the track too. Seekbar in MPC-HC shows only couple of minutes of the real lenght - you can not seek in the full timeline. The weird thing is, im experiencing this in untouched streams and also in remuxed streams ( Im using TSmuxer 10.6 ). Using 4 of 5 movies have wrong lenght.
LAVsplitter 0.13, madvr 0.36
mindbomb
4th February 2011, 00:01
Is the file actually longer that you tried to open? Or is it one of those seamless branching BluRays that are split into hundred small pieces? :d
When using the mpc splitter, i get the correct time of 2h 38min 25s. when using lavfsplitter, i get 5 min 42 seconds.
The seekbar actually does work correctly for the entire 5 min and 42 seconds though. After 5 min 42 seconds, the video just continues to play, but the player reports 5:42/5:42 continually.
I'm playing the m2ts from the stream folder, there appears to be no seamless branching, it is just one large file.
bjd
4th February 2011, 00:06
Is the file actually longer that you tried to open?
Example below is main m2ts from PAL verson of 300 (Vc-1/TrueHd)
General
ID : 0 (0x0)
Complete name : E:\BDMV\STREAM\00000.m2ts
Format : BDAV
Format/Info : Blu-ray Video
File size : 24.7 GiB
Duration : 1h 56mn
Overall bit rate : 30.3 Mbps
Maximum Overall bit rate : 48.0 Mbps
Video
ID : 4113 (0x1011)
Menu ID : 1 (0x1)
Format : VC-1
Format profile : AP@L3
Codec ID : 234
Duration : 1h 56mn
Width : 1 920 pixels
Height : 1 080 pixels
Display aspect ratio : 16:9
Frame rate : 23.976 fps
Chroma subsampling : 4:2:0
Bit depth : 8 bits
Scan type : Progressive
Compression mode : Lossy
Mpc-Hc reports 03:06
File carries on playing after 3 mins 6 secs fine. No problems with playback just wrong time. m2ts with vc-1/dts-hd seem fine. The Dark Knight PAL (vc1/truehd) correctly shows 02:32:13.
Batman Forever PAL (vc1/truehd) main m2ts (37+ gb) shows only 17 seconds as the running time. Once again plays fine after 17 seconds.
mindbomb
4th February 2011, 05:22
atm, if you use ffdshow for mixing, it converts the 24 bit pcm to 16 bit or 32 bit pcm. I want to avoid this, so I'm wondering what other options are there for just a simple stereo downmix?
also, im looking for a way to disable dts decoding in lavcaudio. I'm guessing I can do this by removing a media subtype, though I don't know which one.
nevcairiel
4th February 2011, 07:59
Can you try LAVFSplitter 0.12 on those m2ts files and see if the duration is more accurate?
Guess i have to get some of my BluRays and test them for that bug.
bjd
4th February 2011, 10:29
also, im looking for a way to disable dts decoding in lavcaudio. I'm guessing I can do this by removing a media subtype, though I don't know which one.
If you are using Mpc-Hc, move your preferred dts decoder above lavc audio in your external list. If both are set to preferred, these will be used first before any other filters (including internal ones). Whichever is higher in the list will be used first.
You may have to remove some media types from your prefered DTS decoder if it decodes other streams, but for DTS, it should just need.
{E06D8033-DB46-11CF-B4D1-00805F6CBBEA} DTS
{00002001-0000-0010-8000-00AA00389B71} DTS in mkv
I usually clear the list and create a "Any Type" main media type and add a custom list of subtypes.
You need to check what your splitter presents, in case you need to add any other types.
nevcairiel
4th February 2011, 10:31
I'll eventually offer some config options which formats it should decode, but thats something for a later day.
bjd
4th February 2011, 12:42
atm, if you use ffdshow for mixing, it converts the 24 bit pcm to 16 bit or 32 bit pcm. I want to avoid this, so I'm wondering what other options are there for just a simple stereo downmix?
I am using unified Xonar Drivers on a D2. Although it is a 7.1 soundcard, I am only listening to headphones at work. I can send bit exact multichannel 24bit pcm via relclock to the soundcard and by selecting 2 channels in Xonar control panel get a decent sounding downmix, but obviously I have no control or knowledge of how that downmix is actually performed in soundcard's driver and it is a 32bit DSP anyway.
BelowSky
4th February 2011, 15:29
Hi nevcairiel.
May I suggest a better naming for the codecs, so they look more professional!
"lavc audio decoder" to "LAV Audio Decoder"
"lavf dshow source filter" to "LAV Splitter"
or as:
"LAV DS Splitter" for DirectShow
"LAV MF Splitter" for Media Foundation.
- Unified "lavc" & "lavf" into "LAV" so that it could be used as a codec brand name.
- Removed "C" and "F" from "lavc" & "lavf" because "Decoder" and "Splitter" can replace them efficiently.
- Replaced "filter" with "Splitter" because it is more common on Windows to use "Splitter" than "filters"
- Last but not least, I didn't know what to do with "dshow". I'm not sure if you guys made that to distinguish it from a Media Foundation variant.
nevcairiel
4th February 2011, 16:23
Mpc-Hc reports 03:06
File carries on playing after 3 mins 6 secs fine. No problems with playback just wrong time. m2ts with vc-1/dts-hd seem fine. The Dark Knight PAL (vc1/truehd) correctly shows 02:32:13.
Batman Forever PAL (vc1/truehd) main m2ts (37+ gb) shows only 17 seconds as the running time. Once again plays fine after 17 seconds.
I found a disc with the same problem, but it seems to be weird. None of the timings are even close to the real length, must be something funny in ffmpeg. But if it only affects blurays, i may be able to do something about that...
bjd
4th February 2011, 16:37
But if it only affects blurays, i may be able to do something about that...
It does seems isolated to vc-1/truehd in m2ts. I have not come across it it any mkv/avi regardless of the streams.
I wonder if ffplay exhibits the same bug then ?
mindbomb
4th February 2011, 20:11
I usually clear the list and create a "Any Type" main media type and add a custom list of subtypes.
Thanks bjd, that worked out well.
Will Lavcaudio ever have a stereo and 5.1 downmix option?
I know nev is trying to limit postprocessing, but I'm finding it very difficult to get lavcaudio to work on my stereo setup.
Right now, my sound card just drops all the channels except the FL and FR, so i have a lot of missing sound.
bjd
4th February 2011, 20:34
Right now, my sound card just drops all the channels except the FL and FR, so i have a lot of missing sound.
What soundcard do you have ?
must be something funny in ffmpeg
ffmplay will not play the .m2ts files off my 300 disc, but interestingly reports an incorrect duration 00:00:03.98 on the main movie file
mindbomb
4th February 2011, 20:53
im using a laptop with IDT high definition audio codec as its integrated sound atm.
nevcairiel
4th February 2011, 21:01
Adding rematrixing is something that i might do eventually, because alot of audio drivers do actually fail to downmix multichannel when only stereo is connected, for example.
To what extend, i cannot say yet. The configuration for that is probably the most annoying part to code.
bjd
4th February 2011, 23:03
Just found a possible issue with DVD_LPCM
LAVf splitter correctly identifes pcm_dvd, 96000 Hz, 2 channels, s24, 4608 kb/s
and the lavc decoder is fed 24/96 PCM
CLSID: {B98D13E7-55DB-4385-A33D-09FD1BA26338}
Filter: E:\VIDEO_TS\VTS_01_1.VOB
Pin: Audio
- Connection media type:
Audio: 0x0000 96000Hz stereo 4608kbps
AM_MEDIA_TYPE:
majortype: MEDIATYPE_Audio {73647561-0000-0010-8000-00AA00389B71}
subtype: MEDIASUBTYPE_DVD_LPCM_AUDIO {E06D8032-DB46-11CF-B4D1-00805F6CBBEA}
formattype: FORMAT_WaveFormatEx {05589F81-C356-11CE-BF01-00AA0055595A}
bFixedSizeSamples: 1
bTemporalCompression: 0
lSampleSize: 256000
cbFormat: 18
WAVEFORMATEX:
wFormatTag: 0x0000
nChannels: 2
nSamplesPerSec: 96000
nAvgBytesPerSec: 576000
nBlockAlign: 8
wBitsPerSample: 24
cbSize: 0 (extra bytes)
pbFormat:
0000: 00 00 02 00 00 77 01 00 00 ca 08 00 08 00 18 00 .....w...Ê......
0010: 00 00
But outputs 32bit PCM
Audio: WAVE_FORMAT_EXTENSIBLE 96000Hz stereo 6144kbps
AM_MEDIA_TYPE:
majortype: MEDIATYPE_Audio {73647561-0000-0010-8000-00AA00389B71}
subtype: MEDIASUBTYPE_PCM {00000001-0000-0010-8000-00AA00389B71}
formattype: FORMAT_WaveFormatEx {05589F81-C356-11CE-BF01-00AA0055595A}
bFixedSizeSamples: 1
bTemporalCompression: 0
lSampleSize: 8
cbFormat: 40
WAVEFORMATEX:
wFormatTag: 0xfffe
nChannels: 2
nSamplesPerSec: 96000
nAvgBytesPerSec: 768000
nBlockAlign: 8
wBitsPerSample: 32
cbSize: 22 (extra bytes)
WAVEFORMATEXTENSIBLE:
wValidBitsPerSample: 32
dwChannelMask: 0x00000003
SubFormat: {00000001-0000-0010-8000-00AA00389B71}
pbFormat:
0000: fe ff 02 00 00 77 01 00 00 b8 0b 00 08 00 20 00 þÿ...w...¸.... .
0010: 16 00 20 00 03 00 00 00 01 00 00 00 00 00 10 00 .. .............
0020: 80 00 00 aa 00 38 9b 71 €..ª.8›q
- Enumerated media type 0:
Set as the current media type
nevcairiel
4th February 2011, 23:34
Thanks for the report, i think i know why, should be fixed for the next version
Edit: Reproduced and fixed.
bjd
5th February 2011, 01:06
im using a laptop with IDT high definition audio codec as its integrated sound atm.
I have a similar issue with my laptop's SoundMax Digital HD codec.
To be honest, given that I am listening via crumby laptop speakers in this situation, 24bit output as 32int in ffdshow post proc does not really matter.
With headphone sound from the laptop, I have a Sennheiser MM200 AD2P bluetooth headset (limited to either 16/44.1 or 16/48 pcm) that sounds far superior to the built in SoundMax headphone socket. In this situation I use the ffdshow sample rate converter filter set to 44.1/48khz, and set ffdshow matrix mixer to 2 channel and output as 16bit to reclock
mindbomb
5th February 2011, 03:12
my desktop has a realtek integrated audio and a creative sound card.
when using the realtek, it can't downmix properly. When using the creative, it can.
I'm assuming that most people use a realtek audio chipset, so the rematrixing capability would be a welcome addition for a lot of people.
I'm glad to hear that it is being considered.
bjd
5th February 2011, 11:33
when using the realtek, it can't downmix properly.
I have the Realtek ALC888. It is used purely in 2 channel mode sending spdif to a high end external dec, I use the realtek because although the PCM output is poor, the SPDIF is bit perfect.
It doesnot have any problems downmixing multi-channel to stereo.
vBulletin® v3.8.11, Copyright ©2000-2025, vBulletin Solutions Inc.