Search code examples
ioscore-audio

Parameter for CoreAudio Converter NewTimePitch


According to documentation, there are kTimePitchParam_Rate and kTimePitchParam_Pitch to control. But I don't know if they are float or int, and what are there max and min

Audio Unit Parameters REF

Anybody know what values should I pass in?


Solution

  • The corect paramaters are:

    // Parameters for AUNewTimePitch
    enum {
          // Global, rate, 1/32 -> 32.0, 1.0
      kNewTimePitchParam_Rate                         = 0,
          // Global, Cents, -2400 -> 2400, 1.0
      kNewTimePitchParam_Pitch                        = 1,
          // Global, generic, 3.0 -> 32.0, 8.0
      kNewTimePitchParam_Overlap                      = 4,
          // Global, Boolean, 0->1, 1
      kNewTimePitchParam_EnablePeakLocking            = 6
    };