[ExecString] combine SplitParameters with identical function of CUtil
[xbmc.git] / xbmc / guilib / TextureDX.h
blob6d0c99abe91ea9044db3cdbbc7bf59d1d8277fd6
1 /*
2 * Copyright (C) 2005-2018 Team Kodi
3 * This file is part of Kodi - https://kodi.tv
5 * SPDX-License-Identifier: GPL-2.0-or-later
6 * See LICENSES/README.md for more information.
7 */
9 #pragma once
11 #include "D3DResource.h"
12 #include "Texture.h"
14 /************************************************************************/
15 /* CDXTexture */
16 /************************************************************************/
17 class CDXTexture : public CTexture
19 public:
20 CDXTexture(unsigned int width = 0, unsigned int height = 0, XB_FMT format = XB_FMT_UNKNOWN);
21 virtual ~CDXTexture();
23 void CreateTextureObject();
24 void DestroyTextureObject();
25 virtual void LoadToGPU();
26 void BindToUnit(unsigned int unit);
28 ID3D11Texture2D* GetTextureObject()
30 return m_texture.Get();
33 ID3D11ShaderResourceView* GetShaderResource()
35 return m_texture.GetShaderResource();
38 private:
39 CD3DTexture m_texture;
40 DXGI_FORMAT GetFormat();