Log in

View Full Version : Problem demuxing LPCM from a transport stream


phusg
20th October 2007, 12:46
Hi all (in particular neuron2),

I was wondering if anyone could help me with a problem I'm having getting 6 mono wavs demuxed from the lpcm audio track of a transport stream (.ts). I've already described the problem in detail here (http://www.hydrogenaudio.org/forums/index.php?showtopic=57781&pid=520488&mode=threaded&show=&st=&#entry520488):
1) Demux audio with DGIndex to a single PCM 48k 16bit 3/2lfe .pcm file.
2) Rename to a .raw and convert to wav with SoX.exe -r 48000 -s -w -c 6 file.raw file.wav
3) Split into 6 mono streams (.wavs) with WaveWizard (which needed to be set to ignore size)

WaveWizard tells me there is clipping in each file (peak conv is >2.x). The resulting .dts is mainly loud white noise. If I convert the sampling rate of the mono.wavs to 44100 then each wav individually also sounds like loud white noise, with occasional silent gaps in it (just like the .dts version)?!?

Can anybody tell me what's going on? DGIndex complains about there not being a video sequence header and the audio PID has to be set by hand to a Private Stream otherwise no demuxed .pcm file will come out...

I've also tried ProjectX and xport, but neither of them can demux the lpcm track. If I open the demuxed and renamed .pcm in audacity it recognises all 6 channels and looks something like this:

http://www.bushcraftsurvival.nl/imax.JPG

I noticed audacity was calling each channel 32-bit float, so I tried Sox.exe with the -l long word option instead of -w word option, but that gave (too) high pitched audio.

As you can see it starts with white noise but when this dies down I hear narration and music. The channels don't seem to be separated properly as the sentences are not coherent.

Does anyone have any ideas as to where the problem lies?

Thanks,
Pete

SeeMoreDigital
20th October 2007, 13:20
Hi Pete,

I'm confused... What has your question got to do with DGIndex?

Guest
20th October 2007, 13:30
@phusg

Please post a link to an unprocessed sample of your transport stream.

I have a 48k 16bit 3/2lfe test file and it demuxs fine. When I play the result in MPC it is OK.

When you play the demuxed file is it OK? Or do the problems set in only after you start trying to convert the demuxed file? If the latter, then this is not a DGIndex issue.

phusg
20th October 2007, 16:03
@phusg

Please post a link to an unprocessed sample of your transport stream.

I have a 48k 16bit 3/2lfe test file and it demuxs fine. When I play the result in MPC it is OK.

When you play the demuxed file is it OK? Or do the problems set in only after you start trying to convert the demuxed file? If the latter, then this is not a DGIndex issue.

I'm not too hot on manipulating .ts files, but here (http://www.bushcraftsurvival.nl/doom9_phusg_sample.zip)is a link to an unprocessed piece of a .ts torrent. It's not exactly the same piece as shown in the audacity screenshot above, but the problem is the same. DGIndex seems to demux it fine to a .pcm, I rename to .raw and use sox.exe as above before opening in audacity. Channel 3 definitely seems to contain some speech (a scream?) but the rest are mostly noise.

I don't know if the demuxed file is ok before converting with sox because audacity crashes when trying to open it.

Thanks for having a look.

phusg
20th October 2007, 16:07
Hi Pete,

I'm confused... What has your question got to do with DGIndex?

I'm not sure it does. IMHO there's either a problem with:

1) my transport streams
2) LPCM demuxing by DGIndex
3) sox.exe

As I'm hearing audio in some of the mono wavs coming out of this chain I'm inclined to think that 1) is not the problem. Hopefully neuron2 will be able to tell us more...

SeeMoreDigital
20th October 2007, 16:19
I'm not too hot on manipulating .ts files, but here (http://www.bushcraftsurvival.nl/doom9_phusg_sample.zip)is a link to an unprocessed piece of a .ts torrent.A .TS "torrent"!

Are you saying you did not capture the .TS stream yourself?

phusg
20th October 2007, 16:53
A .TS "torrent"!

Are you saying you did not capture the .TS stream yourself?

No I'm not. The .TS sample was legally procured by myself.

Guest
20th October 2007, 17:17
No I'm not. The .TS sample was legally procured by myself. Please explain how you legally procured it and why you posted a torrent.

Also, what is the PID of the stream you are talking about?

phusg
20th October 2007, 17:40
Please explain how you legally procured it and why you posted a torrent.

Also, what is the PID of the stream you are talking about?

Looks like I need to get myself a lawyer :eek:

In the Netherlands it is not illegal to download copyrighted works. Uploading of copyrighted works is illegal, but what I have uploaded is not a .torrent but a sample from a legally procured .TS. Under the US Copyright Act 1976 (USC) (the Netherlands has something similar), fair use of a copyrighted work (...) for purposes such as ... teaching (including multiple copies for classroom use), scholarship, or research, is not an infringement of copyright.
Legal jargon aside what I am trying to do here is find out whether I can make a full bit stream DTS track from a LPCM track, as the studios/distributors of this content do not always see fit to include this of their own accord.

The PID of the 'Private' stream is 0x1026 (4134).

Guest
20th October 2007, 21:34
here is a link to an unprocessed piece of a .ts torrent

what I have uploaded is not a .torrent Can't keep your story straight, huh? :)

Closed per rule 6.

Also see here:

http://forum.doom9.org/announcement.php?f=6