Wwise SDK 2021.1.14
版本
menu_open
link
HostObjectStore.h
Go to the documentation of this file.
41 * The Object Store contains named lists, and those named lists each contains a vector of inner property sets.
43 * For example, you can create a list named "Property curve points" and have 12 inner property sets with coordinates,
46 * Inner property sets can be created from any inner types, as defined in the plug-in's XML definition file
47 * <code>InnerTypes</code> section. Your lists should contain recognizable types, as there is no way to poll the
48 * type of the created object. This system was created with a one-list-one-type design pattern; however, there is
51 * You can define as many named lists as required. You should consider creating different inner property sets or
54 * You can create new inner property set with \ref CreatePropertySet, and insert it in a list's index with
57 * You can also subscribe to notifications through ak_wwise_plugin_notifications_object_store_v1 in order to be
61 * In order to manage property sets, you must make sure to use \ref AK::Wwise::Plugin::RequestPropertySet in
67 * since we are talking about property sets, the naming has been standardized to "inner property set".
99 * <code>in_uiIndex</code> position, so it will be stored in the project data. Existing object positions
102 * Named lists are created automatically, there is no limitation for naming. However, you should use the
122 * \param[in] in_pszListName Name of the affected list. That list will be created or appended depending
124 * \param[in] in_uiIndex Inner property set index in the list. If higher than or equal to the current
127 * \param[in] in_pPropertySet The inner property set to include in the list's index. This property set
140 * This is useful if you still need the object internally, or if you want to move that object to another
145 * The function \ref DeletePropertySet must be used if you still keep that reference without being
153 * \param[in] in_pPropertySet The inner property set to remove from any list's index. The object is not
174 * \param[in] in_pszListName Name of the polled list. If the list doesn't exist, the function will
176 * \param[in] in_uiIndex Inner property set index in the list. If higher than or equal to the current
192 * \param[in] in_pszListName Name of the polled list. If the list doesn't exist, the function will
204 * An inner property set must be defined as a particular <code>InnerType</code> in the plug-in's XML
217 * \param[in] in_pszType The requested InnerType, as defined in the plug-in's XML definition file.
228 * It will also remove the object from its list if the object has been inserted. As such, you are not
262 * If you do not provide a buffer big enough to write the full string, the function will fail and
270 * \param[in] in_uiBufferSize Size of the provided buffer. If the buffer is not big enough for the
288 * In order to manage property sets, you must make sure to use \ref AK::Wwise::Plugin::RequestPropertySet in
366 AK_WWISE_PLUGIN_BASE_INTERFACE_FROM_ID(AK_WWISE_PLUGIN_INTERFACE_TYPE_NOTIFICATIONS_OBJECT_STORE, 1)
367 #define AK_WWISE_PLUGIN_NOTIFICATIONS_OBJECT_STORE_V1_CTOR(/* ak_wwise_plugin_info* */ in_pluginInfo, /* void* */ in_data) \
369 .m_baseInterface = AK_WWISE_PLUGIN_BASE_INTERFACE_CTOR(AK_WWISE_PLUGIN_NOTIFICATIONS_OBJECT_STORE_V1_ID(), in_pluginInfo, in_data) \
395 };
405 };
412 * <code>in_uiIndex</code> position, so it will be stored in the project data. Existing object positions
415 * Named lists are created automatically, there is no limitation for naming. However, you should use the
434 * \param[in] in_pszListName Name of the affected list. That list will be created or appended depending
436 * \param[in] in_uiIndex Inner property set index in the list. If higher than or equal to the current
439 * \param[in] in_propertySet The inner property set to include in the list's index. This property set
454 * This is useful if you still need the object internally, or if you want to move that object to another
459 * The function \ref DeletePropertySet must be used if you still keep that reference without being
466 * \param[in] in_propertySet The inner property set to remove from any list's index. The object is not
488 * \param[in] in_pszListName Name of the polled list. If the list doesn't exist, the function will
490 * \param[in] in_uiIndex Inner property set index in the list. If higher than or equal to the current
499 return static_cast<PropertySet*>(g_cinterface->GetPropertySet(this, in_pszListName, in_uiIndex));
507 * \param[in] in_pszListName Name of the polled list. If the list doesn't exist, the function will
521 * An inner property set must be defined as a particular <code>InnerType</code> in the plug-in's XML
533 * \param[in] in_pszType The requested InnerType, as defined in the plug-in's XML definition file.
546 * It will also remove the object from its list if the object has been inserted. As such, you are not
582 * If you do not provide a buffer big enough to write the full string, the function will fail and
589 * \param[in] in_uiBufferSize Size of the provided buffer. If the buffer is not big enough for the
626 };
636 };
732 * Deriving your plug-in class from RequestObjectStore will automatically request both ObjectStore and
733 * Notifications::ObjectStore_ interfaces. From this point, you will be able to derive from the virtual
734 * functions, as defined in Notifications::ObjectStore_, and access the host-provided functions in the
756 AK_WWISE_PLUGIN_SPECIALIZE_HOST_INTERFACE(ObjectStore, objectStore,, public Notifications::ObjectStore);
Custom inner property set interface.
Definition: HostObjectStore.h:80
ak_wwise_plugin_notifications_object_store_v1 CObjectStore_
Definition: HostObjectStore.h:606
CObjectStore_::Instance * GetInstancePointer()
Definition: HostObjectStore.h:675
@ k_interfaceType
The interface type, as requested by this plug-in.
Definition: HostObjectStore.h:394
unsigned int GetPropertySetCount(const char *in_pszListName) const
Gets the number of inserted indexes inside the specified list.
Definition: HostObjectStore.h:511
Interface()
Definition: HostObjectStore.h:644
static GluedInterface * g_cinterface
The unique instance of the CInterface interface. Defined at nullptr first, overridden by the Host onc...
Definition: PluginInfoGenerator.h:90
decltype(BaseInterface::m_version) InterfaceVersion
PluginInfoGenerator: Type for the m_version value in BaseInterface.
Definition: PluginInfoGenerator.h:51
unsigned int GetListName(unsigned int in_uiListIndex, char *out_pszListName, unsigned int in_uiBufferSize) const
Gets the name of the list at the specified position.
Definition: HostObjectStore.h:594
Custom inner property set interface.
Definition: HostObjectStore.h:382
unsigned int(* GetListName)(const struct ak_wwise_plugin_host_object_store_instance_v1 *in_this, unsigned int in_uiListIndex, char *out_pszListName, unsigned int in_uiBufferSize)
Gets the name of the list at the specified position.
Definition: HostObjectStore.h:275
ak_wwise_plugin_host_object_store_v1 CHostObjectStore
Definition: HostObjectStore.h:378
V1::Notifications::ObjectStore_ ObjectStore
Latest version of the C++ ObjectStore notification interface.
Definition: HostObjectStore.h:753
Wwise Authoring Plug-ins - Plug-in API for property sets.
@ k_interfaceVersion
The interface version, as provided by this plug-in.
Definition: HostObjectStore.h:635
NotifyInnerObjectOperation
Type of operation for the NotifyInnerObjectAddedRemoved function.
Definition: PluginDef.h:78
ObjectStore_()
Definition: HostObjectStore.h:682
virtual void NotifyInnerObjectAddedRemoved(PropertySet &in_PSet, unsigned int in_uiIndex, NotifyInnerObjectOperation in_eOperation)
Called when an inner property set has changed.
Definition: HostObjectStore.h:721
@ AK_WWISE_PLUGIN_INTERFACE_TYPE_HOST_OBJECT_STORE
2021.1 Object Store host service. ak_wwise_plugin_host_object_store_v1
Definition: PluginBaseInterface.h:80
unsigned int(* GetPropertySetCount)(const struct ak_wwise_plugin_host_object_store_instance_v1 *in_this, const char *in_pszListName)
Gets the number of inserted indexes inside the specified list.
Definition: HostObjectStore.h:196
void InsertPropertySet(const char *in_pszListName, unsigned int in_uiIndex, const PropertySet &in_propertySet)
Inserts an inner property set into the specified list at the specified position.
Definition: HostObjectStore.h:442
ak_wwise_plugin_notifications_object_store_v1()
Definition: HostObjectStore.h:309
virtual void NotifyInnerObjectPropertyChanged(PropertySet &in_PSet, const GUID &in_guidPlatform, const char *in_pszPropertyName)
Called when an inner property set's data has changed.
Definition: HostObjectStore.h:702
bool RemovePropertySet(const PropertySet &in_propertySet)
Removes an inner property set from any list, without deleting the object itself.
Definition: HostObjectStore.h:470
void(* NotifyInnerObjectAddedRemoved)(struct ak_wwise_plugin_notifications_object_store_instance_v1 *in_this, struct ak_wwise_plugin_host_property_set_instance_v1 *in_pPSet, unsigned int in_uiIndex, AK::Wwise::Plugin::NotifyInnerObjectOperation in_eOperation)
Called when an inner property set has changed.
Definition: HostObjectStore.h:349
RequestedHostInterface< ObjectStore > RequestObjectStore
Requests an ObjectStore interface, provided as m_objectStore variable.
Definition: HostObjectStore.h:737
PluginInfoGenerator: Associates an existing C Interface with a variable that can be used....
Definition: PluginInfoGenerator.h:105
void DeletePropertySet(PropertySet *in_pPropertySet)
Frees the inner property set.
Definition: HostObjectStore.h:558
Interface able to receive notifications for custom inner property sets.
Definition: HostObjectStore.h:610
ak_wwise_plugin_notifications_object_store_instance_v1 Instance
Base instance type for receiving notifications on related Object Store's changes.
Definition: HostObjectStore.h:307
struct ak_wwise_plugin_host_property_set_instance_v1 *(* GetPropertySet)(const struct ak_wwise_plugin_host_object_store_instance_v1 *in_this, const char *in_pszListName, unsigned int in_uiIndex)
Gets an inner property set inside the specified list at the specified position.
Definition: HostObjectStore.h:180
PropertySet * CreatePropertySet(const char *in_pszType)
Creates a new inner property set.
Definition: HostObjectStore.h:536
Base instance type for receiving notifications on related Object Store's changes.
Definition: PluginDef.h:833
struct ak_wwise_plugin_host_property_set_instance_v1 *(* CreatePropertySet)(struct ak_wwise_plugin_host_object_store_instance_v1 *in_this, const char *in_pszType)
Creates a new inner property set.
Definition: HostObjectStore.h:220
std::underlying_type< InterfaceType >::type InterfaceTypeValue
PluginInfoGenerator: Underlying storage type for the m_interface value in BaseInterface.
Definition: PluginInfoGenerator.h:50
@ k_interfaceVersion
The interface version, as requested by this plug-in.
Definition: HostObjectStore.h:404
Interface able to receive notifications for custom inner property sets.
Definition: HostObjectStore.h:300
void(* NotifyInnerObjectPropertyChanged)(struct ak_wwise_plugin_notifications_object_store_instance_v1 *in_this, struct ak_wwise_plugin_host_property_set_instance_v1 *in_pPSet, const GUID *in_guidPlatform, const char *in_pszPropertyName)
Called when an inner property set's data has changed.
Definition: HostObjectStore.h:328
ak_wwise_plugin_host_object_store_v1()
Definition: HostObjectStore.h:89
Interface used to interact with property sets.
Definition: HostPropertySet.h:1053
AK_WWISE_PLUGIN_SPECIALIZE_INTERFACE_VERSION(AudioPlugin)
PropertySet * GetPropertySet(const char *in_pszListName, unsigned int in_uiIndex) const
Gets an inner property set inside the specified list at the specified position.
Definition: HostObjectStore.h:494
bool(* RemovePropertySet)(struct ak_wwise_plugin_host_object_store_instance_v1 *in_this, const struct ak_wwise_plugin_host_property_set_instance_v1 *in_pPropertySet)
Removes an inner property set from any list, without deleting the object itself.
Definition: HostObjectStore.h:157
Interface description and base class for every Wwise Authoring plug-in interface.
Definition: PluginBaseInterface.h:117
The C interface, fulfilled by your plug-in.
Definition: HostObjectStore.h:642
unsigned int(* GetListCount)(const struct ak_wwise_plugin_host_object_store_instance_v1 *in_this)
Returns the number of inner property set lists to be used with GetListName.
Definition: HostObjectStore.h:252
@ k_interfaceType
The interface type, as provided by this plug-in.
Definition: HostObjectStore.h:625
virtual ~ObjectStore_()
Definition: HostObjectStore.h:687
unsigned int GetListCount() const
Returns the number of inner property set lists to be used with GetListName.
Definition: HostObjectStore.h:570
Base host-provided instance type for ak_wwise_plugin_host_property_set_v1.
Definition: PluginDef.h:644
Base host-provided instance type for ak_wwise_plugin_host_object_store_v1.
Definition: PluginDef.h:635
void(* InsertPropertySet)(struct ak_wwise_plugin_host_object_store_instance_v1 *in_this, const char *in_pszListName, unsigned int in_uiIndex, const struct ak_wwise_plugin_host_property_set_instance_v1 *in_pPropertySet)
Inserts an inner property set into the specified list at the specified position.
Definition: HostObjectStore.h:130
@ AK_WWISE_PLUGIN_INTERFACE_TYPE_NOTIFICATIONS_OBJECT_STORE
2021.1 Object Store modification notification. ak_wwise_plugin_notifications_object_store_v1
Definition: PluginBaseInterface.h:67
#define AK_WWISE_PLUGIN_SPECIALIZE_HOST_INTERFACE(in_name, in_varname,...)
PluginInfoGenerator: Creates a C++ host specialization for interface class specified in in_name,...
Definition: PluginInfoGenerator.h:238
void(* DeletePropertySet)(struct ak_wwise_plugin_host_object_store_instance_v1 *in_this, struct ak_wwise_plugin_host_property_set_instance_v1 *in_pPropertySet)
Frees the inner property set.
Definition: HostObjectStore.h:241
AK_WWISE_PLUGIN_SPECIALIZE_INTERFACE_CLASS(AudioPlugin)
Definition: PluginHelpers.h:46
Definition: AudioPlugin.h:112
const CObjectStore_::Instance * GetInstancePointer() const
Definition: HostObjectStore.h:678
InterfacePtr GetInterfacePointer()
Definition: HostObjectStore.h:671