AkAudioStyle.h 2.2 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354
  1. /*******************************************************************************
  2. The content of this file includes portions of the proprietary AUDIOKINETIC Wwise
  3. Technology released in source code form as part of the game integration package.
  4. The content of this file may not be used without valid licenses to the
  5. AUDIOKINETIC Wwise Technology.
  6. Note that the use of the game engine is subject to the Unreal(R) Engine End User
  7. License Agreement at https://www.unrealengine.com/en-US/eula/unreal
  8. License Usage
  9. Licensees holding valid licenses to the AUDIOKINETIC Wwise Technology may use
  10. this file in accordance with the end user license agreement provided with the
  11. software or, alternatively, in accordance with the terms contained
  12. in a written agreement between you and Audiokinetic Inc.
  13. Copyright (c) 2023 Audiokinetic Inc.
  14. *******************************************************************************/
  15. #pragma once
  16. #include "WaapiPicker/WwiseTreeItem.h"
  17. #include "Materials/Material.h"
  18. #if WITH_EDITOR
  19. #include "Wwise/Ref/WwiseRefType.h"
  20. #endif
  21. /**
  22. * Implements the visual style of Wwise Browser.
  23. */
  24. class AKAUDIO_API FAkAudioStyle
  25. {
  26. public:
  27. static const ISlateStyle& Get();
  28. static void Initialize();
  29. static void Shutdown();
  30. static void DisplayEditorMessage(const FText& messageText, EWwiseItemType::Type wwiseItemType = EWwiseItemType::Type::None, float duration = 1.5f);
  31. static FName GetStyleSetName();
  32. static const FSlateBrush* GetWwiseIcon();
  33. static const FSlateBrush* GetBrush(EWwiseItemType::Type ItemType);
  34. #if WITH_EDITOR
  35. static const FSlateBrush* GetBrush(EWwiseRefType WwiseRefType);
  36. static const FSlateBrush* GetBrush(UClass* Class);
  37. #endif
  38. static const FSlateBrush* GetBrush(FName PropertyName, const ANSICHAR* Specifier = NULL);
  39. static const FSlateFontInfo GetFontStyle(FName PropertyName, const ANSICHAR* Specifier = NULL);
  40. static UMaterial* GetAkForegroundTextMaterial();
  41. /** returns a color from the WwiseUnrealColorPalette (taken from the dark theme in the Wwise Authoring tool). Use a colorIndex of -1 to use the 'default' color. */
  42. static FLinearColor GetWwiseObjectColor(int colorIndex);
  43. private:
  44. static TSharedPtr< class FSlateStyleSet > StyleInstance;
  45. static UMaterial* TextMaterial;
  46. };