Browse Source

Atomic Namespace and running on Direct3D11

JoshEngebretson 10 years ago
parent
commit
36cb48ace8
29 changed files with 108 additions and 76 deletions
  1. 15 1
      CMake/Modules/AtomicWindows.cmake
  2. 5 1
      Source/Atomic/CMakeLists.txt
  3. 1 1
      Source/Atomic/Graphics/Direct3D11/D3D11ConstantBuffer.cpp
  4. 2 2
      Source/Atomic/Graphics/Direct3D11/D3D11ConstantBuffer.h
  5. 1 1
      Source/Atomic/Graphics/Direct3D11/D3D11GPUObject.cpp
  6. 2 2
      Source/Atomic/Graphics/Direct3D11/D3D11GPUObject.h
  7. 39 31
      Source/Atomic/Graphics/Direct3D11/D3D11Graphics.cpp
  8. 10 4
      Source/Atomic/Graphics/Direct3D11/D3D11Graphics.h
  9. 1 1
      Source/Atomic/Graphics/Direct3D11/D3D11GraphicsImpl.cpp
  10. 3 3
      Source/Atomic/Graphics/Direct3D11/D3D11GraphicsImpl.h
  11. 1 1
      Source/Atomic/Graphics/Direct3D11/D3D11IndexBuffer.cpp
  12. 2 2
      Source/Atomic/Graphics/Direct3D11/D3D11IndexBuffer.h
  13. 1 1
      Source/Atomic/Graphics/Direct3D11/D3D11RenderSurface.cpp
  14. 2 2
      Source/Atomic/Graphics/Direct3D11/D3D11RenderSurface.h
  15. 2 2
      Source/Atomic/Graphics/Direct3D11/D3D11ShaderProgram.h
  16. 1 1
      Source/Atomic/Graphics/Direct3D11/D3D11ShaderVariation.cpp
  17. 2 2
      Source/Atomic/Graphics/Direct3D11/D3D11ShaderVariation.h
  18. 1 1
      Source/Atomic/Graphics/Direct3D11/D3D11Texture.cpp
  19. 2 2
      Source/Atomic/Graphics/Direct3D11/D3D11Texture.h
  20. 1 1
      Source/Atomic/Graphics/Direct3D11/D3D11Texture2D.cpp
  21. 2 2
      Source/Atomic/Graphics/Direct3D11/D3D11Texture2D.h
  22. 1 1
      Source/Atomic/Graphics/Direct3D11/D3D11Texture3D.cpp
  23. 2 2
      Source/Atomic/Graphics/Direct3D11/D3D11Texture3D.h
  24. 1 1
      Source/Atomic/Graphics/Direct3D11/D3D11TextureCube.cpp
  25. 2 2
      Source/Atomic/Graphics/Direct3D11/D3D11TextureCube.h
  26. 1 1
      Source/Atomic/Graphics/Direct3D11/D3D11VertexBuffer.cpp
  27. 2 2
      Source/Atomic/Graphics/Direct3D11/D3D11VertexBuffer.h
  28. 1 1
      Source/Atomic/Graphics/Direct3D11/D3D11VertexDeclaration.cpp
  29. 2 2
      Source/Atomic/Graphics/Direct3D11/D3D11VertexDeclaration.h

+ 15 - 1
CMake/Modules/AtomicWindows.cmake

@@ -8,7 +8,21 @@ set (D3DCOMPILER_47_DLL ${CMAKE_SOURCE_DIR}/Build/Windows/Binaries/x64/D3DCompil
 
 
 add_definitions(-DATOMIC_PLATFORM_WINDOWS -D_CRT_SECURE_NO_WARNINGS -DATOMIC_TBUI)
 add_definitions(-DATOMIC_PLATFORM_WINDOWS -D_CRT_SECURE_NO_WARNINGS -DATOMIC_TBUI)
 
 
-list (APPEND ATOMIC_LINK_LIBRARIES MojoShader user32 gdi32 winmm imm32 ole32 oleaut32 version uuid d3d9 d3dcompiler Ws2_32)
+list (APPEND ATOMIC_LINK_LIBRARIES MojoShader user32 gdi32 winmm imm32 ole32 oleaut32 version uuid Ws2_32)
+
+if (ATOMIC_D3D11)
+
+    add_definitions(-DATOMIC_D3D11)
+
+    list (APPEND ATOMIC_LINK_LIBRARIES d3d11 d3dcompiler dxguid)
+
+else()
+
+    list (APPEND ATOMIC_LINK_LIBRARIES  d3d9 d3dcompiler)
+
+endif()
+
+
 
 
 # compile with static runtime
 # compile with static runtime
 set(CompilerFlags CMAKE_CXX_FLAGS CMAKE_CXX_FLAGS_DEBUG CMAKE_CXX_FLAGS_RELEASE CMAKE_C_FLAGS CMAKE_C_FLAGS_DEBUG CMAKE_C_FLAGS_RELEASE)
 set(CompilerFlags CMAKE_CXX_FLAGS CMAKE_CXX_FLAGS_DEBUG CMAKE_CXX_FLAGS_RELEASE CMAKE_C_FLAGS CMAKE_C_FLAGS_DEBUG CMAKE_C_FLAGS_RELEASE)

+ 5 - 1
Source/Atomic/CMakeLists.txt

@@ -34,7 +34,11 @@ endif()
 file (GLOB GRAPHICS_SOURCE Graphics/*.cpp Graphics/*.h)
 file (GLOB GRAPHICS_SOURCE Graphics/*.cpp Graphics/*.h)
 
 
 if (MSVC)
 if (MSVC)
-    file (GLOB GRAPHICS_IMPL_SOURCE Graphics/Direct3D9/*.cpp Graphics/Direct3D9/*.h)
+    if (ATOMIC_D3D11)  
+      file (GLOB GRAPHICS_IMPL_SOURCE Graphics/Direct3D11/*.cpp Graphics/Direct3D11/*.h)
+    else()
+      file (GLOB GRAPHICS_IMPL_SOURCE Graphics/Direct3D9/*.cpp Graphics/Direct3D9/*.h)
+    endif()  
 else()
 else()
 
 
 # for kNet
 # for kNet

+ 1 - 1
Source/Atomic/Graphics/Direct3D11/D3D11ConstantBuffer.cpp

@@ -27,7 +27,7 @@
 
 
 #include "../../DebugNew.h"
 #include "../../DebugNew.h"
 
 
-namespace Urho3D
+namespace Atomic
 {
 {
 
 
 
 

+ 2 - 2
Source/Atomic/Graphics/Direct3D11/D3D11ConstantBuffer.h

@@ -27,11 +27,11 @@
 #include "../../Container/ArrayPtr.h"
 #include "../../Container/ArrayPtr.h"
 #include "../../Core/Object.h"
 #include "../../Core/Object.h"
 
 
-namespace Urho3D
+namespace Atomic
 {
 {
 
 
 /// Hardware constant buffer.
 /// Hardware constant buffer.
-class URHO3D_API ConstantBuffer : public Object, public GPUObject
+class ATOMIC_API ConstantBuffer : public Object, public GPUObject
 {
 {
     OBJECT(ConstantBuffer);
     OBJECT(ConstantBuffer);
     
     

+ 1 - 1
Source/Atomic/Graphics/Direct3D11/D3D11GPUObject.cpp

@@ -26,7 +26,7 @@
 
 
 #include "../../DebugNew.h"
 #include "../../DebugNew.h"
 
 
-namespace Urho3D
+namespace Atomic
 {
 {
 
 
 GPUObject::GPUObject(Graphics* graphics) :
 GPUObject::GPUObject(Graphics* graphics) :

+ 2 - 2
Source/Atomic/Graphics/Direct3D11/D3D11GPUObject.h

@@ -24,13 +24,13 @@
 
 
 #include "../../Container/Ptr.h"
 #include "../../Container/Ptr.h"
 
 
-namespace Urho3D
+namespace Atomic
 {
 {
 
 
 class Graphics;
 class Graphics;
 
 
 /// Base class for GPU resources.
 /// Base class for GPU resources.
-class URHO3D_API GPUObject
+class ATOMIC_API GPUObject
 {
 {
 public:
 public:
     /// Construct with graphics subsystem pointer.
     /// Construct with graphics subsystem pointer.

+ 39 - 31
Source/Atomic/Graphics/Direct3D11/D3D11Graphics.cpp

@@ -20,15 +20,10 @@
 // THE SOFTWARE.
 // THE SOFTWARE.
 //
 //
 
 
-#include "../../Graphics/AnimatedModel.h"
-#include "../../Graphics/Animation.h"
-#include "../../Graphics/AnimationController.h"
 #include "../../Graphics/Camera.h"
 #include "../../Graphics/Camera.h"
 #include "../../Graphics/ConstantBuffer.h"
 #include "../../Graphics/ConstantBuffer.h"
 #include "../../Core/Context.h"
 #include "../../Core/Context.h"
-#include "../../Graphics/CustomGeometry.h"
 #include "../../Graphics/DebugRenderer.h"
 #include "../../Graphics/DebugRenderer.h"
-#include "../../Graphics/DecalSet.h"
 #include "../../IO/File.h"
 #include "../../IO/File.h"
 #include "../../Graphics/Geometry.h"
 #include "../../Graphics/Geometry.h"
 #include "../../Graphics/Graphics.h"
 #include "../../Graphics/Graphics.h"
@@ -38,8 +33,6 @@
 #include "../../IO/Log.h"
 #include "../../IO/Log.h"
 #include "../../Graphics/Material.h"
 #include "../../Graphics/Material.h"
 #include "../../Graphics/Octree.h"
 #include "../../Graphics/Octree.h"
-#include "../../Graphics/ParticleEffect.h"
-#include "../../Graphics/ParticleEmitter.h"
 #include "../../Core/ProcessUtils.h"
 #include "../../Core/ProcessUtils.h"
 #include "../../Core/Profiler.h"
 #include "../../Core/Profiler.h"
 #include "../../Graphics/Renderer.h"
 #include "../../Graphics/Renderer.h"
@@ -48,11 +41,7 @@
 #include "../../Graphics/ShaderPrecache.h"
 #include "../../Graphics/ShaderPrecache.h"
 #include "../../Graphics/ShaderProgram.h"
 #include "../../Graphics/ShaderProgram.h"
 #include "../../Graphics/ShaderVariation.h"
 #include "../../Graphics/ShaderVariation.h"
-#include "../../Graphics/Skybox.h"
-#include "../../Graphics/StaticModelGroup.h"
 #include "../../Graphics/Technique.h"
 #include "../../Graphics/Technique.h"
-#include "../../Graphics/Terrain.h"
-#include "../../Graphics/TerrainPatch.h"
 #include "../../Graphics/Texture2D.h"
 #include "../../Graphics/Texture2D.h"
 #include "../../Graphics/Texture3D.h"
 #include "../../Graphics/Texture3D.h"
 #include "../../Graphics/TextureCube.h"
 #include "../../Graphics/TextureCube.h"
@@ -61,7 +50,7 @@
 #include "../../Graphics/VertexDeclaration.h"
 #include "../../Graphics/VertexDeclaration.h"
 #include "../../Graphics/Zone.h"
 #include "../../Graphics/Zone.h"
 
 
-#include <SDL/SDL_syswm.h>
+#include <SDL/include/SDL_syswm.h>
 
 
 #include "../../DebugNew.h"
 #include "../../DebugNew.h"
 
 
@@ -74,7 +63,7 @@ extern "C" {
     __declspec(dllexport) DWORD NvOptimusEnablement = 0x00000001;
     __declspec(dllexport) DWORD NvOptimusEnablement = 0x00000001;
 }
 }
 
 
-namespace Urho3D
+namespace Atomic
 {
 {
 
 
 static const D3D11_COMPARISON_FUNC d3dCmpFunc[] =
 static const D3D11_COMPARISON_FUNC d3dCmpFunc[] =
@@ -376,6 +365,39 @@ void Graphics::SetWindowPosition(int x, int y)
     SetWindowPosition(IntVector2(x, y));
     SetWindowPosition(IntVector2(x, y));
 }
 }
 
 
+void Graphics::SetWindowSize(int width, int height)
+{
+    if (impl_->window_)
+    {
+        SDL_SetWindowSize(impl_->window_, width, height);
+        WindowResized();
+    }
+}
+
+void Graphics::CenterWindow()
+{
+    if (impl_->window_)
+    {
+        SDL_DisplayMode mode;
+        SDL_GetDesktopDisplayMode(0, &mode);
+
+        int width, height;
+        SDL_GetWindowSize(impl_->window_, &width, &height);
+
+        int x = mode.w / 2 - width / 2;
+        int y = mode.h / 2 - height / 2;
+
+        SetWindowPosition(x, y);
+
+    }
+}
+
+void Graphics::RaiseWindow()
+{
+    if (impl_->window_)
+        SDL_RaiseWindow(impl_->window_);
+}
+
 bool Graphics::SetMode(int width, int height, bool fullscreen, bool borderless, bool resizable, bool vsync, bool tripleBuffer, int multiSample)
 bool Graphics::SetMode(int width, int height, bool fullscreen, bool borderless, bool resizable, bool vsync, bool tripleBuffer, int multiSample)
 {
 {
     PROFILE(SetScreenMode);
     PROFILE(SetScreenMode);
@@ -554,7 +576,7 @@ void Graphics::Close()
     }
     }
 }
 }
 
 
-bool Graphics::TakeScreenShot(Image& destImage)
+bool Graphics::TakeScreenShot(Image* destImage)
 {
 {
     PROFILE(TakeScreenShot);
     PROFILE(TakeScreenShot);
 
 
@@ -612,8 +634,8 @@ bool Graphics::TakeScreenShot(Image& destImage)
     mappedData.pData = 0;
     mappedData.pData = 0;
     impl_->deviceContext_->Map(stagingTexture, 0, D3D11_MAP_READ, 0, &mappedData);
     impl_->deviceContext_->Map(stagingTexture, 0, D3D11_MAP_READ, 0, &mappedData);
 
 
-    destImage.SetSize(width_, height_, 3);
-    unsigned char* destData = destImage.GetData();
+    destImage->SetSize(width_, height_, 3);
+    unsigned char* destData = destImage->GetData();
     if (mappedData.pData)
     if (mappedData.pData)
     {
     {
         for (int y = 0; y < height_; ++y)
         for (int y = 0; y < height_; ++y)
@@ -2697,10 +2719,8 @@ void Graphics::SetTextureUnitMappings()
 }
 }
 
 
 void RegisterGraphicsLibrary(Context* context)
 void RegisterGraphicsLibrary(Context* context)
-{
-    Animation::RegisterObject(context);
+{ 
     Material::RegisterObject(context);
     Material::RegisterObject(context);
-    Model::RegisterObject(context);
     Shader::RegisterObject(context);
     Shader::RegisterObject(context);
     Technique::RegisterObject(context);
     Technique::RegisterObject(context);
     Texture2D::RegisterObject(context);
     Texture2D::RegisterObject(context);
@@ -2709,18 +2729,6 @@ void RegisterGraphicsLibrary(Context* context)
     Camera::RegisterObject(context);
     Camera::RegisterObject(context);
     Drawable::RegisterObject(context);
     Drawable::RegisterObject(context);
     Light::RegisterObject(context);
     Light::RegisterObject(context);
-    StaticModel::RegisterObject(context);
-    StaticModelGroup::RegisterObject(context);
-    Skybox::RegisterObject(context);
-    AnimatedModel::RegisterObject(context);
-    AnimationController::RegisterObject(context);
-    BillboardSet::RegisterObject(context);
-    ParticleEffect::RegisterObject(context);
-    ParticleEmitter::RegisterObject(context);
-    CustomGeometry::RegisterObject(context);
-    DecalSet::RegisterObject(context);
-    Terrain::RegisterObject(context);
-    TerrainPatch::RegisterObject(context);
     DebugRenderer::RegisterObject(context);
     DebugRenderer::RegisterObject(context);
     Octree::RegisterObject(context);
     Octree::RegisterObject(context);
     Zone::RegisterObject(context);
     Zone::RegisterObject(context);

+ 10 - 4
Source/Atomic/Graphics/Direct3D11/D3D11Graphics.h

@@ -33,7 +33,7 @@
 #include "../../Graphics/GraphicsDefs.h"
 #include "../../Graphics/GraphicsDefs.h"
 #include "../../Graphics/ShaderVariation.h"
 #include "../../Graphics/ShaderVariation.h"
 
 
-namespace Urho3D
+namespace Atomic
 {
 {
 
 
 class ConstantBuffer;
 class ConstantBuffer;
@@ -77,7 +77,7 @@ struct ScratchBuffer
 typedef HashMap<Pair<ShaderVariation*, ShaderVariation*>, SharedPtr<ShaderProgram> > ShaderProgramMap;
 typedef HashMap<Pair<ShaderVariation*, ShaderVariation*>, SharedPtr<ShaderProgram> > ShaderProgramMap;
 
 
 /// %Graphics subsystem. Manages the application window, rendering state and GPU resources.
 /// %Graphics subsystem. Manages the application window, rendering state and GPU resources.
-class URHO3D_API Graphics : public Object
+class ATOMIC_API Graphics : public Object
 {
 {
     OBJECT(Graphics);
     OBJECT(Graphics);
     
     
@@ -97,6 +97,12 @@ public:
     void SetWindowPosition(const IntVector2& position);
     void SetWindowPosition(const IntVector2& position);
     /// Set window position. Sets initial position if window is not created yet.
     /// Set window position. Sets initial position if window is not created yet.
     void SetWindowPosition(int x, int y);
     void SetWindowPosition(int x, int y);
+    /// Set window size.
+    void SetWindowSize(int width, int height);
+    /// Center window.
+    void CenterWindow();
+    /// Bring the window to front with focus
+    void RaiseWindow();
     /// Set screen mode. Return true if successful.
     /// Set screen mode. Return true if successful.
     bool SetMode(int width, int height, bool fullscreen, bool borderless, bool resizable, bool vsync, bool tripleBuffer, int multiSample);
     bool SetMode(int width, int height, bool fullscreen, bool borderless, bool resizable, bool vsync, bool tripleBuffer, int multiSample);
     /// Set screen resolution only. Return true if successful.
     /// Set screen resolution only. Return true if successful.
@@ -112,7 +118,7 @@ public:
     /// Close the window.
     /// Close the window.
     void Close();
     void Close();
     /// Take a screenshot. Return true if successful.
     /// Take a screenshot. Return true if successful.
-    bool TakeScreenShot(Image& destImage);
+    bool TakeScreenShot(Image* destImage);
     /// Begin frame rendering. Return true if device available and can render.
     /// Begin frame rendering. Return true if device available and can render.
     bool BeginFrame();
     bool BeginFrame();
     /// End frame rendering and swap buffers.
     /// End frame rendering and swap buffers.
@@ -633,6 +639,6 @@ private:
 };
 };
 
 
 /// Register Graphics library objects.
 /// Register Graphics library objects.
-void URHO3D_API RegisterGraphicsLibrary(Context* context);
+void ATOMIC_API RegisterGraphicsLibrary(Context* context);
 
 
 }
 }

+ 1 - 1
Source/Atomic/Graphics/Direct3D11/D3D11GraphicsImpl.cpp

@@ -26,7 +26,7 @@
 
 
 #include "../../DebugNew.h"
 #include "../../DebugNew.h"
 
 
-namespace Urho3D
+namespace Atomic
 {
 {
 
 
 GraphicsImpl::GraphicsImpl() :
 GraphicsImpl::GraphicsImpl() :

+ 3 - 3
Source/Atomic/Graphics/Direct3D11/D3D11GraphicsImpl.h

@@ -27,13 +27,13 @@
 
 
 #include <d3d11.h>
 #include <d3d11.h>
 #include <dxgi.h>
 #include <dxgi.h>
-#include <SDL/SDL.h>
+#include <SDL/include/SDL.h>
 
 
-namespace Urho3D
+namespace Atomic
 {
 {
 
 
 /// %Graphics implementation. Holds API-specific objects.
 /// %Graphics implementation. Holds API-specific objects.
-class URHO3D_API GraphicsImpl
+class ATOMIC_API GraphicsImpl
 {
 {
     friend class Graphics;
     friend class Graphics;
     
     

+ 1 - 1
Source/Atomic/Graphics/Direct3D11/D3D11IndexBuffer.cpp

@@ -28,7 +28,7 @@
 
 
 #include "../../DebugNew.h"
 #include "../../DebugNew.h"
 
 
-namespace Urho3D
+namespace Atomic
 {
 {
 
 
 IndexBuffer::IndexBuffer(Context* context) :
 IndexBuffer::IndexBuffer(Context* context) :

+ 2 - 2
Source/Atomic/Graphics/Direct3D11/D3D11IndexBuffer.h

@@ -27,11 +27,11 @@
 #include "../../Graphics/GraphicsDefs.h"
 #include "../../Graphics/GraphicsDefs.h"
 #include "../../Container/ArrayPtr.h"
 #include "../../Container/ArrayPtr.h"
 
 
-namespace Urho3D
+namespace Atomic
 {
 {
 
 
 /// Hardware index buffer.
 /// Hardware index buffer.
-class URHO3D_API IndexBuffer : public Object, public GPUObject
+class ATOMIC_API IndexBuffer : public Object, public GPUObject
 {
 {
     OBJECT(IndexBuffer);
     OBJECT(IndexBuffer);
     
     

+ 1 - 1
Source/Atomic/Graphics/Direct3D11/D3D11RenderSurface.cpp

@@ -31,7 +31,7 @@
 
 
 #include "../../DebugNew.h"
 #include "../../DebugNew.h"
 
 
-namespace Urho3D
+namespace Atomic
 {
 {
 
 
 RenderSurface::RenderSurface(Texture* parentTexture) :
 RenderSurface::RenderSurface(Texture* parentTexture) :

+ 2 - 2
Source/Atomic/Graphics/Direct3D11/D3D11RenderSurface.h

@@ -25,13 +25,13 @@
 #include "../../Graphics/GraphicsDefs.h"
 #include "../../Graphics/GraphicsDefs.h"
 #include "../../Graphics/Viewport.h"
 #include "../../Graphics/Viewport.h"
 
 
-namespace Urho3D
+namespace Atomic
 {
 {
 
 
 class Texture;
 class Texture;
 
 
 /// %Color or depth-stencil surface that can be rendered into.
 /// %Color or depth-stencil surface that can be rendered into.
-class URHO3D_API RenderSurface : public RefCounted
+class ATOMIC_API RenderSurface : public RefCounted
 {
 {
     friend class Texture2D;
     friend class Texture2D;
     friend class TextureCube;
     friend class TextureCube;

+ 2 - 2
Source/Atomic/Graphics/Direct3D11/D3D11ShaderProgram.h

@@ -27,11 +27,11 @@
 #include "../../Graphics/Graphics.h"
 #include "../../Graphics/Graphics.h"
 #include "../../Graphics/ShaderVariation.h"
 #include "../../Graphics/ShaderVariation.h"
 
 
-namespace Urho3D
+namespace Atomic
 {
 {
 
 
 /// Combined information for specific vertex and pixel shaders.
 /// Combined information for specific vertex and pixel shaders.
-class URHO3D_API ShaderProgram : public RefCounted
+class ATOMIC_API ShaderProgram : public RefCounted
 {
 {
 public:
 public:
     /// Construct.
     /// Construct.

+ 1 - 1
Source/Atomic/Graphics/Direct3D11/D3D11ShaderVariation.cpp

@@ -35,7 +35,7 @@
 
 
 #include "../../DebugNew.h"
 #include "../../DebugNew.h"
 
 
-namespace Urho3D
+namespace Atomic
 {
 {
 
 
 ShaderVariation::ShaderVariation(Shader* owner, ShaderType type) :
 ShaderVariation::ShaderVariation(Shader* owner, ShaderType type) :

+ 2 - 2
Source/Atomic/Graphics/Direct3D11/D3D11ShaderVariation.h

@@ -28,7 +28,7 @@
 #include "../../Container/RefCounted.h"
 #include "../../Container/RefCounted.h"
 #include "../../Container/ArrayPtr.h"
 #include "../../Container/ArrayPtr.h"
 
 
-namespace Urho3D
+namespace Atomic
 {
 {
 
 
 class ConstantBuffer;
 class ConstantBuffer;
@@ -73,7 +73,7 @@ struct ShaderParameter
 };
 };
 
 
 /// Vertex or pixel shader on the GPU.
 /// Vertex or pixel shader on the GPU.
-class URHO3D_API ShaderVariation : public RefCounted, public GPUObject
+class ATOMIC_API ShaderVariation : public RefCounted, public GPUObject
 {
 {
 public:
 public:
     /// Construct.
     /// Construct.

+ 1 - 1
Source/Atomic/Graphics/Direct3D11/D3D11Texture.cpp

@@ -33,7 +33,7 @@
 
 
 #include "../../DebugNew.h"
 #include "../../DebugNew.h"
 
 
-namespace Urho3D
+namespace Atomic
 {
 {
 
 
 static const char* addressModeNames[] =
 static const char* addressModeNames[] =

+ 2 - 2
Source/Atomic/Graphics/Direct3D11/D3D11Texture.h

@@ -28,7 +28,7 @@
 #include "../../Graphics/GraphicsDefs.h"
 #include "../../Graphics/GraphicsDefs.h"
 #include "../../Resource/Resource.h"
 #include "../../Resource/Resource.h"
 
 
-namespace Urho3D
+namespace Atomic
 {
 {
 
 
 static const int MAX_TEXTURE_QUALITY_LEVELS = 3;
 static const int MAX_TEXTURE_QUALITY_LEVELS = 3;
@@ -37,7 +37,7 @@ class XMLElement;
 class XMLFile;
 class XMLFile;
 
 
 /// Base class for texture resources.
 /// Base class for texture resources.
-class URHO3D_API Texture : public Resource, public GPUObject
+class ATOMIC_API Texture : public Resource, public GPUObject
 {
 {
 public:
 public:
     /// Construct.
     /// Construct.

+ 1 - 1
Source/Atomic/Graphics/Direct3D11/D3D11Texture2D.cpp

@@ -34,7 +34,7 @@
 
 
 #include "../../DebugNew.h"
 #include "../../DebugNew.h"
 
 
-namespace Urho3D
+namespace Atomic
 {
 {
 
 
 Texture2D::Texture2D(Context* context) :
 Texture2D::Texture2D(Context* context) :

+ 2 - 2
Source/Atomic/Graphics/Direct3D11/D3D11Texture2D.h

@@ -26,14 +26,14 @@
 #include "../../Container/Ptr.h"
 #include "../../Container/Ptr.h"
 #include "../../Graphics/Texture.h"
 #include "../../Graphics/Texture.h"
 
 
-namespace Urho3D
+namespace Atomic
 {
 {
 
 
 class Image;
 class Image;
 class XMLFile;
 class XMLFile;
 
 
 /// 2D texture resource.
 /// 2D texture resource.
-class URHO3D_API Texture2D : public Texture
+class ATOMIC_API Texture2D : public Texture
 {
 {
     OBJECT(Texture2D);
     OBJECT(Texture2D);
     
     

+ 1 - 1
Source/Atomic/Graphics/Direct3D11/D3D11Texture3D.cpp

@@ -34,7 +34,7 @@
 
 
 #include "../../DebugNew.h"
 #include "../../DebugNew.h"
 
 
-namespace Urho3D
+namespace Atomic
 {
 {
 
 
 Texture3D::Texture3D(Context* context) :
 Texture3D::Texture3D(Context* context) :

+ 2 - 2
Source/Atomic/Graphics/Direct3D11/D3D11Texture3D.h

@@ -26,13 +26,13 @@
 #include "../../Container/Ptr.h"
 #include "../../Container/Ptr.h"
 #include "../../Graphics/Texture.h"
 #include "../../Graphics/Texture.h"
 
 
-namespace Urho3D
+namespace Atomic
 {
 {
 
 
 class Image;
 class Image;
 
 
 /// 3D texture resource.
 /// 3D texture resource.
-class URHO3D_API Texture3D : public Texture
+class ATOMIC_API Texture3D : public Texture
 {
 {
     OBJECT(Texture3D);
     OBJECT(Texture3D);
     
     

+ 1 - 1
Source/Atomic/Graphics/Direct3D11/D3D11TextureCube.cpp

@@ -38,7 +38,7 @@
 #pragma warning(disable:4355)
 #pragma warning(disable:4355)
 #endif
 #endif
 
 
-namespace Urho3D
+namespace Atomic
 {
 {
 
 
 static const char* cubeMapLayoutNames[] = {
 static const char* cubeMapLayoutNames[] = {

+ 2 - 2
Source/Atomic/Graphics/Direct3D11/D3D11TextureCube.h

@@ -26,14 +26,14 @@
 #include "../../Container/Ptr.h"
 #include "../../Container/Ptr.h"
 #include "../../Graphics/Texture.h"
 #include "../../Graphics/Texture.h"
 
 
-namespace Urho3D
+namespace Atomic
 {
 {
 
 
 class Deserializer;
 class Deserializer;
 class Image;
 class Image;
 
 
 /// Cube texture resource.
 /// Cube texture resource.
-class URHO3D_API TextureCube : public Texture
+class ATOMIC_API TextureCube : public Texture
 {
 {
     OBJECT(TextureCube);
     OBJECT(TextureCube);
     
     

+ 1 - 1
Source/Atomic/Graphics/Direct3D11/D3D11VertexBuffer.cpp

@@ -27,7 +27,7 @@
 
 
 #include "../../DebugNew.h"
 #include "../../DebugNew.h"
 
 
-namespace Urho3D
+namespace Atomic
 {
 {
 
 
 const unsigned VertexBuffer::elementSize[] =
 const unsigned VertexBuffer::elementSize[] =

+ 2 - 2
Source/Atomic/Graphics/Direct3D11/D3D11VertexBuffer.h

@@ -26,11 +26,11 @@
 #include "../../Graphics/GraphicsDefs.h"
 #include "../../Graphics/GraphicsDefs.h"
 #include "../../Container/ArrayPtr.h"
 #include "../../Container/ArrayPtr.h"
 
 
-namespace Urho3D
+namespace Atomic
 {
 {
 
 
 /// Hardware vertex buffer.
 /// Hardware vertex buffer.
-class URHO3D_API VertexBuffer : public Object, public GPUObject
+class ATOMIC_API VertexBuffer : public Object, public GPUObject
 {
 {
     OBJECT(VertexBuffer);
     OBJECT(VertexBuffer);
     
     

+ 1 - 1
Source/Atomic/Graphics/Direct3D11/D3D11VertexDeclaration.cpp

@@ -29,7 +29,7 @@
 
 
 #include "../../DebugNew.h"
 #include "../../DebugNew.h"
 
 
-namespace Urho3D
+namespace Atomic
 {
 {
 
 
 VertexDeclaration::VertexDeclaration(Graphics* graphics, ShaderVariation* vertexShader, VertexBuffer** vertexBuffers, unsigned* elementMasks) :
 VertexDeclaration::VertexDeclaration(Graphics* graphics, ShaderVariation* vertexShader, VertexBuffer** vertexBuffers, unsigned* elementMasks) :

+ 2 - 2
Source/Atomic/Graphics/Direct3D11/D3D11VertexDeclaration.h

@@ -26,7 +26,7 @@
 #include "../../Container/RefCounted.h"
 #include "../../Container/RefCounted.h"
 #include "../../Container/Vector.h"
 #include "../../Container/Vector.h"
 
 
-namespace Urho3D
+namespace Atomic
 {
 {
 
 
 class Graphics;
 class Graphics;
@@ -34,7 +34,7 @@ class ShaderVariation;
 class VertexBuffer;
 class VertexBuffer;
 
 
 /// Vertex declaration.
 /// Vertex declaration.
-class URHO3D_API VertexDeclaration : public RefCounted
+class ATOMIC_API VertexDeclaration : public RefCounted
 {
 {
 public:
 public:
     /// Construct with vertex buffers and element masks to base declaration on.
     /// Construct with vertex buffers and element masks to base declaration on.