CurrentPositionInfo in AudioUnits?


#1

I’m having a strange issue with AudioPlayHead::CurrentPositionInfo in my AU plugins. It doesn’t seem to be picking up the BPM at all? From what I can tell only timeInSeconds and timeInSamples are returning the correct information. I’ve no problems with VST interfaces. Is there something I’m missing here? I’ve checked the JUCE demo. It works fine of course. I can’t see what I might be doing differently. This is how I’m accessing the information.

    if (AudioPlayHead* const ph = getPlayHead())
    {
        AudioPlayHead::CurrentPositionInfo hostInfo;
        
        if (ph->getCurrentPosition (hostInfo))
        {
            /*
            DBG(String(hostInfo.bpm));
            DBG(String(hostInfo.timeInSeconds));
            DBG(String(hostInfo.isPlaying));
            DBG(String(hostInfo.isRecording));
            DBG(String(hostInfo.ppqPosition));
            DBG(String(hostInfo.timeInSamples));
            DBG(String(hostInfo.timeSigDenominator));
            DBG(String(hostInfo.timeSigNumerator));
            */
        }
    }

#2

Crisis over. I finally remembered to trash the Audiounit cache and hey presto, it works :stuck_out_tongue_winking_eye: