WwiseSharedPlatformId.h 2.2 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869
  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 "Wwise/WwisePlatformId.h"
  17. #include "WwiseSharedPlatformId.generated.h"
  18. USTRUCT(BlueprintType)
  19. struct WWISERESOURCELOADER_API FWwiseSharedPlatformId
  20. {
  21. GENERATED_BODY()
  22. TSharedRef<FWwisePlatformId, ESPMode::ThreadSafe> Platform;
  23. FWwiseSharedPlatformId() :
  24. Platform(new FWwisePlatformId)
  25. {}
  26. FWwiseSharedPlatformId(const FGuid& InPlatformGuid, const FName& InPlatformName) :
  27. Platform(new FWwisePlatformId(InPlatformGuid, InPlatformName))
  28. {}
  29. #if WITH_EDITORONLY_DATA
  30. FWwiseSharedPlatformId(const FGuid& InPlatformGuid, const FName& InPlatformName, const FName& InRelativePath) :
  31. Platform(new FWwisePlatformId(InPlatformGuid, InPlatformName, InRelativePath))
  32. {}
  33. #endif
  34. const FGuid& GetPlatformGuid() const
  35. {
  36. return Platform->PlatformGuid;
  37. }
  38. const FName& GetPlatformName() const
  39. {
  40. return Platform->PlatformName;
  41. }
  42. bool operator==(const FWwiseSharedPlatformId& Rhs) const
  43. {
  44. return Platform->PlatformGuid == Rhs.Platform->PlatformGuid;
  45. }
  46. bool operator!=(const FWwiseSharedPlatformId& Rhs) const
  47. {
  48. return Platform->PlatformGuid != Rhs.Platform->PlatformGuid;
  49. }
  50. };
  51. inline uint32 GetTypeHash(const FWwiseSharedPlatformId& Id)
  52. {
  53. return GetTypeHash(Id.Platform->PlatformGuid);
  54. }