Mixing Mono Samples with Stereo Samples, Audio DSP using C# |
Mixing Mono Samples with Stereo Samples, Audio DSP using C# |
Apr 19 2012, 06:18
Post
#1
|
|
|
Group: Members Posts: 5 Joined: 19-April 12 Member No.: 98974 |
Hello,
I've got two streams of audio sample that are stored in arrays, one mono and one stereo. I'd like to mix the mono into the stereo stream and output as stereo. Any known examples to accomplish? Thanks in advance.........Mick |
|
|
|
![]() |
Apr 19 2012, 19:43
Post
#2
|
|
|
Group: Members Posts: 2137 Joined: 24-August 07 From: Silicon Valley Member No.: 46454 |
Mick,
Typically, a stereo mixer (hardware or software) will have (at least) two controls for each input. There is a level control, so if you are mixing A+B you can mix 30% of A with 70% of B, etc. The total does not have to add to 100%, because there is also a master level control, and if you are using floating-point there are essentially no limits. (You'd normally check/adjust the levels to prevent clipping before rendering to an integer format.) For mono sources there is also a panning control (AKA "pan pot"). The pan control determines "where" the sound is located, left-to right, by adjusting how much of this mono signal gets mixed-into the left channel, and how much gets mixed into the right channel. If you pan to the center (equal amounts in both channels), the level is normally reduced by 3dB, because otherwise the single-track mono volume level is doubled, since it's duplicated in both channels.* By default, you wouldn't use a pan-pot with stereo inputs, since the left-input normally goes to the left-output, and the right- input goes to the right-output. But, most mixers do allow you to pan the left & right stereo channels indpendently. So, you could move both channels to the left, or both to the right, or move them both to the middle, or criss-cross them, etc. You will notice that pan controls can take care of stereo-to-mono, or mono-to-stereo (of course you don't have true stereo if you have the same sound in both channels). * Not all pan pots follow this rule (there are different "pan laws"), and it's usually not that important, since you always have a level control to adjust the mono signal before mixing & panning. It does become important if you are moving the sound around during the track... i.e. If a speaker/singer starts-out on the left and moves across the "stage" to the right during the track/song. In that case, you don't want the voice to get louder in the "center". |
|
|
|
AltAudio Mixing Mono Samples with Stereo Samples Apr 19 2012, 06:18
pdq How about converting the mono to stereo (two ident... Apr 19 2012, 12:49
Speedskater Is this anything like M-S Stereo System? That... Apr 19 2012, 13:40
AltAudio How about converting the mono to stereo (two ident... Apr 19 2012, 15:32
db1989 It’s one of the simplest operations that can... Apr 19 2012, 16:08
AltAudio QUOTE (db1989 @ Apr 19 2012, 10:08) It’s ... Apr 19 2012, 16:41
db1989 QUOTE (AltAudio @ Apr 19 2012, 16:41) Ok,... Apr 19 2012, 17:35
AltAudio QUOTE (db1989 @ Apr 19 2012, 11:35) QUOTE... Apr 19 2012, 18:11
pdq Don't the stereo streams just contain alternat... Apr 19 2012, 17:25
pdq To create mono from stereo you would take pairs of... Apr 19 2012, 18:27
[JAZ] Could I ask which is your background? I don't ... Apr 19 2012, 19:26
AltAudio Ok thanks for the input. I am a .NET developer and... Apr 19 2012, 22:00
DVDdoug QUOTE I am a .NET developer and I've got an al... Apr 20 2012, 00:34![]() ![]() |
|
Lo-Fi Version | Time is now: 19th June 2013 - 04:20 |