I'm trying to use alBufferDataStatic, mentioned in the WWDC 2008 Core Audio video on iTunes. And having trouble compiling it in.
I searched the lists, and found that "site:apple.com alBufferDataStatic" turns out to be a Googlewhack that points over to TN2199's advice to use the alBufferDataStatic function instead of alBufferStatic to eliminate a memcpy(). OK, great. I'm pretty sure that this isn't a dupe question.
Here's the thing. I've imported the header: #import <OpenAL/oalStaticBufferExtension.h>
But on the following line: //alBufferData (buffer[i], AL_FORMAT_STEREO16, data[i], alDataSize, alDataRate); alBufferDataStatic (buffer[i], AL_FORMAT_STEREO16, data[i], alDataSize, alDataRate);
I still get a compiler error: /Users/cadamson/dev/iphone throwaways/OpenALThrowaway5/Classes/OpenALThrowaway5ViewController.m:99: warning: implicit declaration of function 'alBufferDataStatic'
Looking at the header file, I don't quite know how to make sense of the declaration: typedef ALvoid AL_APIENTRY (*alBufferDataStaticProcPtr) (const ALint bid, ALenum format, ALvoid* data, ALsizei size, ALsizei freq);
Is there really a function here that I can use? What do I need to do to get my code to compile with it?
--Chris
|