diff --git a/Src/AlphaTestEffect.cpp b/Src/AlphaTestEffect.cpp index 05c290dd..a9c93e6b 100644 --- a/Src/AlphaTestEffect.cpp +++ b/Src/AlphaTestEffect.cpp @@ -43,6 +43,12 @@ class AlphaTestEffect::Impl : public EffectBase public: explicit Impl(_In_ ID3D11Device* device); + Impl(const Impl&) = delete; + Impl& operator=(const Impl&) = delete; + + Impl(Impl&&) = default; + Impl& operator=(Impl&&) = default; + D3D11_COMPARISON_FUNC alphaFunction; int referenceAlpha; diff --git a/Src/BasicEffect.cpp b/Src/BasicEffect.cpp index fefa201e..ffd158d9 100644 --- a/Src/BasicEffect.cpp +++ b/Src/BasicEffect.cpp @@ -54,6 +54,12 @@ class BasicEffect::Impl : public EffectBase public: explicit Impl(_In_ ID3D11Device* device); + Impl(const Impl&) = delete; + Impl& operator=(const Impl&) = delete; + + Impl(Impl&&) = default; + Impl& operator=(Impl&&) = default; + bool lightingEnabled; bool preferPerPixelLighting; bool vertexColorEnabled; diff --git a/Src/DGSLEffect.cpp b/Src/DGSLEffect.cpp index 54b887d4..b6c60702 100644 --- a/Src/DGSLEffect.cpp +++ b/Src/DGSLEffect.cpp @@ -246,6 +246,12 @@ class DGSLEffect::Impl : public AlignedNew static_assert(MaxDirectionalLights == 4, "Mismatch with DGSL pipline"); } + Impl(const Impl&) = delete; + Impl& operator=(const Impl&) = delete; + + Impl(Impl&&) = default; + Impl& operator=(Impl&&) = default; + void Initialize(_In_ ID3D11Device* device, bool enableSkinning) { weightsPerVertex = enableSkinning ? 4 : 0; diff --git a/Src/DebugEffect.cpp b/Src/DebugEffect.cpp index 497a60a0..96b26e63 100644 --- a/Src/DebugEffect.cpp +++ b/Src/DebugEffect.cpp @@ -44,6 +44,12 @@ class DebugEffect::Impl : public EffectBase public: explicit Impl(_In_ ID3D11Device* device); + Impl(const Impl&) = delete; + Impl& operator=(const Impl&) = delete; + + Impl(Impl&&) = default; + Impl& operator=(Impl&&) = default; + bool vertexColorEnabled; bool biasedVertexNormals; bool instancing; diff --git a/Src/DualTextureEffect.cpp b/Src/DualTextureEffect.cpp index 137e2e3a..38e24f75 100644 --- a/Src/DualTextureEffect.cpp +++ b/Src/DualTextureEffect.cpp @@ -43,6 +43,12 @@ class DualTextureEffect::Impl : public EffectBase public: explicit Impl(_In_ ID3D11Device* device); + Impl(const Impl&) = delete; + Impl& operator=(const Impl&) = delete; + + Impl(Impl&&) = default; + Impl& operator=(Impl&&) = default; + bool vertexColorEnabled; EffectColor color; diff --git a/Src/EnvironmentMapEffect.cpp b/Src/EnvironmentMapEffect.cpp index 094f0503..e4900523 100644 --- a/Src/EnvironmentMapEffect.cpp +++ b/Src/EnvironmentMapEffect.cpp @@ -60,6 +60,12 @@ class EnvironmentMapEffect::Impl : public EffectBase public: explicit Impl(_In_ ID3D11Device* device); + Impl(const Impl&) = delete; + Impl& operator=(const Impl&) = delete; + + Impl(Impl&&) = default; + Impl& operator=(Impl&&) = default; + bool preferPerPixelLighting; bool fresnelEnabled; bool specularEnabled; diff --git a/Src/GeometricPrimitive.cpp b/Src/GeometricPrimitive.cpp index db033854..6f40bc18 100644 --- a/Src/GeometricPrimitive.cpp +++ b/Src/GeometricPrimitive.cpp @@ -26,6 +26,12 @@ class GeometricPrimitive::Impl public: Impl() noexcept : mIndexCount(0) {} + Impl(const Impl&) = delete; + Impl& operator=(const Impl&) = delete; + + Impl(Impl&&) = default; + Impl& operator=(Impl&&) = default; + void Initialize(_In_ ID3D11DeviceContext* deviceContext, const VertexCollection& vertices, const IndexCollection& indices); void XM_CALLCONV Draw(FXMMATRIX world, CXMMATRIX view, CXMMATRIX projection, diff --git a/Src/NormalMapEffect.cpp b/Src/NormalMapEffect.cpp index 10f8d19a..54d4b5db 100644 --- a/Src/NormalMapEffect.cpp +++ b/Src/NormalMapEffect.cpp @@ -70,6 +70,12 @@ class NormalMapEffect::Impl : public EffectBase public: explicit Impl(_In_ ID3D11Device* device); + Impl(const Impl&) = delete; + Impl& operator=(const Impl&) = delete; + + Impl(Impl&&) = default; + Impl& operator=(Impl&&) = default; + void Initialize(_In_ ID3D11Device* device, bool enableSkinning); ComPtr normalTexture; diff --git a/Src/PBREffect.cpp b/Src/PBREffect.cpp index b909731c..b910d807 100644 --- a/Src/PBREffect.cpp +++ b/Src/PBREffect.cpp @@ -73,6 +73,12 @@ class PBREffect::Impl : public EffectBase public: explicit Impl(_In_ ID3D11Device* device); + Impl(const Impl&) = delete; + Impl& operator=(const Impl&) = delete; + + Impl(Impl&&) = default; + Impl& operator=(Impl&&) = default; + void Initialize(_In_ ID3D11Device* device, bool enableSkinning); ComPtr albedoTexture; diff --git a/Src/PrimitiveBatch.cpp b/Src/PrimitiveBatch.cpp index e5b99c0a..5e796ece 100644 --- a/Src/PrimitiveBatch.cpp +++ b/Src/PrimitiveBatch.cpp @@ -24,6 +24,12 @@ class PrimitiveBatchBase::Impl public: Impl(_In_ ID3D11DeviceContext* deviceContext, size_t maxIndices, size_t maxVertices, size_t vertexSize); + Impl(const Impl&) = delete; + Impl& operator=(const Impl&) = delete; + + Impl(Impl&&) = default; + Impl& operator=(Impl&&) = default; + void Begin(); void End(); diff --git a/Src/SkinnedEffect.cpp b/Src/SkinnedEffect.cpp index 1c15097d..93ab830b 100644 --- a/Src/SkinnedEffect.cpp +++ b/Src/SkinnedEffect.cpp @@ -56,6 +56,12 @@ class SkinnedEffect::Impl : public EffectBase public: explicit Impl(_In_ ID3D11Device* device); + Impl(const Impl&) = delete; + Impl& operator=(const Impl&) = delete; + + Impl(Impl&&) = default; + Impl& operator=(Impl&&) = default; + bool preferPerPixelLighting; bool biasedVertexNormals; int weightsPerVertex; diff --git a/Src/SpriteBatch.cpp b/Src/SpriteBatch.cpp index d75fe6fb..670f1526 100644 --- a/Src/SpriteBatch.cpp +++ b/Src/SpriteBatch.cpp @@ -63,6 +63,12 @@ XM_ALIGNED_STRUCT(16) SpriteBatch::Impl : public AlignedNew public: explicit Impl(_In_ ID3D11DeviceContext* deviceContext); + Impl(const Impl&) = delete; + Impl& operator=(const Impl&) = delete; + + Impl(Impl&&) = default; + Impl& operator=(Impl&&) = default; + void XM_CALLCONV Begin(SpriteSortMode sortMode, _In_opt_ ID3D11BlendState* blendState, _In_opt_ ID3D11SamplerState* samplerState, diff --git a/Src/SpriteFont.cpp b/Src/SpriteFont.cpp index 65d208d4..6123b04d 100644 --- a/Src/SpriteFont.cpp +++ b/Src/SpriteFont.cpp @@ -33,6 +33,12 @@ class SpriteFont::Impl size_t glyphCount, float lineSpacing) noexcept(false); + Impl(const Impl&) = delete; + Impl& operator=(const Impl&) = delete; + + Impl(Impl&&) = default; + Impl& operator=(Impl&&) = default; + Glyph const* FindGlyph(wchar_t character) const; void SetDefaultCharacter(wchar_t character);