summaryrefslogtreecommitdiffstats
path: root/Graphics/GraphicsEngineMetal
diff options
context:
space:
mode:
authorassiduous <assiduous@diligentgraphics.com>2020-02-03 18:37:34 +0000
committerassiduous <assiduous@diligentgraphics.com>2020-02-03 18:37:34 +0000
commita8143c85fec240e0fdb17db731f8e06a0d0f48c3 (patch)
tree7c4f03824373f951460f206bf9719c6c12bda7db /Graphics/GraphicsEngineMetal
parentFixed yet another linux build issue (diff)
downloadDiligentCore-a8143c85fec240e0fdb17db731f8e06a0d0f48c3.tar.gz
DiligentCore-a8143c85fec240e0fdb17db731f8e06a0d0f48c3.zip
Updated Mac and iOS native window structs
Diffstat (limited to 'Graphics/GraphicsEngineMetal')
-rw-r--r--Graphics/GraphicsEngineMetal/include/SwapChainMtlImpl.h2
-rw-r--r--Graphics/GraphicsEngineMetal/interface/EngineFactoryMtl.h2
-rw-r--r--Graphics/GraphicsEngineMetal/src/EngineFactoryMtl.mm22
-rw-r--r--Graphics/GraphicsEngineMetal/src/SwapChainMtlImpl.mm2
4 files changed, 14 insertions, 14 deletions
diff --git a/Graphics/GraphicsEngineMetal/include/SwapChainMtlImpl.h b/Graphics/GraphicsEngineMetal/include/SwapChainMtlImpl.h
index 0654f2a7..a868dd32 100644
--- a/Graphics/GraphicsEngineMetal/include/SwapChainMtlImpl.h
+++ b/Graphics/GraphicsEngineMetal/include/SwapChainMtlImpl.h
@@ -42,7 +42,7 @@ public:
const SwapChainDesc& SCDesc,
class RenderDeviceMtlImpl* pRenderDeviceMtl,
class DeviceContextMtlImpl* pDeviceContextMtl,
- void* pView);
+ const NativeWindow& Window);
~SwapChainMtlImpl();
virtual void QueryInterface(const Diligent::INTERFACE_ID& IID, IObject** ppInterface) override final;
diff --git a/Graphics/GraphicsEngineMetal/interface/EngineFactoryMtl.h b/Graphics/GraphicsEngineMetal/interface/EngineFactoryMtl.h
index 7509f082..996b01a4 100644
--- a/Graphics/GraphicsEngineMetal/interface/EngineFactoryMtl.h
+++ b/Graphics/GraphicsEngineMetal/interface/EngineFactoryMtl.h
@@ -53,7 +53,7 @@ public:
virtual void CreateSwapChainMtl(IRenderDevice* pDevice,
IDeviceContext* pImmediateContext,
const SwapChainDesc& SCDesc,
- void* pView,
+ const NativeWindow& Window,
ISwapChain** ppSwapChain) = 0;
virtual void AttachToMtlDevice(void* pMtlNativeDevice,
diff --git a/Graphics/GraphicsEngineMetal/src/EngineFactoryMtl.mm b/Graphics/GraphicsEngineMetal/src/EngineFactoryMtl.mm
index a845f121..3425c849 100644
--- a/Graphics/GraphicsEngineMetal/src/EngineFactoryMtl.mm
+++ b/Graphics/GraphicsEngineMetal/src/EngineFactoryMtl.mm
@@ -54,11 +54,11 @@ public:
IRenderDevice** ppDevice,
IDeviceContext** ppContexts)override final;
- void CreateSwapChainMtl( IRenderDevice* pDevice,
- IDeviceContext* pImmediateContext,
- const SwapChainDesc& SCDesc,
- void* pView,
- ISwapChain** ppSwapChain )override final;
+ void CreateSwapChainMtl( IRenderDevice* pDevice,
+ IDeviceContext* pImmediateContext,
+ const SwapChainDesc& SCDesc,
+ const NativeWindow& Window,
+ ISwapChain** ppSwapChain )override final;
void AttachToMtlDevice(void* pMtlNativeDevice,
const EngineMtlCreateInfo& EngineCI,
@@ -179,11 +179,11 @@ void EngineFactoryMtlImpl::AttachToMtlDevice(void* pMtlNat
///
/// \param [out] ppSwapChain - Address of the memory location where pointer to the new
/// swap chain will be written
-void EngineFactoryMtlImpl::CreateSwapChainMtl(IRenderDevice* pDevice,
- IDeviceContext* pImmediateContext,
- const SwapChainDesc& SCDesc,
- void* pView,
- ISwapChain** ppSwapChain )
+void EngineFactoryMtlImpl::CreateSwapChainMtl(IRenderDevice* pDevice,
+ IDeviceContext* pImmediateContext,
+ const SwapChainDesc& SCDesc,
+ const NativeWindow& Window,
+ ISwapChain** ppSwapChain )
{
VERIFY( ppSwapChain, "Null pointer provided" );
if( !ppSwapChain )
@@ -198,7 +198,7 @@ void EngineFactoryMtlImpl::CreateSwapChainMtl(IRenderDevice* pDevice,
auto &RawMemAllocator = GetRawAllocator();
auto *pSwapChainMtl = NEW_RC_OBJ(RawMemAllocator, "SwapChainMtlImpl instance", SwapChainMtlImpl)
- (SCDesc, pDeviceMtl, pDeviceContextMtl, pView);
+ (SCDesc, pDeviceMtl, pDeviceContextMtl, Window);
pSwapChainMtl->QueryInterface( IID_SwapChain, reinterpret_cast<IObject**>(ppSwapChain) );
}
catch( const std::runtime_error & )
diff --git a/Graphics/GraphicsEngineMetal/src/SwapChainMtlImpl.mm b/Graphics/GraphicsEngineMetal/src/SwapChainMtlImpl.mm
index b9974659..87ba6a6b 100644
--- a/Graphics/GraphicsEngineMetal/src/SwapChainMtlImpl.mm
+++ b/Graphics/GraphicsEngineMetal/src/SwapChainMtlImpl.mm
@@ -32,7 +32,7 @@ SwapChainMtlImpl::SwapChainMtlImpl(IReferenceCounters* pRefCounters,
const SwapChainDesc& SCDesc,
RenderDeviceMtlImpl* pRenderDeviceMtl,
DeviceContextMtlImpl* pDeviceContextMtl,
- void* pNativeWndHandle) :
+ const NativeWindow& Window) :
TSwapChainBase(pRefCounters, pRenderDeviceMtl, pDeviceContextMtl, SCDesc)
{
LOG_ERROR_AND_THROW("Swap chain is not implemented in Metal backend");