Audacity 3.2.0
Public Member Functions | Static Public Member Functions | List of all members
AudacityVst3HostApplication Class Referencefinal

#include <AudacityVst3HostApplication.h>

Inheritance diagram for AudacityVst3HostApplication:
[legend]
Collaboration diagram for AudacityVst3HostApplication:
[legend]

Public Member Functions

DECLARE_FUNKNOWN_METHODS AudacityVst3HostApplication ()
 
virtual ~AudacityVst3HostApplication ()
 
Steinberg::tresult PLUGIN_API getName (Steinberg::Vst::String128 name) override
 
Steinberg::tresult PLUGIN_API createInstance (Steinberg::TUID cid, Steinberg::TUID _iid, void **obj) override
 
Steinberg::tresult PLUGIN_API isPlugInterfaceSupported (const Steinberg::TUID _iid) override
 

Static Public Member Functions

static IHostApplication & Get ()
 

Detailed Description

Definition at line 6 of file AudacityVst3HostApplication.h.

Constructor & Destructor Documentation

◆ AudacityVst3HostApplication()

DECLARE_FUNKNOWN_METHODS AudacityVst3HostApplication::AudacityVst3HostApplication ( )

◆ ~AudacityVst3HostApplication()

AudacityVst3HostApplication::~AudacityVst3HostApplication ( )
virtual

Definition at line 275 of file AudacityVst3HostApplication.cpp.

275{ FUNKNOWN_DTOR }

Member Function Documentation

◆ createInstance()

Steinberg::tresult PLUGIN_API AudacityVst3HostApplication::createInstance ( Steinberg::TUID  cid,
Steinberg::TUID  _iid,
void **  obj 
)
override

Definition at line 312 of file AudacityVst3HostApplication.cpp.

314{
315 using namespace Steinberg;
316
317 FUID classID(FUID::fromTUID(cid));
318 FUID interfaceID(FUID::fromTUID(_iid));
319 if (classID == Vst::IMessage::iid && interfaceID == Vst::IMessage::iid)
320 {
321 *obj = safenew AudacityHostMessage;
322 return kResultTrue;
323 }
324 else if (
325 classID == Vst::IAttributeList::iid &&
326 interfaceID == Vst::IAttributeList::iid)
327 {
329 return kResultTrue;
330 }
331 *obj = nullptr;
332 return kResultFalse;
333}
#define safenew
Definition: MemoryX.h:10

References safenew.

◆ Get()

Steinberg::Vst::IHostApplication & AudacityVst3HostApplication::Get ( )
static

Definition at line 277 of file AudacityVst3HostApplication.cpp.

278{
279 static AudacityVst3HostApplication instance;
280 return instance;
281}

Referenced by VST3EffectsModule::GetModule(), and VST3Wrapper::VST3Wrapper().

Here is the caller graph for this function:

◆ getName()

Steinberg::tresult PLUGIN_API AudacityVst3HostApplication::getName ( Steinberg::Vst::String128  name)
override

Definition at line 305 of file AudacityVst3HostApplication.cpp.

306{
307 return VST3::StringConvert::convert("Audacity VST3 host application", name) ?
308 Steinberg::kResultTrue :
309 Steinberg::kInternalError;
310}
wxString name
Definition: TagsEditor.cpp:166

References name.

◆ isPlugInterfaceSupported()

Steinberg::tresult AudacityVst3HostApplication::isPlugInterfaceSupported ( const Steinberg::TUID  _iid)
override

Definition at line 335 of file AudacityVst3HostApplication.cpp.

337{
338 static auto supportedInterfaces = {
339 Steinberg::Vst::IComponent::iid,
340 Steinberg::Vst::IAudioProcessor::iid,
341 Steinberg::Vst::IEditController::iid,
342 Steinberg::Vst::IConnectionPoint::iid,
343 Steinberg::Vst::IUnitInfo::iid
344 };
345
346 auto uid = Steinberg::FUID::fromTUID(_iid);
347 if (
348 std::find(supportedInterfaces.begin(), supportedInterfaces.end(), uid) !=
349 supportedInterfaces.end())
350 return Steinberg::kResultTrue;
351 return Steinberg::kResultFalse;
352}

The documentation for this class was generated from the following files: