Navigation
API > API/Plugins > API/Plugins/TechAudioToolsMetaSound
Used for retrieving specific viewmodels from a MetaSoundViewModel, such as inputs or outputs. Simplifies the process of initializing MetaSound Literal Widgets by allowing the owning widget to call functions on entire containers of widgets that implement this interface, rather than painstakingly initializing each widget one-by-one.
Widgets implementing this interface are expected to provide an array of input names in order to request the required InputViewModels from the owning widget's MetaSoundViewModel. Then, the widget can implement SetInputViewModels to correctly assign each InputViewModel received.
To assign viewmodels, it is recommended to use either UMVVMView::SetViewModelByClass (if there aren't multiple viewmodels of the same class) or UMVVMView::SetViewModel (if there are multiple viewmodels of the same class). If using UMVVMView::SetViewModel, you must ensure the name of the viewmodel passed into the function matches the name of the corresponding viewmodel instance exactly or else the assignment will fail. It is recommended to expose a name variable to designers rather than hardcode a name value.
| Name | UMetaSoundLiteralWidgetInterface |
| Type | class |
| Header File | /Engine/Plugins/Experimental/TechAudioTools/Source/TechAudioToolsMetaSound/Public/Interfaces/MetaSoundLiteralInterface.h |
| Include Path | #include "Interfaces/MetaSoundLiteralInterface.h" |
Syntax
class UMetaSoundLiteralWidgetInterface : public UInterface
Inheritance Hierarchy
- UObjectBase → UObjectBaseUtility → UObject → UInterface → UMetaSoundLiteralWidgetInterface
See Also
- UMetaSoundLiteralWidget_Float for an example implementation.