Mailing Lists: Apple Mailing Lists
Image of Mac OS face in stamp
Using AUAudioFilePlayer without its UI
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Using AUAudioFilePlayer without its UI



Hello,

I'm currently trying to create a program that plays back audio using an AUAudioFilePlayer
AudioUnit plugin that streams the audio to an output AudioUnit, inside an AUGraph.
I'm going to make the AUGraph more complex, by adding effects to it, that's why I use
this architecture.


This currently works when I use AUAudioFilePlayer's graphical user interface, but I haven't
found a way to add audio files to it and to control playback without this the UI.


The only documentation I have found about AUAudioFilePlayer are the comments in the
header "AudioUnitProperties.h" (--> lines 146 and 1144), but I'm not sure how to use this
properties:


I tried the following, which didn't work:

/* AudioUnit u is set to the AUAudioFilePlayer audio unit;
   AudioFileID f is set to the audio file. */

AudioUnitSetProperty( u,
kAudioUnitProperty_ScheduledFileIDs,
kAudioUnitScope_Global,
0,
a, /* Array containing one AudioFileID (--> AudioUnitProperties.h:148), I'm not sure if
I was supposed to pass an array of AudioFileID pointers or a CFArrayRef instead. */
sizeof(a) );


I was wondering if you could tell me how to control AUAudioFilePlayer without its GUI, or
where to find better documentation / example code about this.


Thanks,

Tim Lenertz
email@hidden

_______________________________________________
Do not post admin requests to the list. They will be ignored.
Coreaudio-api mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden




Visit the Apple Store online or at retail locations.
1-800-MY-APPLE

Contact Apple | Terms of Use | Privacy Policy

Copyright © 2011 Apple Inc. All rights reserved.