[vlc-devel] Re: [MOD] Mac OSX multichannel patch
Matthew.Romaine at jp.sony.com
Mon Jun 7 11:16:10 CEST 2004
Hi Jean-Alexis and others,
I did a fairly thorough search for "HALAudioOutputUnit" on my system
but was not able to find what you mention. I couldn't find it in any
of the CoreAudio documentation either... where should I be looking?
What are VLC developer's thoughts on integrating OS-specific features?
While it's true using AudioUnits would make implementing many features
(such as filters, etc.) easier, if it's just support for multichannel
that is needed, then I think doing it directly with CoreAudio is best.
The original patch allowed selecting a different stream, which was nice
if there was a single stream to handle all channels. Unfortunately,
device manufacturers don't like to work together sometimes :) Thus,
there are some devices that require multiple streams being used at
As such, I'm not aware of any simple function that will return a list
of streams to accommodate a certain channel setting. For example, the
RME Hammerfall supports 18 channels, but all streams are mono (thus, 18
streams). If a user wants to output 5.1, I don't think there is a
function call that will return a pointer to just 6 mono streams.
Likewise, the MOTU 896 has stream 1 supporting 2 channels, and stream 2
supporting 8 channels. If a user wants to output 5.1, there are at
least two ways -- use the first two channels of stream 1 and 4 channels
from stream 2, or use 6 channels from the 8 in stream 2. Generally,
the latter approach is preferred in most scenarios since stream 1 is
usually the main outs, and oftentimes devices will mix down to the main
Like Jean-Alexis points out, VLC-OSX apparently doesn't allow a user to
change which channel-setup to use. My patch basically chose whatever
stream(s) held the most options. (actually, I was testing 5.1 and
forgot to un-comment the 8ch support; sorry). My thinking is that a
simple drop-down on the pane where it currently only says "Audio
Device: -1 (under preferences->modules->audio_output->coreaudio) would
be a nice for now. This would require obtaining a list of options from
the coreaudio.c audio_output module. I would be happy to create said
access function, but I'm not sure if the interface between the UI and
the module exists...
On 2004/06/04, at 19:03, Jean-Alexis Montignies wrote:
> Hi Matt (and all folks),
> I think I'm the last one to have patched coreaudio.c. I've just
> changed the code so that it works with other streams than the first
> one. In my idea, it was a quick patch.
> There is a right and easiest solution for making it work in all cases
> (at least for a single interface) and have the user being able to map
> the channels.
> It is to use the HALAudioOutputUnit of core audio which does all
> conversion/mapping/interleaving for you.
> Now, another problem of VLC is that it decides which kind of surround
> to use depending on the number of channels you have on the interface.
> So if you have a 20 channels interface, it could be lost or output to
> 8 channels, even if you have less speakers (let's say 4 or 5 for
> instance) connected.
> Any idea on where to select the surround setup.
> I've tried in the audio-channels menu, but my code just don't work for
> ouputs with more than 2 channels (even the left/right selection in the
> repository code doesn't work on more than stereo interfaces). Any
> ideas why?
> Jean-Alexis Montignies
This is the vlc-devel mailing-list, see http://www.videolan.org/vlc/
To unsubscribe, please read http://developers.videolan.org/lists.html
If you are in trouble, please contact <postmaster at videolan.org>
More information about the vlc-devel