VST / kVstTransportChanged

For some reason Juce does not use VstTimeInfo::kVstTransportChanged flag at all.

This is necessary to get proper song playback position without polling the position all the time.


I added these changes to Juce source code:


bool hasTransportChanged;


info.hasTransportChanged = (ti->flags & kVstTransportChanged) != 0;

Now it's easy to detect playback state change (play->stop, stop->play, playback position change) in the plugin by simply checking the hasTransportChanged flag.

. jussi

Thanks, but there's no point in adding a flag unless all the formats support it!

This would only be useful to people who are only targeting VST (i.e. very few people!). And even for them, the amount of effort it'd save is trivial. For everyone else, it'd just make the class more cluttered without actually helping, which is why I never added it before.

FWIW, you can get that in AU as well.

playchanged line 590


What would be the proper Juce way of detecting playback position change while playing?

- jussi