Compiling Problem with AudioUnit Framework

Discussion in 'Mac Programming' started by Thethuthinang, May 3, 2012.

  1. Thethuthinang macrumors member

    Jan 3, 2011
    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:

    #import <Cocoa/Cocoa.h>
    #import <AudioUnit/AudioUnit.h>
    @interface THController : NSObject {
    	AudioComponentInstance x;
    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?
  2. Thethuthinang thread starter macrumors member

    Jan 3, 2011
    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?

Share This Page