[vlc-devel] Re: your vlc audio patch

Matthew Romaine Matthew.Romaine at jp.sony.com
Fri Jun 25 04:21:46 CEST 2004


Mark (and other OSX developers),

	Any chance you will be attending WWDC next week?  If you're still 
having debug problems, there might be a chance to flush them out over 
coffee.

	Cool chip, btw.

matt


On 2004/06/24, at 22:58, Mark Wells wrote:

> Matt,
>
> Thanks for your reply, it helps to explain my situation pretty well. 
> So if I isolate a specific audio format (eg 6-channel) by 
> commenting-out all the other support (except mono) then the AC3 stream 
> plays perfectly. I *think* that once specific format selection works 
> (ie once the menus successfully allow you to change between stereo, 
> 5.1, 7.1 etc) then this problem will disappear.
>
> To answer your question, I'm testing using one of our own devices, the 
> OXFW970 (http://www.oxsemi.com/press/jan04/index2.html).
>
> An update so far, for anyone interested.....
>
> I notice that in ChannelsToAoutVar there is a 5-channel support option 
> (3 Front 2 Rear) however there is no initial 5 channel PCM support 
> available to complement this! So I have added this, and opened the 
> correct physical channels. The channel allocation seems to be all 
> wrong tho, as main audio comes out of channel 1 (front left). 2&3 and 
> 4&5 are the stereo pairs, but I havent figured out which pair is 
> front/surround yet.
>
> Further, if I play 5-channel content in a 6-channel environment then 
> channel 4 is empty, channel 5 plays what was in channel 4, and channel 
> 6 plays what was in channel 5 (compared with the 5-channel 
> environment). Playing 5-channel content in an 8-channel environment 
> reverts back to the configuration in the 5-channel environment, but 
> duplicates channels 1-3 on 6-8. Channel-duplication is annoying but 
> tolerable. However channel-switching is not tolerable! im working on 
> it!
>
>
> Mark
>
>
> On 23 Jun 2004, at 03:37, Matthew Romaine wrote:
>
>>
>> Mark,
>>
>> Sorry for the late response; I was away from my desk for the past 
>> couple days.
>>
>> AC3 has not been tested because it was special cased in the original 
>> module and I don't have source material to test it out yet.
>>
>> i've only tested my patch on two devices - RME Hammerfall, which 
>> deinterleaves multichannel streams, and MOTU 896, which uses single 
>> interleaved streams.  Combinations of the two (interleaved and 
>> deinterleaved) should also be possible but is untested :)
>>
>> as for the error, without looking at the code i think I put in that 
>> error message to indicate when a different physical format had to be 
>> chosen but a corresponding channel count wasn't found.  In other 
>> words, some devices allow for multiple formats under a single stream 
>> - i.e. "Stream 1" could have two physical formats, one that handles 4 
>> channels at 44.1 and another that handles 2 channels at 96.  Due to 
>> deinterleaved-implementation constraints (and time :), the code 
>> currently only allows a change in sampling rate, so will basically 
>> fail if a different physical format in the same stream can not also 
>> handle the same number of desired channels.  I *think* that's the 
>> error you're getting.
>>
>> try debugging in extra verbose mode and you should get a clear sense 
>> of the possible stream combinations of your device.  what device are 
>> you using?
>>
>> if all else fails, follow the Xine model :)
>>
>> hth,
>> matt
>>
>>
>> On 2004/06/22, at 18:41, Mark Wells wrote:
>>
>>> Matt
>>>
>>> Firstly, if you dont have the time to answer this, dont worry i'm 
>>> sure I'll figure it out. I just thought it was worth asking incase 
>>> you can put your finger straight on it. Im trying to figure out what 
>>> capabilities your patch provides, and therefore what the priorities 
>>> are for continuing where you left off.
>>>
>>> As far as I am aware from reading up on the vlc-devel list (correct 
>>> me if im wrong) your patch should provide successful multichannel 
>>> support for OS X. The only thing it doesnt do is let you choose how 
>>> many channels you want to use (ie it always uses the most channels 
>>> it can find). Right (in theory) ?
>>>
>>> I'm testing using an 8-channel audio device (yes, i've uncommented 
>>> the 8-channel support) and an ac3 audio stream. When I load the 
>>> stream I get the error "Something is wrong with the physical format 
>>> indexing i[0] j[2] fmt_idx[5]" I have also tried 6-channel instead, 
>>> but get the same error. Having looked at my input stream it seems to 
>>> be a single stream (therefore interleaved) with 9 formats.
>>>
>>> I guess all I'm asking is this: were you/others getting this error 
>>> (ie is this something I need to patch up before addressing the 
>>> problem of selecting how many channels to use) or is this error new 
>>> news to you?
>>>
>>> Many thanks
>>>
>>> Mark
>>>
>>> ----------------------------------
>>> Mark Wells
>>> Oxford Semiconductor Ltd
>>> 25 Milton Park, Abingdon, OX14 4SH, UK
>>>
>>>
>>>
>>> On 15 Jun 2004, at 10:40, Matthew Romaine wrote:
>>>
>>>>
>>>> Mark,
>>>>
>>>> 	Just a quick tip, but be sure to go back over the past couple 
>>>> references to multichannel audio on OSX on the mailing list.  
>>>> There's a patch I sent out that should work for all devices now 
>>>> that interleaved and de-interleaved streams are supported, but it 
>>>> won't let you choose which option to use.  It should be a trivial 
>>>> fix, but my hands are currently tied.  I've also commented the code 
>>>> heavily so anyone should be able to follow.
>>>>
>>>> But if you're really gonna fix it up, be sure to look up references 
>>>> to AUHAL throughout the list to get it done right :)
>>>>
>>>> matt
>>>> ----------------------------------------
>>>> Matthew M.I. Romaine
>>>> IMNC Audio Codec Group
>>>> Sony Corporation
>>>> phone: 03-5448-6065
>>>> fax: 03-5448-5617
>>>> ----------------------------------------
>>>>
>>>> -- 
>>>> 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>
>>>>
>>>>
>>>
>>>
>>>
>> ----------------------------------------
>> Matthew M.I. Romaine
>> IMNC Audio Codec Group
>> Sony Corporation
>> phone: 03-5448-6065
>> fax: 03-5448-5617
>> ----------------------------------------
>>
>>
> ----------------------------------
> Mark Wells
> Oxford Semiconductor Ltd
> 25 Milton Park, Abingdon, OX14 4SH, UK
>
>
>
----------------------------------------
Matthew M.I. Romaine
IMNC Audio Codec Group
Sony Corporation
phone: 03-5448-6065
fax: 03-5448-5617
----------------------------------------

-- 
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 mailing list