Re: My AUHAL Output Audio Unit
Re: My AUHAL Output Audio Unit
- Subject: Re: My AUHAL Output Audio Unit
- From: William Stewart <email@hidden>
- Date: Fri, 25 Jun 2004 14:52:22 -0700
Yes it sure does..
On 25/06/2004, at 11:28 AM, Robert Grant wrote:
>
Bill,
>
>
Sorry to hijack this thread - but it is related....
>
>
Airy and I are having a hard time getting the AUHAL to provide more
>
than two buffers on input regardless of the channelMap settings. Airy
>
(his Tascam has four input channels) and I (using the 16 channel
>
SoundFlower device) are getting only 2 channels/buffers returned from
>
AudioUnitRender and that's with completely separate implementations.
>
>
Can you confirm that > 2 channel input is working with the AUHAL?
>
>
Thanks,
>
>
Robert.
>
>
>
>
On Jun 25, 2004, at 2:09 PM, William Stewart wrote:
>
>
> The settings in the for loop are to -1 (that tells the underlying
>
> converter in the AUHAL that those channels are not used).
>
>
>
> Then following that you describe which channels of the device go into
>
> the channels that you will receive...
>
>
>
> In the example below you allocate a channel map that is as big as the
>
> number of channels you *get* from the device, set them first to -1,
>
> then after you describe for each channel of what you receive, which
>
> channel of the device you want.
>
>
>
> Thus, you are saying below that the first channel that you get, it
>
> will
>
> be the channel 2 of the device... The second channel you receive will
>
> be the channel 3 of the device.
>
>
>
> Bill
>
>
>
> On 24/06/2004, at 11:29 PM, Daniel Todd Currie wrote:
>
>
>
>> I've just finished implementing my AUHAL Output Audio Unit according
>
>> to the sample code and docs available here:
>
>>
>
>> http://developer.apple.com/technotes/tn2002/tn2091.html
>
>>
>
>> I run it and look at the buffer data that comes pouring into my app
>
>> and it is just a big long list of zeros. :(
>
>>
>
>> I have no idea where to begin troubleshooting, as the AU setup sample
>
>> code seems pretty thorough and I have checked for all of the
>
>> ComponentResult errors in my AudioUnitSetProperty calls. I was a bit
>
>> perplexed by one of the listings in the link above, so I wonder if it
>
>> could be the problem. The block of code from that page:
>
>>
>
>>> SInt32 *channelMap =NULL;
>
>>> UInt32 numOfChannels = DesiredFormat.mChannelsPerFrame; //2
>
>>> channels
>
>>> UInt32 mapSize = numOfChannels *sizeof(SInt32);
>
>>> channelMap = (SInt32 *)malloc(size);
>
>>>
>
>>> //for each channel of desired input, map the channel from
>
>>> //the device's output channel.
>
>>> for(UInt32 i=0;i<numOfChannels;i++)
>
>>> {
>
>>> channelMap[i]=-1;
>
>>> }
>
>>> //channelMap[desiredInputChannel] = deviceOutputChannel;
>
>>> channelMap[0] = 2;
>
>>> channelMap[1] = 3;
>
>>> AudioUnitSetProperty(InputUnit, kAudioOutputUnitProperty_ChannelMap,
>
>>> kAudioUnitScope_Output, 1, channelMap, size);
>
>>
>
>> Aside from what seems like a typo where "size" is used instead of
>
>> "mapSize", I don't understand why channelMap elements are set once in
>
>> the for loop, and then once again after the for loop. I implemented
>
>> the AU for my own needs as best I could from this example, but it
>
>> makes sense that if I were somehow mapping the channels incorrectly I
>
>> might get a bunch of silence. Can anyone shed a little light on the
>
>> snippet above?
>
>>
>
>> Thanks a million,
>
>>
>
>> -- Daniel Todd Currie
>
>> _______________________________________________
>
>> coreaudio-api mailing list | email@hidden
>
>> Help/Unsubscribe/Archives:
>
>> http://www.lists.apple.com/mailman/listinfo/coreaudio-api
>
>> Do not post admin requests to the list. They will be ignored.
>
>>
>
>>
>
> -- mailto:email@hidden
>
> tel: +1 408 974 4056
>
>
>
> ______________________________________________________________________
>
> __
>
> __
>
> Culture Ship Names:
>
> Ravished By The Sheer Implausibility Of That Last Statement [GSV]
>
> I said, I've Got A Big Stick [OU]
>
> Inappropiate Response [OU]
>
> Far Over The Borders Of Insanity And Still Accelerating [Eccentric]
>
> ______________________________________________________________________
>
> __
>
> __
>
> _______________________________________________
>
> coreaudio-api mailing list | email@hidden
>
> Help/Unsubscribe/Archives:
>
> http://www.lists.apple.com/mailman/listinfo/coreaudio-api
>
> Do not post admin requests to the list. They will be ignored.
>
_______________________________________________
>
coreaudio-api mailing list | email@hidden
>
Help/Unsubscribe/Archives:
>
http://www.lists.apple.com/mailman/listinfo/coreaudio-api
>
Do not post admin requests to the list. They will be ignored.
>
>
--
mailto:email@hidden
tel: +1 408 974 4056
________________________________________________________________________
__
Culture Ship Names:
Ravished By The Sheer Implausibility Of That Last Statement [GSV]
I said, I've Got A Big Stick [OU]
Inappropiate Response [OU]
Far Over The Borders Of Insanity And Still Accelerating [Eccentric]
________________________________________________________________________
__
_______________________________________________
coreaudio-api mailing list | email@hidden
Help/Unsubscribe/Archives:
http://www.lists.apple.com/mailman/listinfo/coreaudio-api
Do not post admin requests to the list. They will be ignored.