Become a MacRumors Supporter for $50/year with no ads, ability to filter front page stories, and private forums.

Thethuthinang

macrumors member
Original poster
Jan 3, 2011
39
0
I am having trouble getting a project using AudioUnit.h to compile. I made a simple test project to try to locate the error. Here is the .h file:

Code:
#import <Cocoa/Cocoa.h>
#import <AudioUnit/AudioUnit.h>

@interface THController : NSObject {
	AudioComponentInstance x;
}

@end

I've added the AudioUnit framework. I get "syntax error before AudioComponentInstance". In my real project I get a lot of "undeclared . . ." messages as well. What's going on?
 
It seems I am using some old code. The variable AudioComponentInstance is contained in AudioComponent.h, which is not a part of the AudioUnit framework. Does anyone know about this?
 
Register on MacRumors! This sidebar will go away, and you'll see fewer ads.