Help - Search - Members - Calendar
Full Version: MP3, Joint stereo
Hydrogenaudio Forums > Lossy Audio Compression > MP3 > MP3 - Tech
gbmallikarjunarao
Hi ,

Can any body helpme in the following .

1. In one Mp3 file, both stereo and joint stereo modes are possible or not?
i.e. some frames encoded as stereo and some frames as joint stereo.

2. is it same for both MPEG-1, MPEG-2 layerIII?

Thanks
Mallikarjun


SebastianG
double yes

Sebi
gbmallikarjunarao
QUOTE(SebastianG @ Jun 30 2005, 04:49 PM)

double yes

Sebi
*




Hi,

Thanks for your kind information.

I checked some files. The files are giving, same 'mode', throughout the whole file.

If it is stereo mode, mode bits showing '00' in the header,
if it is joint stereo, mode bits showing '01'.

can u send a mp3file, having both stereo and joint stereo?

Thanks
Mallikarjun
dreamliner77
most lame files (using the presets) should have both stereo and joint stereo frames.
mathematician
QUOTE(gbmallikarjunarao @ Jun 30 2005, 04:34 PM)
Hi ,

Can any body helpme in the following .

1. In one Mp3 file, both stereo and joint stereo modes are possible or not?
i.e. some frames encoded as stereo and some frames as joint stereo.

2. is it same for both MPEG-1, MPEG-2 layerIII?

Thanks
Mallikarjun
*



The Joint-Stereo mode of lame (especially with VBR and above 160kps CBR) is Safe-Joint-Stereo mode. i.e. It will decide dynamically whether to use M/S (Mid Side or commonly known as Joint Stereo) or L/R (Left Right or commonly known as Stereo) frame. But most frame analyzers will show the whole file as Joint Stereo. (Anybody having a free analyzer showing correct frames plz let me know wink.gif )

You can force this mode at those bitrates, where it is not enabled by default, using --nssafejoint switch.

Mpeg-2 is usually used for Lower bitrates and will be using intensity stereo (in other than lame encoders). In lame, intensity stereo is not there (AFAIK).

Just For Information (Off-The-Topic):
===========================

M/S is another representation of L/R.
i.e. one channel (L+R)/2 (MIDDLE) and another (L-R)/2 (SIDE)

When playing MP3 file, the decoder decodes it similarly

Left = Middle + Side
Right = Middle - Side

Substituting the earlier expressions for Middle and Side:

Left = (L+R)/2 + (L-R)/2
Right = (L+R)/2 - (L-R)/2

Left = L
Right = R

So, it's completely stereo.

Regards,

OM
rutra80
To add to all this, in joint-stereo mode (-m j) both stereo & joint-stereo frames are used, in stereo mode (-m s) only stereo frames are used. You can use EncSpot to see how many stereo & joint-stereo frames were used in a given MP3 file.
mathematician
QUOTE(rutra80 @ Jul 1 2005, 12:11 PM)
To add to all this, in joint-stereo mode (-m j) both stereo & joint-stereo frames are used, in stereo mode (-m s) only stereo frames are used. You can use EncSpot to see how many stereo & joint-stereo frames were used in a given MP3 file.
*



i see!
actually i am using windows xp, and an attempt to view this detail (about frames used) results in a fatal system error and my pc gets restarted.
if there's any other software, plz let me know
gbmallikarjunarao
Hi,

can anybody send one mp3 file to my mail id: gbmallikarjunarao@yahoo.com, which will show some frames as stereo and some frames as joint stereo in the mode part of header ?
At present i am not having lame encoder.

Thanks in advance,

Mallikarjun
SebastianG
QUOTE(gbmallikarjunarao @ Jul 1 2005, 06:25 AM)
Thanks for your kind information.

I checked some files. The files are giving, same 'mode', throughout the whole file.

If it is stereo mode, mode bits showing '00' in the header,
if it is joint stereo, mode bits showing '01'.
*



There's this 2 bit mode field in each header with
00 = stereo
01 = joint stereo
10 = dual channel
11 = mono

In case of this field being 01 (joint stereo) the mode extension field (again 2 bits) have the following meaning
00 = L/R (completely)
01 = L/R + Intensity for upper frequencies
10 = M/S (completely)
11 = M/S + Intensity for upper frequencies

Though it's not common for an MP3 encoder to produce a stream mixed of stereo and joint stereo frames one could replace mp3 headers in a stream with 01/00 (joint stereo, L/R completely) with 00 (stereo) or 10 (dual) since these three modes are actually equivalent (should be still legal). The difference is meta information only: By using 01/00 you signal that some frames might use M/S and/or Intensity coding in the stream.

IIRC nowhere in the MPEG-1 Audio specification is said that swithing between the first three modes (stereo, joint, dual) is illegal. It is however uncommon for an MP3 encoder to produce such streams. As for MP2, the TooLame encoder switches between stereo and joint frames in its joint-stereo mode to be able to totally switch off intensity stereo for all bands (the mode extension has another meaning for MP2 and is intensity stereo specific).

As for L.A.M.E: In the "joint-stereo mode" it produces always joint-stereo frames with mode extensions 00 or 10 (L/R or M/S frames -- always without Intensity Sterem (for 3.xx))

IMHO it should be avoided to switch between modes, even though the stream won't be illegal otherwise. The problem is that some decoders might check the mode of the first frame they can find and filter following frames (ie not accepting frames with another mode). The built-in MP2 decoder of PowerDVD is a decoder which does that in order to fight "read-errors" (They obviously think swithing is illegal and thus it must have been a read-error) -- So, TooLame's joint-stereo + PowerDVD doesn't work well due to the switching between joint and stereo frames.

HTH,
Sebi
Gabriel
Beware of dual channel: some decoders might properly interpret it.
loophole
What's the difference between dual channel and L+R?
Defsac
QUOTE(loophole @ Jul 1 2005, 11:47 PM)
What's the difference between dual channel and L+R?
*


Dual channel should only be used for surround sound.
Garf
No bitrate redistribution between channels.
Garf
QUOTE(Defsac @ Jul 1 2005, 04:08 PM)
QUOTE(loophole @ Jul 1 2005, 11:47 PM)
What's the difference between dual channel and L+R?
*


Dual channel should only be used for surround sound.
*



I don't see any relation between the two.
Defsac
QUOTE(Garf @ Jul 2 2005, 12:10 AM)
I don't see any relation between the two.
*


If you encode a Pro Logic 2 channel source with JS it can cause problems with the phase shifting that Pro Logic uses. There is a (fairly lousy) explanation here (note they also advocate the use of L+R over JS).
gbmallikarjunarao
Hi sebi,

very good explanation.

thanks alot.


Mallikarjun
Garf
QUOTE
If you encode a Pro Logic 2 channel source with JS it can cause problems with the phase shifting that Pro Logic uses. There is a (fairly lousy) explanation here (note they also advocate the use of L+R over JS).


That has got nothing to do with dual channel vs. LR.
Defsac
QUOTE(Garf @ Jul 2 2005, 12:16 AM)
That has got nothing to do with dual channel vs. LR.
*


L+R is worse for phase shifted audio than JS, because it discards almost all the phase related data of one channel and allocates all the bits to the other.
DC > JS > L+R

The only real world application where dual channel offers better quality over JS or L+R is with phase shifted audio, hence it is relevant.
Garf
QUOTE(Defsac @ Jul 1 2005, 04:20 PM)
QUOTE(Garf @ Jul 2 2005, 12:16 AM)
That has got nothing to do with dual channel vs. LR.
*


L+R is worse for phase shifted audio than JS, because it discards almost all the phase related data of one channel and allocates all the bits to the other.


I must be missing something but that makes absolutely zero sense to me. Channel bitrate allocation should be identical in such a case, making LR exactly equal to dual channel. M+S would probably be worst.

I also see absolutely no reason why in a L/R scenario the decoder can or would "discard allmost all the phase related data".
Defsac
QUOTE(Garf @ Jul 2 2005, 12:31 AM)
I must be missing something but that makes absolutely zero sense to me. Channel bitrate allocation should be identical in such a case, making LR exactly equal to dual channel. M+S would probably be worst.

I also see absolutely no reason why in a L/R scenario the decoder can or would "discard allmost all the phase related data".
*


Do you have a Pro Logic capable setup? If so, try compressing something using L+R, and the 5.1 output will be very odd indeed (if you really want I can simple blind test against DC, but it's so obvious that there's little point). I don't know the reason why this occours (perhaps Gabriel can enlighten us), but a quick Google for "dual channel mp3 phase" yields this and this.
Mark7
QUOTE(Defsac @ Jul 1 2005, 03:13 PM)
If you encode a Pro Logic 2 channel source with JS it can cause problems with the phase shifting that Pro Logic uses. There is a (fairly lousy) explanation here (note they also advocate the use of L+R over JS).


He uses TMPGEnc for encoding in that explanation. No wonder he gets bad results with JS
Garf
QUOTE(Defsac @ Jul 1 2005, 04:36 PM)
Do you have a Pro Logic capable setup? If so, try compressing something using L+R, and the 5.1 output will be very odd indeed (if you really want I can simple blind test against DC, but it's so obvious that there's little point). I don't know the reason why this occours (perhaps Gabriel can enlighten us), but a quick Google for "dual channel mp3 phase" yields this and this.
*



Sounds like a weird interaction, though I can't verify nor investigate it here. Thanks for the info.
SebastianG
QUOTE(Mark7 @ Jul 1 2005, 03:38 PM)
QUOTE(Defsac @ Jul 1 2005, 03:13 PM)
If you encode a Pro Logic 2 channel source with JS it can cause problems with the phase shifting that Pro Logic uses. There is a (fairly lousy) explanation here (note they also advocate the use of L+R over JS).


He uses TMPGEnc for encoding in that explanation. No wonder he gets bad results with JS
*



Also: This article is about MP2 -- not MP3. MP2's "joint-stereo" is intensity stereo only (no M/S coding).

Sebi
robert
QUOTE(Defsac @ Jul 1 2005, 04:08 PM)
QUOTE(loophole @ Jul 1 2005, 11:47 PM)
What's the difference between dual channel and L+R?
*


Dual channel should only be used for surround sound.
*


NO

dual channel is for bi-lingual encodings where you have to decide to hear the left channel (ie. frensh) or the right channel (ie. german)
The Windjammer
Hello everybody! I'm very sorry to bring up a topic that's more than a month old, but I would really like to ask something about dual channel and joint stereo sound files. I've recently came across this sound file:

http://8520.atw.hu/GinIroNoMichi.mp3 (you have to click on the link, Save target as... doesn't work with this server)

This is the number Gin Iro No Michi played by The Shadows, and if you check it out you will hear that the lead is on a separate channel, while the backin (rhythm, bass and drums) are on the other channel. I would really like to know how I can create such files, and which program should I use (I have GoldWave v5.10).

As far as I know this file has been ripped from the CD titled "The Very Best Of The Shadows" (I also own the original copy of this disk), and I'd like to ask how I can create a file like the one i posted above.

Thanks for your help in advance, kind regards

-The Windjammer
This is a "lo-fi" version of our main content. To view the full version with more information, formatting and images, please click here.
Invision Power Board © 2001-2008 Invision Power Services, Inc.