/ VST Home / Technical Documentation

[3.7.0] Progress display

On this page:


Introduction

Extended host callback interface for an edit controller: Vst::IProgress.

Allows the plug-in to ask the host to create a progress for specific tasks which take some time. The host can visualize the progress as read-only UI elements. For example, after loading a project where a plug-in needs to load extra data (e.g. samples) in a background thread, this enables the host to get and visualize the current status of the loading progress and to inform the user when the loading is finished. Note: During the progress, the host can unload the plug-in at any time. Make sure that the plug-in supports this use case.

Examples

How to call it from the plug-in side

//--------------------------------------
// we are in the editcontroller:
// as member: IProgress::ID mProgressID;
  
if (auto progress = Steinberg::U::cast<IProgress> (componentHandler))
    progress->start (IProgress::ProgressType::UIBackgroundTask, STR ("Load Samples..."), mProgressID);
  
// ...
myProgressValue += incProgressStep;
if (auto progress = Steinberg::U::cast<IProgress> (componentHandler))
    progress->update (mProgressID, myProgressValue);
  
// ...
if (auto progress = Steinberg::U::cast<IProgress> (componentHandler))
    progress->finish (mProgressID);

VST 3 Plug-in Test Host integration of Vst::IProgress:

Tech_doc_35