• Jump to DAW playback position

    Solved Scripting
    10
    0 Votes
    10 Posts
    328 Views
    Matt_SFM

    @ulrik Ok, I'm not completely useless then 😂

    It's the first time I'm using midi clips in a plugin so...
    Thank you again for your help, it's much appreciated !

  • Waveform how to get playback position?

    Unsolved Scripting
    6
    0 Votes
    6 Posts
    411 Views
    d.healeyD

    Still haven't found a solution to this one. Also it seems ScriptAudioWaveform.setPlaybackPosition() doesn't do anything, at least when it's connected to a sampler?

  • Engine.getPlayhead() functionality

    Feature Requests
    23
    1 Votes
    23 Posts
    928 Views
    Christoph HartC

    @Christoph-Hart found the culprit:

    // if this is non-zero it means that the buffer coming // from the DAW was split into chunks for processing // so we need to update the playhead to reflect the // "real" position for the given buffer if(offsetWithinProcessBuffer != 0) { newTime.timeInSamples += offsetWithinProcessBuffer; newTime.timeInSeconds += (double)offsetWithinProcessBuffer / processingSampleRate; const auto numSamplesPerQuarter = (double)TempoSyncer::getTempoInSamples(newTime.bpm, processingSampleRate, 1.0f); newTime.ppqPosition += (double)offsetWithinProcessBuffer / numSamplesPerQuarter; }