Files
UnrealEngineUWP/Engine/Source/Runtime/AVEncoder/Private/Microsoft/AVEncoderMicrosoftCommon.cpp
ryan durand 0f0464a30e Updating copyright for Engine Runtime.
#rnx
#rb none


#ROBOMERGE-OWNER: ryan.durand
#ROBOMERGE-AUTHOR: ryan.durand
#ROBOMERGE-SOURCE: CL 10869210 via CL 10869511 via CL 10869900
#ROBOMERGE-BOT: (v613-10869866)

[CL 10870549 by ryan durand in Main branch]
2019-12-26 14:45:42 -05:00

46 lines
885 B
C++

// Copyright Epic Games, Inc. All Rights Reserved.
#include "AVEncoderMicrosoftCommon.h"
#if PLATFORM_WINDOWS || PLATFORM_XBOXONE
#if WMFMEDIA_SUPPORTED_PLATFORM
#pragma comment(lib, "mfplat")
#pragma comment(lib, "mfuuid")
#pragma comment(lib, "Mfreadwrite")
#endif
namespace AVEncoder
{
//
// Windows only code
//
#if PLATFORM_WINDOWS
ID3D11Device* GetUE4DxDevice()
{
auto Device = static_cast<ID3D11Device*>(GDynamicRHI->RHIGetNativeDevice());
checkf(Device != nullptr, TEXT("Failed to get UE4's ID3D11Device"));
return Device;
}
#endif
//
// XboxOne only code
//
#if PLATFORM_XBOXONE
ID3D12Device* GetUE4DxDevice()
{
auto Device = static_cast<ID3D12Device*>(GDynamicRHI->RHIGetNativeDevice());
checkf(Device != nullptr, TEXT("Failed to get UE4's ID3D12Device"));
return Device;
}
#endif
} // namespace AVEncoder
#endif // PLATFORM_WINDOWS || PLATFORM_XBOXONE