فهرست منبع

Cleanup: Getting rid of the Core suffix on core thread objects since they're now in their own namespace

BearishSun 9 سال پیش
والد
کامیت
457ab039d5
48فایلهای تغییر یافته به همراه554 افزوده شده و 537 حذف شده
  1. 20 20
      Source/BansheeCore/Include/BsRenderAPI.h
  2. 2 2
      Source/BansheeCore/Include/BsRenderTarget.h
  3. 6 6
      Source/BansheeCore/Include/BsRenderWindow.h
  4. 4 4
      Source/BansheeD3D11RenderAPI/Include/BsD3D11BlendState.h
  5. 4 4
      Source/BansheeD3D11RenderAPI/Include/BsD3D11DepthStencilState.h
  6. 5 5
      Source/BansheeD3D11RenderAPI/Include/BsD3D11GpuBuffer.h
  7. 5 5
      Source/BansheeD3D11RenderAPI/Include/BsD3D11GpuBufferView.h
  8. 3 3
      Source/BansheeD3D11RenderAPI/Include/BsD3D11GpuParamBlockBuffer.h
  9. 27 27
      Source/BansheeD3D11RenderAPI/Include/BsD3D11GpuProgram.h
  10. 2 2
      Source/BansheeD3D11RenderAPI/Include/BsD3D11HardwareBufferManager.h
  11. 3 3
      Source/BansheeD3D11RenderAPI/Include/BsD3D11IndexBuffer.h
  12. 2 2
      Source/BansheeD3D11RenderAPI/Include/BsD3D11InputLayoutManager.h
  13. 4 11
      Source/BansheeD3D11RenderAPI/Include/BsD3D11Prerequisites.h
  14. 4 4
      Source/BansheeD3D11RenderAPI/Include/BsD3D11RasterizerState.h
  15. 2 2
      Source/BansheeD3D11RenderAPI/Include/BsD3D11RenderAPI.h
  16. 1 1
      Source/BansheeD3D11RenderAPI/Include/BsD3D11RenderStateManager.h
  17. 20 19
      Source/BansheeD3D11RenderAPI/Include/BsD3D11RenderTexture.h
  18. 52 53
      Source/BansheeD3D11RenderAPI/Include/BsD3D11RenderWindow.h
  19. 12 8
      Source/BansheeD3D11RenderAPI/Include/BsD3D11RenderWindowManager.h
  20. 4 4
      Source/BansheeD3D11RenderAPI/Include/BsD3D11SamplerState.h
  21. 4 4
      Source/BansheeD3D11RenderAPI/Include/BsD3D11Texture.h
  22. 6 3
      Source/BansheeD3D11RenderAPI/Include/BsD3D11TextureManager.h
  23. 5 5
      Source/BansheeD3D11RenderAPI/Include/BsD3D11TextureView.h
  24. 3 3
      Source/BansheeD3D11RenderAPI/Include/BsD3D11VertexBuffer.h
  25. 3 3
      Source/BansheeD3D11RenderAPI/Source/BsD3D11BlendState.cpp
  26. 3 3
      Source/BansheeD3D11RenderAPI/Source/BsD3D11DepthStencilState.cpp
  27. 17 17
      Source/BansheeD3D11RenderAPI/Source/BsD3D11GpuBuffer.cpp
  28. 5 4
      Source/BansheeD3D11RenderAPI/Source/BsD3D11GpuBufferView.cpp
  29. 5 5
      Source/BansheeD3D11RenderAPI/Source/BsD3D11GpuParamBlockBuffer.cpp
  30. 37 37
      Source/BansheeD3D11RenderAPI/Source/BsD3D11GpuProgram.cpp
  31. 24 24
      Source/BansheeD3D11RenderAPI/Source/BsD3D11HLSLProgramFactory.cpp
  32. 13 13
      Source/BansheeD3D11RenderAPI/Source/BsD3D11HardwareBufferManager.cpp
  33. 8 8
      Source/BansheeD3D11RenderAPI/Source/BsD3D11IndexBuffer.cpp
  34. 2 2
      Source/BansheeD3D11RenderAPI/Source/BsD3D11InputLayoutManager.cpp
  35. 3 3
      Source/BansheeD3D11RenderAPI/Source/BsD3D11RasterizerState.cpp
  36. 37 37
      Source/BansheeD3D11RenderAPI/Source/BsD3D11RenderAPI.cpp
  37. 8 8
      Source/BansheeD3D11RenderAPI/Source/BsD3D11RenderStateManager.cpp
  38. 12 10
      Source/BansheeD3D11RenderAPI/Source/BsD3D11RenderTexture.cpp
  39. 7 7
      Source/BansheeD3D11RenderAPI/Source/BsD3D11RenderUtility.cpp
  40. 83 79
      Source/BansheeD3D11RenderAPI/Source/BsD3D11RenderWindow.cpp
  41. 17 11
      Source/BansheeD3D11RenderAPI/Source/BsD3D11RenderWindowManager.cpp
  42. 3 3
      Source/BansheeD3D11RenderAPI/Source/BsD3D11SamplerState.cpp
  43. 21 21
      Source/BansheeD3D11RenderAPI/Source/BsD3D11Texture.cpp
  44. 13 9
      Source/BansheeD3D11RenderAPI/Source/BsD3D11TextureManager.cpp
  45. 5 5
      Source/BansheeD3D11RenderAPI/Source/BsD3D11TextureView.cpp
  46. 8 8
      Source/BansheeD3D11RenderAPI/Source/BsD3D11VertexBuffer.cpp
  47. 6 6
      Source/BansheeEditor/Include/BsScenePicking.h
  48. 14 14
      Source/BansheeEditor/Source/BsScenePicking.cpp

+ 20 - 20
Source/BansheeCore/Include/BsRenderAPI.h

@@ -34,77 +34,77 @@ namespace bs
 	{
 	public:
 		/** 
-		 * @see RenderAPICore::setGpuParams() 
+		 * @see ct::RenderAPICore::setGpuParams() 
 		 *
 		 * @note This is an @ref asyncMethod "asynchronous method".
 		 */
 		static void setGpuParams(const SPtr<GpuParams>& gpuParams);
 
 		/** 
-		 * @see RenderAPICore::setGraphicsPipeline() 
+		 * @see ct::RenderAPICore::setGraphicsPipeline() 
 		 * 
 		 * @note This is an @ref asyncMethod "asynchronous method".
 		 */
 		static void setGraphicsPipeline(const SPtr<GraphicsPipelineState>& pipelineState);
 
 		/** 
-		 * @see RenderAPICore::setComputePipeline() 
+		 * @see ct::RenderAPICore::setComputePipeline() 
 		 * 
 		 * @note This is an @ref asyncMethod "asynchronous method".
 		 */
 		static void setComputePipeline(const SPtr<ComputePipelineState>& pipelineState);
 
 		/** 
-		 * @see RenderAPICore::setVertexBuffers() 
+		 * @see ct::RenderAPICore::setVertexBuffers() 
 		 * 
 		 * @note This is an @ref asyncMethod "asynchronous method".
 		 */
 		static void setVertexBuffers(UINT32 index, const Vector<SPtr<VertexBuffer>>& buffers);
 
 		/** 
-		 * @see RenderAPICore::setIndexBuffer() 
+		 * @see ct::RenderAPICore::setIndexBuffer() 
 		 * 
 		 * @note This is an @ref asyncMethod "asynchronous method".
 		 */
 		static void setIndexBuffer(const SPtr<IndexBuffer>& buffer);
 
 		/** 
-		 * @see RenderAPICore::setVertexDeclaration() 
+		 * @see ct::RenderAPICore::setVertexDeclaration() 
 		 * 
 		 * @note This is an @ref asyncMethod "asynchronous method".
 		 */
 		static void setVertexDeclaration(const SPtr<VertexDeclaration>& vertexDeclaration);
 
 		/** 
-		 * @see RenderAPICore::setViewport() 
+		 * @see ct::RenderAPICore::setViewport() 
 		 * 
 		 * @note This is an @ref asyncMethod "asynchronous method".
 		 */
 		static void setViewport(const Rect2& area);
 
 		/** 
-		 * @see RenderAPICore::setViewport() 
+		 * @see ct::RenderAPICore::setViewport() 
 		 * 
 		 * @note This is an @ref asyncMethod "asynchronous method".
 		 */
 		static void setStencilRef(UINT32 value);
 
 		/** 
-		 * @see RenderAPICore::setDrawOperation()  
+		 * @see ct::RenderAPICore::setDrawOperation()  
 		 * 
 		 * @note This is an @ref asyncMethod "asynchronous method".
 		 */
 		static void setDrawOperation(DrawOperationType op);
 
 		/** 
-		 * @see RenderAPICore::setScissorRect() 
+		 * @see ct::RenderAPICore::setScissorRect() 
 		 * 
 		 * @note This is an @ref asyncMethod "asynchronous method".
 		 */
 		static void setScissorRect(UINT32 left = 0, UINT32 top = 0, UINT32 right = 800, UINT32 bottom = 600);
 
 		/** 
-		 * @see RenderAPICore::setRenderTarget() 
+		 * @see ct::RenderAPICore::setRenderTarget() 
 		 * 
 		 * @note This is an @ref asyncMethod "asynchronous method".
 		 */
@@ -112,7 +112,7 @@ namespace bs
 			RenderSurfaceMask loadMask = RT_NONE);
 
 		/** 
-		 * @see RenderAPICore::clearRenderTarget() 
+		 * @see ct::RenderAPICore::clearRenderTarget() 
 		 * 
 		 * @note This is an @ref asyncMethod "asynchronous method".
 		 */
@@ -120,7 +120,7 @@ namespace bs
 			UINT16 stencil = 0, UINT8 targetMask = 0xFF);
 
 		/** 
-		 * @see RenderAPICore::clearViewport() 
+		 * @see ct::RenderAPICore::clearViewport() 
 		 * 
 		 * @note This is an @ref asyncMethod "asynchronous method".
 		 */
@@ -128,21 +128,21 @@ namespace bs
 			UINT8 targetMask = 0xFF);
 
 		/** 
-		 * @see RenderAPICore::swapBuffers() 
+		 * @see ct::RenderAPICore::swapBuffers() 
 		 * 
 		 * @note This is an @ref asyncMethod "asynchronous method".
 		 */
 		static void swapBuffers(const SPtr<RenderTarget>& target);
 
 		/** 
-		 * @see RenderAPICore::draw() 
+		 * @see ct::RenderAPICore::draw() 
 		 * 
 		 * @note This is an @ref asyncMethod "asynchronous method".
 		 */
 		static void draw(UINT32 vertexOffset, UINT32 vertexCount, UINT32 instanceCount = 0);
 
 		/** 
-		 * @see RenderAPICore::drawIndexed() 
+		 * @see ct::RenderAPICore::drawIndexed() 
 		 * 
 		 * @note This is an @ref asyncMethod "asynchronous method".
 		 */
@@ -150,19 +150,19 @@ namespace bs
 			UINT32 instanceCount = 0);
 
 		/** 
-		 * @see RenderAPICore::dispatchCompute() 
+		 * @see ct::RenderAPICore::dispatchCompute() 
 		 * 
 		 * @note This is an @ref asyncMethod "asynchronous method".
 		 */
 		static void dispatchCompute(UINT32 numGroupsX, UINT32 numGroupsY = 1, UINT32 numGroupsZ = 1);
 
-		/** @copydoc RenderAPICore::getVideoModeInfo */
+		/** @copydoc ct::RenderAPICore::getVideoModeInfo */
 		static const VideoModeInfo& getVideoModeInfo();
 
-		/** @copydoc RenderAPICore::convertProjectionMatrix */
+		/** @copydoc ct::RenderAPICore::convertProjectionMatrix */
 		static void convertProjectionMatrix(const Matrix4& matrix, Matrix4& dest);
 
-		/** @copydoc RenderAPICore::getAPIInfo */
+		/** @copydoc ct::RenderAPICore::getAPIInfo */
 		static const RenderAPIInfo& getAPIInfo();
 	};
 

+ 2 - 2
Source/BansheeCore/Include/BsRenderTarget.h

@@ -158,7 +158,7 @@ namespace bs
 		virtual void getCustomAttribute(const String& name, void* pData) const;
 
 		/** 
-		 * @copydoc RenderTargetCore::setPriority 
+		 * @copydoc ct::RenderTargetCore::setPriority 
 		 *
 		 * @note This is an @ref asyncMethod "asynchronous method".
 		 */
@@ -240,7 +240,7 @@ namespace bs
 		const RenderTargetProperties& getProperties() const;
 
 	protected:
-		friend class RenderTarget;
+		friend class bs::RenderTarget;
 
 		/**	Returns properties that describe the render target. */
 		virtual const RenderTargetProperties& getPropertiesInternal() const = 0;

+ 6 - 6
Source/BansheeCore/Include/BsRenderWindow.h

@@ -134,42 +134,42 @@ namespace bs
 		void show();
 
 		/** 
-		 * @copydoc RenderWindowCore::minimize  
+		 * @copydoc ct::RenderWindowCore::minimize  
 		 * 
 		 * @note This is an @ref asyncMethod "asynchronous method".
 		 */
 		void minimize();
 
 		/** 
-		 * @copydoc RenderWindowCore::maximize 
+		 * @copydoc ct::RenderWindowCore::maximize 
 		 * 
 		 * @note This is an @ref asyncMethod "asynchronous method".
 		 */
 		void maximize();
 
 		/** 
-		 * @copydoc RenderWindowCore::restore  
+		 * @copydoc ct::RenderWindowCore::restore  
 		 * 
 		 * @note This is an @ref asyncMethod "asynchronous method".
 		 */
 		void restore();
 
 		/** 
-		 * @copydoc RenderWindowCore::setFullscreen(UINT32, UINT32, float, UINT32) 
+		 * @copydoc ct::RenderWindowCore::setFullscreen(UINT32, UINT32, float, UINT32) 
 		 * 
 		 * @note This is an @ref asyncMethod "asynchronous method".
 		 */
 		void setFullscreen(UINT32 width, UINT32 height, float refreshRate = 60.0f, UINT32 monitorIdx = 0);
 
 		/** 
-		 * @copydoc RenderWindowCore::setFullscreen(const VideoMode&) 
+		 * @copydoc ct::RenderWindowCore::setFullscreen(const VideoMode&) 
 		 * 
 		 * @note This is an @ref asyncMethod "asynchronous method".
 		 */
 		void setFullscreen(const VideoMode& videoMode);
 
 		/** 
-		 * @copydoc RenderWindowCore::setWindowed 
+		 * @copydoc ct::RenderWindowCore::setWindowed 
 		 * 
 		 * @note This is an @ref asyncMethod "asynchronous method".
 		 */

+ 4 - 4
Source/BansheeD3D11RenderAPI/Include/BsD3D11BlendState.h

