From 5257f98c5b0b43a887f7cd0528d343c831c053cb Mon Sep 17 00:00:00 2001 From: Egor Yusov Date: Sun, 1 Jul 2018 11:34:20 -0700 Subject: Reworked how render targets are bound in Vulkan: added RenderPass cache --- Graphics/GraphicsEngine/include/TextureViewBase.h | 12 ++++++++++++ 1 file changed, 12 insertions(+) (limited to 'Graphics/GraphicsEngine') diff --git a/Graphics/GraphicsEngine/include/TextureViewBase.h b/Graphics/GraphicsEngine/include/TextureViewBase.h index 25c2c436..97256df2 100644 --- a/Graphics/GraphicsEngine/include/TextureViewBase.h +++ b/Graphics/GraphicsEngine/include/TextureViewBase.h @@ -97,6 +97,18 @@ public: return m_pTexture; } + template + TextureType* GetTexture() + { + return ValidatedCast(m_pTexture); + } + + template + TextureType* GetTexture()const + { + return ValidatedCast(m_pTexture); + } + protected: /// Strong reference to the sampler Diligent::RefCntAutoPtr m_pSampler; -- cgit v1.2.3