OpenAL and OGG
OpenAL and OGG
- Subject: OpenAL and OGG
- From: Development <email@hidden>
- Date: Tue, 29 Jun 2010 15:18:22 -0700
Can open al not read ogg files? I'm attempting to load a short ogg clip and I keep getting random errors.
getOpenALAudioData: ExtAudioFileOpenURL FAILED, Error = 1954115647
2010-06-29 15:13:53.965 MixPad[12402:207] error attaching audio to buffer: a003
this is the file loading code, it is directly from an apple example
ALenum error = AL_NO_ERROR;
ALenum format;
ALsizei size;
ALsizei freq;
//NSBundle* bundle = [NSBundle mainBundle];
// get some audio data from a wave file
CFURLRef fileURL = (CFURLRef)[[NSURL fileURLWithPath:self.path] retain];
if (fileURL)
{
data = getOpenALAudioData(fileURL, &size, &format, &freq);
CFRelease(fileURL);
if((error = alGetError()) != AL_NO_ERROR) {
NSLog(@"error loading sound: %x\n", error);
exit(1);
}
// use the static buffer data API
alBufferDataStaticProc(self.alBufferID, format, data, size, freq);
NSLog(@"Format %i",format);
NSLog(@"Data %i",sizeof(data));
if((error = alGetError()) != AL_NO_ERROR) {
NSLog(@"error attaching audio to buffer: %x\n", error);
}
}
else
NSLog(@"Could not find file!\n");_______________________________________________
Cocoa-dev mailing list (email@hidden)
Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden