Wwise SDK 2021.1.14
_sink_devices_8h_source
Version
menu_open
link
SinkDevices.h
Go to the documentation of this file.
32 * Provides a list of up-to-date device IDs that can be used to instantiate a new Sound Engine sink.
48 * Allows your plug-in to provide a list of up-to-date device IDs that can be used to instantiate a new
51 * This plug-in interface cannot be linked to a backend or a frontend plug-in, it must be standalone.
69 using Instance = ak_wwise_plugin_sink_devices_instance_v1; ///< \copydoc ak_wwise_plugin_sink_devices_instance_v1
82 * Due to the unpredictable nature of hardware configuration changes, an unpadded, basic system would return
85 * As a plug-in designer, you are responsible to address this by returning adequate values that make sense as a whole.
87 * To guide you, Sink Devices interface is used for retrieval and data copy in a tight loop over a single thread
88 * at once. Host will retrieve the count, followed by the Name (GetName) and DeviceID (GetDeviceID), in the
89 * order the compiler sees fit. Data is expected to survive for the amount of time this tight loop exists.
102 * A proposal is to use GetCount to internally retrieve the device names and IDs, make a static internal
105 * You can also spawn an event listener or an update thread, and ensure the data is up to date when the calls
117 * Provided by your plug-in, this should return a const char* in UTF-8, valid at least until the next
128 const char*(*GetName)(const struct ak_wwise_plugin_sink_devices_instance_v1* in_this, int in_num);
133 * Provided by your plug-in, this should return a uint32_t that can be understood by the Sound Engine part of
134 * your sink plug-in. It must not return duplicates or pointers, and the value should be applicable to the
143 uint32_t(*GetDeviceID)(const struct ak_wwise_plugin_sink_devices_instance_v1* in_this, int in_num);
147 #define AK_WWISE_PLUGIN_SINK_DEVICES_V1_CTOR(/* ak_wwise_plugin_info* */ in_pluginInfo, /* void* */ in_data) \
149 .m_baseInterface = AK_WWISE_PLUGIN_BASE_INTERFACE_CTOR(AK_WWISE_PLUGIN_SINK_DEVICES_V1_ID(), in_pluginInfo, in_data) \
158 using CSinkDevices = ak_wwise_plugin_sink_devices_v1; ///< \copydoc ak_wwise_plugin_sink_devices_v1
163 * Allows your plug-in to provide a list of up-to-date device IDs that can be used to instantiate a new Sound
166 * This plug-in interface cannot be linked to a backend or a frontend plug-in, it must be standalone.
189 };
199 };
209 CSinkDevices::GetCount = [](const struct ak_wwise_plugin_sink_devices_instance_v1* in_this) { return static_cast<const Instance*>(in_this)->GetCount(); };
210 CSinkDevices::GetName = [](const struct ak_wwise_plugin_sink_devices_instance_v1* in_this, int in_num) { return static_cast<const Instance*>(in_this)->GetName(in_num); };
211 CSinkDevices::GetDeviceID = [](const struct ak_wwise_plugin_sink_devices_instance_v1* in_this, int in_num) { return static_cast<const Instance*>(in_this)->GetDeviceID(in_num); };
217 * \brief Get the static Interface object, as used internally in AK::Wwise::Plugin::PluginInfoGenerator.
226 * \brief Get the static Instance object, as used internally in AK::Wwise::Plugin::PluginInfoGenerator.
234 * \brief Get the static Instance object, as used internally in AK::Wwise::Plugin::PluginInfoGenerator.
253 * Due to the unpredictable nature of hardware configuration changes, an unpadded, basic system would return
256 * As a plug-in designer, you are responsible to address this by returning adequate values that make sense as a whole.
258 * To guide you, Sink Devices interface is used for retrieval and data copy in a tight loop over a single thread
259 * at once. Host will retrieve the count, followed by the Name (GetName) and DeviceID (GetDeviceID), in the
260 * order the compiler sees fit. Data is expected to survive for the amount of time this tight loop exists.
273 * A proposal is to use GetCount to internally retrieve the device names and IDs, make a static internal
276 * You can also spawn an event listener or an update thread, and ensure the data is up to date when the calls
287 * Provided by your plug-in, this should return a const char* in UTF-8, valid at least until the next
302 * Provided by your plug-in, this should return a uint32_t that can be understood by the Sound Engine part of
C++ API to provide device enumeration for sink plug-ins.
Definition: SinkDevices.h:173
ak_wwise_plugin_sink_devices_v1()
Definition: SinkDevices.h:71
int(* GetCount)(const struct ak_wwise_plugin_sink_devices_instance_v1 *in_this)
Get a count of the number of interfaces currently available.
Definition: SinkDevices.h:112
virtual int GetCount() const =0
Get a count of the number of interfaces currently available.
ak_wwise_plugin_sink_devices_v1 CSinkDevices
Device enumerator for sink plug-ins.
Definition: SinkDevices.h:158
decltype(BaseInterface::m_version) InterfaceVersion
PluginInfoGenerator: Type for the m_version value in BaseInterface.
Definition: PluginInfoGenerator.h:51
@ k_interfaceVersion
The interface version, as provided by this plug-in.
Definition: SinkDevices.h:198
@ AK_WWISE_PLUGIN_INTERFACE_TYPE_SINK_DEVICES
2021.1 Sink Devices enumeration plug-in. ak_wwise_plugin_sink_devices_v1
Definition: PluginBaseInterface.h:70
virtual ~SinkDevices()
Definition: SinkDevices.h:245
const CSinkDevices::Instance * GetInstancePointer() const
Definition: SinkDevices.h:236
Wwise Authoring Plug-ins - C++ class helper to automatically determine the plug-in interfaces used in...
The C interface, fulfilled by your plug-in.
Definition: SinkDevices.h:205
uint32_t(* GetDeviceID)(const struct ak_wwise_plugin_sink_devices_instance_v1 *in_this, int in_num)
Get a device ID for the device number in_num.
Definition: SinkDevices.h:143
Base instance type for providing a device list for your custom sink through ak_wwise_plugin_sink_devi...
Definition: PluginDef.h:896
std::underlying_type< InterfaceType >::type InterfaceTypeValue
PluginInfoGenerator: Underlying storage type for the m_interface value in BaseInterface.
Definition: PluginInfoGenerator.h:50
CSinkDevices::Instance * GetInstancePointer()
Definition: SinkDevices.h:228
AK_WWISE_PLUGIN_SPECIALIZE_INTERFACE_VERSION(AudioPlugin)
const char *(* GetName)(const struct ak_wwise_plugin_sink_devices_instance_v1 *in_this, int in_num)
Get a user-presentable name for the device number in_num.
Definition: SinkDevices.h:128
virtual const char * GetName(int in_num) const =0
Get a user-presentable name for the device number in_num.
Interface description and base class for every Wwise Authoring plug-in interface.
Definition: PluginBaseInterface.h:117
ak_wwise_plugin_sink_devices_instance_v1 Instance
Base instance type for providing a device list for your custom sink through ak_wwise_plugin_sink_devi...
Definition: SinkDevices.h:69
virtual uint32_t GetDeviceID(int in_num) const =0
Get a device ID for the device number in_num.
InterfacePtr GetInterfacePointer()
Definition: SinkDevices.h:219
V1::SinkDevices SinkDevices
Latest version of the C++ SinkDevices interface.
Definition: SinkDevices.h:318
AK_WWISE_PLUGIN_SPECIALIZE_INTERFACE_CLASS(AudioPlugin)
Definition: AudioPlugin.h:112
Was this page helpful?
Need Support?
Questions? Problems? Need more info? Contact us, and we can help!
Visit our Support pageTell us about your project. We're here to help.
Register your project and we'll help you get started with no strings attached!
Get started with Wwise