@@ -12,18 +12,18 @@ namespace bs { namespace ct
 	 */
 
 	/** DirectX 11 implementation of a blend state. Corresponds directly with a DX11 blend state object. */
-	class BS_D3D11_EXPORT D3D11BlendStateCore : public BlendStateCore
+	class BS_D3D11_EXPORT D3D11BlendState : public BlendStateCore
 	{
 	public:
-		~D3D11BlendStateCore();
+		~D3D11BlendState();
 
 		/**	Returns the internal DX11 blend state object. */
 		ID3D11BlendState* getInternal() const { return mBlendState; }
 
 	protected:
-		friend class D3D11RenderStateCoreManager;
+		friend class D3D11RenderStateManager;
 
-		D3D11BlendStateCore(const BLEND_STATE_DESC& desc, UINT32 id);
+		D3D11BlendState(const BLEND_STATE_DESC& desc, UINT32 id);
 
 		/** @copydoc BlendStateCore::createInternal */
 		void createInternal() override;

+ 4 - 4
Source/BansheeD3D11RenderAPI/Include/BsD3D11DepthStencilState.h

@@ -12,18 +12,18 @@ namespace bs { namespace ct
 	 */
 
 	/** DirectX 11 implementation of a depth stencil state. Corresponds directly with a DX11 depth stencil state object. */
-	class BS_D3D11_EXPORT D3D11DepthStencilStateCore : public DepthStencilStateCore
+	class BS_D3D11_EXPORT D3D11DepthStencilState : public DepthStencilStateCore
 	{
 	public:
-		~D3D11DepthStencilStateCore();
+		~D3D11DepthStencilState();
 
 		/**	Returns the internal DX11 depth stencil state object. */
 		ID3D11DepthStencilState* getInternal() const { return mDepthStencilState; }
 
 	protected:
-		friend class D3D11RenderStateCoreManager;
+		friend class D3D11RenderStateManager;
 
-		D3D11DepthStencilStateCore(const DEPTH_STENCIL_STATE_DESC& desc, UINT32 id);
+		D3D11DepthStencilState(const DEPTH_STENCIL_STATE_DESC& desc, UINT32 id);
 
 		/** @copydoc DepthStencilStateCore::createInternal() */
 		void createInternal() override;

+ 5 - 5
Source/BansheeD3D11RenderAPI/Include/BsD3D11GpuBuffer.h

@@ -13,10 +13,10 @@ namespace bs { namespace ct
 	 */
 
 	/**	DirectX 11 implementation of a generic GPU buffer. */
-	class BS_D3D11_EXPORT D3D11GpuBufferCore : public GpuBufferCore
+	class BS_D3D11_EXPORT D3D11GpuBuffer : public GpuBufferCore
     {
     public:
-		~D3D11GpuBufferCore();
+		~D3D11GpuBuffer();
 
 		/** @copydoc GpuBufferCore::lock */
 		void* lock(UINT32 offset, UINT32 length, GpuLockOptions options, UINT32 deviceIdx = 0,
@@ -50,7 +50,7 @@ namespace bs { namespace ct
 		 * @note Only Default and RandomWrite views are supported for this type of buffer. 
 		 */
 		// TODO Low Priority: Perhaps reflect usage flag limitation by having an enum with only the supported two options?
-		static GpuBufferView* requestView(const SPtr<D3D11GpuBufferCore>& buffer, UINT32 firstElement, 
+		static GpuBufferView* requestView(const SPtr<D3D11GpuBuffer>& buffer, UINT32 firstElement, 
 			UINT32 numElements, GpuViewUsage usage);
 
 		/**
@@ -70,9 +70,9 @@ namespace bs { namespace ct
 		ID3D11UnorderedAccessView* getUAV() const;
 
 	protected:
-		friend class D3D11HardwareBufferCoreManager;
+		friend class D3D11HardwareBufferManager;
 
-		D3D11GpuBufferCore(const GPU_BUFFER_DESC& desc, GpuDeviceFlags deviceMask);
+		D3D11GpuBuffer(const GPU_BUFFER_DESC& desc, GpuDeviceFlags deviceMask);
 
 		/**	Destroys all buffer views regardless if their reference count is zero or not. */
 		void clearBufferViews();

+ 5 - 5
Source/BansheeD3D11RenderAPI/Include/BsD3D11GpuBufferView.h

@@ -51,13 +51,13 @@ namespace bs { namespace ct
 		 * Initializes a new buffer view for the specified buffer. Descriptor structure defines which portion of the buffer,
 		 * and how will its contents be represented by the view.
 		 */
-		void initialize(const SPtr<D3D11GpuBufferCore>& buffer, GPU_BUFFER_VIEW_DESC& desc);
+		void initialize(const SPtr<D3D11GpuBuffer>& buffer, GPU_BUFFER_VIEW_DESC& desc);
 
 		/** Returns a descriptor structure used for creating the view. */
 		const GPU_BUFFER_VIEW_DESC& getDesc() const { return mDesc; }
 
 		/**	Returns the buffer this view was created for. */
-		SPtr<D3D11GpuBufferCore> getBuffer() const { return mBuffer; }
+		SPtr<D3D11GpuBuffer> getBuffer() const { return mBuffer; }
 
 		/** Returns index of first element in the buffer that this view provides access to. */
 		UINT32 getFirstElement() const { return mDesc.firstElement; }
@@ -95,7 +95,7 @@ namespace bs { namespace ct
 		 *								number of bytes for raw buffers or number of structures for structured buffers.
 		 * @return						Constructed DX11 shader resource view object.
 		 */
-		ID3D11ShaderResourceView* createSRV(D3D11GpuBufferCore* buffer, UINT32 firstElement, UINT32 elementWidth, UINT32 numElements);
+		ID3D11ShaderResourceView* createSRV(D3D11GpuBuffer* buffer, UINT32 firstElement, UINT32 elementWidth, UINT32 numElements);
 
 		/**
 		 * Creates a DX11 unordered access view that allows a buffer to be bound to a shader for random reading or writing.
@@ -108,13 +108,13 @@ namespace bs { namespace ct
 		 *								number of bytes for raw buffers or number of structures for structured buffers.
 		 * @return						Constructed DX11 unordered access view object.
 		 */
-		ID3D11UnorderedAccessView* createUAV(D3D11GpuBufferCore* buffer, UINT32 firstElement, UINT32 numElements, bool useCounter);
+		ID3D11UnorderedAccessView* createUAV(D3D11GpuBuffer* buffer, UINT32 firstElement, UINT32 numElements, bool useCounter);
 
 		ID3D11ShaderResourceView* mSRV;
 		ID3D11UnorderedAccessView* mUAV;
 
 		GPU_BUFFER_VIEW_DESC mDesc;
-		SPtr<D3D11GpuBufferCore> mBuffer;
+		SPtr<D3D11GpuBuffer> mBuffer;
 	};
 
 	/** @} */

+ 3 - 3
Source/BansheeD3D11RenderAPI/Include/BsD3D11GpuParamBlockBuffer.h

@@ -12,11 +12,11 @@ namespace bs { namespace ct
 	 */
 
 	/**	DirectX 11 implementation of a parameter block buffer (constant buffer in DX11 lingo). */
-	class BS_D3D11_EXPORT D3D11GpuParamBlockBufferCore : public GpuParamBlockBufferCore
+	class BS_D3D11_EXPORT D3D11GpuParamBlockBuffer : public GpuParamBlockBufferCore
 	{
 	public:
-		D3D11GpuParamBlockBufferCore(UINT32 size, GpuParamBlockUsage usage, GpuDeviceFlags deviceMask);
-		~D3D11GpuParamBlockBufferCore();
+		D3D11GpuParamBlockBuffer(UINT32 size, GpuParamBlockUsage usage, GpuDeviceFlags deviceMask);
+		~D3D11GpuParamBlockBuffer();
 
 		/** @copydoc GpuParamBlockBufferCore::writeToGPU */
 		void writeToGPU(const UINT8* data, UINT32 queueIdx = 0) override;

+ 27 - 27
Source/BansheeD3D11RenderAPI/Include/BsD3D11GpuProgram.h

@@ -12,10 +12,10 @@ namespace bs { namespace ct
 	 */
 
 	/**	Abstraction of a DirectX 11 shader object. */
-	class BS_D3D11_EXPORT D3D11GpuProgramCore : public GpuProgramCore
+	class BS_D3D11_EXPORT D3D11GpuProgram : public GpuProgramCore
 	{
 	public:
-		virtual ~D3D11GpuProgramCore();
+		virtual ~D3D11GpuProgram();
 
 		/**	Returns compiled shader microcode. */
 		const HLSLMicroCode& getMicroCode() const { return mMicrocode; }
@@ -24,7 +24,7 @@ namespace bs { namespace ct
 		UINT32 getProgramId() const { return mProgramId; }
 
 	protected:
-		D3D11GpuProgramCore(const GPU_PROGRAM_DESC& desc, GpuDeviceFlags deviceMask);
+		D3D11GpuProgram(const GPU_PROGRAM_DESC& desc, GpuDeviceFlags deviceMask);
 
 		/** @copydoc GpuProgramCore::initialize */
 		void initialize() override;
@@ -53,10 +53,10 @@ namespace bs { namespace ct
 	};
 
 	/**	Implementation of a DX11 vertex shader. */
-	class BS_D3D11_EXPORT D3D11GpuVertexProgramCore : public D3D11GpuProgramCore
+	class BS_D3D11_EXPORT D3D11GpuVertexProgram : public D3D11GpuProgram
 	{
 	public:
-		~D3D11GpuVertexProgramCore();
+		~D3D11GpuVertexProgram();
 
 		/**	Returns internal DX11 vertex shader object. */
 		ID3D11VertexShader* getVertexShader() const;
@@ -64,9 +64,9 @@ namespace bs { namespace ct
 	protected:
 		friend class D3D11HLSLProgramFactory;
 
-		D3D11GpuVertexProgramCore(const GPU_PROGRAM_DESC& desc, GpuDeviceFlags deviceMask);
+		D3D11GpuVertexProgram(const GPU_PROGRAM_DESC& desc, GpuDeviceFlags deviceMask);
 
-		/** @copydoc D3D11GpuProgramCore::loadFromMicrocode */
+		/** @copydoc D3D11GpuProgram::loadFromMicrocode */
 		void loadFromMicrocode(D3D11Device& device, ID3D10Blob* microcode) override;
 
 	protected:
@@ -74,10 +74,10 @@ namespace bs { namespace ct
 	};
 
 	/**	Implementation of a DX11 pixel shader. */
-	class BS_D3D11_EXPORT D3D11GpuFragmentProgramCore : public D3D11GpuProgramCore
+	class BS_D3D11_EXPORT D3D11GpuFragmentProgram : public D3D11GpuProgram
 	{
 	public:
-		~D3D11GpuFragmentProgramCore();
+		~D3D11GpuFragmentProgram();
 
 		/**	Returns internal DX11 pixel shader object. */
 		ID3D11PixelShader* getPixelShader() const;
@@ -85,9 +85,9 @@ namespace bs { namespace ct
 	protected:
 		friend class D3D11HLSLProgramFactory;
 
-		D3D11GpuFragmentProgramCore(const GPU_PROGRAM_DESC& desc, GpuDeviceFlags deviceMask);
+		D3D11GpuFragmentProgram(const GPU_PROGRAM_DESC& desc, GpuDeviceFlags deviceMask);
 
-		/** @copydoc D3D11GpuProgramCore::loadFromMicrocode */
+		/** @copydoc D3D11GpuProgram::loadFromMicrocode */
 		void loadFromMicrocode(D3D11Device& device, ID3D10Blob* microcode) override;
 
 	protected:
@@ -95,10 +95,10 @@ namespace bs { namespace ct
 	};
 
 	/**	Implementation of a DX11 domain shader. */
-	class BS_D3D11_EXPORT D3D11GpuDomainProgramCore : public D3D11GpuProgramCore
+	class BS_D3D11_EXPORT D3D11GpuDomainProgram : public D3D11GpuProgram
 	{
 	public:
-		~D3D11GpuDomainProgramCore();
+		~D3D11GpuDomainProgram();
 
 		/**	Returns internal DX11 domain shader object. */
 		ID3D11DomainShader* getDomainShader() const;
@@ -106,9 +106,9 @@ namespace bs { namespace ct
 	protected:
 		friend class D3D11HLSLProgramFactory;
 
-		D3D11GpuDomainProgramCore(const GPU_PROGRAM_DESC& desc, GpuDeviceFlags deviceMask);
+		D3D11GpuDomainProgram(const GPU_PROGRAM_DESC& desc, GpuDeviceFlags deviceMask);
 
-		/** @copydoc D3D11GpuProgramCore::loadFromMicrocode */
+		/** @copydoc D3D11GpuProgram::loadFromMicrocode */
 		void loadFromMicrocode(D3D11Device& device, ID3D10Blob* microcode) override;
 
 	protected:
@@ -116,10 +116,10 @@ namespace bs { namespace ct
 	};
 
 	/**	Implementation of a DX11 hull shader. */
-	class BS_D3D11_EXPORT D3D11GpuHullProgramCore : public D3D11GpuProgramCore
+	class BS_D3D11_EXPORT D3D11GpuHullProgram : public D3D11GpuProgram
 	{
 	public:
-		~D3D11GpuHullProgramCore();
+		~D3D11GpuHullProgram();
 
 		/**	Returns internal DX11 hull shader object. */
 		ID3D11HullShader* getHullShader() const;
@@ -127,9 +127,9 @@ namespace bs { namespace ct
 	protected:
 		friend class D3D11HLSLProgramFactory;
 
-		D3D11GpuHullProgramCore(const GPU_PROGRAM_DESC& desc, GpuDeviceFlags deviceMask);
+		D3D11GpuHullProgram(const GPU_PROGRAM_DESC& desc, GpuDeviceFlags deviceMask);
 
-		/** @copydoc D3D11GpuProgramCore::loadFromMicrocode */
+		/** @copydoc D3D11GpuProgram::loadFromMicrocode */
 		void loadFromMicrocode(D3D11Device& device, ID3D10Blob* microcode) override;
 
 	protected:
@@ -137,10 +137,10 @@ namespace bs { namespace ct
 	};
 
 	/**	Implementation of a DX11 geometry shader. */
-	class BS_D3D11_EXPORT D3D11GpuGeometryProgramCore : public D3D11GpuProgramCore
+	class BS_D3D11_EXPORT D3D11GpuGeometryProgram : public D3D11GpuProgram
 	{
 	public:
-		~D3D11GpuGeometryProgramCore();
+		~D3D11GpuGeometryProgram();
 
 		/**	Returns internal DX11 geometry shader object. */
 		ID3D11GeometryShader* getGeometryShader() const;
@@ -148,9 +148,9 @@ namespace bs { namespace ct
 	protected:
 		friend class D3D11HLSLProgramFactory;
 
-		D3D11GpuGeometryProgramCore(const GPU_PROGRAM_DESC& desc, GpuDeviceFlags deviceMask);
+		D3D11GpuGeometryProgram(const GPU_PROGRAM_DESC& desc, GpuDeviceFlags deviceMask);
 
-		/** @copydoc D3D11GpuProgramCore::loadFromMicrocode */
+		/** @copydoc D3D11GpuProgram::loadFromMicrocode */
 		void loadFromMicrocode(D3D11Device& device, ID3D10Blob* microcode) override;
 
 	protected:
@@ -158,10 +158,10 @@ namespace bs { namespace ct
 	};
 
 	/**	Implementation of a DX11 compute shader. */
-	class BS_D3D11_EXPORT D3D11GpuComputeProgramCore : public D3D11GpuProgramCore
+	class BS_D3D11_EXPORT D3D11GpuComputeProgram : public D3D11GpuProgram
 	{
 	public:
-		~D3D11GpuComputeProgramCore();
+		~D3D11GpuComputeProgram();
 
 		/**	Returns internal DX11 compute shader object. */
 		ID3D11ComputeShader* getComputeShader() const;
@@ -169,9 +169,9 @@ namespace bs { namespace ct
 	protected:
 		friend class D3D11HLSLProgramFactory;
 
-		D3D11GpuComputeProgramCore(const GPU_PROGRAM_DESC& desc, GpuDeviceFlags deviceMask);
+		D3D11GpuComputeProgram(const GPU_PROGRAM_DESC& desc, GpuDeviceFlags deviceMask);
 
-		/** @copydoc D3D11GpuProgramCore::loadFromMicrocode */
+		/** @copydoc D3D11GpuProgram::loadFromMicrocode */
 		void loadFromMicrocode(D3D11Device& device, ID3D10Blob* microcode) override;
 
 	protected:

+ 2 - 2
Source/BansheeD3D11RenderAPI/Include/BsD3D11HardwareBufferManager.h

@@ -12,10 +12,10 @@ namespace bs { namespace ct
 	 */
 
 	/**	Handles creation of DirectX 11 hardware buffers. */
-	class BS_D3D11_EXPORT D3D11HardwareBufferCoreManager : public HardwareBufferCoreManager
+	class BS_D3D11_EXPORT D3D11HardwareBufferManager : public HardwareBufferCoreManager
 	{
 	public:
-		D3D11HardwareBufferCoreManager(D3D11Device& device);
+		D3D11HardwareBufferManager(D3D11Device& device);
 
 	protected:     
 		/** @copydoc HardwareBufferCoreManager::createVertexBufferInternal */

+ 3 - 3
Source/BansheeD3D11RenderAPI/Include/BsD3D11IndexBuffer.h

@@ -13,12 +13,12 @@ namespace bs { namespace ct
 	 */
 
 	/**	DirectX 11 implementation of an index buffer. */
-	class BS_D3D11_EXPORT D3D11IndexBufferCore : public IndexBufferCore
+	class BS_D3D11_EXPORT D3D11IndexBuffer : public IndexBufferCore
 	{
 	public:
-		D3D11IndexBufferCore(D3D11Device& device, const INDEX_BUFFER_DESC& desc, GpuDeviceFlags deviceMask);
+		D3D11IndexBuffer(D3D11Device& device, const INDEX_BUFFER_DESC& desc, GpuDeviceFlags deviceMask);
 
-		~D3D11IndexBufferCore();
+		~D3D11IndexBuffer();
 
 		/** @copydoc IndexBufferCore::readData */
 		void readData(UINT32 offset, UINT32 length, void* dest, UINT32 deviceIdx = 0, UINT32 queueIdx = 0) override;

+ 2 - 2
Source/BansheeD3D11RenderAPI/Include/BsD3D11InputLayoutManager.h

@@ -61,12 +61,12 @@ namespace bs { namespace ct
 		 * @note	Error will be thrown if the vertex buffer doesn't provide all the necessary data that the shader expects.
 		 */
 		ID3D11InputLayout* retrieveInputLayout(const SPtr<VertexDeclarationCore>& vertexShaderDecl,
-			const SPtr<VertexDeclarationCore>& vertexBufferDecl, D3D11GpuProgramCore& vertexProgram);
+			const SPtr<VertexDeclarationCore>& vertexBufferDecl, D3D11GpuProgram& vertexProgram);
 
 	private:
 		/**	Creates a new input layout using the specified parameters and stores it in the input layout map. */
 		void addNewInputLayout(const SPtr<VertexDeclarationCore>& vertexShaderDecl, const SPtr<VertexDeclarationCore>& vertexBufferDecl,
-			D3D11GpuProgramCore& vertexProgram);
+			D3D11GpuProgram& vertexProgram);
 
 		/**	Destroys least used input layout. */
 		void removeLeastUsed();

+ 4 - 11
Source/BansheeD3D11RenderAPI/Include/BsD3D11Prerequisites.h

@@ -32,28 +32,21 @@
 namespace bs { namespace ct
 {
 	class D3D11RenderAPI;
-	class D3D11RenderWindow;
-	class D3D11TextureManager;
 	class D3D11Driver;
 	class D3D11DriverList;
 	class D3D11VideoMode;
 	class D3D11VideoModeList;
 	class D3D11GpuProgramManager;
-	class D3D11IndexBuffer;
 	class D3D11HLSLProgramFactory;
 	class D3D11Device;
 	class D3D11HardwareBuffer;
-	class D3D11GpuVertexProgram;
-	class D3D11GpuFragmentProgram;
-	class D3D11GpuGeometryProgram;
-	class D3D11GpuHullProgram;
-	class D3D11GpuDomainProgram;
-	class D3D11DepthStencilStateCore;
+	class D3D11DepthStencilState;
 	class D3D11InputLayoutManager;
-	class D3D11GpuBufferCore;
+	class D3D11GpuBuffer;
 	class D3D11RenderUtility;
-	class D3D11GpuProgramCore;
+	class D3D11GpuProgram;
 	class D3D11TextureView;
+	class D3D11RenderWindow;
 	class GpuBufferView;
 
 	/**	DirectX 11 specific types to track resource statistics for. */

+ 4 - 4
Source/BansheeD3D11RenderAPI/Include/BsD3D11RasterizerState.h

@@ -12,16 +12,16 @@ namespace bs { namespace ct
 	 */
 
 	/** DirectX 11 implementation of a rasterizer state. Wraps a DX11 rasterizer state object. */
-	class BS_D3D11_EXPORT D3D11RasterizerStateCore : public RasterizerStateCore
+	class BS_D3D11_EXPORT D3D11RasterizerState : public RasterizerStateCore
 	{
 	public:
-		~D3D11RasterizerStateCore();
+		~D3D11RasterizerState();
 		ID3D11RasterizerState* getInternal() const { return mRasterizerState; }
 
 	protected:
-		friend class D3D11RenderStateCoreManager;
+		friend class D3D11RenderStateManager;
 
-		D3D11RasterizerStateCore(const RASTERIZER_STATE_DESC& desc, UINT32 id);
+		D3D11RasterizerState(const RASTERIZER_STATE_DESC& desc, UINT32 id);
 
 		/** @copydoc RasterizerStateCore::createInternal */
 		void createInternal() override;

+ 2 - 2
Source/BansheeD3D11RenderAPI/Include/BsD3D11RenderAPI.h

@@ -220,8 +220,8 @@ namespace bs { namespace ct
 		D3D11_RECT mScissorRect;
 
 		SPtr<VertexDeclarationCore> mActiveVertexDeclaration;
-		SPtr<D3D11GpuProgramCore> mActiveVertexShader;
-		SPtr<D3D11DepthStencilStateCore> mActiveDepthStencilState;
+		SPtr<D3D11GpuProgram> mActiveVertexShader;
+		SPtr<D3D11DepthStencilState> mActiveDepthStencilState;
 
 		DrawOperationType mActiveDrawOp;
 	};

+ 1 - 1
Source/BansheeD3D11RenderAPI/Include/BsD3D11RenderStateManager.h

@@ -12,7 +12,7 @@ namespace bs { namespace ct
 	 */
 
 	/**	Handles creation of DirectX 11 pipeline states. */
-	class BS_D3D11_EXPORT D3D11RenderStateCoreManager : public RenderStateCoreManager
+	class BS_D3D11_EXPORT D3D11RenderStateManager : public RenderStateCoreManager
 	{
 	protected:
 		/** @copydoc RenderStateCoreManager::createSamplerStateInternal */

+ 20 - 19
Source/BansheeD3D11RenderAPI/Include/BsD3D11RenderTexture.h

@@ -6,55 +6,56 @@
 #include "BsTexture.h"
 #include "BsRenderTexture.h"
 
-namespace bs { namespace ct
+namespace bs
 {
 	/** @addtogroup D3D11
 	 *  @{
 	 */
 
-	class D3D11RenderTexture;
-
 	/**
 	 * DirectX 11 implementation of a render texture.
 	 *
-	 * @note	Core thread only.
+	 * @note	Sim thread only.
 	 */
-	class D3D11RenderTextureCore : public RenderTextureCore
+	class D3D11RenderTexture : public RenderTexture
 	{
 	public:
-		D3D11RenderTextureCore(const RENDER_TEXTURE_DESC_CORE& desc, UINT32 deviceIdx);
-		virtual ~D3D11RenderTextureCore() { }
-
-		/** @copydoc RenderTextureCore::getCustomAttribute */
-		void getCustomAttribute(const String& name, void* data) const override;
+		virtual ~D3D11RenderTexture() { }
 
 	protected:
-		/** @copydoc RenderTextureCore::getProperties */
+		friend class D3D11TextureManager;
+
+		D3D11RenderTexture(const RENDER_TEXTURE_DESC& desc);
+
+		/** @copydoc RenderTexture::getProperties */
 		const RenderTargetProperties& getPropertiesInternal() const override { return mProperties; }
 
 		RenderTextureProperties mProperties;
 	};
 
+	namespace ct
+	{
 	/**
 	 * DirectX 11 implementation of a render texture.
 	 *
-	 * @note	Sim thread only.
+	 * @note	Core thread only.
 	 */
-	class D3D11RenderTexture : public RenderTexture
+	class D3D11RenderTexture : public RenderTextureCore
 	{
 	public:
+		D3D11RenderTexture(const RENDER_TEXTURE_DESC_CORE& desc, UINT32 deviceIdx);
 		virtual ~D3D11RenderTexture() { }
 
-	protected:
-		friend class D3D11TextureManager;
-
-		D3D11RenderTexture(const RENDER_TEXTURE_DESC& desc);
+		/** @copydoc RenderTextureCore::getCustomAttribute */
+		void getCustomAttribute(const String& name, void* data) const override;
 
-		/** @copydoc RenderTexture::getProperties */
+	protected:
+		/** @copydoc RenderTextureCore::getProperties */
 		const RenderTargetProperties& getPropertiesInternal() const override { return mProperties; }
 
 		RenderTextureProperties mProperties;
 	};
+	}
 
 	/** @} */
-}}
+}

+ 52 - 53
Source/BansheeD3D11RenderAPI/Include/BsD3D11RenderWindow.h

@@ -5,14 +5,11 @@
 #include "BsD3D11Prerequisites.h"
 #include "BsRenderWindow.h"
 
-namespace bs { namespace ct
-{
+namespace bs { 
 	/** @addtogroup D3D11
 	 *  @{
 	 */
 
-	class D3D11RenderWindow;
-
 	/**	Contains various properties that describe a render window. */
 	class BS_D3D11_EXPORT D3D11RenderWindowProperties : public RenderWindowProperties
 	{
@@ -21,22 +18,68 @@ namespace bs { namespace ct
 		virtual ~D3D11RenderWindowProperties() { }
 
 	private:
-		friend class D3D11RenderWindowCore;
 		friend class D3D11RenderWindow;
+		friend class ct::D3D11RenderWindow;
+	};
+
+	/**
+	 * Render window implementation for Windows and DirectX 11.
+	 *
+	 * @note	Sim thread only.
+	 */
+	class BS_D3D11_EXPORT D3D11RenderWindow : public RenderWindow
+	{
+	public:
+		~D3D11RenderWindow() { }
+
+		/** @copydoc RenderWindow::screenToWindowPos */
+		void getCustomAttribute(const String& name, void* pData) const override;
+
+		/** @copydoc RenderWindow::screenToWindowPos */
+		Vector2I screenToWindowPos(const Vector2I& screenPos) const override;
+
+		/** @copydoc RenderWindow::windowToScreenPos */
+		Vector2I windowToScreenPos(const Vector2I& windowPos) const override;
+
+		/** @copydoc RenderWindow::getCore */
+		SPtr<ct::D3D11RenderWindow> getCore() const;
+
+	protected:
+		friend class D3D11RenderWindowManager;
+		friend class ct::D3D11RenderWindow;
+
+		D3D11RenderWindow(const RENDER_WINDOW_DESC& desc, UINT32 windowId, 
+			ct::D3D11Device& device, IDXGIFactory* DXGIFactory);
+
+		/** @copydoc RenderWindow::getProperties */
+		const RenderTargetProperties& getPropertiesInternal() const override { return mProperties; }
+
+		/** @copydoc RenderWindow::syncProperties */
+		void syncProperties() override;
+
+		/**	Retrieves internal window handle. */
+		HWND getHWnd() const;
+
+	private:
+		ct::D3D11Device& mDevice;
+		IDXGIFactory* mDXGIFactory;
+		D3D11RenderWindowProperties mProperties;
 	};
 
+	namespace ct
+	{
 	/**
 	 * Render window implementation for Windows and DirectX 11.
 	 *
 	 * @note	Core thread only.
 	 */
-	class BS_D3D11_EXPORT D3D11RenderWindowCore : public RenderWindowCore
+	class BS_D3D11_EXPORT D3D11RenderWindow : public RenderWindowCore
 	{
 	public:
-		D3D11RenderWindowCore(const RENDER_WINDOW_DESC& desc, UINT32 windowId,
+		D3D11RenderWindow(const RENDER_WINDOW_DESC& desc, UINT32 windowId,
 			D3D11Device& device, IDXGIFactory* DXGIFactory);
 
-		~D3D11RenderWindowCore();
+		~D3D11RenderWindow();
 
 		/** @copydoc RenderWindowCore::move */
 		void move(INT32 left, INT32 top) override;
@@ -92,7 +135,7 @@ namespace bs { namespace ct
 		HWND _getWindowHandle() const;
 
 	protected:
-		friend class D3D11RenderWindow;
+		friend class bs::D3D11RenderWindow;
 
 		/** @copydoc CoreObjectCore::initialize */
 		void initialize() override;
@@ -144,50 +187,6 @@ namespace bs { namespace ct
 		D3D11RenderWindowProperties mProperties;
 		D3D11RenderWindowProperties mSyncedProperties;
 	};
-
-	/**
-	 * Render window implementation for Windows and DirectX 11.
-	 *
-	 * @note	Sim thread only.
-	 */
-	class BS_D3D11_EXPORT D3D11RenderWindow : public RenderWindow
-	{
-	public:
-		~D3D11RenderWindow() { }
-
-		/** @copydoc RenderWindow::screenToWindowPos */
-		void getCustomAttribute(const String& name, void* pData) const override;
-
-		/** @copydoc RenderWindow::screenToWindowPos */
-		Vector2I screenToWindowPos(const Vector2I& screenPos) const override;
-
-		/** @copydoc RenderWindow::windowToScreenPos */
-		Vector2I windowToScreenPos(const Vector2I& windowPos) const override;
-
-		/** @copydoc RenderWindow::getCore */
-		SPtr<D3D11RenderWindowCore> getCore() const;
-
-	protected:
-		friend class D3D11RenderWindowManager;
-		friend class D3D11RenderWindowCore;
-
-		D3D11RenderWindow(const RENDER_WINDOW_DESC& desc, UINT32 windowId, 
-			D3D11Device& device, IDXGIFactory* DXGIFactory);
-
-		/** @copydoc RenderWindowCore::getProperties */
-		const RenderTargetProperties& getPropertiesInternal() const override { return mProperties; }
-
-		/** @copydoc RenderWindow::syncProperties */
-		void syncProperties() override;
-
-		/**	Retrieves internal window handle. */
-		HWND getHWnd() const;
-
-	private:
-		D3D11Device& mDevice;
-		IDXGIFactory* mDXGIFactory;
-		D3D11RenderWindowProperties mProperties;
-	};
 	
 	/** @} */
 }}

+ 12 - 8
Source/BansheeD3D11RenderAPI/Include/BsD3D11RenderWindowManager.h

@@ -5,7 +5,7 @@
 #include "BsD3D11Prerequisites.h"
 #include "BsRenderWindowManager.h"
 
-namespace bs { namespace ct
+namespace bs
 {
 	/** @addtogroup D3D11
 	 *  @{
@@ -15,29 +15,33 @@ namespace bs { namespace ct
 	class BS_D3D11_EXPORT D3D11RenderWindowManager : public RenderWindowManager
 	{
 	public:
-		D3D11RenderWindowManager(D3D11RenderAPI* renderSystem);
+		D3D11RenderWindowManager(ct::D3D11RenderAPI* renderSystem);
 
 	protected:
 		/** @copydoc RenderWindowManager::createImpl */
-		SPtr<RenderWindow> createImpl(RENDER_WINDOW_DESC& desc, UINT32 windowId, const SPtr<RenderWindow>& parentWindow) override;
+		SPtr<RenderWindow> createImpl(RENDER_WINDOW_DESC& desc, UINT32 windowId, 
+			const SPtr<RenderWindow>& parentWindow) override;
 
 	private:
-		D3D11RenderAPI* mRenderSystem;
+		ct::D3D11RenderAPI* mRenderSystem;
 	};
 
+	namespace ct
+	{
 	/** @copydoc RenderWindowCoreManager */
-	class BS_D3D11_EXPORT D3D11RenderWindowCoreManager : public RenderWindowCoreManager
+	class BS_D3D11_EXPORT D3D11RenderWindowManager : public RenderWindowCoreManager
 	{
 	public:
-		D3D11RenderWindowCoreManager(D3D11RenderAPI* renderSystem);
+		D3D11RenderWindowManager(D3D11RenderAPI* renderSystem);
 
 	protected:
 		/** @copydoc RenderWindowCoreManager::createInternal */
-		virtual SPtr<RenderWindowCore> createInternal(RENDER_WINDOW_DESC& desc, UINT32 windowId) override;
+		SPtr<RenderWindowCore> createInternal(RENDER_WINDOW_DESC& desc, UINT32 windowId) override;
 
 	private:
 		D3D11RenderAPI* mRenderSystem;
 	};
+	}
 
 	/** @} */
-}}
+}

+ 4 - 4
Source/BansheeD3D11RenderAPI/Include/BsD3D11SamplerState.h

@@ -12,16 +12,16 @@ namespace bs { namespace ct
 	 */
 
 	/**	DirectX 11 implementation of a sampler state. Wraps a DX11 sampler state object. */
-	class BS_D3D11_EXPORT D3D11SamplerStateCore : public SamplerStateCore
+	class BS_D3D11_EXPORT D3D11SamplerState : public SamplerStateCore
 	{
 	public:
-		~D3D11SamplerStateCore();
+		~D3D11SamplerState();
 		ID3D11SamplerState* getInternal() const { return mSamplerState; }
 
 	protected:
-		friend class D3D11RenderStateCoreManager;
+		friend class D3D11RenderStateManager;
 
-		D3D11SamplerStateCore(const SAMPLER_STATE_DESC& desc, GpuDeviceFlags deviceMask);
+		D3D11SamplerState(const SAMPLER_STATE_DESC& desc, GpuDeviceFlags deviceMask);
 
 		/** @copydoc SamplerStateCore::createInternal */
 		void createInternal() override;

+ 4 - 4
Source/BansheeD3D11RenderAPI/Include/BsD3D11Texture.h

@@ -12,10 +12,10 @@ namespace bs { namespace ct
 	 */
 
 	/**	DirectX 11 implementation of a texture. */
-	class D3D11TextureCore : public TextureCore
+	class D3D11Texture : public TextureCore
 	{
 	public:
-		~D3D11TextureCore();
+		~D3D11Texture();
 
 		/**	Returns internal DX11 texture resource object. */
 		ID3D11Resource* getDX11Resource() const { return mTex; }
@@ -33,9 +33,9 @@ namespace bs { namespace ct
 		DXGI_FORMAT getDepthStencilFormat() const { return mDXGIDepthStencilFormat; }
 
 	protected:
-		friend class D3D11TextureCoreManager;
+		friend class D3D11TextureManager;
 
-		D3D11TextureCore(const TEXTURE_DESC& desc, const SPtr<PixelData>& initialData, GpuDeviceFlags deviceMask);
+		D3D11Texture(const TEXTURE_DESC& desc, const SPtr<PixelData>& initialData, GpuDeviceFlags deviceMask);
 
 		/** @copydoc CoreObjectCore::initialize() */
 		void initialize() override;

+ 6 - 3
Source/BansheeD3D11RenderAPI/Include/BsD3D11TextureManager.h

@@ -5,7 +5,7 @@
 #include "BsD3D11Prerequisites.h"
 #include "BsTextureManager.h"
 
-namespace bs { namespace ct
+namespace bs
 {
 	/** @addtogroup D3D11
 	 *  @{
@@ -23,8 +23,10 @@ namespace bs { namespace ct
 		SPtr<RenderTexture> createRenderTextureImpl(const RENDER_TEXTURE_DESC& desc) override;
 	};
 
+	namespace ct
+	{
 	/**	Handles creation of DirectX 11 textures. */
-	class BS_D3D11_EXPORT D3D11TextureCoreManager : public TextureCoreManager
+	class BS_D3D11_EXPORT D3D11TextureManager : public TextureCoreManager
 	{
 	protected:
 		/** @copydoc TextureCoreManager::createTextureInternal */
@@ -35,6 +37,7 @@ namespace bs { namespace ct
 		SPtr<RenderTextureCore> createRenderTextureInternal(const RENDER_TEXTURE_DESC_CORE& desc, 
 			UINT32 deviceIdx = 0) override;
 	};
+	}
 
 	/** @} */
-}}
+}

+ 5 - 5
Source/BansheeD3D11RenderAPI/Include/BsD3D11TextureView.h

@@ -45,7 +45,7 @@ namespace bs { namespace ct
 		ID3D11DepthStencilView*	getDSV(bool readOnly) const { return readOnly ? mRODSV : mDSV; }
 
 	protected:
-		friend class D3D11TextureCore;
+		friend class D3D11Texture;
 
 		D3D11TextureView(const SPtr<TextureCore>& texture, const TEXTURE_VIEW_DESC& desc);
 	private:
@@ -62,7 +62,7 @@ namespace bs { namespace ct
 		 *								for 1D and 2D array textures, number of slices for 3D textures, and number of cubes
 		 *								for cube textures.
 		 */
-		ID3D11ShaderResourceView* createSRV(D3D11TextureCore* texture, 
+		ID3D11ShaderResourceView* createSRV(D3D11Texture* texture, 
 			UINT32 mostDetailMip, UINT32 numMips, UINT32 firstArraySlice, UINT32 numArraySlices);
 
 		/**
@@ -77,7 +77,7 @@ namespace bs { namespace ct
 		 *								for 1D and 2D array textures, number of slices for 3D textures, and number of cubes
 		 *								for cube textures.
 		 */
-		ID3D11RenderTargetView* createRTV(D3D11TextureCore* texture, 
+		ID3D11RenderTargetView* createRTV(D3D11Texture* texture, 
 			UINT32 mipSlice, UINT32 firstArraySlice, UINT32 numArraySlices);
 
 		/**
@@ -92,7 +92,7 @@ namespace bs { namespace ct
 		 *								for 1D and 2D array textures, number of slices for 3D textures, and number of cubes
 		 *								for cube textures.
 		 */
-		ID3D11UnorderedAccessView* createUAV(D3D11TextureCore* texture, 
+		ID3D11UnorderedAccessView* createUAV(D3D11Texture* texture, 
 			UINT32 mipSlice, UINT32 firstArraySlice, UINT32 numArraySlices);
 
 		/**
@@ -109,7 +109,7 @@ namespace bs { namespace ct
 		 * @param[in]	readOnly		Should the depth stencil view only support read operations (allows the bound texture
 		 *								to be also used as a shader resource view while bound as a depth stencil target).
 		 */
-		ID3D11DepthStencilView* createDSV(D3D11TextureCore* texture, 
+		ID3D11DepthStencilView* createDSV(D3D11Texture* texture, 
 			UINT32 mipSlice, UINT32 firstArraySlice, UINT32 numArraySlices, bool readOnly);
 
 		ID3D11ShaderResourceView* mSRV;

+ 3 - 3
Source/BansheeD3D11RenderAPI/Include/BsD3D11VertexBuffer.h

@@ -13,12 +13,12 @@ namespace bs { namespace ct
 	 */
 
 	/**	DirectX 11 implementation of a vertex buffer. */
-	class BS_D3D11_EXPORT D3D11VertexBufferCore : public VertexBufferCore
+	class BS_D3D11_EXPORT D3D11VertexBuffer : public VertexBufferCore
 	{
 	public:
-		D3D11VertexBufferCore(D3D11Device& device, const VERTEX_BUFFER_DESC& desc, GpuDeviceFlags deviceMask);
+		D3D11VertexBuffer(D3D11Device& device, const VERTEX_BUFFER_DESC& desc, GpuDeviceFlags deviceMask);
 
-		~D3D11VertexBufferCore();
+		~D3D11VertexBuffer();
 
 		/** @copydoc VertexBufferCore::readData */
 		void readData(UINT32 offset, UINT32 length, void* dest, UINT32 deviceIdx = 0, UINT32 queueIdx = 0) override;

+ 3 - 3
Source/BansheeD3D11RenderAPI/Source/BsD3D11BlendState.cpp

@@ -8,18 +8,18 @@
 
 namespace bs { namespace ct
 {
-	D3D11BlendStateCore::D3D11BlendStateCore(const BLEND_STATE_DESC& desc, UINT32 id)
+	D3D11BlendState::D3D11BlendState(const BLEND_STATE_DESC& desc, UINT32 id)
 		:BlendStateCore(desc, id), mBlendState(nullptr)
 	{ }
 
-	D3D11BlendStateCore::~D3D11BlendStateCore()
+	D3D11BlendState::~D3D11BlendState()
 	{
 		SAFE_RELEASE(mBlendState);
 
 		BS_INC_RENDER_STAT_CAT(ResDestroyed, RenderStatObject_BlendState);
 	}
 
-	void D3D11BlendStateCore::createInternal()
+	void D3D11BlendState::createInternal()
 	{
 		D3D11_BLEND_DESC blendStateDesc;
 		ZeroMemory(&blendStateDesc, sizeof(D3D11_BLEND_DESC));

+ 3 - 3
Source/BansheeD3D11RenderAPI/Source/BsD3D11DepthStencilState.cpp

@@ -8,18 +8,18 @@
 
 namespace bs { namespace ct
 {
-	D3D11DepthStencilStateCore::D3D11DepthStencilStateCore(const DEPTH_STENCIL_STATE_DESC& desc, UINT32 id)
+	D3D11DepthStencilState::D3D11DepthStencilState(const DEPTH_STENCIL_STATE_DESC& desc, UINT32 id)
 		:DepthStencilStateCore(desc, id), mDepthStencilState(nullptr)
 	{ }
 
-	D3D11DepthStencilStateCore::~D3D11DepthStencilStateCore()
+	D3D11DepthStencilState::~D3D11DepthStencilState()
 	{
 		SAFE_RELEASE(mDepthStencilState);
 
 		BS_INC_RENDER_STAT_CAT(ResDestroyed, RenderStatObject_DepthStencilState);
 	}
 
-	void D3D11DepthStencilStateCore::createInternal()
+	void D3D11DepthStencilState::createInternal()
 	{
 		D3D11_DEPTH_STENCIL_DESC depthStencilState;
 		ZeroMemory(&depthStencilState, sizeof(D3D11_DEPTH_STENCIL_DESC));

+ 17 - 17
Source/BansheeD3D11RenderAPI/Source/BsD3D11GpuBuffer.cpp

@@ -11,7 +11,7 @@
 
 namespace bs { namespace ct
 {
-	D3D11GpuBufferCore::D3D11GpuBufferCore(const GPU_BUFFER_DESC& desc, GpuDeviceFlags deviceMask)
+	D3D11GpuBuffer::D3D11GpuBuffer(const GPU_BUFFER_DESC& desc, GpuDeviceFlags deviceMask)
 		: GpuBufferCore(desc, deviceMask), mBuffer(nullptr)
 	{
 		if (desc.type != GBT_STANDARD)
@@ -22,14 +22,14 @@ namespace bs { namespace ct
 		assert((deviceMask == GDF_DEFAULT || deviceMask == GDF_PRIMARY) && "Multiple GPUs not supported natively on DirectX 11.");
 	}
 
-	D3D11GpuBufferCore::~D3D11GpuBufferCore()
+	D3D11GpuBuffer::~D3D11GpuBuffer()
 	{ 
 		bs_delete(mBuffer);
 		clearBufferViews();
 		BS_INC_RENDER_STAT_CAT(ResDestroyed, RenderStatObject_GpuBuffer);
 	}
 
-	void D3D11GpuBufferCore::initialize()
+	void D3D11GpuBuffer::initialize()
 	{
 		D3D11HardwareBuffer::BufferType bufferType;
 		D3D11RenderAPI* d3d11rs = static_cast<D3D11RenderAPI*>(D3D11RenderAPI::instancePtr());
@@ -58,7 +58,7 @@ namespace bs { namespace ct
 		mBuffer = bs_new<D3D11HardwareBuffer>(bufferType, props.getUsage(), props.getElementCount(), props.getElementSize(),
 			d3d11rs->getPrimaryDevice(), false, false, props.getRandomGpuWrite(), props.getUseCounter());
 
-		SPtr<D3D11GpuBufferCore> thisPtr = std::static_pointer_cast<D3D11GpuBufferCore>(getThisPtr());
+		SPtr<D3D11GpuBuffer> thisPtr = std::static_pointer_cast<D3D11GpuBuffer>(getThisPtr());
 		UINT32 usage = GVU_DEFAULT;
 		if (props.getRandomGpuWrite())
 			usage |= GVU_RANDOMWRITE;
@@ -71,7 +71,7 @@ namespace bs { namespace ct
 		GpuBufferCore::initialize();
 	}
 
-	void* D3D11GpuBufferCore::lock(UINT32 offset, UINT32 length, GpuLockOptions options, UINT32 deviceIdx, UINT32 queueIdx)
+	void* D3D11GpuBuffer::lock(UINT32 offset, UINT32 length, GpuLockOptions options, UINT32 deviceIdx, UINT32 queueIdx)
 	{
 #if BS_PROFILING_ENABLED
 		if (options == GBL_READ_ONLY || options == GBL_READ_WRITE)
@@ -88,19 +88,19 @@ namespace bs { namespace ct
 		return mBuffer->lock(offset, length, options);
 	}
 
-	void D3D11GpuBufferCore::unlock()
+	void D3D11GpuBuffer::unlock()
 	{
 		mBuffer->unlock();
 	}
 
-	void D3D11GpuBufferCore::readData(UINT32 offset, UINT32 length, void* dest, UINT32 deviceIdx, UINT32 queueIdx)
+	void D3D11GpuBuffer::readData(UINT32 offset, UINT32 length, void* dest, UINT32 deviceIdx, UINT32 queueIdx)
 	{
 		BS_INC_RENDER_STAT_CAT(ResRead, RenderStatObject_GpuBuffer);
 
 		mBuffer->readData(offset, length, dest);
 	}
 
-	void D3D11GpuBufferCore::writeData(UINT32 offset, UINT32 length, const void* source, BufferWriteType writeFlags, 
+	void D3D11GpuBuffer::writeData(UINT32 offset, UINT32 length, const void* source, BufferWriteType writeFlags, 
 		UINT32 queueIdx)
 	{
 		BS_INC_RENDER_STAT_CAT(ResWrite, RenderStatObject_GpuBuffer);
@@ -108,20 +108,20 @@ namespace bs { namespace ct
 		mBuffer->writeData(offset, length, source, writeFlags);
 	}
 
-	void D3D11GpuBufferCore::copyData(HardwareBuffer& srcBuffer, UINT32 srcOffset,
+	void D3D11GpuBuffer::copyData(HardwareBuffer& srcBuffer, UINT32 srcOffset,
 		UINT32 dstOffset, UINT32 length, bool discardWholeBuffer, UINT32 queueIdx)
 	{
-		D3D11GpuBufferCore* d3d11SrcBuffer = static_cast<D3D11GpuBufferCore*>(&srcBuffer);
+		D3D11GpuBuffer* d3d11SrcBuffer = static_cast<D3D11GpuBuffer*>(&srcBuffer);
 
 		mBuffer->copyData(*d3d11SrcBuffer->mBuffer, srcOffset, dstOffset, length, discardWholeBuffer);
 	}
 
-	ID3D11Buffer* D3D11GpuBufferCore::getDX11Buffer() const
+	ID3D11Buffer* D3D11GpuBuffer::getDX11Buffer() const
 	{ 
 		return mBuffer->getD3DBuffer(); 
 	}
 
-	GpuBufferView* D3D11GpuBufferCore::requestView(const SPtr<D3D11GpuBufferCore>& buffer, UINT32 firstElement,
+	GpuBufferView* D3D11GpuBuffer::requestView(const SPtr<D3D11GpuBuffer>& buffer, UINT32 firstElement,
 		UINT32 numElements, GpuViewUsage usage)
 	{
 		const auto& props = buffer->getProperties();
@@ -148,9 +148,9 @@ namespace bs { namespace ct
 		return iterFind->second->view;
 	}
 
-	void D3D11GpuBufferCore::releaseView(GpuBufferView* view)
+	void D3D11GpuBuffer::releaseView(GpuBufferView* view)
 	{
-		SPtr<D3D11GpuBufferCore> buffer = view->getBuffer();
+		SPtr<D3D11GpuBuffer> buffer = view->getBuffer();
 
 		auto iterFind = buffer->mBufferViews.find(view->getDesc());
 		if (iterFind == buffer->mBufferViews.end())
@@ -173,7 +173,7 @@ namespace bs { namespace ct
 		}
 	}
 
-	void D3D11GpuBufferCore::clearBufferViews()
+	void D3D11GpuBuffer::clearBufferViews()
 	{
 		for (auto iter = mBufferViews.begin(); iter != mBufferViews.end(); ++iter)
 		{
@@ -186,12 +186,12 @@ namespace bs { namespace ct
 		mBufferViews.clear();
 	}
 
-	ID3D11ShaderResourceView* D3D11GpuBufferCore::getSRV() const
+	ID3D11ShaderResourceView* D3D11GpuBuffer::getSRV() const
 	{
 		return mBufferView->getSRV();
 	}
 
-	ID3D11UnorderedAccessView* D3D11GpuBufferCore::getUAV() const
+	ID3D11UnorderedAccessView* D3D11GpuBuffer::getUAV() const
 	{
 		return mBufferView->getUAV();
 	}

+ 5 - 4
Source/BansheeD3D11RenderAPI/Source/BsD3D11GpuBufferView.cpp

@@ -43,12 +43,12 @@ namespace bs { namespace ct
 		BS_INC_RENDER_STAT_CAT(ResDestroyed, RenderStatObject_ResourceView);
 	}
 
-	void GpuBufferView::initialize(const SPtr<D3D11GpuBufferCore>& buffer, GPU_BUFFER_VIEW_DESC& desc)
+	void GpuBufferView::initialize(const SPtr<D3D11GpuBuffer>& buffer, GPU_BUFFER_VIEW_DESC& desc)
 	{
 		mBuffer = buffer;
 		mDesc = desc;
 
-		D3D11GpuBufferCore* d3d11GpuBuffer = static_cast<D3D11GpuBufferCore*>(buffer.get());
+		D3D11GpuBuffer* d3d11GpuBuffer = static_cast<D3D11GpuBuffer*>(buffer.get());
 
 		if ((desc.usage & GVU_DEFAULT) != 0)
 			mSRV = createSRV(d3d11GpuBuffer, desc.firstElement, desc.elementWidth, desc.numElements);
@@ -64,7 +64,7 @@ namespace bs { namespace ct
 		BS_INC_RENDER_STAT_CAT(ResCreated, RenderStatObject_ResourceView);
 	}
 
-	ID3D11ShaderResourceView* GpuBufferView::createSRV(D3D11GpuBufferCore* buffer, UINT32 firstElement, UINT32 elementWidth, UINT32 numElements)
+	ID3D11ShaderResourceView* GpuBufferView::createSRV(D3D11GpuBuffer* buffer, UINT32 firstElement, UINT32 elementWidth, UINT32 numElements)
 	{
 		const GpuBufferProperties& props = buffer->getProperties();
 
@@ -111,7 +111,8 @@ namespace bs { namespace ct
 		return srv;
 	}
 
-	ID3D11UnorderedAccessView* GpuBufferView::createUAV(D3D11GpuBufferCore* buffer, UINT32 firstElement, UINT32 numElements, bool useCounter)
+	ID3D11UnorderedAccessView* GpuBufferView::createUAV(D3D11GpuBuffer* buffer, UINT32 firstElement, UINT32 numElements, 
+		bool useCounter)
 	{
 		const GpuBufferProperties& props = buffer->getProperties();
 

+ 5 - 5
Source/BansheeD3D11RenderAPI/Source/BsD3D11GpuParamBlockBuffer.cpp

@@ -8,14 +8,14 @@
 
 namespace bs { namespace ct
 {
-	D3D11GpuParamBlockBufferCore::D3D11GpuParamBlockBufferCore(UINT32 size, GpuParamBlockUsage usage, 
+	D3D11GpuParamBlockBuffer::D3D11GpuParamBlockBuffer(UINT32 size, GpuParamBlockUsage usage, 
 		GpuDeviceFlags deviceMask)
 		:GpuParamBlockBufferCore(size, usage, deviceMask), mBuffer(nullptr)
 	{
 		assert((deviceMask == GDF_DEFAULT || deviceMask == GDF_PRIMARY) && "Multiple GPUs not supported natively on DirectX 11.");
 	}
 
-	D3D11GpuParamBlockBufferCore::~D3D11GpuParamBlockBufferCore()
+	D3D11GpuParamBlockBuffer::~D3D11GpuParamBlockBuffer()
 	{
 		if (mBuffer != nullptr)
 			bs_delete(mBuffer);
@@ -23,7 +23,7 @@ namespace bs { namespace ct
 		BS_INC_RENDER_STAT_CAT(ResDestroyed, RenderStatObject_GpuParamBuffer);
 	}
 
-	void D3D11GpuParamBlockBufferCore::initialize()
+	void D3D11GpuParamBlockBuffer::initialize()
 	{
 		D3D11RenderAPI* d3d11rs = static_cast<D3D11RenderAPI*>(RenderAPICore::instancePtr());
 		D3D11Device& device = d3d11rs->getPrimaryDevice();
@@ -41,12 +41,12 @@ namespace bs { namespace ct
 	}
 
 
-	ID3D11Buffer* D3D11GpuParamBlockBufferCore::getD3D11Buffer() const
+	ID3D11Buffer* D3D11GpuParamBlockBuffer::getD3D11Buffer() const
 	{
 		return mBuffer->getD3DBuffer();
 	}
 
-	void D3D11GpuParamBlockBufferCore::writeToGPU(const UINT8* data, UINT32 queueIdx)
+	void D3D11GpuParamBlockBuffer::writeToGPU(const UINT8* data, UINT32 queueIdx)
 	{
 		mBuffer->writeData(0, mSize, data, BWT_DISCARD);
 

+ 37 - 37
Source/BansheeD3D11RenderAPI/Source/BsD3D11GpuProgram.cpp

@@ -14,16 +14,16 @@
 
 namespace bs { namespace ct
 {
-	UINT32 D3D11GpuProgramCore::GlobalProgramId = 0;
+	UINT32 D3D11GpuProgram::GlobalProgramId = 0;
 
-	D3D11GpuProgramCore::D3D11GpuProgramCore(const GPU_PROGRAM_DESC& desc, GpuDeviceFlags deviceMask)
+	D3D11GpuProgram::D3D11GpuProgram(const GPU_PROGRAM_DESC& desc, GpuDeviceFlags deviceMask)
 		: GpuProgramCore(desc, deviceMask),
 		mEnableBackwardsCompatibility(false), mProgramId(0)
 	{
 		assert((deviceMask == GDF_DEFAULT || deviceMask == GDF_PRIMARY) && "Multiple GPUs not supported natively on DirectX 11.");
 	}
 
-	D3D11GpuProgramCore::~D3D11GpuProgramCore()
+	D3D11GpuProgram::~D3D11GpuProgram()
 	{
 		mMicrocode.clear();
 		mInputDeclaration = nullptr;
@@ -31,7 +31,7 @@ namespace bs { namespace ct
 		BS_INC_RENDER_STAT_CAT(ResDestroyed, RenderStatObject_GpuProgram);
 	}
 
-	void D3D11GpuProgramCore::initialize()
+	void D3D11GpuProgram::initialize()
 	{
 		if (!isSupported())
 		{
@@ -86,7 +86,7 @@ namespace bs { namespace ct
 		GpuProgramCore::initialize();
 	}
 
-	UINT32 D3D11GpuProgramCore::parseErrorMessage(const char* message)
+	UINT32 D3D11GpuProgram::parseErrorMessage(const char* message)
 	{
 		if (message == nullptr)
 			return 0;
@@ -105,7 +105,7 @@ namespace bs { namespace ct
 		return 0;
 	}
 
-	ID3DBlob* D3D11GpuProgramCore::compileMicrocode(const String& profile)
+	ID3DBlob* D3D11GpuProgram::compileMicrocode(const String& profile)
 	{
 		UINT compileFlags = 0;
 #if defined(BS_DEBUG_MODE)
@@ -168,7 +168,7 @@ namespace bs { namespace ct
 		}
 	}
 
-	void D3D11GpuProgramCore::populateParametersAndConstants(ID3DBlob* microcode)
+	void D3D11GpuProgram::populateParametersAndConstants(ID3DBlob* microcode)
 	{
 		assert(microcode != nullptr);
 
@@ -186,16 +186,16 @@ namespace bs { namespace ct
 		}
 	}
 
-	D3D11GpuVertexProgramCore::D3D11GpuVertexProgramCore(const GPU_PROGRAM_DESC& desc, GpuDeviceFlags deviceMask)
-		: D3D11GpuProgramCore(desc, deviceMask), mVertexShader(nullptr)
+	D3D11GpuVertexProgram::D3D11GpuVertexProgram(const GPU_PROGRAM_DESC& desc, GpuDeviceFlags deviceMask)
+		: D3D11GpuProgram(desc, deviceMask), mVertexShader(nullptr)
 	{ }
 
-	D3D11GpuVertexProgramCore::~D3D11GpuVertexProgramCore()
+	D3D11GpuVertexProgram::~D3D11GpuVertexProgram()
 	{
 		SAFE_RELEASE(mVertexShader);
 	}
 
-	void D3D11GpuVertexProgramCore::loadFromMicrocode(D3D11Device& device, ID3D10Blob*  microcode)
+	void D3D11GpuVertexProgram::loadFromMicrocode(D3D11Device& device, ID3D10Blob*  microcode)
 	{
 		HRESULT hr = device.getD3D11Device()->CreateVertexShader( 
 			static_cast<DWORD*>(microcode->GetBufferPointer()), microcode->GetBufferSize(),
@@ -210,21 +210,21 @@ namespace bs { namespace ct
 		}
 	}
 
-	ID3D11VertexShader * D3D11GpuVertexProgramCore::getVertexShader() const
+	ID3D11VertexShader * D3D11GpuVertexProgram::getVertexShader() const
 	{
 		return mVertexShader;
 	}
 
-	D3D11GpuFragmentProgramCore::D3D11GpuFragmentProgramCore(const GPU_PROGRAM_DESC& desc, GpuDeviceFlags deviceMask)
-		: D3D11GpuProgramCore(desc, deviceMask), mPixelShader(nullptr)
+	D3D11GpuFragmentProgram::D3D11GpuFragmentProgram(const GPU_PROGRAM_DESC& desc, GpuDeviceFlags deviceMask)
+		: D3D11GpuProgram(desc, deviceMask), mPixelShader(nullptr)
 	{ }
 
-	D3D11GpuFragmentProgramCore::~D3D11GpuFragmentProgramCore()
+	D3D11GpuFragmentProgram::~D3D11GpuFragmentProgram()
 	{
 		SAFE_RELEASE(mPixelShader);
 	}
 
-	void D3D11GpuFragmentProgramCore::loadFromMicrocode(D3D11Device& device, ID3D10Blob* microcode)
+	void D3D11GpuFragmentProgram::loadFromMicrocode(D3D11Device& device, ID3D10Blob* microcode)
 	{
 		HRESULT hr = device.getD3D11Device()->CreatePixelShader(
 			static_cast<DWORD*>(microcode->GetBufferPointer()), microcode->GetBufferSize(),
@@ -238,22 +238,22 @@ namespace bs { namespace ct
 		}
 	}
 
-	ID3D11PixelShader * D3D11GpuFragmentProgramCore::getPixelShader() const
+	ID3D11PixelShader * D3D11GpuFragmentProgram::getPixelShader() const
 	{
 		return mPixelShader;
 	}
 
 
-	D3D11GpuGeometryProgramCore::D3D11GpuGeometryProgramCore(const GPU_PROGRAM_DESC& desc, GpuDeviceFlags deviceMask)
-		: D3D11GpuProgramCore(desc, deviceMask), mGeometryShader(nullptr)
+	D3D11GpuGeometryProgram::D3D11GpuGeometryProgram(const GPU_PROGRAM_DESC& desc, GpuDeviceFlags deviceMask)
+		: D3D11GpuProgram(desc, deviceMask), mGeometryShader(nullptr)
 	{ }
 
-	D3D11GpuGeometryProgramCore::~D3D11GpuGeometryProgramCore()
+	D3D11GpuGeometryProgram::~D3D11GpuGeometryProgram()
 	{ 
 		SAFE_RELEASE(mGeometryShader);
 	}
 
-	void D3D11GpuGeometryProgramCore::loadFromMicrocode(D3D11Device& device, ID3D10Blob* microcode)
+	void D3D11GpuGeometryProgram::loadFromMicrocode(D3D11Device& device, ID3D10Blob* microcode)
 	{
 		HRESULT hr = device.getD3D11Device()->CreateGeometryShader(
 			static_cast<DWORD*>(microcode->GetBufferPointer()), microcode->GetBufferSize(),
@@ -267,21 +267,21 @@ namespace bs { namespace ct
 		}
 	}
 
-	ID3D11GeometryShader * D3D11GpuGeometryProgramCore::getGeometryShader() const
+	ID3D11GeometryShader * D3D11GpuGeometryProgram::getGeometryShader() const
 	{
 		return mGeometryShader;
 	}
 
-	D3D11GpuDomainProgramCore::D3D11GpuDomainProgramCore(const GPU_PROGRAM_DESC& desc, GpuDeviceFlags deviceMask)
-		: D3D11GpuProgramCore(desc, deviceMask), mDomainShader(nullptr)
+	D3D11GpuDomainProgram::D3D11GpuDomainProgram(const GPU_PROGRAM_DESC& desc, GpuDeviceFlags deviceMask)
+		: D3D11GpuProgram(desc, deviceMask), mDomainShader(nullptr)
 	{ }
 
-	D3D11GpuDomainProgramCore::~D3D11GpuDomainProgramCore()
+	D3D11GpuDomainProgram::~D3D11GpuDomainProgram()
 	{ 
 		SAFE_RELEASE(mDomainShader);
 	}
 
-	void D3D11GpuDomainProgramCore::loadFromMicrocode(D3D11Device& device, ID3D10Blob* microcode)
+	void D3D11GpuDomainProgram::loadFromMicrocode(D3D11Device& device, ID3D10Blob* microcode)
 	{
 		HRESULT hr = device.getD3D11Device()->CreateDomainShader(
 			static_cast<DWORD*>(microcode->GetBufferPointer()), microcode->GetBufferSize(),
@@ -295,21 +295,21 @@ namespace bs { namespace ct
 		}
 	}
 
-	ID3D11DomainShader * D3D11GpuDomainProgramCore::getDomainShader() const
+	ID3D11DomainShader * D3D11GpuDomainProgram::getDomainShader() const
 	{
 		return mDomainShader;
 	}
 
-	D3D11GpuHullProgramCore::D3D11GpuHullProgramCore(const GPU_PROGRAM_DESC& desc, GpuDeviceFlags deviceMask)
-		: D3D11GpuProgramCore(desc, deviceMask), mHullShader(nullptr)
+	D3D11GpuHullProgram::D3D11GpuHullProgram(const GPU_PROGRAM_DESC& desc, GpuDeviceFlags deviceMask)
+		: D3D11GpuProgram(desc, deviceMask), mHullShader(nullptr)
 	{ }
 
-	D3D11GpuHullProgramCore::~D3D11GpuHullProgramCore()
+	D3D11GpuHullProgram::~D3D11GpuHullProgram()
 	{ 
 		SAFE_RELEASE(mHullShader);
 	}
 
-	void D3D11GpuHullProgramCore::loadFromMicrocode(D3D11Device& device, ID3D10Blob* microcode)
+	void D3D11GpuHullProgram::loadFromMicrocode(D3D11Device& device, ID3D10Blob* microcode)
 	{
 		// Create the shader
 		HRESULT hr = device.getD3D11Device()->CreateHullShader(
@@ -324,22 +324,22 @@ namespace bs { namespace ct
 		}
 	}
 
-	ID3D11HullShader* D3D11GpuHullProgramCore::getHullShader() const
+	ID3D11HullShader* D3D11GpuHullProgram::getHullShader() const
 	{
 		return mHullShader;
 	}
 
 
-	D3D11GpuComputeProgramCore::D3D11GpuComputeProgramCore(const GPU_PROGRAM_DESC& desc, GpuDeviceFlags deviceMask)
-		: D3D11GpuProgramCore(desc, deviceMask), mComputeShader(nullptr)
+	D3D11GpuComputeProgram::D3D11GpuComputeProgram(const GPU_PROGRAM_DESC& desc, GpuDeviceFlags deviceMask)
+		: D3D11GpuProgram(desc, deviceMask), mComputeShader(nullptr)
 	{ }
 
-	D3D11GpuComputeProgramCore::~D3D11GpuComputeProgramCore()
+	D3D11GpuComputeProgram::~D3D11GpuComputeProgram()
 	{
 		SAFE_RELEASE(mComputeShader);
 	}
 
-	void D3D11GpuComputeProgramCore::loadFromMicrocode(D3D11Device& device, ID3D10Blob* microcode)
+	void D3D11GpuComputeProgram::loadFromMicrocode(D3D11Device& device, ID3D10Blob* microcode)
 	{
 		HRESULT hr = device.getD3D11Device()->CreateComputeShader(
 			static_cast<DWORD*>(microcode->GetBufferPointer()), microcode->GetBufferSize(),
@@ -353,7 +353,7 @@ namespace bs { namespace ct
 		}
 	}
 
-	ID3D11ComputeShader* D3D11GpuComputeProgramCore::getComputeShader() const
+	ID3D11ComputeShader* D3D11GpuComputeProgram::getComputeShader() const
 	{
 		return mComputeShader;
 	}

+ 24 - 24
Source/BansheeD3D11RenderAPI/Source/BsD3D11HLSLProgramFactory.cpp

@@ -27,28 +27,28 @@ namespace bs { namespace ct
 		switch (desc.type)
 		{
 		case GPT_VERTEX_PROGRAM:
-			gpuProg = bs_shared_ptr<D3D11GpuVertexProgramCore>(new (bs_alloc<D3D11GpuVertexProgramCore>())
-				D3D11GpuVertexProgramCore(desc, deviceMask));
+			gpuProg = bs_shared_ptr<D3D11GpuVertexProgram>(new (bs_alloc<D3D11GpuVertexProgram>())
+				D3D11GpuVertexProgram(desc, deviceMask));
 			break;
 		case GPT_FRAGMENT_PROGRAM:
-			gpuProg = bs_shared_ptr<D3D11GpuFragmentProgramCore>(new (bs_alloc<D3D11GpuFragmentProgramCore>())
-				D3D11GpuFragmentProgramCore(desc, deviceMask));
+			gpuProg = bs_shared_ptr<D3D11GpuFragmentProgram>(new (bs_alloc<D3D11GpuFragmentProgram>())
+				D3D11GpuFragmentProgram(desc, deviceMask));
 			break;
 		case GPT_HULL_PROGRAM:
-			gpuProg = bs_shared_ptr<D3D11GpuHullProgramCore>(new (bs_alloc<D3D11GpuHullProgramCore>())
-				D3D11GpuHullProgramCore(desc, deviceMask));
+			gpuProg = bs_shared_ptr<D3D11GpuHullProgram>(new (bs_alloc<D3D11GpuHullProgram>())
+				D3D11GpuHullProgram(desc, deviceMask));
 			break;
 		case GPT_DOMAIN_PROGRAM:
-			gpuProg = bs_shared_ptr<D3D11GpuDomainProgramCore>(new (bs_alloc<D3D11GpuDomainProgramCore>())
-				D3D11GpuDomainProgramCore(desc, deviceMask));
+			gpuProg = bs_shared_ptr<D3D11GpuDomainProgram>(new (bs_alloc<D3D11GpuDomainProgram>())
+				D3D11GpuDomainProgram(desc, deviceMask));
 			break;
 		case GPT_GEOMETRY_PROGRAM:
-			gpuProg = bs_shared_ptr<D3D11GpuGeometryProgramCore>(new (bs_alloc<D3D11GpuGeometryProgramCore>())
-				D3D11GpuGeometryProgramCore(desc, deviceMask));
+			gpuProg = bs_shared_ptr<D3D11GpuGeometryProgram>(new (bs_alloc<D3D11GpuGeometryProgram>())
+				D3D11GpuGeometryProgram(desc, deviceMask));
 			break;
 		case GPT_COMPUTE_PROGRAM:
-			gpuProg = bs_shared_ptr<D3D11GpuComputeProgramCore>(new (bs_alloc<D3D11GpuComputeProgramCore>())
-				D3D11GpuComputeProgramCore(desc, deviceMask));
+			gpuProg = bs_shared_ptr<D3D11GpuComputeProgram>(new (bs_alloc<D3D11GpuComputeProgram>())
+				D3D11GpuComputeProgram(desc, deviceMask));
 			break;
 		}
 
@@ -68,28 +68,28 @@ namespace bs { namespace ct
 		switch (type)
 		{
 		case GPT_VERTEX_PROGRAM:
-			gpuProg = bs_shared_ptr<D3D11GpuVertexProgramCore>(new (bs_alloc<D3D11GpuVertexProgramCore>())
-				D3D11GpuVertexProgramCore(desc, deviceMask));
+			gpuProg = bs_shared_ptr<D3D11GpuVertexProgram>(new (bs_alloc<D3D11GpuVertexProgram>())
+				D3D11GpuVertexProgram(desc, deviceMask));
 			break;
 		case GPT_FRAGMENT_PROGRAM:
-			gpuProg = bs_shared_ptr<D3D11GpuFragmentProgramCore>(new (bs_alloc<D3D11GpuFragmentProgramCore>())
-				D3D11GpuFragmentProgramCore(desc, deviceMask));
+			gpuProg = bs_shared_ptr<D3D11GpuFragmentProgram>(new (bs_alloc<D3D11GpuFragmentProgram>())
+				D3D11GpuFragmentProgram(desc, deviceMask));
 			break;
 		case GPT_HULL_PROGRAM:
-			gpuProg = bs_shared_ptr<D3D11GpuHullProgramCore>(new (bs_alloc<D3D11GpuHullProgramCore>())
-				D3D11GpuHullProgramCore(desc, deviceMask));
+			gpuProg = bs_shared_ptr<D3D11GpuHullProgram>(new (bs_alloc<D3D11GpuHullProgram>())
+				D3D11GpuHullProgram(desc, deviceMask));
 			break;
 		case GPT_DOMAIN_PROGRAM:
-			gpuProg = bs_shared_ptr<D3D11GpuDomainProgramCore>(new (bs_alloc<D3D11GpuDomainProgramCore>())
-				D3D11GpuDomainProgramCore(desc, deviceMask));
+			gpuProg = bs_shared_ptr<D3D11GpuDomainProgram>(new (bs_alloc<D3D11GpuDomainProgram>())
+				D3D11GpuDomainProgram(desc, deviceMask));
 			break;
 		case GPT_GEOMETRY_PROGRAM:
-			gpuProg = bs_shared_ptr<D3D11GpuGeometryProgramCore>(new (bs_alloc<D3D11GpuGeometryProgramCore>())
-				D3D11GpuGeometryProgramCore(desc, deviceMask));
+			gpuProg = bs_shared_ptr<D3D11GpuGeometryProgram>(new (bs_alloc<D3D11GpuGeometryProgram>())
+				D3D11GpuGeometryProgram(desc, deviceMask));
 			break;
 		case GPT_COMPUTE_PROGRAM:
-			gpuProg = bs_shared_ptr<D3D11GpuComputeProgramCore>(new (bs_alloc<D3D11GpuComputeProgramCore>())
-				D3D11GpuComputeProgramCore(desc, deviceMask));
+			gpuProg = bs_shared_ptr<D3D11GpuComputeProgram>(new (bs_alloc<D3D11GpuComputeProgram>())
+				D3D11GpuComputeProgram(desc, deviceMask));
 			break;
 		}
 

+ 13 - 13
Source/BansheeD3D11RenderAPI/Source/BsD3D11HardwareBufferManager.cpp

@@ -9,47 +9,47 @@
 
 namespace bs { namespace ct
 {
-	D3D11HardwareBufferCoreManager::D3D11HardwareBufferCoreManager(D3D11Device& device)
+	D3D11HardwareBufferManager::D3D11HardwareBufferManager(D3D11Device& device)
 		: mDevice(device)
 	{ }
 
-	SPtr<VertexBufferCore> D3D11HardwareBufferCoreManager::createVertexBufferInternal(const VERTEX_BUFFER_DESC& desc, 
+	SPtr<VertexBufferCore> D3D11HardwareBufferManager::createVertexBufferInternal(const VERTEX_BUFFER_DESC& desc, 
 		GpuDeviceFlags deviceMask)
 	{
-		SPtr<D3D11VertexBufferCore> ret = bs_shared_ptr_new<D3D11VertexBufferCore>(mDevice, desc, deviceMask);
+		SPtr<D3D11VertexBuffer> ret = bs_shared_ptr_new<D3D11VertexBuffer>(mDevice, desc, deviceMask);
 		ret->_setThisPtr(ret);
 
 		return ret;
 	}
 
-	SPtr<IndexBufferCore> D3D11HardwareBufferCoreManager::createIndexBufferInternal(const INDEX_BUFFER_DESC& desc, 
+	SPtr<IndexBufferCore> D3D11HardwareBufferManager::createIndexBufferInternal(const INDEX_BUFFER_DESC& desc, 
 		GpuDeviceFlags deviceMask)
 	{
-		SPtr<D3D11IndexBufferCore> ret = bs_shared_ptr_new<D3D11IndexBufferCore>(mDevice, desc, deviceMask);
+		SPtr<D3D11IndexBuffer> ret = bs_shared_ptr_new<D3D11IndexBuffer>(mDevice, desc, deviceMask);
 		ret->_setThisPtr(ret);
 
 		return ret;
 	}
 
-	SPtr<GpuParamBlockBufferCore> D3D11HardwareBufferCoreManager::createGpuParamBlockBufferInternal(UINT32 size, 
+	SPtr<GpuParamBlockBufferCore> D3D11HardwareBufferManager::createGpuParamBlockBufferInternal(UINT32 size, 
 		GpuParamBlockUsage usage, GpuDeviceFlags deviceMask)
 	{
-		D3D11GpuParamBlockBufferCore* paramBlockBuffer = 
-			new (bs_alloc<D3D11GpuParamBlockBufferCore>()) D3D11GpuParamBlockBufferCore(size, usage, deviceMask);
+		D3D11GpuParamBlockBuffer* paramBlockBuffer = 
+			new (bs_alloc<D3D11GpuParamBlockBuffer>()) D3D11GpuParamBlockBuffer(size, usage, deviceMask);
 
-		SPtr<GpuParamBlockBufferCore> paramBlockBufferPtr = bs_shared_ptr<D3D11GpuParamBlockBufferCore>(paramBlockBuffer);
+		SPtr<GpuParamBlockBufferCore> paramBlockBufferPtr = bs_shared_ptr<D3D11GpuParamBlockBuffer>(paramBlockBuffer);
 		paramBlockBufferPtr->_setThisPtr(paramBlockBufferPtr);
 
 		return paramBlockBufferPtr;
 	}
 
-	SPtr<GpuBufferCore> D3D11HardwareBufferCoreManager::createGpuBufferInternal(const GPU_BUFFER_DESC& desc,
+	SPtr<GpuBufferCore> D3D11HardwareBufferManager::createGpuBufferInternal(const GPU_BUFFER_DESC& desc,
 		GpuDeviceFlags deviceMask)
 	{
-		D3D11GpuBufferCore* buffer = new (bs_alloc<D3D11GpuBufferCore>()) 
-			D3D11GpuBufferCore(desc, deviceMask);
+		D3D11GpuBuffer* buffer = new (bs_alloc<D3D11GpuBuffer>()) 
+			D3D11GpuBuffer(desc, deviceMask);
 
-		SPtr<D3D11GpuBufferCore> bufferPtr = bs_shared_ptr<D3D11GpuBufferCore>(buffer);
+		SPtr<D3D11GpuBuffer> bufferPtr = bs_shared_ptr<D3D11GpuBuffer>(buffer);
 		bufferPtr->_setThisPtr(bufferPtr);
 
 		return bufferPtr;

+ 8 - 8
Source/BansheeD3D11RenderAPI/Source/BsD3D11IndexBuffer.cpp

@@ -6,14 +6,14 @@
 
 namespace bs { namespace ct
 {
-	D3D11IndexBufferCore::D3D11IndexBufferCore(D3D11Device& device, const INDEX_BUFFER_DESC& desc, 
+	D3D11IndexBuffer::D3D11IndexBuffer(D3D11Device& device, const INDEX_BUFFER_DESC& desc, 
 		GpuDeviceFlags deviceMask)
 		:IndexBufferCore(desc, deviceMask), mBuffer(nullptr), mDevice(device), mUsage(desc.usage)
 	{
 		assert((deviceMask == GDF_DEFAULT || deviceMask == GDF_PRIMARY) && "Multiple GPUs not supported natively on DirectX.");
 	}
 
-	D3D11IndexBufferCore::~D3D11IndexBufferCore()
+	D3D11IndexBuffer::~D3D11IndexBuffer()
 	{
 		if (mBuffer != nullptr)
 			bs_delete(mBuffer);
@@ -21,7 +21,7 @@ namespace bs { namespace ct
 		BS_INC_RENDER_STAT_CAT(ResDestroyed, RenderStatObject_IndexBuffer);
 	}
 
-	void D3D11IndexBufferCore::initialize()
+	void D3D11IndexBuffer::initialize()
 	{
 		mBuffer = bs_new<D3D11HardwareBuffer>(D3D11HardwareBuffer::BT_INDEX, mUsage, 1, mSize, std::ref(mDevice), false);
 
@@ -29,7 +29,7 @@ namespace bs { namespace ct
 		IndexBufferCore::initialize();
 	}
 
-	void* D3D11IndexBufferCore::map(UINT32 offset, UINT32 length, GpuLockOptions options, UINT32 deviceIdx, UINT32 queueIdx)
+	void* D3D11IndexBuffer::map(UINT32 offset, UINT32 length, GpuLockOptions options, UINT32 deviceIdx, UINT32 queueIdx)
 	{
 #if BS_PROFILING_ENABLED
 		if (options == GBL_READ_ONLY || options == GBL_READ_WRITE)
@@ -46,26 +46,26 @@ namespace bs { namespace ct
 		return mBuffer->lock(offset, length, options);
 	}
 
-	void D3D11IndexBufferCore::unmap()
+	void D3D11IndexBuffer::unmap()
 	{
 		mBuffer->unlock();
 	}
 
-	void D3D11IndexBufferCore::readData(UINT32 offset, UINT32 length, void* dest, UINT32 deviceIdx, UINT32 queueIdx)
+	void D3D11IndexBuffer::readData(UINT32 offset, UINT32 length, void* dest, UINT32 deviceIdx, UINT32 queueIdx)
 	{
 		mBuffer->readData(offset, length, dest);
 
 		BS_INC_RENDER_STAT_CAT(ResRead, RenderStatObject_IndexBuffer);
 	}
 
-	void D3D11IndexBufferCore::writeData(UINT32 offset, UINT32 length, const void* pSource, BufferWriteType writeFlags, UINT32 queueIdx)
+	void D3D11IndexBuffer::writeData(UINT32 offset, UINT32 length, const void* pSource, BufferWriteType writeFlags, UINT32 queueIdx)
 	{
 		mBuffer->writeData(offset, length, pSource, writeFlags);
 
 		BS_INC_RENDER_STAT_CAT(ResWrite, RenderStatObject_IndexBuffer);
 	}
 
-	void D3D11IndexBufferCore::copyData(HardwareBuffer& srcBuffer, UINT32 srcOffset,
+	void D3D11IndexBuffer::copyData(HardwareBuffer& srcBuffer, UINT32 srcOffset,
 		UINT32 dstOffset, UINT32 length, bool discardWholeBuffer, UINT32 queueIdx)
 	{
 		mBuffer->copyData(srcBuffer, srcOffset, dstOffset, length, discardWholeBuffer);

+ 2 - 2
Source/BansheeD3D11RenderAPI/Source/BsD3D11InputLayoutManager.cpp

@@ -55,7 +55,7 @@ namespace bs { namespace ct
 	}
 
 	ID3D11InputLayout* D3D11InputLayoutManager::retrieveInputLayout(const SPtr<VertexDeclarationCore>& vertexShaderDecl, 
-		const SPtr<VertexDeclarationCore>& vertexBufferDecl, D3D11GpuProgramCore& vertexProgram)
+		const SPtr<VertexDeclarationCore>& vertexBufferDecl, D3D11GpuProgram& vertexProgram)
 	{
 		VertexDeclarationKey pair;
 		pair.vertxDeclId = vertexBufferDecl->getId();
@@ -80,7 +80,7 @@ namespace bs { namespace ct
 	}
 
 	void D3D11InputLayoutManager::addNewInputLayout(const SPtr<VertexDeclarationCore>& vertexShaderDecl, 
-		const SPtr<VertexDeclarationCore>& vertexBufferDecl, D3D11GpuProgramCore& vertexProgram)
+		const SPtr<VertexDeclarationCore>& vertexBufferDecl, D3D11GpuProgram& vertexProgram)
 	{
 		const VertexDeclarationProperties& bufferDeclProps = vertexBufferDecl->getProperties();
 		const VertexDeclarationProperties& shaderDeclProps = vertexShaderDecl->getProperties();

+ 3 - 3
Source/BansheeD3D11RenderAPI/Source/BsD3D11RasterizerState.cpp

@@ -9,18 +9,18 @@
 
 namespace bs { namespace ct
 {
-	D3D11RasterizerStateCore::D3D11RasterizerStateCore(const RASTERIZER_STATE_DESC& desc, UINT32 id)
+	D3D11RasterizerState::D3D11RasterizerState(const RASTERIZER_STATE_DESC& desc, UINT32 id)
 		:RasterizerStateCore(desc, id), mRasterizerState(nullptr)
 	{ }
 
-	D3D11RasterizerStateCore::~D3D11RasterizerStateCore()
+	D3D11RasterizerState::~D3D11RasterizerState()
 	{
 		SAFE_RELEASE(mRasterizerState);
 
 		BS_INC_RENDER_STAT_CAT(ResDestroyed, RenderStatObject_RasterizerState);
 	}
 
-	void D3D11RasterizerStateCore::createInternal()
+	void D3D11RasterizerState::createInternal()
 	{
 		INT32 scaledDepthBias = Math::floorToInt(-mProperties.getDepthBias() * float((1 << 24))); // Note: Assumes 24-bit depth buffer
 

+ 37 - 37
Source/BansheeD3D11RenderAPI/Source/BsD3D11RenderAPI.cpp

@@ -98,22 +98,22 @@ namespace bs { namespace ct
 		mDevice = bs_new<D3D11Device>(device);
 		
 		// Create the texture manager for use by others		
-		TextureManager::startUp<D3D11TextureManager>();
-		TextureCoreManager::startUp<D3D11TextureCoreManager>();
+		TextureManager::startUp<bs::D3D11TextureManager>();
+		TextureCoreManager::startUp<D3D11TextureManager>();
 
 		// Create hardware buffer manager		
 		HardwareBufferManager::startUp();
-		HardwareBufferCoreManager::startUp<D3D11HardwareBufferCoreManager>(std::ref(*mDevice));
+		HardwareBufferCoreManager::startUp<D3D11HardwareBufferManager>(std::ref(*mDevice));
 
 		// Create render window manager
-		RenderWindowManager::startUp<D3D11RenderWindowManager>(this);
-		RenderWindowCoreManager::startUp<D3D11RenderWindowCoreManager>(this);
+		RenderWindowManager::startUp<bs::D3D11RenderWindowManager>(this);
+		RenderWindowCoreManager::startUp<D3D11RenderWindowManager>(this);
 
 		// Create & register HLSL factory		
 		mHLSLFactory = bs_new<D3D11HLSLProgramFactory>();
 
 		// Create render state manager
-		RenderStateCoreManager::startUp<D3D11RenderStateCoreManager>();
+		RenderStateCoreManager::startUp<D3D11RenderStateManager>();
 
 		mNumDevices = 1;
 		mCurrentCapabilities = bs_newN<RenderAPICapabilities>(mNumDevices);
@@ -213,40 +213,40 @@ namespace bs { namespace ct
 		{
 			THROW_IF_NOT_CORE_THREAD;
 
-			D3D11BlendStateCore* d3d11BlendState;
-			D3D11RasterizerStateCore* d3d11RasterizerState;
+			D3D11BlendState* d3d11BlendState;
+			D3D11RasterizerState* d3d11RasterizerState;
 
-			D3D11GpuFragmentProgramCore* d3d11FragmentProgram;
-			D3D11GpuGeometryProgramCore* d3d11GeometryProgram;
-			D3D11GpuDomainProgramCore* d3d11DomainProgram;
-			D3D11GpuHullProgramCore* d3d11HullProgram;
+			D3D11GpuFragmentProgram* d3d11FragmentProgram;
+			D3D11GpuGeometryProgram* d3d11GeometryProgram;
+			D3D11GpuDomainProgram* d3d11DomainProgram;
+			D3D11GpuHullProgram* d3d11HullProgram;
 
 			if(pipelineState != nullptr)
 			{
-				d3d11BlendState = static_cast<D3D11BlendStateCore*>(pipelineState->getBlendState().get());
-				d3d11RasterizerState = static_cast<D3D11RasterizerStateCore*>(pipelineState->getRasterizerState().get());
-				mActiveDepthStencilState = std::static_pointer_cast<D3D11DepthStencilStateCore>(pipelineState->getDepthStencilState());
+				d3d11BlendState = static_cast<D3D11BlendState*>(pipelineState->getBlendState().get());
+				d3d11RasterizerState = static_cast<D3D11RasterizerState*>(pipelineState->getRasterizerState().get());
+				mActiveDepthStencilState = std::static_pointer_cast<D3D11DepthStencilState>(pipelineState->getDepthStencilState());
 
-				mActiveVertexShader = std::static_pointer_cast<D3D11GpuVertexProgramCore>(pipelineState->getVertexProgram());
-				d3d11FragmentProgram = static_cast<D3D11GpuFragmentProgramCore*>(pipelineState->getFragmentProgram().get());
-				d3d11GeometryProgram = static_cast<D3D11GpuGeometryProgramCore*>(pipelineState->getGeometryProgram().get());
-				d3d11DomainProgram = static_cast<D3D11GpuDomainProgramCore*>(pipelineState->getDomainProgram().get());
-				d3d11HullProgram = static_cast<D3D11GpuHullProgramCore*>(pipelineState->getHullProgram().get());
+				mActiveVertexShader = std::static_pointer_cast<D3D11GpuVertexProgram>(pipelineState->getVertexProgram());
+				d3d11FragmentProgram = static_cast<D3D11GpuFragmentProgram*>(pipelineState->getFragmentProgram().get());
+				d3d11GeometryProgram = static_cast<D3D11GpuGeometryProgram*>(pipelineState->getGeometryProgram().get());
+				d3d11DomainProgram = static_cast<D3D11GpuDomainProgram*>(pipelineState->getDomainProgram().get());
+				d3d11HullProgram = static_cast<D3D11GpuHullProgram*>(pipelineState->getHullProgram().get());
 
 				if (d3d11BlendState == nullptr)
-					d3d11BlendState = static_cast<D3D11BlendStateCore*>(BlendStateCore::getDefault().get());
+					d3d11BlendState = static_cast<D3D11BlendState*>(BlendStateCore::getDefault().get());
 
 				if (d3d11RasterizerState == nullptr)
-					d3d11RasterizerState = static_cast<D3D11RasterizerStateCore*>(RasterizerStateCore::getDefault().get());
+					d3d11RasterizerState = static_cast<D3D11RasterizerState*>(RasterizerStateCore::getDefault().get());
 
 				if (mActiveDepthStencilState == nullptr)
-					mActiveDepthStencilState = std::static_pointer_cast<D3D11DepthStencilStateCore>(DepthStencilStateCore::getDefault());
+					mActiveDepthStencilState = std::static_pointer_cast<D3D11DepthStencilState>(DepthStencilStateCore::getDefault());
 			}
 			else
 			{
-				d3d11BlendState = static_cast<D3D11BlendStateCore*>(BlendStateCore::getDefault().get());
-				d3d11RasterizerState = static_cast<D3D11RasterizerStateCore*>(RasterizerStateCore::getDefault().get());
-				mActiveDepthStencilState = std::static_pointer_cast<D3D11DepthStencilStateCore>(DepthStencilStateCore::getDefault());
+				d3d11BlendState = static_cast<D3D11BlendState*>(BlendStateCore::getDefault().get());
+				d3d11RasterizerState = static_cast<D3D11RasterizerState*>(RasterizerStateCore::getDefault().get());
+				mActiveDepthStencilState = std::static_pointer_cast<D3D11DepthStencilState>(DepthStencilStateCore::getDefault());
 
 				mActiveVertexShader = nullptr;
 				d3d11FragmentProgram = nullptr;
@@ -262,7 +262,7 @@ namespace bs { namespace ct
 
 			if (mActiveVertexShader != nullptr)
 			{
-				D3D11GpuVertexProgramCore* vertexProgram = static_cast<D3D11GpuVertexProgramCore*>(mActiveVertexShader.get());
+				D3D11GpuVertexProgram* vertexProgram = static_cast<D3D11GpuVertexProgram*>(mActiveVertexShader.get());
 				d3d11Context->VSSetShader(vertexProgram->getVertexShader(), nullptr, 0);
 			}
 			else
@@ -316,7 +316,7 @@ namespace bs { namespace ct
 
 			if (program != nullptr && program->getProperties().getType() == GPT_COMPUTE_PROGRAM)
 			{
-				D3D11GpuComputeProgramCore *d3d11ComputeProgram = static_cast<D3D11GpuComputeProgramCore*>(program.get());
+				D3D11GpuComputeProgram *d3d11ComputeProgram = static_cast<D3D11GpuComputeProgram*>(program.get());
 				mDevice->getImmediateContext()->CSSetShader(d3d11ComputeProgram->getComputeShader(), nullptr, 0);
 			}
 			else
@@ -396,7 +396,7 @@ namespace bs { namespace ct
 
 						if (texture != nullptr)
 						{
-							D3D11TextureCore* d3d11Texture = static_cast<D3D11TextureCore*>(texture.get());
+							D3D11Texture* d3d11Texture = static_cast<D3D11Texture*>(texture.get());
 							srvs[slot] = d3d11Texture->getSRV();
 						}
 					}
@@ -416,7 +416,7 @@ namespace bs { namespace ct
 
 							if (buffer != nullptr)
 							{
-								D3D11GpuBufferCore* d3d11buffer = static_cast<D3D11GpuBufferCore*>(buffer.get());
+								D3D11GpuBuffer* d3d11buffer = static_cast<D3D11GpuBuffer*>(buffer.get());
 								srvs[slot] = d3d11buffer->getSRV();
 							}
 						}
@@ -427,7 +427,7 @@ namespace bs { namespace ct
 
 							if (buffer != nullptr)
 							{
-								D3D11GpuBufferCore* d3d11buffer = static_cast<D3D11GpuBufferCore*>(buffer.get());
+								D3D11GpuBuffer* d3d11buffer = static_cast<D3D11GpuBuffer*>(buffer.get());
 								uavs[slot] = d3d11buffer->getUAV();
 							}
 						}
@@ -478,8 +478,8 @@ namespace bs { namespace ct
 						if (samplerState == nullptr)
 							samplerState = SamplerStateCore::getDefault();
 
-						D3D11SamplerStateCore* d3d11SamplerState = 
-							static_cast<D3D11SamplerStateCore*>(const_cast<SamplerStateCore*>(samplerState.get()));
+						D3D11SamplerState* d3d11SamplerState = 
+							static_cast<D3D11SamplerState*>(const_cast<SamplerStateCore*>(samplerState.get()));
 						samplers[slot] = d3d11SamplerState->getInternal();
 					}
 
@@ -495,8 +495,8 @@ namespace bs { namespace ct
 						{
 							buffer->flushToGPU();
 
-							const D3D11GpuParamBlockBufferCore* d3d11paramBlockBuffer =
-								static_cast<const D3D11GpuParamBlockBufferCore*>(buffer.get());
+							const D3D11GpuParamBlockBuffer* d3d11paramBlockBuffer =
+								static_cast<const D3D11GpuParamBlockBuffer*>(buffer.get());
 							constBuffers[slot] = d3d11paramBlockBuffer->getD3D11Buffer();
 						}
 					}
@@ -667,7 +667,7 @@ namespace bs { namespace ct
 
 			for (UINT32 i = 0; i < numBuffers; i++)
 			{
-				SPtr<D3D11VertexBufferCore> vertexBuffer = std::static_pointer_cast<D3D11VertexBufferCore>(buffers[i]);
+				SPtr<D3D11VertexBuffer> vertexBuffer = std::static_pointer_cast<D3D11VertexBuffer>(buffers[i]);
 				const VertexBufferProperties& vbProps = vertexBuffer->getProperties();
 
 				dx11buffers[i] = vertexBuffer->getD3DVertexBuffer();
@@ -698,7 +698,7 @@ namespace bs { namespace ct
 		{
 			THROW_IF_NOT_CORE_THREAD;
 
-			SPtr<D3D11IndexBufferCore> indexBuffer = std::static_pointer_cast<D3D11IndexBufferCore>(buffer);
+			SPtr<D3D11IndexBuffer> indexBuffer = std::static_pointer_cast<D3D11IndexBuffer>(buffer);
 
 			DXGI_FORMAT indexFormat = DXGI_FORMAT_R16_UINT;
 			if (indexBuffer->getProperties().getType() == IT_16BIT)

+ 8 - 8
Source/BansheeD3D11RenderAPI/Source/BsD3D11RenderStateManager.cpp

@@ -8,33 +8,33 @@
 
 namespace bs { namespace ct
 {
-	SPtr<SamplerStateCore> D3D11RenderStateCoreManager::createSamplerStateInternal(const SAMPLER_STATE_DESC& desc, GpuDeviceFlags deviceMask) const
+	SPtr<SamplerStateCore> D3D11RenderStateManager::createSamplerStateInternal(const SAMPLER_STATE_DESC& desc, GpuDeviceFlags deviceMask) const
 	{
-		SPtr<SamplerStateCore> ret = bs_shared_ptr<D3D11SamplerStateCore>(new (bs_alloc<D3D11SamplerStateCore>()) D3D11SamplerStateCore(desc, deviceMask));
+		SPtr<SamplerStateCore> ret = bs_shared_ptr<D3D11SamplerState>(new (bs_alloc<D3D11SamplerState>()) D3D11SamplerState(desc, deviceMask));
 		ret->_setThisPtr(ret);
 
 		return ret;
 	}
 
-	SPtr<BlendStateCore> D3D11RenderStateCoreManager::createBlendStateInternal(const BLEND_STATE_DESC& desc, UINT32 id) const
+	SPtr<BlendStateCore> D3D11RenderStateManager::createBlendStateInternal(const BLEND_STATE_DESC& desc, UINT32 id) const
 	{
-		SPtr<BlendStateCore> ret = bs_shared_ptr<D3D11BlendStateCore>(new (bs_alloc<D3D11BlendStateCore>()) D3D11BlendStateCore(desc, id));
+		SPtr<BlendStateCore> ret = bs_shared_ptr<D3D11BlendState>(new (bs_alloc<D3D11BlendState>()) D3D11BlendState(desc, id));
 		ret->_setThisPtr(ret);
 
 		return ret;
 	}
 
-	SPtr<RasterizerStateCore> D3D11RenderStateCoreManager::createRasterizerStateInternal(const RASTERIZER_STATE_DESC& desc, UINT32 id) const
+	SPtr<RasterizerStateCore> D3D11RenderStateManager::createRasterizerStateInternal(const RASTERIZER_STATE_DESC& desc, UINT32 id) const
 	{
-		SPtr<RasterizerStateCore> ret = bs_shared_ptr<D3D11RasterizerStateCore>(new (bs_alloc<D3D11RasterizerStateCore>()) D3D11RasterizerStateCore(desc, id));
+		SPtr<RasterizerStateCore> ret = bs_shared_ptr<D3D11RasterizerState>(new (bs_alloc<D3D11RasterizerState>()) D3D11RasterizerState(desc, id));
 		ret->_setThisPtr(ret);
 
 		return ret;
 	}
 
-	SPtr<DepthStencilStateCore> D3D11RenderStateCoreManager::createDepthStencilStateInternal(const DEPTH_STENCIL_STATE_DESC& desc, UINT32 id) const
+	SPtr<DepthStencilStateCore> D3D11RenderStateManager::createDepthStencilStateInternal(const DEPTH_STENCIL_STATE_DESC& desc, UINT32 id) const
 	{
-		SPtr<DepthStencilStateCore> ret = bs_shared_ptr<D3D11DepthStencilStateCore>(new (bs_alloc<D3D11DepthStencilStateCore>()) D3D11DepthStencilStateCore(desc, id));
+		SPtr<DepthStencilStateCore> ret = bs_shared_ptr<D3D11DepthStencilState>(new (bs_alloc<D3D11DepthStencilState>()) D3D11DepthStencilState(desc, id));
 		ret->_setThisPtr(ret);
 
 		return ret;

+ 12 - 10
Source/BansheeD3D11RenderAPI/Source/BsD3D11RenderTexture.cpp

@@ -3,15 +3,23 @@
 #include "BsD3D11RenderTexture.h"
 #include "BsD3D11TextureView.h"
 
-namespace bs { namespace ct
-{
-	D3D11RenderTextureCore::D3D11RenderTextureCore(const RENDER_TEXTURE_DESC_CORE& desc, UINT32 deviceIdx)
+namespace bs 
+{ 
+	D3D11RenderTexture::D3D11RenderTexture(const RENDER_TEXTURE_DESC& desc)
+		:RenderTexture(desc), mProperties(desc, false)
+	{
+
+	}
+
+	namespace ct
+	{
+	D3D11RenderTexture::D3D11RenderTexture(const RENDER_TEXTURE_DESC_CORE& desc, UINT32 deviceIdx)
 		:RenderTextureCore(desc, deviceIdx), mProperties(desc, false)
 	{ 
 		assert(deviceIdx == 0 && "Multiple GPUs not supported natively on DirectX 11.");
 	}
 
-	void D3D11RenderTextureCore::getCustomAttribute(const String& name, void* data) const
+	void D3D11RenderTexture::getCustomAttribute(const String& name, void* data) const
 	{
 		if(name == "RTV")
 		{
@@ -46,10 +54,4 @@ namespace bs { namespace ct
 			*dsv = depthStencilView->getDSV(true);
 		}
 	}
-
-	D3D11RenderTexture::D3D11RenderTexture(const RENDER_TEXTURE_DESC& desc)
-		:RenderTexture(desc), mProperties(desc, false)
-	{ 
-
-	}
 }}

+ 7 - 7
Source/BansheeD3D11RenderAPI/Source/BsD3D11RenderUtility.cpp

@@ -39,28 +39,28 @@ namespace bs { namespace ct
 		// Set states
 		if((clearBuffers & FBT_COLOR) != 0)
 		{
-			D3D11BlendStateCore* d3d11BlendState = static_cast<D3D11BlendStateCore*>(const_cast<BlendStateCore*>(mClearQuadBlendStateYesC.get()));
+			D3D11BlendState* d3d11BlendState = static_cast<D3D11BlendState*>(const_cast<BlendStateCore*>(mClearQuadBlendStateYesC.get()));
 			mDevice->getImmediateContext()->OMSetBlendState(d3d11BlendState->getInternal(), nullptr, 0xFFFFFFFF);
 		}
 		else
 		{
-			D3D11BlendStateCore* d3d11BlendState = static_cast<D3D11BlendStateCore*>(const_cast<BlendStateCore*>(mClearQuadBlendStateNoC.get()));
+			D3D11BlendState* d3d11BlendState = static_cast<D3D11BlendState*>(const_cast<BlendStateCore*>(mClearQuadBlendStateNoC.get()));
 			mDevice->getImmediateContext()->OMSetBlendState(d3d11BlendState->getInternal(), nullptr, 0xFFFFFFFF);
 		}
 
-		D3D11RasterizerStateCore* d3d11RasterizerState = static_cast<D3D11RasterizerStateCore*>(const_cast<RasterizerStateCore*>(mClearQuadRasterizerState.get()));
+		D3D11RasterizerState* d3d11RasterizerState = static_cast<D3D11RasterizerState*>(const_cast<RasterizerStateCore*>(mClearQuadRasterizerState.get()));
 		mDevice->getImmediateContext()->RSSetState(d3d11RasterizerState->getInternal());
 
 		if((clearBuffers & FBT_DEPTH) != 0)
 		{
 			if((clearBuffers & FBT_STENCIL) != 0)
 			{
-				D3D11DepthStencilStateCore* d3d11RasterizerState = static_cast<D3D11DepthStencilStateCore*>(const_cast<DepthStencilStateCore*>(mClearQuadDSStateYesD_YesS.get()));
+				D3D11DepthStencilState* d3d11RasterizerState = static_cast<D3D11DepthStencilState*>(const_cast<DepthStencilStateCore*>(mClearQuadDSStateYesD_YesS.get()));
 				mDevice->getImmediateContext()->OMSetDepthStencilState(d3d11RasterizerState->getInternal(), stencil);
 			}
 			else
 			{
-				D3D11DepthStencilStateCore* d3d11RasterizerState = static_cast<D3D11DepthStencilStateCore*>(const_cast<DepthStencilStateCore*>(mClearQuadDSStateYesD_NoS.get()));
+				D3D11DepthStencilState* d3d11RasterizerState = static_cast<D3D11DepthStencilState*>(const_cast<DepthStencilStateCore*>(mClearQuadDSStateYesD_NoS.get()));
 				mDevice->getImmediateContext()->OMSetDepthStencilState(d3d11RasterizerState->getInternal(), stencil);
 			}
 		}
@@ -68,12 +68,12 @@ namespace bs { namespace ct
 		{
 			if((clearBuffers & FBT_STENCIL) != 0)
 			{
-				D3D11DepthStencilStateCore* d3d11RasterizerState = static_cast<D3D11DepthStencilStateCore*>(const_cast<DepthStencilStateCore*>(mClearQuadDSStateNoD_YesS.get()));
+				D3D11DepthStencilState* d3d11RasterizerState = static_cast<D3D11DepthStencilState*>(const_cast<DepthStencilStateCore*>(mClearQuadDSStateNoD_YesS.get()));
 				mDevice->getImmediateContext()->OMSetDepthStencilState(d3d11RasterizerState->getInternal(), stencil);
 			}
 			else
 			{
-				D3D11DepthStencilStateCore* d3d11RasterizerState = static_cast<D3D11DepthStencilStateCore*>(const_cast<DepthStencilStateCore*>(mClearQuadDSStateNoD_NoS.get()));
+				D3D11DepthStencilState* d3d11RasterizerState = static_cast<D3D11DepthStencilState*>(const_cast<DepthStencilStateCore*>(mClearQuadDSStateNoD_NoS.get()));
 				mDevice->getImmediateContext()->OMSetDepthStencilState(d3d11RasterizerState->getInternal(), stencil);
 			}
 		}

+ 83 - 79
Source/BansheeD3D11RenderAPI/Source/BsD3D11RenderWindow.cpp

@@ -18,19 +18,75 @@
 #include "BsMath.h"
 #include "Win32/BsWin32Window.h"
 
-namespace bs { namespace ct
+namespace bs
 {
 	D3D11RenderWindowProperties::D3D11RenderWindowProperties(const RENDER_WINDOW_DESC& desc)
 		:RenderWindowProperties(desc)
 	{ }
 
-	D3D11RenderWindowCore::D3D11RenderWindowCore(const RENDER_WINDOW_DESC& desc, UINT32 windowId, D3D11Device& device, IDXGIFactory* DXGIFactory)
+	D3D11RenderWindow::D3D11RenderWindow(const RENDER_WINDOW_DESC& desc, UINT32 windowId, ct::D3D11Device& device, 
+		IDXGIFactory* DXGIFactory)
+		:RenderWindow(desc, windowId), mProperties(desc), mDevice(device), mDXGIFactory(DXGIFactory)
+	{
+
+	}
+
+	void D3D11RenderWindow::getCustomAttribute(const String& name, void* pData) const
+	{
+		if (name == "WINDOW")
+		{
+			UINT64 *pHwnd = (UINT64*)pData;
+			*pHwnd = (UINT64)getHWnd();
+			return;
+		}
+	}
+
+	Vector2I D3D11RenderWindow::screenToWindowPos(const Vector2I& screenPos) const
+	{
+		POINT pos;
+		pos.x = screenPos.x;
+		pos.y = screenPos.y;
+
+		ScreenToClient(getHWnd(), &pos);
+		return Vector2I(pos.x, pos.y);
+	}
+
+	Vector2I D3D11RenderWindow::windowToScreenPos(const Vector2I& windowPos) const
+	{
+		POINT pos;
+		pos.x = windowPos.x;
+		pos.y = windowPos.y;
+
+		ClientToScreen(getHWnd(), &pos);
+		return Vector2I(pos.x, pos.y);
+	}
+
+	SPtr<ct::D3D11RenderWindow> D3D11RenderWindow::getCore() const
+	{
+		return std::static_pointer_cast<ct::D3D11RenderWindow>(mCoreSpecific);
+	}
+
+	HWND D3D11RenderWindow::getHWnd() const
+	{
+		blockUntilCoreInitialized();
+		return getCore()->_getWindowHandle();
+	}
+
+	void D3D11RenderWindow::syncProperties()
+	{
+		ScopedSpinLock lock(getCore()->mLock);
+		mProperties = getCore()->mSyncedProperties;
+	}
+
+	namespace ct
+	{
+	D3D11RenderWindow::D3D11RenderWindow(const RENDER_WINDOW_DESC& desc, UINT32 windowId, D3D11Device& device, IDXGIFactory* DXGIFactory)
 		: RenderWindowCore(desc, windowId), mProperties(desc), mSyncedProperties(desc), mDevice(device), mDXGIFactory(DXGIFactory), 
 		mSizing(false), mRenderTargetView(nullptr), mBackBuffer(nullptr), mSwapChain(nullptr), mDepthStencilView(nullptr), mIsChild(false), 
 		mRefreshRateNumerator(0), mRefreshRateDenominator(0), mShowOnSwap(false), mWindow(nullptr)
 	{ }
 
-	D3D11RenderWindowCore::~D3D11RenderWindowCore()
+	D3D11RenderWindow::~D3D11RenderWindow()
 	{ 
 		D3D11RenderWindowProperties& props = mProperties;
 
@@ -54,7 +110,7 @@ namespace bs { namespace ct
 		destroySizeDependedD3DResources();
 	}
 
-	void D3D11RenderWindowCore::initialize()
+	void D3D11RenderWindow::initialize()
 	{
 		ZeroMemory(&mSwapChainDesc, sizeof(DXGI_SWAP_CHAIN_DESC));
 
@@ -161,7 +217,7 @@ namespace bs { namespace ct
 		RenderWindowCore::initialize();
 	}
 
-	void D3D11RenderWindowCore::swapBuffers(UINT32 syncMask)
+	void D3D11RenderWindow::swapBuffers(UINT32 syncMask)
 	{
 		THROW_IF_NOT_CORE_THREAD;
 
@@ -177,7 +233,7 @@ namespace bs { namespace ct
 		}
 	}
 
-	void D3D11RenderWindowCore::move(INT32 left, INT32 top)
+	void D3D11RenderWindow::move(INT32 left, INT32 top)
 	{
 		THROW_IF_NOT_CORE_THREAD;
 
@@ -200,7 +256,7 @@ namespace bs { namespace ct
 		}
 	}
 
-	void D3D11RenderWindowCore::resize(UINT32 width, UINT32 height)
+	void D3D11RenderWindow::resize(UINT32 width, UINT32 height)
 	{
 		THROW_IF_NOT_CORE_THREAD;
 
@@ -223,7 +279,7 @@ namespace bs { namespace ct
 		}
 	}
 
-	void D3D11RenderWindowCore::setActive(bool state)
+	void D3D11RenderWindow::setActive(bool state)
 	{
 		THROW_IF_NOT_CORE_THREAD;
 
@@ -241,7 +297,7 @@ namespace bs { namespace ct
 		RenderWindowCore::setActive(state);
 	}
 
-	void D3D11RenderWindowCore::setHidden(bool hidden)
+	void D3D11RenderWindow::setHidden(bool hidden)
 	{
 		THROW_IF_NOT_CORE_THREAD;
 
@@ -251,28 +307,28 @@ namespace bs { namespace ct
 		RenderWindowCore::setHidden(hidden);
 	}
 
-	void D3D11RenderWindowCore::minimize()
+	void D3D11RenderWindow::minimize()
 	{
 		THROW_IF_NOT_CORE_THREAD;
 
 		mWindow->minimize();
 	}
 
-	void D3D11RenderWindowCore::maximize()
+	void D3D11RenderWindow::maximize()
 	{
 		THROW_IF_NOT_CORE_THREAD;
 
 		mWindow->maximize();
 	}
 
-	void D3D11RenderWindowCore::restore()
+	void D3D11RenderWindow::restore()
 	{
 		THROW_IF_NOT_CORE_THREAD;
 
 		mWindow->restore();
 	}
 
-	void D3D11RenderWindowCore::setFullscreen(UINT32 width, UINT32 height, float refreshRate, UINT32 monitorIdx)
+	void D3D11RenderWindow::setFullscreen(UINT32 width, UINT32 height, float refreshRate, UINT32 monitorIdx)
 	{
 		THROW_IF_NOT_CORE_THREAD;
 
@@ -322,7 +378,7 @@ namespace bs { namespace ct
 		RenderWindowManager::instance().notifyMovedOrResized(this);
 	}
 
-	void D3D11RenderWindowCore::setFullscreen(const VideoMode& mode)
+	void D3D11RenderWindow::setFullscreen(const VideoMode& mode)
 	{
 		THROW_IF_NOT_CORE_THREAD;
 
@@ -364,7 +420,7 @@ namespace bs { namespace ct
 		RenderWindowManager::instance().notifyMovedOrResized(this);
 	}
 
-	void D3D11RenderWindowCore::setWindowed(UINT32 width, UINT32 height)
+	void D3D11RenderWindow::setWindowed(UINT32 width, UINT32 height)
 	{
 		THROW_IF_NOT_CORE_THREAD;
 
@@ -402,12 +458,12 @@ namespace bs { namespace ct
 		RenderWindowManager::instance().notifyMovedOrResized(this);
 	}
 
-	HWND D3D11RenderWindowCore::_getWindowHandle() const
+	HWND D3D11RenderWindow::_getWindowHandle() const
 	{
 		return mWindow->getHWnd();
 	}
 
-	void D3D11RenderWindowCore::getCustomAttribute(const String& name, void* pData) const
+	void D3D11RenderWindow::getCustomAttribute(const String& name, void* pData) const
 	{
 		if(name == "WINDOW")
 		{
@@ -453,7 +509,7 @@ namespace bs { namespace ct
 		RenderWindowCore::getCustomAttribute(name, pData);
 	}
 
-	void D3D11RenderWindowCore::copyToMemory(PixelData &dst, FrameBuffer buffer)
+	void D3D11RenderWindow::copyToMemory(PixelData &dst, FrameBuffer buffer)
 	{
 		THROW_IF_NOT_CORE_THREAD;
 
@@ -523,7 +579,7 @@ namespace bs { namespace ct
 		SAFE_RELEASE(backbuffer);
 	}
 
-	void D3D11RenderWindowCore::_windowMovedOrResized()
+	void D3D11RenderWindow::_windowMovedOrResized()
 	{
 		THROW_IF_NOT_CORE_THREAD;
 
@@ -550,7 +606,7 @@ namespace bs { namespace ct
 		RenderWindowCore::_windowMovedOrResized();
 	}
 
-	void D3D11RenderWindowCore::createSwapChain()
+	void D3D11RenderWindow::createSwapChain()
 	{
 		ZeroMemory(&mSwapChainDesc, sizeof(DXGI_SWAP_CHAIN_DESC));
 
@@ -610,7 +666,7 @@ namespace bs { namespace ct
 		BS_INC_RENDER_STAT_CAT(ResCreated, RenderStatObject_SwapChain);
 	}
 
-	void D3D11RenderWindowCore::createSizeDependedD3DResources()
+	void D3D11RenderWindow::createSizeDependedD3DResources()
 	{
 		SAFE_RELEASE(mBackBuffer);
 
@@ -660,7 +716,7 @@ namespace bs { namespace ct
 			mDepthStencilBuffer = nullptr;
 	}
 
-	void D3D11RenderWindowCore::destroySizeDependedD3DResources()
+	void D3D11RenderWindow::destroySizeDependedD3DResources()
 	{
 		SAFE_RELEASE(mBackBuffer);
 		SAFE_RELEASE(mRenderTargetView);
@@ -668,7 +724,7 @@ namespace bs { namespace ct
 		mDepthStencilBuffer = nullptr;
 	}
 
-	void D3D11RenderWindowCore::resizeSwapChainBuffers(UINT32 width, UINT32 height)
+	void D3D11RenderWindow::resizeSwapChainBuffers(UINT32 width, UINT32 height)
 	{
 		destroySizeDependedD3DResources();
 
@@ -688,7 +744,7 @@ namespace bs { namespace ct
 		mDevice.getImmediateContext()->OMSetRenderTargets(0, 0, 0);
 	}
 
-	IDXGIDevice* D3D11RenderWindowCore::queryDxgiDevice()
+	IDXGIDevice* D3D11RenderWindow::queryDxgiDevice()
 	{
 		if (mDevice.getD3D11Device() == nullptr)
 		{
@@ -704,62 +760,10 @@ namespace bs { namespace ct
 		return pDXGIDevice;
 	}
 
-	void D3D11RenderWindowCore::syncProperties()
+	void D3D11RenderWindow::syncProperties()
 	{
 		ScopedSpinLock lock(mLock);
 		mProperties = mSyncedProperties;
+	}		
 	}
-
-	D3D11RenderWindow::D3D11RenderWindow(const RENDER_WINDOW_DESC& desc, UINT32 windowId, D3D11Device& device, IDXGIFactory* DXGIFactory)
-		:RenderWindow(desc, windowId), mProperties(desc), mDevice(device), mDXGIFactory(DXGIFactory)
-	{
-
-	}
-
-	void D3D11RenderWindow::getCustomAttribute(const String& name, void* pData) const
-	{
-		if (name == "WINDOW")
-		{
-			UINT64 *pHwnd = (UINT64*)pData;
-			*pHwnd = (UINT64)getHWnd();
-			return;
-		}
-	}
-
-	Vector2I D3D11RenderWindow::screenToWindowPos(const Vector2I& screenPos) const
-	{
-		POINT pos;
-		pos.x = screenPos.x;
-		pos.y = screenPos.y;
-
-		ScreenToClient(getHWnd(), &pos);
-		return Vector2I(pos.x, pos.y);
-	}
-
-	Vector2I D3D11RenderWindow::windowToScreenPos(const Vector2I& windowPos) const
-	{
-		POINT pos;
-		pos.x = windowPos.x;
-		pos.y = windowPos.y;
-
-		ClientToScreen(getHWnd(), &pos);
-		return Vector2I(pos.x, pos.y);
-	}
-
-	SPtr<D3D11RenderWindowCore> D3D11RenderWindow::getCore() const
-	{
-		return std::static_pointer_cast<D3D11RenderWindowCore>(mCoreSpecific);
-	}
-
-	HWND D3D11RenderWindow::getHWnd() const
-	{
-		blockUntilCoreInitialized();
-		return getCore()->_getWindowHandle();
-	}
-
-	void D3D11RenderWindow::syncProperties()
-	{
-		ScopedSpinLock lock(getCore()->mLock);
-		mProperties = getCore()->mSyncedProperties;
-	}
-}}
+}

+ 17 - 11
Source/BansheeD3D11RenderAPI/Source/BsD3D11RenderWindowManager.cpp

@@ -5,18 +5,19 @@
 #include "BsD3D11RenderWindow.h"
 #include "BsAsyncOp.h"
 
-namespace bs { namespace ct
+namespace bs
 {
-	D3D11RenderWindowManager::D3D11RenderWindowManager(D3D11RenderAPI* renderSystem)
+	D3D11RenderWindowManager::D3D11RenderWindowManager(ct::D3D11RenderAPI* renderSystem)
 		:mRenderSystem(renderSystem)
 	{
 		assert(mRenderSystem != nullptr);
 	}
 
-	SPtr<RenderWindow> D3D11RenderWindowManager::createImpl(RENDER_WINDOW_DESC& desc, UINT32 windowId, const SPtr<RenderWindow>& parentWindow)
+	SPtr<RenderWindow> D3D11RenderWindowManager::createImpl(RENDER_WINDOW_DESC& desc, UINT32 windowId, 
+		const SPtr<RenderWindow>& parentWindow)
 	{
-		RenderAPICore* rs = RenderAPICore::instancePtr();
-		D3D11RenderAPI* d3d11rs = static_cast<D3D11RenderAPI*>(rs);
+		ct::RenderAPICore* rs = ct::RenderAPICore::instancePtr();
+		ct::D3D11RenderAPI* d3d11rs = static_cast<ct::D3D11RenderAPI*>(rs);
 
 		if(parentWindow != nullptr)
 		{
@@ -26,29 +27,34 @@ namespace bs { namespace ct
 		}
 
 		// Create the window
-		D3D11RenderWindow* renderWindow = new (bs_alloc<D3D11RenderWindow>()) D3D11RenderWindow(desc, windowId, d3d11rs->getPrimaryDevice(), d3d11rs->getDXGIFactory());
+		D3D11RenderWindow* renderWindow = new (bs_alloc<D3D11RenderWindow>()) D3D11RenderWindow(desc, windowId, 
+			d3d11rs->getPrimaryDevice(), d3d11rs->getDXGIFactory());
 		return bs_core_ptr<D3D11RenderWindow>(renderWindow);
 	}
 
-	D3D11RenderWindowCoreManager::D3D11RenderWindowCoreManager(D3D11RenderAPI* renderSystem)
+	namespace ct
+	{
+	D3D11RenderWindowManager::D3D11RenderWindowManager(D3D11RenderAPI* renderSystem)
 		:mRenderSystem(renderSystem)
 	{
 		assert(mRenderSystem != nullptr);
 	}
 
-	SPtr<RenderWindowCore> D3D11RenderWindowCoreManager::createInternal(RENDER_WINDOW_DESC& desc, UINT32 windowId)
+	SPtr<RenderWindowCore> D3D11RenderWindowManager::createInternal(RENDER_WINDOW_DESC& desc, UINT32 windowId)
 	{
 		RenderAPICore* rs = RenderAPICore::instancePtr();
 		D3D11RenderAPI* d3d11rs = static_cast<D3D11RenderAPI*>(rs);
 
 		// Create the window
-		D3D11RenderWindowCore* renderWindow = new (bs_alloc<D3D11RenderWindowCore>()) D3D11RenderWindowCore(desc, windowId, d3d11rs->getPrimaryDevice(), d3d11rs->getDXGIFactory());
+		D3D11RenderWindow* renderWindow = new (bs_alloc<D3D11RenderWindow>()) D3D11RenderWindow(desc, windowId, 
+			d3d11rs->getPrimaryDevice(), d3d11rs->getDXGIFactory());
 
-		SPtr<D3D11RenderWindowCore> renderWindowPtr = bs_shared_ptr<D3D11RenderWindowCore>(renderWindow);
+		SPtr<D3D11RenderWindow> renderWindowPtr = bs_shared_ptr<D3D11RenderWindow>(renderWindow);
 		renderWindowPtr->_setThisPtr(renderWindowPtr);
 
 		windowCreated(renderWindow);
 
 		return renderWindowPtr;
 	}
-}}
+	}
+}

+ 3 - 3
Source/BansheeD3D11RenderAPI/Source/BsD3D11SamplerState.cpp

@@ -8,18 +8,18 @@
 
 namespace bs { namespace ct
 {
-	D3D11SamplerStateCore::D3D11SamplerStateCore(const SAMPLER_STATE_DESC& desc, GpuDeviceFlags deviceMask)
+	D3D11SamplerState::D3D11SamplerState(const SAMPLER_STATE_DESC& desc, GpuDeviceFlags deviceMask)
 		:SamplerStateCore(desc, deviceMask), mSamplerState(nullptr)
 	{ }
 
-	D3D11SamplerStateCore::~D3D11SamplerStateCore()
+	D3D11SamplerState::~D3D11SamplerState()
 	{
 		SAFE_RELEASE(mSamplerState);
 
 		BS_INC_RENDER_STAT_CAT(ResDestroyed, RenderStatObject_SamplerState);
 	}
 
-	void D3D11SamplerStateCore::createInternal()
+	void D3D11SamplerState::createInternal()
 	{
 		D3D11_SAMPLER_DESC samplerState;
 		ZeroMemory(&samplerState, sizeof(D3D11_SAMPLER_DESC));

+ 21 - 21
Source/BansheeD3D11RenderAPI/Source/BsD3D11Texture.cpp

@@ -13,7 +13,7 @@
 
 namespace bs { namespace ct
 {
-	D3D11TextureCore::D3D11TextureCore(const TEXTURE_DESC& desc, const SPtr<PixelData>& initialData, 
+	D3D11Texture::D3D11Texture(const TEXTURE_DESC& desc, const SPtr<PixelData>& initialData, 
 		GpuDeviceFlags deviceMask)
 		: TextureCore(desc, initialData, deviceMask),
 		m1DTex(nullptr), m2DTex(nullptr), m3DTex(nullptr), mDXGIFormat(DXGI_FORMAT_UNKNOWN), mDXGIColorFormat(DXGI_FORMAT_UNKNOWN),
@@ -23,7 +23,7 @@ namespace bs { namespace ct
 		assert((deviceMask == GDF_DEFAULT || deviceMask == GDF_PRIMARY) && "Multiple GPUs not supported natively on DirectX 11.");
 	}
 
-	D3D11TextureCore::~D3D11TextureCore()
+	D3D11Texture::~D3D11Texture()
 	{ 
 		SAFE_RELEASE(mTex);
 		SAFE_RELEASE(m1DTex);
@@ -34,7 +34,7 @@ namespace bs { namespace ct
 		BS_INC_RENDER_STAT_CAT(ResDestroyed, RenderStatObject_Texture);
 	}
 
-	void D3D11TextureCore::initialize()
+	void D3D11Texture::initialize()
 	{
 		THROW_IF_NOT_CORE_THREAD;
 
@@ -58,10 +58,10 @@ namespace bs { namespace ct
 		TextureCore::initialize();
 	}
 
-	void D3D11TextureCore::copyImpl(UINT32 srcFace, UINT32 srcMipLevel, UINT32 destFace, UINT32 destMipLevel,
+	void D3D11Texture::copyImpl(UINT32 srcFace, UINT32 srcMipLevel, UINT32 destFace, UINT32 destMipLevel,
 									const SPtr<TextureCore>& target, UINT32 queueIdx)
 	{
-		D3D11TextureCore* other = static_cast<D3D11TextureCore*>(target.get());
+		D3D11Texture* other = static_cast<D3D11Texture*>(target.get());
 
 		UINT32 srcResIdx = D3D11CalcSubresource(srcMipLevel, srcFace, mProperties.getNumMipmaps() + 1);
 		UINT32 destResIdx = D3D11CalcSubresource(destMipLevel, destFace, target->getProperties().getNumMipmaps() + 1);
@@ -94,7 +94,7 @@ namespace bs { namespace ct
 		}
 	}
 
-	PixelData D3D11TextureCore::lockImpl(GpuLockOptions options, UINT32 mipLevel, UINT32 face, UINT32 deviceIdx,
+	PixelData D3D11Texture::lockImpl(GpuLockOptions options, UINT32 mipLevel, UINT32 face, UINT32 deviceIdx,
 										 UINT32 queueIdx)
 	{
 		if (mProperties.getNumSamples() > 1)
@@ -146,7 +146,7 @@ namespace bs { namespace ct
 		return lockedArea;
 	}
 
-	void D3D11TextureCore::unlockImpl()
+	void D3D11Texture::unlockImpl()
 	{
 		if(mLockedForReading)
 			unmapstagingbuffer();
@@ -159,7 +159,7 @@ namespace bs { namespace ct
 		}
 	}
 
-	void D3D11TextureCore::readDataImpl(PixelData& dest, UINT32 mipLevel, UINT32 face, UINT32 deviceIdx, UINT32 queueIdx)
+	void D3D11Texture::readDataImpl(PixelData& dest, UINT32 mipLevel, UINT32 face, UINT32 deviceIdx, UINT32 queueIdx)
 	{
 		if (mProperties.getNumSamples() > 1)
 		{
@@ -172,7 +172,7 @@ namespace bs { namespace ct
 		unlock();
 	}
 
-	void D3D11TextureCore::writeDataImpl(const PixelData& src, UINT32 mipLevel, UINT32 face, bool discardWholeBuffer,
+	void D3D11Texture::writeDataImpl(const PixelData& src, UINT32 mipLevel, UINT32 face, bool discardWholeBuffer,
 									 UINT32 queueIdx)
 	{
 		PixelFormat format = mProperties.getFormat();
@@ -223,7 +223,7 @@ namespace bs { namespace ct
 		}
 	}
 
-	void D3D11TextureCore::create1DTex()
+	void D3D11Texture::create1DTex()
 	{
 		UINT32 width = mProperties.getWidth();
 		int usage = mProperties.getUsage();
@@ -340,7 +340,7 @@ namespace bs { namespace ct
 		}
 	}
 
-	void D3D11TextureCore::create2DTex()
+	void D3D11Texture::create2DTex()
 	{
 		UINT32 width = mProperties.getWidth();
 		UINT32 height = mProperties.getHeight();
@@ -488,7 +488,7 @@ namespace bs { namespace ct
 		}
 	}
 
-	void D3D11TextureCore::create3DTex()
+	void D3D11Texture::create3DTex()
 	{
 		UINT32 width = mProperties.getWidth();
 		UINT32 height = mProperties.getHeight();
@@ -606,7 +606,7 @@ namespace bs { namespace ct
 		}
 	}
 
-	void* D3D11TextureCore::map(ID3D11Resource* res, D3D11_MAP flags, UINT32 mipLevel, UINT32 face, UINT32& rowPitch, UINT32& slicePitch)
+	void* D3D11Texture::map(ID3D11Resource* res, D3D11_MAP flags, UINT32 mipLevel, UINT32 face, UINT32& rowPitch, UINT32& slicePitch)
 	{
 		D3D11_MAPPED_SUBRESOURCE pMappedResource;
 		pMappedResource.pData = nullptr;
@@ -636,7 +636,7 @@ namespace bs { namespace ct
 		return pMappedResource.pData;
 	}
 
-	void D3D11TextureCore::unmap(ID3D11Resource* res)
+	void D3D11Texture::unmap(ID3D11Resource* res)
 	{
 		D3D11RenderAPI* rs = static_cast<D3D11RenderAPI*>(RenderAPICore::instancePtr());
 		D3D11Device& device = rs->getPrimaryDevice();
@@ -649,7 +649,7 @@ namespace bs { namespace ct
 		}
 	}
 
-	void* D3D11TextureCore::mapstagingbuffer(D3D11_MAP flags, UINT32 mipLevel, UINT32 face, UINT32& rowPitch, UINT32& slicePitch)
+	void* D3D11Texture::mapstagingbuffer(D3D11_MAP flags, UINT32 mipLevel, UINT32 face, UINT32& rowPitch, UINT32& slicePitch)
 	{
 		// Note: I am creating and destroying a staging resource every time a texture is read. 
 		// Consider offering a flag on init that will keep this active all the time (at the cost of double memory).
@@ -665,13 +665,13 @@ namespace bs { namespace ct
 		return map(mStagingBuffer, flags, face, mipLevel, rowPitch, slicePitch);
 	}
 
-	void D3D11TextureCore::unmapstagingbuffer()
+	void D3D11Texture::unmapstagingbuffer()
 	{
 		unmap(mStagingBuffer);
 		SAFE_RELEASE(mStagingBuffer);
 	}
 
-	void* D3D11TextureCore::mapstaticbuffer(PixelData lock, UINT32 mipLevel, UINT32 face)
+	void* D3D11Texture::mapstaticbuffer(PixelData lock, UINT32 mipLevel, UINT32 face)
 	{
 		UINT32 sizeOfImage = lock.getConsecutiveSize();
 		mLockedSubresourceIdx = D3D11CalcSubresource(mipLevel, face, mProperties.getNumMipmaps()+1);
@@ -682,7 +682,7 @@ namespace bs { namespace ct
 		return mStaticBuffer->getData();
 	}
 
-	void D3D11TextureCore::unmapstaticbuffer()
+	void D3D11Texture::unmapstaticbuffer()
 	{
 		UINT32 rowWidth = D3D11Mappings::getSizeInBytes(mStaticBuffer->getFormat(), mStaticBuffer->getWidth());
 		UINT32 sliceWidth = D3D11Mappings::getSizeInBytes(mStaticBuffer->getFormat(), mStaticBuffer->getWidth(), mStaticBuffer->getHeight());
@@ -701,12 +701,12 @@ namespace bs { namespace ct
 			bs_delete(mStaticBuffer);
 	}
 
-	ID3D11ShaderResourceView* D3D11TextureCore::getSRV() const
+	ID3D11ShaderResourceView* D3D11Texture::getSRV() const
 	{
 		return mShaderResourceView->getSRV();
 	}
 
-	void D3D11TextureCore::createStagingBuffer()
+	void D3D11Texture::createStagingBuffer()
 	{
 		D3D11RenderAPI* rs = static_cast<D3D11RenderAPI*>(RenderAPICore::instancePtr());
 		D3D11Device& device = rs->getPrimaryDevice();
@@ -755,7 +755,7 @@ namespace bs { namespace ct
 		}
 	}
 
-	SPtr<TextureView> D3D11TextureCore::createView(const SPtr<TextureCore>& texture, const TEXTURE_VIEW_DESC& desc)
+	SPtr<TextureView> D3D11Texture::createView(const SPtr<TextureCore>& texture, const TEXTURE_VIEW_DESC& desc)
 	{
 		return bs_shared_ptr<D3D11TextureView>(new (bs_alloc<D3D11TextureView>()) D3D11TextureView(texture, desc));
 	}

+ 13 - 9
Source/BansheeD3D11RenderAPI/Source/BsD3D11TextureManager.cpp

@@ -6,7 +6,7 @@
 #include "BsD3D11Mappings.h"
 #include "BsD3D11RenderAPI.h"
 
-namespace bs { namespace ct
+namespace bs
 {
 	SPtr<RenderTexture> D3D11TextureManager::createRenderTextureImpl(const RENDER_TEXTURE_DESC& desc)
 	{
@@ -17,28 +17,32 @@ namespace bs { namespace ct
 
 	PixelFormat D3D11TextureManager::getNativeFormat(TextureType ttype, PixelFormat format, int usage, bool hwGamma)
 	{
-		DXGI_FORMAT d3dPF = D3D11Mappings::getPF(D3D11Mappings::getClosestSupportedPF(format, ttype, usage), hwGamma);
+		DXGI_FORMAT d3dPF = ct::D3D11Mappings::getPF(
+			ct::D3D11Mappings::getClosestSupportedPF(format, ttype, usage), hwGamma);
 
-		return D3D11Mappings::getPF(d3dPF);
+		return ct::D3D11Mappings::getPF(d3dPF);
 	}
 
-	SPtr<TextureCore> D3D11TextureCoreManager::createTextureInternal(const TEXTURE_DESC& desc,
+	namespace ct
+	{
+	SPtr<TextureCore> D3D11TextureManager::createTextureInternal(const TEXTURE_DESC& desc,
 		const SPtr<PixelData>& initialData, GpuDeviceFlags deviceMask)
 	{
-		D3D11TextureCore* tex = new (bs_alloc<D3D11TextureCore>()) D3D11TextureCore(desc, initialData, deviceMask);
+		D3D11Texture* tex = new (bs_alloc<D3D11Texture>()) D3D11Texture(desc, initialData, deviceMask);
 
-		SPtr<D3D11TextureCore> texPtr = bs_shared_ptr<D3D11TextureCore>(tex);
+		SPtr<D3D11Texture> texPtr = bs_shared_ptr<D3D11Texture>(tex);
 		texPtr->_setThisPtr(texPtr);
 
 		return texPtr;
 	}
 
-	SPtr<RenderTextureCore> D3D11TextureCoreManager::createRenderTextureInternal(const RENDER_TEXTURE_DESC_CORE& desc,
+	SPtr<RenderTextureCore> D3D11TextureManager::createRenderTextureInternal(const RENDER_TEXTURE_DESC_CORE& desc,
 																				 UINT32 deviceIdx)
 	{
-		SPtr<D3D11RenderTextureCore> texPtr = bs_shared_ptr_new<D3D11RenderTextureCore>(desc, deviceIdx);
+		SPtr<D3D11RenderTexture> texPtr = bs_shared_ptr_new<D3D11RenderTexture>(desc, deviceIdx);
 		texPtr->_setThisPtr(texPtr);
 
 		return texPtr;
 	}
-}}
+	}
+}

+ 5 - 5
Source/BansheeD3D11RenderAPI/Source/BsD3D11TextureView.cpp

@@ -13,7 +13,7 @@ namespace bs { namespace ct
 	D3D11TextureView::D3D11TextureView(const SPtr<TextureCore>& texture, const TEXTURE_VIEW_DESC& desc)
 		:TextureView(texture, desc), mSRV(nullptr), mUAV(nullptr), mDSV(nullptr), mRTV(nullptr), mRODSV(nullptr)
 	{
-		D3D11TextureCore* d3d11Texture = static_cast<D3D11TextureCore*>(mOwnerTexture.get());
+		D3D11Texture* d3d11Texture = static_cast<D3D11Texture*>(mOwnerTexture.get());
 
 		if ((mDesc.usage & GVU_RANDOMWRITE) != 0)
 			mUAV = createUAV(d3d11Texture, mDesc.mostDetailMip, mDesc.firstArraySlice, mDesc.numArraySlices);
@@ -37,7 +37,7 @@ namespace bs { namespace ct
 		SAFE_RELEASE(mRTV);
 	}
 
-	ID3D11ShaderResourceView* D3D11TextureView::createSRV(D3D11TextureCore* texture, 
+	ID3D11ShaderResourceView* D3D11TextureView::createSRV(D3D11Texture* texture, 
 		UINT32 mostDetailMip, UINT32 numMips, UINT32 firstArraySlice, UINT32 numArraySlices)
 	{
 		D3D11_SHADER_RESOURCE_VIEW_DESC desc;
@@ -137,7 +137,7 @@ namespace bs { namespace ct
 		return srv;
 	}
 
-	ID3D11RenderTargetView* D3D11TextureView::createRTV(D3D11TextureCore* texture,
+	ID3D11RenderTargetView* D3D11TextureView::createRTV(D3D11Texture* texture,
 		UINT32 mipSlice, UINT32 firstArraySlice, UINT32 numArraySlices)
 	{
 		D3D11_RENDER_TARGET_VIEW_DESC desc;
@@ -224,7 +224,7 @@ namespace bs { namespace ct
 		return rtv;
 	}
 
-	ID3D11UnorderedAccessView* D3D11TextureView::createUAV(D3D11TextureCore* texture,
+	ID3D11UnorderedAccessView* D3D11TextureView::createUAV(D3D11Texture* texture,
 		UINT32 mipSlice, UINT32 firstArraySlice, UINT32 numArraySlices)
 	{
 		D3D11_UNORDERED_ACCESS_VIEW_DESC desc;
@@ -295,7 +295,7 @@ namespace bs { namespace ct
 		return uav;
 	}
 
-	ID3D11DepthStencilView* D3D11TextureView::createDSV(D3D11TextureCore* texture,
+	ID3D11DepthStencilView* D3D11TextureView::createDSV(D3D11Texture* texture,
 		UINT32 mipSlice, UINT32 firstArraySlice, UINT32 numArraySlices, bool readOnly)
 	{
 		D3D11_DEPTH_STENCIL_VIEW_DESC desc;

+ 8 - 8
Source/BansheeD3D11RenderAPI/Source/BsD3D11VertexBuffer.cpp

@@ -6,7 +6,7 @@
 
 namespace bs { namespace ct
 {
-	D3D11VertexBufferCore::D3D11VertexBufferCore(D3D11Device& device, const VERTEX_BUFFER_DESC& desc, 
+	D3D11VertexBuffer::D3D11VertexBuffer(D3D11Device& device, const VERTEX_BUFFER_DESC& desc, 
 		GpuDeviceFlags deviceMask)
 		: VertexBufferCore(desc, deviceMask), mBuffer(nullptr), mDevice(device), mStreamOut(desc.streamOut)
 		, mUsage(desc.usage)
@@ -14,7 +14,7 @@ namespace bs { namespace ct
 		assert((deviceMask == GDF_DEFAULT || deviceMask == GDF_PRIMARY) && "Multiple GPUs not supported natively on DirectX 11.");
 	}
 
-	D3D11VertexBufferCore::~D3D11VertexBufferCore()
+	D3D11VertexBuffer::~D3D11VertexBuffer()
 	{
 		if (mBuffer != nullptr)
 			bs_delete(mBuffer);
@@ -22,7 +22,7 @@ namespace bs { namespace ct
 		BS_INC_RENDER_STAT_CAT(ResDestroyed, RenderStatObject_VertexBuffer);
 	}
 
-	void* D3D11VertexBufferCore::map(UINT32 offset, UINT32 length, GpuLockOptions options, UINT32 deviceIdx, UINT32 queueIdx)
+	void* D3D11VertexBuffer::map(UINT32 offset, UINT32 length, GpuLockOptions options, UINT32 deviceIdx, UINT32 queueIdx)
 	{
 #if BS_PROFILING_ENABLED
 		if (options == GBL_READ_ONLY || options == GBL_READ_WRITE)
@@ -39,31 +39,31 @@ namespace bs { namespace ct
 		return mBuffer->lock(offset, length, options);
 	}
 
-	void D3D11VertexBufferCore::unmap()
+	void D3D11VertexBuffer::unmap()
 	{
 		mBuffer->unlock();
 	}
 
-	void D3D11VertexBufferCore::readData(UINT32 offset, UINT32 length, void* dest, UINT32 deviceIdx, UINT32 queueIdx)
+	void D3D11VertexBuffer::readData(UINT32 offset, UINT32 length, void* dest, UINT32 deviceIdx, UINT32 queueIdx)
 	{
 		mBuffer->readData(offset, length, dest);
 		BS_INC_RENDER_STAT_CAT(ResRead, RenderStatObject_VertexBuffer);
 	}
 
-	void D3D11VertexBufferCore::writeData(UINT32 offset, UINT32 length, const void* source, BufferWriteType writeFlags, 
+	void D3D11VertexBuffer::writeData(UINT32 offset, UINT32 length, const void* source, BufferWriteType writeFlags, 
 		UINT32 queueIdx)
 	{
 		mBuffer->writeData(offset, length, source, writeFlags);
 		BS_INC_RENDER_STAT_CAT(ResWrite, RenderStatObject_VertexBuffer);
 	}
 
-	void D3D11VertexBufferCore::copyData(HardwareBuffer& srcBuffer, UINT32 srcOffset,
+	void D3D11VertexBuffer::copyData(HardwareBuffer& srcBuffer, UINT32 srcOffset,
 		UINT32 dstOffset, UINT32 length, bool discardWholeBuffer, UINT32 queueIdx)
 	{
 		mBuffer->copyData(srcBuffer, srcOffset, dstOffset, length, discardWholeBuffer);
 	}
 
-	void D3D11VertexBufferCore::initialize()
+	void D3D11VertexBuffer::initialize()
 	{
 		mBuffer = bs_new<D3D11HardwareBuffer>(D3D11HardwareBuffer::BT_VERTEX, 
 											  mUsage, 1, mSize, std::ref(mDevice), false, mStreamOut);

+ 6 - 6
Source/BansheeEditor/Include/BsScenePicking.h

@@ -29,7 +29,7 @@ namespace bs
 		float depth;
 	};
 
-	namespace ct { class ScenePickingCore; }
+	namespace ct { class ScenePicking; }
 
 	/**	Handles picking of scene objects with a pointer in scene view. */
 	class BS_ED_EXPORT ScenePicking : public Module<ScenePicking>
@@ -80,7 +80,7 @@ namespace bs
 			Vector<HSceneObject>& ignoreRenderables, SnapData* data = nullptr);
 
 	private:
-		friend class ct::ScenePickingCore;
+		friend class ct::ScenePicking;
 
 		typedef Set<RenderablePickData, std::function<bool(const RenderablePickData&, const RenderablePickData&)>> RenderableSet;
 
@@ -90,7 +90,7 @@ namespace bs
 		/** Decodes a color into a unique object identifier. Color should have initially been encoded with encodeIndex(). */
 		static UINT32 decodeIndex(Color color);
 
-		ct::ScenePickingCore* mCore;
+		ct::ScenePicking* mCore;
 	};
 
 	/** @} */
@@ -110,7 +110,7 @@ namespace bs
 	extern PickingParamBlockDef gPickingParamBlockDef;
 
 	/** Core thread version of the ScenePicking manager. Handles actual rendering. */
-	class ScenePickingCore
+	class ScenePicking
 	{
 	public:
 		/**	Initializes the manager. Must be called right after construction. */
@@ -131,7 +131,7 @@ namespace bs
 		 * @param[in]	area			Width/height of the area to pick objects, in pixels.
 		 */
 		void corePickingBegin(const SPtr<RenderTargetCore>& target, const Rect2& viewportArea, 
-			const ScenePicking::RenderableSet& renderables, const Vector2I& position, const Vector2I& area);
+			const bs::ScenePicking::RenderableSet& renderables, const Vector2I& position, const Vector2I& area);
 		
 		/**
 		 * Ends picking operation started by corePickingBegin(). Render target is resolved and objects in the picked area
@@ -149,7 +149,7 @@ namespace bs
 			const Vector2I& area, bool gatherSnapData, AsyncOp& asyncOp);
 
 	private:
-		friend class ScenePicking;
+		friend class bs::ScenePicking;
 
 		static const float ALPHA_CUTOFF;
 

+ 14 - 14
Source/BansheeEditor/Source/BsScenePicking.cpp

@@ -32,7 +32,7 @@ namespace bs
 {
 	ScenePicking::ScenePicking()
 	{
-		mCore = bs_new<ct::ScenePickingCore>();
+		mCore = bs_new<ct::ScenePicking>();
 
 		for (UINT32 i = 0; i < 3; i++)
 		{
@@ -43,12 +43,12 @@ namespace bs
 			mCore->mMaterials[3 + i] = matPickingAlpha->getCore();
 		}
 
-		gCoreThread().queueCommand(std::bind(&ct::ScenePickingCore::initialize, mCore));
+		gCoreThread().queueCommand(std::bind(&ct::ScenePicking::initialize, mCore));
 	}
 
 	ScenePicking::~ScenePicking()
 	{
-		gCoreThread().queueCommand(std::bind(&ct::ScenePickingCore::destroy, mCore));
+		gCoreThread().queueCommand(std::bind(&ct::ScenePicking::destroy, mCore));
 	}
 
 	HSceneObject ScenePicking::pickClosestObject(const SPtr<Camera>& cam, const Vector2I& position, const Vector2I& area, 
@@ -175,12 +175,12 @@ namespace bs
 		UINT32 firstGizmoIdx = (UINT32)pickData.size();
 
 		SPtr<ct::RenderTargetCore> target = cam->getViewport()->getTarget()->getCore();
-		gCoreThread().queueCommand(std::bind(&ct::ScenePickingCore::corePickingBegin, mCore, target,
+		gCoreThread().queueCommand(std::bind(&ct::ScenePicking::corePickingBegin, mCore, target,
 			cam->getViewport()->getNormArea(), std::cref(pickData), position, area));
 
 		GizmoManager::instance().renderForPicking(cam, [&](UINT32 inputIdx) { return encodeIndex(firstGizmoIdx + inputIdx); });
 
-		AsyncOp op = gCoreThread().queueReturnCommand(std::bind(&ct::ScenePickingCore::corePickingEnd, mCore, target,
+		AsyncOp op = gCoreThread().queueReturnCommand(std::bind(&ct::ScenePicking::corePickingEnd, mCore, target,
 			cam->getViewport()->getNormArea(), position, area, data != nullptr, _1));
 		gCoreThread().submit(true);
 
@@ -243,22 +243,22 @@ namespace bs
 
 	namespace ct
 	{
-	const float ScenePickingCore::ALPHA_CUTOFF = 0.5f;
+	const float ScenePicking::ALPHA_CUTOFF = 0.5f;
 
 	PickingParamBlockDef gPickingParamBlockDef;
 
-	void ScenePickingCore::initialize()
+	void ScenePicking::initialize()
 	{
 		// Do nothing
 	}
 
-	void ScenePickingCore::destroy()
+	void ScenePicking::destroy()
 	{
 		bs_delete(this);
 	}
 
-	void ScenePickingCore::corePickingBegin(const SPtr<RenderTargetCore>& target, const Rect2& viewportArea,
-		const ScenePicking::RenderableSet& renderables, const Vector2I& position, const Vector2I& area)
+	void ScenePicking::corePickingBegin(const SPtr<RenderTargetCore>& target, const Rect2& viewportArea,
+		const bs::ScenePicking::RenderableSet& renderables, const Vector2I& position, const Vector2I& area)
 	{
 		RenderAPICore& rs = RenderAPICore::instance();
 
@@ -335,7 +335,7 @@ namespace bs
 
 			paramsSet->setParamBlockBuffer("Uniforms", paramBuffer, true);
 
-			Color color = ScenePicking::encodeIndex(renderable.index);
+			Color color = bs::ScenePicking::encodeIndex(renderable.index);
 
 			gPickingParamBlockDef.gMatViewProj.set(paramBuffer, renderable.wvpTransform);
 			gPickingParamBlockDef.gAlphaCutoff.set(paramBuffer, ALPHA_CUTOFF);
@@ -377,7 +377,7 @@ namespace bs
 		bs_stack_free(renderableIndices);
 	}
 
-	void ScenePickingCore::corePickingEnd(const SPtr<RenderTargetCore>& target, const Rect2& viewportArea, 
+	void ScenePicking::corePickingEnd(const SPtr<RenderTargetCore>& target, const Rect2& viewportArea, 
 		const Vector2I& position, const Vector2I& area, bool gatherSnapData, AsyncOp& asyncOp)
 	{
 		const RenderTargetProperties& rtProps = target->getProperties();
@@ -428,7 +428,7 @@ namespace bs
 				for (UINT32 x = (UINT32)position.x; x < maxWidth; x++)
 				{
 					Color color = outputPixelData->getColorAt(x, vertOffset - y);
-					UINT32 index = ScenePicking::decodeIndex(color);
+					UINT32 index = bs::ScenePicking::decodeIndex(color);
 
 					if (index == 0x00FFFFFF) // Nothing selected
 						continue;
@@ -448,7 +448,7 @@ namespace bs
 				for (UINT32 x = (UINT32)position.x; x < maxWidth; x++)
 				{
 					Color color = outputPixelData->getColorAt(x, y);
-					UINT32 index = ScenePicking::decodeIndex(color);
+					UINT32 index = bs::ScenePicking::decodeIndex(color);
 
 					if (index == 0x00FFFFFF) // Nothing selected
 						continue;