aboutsummaryrefslogtreecommitdiff
path: root/lib/win32/Effects11/EffectVariable.inl
diff options
context:
space:
mode:
Diffstat (limited to 'lib/win32/Effects11/EffectVariable.inl')
-rw-r--r--lib/win32/Effects11/EffectVariable.inl758
1 files changed, 377 insertions, 381 deletions
diff --git a/lib/win32/Effects11/EffectVariable.inl b/lib/win32/Effects11/EffectVariable.inl
index c65c8d69cd..d287e85f56 100644
--- a/lib/win32/Effects11/EffectVariable.inl
+++ b/lib/win32/Effects11/EffectVariable.inl
@@ -4,7 +4,7 @@
// Direct3D 11 Effects Variable reflection template
// These templates define the many Effect variable types.
//
-// Copyright (c) Microsoft Corporation. All rights reserved.
+// Copyright (c) Microsoft Corporation.
// Licensed under the MIT License.
//
// http://go.microsoft.com/fwlink/p/?LinkId=271568
@@ -749,7 +749,6 @@ inline HRESULT SetScalarArray(_In_reads_(Count) const SRC_TYPE *pSrcValues, _Out
_In_ const SType *pType, _In_ uint32_t TotalUnpackedSize, _In_z_ const char *pFuncName)
{
HRESULT hr = S_OK;
- uint32_t delta = pType->NumericType.IsPackedArray ? 1 : SType::c_ScalarsPerRegister;
#ifdef _DEBUG
VERIFYPARAMETER(pSrcValues);
@@ -765,8 +764,9 @@ inline HRESULT SetScalarArray(_In_reads_(Count) const SRC_TYPE *pSrcValues, _Out
UNREFERENCED_PARAMETER(pFuncName);
#endif
+ uint32_t i, j, delta = pType->NumericType.IsPackedArray ? 1 : SType::c_ScalarsPerRegister;
pDestValues += Offset * delta;
- for (uint32_t i = 0, j = 0; j < Count; i += delta, ++ j)
+ for (i = 0, j = 0; j < Count; i += delta, ++ j)
{
// pDestValues[i] = (DEST_TYPE)pSrcValues[j];
CopyScalarValue<SourceType, DestType, SRC_TYPE, false>(pSrcValues[j], &pDestValues[i], "SetScalarArray");
@@ -784,7 +784,6 @@ inline HRESULT GetScalarArray(_In_reads_(Count) SRC_TYPE *pSrcValues, _Out_write
_In_ const SType *pType, _In_ uint32_t TotalUnpackedSize, _In_z_ const char *pFuncName)
{
HRESULT hr = S_OK;
- uint32_t delta = pType->NumericType.IsPackedArray ? 1 : SType::c_ScalarsPerRegister;
#ifdef _DEBUG
VERIFYPARAMETER(pDestValues);
@@ -800,8 +799,9 @@ inline HRESULT GetScalarArray(_In_reads_(Count) SRC_TYPE *pSrcValues, _Out_write
UNREFERENCED_PARAMETER(pFuncName);
#endif
+ uint32_t i, j, delta = pType->NumericType.IsPackedArray ? 1 : SType::c_ScalarsPerRegister;
pSrcValues += Offset * delta;
- for (uint32_t i = 0, j = 0; j < Count; i += delta, ++ j)
+ for (i = 0, j = 0; j < Count; i += delta, ++ j)
{
// pDestValues[j] = (DEST_TYPE)pSrcValues[i];
CopyScalarValue<SourceType, DestType, SRC_TYPE, false>(pSrcValues[i], &pDestValues[j], "GetScalarArray");
@@ -810,8 +810,7 @@ inline HRESULT GetScalarArray(_In_reads_(Count) SRC_TYPE *pSrcValues, _Out_write
lExit:
return hr;
}
-template<class IBaseInterface>
-struct TTopLevelVariable;
+
//////////////////////////////////////////////////////////////////////////
// TVariable - implements type casting and member/element retrieval
@@ -827,7 +826,7 @@ struct TVariable : public IBaseInterface
{
SVariable *pMember;
UDataPointer dataPtr;
- TTopLevelVariable<ID3DX11EffectVariable> *pTopLevelEntity2 = this->GetTopLevelEntity();
+ TTopLevelVariable<ID3DX11EffectVariable> *pTopLevelEntity2 = GetTopLevelEntity();
if (((ID3DX11Effect*)pTopLevelEntity2->pEffect)->IsOptimized())
{
@@ -835,14 +834,14 @@ struct TVariable : public IBaseInterface
return &g_InvalidScalarVariable;
}
- if (this->pType->VarType != EVT_Struct)
+ if (pType->VarType != EVT_Struct)
{
DPF(0, "ID3DX11EffectVariable::GetMemberByIndex: Variable is not a structure");
return &g_InvalidScalarVariable;
}
- if (!GetVariableByIndexHelper<SVariable>(Index, this->pType->StructType.Members, this->pType->StructType.pMembers,
- this->Data.pNumeric, &pMember, &dataPtr.pGeneric))
+ if (!GetVariableByIndexHelper<SVariable>(Index, pType->StructType.Members, pType->StructType.pMembers,
+ Data.pNumeric, &pMember, &dataPtr.pGeneric))
{
return &g_InvalidScalarVariable;
}
@@ -855,7 +854,7 @@ struct TVariable : public IBaseInterface
SVariable *pMember;
UDataPointer dataPtr;
uint32_t index;
- TTopLevelVariable<ID3DX11EffectVariable> *pTopLevelEntity2 = this->GetTopLevelEntity();
+ TTopLevelVariable<ID3DX11EffectVariable> *pTopLevelEntity2 = GetTopLevelEntity();
if (pTopLevelEntity2->pEffect->IsOptimized())
{
@@ -863,14 +862,14 @@ struct TVariable : public IBaseInterface
return &g_InvalidScalarVariable;
}
- if (this->pType->VarType != EVT_Struct)
+ if (pType->VarType != EVT_Struct)
{
DPF(0, "ID3DX11EffectVariable::GetMemberByName: Variable is not a structure");
return &g_InvalidScalarVariable;
}
- if (!GetVariableByNameHelper<SVariable>(Name, this->pType->StructType.Members, this->pType->StructType.pMembers,
- this->Data.pNumeric, &pMember, &dataPtr.pGeneric, &index))
+ if (!GetVariableByNameHelper<SVariable>(Name, pType->StructType.Members, pType->StructType.pMembers,
+ Data.pNumeric, &pMember, &dataPtr.pGeneric, &index))
{
return &g_InvalidScalarVariable;
@@ -884,7 +883,7 @@ struct TVariable : public IBaseInterface
SVariable *pMember;
UDataPointer dataPtr;
uint32_t index;
- TTopLevelVariable<ID3DX11EffectVariable> *pTopLevelEntity2 = this->GetTopLevelEntity();
+ TTopLevelVariable<ID3DX11EffectVariable> *pTopLevelEntity2 = GetTopLevelEntity();
if (pTopLevelEntity2->pEffect->IsOptimized())
{
@@ -892,14 +891,14 @@ struct TVariable : public IBaseInterface
return &g_InvalidScalarVariable;
}
- if (this->pType->VarType != EVT_Struct)
+ if (pType->VarType != EVT_Struct)
{
DPF(0, "ID3DX11EffectVariable::GetMemberBySemantic: Variable is not a structure");
return &g_InvalidScalarVariable;
}
- if (!GetVariableBySemanticHelper<SVariable>(Semantic, this->pType->StructType.Members, this->pType->StructType.pMembers,
- this->Data.pNumeric, &pMember, &dataPtr.pGeneric, &index))
+ if (!GetVariableBySemanticHelper<SVariable>(Semantic, pType->StructType.Members, pType->StructType.pMembers,
+ Data.pNumeric, &pMember, &dataPtr.pGeneric, &index))
{
return &g_InvalidScalarVariable;
@@ -911,7 +910,7 @@ struct TVariable : public IBaseInterface
STDMETHOD_(ID3DX11EffectVariable*, GetElement)(_In_ uint32_t Index)
{
static LPCSTR pFuncName = "ID3DX11EffectVariable::GetElement";
- TTopLevelVariable<ID3DX11EffectVariable> *pTopLevelEntity2 = this->GetTopLevelEntity();
+ TTopLevelVariable<ID3DX11EffectVariable> *pTopLevelEntity2 = GetTopLevelEntity();
UDataPointer dataPtr;
if (pTopLevelEntity2->pEffect->IsOptimized())
@@ -920,25 +919,25 @@ struct TVariable : public IBaseInterface
return &g_InvalidScalarVariable;
}
- if (!this->IsArray())
+ if (!IsArray())
{
DPF(0, "%s: This interface does not refer to an array", pFuncName);
return &g_InvalidScalarVariable;
}
- if (Index >= this->pType->Elements)
+ if (Index >= pType->Elements)
{
- DPF(0, "%s: Invalid element index (%u, total: %u)", pFuncName, Index, this->pType->Elements);
+ DPF(0, "%s: Invalid element index (%u, total: %u)", pFuncName, Index, pType->Elements);
return &g_InvalidScalarVariable;
}
- if (this->pType->BelongsInConstantBuffer())
+ if (pType->BelongsInConstantBuffer())
{
- dataPtr.pGeneric = this->Data.pNumeric + this->pType->Stride * Index;
+ dataPtr.pGeneric = Data.pNumeric + pType->Stride * Index;
}
else
{
- dataPtr.pGeneric = GetBlockByIndex(this->pType->VarType, this->pType->ObjectType, this->Data.pGeneric, Index);
+ dataPtr.pGeneric = GetBlockByIndex(pType->VarType, pType->ObjectType, Data.pGeneric, Index);
if (nullptr == dataPtr.pGeneric)
{
DPF(0, "%s: Internal error", pFuncName);
@@ -953,8 +952,8 @@ struct TVariable : public IBaseInterface
{
static LPCSTR pFuncName = "ID3DX11EffectVariable::AsScalar";
- if (this->pType->VarType != EVT_Numeric ||
- this->pType->NumericType.NumericLayout != ENL_Scalar)
+ if (pType->VarType != EVT_Numeric ||
+ pType->NumericType.NumericLayout != ENL_Scalar)
{
DPF(0, "%s: Invalid typecast", pFuncName);
return &g_InvalidScalarVariable;
@@ -967,8 +966,8 @@ struct TVariable : public IBaseInterface
{
static LPCSTR pFuncName = "ID3DX11EffectVariable::AsVector";
- if (this->pType->VarType != EVT_Numeric ||
- this->pType->NumericType.NumericLayout != ENL_Vector)
+ if (pType->VarType != EVT_Numeric ||
+ pType->NumericType.NumericLayout != ENL_Vector)
{
DPF(0, "%s: Invalid typecast", pFuncName);
return &g_InvalidVectorVariable;
@@ -981,8 +980,8 @@ struct TVariable : public IBaseInterface
{
static LPCSTR pFuncName = "ID3DX11EffectVariable::AsMatrix";
- if (this->pType->VarType != EVT_Numeric ||
- this->pType->NumericType.NumericLayout != ENL_Matrix)
+ if (pType->VarType != EVT_Numeric ||
+ pType->NumericType.NumericLayout != ENL_Matrix)
{
DPF(0, "%s: Invalid typecast", pFuncName);
return &g_InvalidMatrixVariable;
@@ -995,7 +994,7 @@ struct TVariable : public IBaseInterface
{
static LPCSTR pFuncName = "ID3DX11EffectVariable::AsString";
- if (!this->pType->IsObjectType(EOT_String))
+ if (!pType->IsObjectType(EOT_String))
{
DPF(0, "%s: Invalid typecast", pFuncName);
return &g_InvalidStringVariable;
@@ -1008,12 +1007,12 @@ struct TVariable : public IBaseInterface
{
static LPCSTR pFuncName = "ID3DX11EffectVariable::AsClassInstance";
- if (!this->pType->IsClassInstance() )
+ if (!pType->IsClassInstance() )
{
DPF(0, "%s: Invalid typecast", pFuncName);
return &g_InvalidClassInstanceVariable;
}
- else if( this->pMemberData == nullptr )
+ else if( pMemberData == nullptr )
{
DPF(0, "%s: Non-global class instance variables (members of structs or classes) and class instances "
"inside tbuffers are not supported.", pFuncName );
@@ -1027,7 +1026,7 @@ struct TVariable : public IBaseInterface
{
static LPCSTR pFuncName = "ID3DX11EffectVariable::AsInterface";
- if (!this->pType->IsInterface())
+ if (!pType->IsInterface())
{
DPF(0, "%s: Invalid typecast", pFuncName);
return &g_InvalidInterfaceVariable;
@@ -1040,7 +1039,7 @@ struct TVariable : public IBaseInterface
{
static LPCSTR pFuncName = "ID3DX11EffectVariable::AsShaderResource";
- if (!this->pType->IsShaderResource())
+ if (!pType->IsShaderResource())
{
DPF(0, "%s: Invalid typecast", pFuncName);
return &g_InvalidShaderResourceVariable;
@@ -1053,7 +1052,7 @@ struct TVariable : public IBaseInterface
{
static LPCSTR pFuncName = "ID3DX11EffectVariable::AsUnorderedAccessView";
- if (!this->pType->IsUnorderedAccessView())
+ if (!pType->IsUnorderedAccessView())
{
DPF(0, "%s: Invalid typecast", pFuncName);
return &g_InvalidUnorderedAccessViewVariable;
@@ -1066,7 +1065,7 @@ struct TVariable : public IBaseInterface
{
static LPCSTR pFuncName = "ID3DX11EffectVariable::AsRenderTargetView";
- if (!this->pType->IsRenderTargetView())
+ if (!pType->IsRenderTargetView())
{
DPF(0, "%s: Invalid typecast", pFuncName);
return &g_InvalidRenderTargetViewVariable;
@@ -1079,7 +1078,7 @@ struct TVariable : public IBaseInterface
{
static LPCSTR pFuncName = "ID3DX11EffectVariable::AsDepthStencilView";
- if (!this->pType->IsDepthStencilView())
+ if (!pType->IsDepthStencilView())
{
DPF(0, "%s: Invalid typecast", pFuncName);
return &g_InvalidDepthStencilViewVariable;
@@ -1099,7 +1098,7 @@ struct TVariable : public IBaseInterface
{
static LPCSTR pFuncName = "ID3DX11EffectVariable::AsShader";
- if (!this->pType->IsShader())
+ if (!pType->IsShader())
{
DPF(0, "%s: Invalid typecast", pFuncName);
return &g_InvalidShaderVariable;
@@ -1112,7 +1111,7 @@ struct TVariable : public IBaseInterface
{
static LPCSTR pFuncName = "ID3DX11EffectVariable::AsBlend";
- if (!this->pType->IsObjectType(EOT_Blend))
+ if (!pType->IsObjectType(EOT_Blend))
{
DPF(0, "%s: Invalid typecast", pFuncName);
return &g_InvalidBlendVariable;
@@ -1125,7 +1124,7 @@ struct TVariable : public IBaseInterface
{
static LPCSTR pFuncName = "ID3DX11EffectVariable::AsDepthStencil";
- if (!this->pType->IsObjectType(EOT_DepthStencil))
+ if (!pType->IsObjectType(EOT_DepthStencil))
{
DPF(0, "%s: Invalid typecast", pFuncName);
return &g_InvalidDepthStencilVariable;
@@ -1138,7 +1137,7 @@ struct TVariable : public IBaseInterface
{
static LPCSTR pFuncName = "ID3DX11EffectVariable::AsRasterizer";
- if (!this->pType->IsObjectType(EOT_Rasterizer))
+ if (!pType->IsObjectType(EOT_Rasterizer))
{
DPF(0, "%s: Invalid typecast", pFuncName);
return &g_InvalidRasterizerVariable;
@@ -1151,7 +1150,7 @@ struct TVariable : public IBaseInterface
{
static LPCSTR pFuncName = "ID3DX11EffectVariable::AsSampler";
- if (!this->pType->IsSampler())
+ if (!pType->IsSampler())
{
DPF(0, "%s: Invalid typecast", pFuncName);
return &g_InvalidSamplerVariable;
@@ -1171,8 +1170,8 @@ struct TVariable : public IBaseInterface
// TTopLevelVariable - functionality for annotations and global variables
//////////////////////////////////////////////////////////////////////////
-template<class IBaseInterface>
-struct TTopLevelVariable : public D3DX11Effects::SVariable, public IBaseInterface
+template<typename IBaseInterface>
+struct TTopLevelVariable : public SVariable, public IBaseInterface
{
// Required to create member/element variable interfaces
CEffect *pEffect;
@@ -1209,9 +1208,6 @@ struct TTopLevelVariable : public D3DX11Effects::SVariable, public IBaseInterfac
};
-template<typename IBaseInterface>
-struct TGlobalVariable;
-
//////////////////////////////////////////////////////////////////////////
// TMember - functionality for structure/array members of other variables
//////////////////////////////////////////////////////////////////////////
@@ -1267,7 +1263,7 @@ struct TMember : public SVariable, public IBaseInterface
if (pTopLevelEntity->pEffect->IsReflectionData(pTopLevelEntity))
{
// Is part of an annotation
- assert(pTopLevelEntity->pEffect->IsReflectionData(this->Data.pGeneric));
+ assert(pTopLevelEntity->pEffect->IsReflectionData(Data.pGeneric));
pDesc->Annotations = 0;
pDesc->BufferOffset = 0;
pDesc->Flags |= D3DX11_EFFECT_VARIABLE_ANNOTATION;
@@ -1279,7 +1275,7 @@ struct TMember : public SVariable, public IBaseInterface
if (!pTopLevelEntity->pType->IsObjectType(EOT_String))
{
// strings are funny; their data is reflection data, so ignore those
- assert(pTopLevelEntity->pEffect->IsRuntimeData(this->Data.pGeneric));
+ assert(pTopLevelEntity->pEffect->IsRuntimeData(Data.pGeneric));
}
pDesc->Annotations = ((TGlobalVariable<ID3DX11Effect>*)pTopLevelEntity)->AnnotationCount;
@@ -1290,10 +1286,10 @@ struct TMember : public SVariable, public IBaseInterface
{
assert(pCB != 0);
_Analysis_assume_(pCB != 0);
- UINT_PTR offset = this->Data.pNumeric - pCB->pBackingStore;
+ UINT_PTR offset = Data.pNumeric - pCB->pBackingStore;
assert(offset == (uint32_t)offset);
pDesc->BufferOffset = (uint32_t)offset;
- assert(pDesc->BufferOffset >= 0 && pDesc->BufferOffset + this->GetTotalUnpackedSize() <= pCB->Size);
+ assert(pDesc->BufferOffset >= 0 && pDesc->BufferOffset + GetTotalUnpackedSize() <= pCB->Size);
}
else
{
@@ -1346,8 +1342,8 @@ struct TAnnotation : public TVariable<TTopLevelVariable<IBaseInterface> >
VERIFYPARAMETER(pDesc != nullptr);
- pDesc->Name = this->pName;
- pDesc->Semantic = this->pSemantic;
+ pDesc->Name = pName;
+ pDesc->Semantic = pSemantic;
pDesc->Flags = D3DX11_EFFECT_VARIABLE_ANNOTATION;
pDesc->Annotations = 0;
pDesc->BufferOffset = 0;
@@ -1413,19 +1409,19 @@ struct TGlobalVariable : public TVariable<TTopLevelVariable<IBaseInterface> >
VERIFYPARAMETER(pDesc != nullptr);
- pDesc->Name = this->pName;
- pDesc->Semantic = this->pSemantic;
+ pDesc->Name = pName;
+ pDesc->Semantic = pSemantic;
pDesc->Flags = 0;
pDesc->Annotations = AnnotationCount;
- if (this->pType->BelongsInConstantBuffer())
+ if (pType->BelongsInConstantBuffer())
{
assert(pCB != 0);
_Analysis_assume_(pCB != 0);
- UINT_PTR offset = this->Data.pNumeric - pCB->pBackingStore;
+ UINT_PTR offset = Data.pNumeric - pCB->pBackingStore;
assert(offset == (uint32_t)offset);
pDesc->BufferOffset = (uint32_t)offset;
- assert(pDesc->BufferOffset >= 0 && pDesc->BufferOffset + this->GetTotalUnpackedSize() <= pCB->Size );
+ assert(pDesc->BufferOffset >= 0 && pDesc->BufferOffset + GetTotalUnpackedSize() <= pCB->Size );
}
else
{
@@ -1433,9 +1429,9 @@ struct TGlobalVariable : public TVariable<TTopLevelVariable<IBaseInterface> >
pDesc->BufferOffset = 0;
}
- if (this->ExplicitBindPoint != -1)
+ if (ExplicitBindPoint != -1)
{
- pDesc->ExplicitBindPoint = this->ExplicitBindPoint;
+ pDesc->ExplicitBindPoint = ExplicitBindPoint;
pDesc->Flags |= D3DX11_EFFECT_VARIABLE_EXPLICIT_BIND_POINT;
}
else
@@ -1462,12 +1458,12 @@ lExit:
{
if (nullptr != pCB)
{
- assert(this->pType->BelongsInConstantBuffer());
+ assert(pType->BelongsInConstantBuffer());
return (ID3DX11EffectConstantBuffer*)pCB;
}
else
{
- assert(!this->pType->BelongsInConstantBuffer());
+ assert(!pType->BelongsInConstantBuffer());
return &g_InvalidConstantBuffer;
}
}
@@ -1477,7 +1473,7 @@ lExit:
assert(pCB != 0);
_Analysis_assume_(pCB != 0);
pCB->IsDirty = true;
- LastModifiedTime = this->pEffect->GetCurrentTime();
+ LastModifiedTime = pEffect->GetCurrentTime();
}
};
@@ -1512,7 +1508,7 @@ struct TNumericVariable : public IBaseInterface
if ((ByteOffset + ByteCount < ByteOffset) ||
(ByteCount + (uint8_t*)pData < (uint8_t*)pData) ||
- ((ByteOffset + ByteCount) > this->GetTotalUnpackedSize()))
+ ((ByteOffset + ByteCount) > GetTotalUnpackedSize()))
{
// overflow of some kind
DPF(0, "%s: Invalid range specified", pFuncName);
@@ -1520,8 +1516,8 @@ struct TNumericVariable : public IBaseInterface
}
#endif
- this->DirtyVariable();
- memcpy(this->Data.pNumeric + ByteOffset, pData, ByteCount);
+ DirtyVariable();
+ memcpy(Data.pNumeric + ByteOffset, pData, ByteCount);
lExit:
return hr;
@@ -1539,7 +1535,7 @@ lExit:
if ((ByteOffset + ByteCount < ByteOffset) ||
(ByteCount + (uint8_t*)pData < (uint8_t*)pData) ||
- ((ByteOffset + ByteCount) > this->GetTotalUnpackedSize()))
+ ((ByteOffset + ByteCount) > GetTotalUnpackedSize()))
{
// overflow of some kind
DPF(0, "%s: Invalid range specified", pFuncName);
@@ -1547,7 +1543,7 @@ lExit:
}
#endif
- memcpy(pData, this->Data.pNumeric + ByteOffset, ByteCount);
+ memcpy(pData, Data.pNumeric + ByteOffset, ByteCount);
lExit:
return hr;
@@ -1586,15 +1582,15 @@ HRESULT TFloatScalarVariable<IBaseInterface, IsAnnotation>::SetFloat(float Value
{
static LPCSTR pFuncName = "ID3DX11EffectScalarVariable::SetFloat";
if (IsAnnotation) return AnnotationInvalidSetCall(pFuncName);
- this->DirtyVariable();
- return CopyScalarValue<ETVT_Float, ETVT_Float, float, false>(Value, this->Data.pNumericFloat, pFuncName);
+ DirtyVariable();
+ return CopyScalarValue<ETVT_Float, ETVT_Float, float, false>(Value, Data.pNumericFloat, pFuncName);
}
template<typename IBaseInterface, bool IsAnnotation>
_Use_decl_annotations_
HRESULT TFloatScalarVariable<IBaseInterface, IsAnnotation>::GetFloat(float *pValue)
{
- return CopyScalarValue<ETVT_Float, ETVT_Float, float, true>(*this->Data.pNumericFloat, pValue, "ID3DX11EffectScalarVariable::GetFloat");
+ return CopyScalarValue<ETVT_Float, ETVT_Float, float, true>(*Data.pNumericFloat, pValue, "ID3DX11EffectScalarVariable::GetFloat");
}
template<typename IBaseInterface, bool IsAnnotation>
@@ -1603,17 +1599,17 @@ HRESULT TFloatScalarVariable<IBaseInterface, IsAnnotation>::SetFloatArray(const
{
static LPCSTR pFuncName = "ID3DX11EffectScalarVariable::SetFloatArray";
if (IsAnnotation) return AnnotationInvalidSetCall(pFuncName);
- this->DirtyVariable();
- return SetScalarArray<ETVT_Float, ETVT_Float, float, float>(pData, this->Data.pNumericFloat, Offset, Count,
- this->pType, this->GetTotalUnpackedSize(), pFuncName);
+ DirtyVariable();
+ return SetScalarArray<ETVT_Float, ETVT_Float, float, float>(pData, Data.pNumericFloat, Offset, Count,
+ pType, GetTotalUnpackedSize(), pFuncName);
}
template<typename IBaseInterface, bool IsAnnotation>
_Use_decl_annotations_
HRESULT TFloatScalarVariable<IBaseInterface, IsAnnotation>::GetFloatArray(float *pData, uint32_t Offset, uint32_t Count)
{
- return GetScalarArray<ETVT_Float, ETVT_Float, float, float>(this->Data.pNumericFloat, pData, Offset, Count,
- this->pType, this->GetTotalUnpackedSize(), "ID3DX11EffectScalarVariable::GetFloatArray");
+ return GetScalarArray<ETVT_Float, ETVT_Float, float, float>(Data.pNumericFloat, pData, Offset, Count,
+ pType, GetTotalUnpackedSize(), "ID3DX11EffectScalarVariable::GetFloatArray");
}
template<typename IBaseInterface, bool IsAnnotation>
@@ -1622,15 +1618,15 @@ HRESULT TFloatScalarVariable<IBaseInterface, IsAnnotation>::SetInt(const int Val
{
static LPCSTR pFuncName = "ID3DX11EffectScalarVariable::SetInt";
if (IsAnnotation) return AnnotationInvalidSetCall(pFuncName);
- this->DirtyVariable();
- return CopyScalarValue<ETVT_Int, ETVT_Float, int, false>(Value, this->Data.pNumericFloat, pFuncName);
+ DirtyVariable();
+ return CopyScalarValue<ETVT_Int, ETVT_Float, int, false>(Value, Data.pNumericFloat, pFuncName);
}
template<typename IBaseInterface, bool IsAnnotation>
_Use_decl_annotations_
HRESULT TFloatScalarVariable<IBaseInterface, IsAnnotation>::GetInt(int *pValue)
{
- return CopyScalarValue<ETVT_Float, ETVT_Int, float, true>(*this->Data.pNumericFloat, pValue, "ID3DX11EffectScalarVariable::GetInt");
+ return CopyScalarValue<ETVT_Float, ETVT_Int, float, true>(*Data.pNumericFloat, pValue, "ID3DX11EffectScalarVariable::GetInt");
}
template<typename IBaseInterface, bool IsAnnotation>
@@ -1639,17 +1635,17 @@ HRESULT TFloatScalarVariable<IBaseInterface, IsAnnotation>::SetIntArray(const in
{
static LPCSTR pFuncName = "ID3DX11EffectScalarVariable::SetIntArray";
if (IsAnnotation) return AnnotationInvalidSetCall(pFuncName);
- this->DirtyVariable();
- return SetScalarArray<ETVT_Int, ETVT_Float, int, float>(pData, this->Data.pNumericFloat, Offset, Count,
- this->pType, this->GetTotalUnpackedSize(), pFuncName);
+ DirtyVariable();
+ return SetScalarArray<ETVT_Int, ETVT_Float, int, float>(pData, Data.pNumericFloat, Offset, Count,
+ pType, GetTotalUnpackedSize(), pFuncName);
}
template<typename IBaseInterface, bool IsAnnotation>
_Use_decl_annotations_
HRESULT TFloatScalarVariable<IBaseInterface, IsAnnotation>::GetIntArray(int *pData, uint32_t Offset, uint32_t Count)
{
- return GetScalarArray<ETVT_Float, ETVT_Int, float, int>(this->Data.pNumericFloat, pData, Offset, Count,
- this->pType, this->GetTotalUnpackedSize(), "ID3DX11EffectScalarVariable::GetIntArray");
+ return GetScalarArray<ETVT_Float, ETVT_Int, float, int>(Data.pNumericFloat, pData, Offset, Count,
+ pType, GetTotalUnpackedSize(), "ID3DX11EffectScalarVariable::GetIntArray");
}
template<typename IBaseInterface, bool IsAnnotation>
@@ -1658,15 +1654,15 @@ HRESULT TFloatScalarVariable<IBaseInterface, IsAnnotation>::SetBool(const bool V
{
static LPCSTR pFuncName = "ID3DX11EffectScalarVariable::SetBool";
if (IsAnnotation) return AnnotationInvalidSetCall(pFuncName);
- this->DirtyVariable();
- return CopyScalarValue<ETVT_bool, ETVT_Float, bool, false>(Value, this->Data.pNumericFloat, pFuncName);
+ DirtyVariable();
+ return CopyScalarValue<ETVT_bool, ETVT_Float, bool, false>(Value, Data.pNumericFloat, pFuncName);
}
template<typename IBaseInterface, bool IsAnnotation>
_Use_decl_annotations_
HRESULT TFloatScalarVariable<IBaseInterface, IsAnnotation>::GetBool(bool *pValue)
{
- return CopyScalarValue<ETVT_Float, ETVT_bool, float, true>(*this->Data.pNumericFloat, pValue, "ID3DX11EffectScalarVariable::GetBool");
+ return CopyScalarValue<ETVT_Float, ETVT_bool, float, true>(*Data.pNumericFloat, pValue, "ID3DX11EffectScalarVariable::GetBool");
}
template<typename IBaseInterface, bool IsAnnotation>
@@ -1675,17 +1671,17 @@ HRESULT TFloatScalarVariable<IBaseInterface, IsAnnotation>::SetBoolArray(const b
{
static LPCSTR pFuncName = "ID3DX11EffectScalarVariable::SetBoolArray";
if (IsAnnotation) return AnnotationInvalidSetCall(pFuncName);
- this->DirtyVariable();
- return SetScalarArray<ETVT_bool, ETVT_Float, bool, float>(pData, this->Data.pNumericFloat, Offset, Count,
- this->pType, this->GetTotalUnpackedSize(), pFuncName);
+ DirtyVariable();
+ return SetScalarArray<ETVT_bool, ETVT_Float, bool, float>(pData, Data.pNumericFloat, Offset, Count,
+ pType, GetTotalUnpackedSize(), pFuncName);
}
template<typename IBaseInterface, bool IsAnnotation>
_Use_decl_annotations_
HRESULT TFloatScalarVariable<IBaseInterface, IsAnnotation>::GetBoolArray(bool *pData, uint32_t Offset, uint32_t Count)
{
- return GetScalarArray<ETVT_Float, ETVT_bool, float, bool>(this->Data.pNumericFloat, pData, Offset, Count,
- this->pType, this->GetTotalUnpackedSize(), "ID3DX11EffectScalarVariable::GetBoolArray");
+ return GetScalarArray<ETVT_Float, ETVT_bool, float, bool>(Data.pNumericFloat, pData, Offset, Count,
+ pType, GetTotalUnpackedSize(), "ID3DX11EffectScalarVariable::GetBoolArray");
}
//////////////////////////////////////////////////////////////////////////
@@ -1720,15 +1716,15 @@ HRESULT TIntScalarVariable<IBaseInterface, IsAnnotation>::SetFloat(float Value)
{
static LPCSTR pFuncName = "ID3DX11EffectScalarVariable::SetFloat";
if (IsAnnotation) return AnnotationInvalidSetCall(pFuncName);
- this->DirtyVariable();
- return CopyScalarValue<ETVT_Float, ETVT_Int, float, false>(Value, this->Data.pNumericInt, pFuncName);
+ DirtyVariable();
+ return CopyScalarValue<ETVT_Float, ETVT_Int, float, false>(Value, Data.pNumericInt, pFuncName);
}
template<typename IBaseInterface, bool IsAnnotation>
_Use_decl_annotations_
HRESULT TIntScalarVariable<IBaseInterface, IsAnnotation>::GetFloat(float *pValue)
{
- return CopyScalarValue<ETVT_Int, ETVT_Float, int, true>(*this->Data.pNumericInt, pValue, "ID3DX11EffectScalarVariable::GetFloat");
+ return CopyScalarValue<ETVT_Int, ETVT_Float, int, true>(*Data.pNumericInt, pValue, "ID3DX11EffectScalarVariable::GetFloat");
}
template<typename IBaseInterface, bool IsAnnotation>
@@ -1737,17 +1733,17 @@ HRESULT TIntScalarVariable<IBaseInterface, IsAnnotation>::SetFloatArray(const fl
{
static LPCSTR pFuncName = "ID3DX11EffectScalarVariable::SetFloatArray";
if (IsAnnotation) return AnnotationInvalidSetCall(pFuncName);
- this->DirtyVariable();
- return SetScalarArray<ETVT_Float, ETVT_Int, float, int>(pData, this->Data.pNumericInt, Offset, Count,
- this->pType, this->GetTotalUnpackedSize(), pFuncName);
+ DirtyVariable();
+ return SetScalarArray<ETVT_Float, ETVT_Int, float, int>(pData, Data.pNumericInt, Offset, Count,
+ pType, GetTotalUnpackedSize(), pFuncName);
}
template<typename IBaseInterface, bool IsAnnotation>
_Use_decl_annotations_
HRESULT TIntScalarVariable<IBaseInterface, IsAnnotation>::GetFloatArray(float *pData, uint32_t Offset, uint32_t Count)
{
- return GetScalarArray<ETVT_Int, ETVT_Float, int, float>(this->Data.pNumericInt, pData, Offset, Count,
- this->pType, this->GetTotalUnpackedSize(), "ID3DX11EffectScalarVariable::GetFloatArray");
+ return GetScalarArray<ETVT_Int, ETVT_Float, int, float>(Data.pNumericInt, pData, Offset, Count,
+ pType, GetTotalUnpackedSize(), "ID3DX11EffectScalarVariable::GetFloatArray");
}
template<typename IBaseInterface, bool IsAnnotation>
@@ -1756,15 +1752,15 @@ HRESULT TIntScalarVariable<IBaseInterface, IsAnnotation>::SetInt(const int Value
{
static LPCSTR pFuncName = "ID3DX11EffectScalarVariable::SetInt";
if (IsAnnotation) return AnnotationInvalidSetCall(pFuncName);
- this->DirtyVariable();
- return CopyScalarValue<ETVT_Int, ETVT_Int, int, false>(Value, this->Data.pNumericInt, pFuncName);
+ DirtyVariable();
+ return CopyScalarValue<ETVT_Int, ETVT_Int, int, false>(Value, Data.pNumericInt, pFuncName);
}
template<typename IBaseInterface, bool IsAnnotation>
_Use_decl_annotations_
HRESULT TIntScalarVariable<IBaseInterface, IsAnnotation>::GetInt(int *pValue)
{
- return CopyScalarValue<ETVT_Int, ETVT_Int, int, true>(*this->Data.pNumericInt, pValue, "ID3DX11EffectScalarVariable::GetInt");
+ return CopyScalarValue<ETVT_Int, ETVT_Int, int, true>(*Data.pNumericInt, pValue, "ID3DX11EffectScalarVariable::GetInt");
}
template<typename IBaseInterface, bool IsAnnotation>
@@ -1773,17 +1769,17 @@ HRESULT TIntScalarVariable<IBaseInterface, IsAnnotation>::SetIntArray(const int
{
static LPCSTR pFuncName = "ID3DX11EffectScalarVariable::SetIntArray";
if (IsAnnotation) return AnnotationInvalidSetCall(pFuncName);
- this->DirtyVariable();
- return SetScalarArray<ETVT_Int, ETVT_Int, int, int>(pData, this->Data.pNumericInt, Offset, Count,
- this->pType, this->GetTotalUnpackedSize(), pFuncName);
+ DirtyVariable();
+ return SetScalarArray<ETVT_Int, ETVT_Int, int, int>(pData, Data.pNumericInt, Offset, Count,
+ pType, GetTotalUnpackedSize(), pFuncName);
}
template<typename IBaseInterface, bool IsAnnotation>
_Use_decl_annotations_
HRESULT TIntScalarVariable<IBaseInterface, IsAnnotation>::GetIntArray(int *pData, uint32_t Offset, uint32_t Count)
{
- return GetScalarArray<ETVT_Int, ETVT_Int, int, int>(this->Data.pNumericInt, pData, Offset, Count,
- this->pType, this->GetTotalUnpackedSize(), "ID3DX11EffectScalarVariable::GetIntArray");
+ return GetScalarArray<ETVT_Int, ETVT_Int, int, int>(Data.pNumericInt, pData, Offset, Count,
+ pType, GetTotalUnpackedSize(), "ID3DX11EffectScalarVariable::GetIntArray");
}
template<typename IBaseInterface, bool IsAnnotation>
@@ -1792,15 +1788,15 @@ HRESULT TIntScalarVariable<IBaseInterface, IsAnnotation>::SetBool(const bool Val
{
static LPCSTR pFuncName = "ID3DX11EffectScalarVariable::SetBool";
if (IsAnnotation) return AnnotationInvalidSetCall(pFuncName);
- this->DirtyVariable();
- return CopyScalarValue<ETVT_bool, ETVT_Int, bool, false>(Value, this->Data.pNumericInt, pFuncName);
+ DirtyVariable();
+ return CopyScalarValue<ETVT_bool, ETVT_Int, bool, false>(Value, Data.pNumericInt, pFuncName);
}
template<typename IBaseInterface, bool IsAnnotation>
_Use_decl_annotations_
HRESULT TIntScalarVariable<IBaseInterface, IsAnnotation>::GetBool(bool *pValue)
{
- return CopyScalarValue<ETVT_Int, ETVT_bool, int, true>(*this->Data.pNumericInt, pValue, "ID3DX11EffectScalarVariable::GetBool");
+ return CopyScalarValue<ETVT_Int, ETVT_bool, int, true>(*Data.pNumericInt, pValue, "ID3DX11EffectScalarVariable::GetBool");
}
template<typename IBaseInterface, bool IsAnnotation>
@@ -1809,17 +1805,17 @@ HRESULT TIntScalarVariable<IBaseInterface, IsAnnotation>::SetBoolArray(const boo
{
static LPCSTR pFuncName = "ID3DX11EffectScalarVariable::SetBoolArray";
if (IsAnnotation) return AnnotationInvalidSetCall(pFuncName);
- this->DirtyVariable();
- return SetScalarArray<ETVT_bool, ETVT_Int, bool, int>(pData, this->Data.pNumericInt, Offset, Count,
- this->pType, this->GetTotalUnpackedSize(), pFuncName);
+ DirtyVariable();
+ return SetScalarArray<ETVT_bool, ETVT_Int, bool, int>(pData, Data.pNumericInt, Offset, Count,
+ pType, GetTotalUnpackedSize(), pFuncName);
}
template<typename IBaseInterface, bool IsAnnotation>
_Use_decl_annotations_
HRESULT TIntScalarVariable<IBaseInterface, IsAnnotation>::GetBoolArray(bool *pData, uint32_t Offset, uint32_t Count)
{
- return GetScalarArray<ETVT_Int, ETVT_bool, int, bool>(this->Data.pNumericInt, pData, Offset, Count,
- this->pType, this->GetTotalUnpackedSize(), "ID3DX11EffectScalarVariable::GetBoolArray");
+ return GetScalarArray<ETVT_Int, ETVT_bool, int, bool>(Data.pNumericInt, pData, Offset, Count,
+ pType, GetTotalUnpackedSize(), "ID3DX11EffectScalarVariable::GetBoolArray");
}
//////////////////////////////////////////////////////////////////////////
@@ -1854,15 +1850,15 @@ HRESULT TBoolScalarVariable<IBaseInterface, IsAnnotation>::SetFloat(float Value)
{
static LPCSTR pFuncName = "ID3DX11EffectScalarVariable::SetFloat";
if (IsAnnotation) return AnnotationInvalidSetCall(pFuncName);
- this->DirtyVariable();
- return CopyScalarValue<ETVT_Float, ETVT_Bool, float, false>(Value, this->Data.pNumericBool, pFuncName);
+ DirtyVariable();
+ return CopyScalarValue<ETVT_Float, ETVT_Bool, float, false>(Value, Data.pNumericBool, pFuncName);
}
template<typename IBaseInterface, bool IsAnnotation>
_Use_decl_annotations_
HRESULT TBoolScalarVariable<IBaseInterface, IsAnnotation>::GetFloat(float *pValue)
{
- return CopyScalarValue<ETVT_Bool, ETVT_Float, BOOL, true>(*this->Data.pNumericBool, pValue, "ID3DX11EffectScalarVariable::GetFloat");
+ return CopyScalarValue<ETVT_Bool, ETVT_Float, BOOL, true>(*Data.pNumericBool, pValue, "ID3DX11EffectScalarVariable::GetFloat");
}
template<typename IBaseInterface, bool IsAnnotation>
@@ -1871,17 +1867,17 @@ HRESULT TBoolScalarVariable<IBaseInterface, IsAnnotation>::SetFloatArray(const f
{
static LPCSTR pFuncName = "ID3DX11EffectScalarVariable::SetFloatArray";
if (IsAnnotation) return AnnotationInvalidSetCall(pFuncName);
- this->DirtyVariable();
- return SetScalarArray<ETVT_Float, ETVT_Bool, float, BOOL>(pData, this->Data.pNumericBool, Offset, Count,
- this->pType, this->GetTotalUnpackedSize(), pFuncName);
+ DirtyVariable();
+ return SetScalarArray<ETVT_Float, ETVT_Bool, float, BOOL>(pData, Data.pNumericBool, Offset, Count,
+ pType, GetTotalUnpackedSize(), pFuncName);
}
template<typename IBaseInterface, bool IsAnnotation>
_Use_decl_annotations_
HRESULT TBoolScalarVariable<IBaseInterface, IsAnnotation>::GetFloatArray(float *pData, uint32_t Offset, uint32_t Count)
{
- return GetScalarArray<ETVT_Bool, ETVT_Float, BOOL, float>(this->Data.pNumericBool, pData, Offset, Count,
- this->pType, this->GetTotalUnpackedSize(), "ID3DX11EffectScalarVariable::GetFloatArray");
+ return GetScalarArray<ETVT_Bool, ETVT_Float, BOOL, float>(Data.pNumericBool, pData, Offset, Count,
+ pType, GetTotalUnpackedSize(), "ID3DX11EffectScalarVariable::GetFloatArray");
}
template<typename IBaseInterface, bool IsAnnotation>
@@ -1890,15 +1886,15 @@ HRESULT TBoolScalarVariable<IBaseInterface, IsAnnotation>::SetInt(const int Valu
{
static LPCSTR pFuncName = "ID3DX11EffectScalarVariable::SetInt";
if (IsAnnotation) return AnnotationInvalidSetCall(pFuncName);
- this->DirtyVariable();
- return CopyScalarValue<ETVT_Int, ETVT_Bool, int, false>(Value, this->Data.pNumericBool, pFuncName);
+ DirtyVariable();
+ return CopyScalarValue<ETVT_Int, ETVT_Bool, int, false>(Value, Data.pNumericBool, pFuncName);
}
template<typename IBaseInterface, bool IsAnnotation>
_Use_decl_annotations_
HRESULT TBoolScalarVariable<IBaseInterface, IsAnnotation>::GetInt(int *pValue)
{
- return CopyScalarValue<ETVT_Bool, ETVT_Int, BOOL, true>(*this->Data.pNumericBool, pValue, "ID3DX11EffectScalarVariable::GetInt");
+ return CopyScalarValue<ETVT_Bool, ETVT_Int, BOOL, true>(*Data.pNumericBool, pValue, "ID3DX11EffectScalarVariable::GetInt");
}
template<typename IBaseInterface, bool IsAnnotation>
@@ -1907,17 +1903,17 @@ HRESULT TBoolScalarVariable<IBaseInterface, IsAnnotation>::SetIntArray(const int
{
static LPCSTR pFuncName = "ID3DX11EffectScalarVariable::SetIntArray";
if (IsAnnotation) return AnnotationInvalidSetCall(pFuncName);
- this->DirtyVariable();
- return SetScalarArray<ETVT_Int, ETVT_Bool, int, BOOL>(pData, this->Data.pNumericBool, Offset, Count,
- this->pType, this->GetTotalUnpackedSize(), pFuncName);
+ DirtyVariable();
+ return SetScalarArray<ETVT_Int, ETVT_Bool, int, BOOL>(pData, Data.pNumericBool, Offset, Count,
+ pType, GetTotalUnpackedSize(), pFuncName);
}
template<typename IBaseInterface, bool IsAnnotation>
_Use_decl_annotations_
HRESULT TBoolScalarVariable<IBaseInterface, IsAnnotation>::GetIntArray(int *pData, uint32_t Offset, uint32_t Count)
{
- return GetScalarArray<ETVT_Bool, ETVT_Int, BOOL, int>(this->Data.pNumericBool, pData, Offset, Count,
- this->pType, this->GetTotalUnpackedSize(), "ID3DX11EffectScalarVariable::GetIntArray");
+ return GetScalarArray<ETVT_Bool, ETVT_Int, BOOL, int>(Data.pNumericBool, pData, Offset, Count,
+ pType, GetTotalUnpackedSize(), "ID3DX11EffectScalarVariable::GetIntArray");
}
template<typename IBaseInterface, bool IsAnnotation>
@@ -1926,15 +1922,15 @@ HRESULT TBoolScalarVariable<IBaseInterface, IsAnnotation>::SetBool(const bool Va
{
static LPCSTR pFuncName = "ID3DX11EffectScalarVariable::SetBool";
if (IsAnnotation) return AnnotationInvalidSetCall(pFuncName);
- this->DirtyVariable();
- return CopyScalarValue<ETVT_bool, ETVT_Bool, bool, false>(Value, this->Data.pNumericBool, pFuncName);
+ DirtyVariable();
+ return CopyScalarValue<ETVT_bool, ETVT_Bool, bool, false>(Value, Data.pNumericBool, pFuncName);
}
template<typename IBaseInterface, bool IsAnnotation>
_Use_decl_annotations_
HRESULT TBoolScalarVariable<IBaseInterface, IsAnnotation>::GetBool(bool *pValue)
{
- return CopyScalarValue<ETVT_Bool, ETVT_bool, BOOL, true>(*this->Data.pNumericBool, pValue, "ID3DX11EffectScalarVariable::GetBool");
+ return CopyScalarValue<ETVT_Bool, ETVT_bool, BOOL, true>(*Data.pNumericBool, pValue, "ID3DX11EffectScalarVariable::GetBool");
}
template<typename IBaseInterface, bool IsAnnotation>
@@ -1943,17 +1939,17 @@ HRESULT TBoolScalarVariable<IBaseInterface, IsAnnotation>::SetBoolArray(const bo
{
static LPCSTR pFuncName = "ID3DX11EffectScalarVariable::SetBoolArray";
if (IsAnnotation) return AnnotationInvalidSetCall(pFuncName);
- this->DirtyVariable();
- return SetScalarArray<ETVT_bool, ETVT_Bool, bool, BOOL>(pData, this->Data.pNumericBool, Offset, Count,
- this->pType, this->GetTotalUnpackedSize(), pFuncName);
+ DirtyVariable();
+ return SetScalarArray<ETVT_bool, ETVT_Bool, bool, BOOL>(pData, Data.pNumericBool, Offset, Count,
+ pType, GetTotalUnpackedSize(), pFuncName);
}
template<typename IBaseInterface, bool IsAnnotation>
_Use_decl_annotations_
HRESULT TBoolScalarVariable<IBaseInterface, IsAnnotation>::GetBoolArray(bool *pData, uint32_t Offset, uint32_t Count)
{
- return GetScalarArray<ETVT_Bool, ETVT_bool, BOOL, bool>(this->Data.pNumericBool, pData, Offset, Count,
- this->pType, this->GetTotalUnpackedSize(), "ID3DX11EffectScalarVariable::GetBoolArray");
+ return GetScalarArray<ETVT_Bool, ETVT_bool, BOOL, bool>(Data.pNumericBool, pData, Offset, Count,
+ pType, GetTotalUnpackedSize(), "ID3DX11EffectScalarVariable::GetBoolArray");
}
//////////////////////////////////////////////////////////////////////////
@@ -2216,8 +2212,8 @@ HRESULT TVectorVariable<IBaseInterface, IsAnnotation, BaseType >::SetFloatVector
#endif
if (IsAnnotation) return AnnotationInvalidSetCall(pFuncName);
- this->DirtyVariable();
- CopyDataWithTypeConversion<BaseType, ETVT_Float>(this->Data.pVector, pData, 4, this->pType->NumericType.Columns, this->pType->NumericType.Columns, 1);
+ DirtyVariable();
+ CopyDataWithTypeConversion<BaseType, ETVT_Float>(Data.pVector, pData, 4, pType->NumericType.Columns, pType->NumericType.Columns, 1);
lExit:
return hr;
@@ -2234,7 +2230,7 @@ HRESULT TVectorVariable<IBaseInterface, IsAnnotation, BaseType>::GetFloatVector(
VERIFYPARAMETER(pData);
#endif
- CopyDataWithTypeConversion<ETVT_Float, BaseType>(pData, this->Data.pVector, this->pType->NumericType.Columns, 4, this->pType->NumericType.Columns, 1);
+ CopyDataWithTypeConversion<ETVT_Float, BaseType>(pData, Data.pVector, pType->NumericType.Columns, 4, pType->NumericType.Columns, 1);
lExit:
return hr;
@@ -2254,8 +2250,8 @@ HRESULT TVectorVariable<IBaseInterface, IsAnnotation, BaseType >::SetIntVector(c
#endif
if (IsAnnotation) return AnnotationInvalidSetCall(pFuncName);
- this->DirtyVariable();
- CopyDataWithTypeConversion<BaseType, ETVT_Int>(this->Data.pVector, pData, 4, this->pType->NumericType.Columns, this->pType->NumericType.Columns, 1);
+ DirtyVariable();
+ CopyDataWithTypeConversion<BaseType, ETVT_Int>(Data.pVector, pData, 4, pType->NumericType.Columns, pType->NumericType.Columns, 1);
lExit:
return hr;
@@ -2272,7 +2268,7 @@ HRESULT TVectorVariable<IBaseInterface, IsAnnotation, BaseType>::GetIntVector(in
VERIFYPARAMETER(pData);
#endif
- CopyDataWithTypeConversion<ETVT_Int, BaseType>(pData, this->Data.pVector, this->pType->NumericType.Columns, 4, this->pType->NumericType.Columns, 1);
+ CopyDataWithTypeConversion<ETVT_Int, BaseType>(pData, Data.pVector, pType->NumericType.Columns, 4, pType->NumericType.Columns, 1);
lExit:
return hr;
@@ -2293,8 +2289,8 @@ HRESULT TVectorVariable<IBaseInterface, IsAnnotation, BaseType >::SetBoolVector(
#endif
if (IsAnnotation) return AnnotationInvalidSetCall(pFuncName);
- this->DirtyVariable();
- CopyDataWithTypeConversion<BaseType, ETVT_bool>(this->Data.pVector, pData, 4, this->pType->NumericType.Columns, this->pType->NumericType.Columns, 1);
+ DirtyVariable();
+ CopyDataWithTypeConversion<BaseType, ETVT_bool>(Data.pVector, pData, 4, pType->NumericType.Columns, pType->NumericType.Columns, 1);
lExit:
return hr;
@@ -2311,7 +2307,7 @@ HRESULT TVectorVariable<IBaseInterface, IsAnnotation, BaseType>::GetBoolVector(b
VERIFYPARAMETER(pData);
#endif
- CopyDataWithTypeConversion<ETVT_bool, BaseType>(pData, this->Data.pVector, this->pType->NumericType.Columns, 4, this->pType->NumericType.Columns, 1);
+ CopyDataWithTypeConversion<ETVT_bool, BaseType>(pData, Data.pVector, pType->NumericType.Columns, 4, pType->NumericType.Columns, 1);
lExit:
return hr;
@@ -2328,7 +2324,7 @@ HRESULT TVectorVariable<IBaseInterface, IsAnnotation, BaseType>::SetFloatVectorA
#ifdef _DEBUG
#pragma warning( suppress : 6001 )
- if (!AreBoundsValid(Offset, Count, pData, this->pType, this->GetTotalUnpackedSize()))
+ if (!AreBoundsValid(Offset, Count, pData, pType, GetTotalUnpackedSize()))
{
DPF(0, "%s: Invalid range specified", pFuncName);
VH(E_INVALIDARG);
@@ -2336,9 +2332,9 @@ HRESULT TVectorVariable<IBaseInterface, IsAnnotation, BaseType>::SetFloatVectorA
#endif
if (IsAnnotation) return AnnotationInvalidSetCall(pFuncName);
- this->DirtyVariable();
+ DirtyVariable();
// ensure we don't write over the padding at the end of the vector array
- CopyDataWithTypeConversion<BaseType, ETVT_Float>(this->Data.pVector + Offset, pData, 4, this->pType->NumericType.Columns, this->pType->NumericType.Columns, std::max(std::min((int)Count, (int)this->pType->Elements - (int)Offset), 0));
+ CopyDataWithTypeConversion<BaseType, ETVT_Float>(Data.pVector + Offset, pData, 4, pType->NumericType.Columns, pType->NumericType.Columns, std::max(std::min((int)Count, (int)pType->Elements - (int)Offset), 0));
lExit:
return hr;
@@ -2353,7 +2349,7 @@ HRESULT TVectorVariable<IBaseInterface, IsAnnotation, BaseType>::GetFloatVectorA
#ifdef _DEBUG
static LPCSTR pFuncName = "ID3DX11EffectVectorVariable::GetFloatVectorArray";
#pragma warning( suppress : 6001 )
- if (!AreBoundsValid(Offset, Count, pData, this->pType, this->GetTotalUnpackedSize()))
+ if (!AreBoundsValid(Offset, Count, pData, pType, GetTotalUnpackedSize()))
{
DPF(0, "%s: Invalid range specified", pFuncName);
VH(E_INVALIDARG);
@@ -2361,7 +2357,7 @@ HRESULT TVectorVariable<IBaseInterface, IsAnnotation, BaseType>::GetFloatVectorA
#endif
// ensure we don't read past the end of the vector array
- CopyDataWithTypeConversion<ETVT_Float, BaseType>(pData, this->Data.pVector + Offset, this->pType->NumericType.Columns, 4, this->pType->NumericType.Columns, std::max(std::min((int)Count, (int)this->pType->Elements - (int)Offset), 0));
+ CopyDataWithTypeConversion<ETVT_Float, BaseType>(pData, Data.pVector + Offset, pType->NumericType.Columns, 4, pType->NumericType.Columns, std::max(std::min((int)Count, (int)pType->Elements - (int)Offset), 0));
lExit:
return hr;
@@ -2378,7 +2374,7 @@ HRESULT TVectorVariable<IBaseInterface, IsAnnotation, BaseType>::SetIntVectorArr
#ifdef _DEBUG
#pragma warning( suppress : 6001 )
- if (!AreBoundsValid(Offset, Count, pData, this->pType, this->GetTotalUnpackedSize()))
+ if (!AreBoundsValid(Offset, Count, pData, pType, GetTotalUnpackedSize()))
{
DPF(0, "%s: Invalid range specified", pFuncName);
VH(E_INVALIDARG);
@@ -2386,9 +2382,9 @@ HRESULT TVectorVariable<IBaseInterface, IsAnnotation, BaseType>::SetIntVectorArr
#endif
if (IsAnnotation) return AnnotationInvalidSetCall(pFuncName);
- this->DirtyVariable();
+ DirtyVariable();
// ensure we don't write over the padding at the end of the vector array
- CopyDataWithTypeConversion<BaseType, ETVT_Int>(this->Data.pVector + Offset, pData, 4, this->pType->NumericType.Columns, this->pType->NumericType.Columns, std::max(std::min((int)Count, (int)this->pType->Elements - (int)Offset), 0));
+ CopyDataWithTypeConversion<BaseType, ETVT_Int>(Data.pVector + Offset, pData, 4, pType->NumericType.Columns, pType->NumericType.Columns, std::max(std::min((int)Count, (int)pType->Elements - (int)Offset), 0));
lExit:
return hr;
@@ -2403,7 +2399,7 @@ HRESULT TVectorVariable<IBaseInterface, IsAnnotation, BaseType>::GetIntVectorArr
#ifdef _DEBUG
#pragma warning( suppress : 6001 )
- if (!AreBoundsValid(Offset, Count, pData, this->pType, this->GetTotalUnpackedSize()))
+ if (!AreBoundsValid(Offset, Count, pData, pType, GetTotalUnpackedSize()))
{
DPF(0, "%s: Invalid range specified", pFuncName);
VH(E_INVALIDARG);
@@ -2411,7 +2407,7 @@ HRESULT TVectorVariable<IBaseInterface, IsAnnotation, BaseType>::GetIntVectorArr
#endif
// ensure we don't read past the end of the vector array
- CopyDataWithTypeConversion<ETVT_Int, BaseType>(pData, this->Data.pVector + Offset, this->pType->NumericType.Columns, 4, this->pType->NumericType.Columns, std::max(std::min((int)Count, (int)this->pType->Elements - (int)Offset), 0));
+ CopyDataWithTypeConversion<ETVT_Int, BaseType>(pData, Data.pVector + Offset, pType->NumericType.Columns, 4, pType->NumericType.Columns, std::max(std::min((int)Count, (int)pType->Elements - (int)Offset), 0));
lExit:
return hr;
@@ -2428,7 +2424,7 @@ HRESULT TVectorVariable<IBaseInterface, IsAnnotation, BaseType>::SetBoolVectorAr
#ifdef _DEBUG
#pragma warning( suppress : 6001 )
- if (!AreBoundsValid(Offset, Count, pData, this->pType, this->GetTotalUnpackedSize()))
+ if (!AreBoundsValid(Offset, Count, pData, pType, GetTotalUnpackedSize()))
{
DPF(0, "%s: Invalid range specified", pFuncName);
VH(E_INVALIDARG);
@@ -2436,9 +2432,9 @@ HRESULT TVectorVariable<IBaseInterface, IsAnnotation, BaseType>::SetBoolVectorAr
#endif
if (IsAnnotation) return AnnotationInvalidSetCall(pFuncName);
- this->DirtyVariable();
+ DirtyVariable();
// ensure we don't write over the padding at the end of the vector array
- CopyDataWithTypeConversion<BaseType, ETVT_bool>(this->Data.pVector + Offset, pData, 4, this->pType->NumericType.Columns, this->pType->NumericType.Columns, std::max(std::min((int)Count, (int)this->pType->Elements - (int)Offset), 0));
+ CopyDataWithTypeConversion<BaseType, ETVT_bool>(Data.pVector + Offset, pData, 4, pType->NumericType.Columns, pType->NumericType.Columns, std::max(std::min((int)Count, (int)pType->Elements - (int)Offset), 0));
lExit:
return hr;
@@ -2453,7 +2449,7 @@ HRESULT TVectorVariable<IBaseInterface, IsAnnotation, BaseType>::GetBoolVectorAr
#ifdef _DEBUG
#pragma warning( suppress : 6001 )
- if (!AreBoundsValid(Offset, Count, pData, this->pType, this->GetTotalUnpackedSize()))
+ if (!AreBoundsValid(Offset, Count, pData, pType, GetTotalUnpackedSize()))
{
DPF(0, "%s: Invalid range specified", pFuncName);
VH(E_INVALIDARG);
@@ -2461,7 +2457,7 @@ HRESULT TVectorVariable<IBaseInterface, IsAnnotation, BaseType>::GetBoolVectorAr
#endif
// ensure we don't read past the end of the vector array
- CopyDataWithTypeConversion<ETVT_bool, BaseType>(pData, this->Data.pVector + Offset, this->pType->NumericType.Columns, 4, this->pType->NumericType.Columns, std::max(std::min((int)Count, (int)this->pType->Elements - (int)Offset), 0));
+ CopyDataWithTypeConversion<ETVT_bool, BaseType>(pData, Data.pVector + Offset, pType->NumericType.Columns, 4, pType->NumericType.Columns, std::max(std::min((int)Count, (int)pType->Elements - (int)Offset), 0));
lExit:
return hr;
@@ -2492,8 +2488,8 @@ HRESULT TVector4Variable<IBaseInterface>::SetFloatVector(const float *pData)
VERIFYPARAMETER(pData);
#endif
- this->DirtyVariable();
- this->Data.pVector[0] = ((CEffectVector4*) pData)[0];
+ DirtyVariable();
+ Data.pVector[0] = ((CEffectVector4*) pData)[0];
lExit:
return hr;
@@ -2510,7 +2506,7 @@ HRESULT TVector4Variable<IBaseInterface>::GetFloatVector(float *pData)
VERIFYPARAMETER(pData);
#endif
- memcpy(pData, this->Data.pVector, this->pType->NumericType.Columns * SType::c_ScalarSize);
+ memcpy(pData, Data.pVector, pType->NumericType.Columns * SType::c_ScalarSize);
lExit:
return hr;
@@ -2525,17 +2521,17 @@ HRESULT TVector4Variable<IBaseInterface>::SetFloatVectorArray(const float *pData
#ifdef _DEBUG
#pragma warning( suppress : 6001 )
- if (!AreBoundsValid(Offset, Count, pData, this->pType, this->GetTotalUnpackedSize()))
+ if (!AreBoundsValid(Offset, Count, pData, pType, GetTotalUnpackedSize()))
{
DPF(0, "%s: Invalid range specified", pFuncName);
VH(E_INVALIDARG);
}
#endif
- this->DirtyVariable();
+ DirtyVariable();
// ensure we don't write over the padding at the end of the vector array
- memcpy(this->Data.pVector + Offset, pData,
- std::min<size_t>(Count * sizeof(CEffectVector4), this->pType->TotalSize - (Offset * sizeof(CEffectVector4))));
+ memcpy(Data.pVector + Offset, pData,
+ std::min<size_t>(Count * sizeof(CEffectVector4), pType->TotalSize - (Offset * sizeof(CEffectVector4))));
lExit:
return hr;
@@ -2550,7 +2546,7 @@ HRESULT TVector4Variable<IBaseInterface>::GetFloatVectorArray(float *pData, uint
#ifdef _DEBUG
#pragma warning( suppress : 6001 )
- if (!AreBoundsValid(Offset, Count, pData, this->pType, this->GetTotalUnpackedSize()))
+ if (!AreBoundsValid(Offset, Count, pData, pType, GetTotalUnpackedSize()))
{
DPF(0, "%s: Invalid range specified", pFuncName);
VH(E_INVALIDARG);
@@ -2558,8 +2554,8 @@ HRESULT TVector4Variable<IBaseInterface>::GetFloatVectorArray(float *pData, uint
#endif
// ensure we don't read past the end of the vector array
- memcpy(pData, this->Data.pVector + Offset,
- std::min<size_t>(Count * sizeof(CEffectVector4), this->pType->TotalSize - (Offset * sizeof(CEffectVector4))));
+ memcpy(pData, Data.pVector + Offset,
+ std::min<size_t>(Count * sizeof(CEffectVector4), pType->TotalSize - (Offset * sizeof(CEffectVector4))));
lExit:
return hr;
@@ -2755,17 +2751,17 @@ HRESULT TMatrixVariable<IBaseInterface, IsAnnotation>::SetMatrix(const float *pD
{
static LPCSTR pFuncName = "ID3DX11EffectMatrixVariable::SetMatrix";
if (IsAnnotation) return AnnotationInvalidSetCall(pFuncName);
- this->DirtyVariable();
- return DoMatrixArrayInternal<false, true, false>(this->pType, this->GetTotalUnpackedSize(),
- this->Data.pNumeric, const_cast<float*>(pData), 0, 1, pFuncName);
+ DirtyVariable();
+ return DoMatrixArrayInternal<false, true, false>(pType, GetTotalUnpackedSize(),
+ Data.pNumeric, const_cast<float*>(pData), 0, 1, pFuncName);
}
template<typename IBaseInterface, bool IsAnnotation>
_Use_decl_annotations_
HRESULT TMatrixVariable<IBaseInterface, IsAnnotation>::GetMatrix(float *pData)
{
- return DoMatrixArrayInternal<false, false, false>(this->pType, this->GetTotalUnpackedSize(),
- this->Data.pNumeric, pData, 0, 1, "ID3DX11EffectMatrixVariable::GetMatrix");
+ return DoMatrixArrayInternal<false, false, false>(pType, GetTotalUnpackedSize(),
+ Data.pNumeric, pData, 0, 1, "ID3DX11EffectMatrixVariable::GetMatrix");
}
template<typename IBaseInterface, bool IsAnnotation>
@@ -2774,17 +2770,17 @@ HRESULT TMatrixVariable<IBaseInterface, IsAnnotation>::SetMatrixArray(const floa
{
static LPCSTR pFuncName = "ID3DX11EffectMatrixVariable::SetMatrixArray";
if (IsAnnotation) return AnnotationInvalidSetCall(pFuncName);
- this->DirtyVariable();
- return DoMatrixArrayInternal<false, true, false>(this->pType, this->GetTotalUnpackedSize(),
- this->Data.pNumeric, const_cast<float*>(pData), Offset, Count, "ID3DX11EffectMatrixVariable::SetMatrixArray");
+ DirtyVariable();
+ return DoMatrixArrayInternal<false, true, false>(pType, GetTotalUnpackedSize(),
+ Data.pNumeric, const_cast<float*>(pData), Offset, Count, "ID3DX11EffectMatrixVariable::SetMatrixArray");
}
template<typename IBaseInterface, bool IsAnnotation>
_Use_decl_annotations_
HRESULT TMatrixVariable<IBaseInterface, IsAnnotation>::GetMatrixArray(float *pData, uint32_t Offset, uint32_t Count)
{
- return DoMatrixArrayInternal<false, false, false>(this->pType, this->GetTotalUnpackedSize(),
- this->Data.pNumeric, pData, Offset, Count, "ID3DX11EffectMatrixVariable::GetMatrixArray");
+ return DoMatrixArrayInternal<false, false, false>(pType, GetTotalUnpackedSize(),
+ Data.pNumeric, pData, Offset, Count, "ID3DX11EffectMatrixVariable::GetMatrixArray");
}
template<typename IBaseInterface, bool IsAnnotation>
@@ -2793,17 +2789,17 @@ HRESULT TMatrixVariable<IBaseInterface, IsAnnotation>::SetMatrixPointerArray(con
{
static LPCSTR pFuncName = "ID3DX11EffectMatrixVariable::SetMatrixPointerArray";
if (IsAnnotation) return AnnotationInvalidSetCall(pFuncName);
- this->DirtyVariable();
- return DoMatrixArrayInternal<false, true, true>(this->pType, this->GetTotalUnpackedSize(),
- this->Data.pNumeric, const_cast<float**>(ppData), Offset, Count, "ID3DX11EffectMatrixVariable::SetMatrixPointerArray");
+ DirtyVariable();
+ return DoMatrixArrayInternal<false, true, true>(pType, GetTotalUnpackedSize(),
+ Data.pNumeric, const_cast<float**>(ppData), Offset, Count, "ID3DX11EffectMatrixVariable::SetMatrixPointerArray");
}
template<typename IBaseInterface, bool IsAnnotation>
_Use_decl_annotations_
HRESULT TMatrixVariable<IBaseInterface, IsAnnotation>::GetMatrixPointerArray(float **ppData, uint32_t Offset, uint32_t Count)
{
- return DoMatrixArrayInternal<false, false, true>(this->pType, this->GetTotalUnpackedSize(),
- this->Data.pNumeric, ppData, Offset, Count, "ID3DX11EffectMatrixVariable::GetMatrixPointerArray");
+ return DoMatrixArrayInternal<false, false, true>(pType, GetTotalUnpackedSize(),
+ Data.pNumeric, ppData, Offset, Count, "ID3DX11EffectMatrixVariable::GetMatrixPointerArray");
}
template<typename IBaseInterface, bool IsAnnotation>
@@ -2812,17 +2808,17 @@ HRESULT TMatrixVariable<IBaseInterface, IsAnnotation>::SetMatrixTranspose(const
{
static LPCSTR pFuncName = "ID3DX11EffectMatrixVariable::SetMatrixTranspose";
if (IsAnnotation) return AnnotationInvalidSetCall(pFuncName);
- this->DirtyVariable();
- return DoMatrixArrayInternal<true, true, false>(this->pType, this->GetTotalUnpackedSize(),
- this->Data.pNumeric, const_cast<float*>(pData), 0, 1, "ID3DX11EffectMatrixVariable::SetMatrixTranspose");
+ DirtyVariable();
+ return DoMatrixArrayInternal<true, true, false>(pType, GetTotalUnpackedSize(),
+ Data.pNumeric, const_cast<float*>(pData), 0, 1, "ID3DX11EffectMatrixVariable::SetMatrixTranspose");
}
template<typename IBaseInterface, bool IsAnnotation>
_Use_decl_annotations_
HRESULT TMatrixVariable<IBaseInterface, IsAnnotation>::GetMatrixTranspose(float *pData)
{
- return DoMatrixArrayInternal<true, false, false>(this->pType, this->GetTotalUnpackedSize(),
- this->Data.pNumeric, pData, 0, 1, "ID3DX11EffectMatrixVariable::GetMatrixTranspose");
+ return DoMatrixArrayInternal<true, false, false>(pType, GetTotalUnpackedSize(),
+ Data.pNumeric, pData, 0, 1, "ID3DX11EffectMatrixVariable::GetMatrixTranspose");
}
template<typename IBaseInterface, bool IsAnnotation>
@@ -2831,17 +2827,17 @@ HRESULT TMatrixVariable<IBaseInterface, IsAnnotation>::SetMatrixTransposeArray(c
{
static LPCSTR pFuncName = "ID3DX11EffectMatrixVariable::SetMatrixTransposeArray";
if (IsAnnotation) return AnnotationInvalidSetCall(pFuncName);
- this->DirtyVariable();
- return DoMatrixArrayInternal<true, true, false>(this->pType, this->GetTotalUnpackedSize(),
- this->Data.pNumeric, const_cast<float*>(pData), Offset, Count, "ID3DX11EffectMatrixVariable::SetMatrixTransposeArray");
+ DirtyVariable();
+ return DoMatrixArrayInternal<true, true, false>(pType, GetTotalUnpackedSize(),
+ Data.pNumeric, const_cast<float*>(pData), Offset, Count, "ID3DX11EffectMatrixVariable::SetMatrixTransposeArray");
}
template<typename IBaseInterface, bool IsAnnotation>
_Use_decl_annotations_
HRESULT TMatrixVariable<IBaseInterface, IsAnnotation>::GetMatrixTransposeArray(float *pData, uint32_t Offset, uint32_t Count)
{
- return DoMatrixArrayInternal<true, false, false>(this->pType, this->GetTotalUnpackedSize(),
- this->Data.pNumeric, pData, Offset, Count, "ID3DX11EffectMatrixVariable::GetMatrixTransposeArray");
+ return DoMatrixArrayInternal<true, false, false>(pType, GetTotalUnpackedSize(),
+ Data.pNumeric, pData, Offset, Count, "ID3DX11EffectMatrixVariable::GetMatrixTransposeArray");
}
template<typename IBaseInterface, bool IsAnnotation>
@@ -2850,17 +2846,17 @@ HRESULT TMatrixVariable<IBaseInterface, IsAnnotation>::SetMatrixTransposePointer
{
static LPCSTR pFuncName = "ID3DX11EffectMatrixVariable::SetMatrixTransposePointerArray";
if (IsAnnotation) return AnnotationInvalidSetCall(pFuncName);
- this->DirtyVariable();
- return DoMatrixArrayInternal<true, true, true>(this->pType, this->GetTotalUnpackedSize(),
- this->Data.pNumeric, const_cast<float**>(ppData), Offset, Count, "ID3DX11EffectMatrixVariable::SetMatrixTransposePointerArray");
+ DirtyVariable();
+ return DoMatrixArrayInternal<true, true, true>(pType, GetTotalUnpackedSize(),
+ Data.pNumeric, const_cast<float**>(ppData), Offset, Count, "ID3DX11EffectMatrixVariable::SetMatrixTransposePointerArray");
}
template<typename IBaseInterface, bool IsAnnotation>
_Use_decl_annotations_
HRESULT TMatrixVariable<IBaseInterface, IsAnnotation>::GetMatrixTransposePointerArray(float **ppData, uint32_t Offset, uint32_t Count)
{
- return DoMatrixArrayInternal<true, false, true>(this->pType, this->GetTotalUnpackedSize(),
- this->Data.pNumeric, ppData, Offset, Count, "ID3DX11EffectMatrixVariable::GetMatrixTransposePointerArray");
+ return DoMatrixArrayInternal<true, false, true>(pType, GetTotalUnpackedSize(),
+ Data.pNumeric, ppData, Offset, Count, "ID3DX11EffectMatrixVariable::GetMatrixTransposePointerArray");
}
// Optimize commonly used fast paths
@@ -3027,10 +3023,10 @@ template<typename IBaseInterface, bool IsColumnMajor>
_Use_decl_annotations_
HRESULT TMatrix4x4Variable<IBaseInterface, IsColumnMajor>::SetMatrix(const float *pData)
{
- this->DirtyVariable();
- return DoMatrix4x4ArrayInternal<IsColumnMajor, false, true>(this->Data.pNumeric, const_cast<float*>(pData), 0, 1
+ DirtyVariable();
+ return DoMatrix4x4ArrayInternal<IsColumnMajor, false, true>(Data.pNumeric, const_cast<float*>(pData), 0, 1
#ifdef _DEBUG
- , this->pType, this->GetTotalUnpackedSize(), "ID3DX11EffectMatrixVariable::SetMatrix");
+ , pType, GetTotalUnpackedSize(), "ID3DX11EffectMatrixVariable::SetMatrix");
#else
);
#endif
@@ -3040,9 +3036,9 @@ template<typename IBaseInterface, bool IsColumnMajor>
_Use_decl_annotations_
HRESULT TMatrix4x4Variable<IBaseInterface, IsColumnMajor>::GetMatrix(float *pData)
{
- return DoMatrix4x4ArrayInternal<IsColumnMajor, false, false>(this->Data.pNumeric, pData, 0, 1
+ return DoMatrix4x4ArrayInternal<IsColumnMajor, false, false>(Data.pNumeric, pData, 0, 1
#ifdef _DEBUG
- , this->pType, this->GetTotalUnpackedSize(), "ID3DX11EffectMatrixVariable::GetMatrix");
+ , pType, GetTotalUnpackedSize(), "ID3DX11EffectMatrixVariable::GetMatrix");
#else
);
#endif
@@ -3052,10 +3048,10 @@ template<typename IBaseInterface, bool IsColumnMajor>
_Use_decl_annotations_
HRESULT TMatrix4x4Variable<IBaseInterface, IsColumnMajor>::SetMatrixArray(const float *pData, uint32_t Offset, uint32_t Count)
{
- this->DirtyVariable();
- return DoMatrix4x4ArrayInternal<IsColumnMajor, false, true>(this->Data.pNumeric, const_cast<float*>(pData), Offset, Count
+ DirtyVariable();
+ return DoMatrix4x4ArrayInternal<IsColumnMajor, false, true>(Data.pNumeric, const_cast<float*>(pData), Offset, Count
#ifdef _DEBUG
- , this->pType, this->GetTotalUnpackedSize(), "ID3DX11EffectMatrixVariable::SetMatrixArray");
+ , pType, GetTotalUnpackedSize(), "ID3DX11EffectMatrixVariable::SetMatrixArray");
#else
);
#endif
@@ -3065,9 +3061,9 @@ template<typename IBaseInterface, bool IsColumnMajor>
_Use_decl_annotations_
HRESULT TMatrix4x4Variable<IBaseInterface, IsColumnMajor>::GetMatrixArray(float *pData, uint32_t Offset, uint32_t Count)
{
- return DoMatrix4x4ArrayInternal<IsColumnMajor, false, false>(this->Data.pNumeric, pData, Offset, Count
+ return DoMatrix4x4ArrayInternal<IsColumnMajor, false, false>(Data.pNumeric, pData, Offset, Count
#ifdef _DEBUG
- , this->pType, this->GetTotalUnpackedSize(), "ID3DX11EffectMatrixVariable::GetMatrixArray");
+ , pType, GetTotalUnpackedSize(), "ID3DX11EffectMatrixVariable::GetMatrixArray");
#else
);
#endif
@@ -3077,10 +3073,10 @@ template<typename IBaseInterface, bool IsColumnMajor>
_Use_decl_annotations_
HRESULT TMatrix4x4Variable<IBaseInterface, IsColumnMajor>::SetMatrixTranspose(const float *pData)
{
- this->DirtyVariable();
- return DoMatrix4x4ArrayInternal<IsColumnMajor, true, true>(this->Data.pNumeric, const_cast<float*>(pData), 0, 1
+ DirtyVariable();
+ return DoMatrix4x4ArrayInternal<IsColumnMajor, true, true>(Data.pNumeric, const_cast<float*>(pData), 0, 1
#ifdef _DEBUG
- , this->pType, this->GetTotalUnpackedSize(), "ID3DX11EffectMatrixVariable::SetMatrixTranspose");
+ , pType, GetTotalUnpackedSize(), "ID3DX11EffectMatrixVariable::SetMatrixTranspose");
#else
);
#endif
@@ -3090,9 +3086,9 @@ template<typename IBaseInterface, bool IsColumnMajor>
_Use_decl_annotations_
HRESULT TMatrix4x4Variable<IBaseInterface, IsColumnMajor>::GetMatrixTranspose(float *pData)
{
- return DoMatrix4x4ArrayInternal<IsColumnMajor, true, false>(this->Data.pNumeric, pData, 0, 1
+ return DoMatrix4x4ArrayInternal<IsColumnMajor, true, false>(Data.pNumeric, pData, 0, 1
#ifdef _DEBUG
- , this->pType, this->GetTotalUnpackedSize(), "ID3DX11EffectMatrixVariable::GetMatrixTranspose");
+ , pType, GetTotalUnpackedSize(), "ID3DX11EffectMatrixVariable::GetMatrixTranspose");
#else
);
#endif
@@ -3102,10 +3098,10 @@ template<typename IBaseInterface, bool IsColumnMajor>
_Use_decl_annotations_
HRESULT TMatrix4x4Variable<IBaseInterface, IsColumnMajor>::SetMatrixTransposeArray(const float *pData, uint32_t Offset, uint32_t Count)
{
- this->DirtyVariable();
- return DoMatrix4x4ArrayInternal<IsColumnMajor, true, true>(this->Data.pNumeric, const_cast<float*>(pData), Offset, Count
+ DirtyVariable();
+ return DoMatrix4x4ArrayInternal<IsColumnMajor, true, true>(Data.pNumeric, const_cast<float*>(pData), Offset, Count
#ifdef _DEBUG
- , this->pType, this->GetTotalUnpackedSize(), "ID3DX11EffectMatrixVariable::SetMatrixTransposeArray");
+ , pType, GetTotalUnpackedSize(), "ID3DX11EffectMatrixVariable::SetMatrixTransposeArray");
#else
);
#endif
@@ -3115,9 +3111,9 @@ template<typename IBaseInterface, bool IsColumnMajor>
_Use_decl_annotations_
HRESULT TMatrix4x4Variable<IBaseInterface, IsColumnMajor>::GetMatrixTransposeArray(float *pData, uint32_t Offset, uint32_t Count)
{
- return DoMatrix4x4ArrayInternal<IsColumnMajor, true, false>(this->Data.pNumeric, pData, Offset, Count
+ return DoMatrix4x4ArrayInternal<IsColumnMajor, true, false>(Data.pNumeric, pData, Offset, Count
#ifdef _DEBUG
- , this->pType, this->GetTotalUnpackedSize(), "ID3DX11EffectMatrixVariable::GetMatrixTransposeArray");
+ , pType, GetTotalUnpackedSize(), "ID3DX11EffectMatrixVariable::GetMatrixTransposeArray");
#else
);
#endif
@@ -3128,8 +3124,8 @@ HRESULT TMatrix4x4Variable<IBaseInterface, IsColumnMajor>::GetMatrixTransposeArr
// Useful object macro to check bounds and parameters
#define CHECK_OBJECT_ARRAY_BOUNDS(Offset, Count, Pointer) \
HRESULT hr = S_OK; \
- const uint32_t elements = this->IsArray() ? this->pType->Elements : 1; \
VERIFYPARAMETER(Pointer) \
+ uint32_t elements = IsArray() ? pType->Elements : 1; \
\
if ((Offset + Count < Offset) || (elements < Offset + Count)) \
{ \
@@ -3139,8 +3135,8 @@ HRESULT TMatrix4x4Variable<IBaseInterface, IsColumnMajor>::GetMatrixTransposeArr
#define CHECK_OBJECT_SCALAR_BOUNDS(Index, Pointer) \
HRESULT hr = S_OK; \
- const uint32_t elements = this->IsArray() ? this->pType->Elements : 1; \
VERIFYPARAMETER(Pointer) \
+ uint32_t elements = IsArray() ? pType->Elements : 1; \
\
if (Index >= elements) \
{ \
@@ -3150,7 +3146,7 @@ HRESULT TMatrix4x4Variable<IBaseInterface, IsColumnMajor>::GetMatrixTransposeArr
#define CHECK_SCALAR_BOUNDS(Index) \
HRESULT hr = S_OK; \
- uint32_t elements = this->IsArray() ? this->pType->Elements : 1; \
+ uint32_t elements = IsArray() ? pType->Elements : 1; \
\
if (Index >= elements) \
{ \
@@ -3191,16 +3187,16 @@ HRESULT TStringVariable<IBaseInterface, IsAnnotation>::GetString(LPCSTR *ppStrin
VERIFYPARAMETER(ppString);
- if (this->GetTopLevelEntity()->pEffect->IsOptimized())
+ if (GetTopLevelEntity()->pEffect->IsOptimized())
{
DPF(0, "%s: Effect has been Optimize()'ed; all string/reflection data has been deleted", pFuncName);
return D3DERR_INVALIDCALL;
}
- assert(this->Data.pString != 0);
- _Analysis_assume_(this->Data.pString != 0);
+ assert(Data.pString != 0);
+ _Analysis_assume_(Data.pString != 0);
- *ppString = this->Data.pString->pString;
+ *ppString = Data.pString->pString;
lExit:
return hr;
@@ -3215,18 +3211,18 @@ HRESULT TStringVariable<IBaseInterface, IsAnnotation>::GetStringArray( LPCSTR *p
CHECK_OBJECT_ARRAY_BOUNDS(Offset, Count, ppStrings);
- if (this->GetTopLevelEntity()->pEffect->IsOptimized())
+ if (GetTopLevelEntity()->pEffect->IsOptimized())
{
DPF(0, "%s: Effect has been Optimize()'ed; all string/reflection data has been deleted", pFuncName);
return D3DERR_INVALIDCALL;
}
- assert(this->Data.pString != 0);
- _Analysis_assume_(this->Data.pString != 0);
+ assert(Data.pString != 0);
+ _Analysis_assume_(Data.pString != 0);
for (size_t i = 0; i < Count; ++ i)
{
- ppStrings[i] = (this->Data.pString + Offset + i)->pString;
+ ppStrings[i] = (Data.pString + Offset + i)->pString;
}
lExit:
@@ -3249,9 +3245,9 @@ HRESULT TClassInstanceVariable<IBaseClassInstance>::GetClassInstance(_Outptr_ ID
HRESULT hr = S_OK;
static LPCSTR pFuncName = "ID3DX11EffectClassInstanceVariable::GetClassInstance";
- assert( this->pMemberData != 0 && this->pMemberData->Data.pD3DClassInstance != 0);
- _Analysis_assume_( this->pMemberData != 0 && this->pMemberData->Data.pD3DClassInstance != 0);
- *ppClassInstance = this->pMemberData->Data.pD3DClassInstance;
+ assert( pMemberData != 0 && pMemberData->Data.pD3DClassInstance != 0);
+ _Analysis_assume_( pMemberData != 0 && pMemberData->Data.pD3DClassInstance != 0);
+ *ppClassInstance = pMemberData->Data.pD3DClassInstance;
SAFE_ADDREF(*ppClassInstance);
lExit:
@@ -3278,7 +3274,7 @@ HRESULT TInterfaceVariable<IBaseInterface>::SetClassInstance(_In_ ID3DX11EffectC
// Note that we don't check if the types are compatible. The debug layer will complain if it is.
// IsValid() will not catch type mismatches.
SClassInstanceGlobalVariable* pCI = (SClassInstanceGlobalVariable*)pEffectClassInstance;
- this->Data.pInterface->pClassInstance = pCI;
+ Data.pInterface->pClassInstance = pCI;
lExit:
return hr;
@@ -3294,7 +3290,7 @@ HRESULT TInterfaceVariable<IBaseInterface>::GetClassInstance(_Outptr_ ID3DX11Eff
VERIFYPARAMETER(ppEffectClassInstance);
#endif
- *ppEffectClassInstance = this->Data.pInterface->pClassInstance;
+ *ppEffectClassInstance = Data.pInterface->pClassInstance;
lExit:
return hr;
@@ -3586,13 +3582,13 @@ HRESULT TShaderResourceVariable<IBaseInterface>::SetResource(ID3D11ShaderResourc
#ifdef _DEBUG
static LPCSTR pFuncName = "ID3DX11EffectShaderResourceVariable::SetResource";
- VH(ValidateTextureType(pResource, this->pType->ObjectType, pFuncName));
+ VH(ValidateTextureType(pResource, pType->ObjectType, pFuncName));
#endif
// Texture variables don't need to be dirtied.
SAFE_ADDREF(pResource);
- SAFE_RELEASE(this->Data.pShaderResource->pShaderResource);
- this->Data.pShaderResource->pShaderResource = pResource;
+ SAFE_RELEASE(Data.pShaderResource->pShaderResource);
+ Data.pShaderResource->pShaderResource = pResource;
lExit:
return hr;
@@ -3610,9 +3606,9 @@ HRESULT TShaderResourceVariable<IBaseInterface>::GetResource(ID3D11ShaderResourc
VERIFYPARAMETER(ppResource);
#endif
- assert(this->Data.pShaderResource != 0 && this->Data.pShaderResource->pShaderResource != 0);
- _Analysis_assume_(this->Data.pShaderResource != 0 && this->Data.pShaderResource->pShaderResource != 0);
- *ppResource = this->Data.pShaderResource->pShaderResource;
+ assert(Data.pShaderResource != 0 && Data.pShaderResource->pShaderResource != 0);
+ _Analysis_assume_(Data.pShaderResource != 0 && Data.pShaderResource->pShaderResource != 0);
+ *ppResource = Data.pShaderResource->pShaderResource;
SAFE_ADDREF(*ppResource);
lExit:
@@ -3630,14 +3626,14 @@ HRESULT TShaderResourceVariable<IBaseInterface>::SetResourceArray(ID3D11ShaderRe
#ifdef _DEBUG
for (size_t i = 0; i < Count; ++ i)
{
- VH(ValidateTextureType(ppResources[i], this->pType->ObjectType, pFuncName));
+ VH(ValidateTextureType(ppResources[i], pType->ObjectType, pFuncName));
}
#endif
// Texture variables don't need to be dirtied.
for (size_t i = 0; i < Count; ++ i)
{
- SShaderResource *pResourceBlock = this->Data.pShaderResource + Offset + i;
+ SShaderResource *pResourceBlock = Data.pShaderResource + Offset + i;
SAFE_ADDREF(ppResources[i]);
SAFE_RELEASE(pResourceBlock->pShaderResource);
pResourceBlock->pShaderResource = ppResources[i];
@@ -3657,7 +3653,7 @@ HRESULT TShaderResourceVariable<IBaseInterface>::GetResourceArray(ID3D11ShaderRe
for (size_t i = 0; i < Count; ++ i)
{
- ppResources[i] = (this->Data.pShaderResource + Offset + i)->pShaderResource;
+ ppResources[i] = (Data.pShaderResource + Offset + i)->pShaderResource;
SAFE_ADDREF(ppResources[i]);
}
@@ -3803,13 +3799,13 @@ HRESULT TUnorderedAccessViewVariable<IBaseInterface>::SetUnorderedAccessView(ID3
#ifdef _DEBUG
static LPCSTR pFuncName = "ID3DX11EffectUnorderedAccessViewVariable::SetUnorderedAccessView";
- VH(ValidateTextureType(pResource, this->pType->ObjectType, pFuncName));
+ VH(ValidateTextureType(pResource, pType->ObjectType, pFuncName));
#endif
// UAV variables don't need to be dirtied.
SAFE_ADDREF(pResource);
- SAFE_RELEASE(this->Data.pUnorderedAccessView->pUnorderedAccessView);
- this->Data.pUnorderedAccessView->pUnorderedAccessView = pResource;
+ SAFE_RELEASE(Data.pUnorderedAccessView->pUnorderedAccessView);
+ Data.pUnorderedAccessView->pUnorderedAccessView = pResource;
lExit:
return hr;
@@ -3827,9 +3823,9 @@ HRESULT TUnorderedAccessViewVariable<IBaseInterface>::GetUnorderedAccessView(ID3
VERIFYPARAMETER(ppResource);
#endif
- assert(this->Data.pUnorderedAccessView != 0 && this->Data.pUnorderedAccessView->pUnorderedAccessView != 0);
- _Analysis_assume_(this->Data.pUnorderedAccessView != 0 && this->Data.pUnorderedAccessView->pUnorderedAccessView != 0);
- *ppResource = this->Data.pUnorderedAccessView->pUnorderedAccessView;
+ assert(Data.pUnorderedAccessView != 0 && Data.pUnorderedAccessView->pUnorderedAccessView != 0);
+ _Analysis_assume_(Data.pUnorderedAccessView != 0 && Data.pUnorderedAccessView->pUnorderedAccessView != 0);
+ *ppResource = Data.pUnorderedAccessView->pUnorderedAccessView;
SAFE_ADDREF(*ppResource);
lExit:
@@ -3847,14 +3843,14 @@ HRESULT TUnorderedAccessViewVariable<IBaseInterface>::SetUnorderedAccessViewArra
#ifdef _DEBUG
for (size_t i = 0; i < Count; ++ i)
{
- VH(ValidateTextureType(ppResources[i], this->pType->ObjectType, pFuncName));
+ VH(ValidateTextureType(ppResources[i], pType->ObjectType, pFuncName));
}
#endif
// Texture variables don't need to be dirtied.
for (size_t i = 0; i < Count; ++ i)
{
- SUnorderedAccessView *pResourceBlock = this->Data.pUnorderedAccessView + Offset + i;
+ SUnorderedAccessView *pResourceBlock = Data.pUnorderedAccessView + Offset + i;
SAFE_ADDREF(ppResources[i]);
SAFE_RELEASE(pResourceBlock->pUnorderedAccessView);
pResourceBlock->pUnorderedAccessView = ppResources[i];
@@ -3874,7 +3870,7 @@ HRESULT TUnorderedAccessViewVariable<IBaseInterface>::GetUnorderedAccessViewArra
for (size_t i = 0; i < Count; ++ i)
{
- ppResources[i] = (this->Data.pUnorderedAccessView + Offset + i)->pUnorderedAccessView;
+ ppResources[i] = (Data.pUnorderedAccessView + Offset + i)->pUnorderedAccessView;
SAFE_ADDREF(ppResources[i]);
}
@@ -3909,8 +3905,8 @@ HRESULT TRenderTargetViewVariable<IBaseInterface>::SetRenderTarget(ID3D11RenderT
// Texture variables don't need to be dirtied.
SAFE_ADDREF(pResource);
- SAFE_RELEASE(this->Data.pRenderTargetView->pRenderTargetView);
- this->Data.pRenderTargetView->pRenderTargetView = pResource;
+ SAFE_RELEASE(Data.pRenderTargetView->pRenderTargetView);
+ Data.pRenderTargetView->pRenderTargetView = pResource;
lExit:
return hr;
@@ -3922,9 +3918,9 @@ HRESULT TRenderTargetViewVariable<IBaseInterface>::GetRenderTarget(ID3D11RenderT
{
HRESULT hr = S_OK;
- assert(this->Data.pRenderTargetView->pRenderTargetView != 0);
- _Analysis_assume_(this->Data.pRenderTargetView->pRenderTargetView != 0);
- *ppResource = this->Data.pRenderTargetView->pRenderTargetView;
+ assert(Data.pRenderTargetView->pRenderTargetView != 0);
+ _Analysis_assume_(Data.pRenderTargetView->pRenderTargetView != 0);
+ *ppResource = Data.pRenderTargetView->pRenderTargetView;
SAFE_ADDREF(*ppResource);
lExit:
@@ -3942,7 +3938,7 @@ HRESULT TRenderTargetViewVariable<IBaseInterface>::SetRenderTargetArray(ID3D11Re
// Texture variables don't need to be dirtied.
for (size_t i = 0; i < Count; ++ i)
{
- SRenderTargetView *pResourceBlock = this->Data.pRenderTargetView + Offset + i;
+ SRenderTargetView *pResourceBlock = Data.pRenderTargetView + Offset + i;
SAFE_ADDREF(ppResources[i]);
SAFE_RELEASE(pResourceBlock->pRenderTargetView);
pResourceBlock->pRenderTargetView = ppResources[i];
@@ -3962,7 +3958,7 @@ HRESULT TRenderTargetViewVariable<IBaseInterface>::GetRenderTargetArray(ID3D11Re
for (size_t i = 0; i < Count; ++ i)
{
- ppResources[i] = (this->Data.pRenderTargetView + Offset + i)->pRenderTargetView;
+ ppResources[i] = (Data.pRenderTargetView + Offset + i)->pRenderTargetView;
SAFE_ADDREF(ppResources[i]);
}
@@ -3998,8 +3994,8 @@ HRESULT TDepthStencilViewVariable<IBaseInterface>::SetDepthStencil(ID3D11DepthSt
// Texture variables don't need to be dirtied.
SAFE_ADDREF(pResource);
- SAFE_RELEASE(this->Data.pDepthStencilView->pDepthStencilView);
- this->Data.pDepthStencilView->pDepthStencilView = pResource;
+ SAFE_RELEASE(Data.pDepthStencilView->pDepthStencilView);
+ Data.pDepthStencilView->pDepthStencilView = pResource;
lExit:
return hr;
@@ -4017,9 +4013,9 @@ HRESULT TDepthStencilViewVariable<IBaseInterface>::GetDepthStencil(ID3D11DepthSt
VERIFYPARAMETER(ppResource);
#endif
- assert(this->Data.pDepthStencilView->pDepthStencilView != 0);
- _Analysis_assume_(this->Data.pDepthStencilView->pDepthStencilView != 0);
- *ppResource = this->Data.pDepthStencilView->pDepthStencilView;
+ assert(Data.pDepthStencilView->pDepthStencilView != 0);
+ _Analysis_assume_(Data.pDepthStencilView->pDepthStencilView != 0);
+ *ppResource = Data.pDepthStencilView->pDepthStencilView;
SAFE_ADDREF(*ppResource);
lExit:
@@ -4037,7 +4033,7 @@ HRESULT TDepthStencilViewVariable<IBaseInterface>::SetDepthStencilArray(ID3D11De
// Texture variables don't need to be dirtied.
for (size_t i = 0; i < Count; ++ i)
{
- SDepthStencilView *pResourceBlock = this->Data.pDepthStencilView + Offset + i;
+ SDepthStencilView *pResourceBlock = Data.pDepthStencilView + Offset + i;
SAFE_ADDREF(ppResources[i]);
SAFE_RELEASE(pResourceBlock->pDepthStencilView);
pResourceBlock->pDepthStencilView = ppResources[i];
@@ -4057,7 +4053,7 @@ HRESULT TDepthStencilViewVariable<IBaseInterface>::GetDepthStencilArray(ID3D11De
for (size_t i = 0; i < Count; ++ i)
{
- ppResources[i] = (this->Data.pDepthStencilView + Offset + i)->pDepthStencilView;
+ ppResources[i] = (Data.pDepthStencilView + Offset + i)->pDepthStencilView;
SAFE_ADDREF(ppResources[i]);
}
@@ -4096,7 +4092,7 @@ HRESULT TShaderVariable<IBaseInterface>::GetShaderDesc(uint32_t ShaderIndex, D3D
CHECK_OBJECT_SCALAR_BOUNDS(ShaderIndex, pDesc);
- hr = this->Data.pShader[ShaderIndex].GetShaderDesc(pDesc, false);
+ hr = Data.pShader[ShaderIndex].GetShaderDesc(pDesc, false);
lExit:
return hr;
@@ -4110,7 +4106,7 @@ HRESULT TShaderVariable<IBaseInterface>::GetVertexShader(uint32_t ShaderIndex, I
CHECK_OBJECT_SCALAR_BOUNDS(ShaderIndex, ppVS);
- VH( this->Data.pShader[ShaderIndex].GetVertexShader(ppVS) );
+ VH( Data.pShader[ShaderIndex].GetVertexShader(ppVS) );
lExit:
return hr;
@@ -4124,7 +4120,7 @@ HRESULT TShaderVariable<IBaseInterface>::GetGeometryShader(uint32_t ShaderIndex,
CHECK_OBJECT_SCALAR_BOUNDS(ShaderIndex, ppGS);
- VH( this->Data.pShader[ShaderIndex].GetGeometryShader(ppGS) );
+ VH( Data.pShader[ShaderIndex].GetGeometryShader(ppGS) );
lExit:
return hr;
@@ -4138,7 +4134,7 @@ HRESULT TShaderVariable<IBaseInterface>::GetPixelShader(uint32_t ShaderIndex, ID
CHECK_OBJECT_SCALAR_BOUNDS(ShaderIndex, ppPS);
- VH( this->Data.pShader[ShaderIndex].GetPixelShader(ppPS) );
+ VH( Data.pShader[ShaderIndex].GetPixelShader(ppPS) );
lExit:
return hr;
@@ -4152,7 +4148,7 @@ HRESULT TShaderVariable<IBaseInterface>::GetHullShader(uint32_t ShaderIndex, ID3
CHECK_OBJECT_SCALAR_BOUNDS(ShaderIndex, ppHS);
- VH( this->Data.pShader[ShaderIndex].GetHullShader(ppHS) );
+ VH( Data.pShader[ShaderIndex].GetHullShader(ppHS) );
lExit:
return hr;
@@ -4166,7 +4162,7 @@ HRESULT TShaderVariable<IBaseInterface>::GetDomainShader(uint32_t ShaderIndex, I
CHECK_OBJECT_SCALAR_BOUNDS(ShaderIndex, ppDS);
- VH( this->Data.pShader[ShaderIndex].GetDomainShader(ppDS) );
+ VH( Data.pShader[ShaderIndex].GetDomainShader(ppDS) );
lExit:
return hr;
@@ -4180,7 +4176,7 @@ HRESULT TShaderVariable<IBaseInterface>::GetComputeShader(uint32_t ShaderIndex,
CHECK_OBJECT_SCALAR_BOUNDS(ShaderIndex, ppCS);
- VH( this->Data.pShader[ShaderIndex].GetComputeShader(ppCS) );
+ VH( Data.pShader[ShaderIndex].GetComputeShader(ppCS) );
lExit:
return hr;
@@ -4194,7 +4190,7 @@ HRESULT TShaderVariable<IBaseInterface>::GetInputSignatureElementDesc(uint32_t S
CHECK_OBJECT_SCALAR_BOUNDS(ShaderIndex, pDesc);
- VH( this->Data.pShader[ShaderIndex].GetSignatureElementDesc(SShaderBlock::ST_Input, Element, pDesc) );
+ VH( Data.pShader[ShaderIndex].GetSignatureElementDesc(SShaderBlock::ST_Input, Element, pDesc) );
lExit:
return hr;
@@ -4208,7 +4204,7 @@ HRESULT TShaderVariable<IBaseInterface>::GetOutputSignatureElementDesc(uint32_t
CHECK_OBJECT_SCALAR_BOUNDS(ShaderIndex, pDesc);
- VH( this->Data.pShader[ShaderIndex].GetSignatureElementDesc(SShaderBlock::ST_Output, Element, pDesc) );
+ VH( Data.pShader[ShaderIndex].GetSignatureElementDesc(SShaderBlock::ST_Output, Element, pDesc) );
lExit:
return hr;
@@ -4222,7 +4218,7 @@ HRESULT TShaderVariable<IBaseInterface>::GetPatchConstantSignatureElementDesc(ui
CHECK_OBJECT_SCALAR_BOUNDS(ShaderIndex, pDesc);
- VH( this->Data.pShader[ShaderIndex].GetSignatureElementDesc(SShaderBlock::ST_PatchConstant, Element, pDesc) );
+ VH( Data.pShader[ShaderIndex].GetSignatureElementDesc(SShaderBlock::ST_PatchConstant, Element, pDesc) );
lExit:
return hr;
@@ -4231,9 +4227,9 @@ lExit:
template<typename IBaseInterface>
bool TShaderVariable<IBaseInterface>::IsValid()
{
- uint32_t numElements = this->IsArray()? this->pType->Elements : 1;
+ uint32_t numElements = IsArray()? pType->Elements : 1;
bool valid = true;
- while( numElements > 0 && ( valid = this->Data.pShader[ numElements-1 ].IsValid ) )
+ while( numElements > 0 && ( valid = Data.pShader[ numElements-1 ].IsValid ) )
numElements--;
return valid;
}
@@ -4261,9 +4257,9 @@ HRESULT TBlendVariable<IBaseInterface>::GetBlendState(uint32_t Index, ID3D11Blen
CHECK_OBJECT_SCALAR_BOUNDS(Index, ppState);
- assert(this->Data.pBlend[Index].pBlendObject != 0);
- _Analysis_assume_(this->Data.pBlend[Index].pBlendObject != 0);
- *ppState = this->Data.pBlend[Index].pBlendObject;
+ assert(Data.pBlend[Index].pBlendObject != 0);
+ _Analysis_assume_(Data.pBlend[Index].pBlendObject != 0);
+ *ppState = Data.pBlend[Index].pBlendObject;
SAFE_ADDREF(*ppState);
lExit:
@@ -4278,20 +4274,20 @@ HRESULT TBlendVariable<IBaseInterface>::SetBlendState(uint32_t Index, ID3D11Blen
CHECK_SCALAR_BOUNDS(Index);
- if( !this->Data.pBlend[Index].IsUserManaged )
+ if( !Data.pBlend[Index].IsUserManaged )
{
// Save original state object in case we UndoSet
- assert( this->pMemberData[Index].Type == MDT_BlendState );
- VB( this->pMemberData[Index].Data.pD3DEffectsManagedBlendState == nullptr );
- this->pMemberData[Index].Data.pD3DEffectsManagedBlendState = this->Data.pBlend[Index].pBlendObject;
- this->Data.pBlend[Index].pBlendObject = nullptr;
- this->Data.pBlend[Index].IsUserManaged = true;
+ assert( pMemberData[Index].Type == MDT_BlendState );
+ VB( pMemberData[Index].Data.pD3DEffectsManagedBlendState == nullptr );
+ pMemberData[Index].Data.pD3DEffectsManagedBlendState = Data.pBlend[Index].pBlendObject;
+ Data.pBlend[Index].pBlendObject = nullptr;
+ Data.pBlend[Index].IsUserManaged = true;
}
SAFE_ADDREF( pState );
- SAFE_RELEASE( this->Data.pBlend[Index].pBlendObject );
- this->Data.pBlend[Index].pBlendObject = pState;
- this->Data.pBlend[Index].IsValid = true;
+ SAFE_RELEASE( Data.pBlend[Index].pBlendObject );
+ Data.pBlend[Index].pBlendObject = pState;
+ Data.pBlend[Index].IsValid = true;
lExit:
return hr;
}
@@ -4304,16 +4300,16 @@ HRESULT TBlendVariable<IBaseInterface>::UndoSetBlendState(uint32_t Index)
CHECK_SCALAR_BOUNDS(Index);
- if( !this->Data.pBlend[Index].IsUserManaged )
+ if( !Data.pBlend[Index].IsUserManaged )
{
return S_FALSE;
}
// Revert to original state object
- SAFE_RELEASE( this->Data.pBlend[Index].pBlendObject );
- this->Data.pBlend[Index].pBlendObject = this->pMemberData[Index].Data.pD3DEffectsManagedBlendState;
- this->pMemberData[Index].Data.pD3DEffectsManagedBlendState = nullptr;
- this->Data.pBlend[Index].IsUserManaged = false;
+ SAFE_RELEASE( Data.pBlend[Index].pBlendObject );
+ Data.pBlend[Index].pBlendObject = pMemberData[Index].Data.pD3DEffectsManagedBlendState;
+ pMemberData[Index].Data.pD3DEffectsManagedBlendState = nullptr;
+ Data.pBlend[Index].IsUserManaged = false;
lExit:
return hr;
@@ -4327,11 +4323,11 @@ HRESULT TBlendVariable<IBaseInterface>::GetBackingStore(uint32_t Index, D3D11_BL
CHECK_OBJECT_SCALAR_BOUNDS(Index, pBlendDesc);
- if( this->Data.pBlend[Index].IsUserManaged )
+ if( Data.pBlend[Index].IsUserManaged )
{
- if( this->Data.pBlend[Index].pBlendObject )
+ if( Data.pBlend[Index].pBlendObject )
{
- this->Data.pBlend[Index].pBlendObject->GetDesc( pBlendDesc );
+ Data.pBlend[Index].pBlendObject->GetDesc( pBlendDesc );
}
else
{
@@ -4340,8 +4336,8 @@ HRESULT TBlendVariable<IBaseInterface>::GetBackingStore(uint32_t Index, D3D11_BL
}
else
{
- SBlendBlock *pBlock = this->Data.pBlend + Index;
- if (pBlock->ApplyAssignments(this->GetTopLevelEntity()->pEffect))
+ SBlendBlock *pBlock = Data.pBlend + Index;
+ if (pBlock->ApplyAssignments(GetTopLevelEntity()->pEffect))
{
pBlock->pAssignments[0].LastRecomputedTime = 0; // Force a recreate of this block the next time ApplyRenderStateBlock is called
}
@@ -4356,9 +4352,9 @@ lExit:
template<typename IBaseInterface>
bool TBlendVariable<IBaseInterface>::IsValid()
{
- uint32_t numElements = this->IsArray()? this->pType->Elements : 1;
+ uint32_t numElements = IsArray()? pType->Elements : 1;
bool valid = true;
- while( numElements > 0 && ( valid = this->Data.pBlend[ numElements-1 ].IsValid ) )
+ while( numElements > 0 && ( valid = Data.pBlend[ numElements-1 ].IsValid ) )
numElements--;
return valid;
}
@@ -4387,9 +4383,9 @@ HRESULT TDepthStencilVariable<IBaseInterface>::GetDepthStencilState(uint32_t Ind
CHECK_OBJECT_SCALAR_BOUNDS(Index, ppState);
- assert(this->Data.pDepthStencil[Index].pDSObject != 0);
- _Analysis_assume_(this->Data.pDepthStencil[Index].pDSObject != 0);
- *ppState = this->Data.pDepthStencil[Index].pDSObject;
+ assert(Data.pDepthStencil[Index].pDSObject != 0);
+ _Analysis_assume_(Data.pDepthStencil[Index].pDSObject != 0);
+ *ppState = Data.pDepthStencil[Index].pDSObject;
SAFE_ADDREF(*ppState);
lExit:
@@ -4404,20 +4400,20 @@ HRESULT TDepthStencilVariable<IBaseInterface>::SetDepthStencilState(uint32_t Ind
CHECK_SCALAR_BOUNDS(Index);
- if( !this->Data.pDepthStencil[Index].IsUserManaged )
+ if( !Data.pDepthStencil[Index].IsUserManaged )
{
// Save original state object in case we UndoSet
- assert( this->pMemberData[Index].Type == MDT_DepthStencilState );
- VB( this->pMemberData[Index].Data.pD3DEffectsManagedDepthStencilState == nullptr );
- this->pMemberData[Index].Data.pD3DEffectsManagedDepthStencilState = this->Data.pDepthStencil[Index].pDSObject;
- this->Data.pDepthStencil[Index].pDSObject = nullptr;
- this->Data.pDepthStencil[Index].IsUserManaged = true;
+ assert( pMemberData[Index].Type == MDT_DepthStencilState );
+ VB( pMemberData[Index].Data.pD3DEffectsManagedDepthStencilState == nullptr );
+ pMemberData[Index].Data.pD3DEffectsManagedDepthStencilState = Data.pDepthStencil[Index].pDSObject;
+ Data.pDepthStencil[Index].pDSObject = nullptr;
+ Data.pDepthStencil[Index].IsUserManaged = true;
}
SAFE_ADDREF( pState );
- SAFE_RELEASE( this->Data.pDepthStencil[Index].pDSObject );
- this->Data.pDepthStencil[Index].pDSObject = pState;
- this->Data.pDepthStencil[Index].IsValid = true;
+ SAFE_RELEASE( Data.pDepthStencil[Index].pDSObject );
+ Data.pDepthStencil[Index].pDSObject = pState;
+ Data.pDepthStencil[Index].IsValid = true;
lExit:
return hr;
}
@@ -4429,16 +4425,16 @@ HRESULT TDepthStencilVariable<IBaseInterface>::UndoSetDepthStencilState(_In_ uin
CHECK_SCALAR_BOUNDS(Index);
- if( !this->Data.pDepthStencil[Index].IsUserManaged )
+ if( !Data.pDepthStencil[Index].IsUserManaged )
{
return S_FALSE;
}
// Revert to original state object
- SAFE_RELEASE( this->Data.pDepthStencil[Index].pDSObject );
- this->Data.pDepthStencil[Index].pDSObject = this->pMemberData[Index].Data.pD3DEffectsManagedDepthStencilState;
- this->pMemberData[Index].Data.pD3DEffectsManagedDepthStencilState = nullptr;
- this->Data.pDepthStencil[Index].IsUserManaged = false;
+ SAFE_RELEASE( Data.pDepthStencil[Index].pDSObject );
+ Data.pDepthStencil[Index].pDSObject = pMemberData[Index].Data.pD3DEffectsManagedDepthStencilState;
+ pMemberData[Index].Data.pD3DEffectsManagedDepthStencilState = nullptr;
+ Data.pDepthStencil[Index].IsUserManaged = false;
lExit:
return hr;
@@ -4452,11 +4448,11 @@ HRESULT TDepthStencilVariable<IBaseInterface>::GetBackingStore(uint32_t Index, D
CHECK_OBJECT_SCALAR_BOUNDS(Index, pDepthStencilDesc);
- if( this->Data.pDepthStencil[Index].IsUserManaged )
+ if( Data.pDepthStencil[Index].IsUserManaged )
{
- if( this->Data.pDepthStencil[Index].pDSObject )
+ if( Data.pDepthStencil[Index].pDSObject )
{
- this->Data.pDepthStencil[Index].pDSObject->GetDesc( pDepthStencilDesc );
+ Data.pDepthStencil[Index].pDSObject->GetDesc( pDepthStencilDesc );
}
else
{
@@ -4465,8 +4461,8 @@ HRESULT TDepthStencilVariable<IBaseInterface>::GetBackingStore(uint32_t Index, D
}
else
{
- SDepthStencilBlock *pBlock = this->Data.pDepthStencil + Index;
- if (pBlock->ApplyAssignments(this->GetTopLevelEntity()->pEffect))
+ SDepthStencilBlock *pBlock = Data.pDepthStencil + Index;
+ if (pBlock->ApplyAssignments(GetTopLevelEntity()->pEffect))
{
pBlock->pAssignments[0].LastRecomputedTime = 0; // Force a recreate of this block the next time ApplyRenderStateBlock is called
}
@@ -4481,9 +4477,9 @@ lExit:
template<typename IBaseInterface>
bool TDepthStencilVariable<IBaseInterface>::IsValid()
{
- uint32_t numElements = this->IsArray()? this->pType->Elements : 1;
+ uint32_t numElements = IsArray()? pType->Elements : 1;
bool valid = true;
- while( numElements > 0 && ( valid = this->Data.pDepthStencil[ numElements-1 ].IsValid ) )
+ while( numElements > 0 && ( valid = Data.pDepthStencil[ numElements-1 ].IsValid ) )
numElements--;
return valid;
}
@@ -4512,9 +4508,9 @@ HRESULT TRasterizerVariable<IBaseInterface>::GetRasterizerState(uint32_t Index,
CHECK_OBJECT_SCALAR_BOUNDS(Index, ppState);
- assert(this->Data.pRasterizer[Index].pRasterizerObject != 0);
- _Analysis_assume_(this->Data.pRasterizer[Index].pRasterizerObject != 0);
- *ppState = this->Data.pRasterizer[Index].pRasterizerObject;
+ assert(Data.pRasterizer[Index].pRasterizerObject != 0);
+ _Analysis_assume_(Data.pRasterizer[Index].pRasterizerObject != 0);
+ *ppState = Data.pRasterizer[Index].pRasterizerObject;
SAFE_ADDREF(*ppState);
lExit:
@@ -4529,20 +4525,20 @@ HRESULT TRasterizerVariable<IBaseInterface>::SetRasterizerState(uint32_t Index,
CHECK_SCALAR_BOUNDS(Index);
- if( !this->Data.pRasterizer[Index].IsUserManaged )
+ if( !Data.pRasterizer[Index].IsUserManaged )
{
// Save original state object in case we UndoSet
- assert( this->pMemberData[Index].Type == MDT_RasterizerState );
- VB( this->pMemberData[Index].Data.pD3DEffectsManagedRasterizerState == nullptr );
- this->pMemberData[Index].Data.pD3DEffectsManagedRasterizerState = this->Data.pRasterizer[Index].pRasterizerObject;
- this->Data.pRasterizer[Index].pRasterizerObject = nullptr;
- this->Data.pRasterizer[Index].IsUserManaged = true;
+ assert( pMemberData[Index].Type == MDT_RasterizerState );
+ VB( pMemberData[Index].Data.pD3DEffectsManagedRasterizerState == nullptr );
+ pMemberData[Index].Data.pD3DEffectsManagedRasterizerState = Data.pRasterizer[Index].pRasterizerObject;
+ Data.pRasterizer[Index].pRasterizerObject = nullptr;
+ Data.pRasterizer[Index].IsUserManaged = true;
}
SAFE_ADDREF( pState );
- SAFE_RELEASE( this->Data.pRasterizer[Index].pRasterizerObject );
- this->Data.pRasterizer[Index].pRasterizerObject = pState;
- this->Data.pRasterizer[Index].IsValid = true;
+ SAFE_RELEASE( Data.pRasterizer[Index].pRasterizerObject );
+ Data.pRasterizer[Index].pRasterizerObject = pState;
+ Data.pRasterizer[Index].IsValid = true;
lExit:
return hr;
}
@@ -4555,16 +4551,16 @@ HRESULT TRasterizerVariable<IBaseInterface>::UndoSetRasterizerState(uint32_t Ind
CHECK_SCALAR_BOUNDS(Index);
- if( !this->Data.pRasterizer[Index].IsUserManaged )
+ if( !Data.pRasterizer[Index].IsUserManaged )
{
return S_FALSE;
}
// Revert to original state object
- SAFE_RELEASE( this->Data.pRasterizer[Index].pRasterizerObject );
- this->Data.pRasterizer[Index].pRasterizerObject = this->pMemberData[Index].Data.pD3DEffectsManagedRasterizerState;
- this->pMemberData[Index].Data.pD3DEffectsManagedRasterizerState = nullptr;
- this->Data.pRasterizer[Index].IsUserManaged = false;
+ SAFE_RELEASE( Data.pRasterizer[Index].pRasterizerObject );
+ Data.pRasterizer[Index].pRasterizerObject = pMemberData[Index].Data.pD3DEffectsManagedRasterizerState;
+ pMemberData[Index].Data.pD3DEffectsManagedRasterizerState = nullptr;
+ Data.pRasterizer[Index].IsUserManaged = false;
lExit:
return hr;
@@ -4578,11 +4574,11 @@ HRESULT TRasterizerVariable<IBaseInterface>::GetBackingStore(uint32_t Index, D3D
CHECK_OBJECT_SCALAR_BOUNDS(Index, pRasterizerDesc);
- if( this->Data.pRasterizer[Index].IsUserManaged )
+ if( Data.pRasterizer[Index].IsUserManaged )
{
- if( this->Data.pRasterizer[Index].pRasterizerObject )
+ if( Data.pRasterizer[Index].pRasterizerObject )
{
- this->Data.pRasterizer[Index].pRasterizerObject->GetDesc( pRasterizerDesc );
+ Data.pRasterizer[Index].pRasterizerObject->GetDesc( pRasterizerDesc );
}
else
{
@@ -4591,8 +4587,8 @@ HRESULT TRasterizerVariable<IBaseInterface>::GetBackingStore(uint32_t Index, D3D
}
else
{
- SRasterizerBlock *pBlock = this->Data.pRasterizer + Index;
- if (pBlock->ApplyAssignments(this->GetTopLevelEntity()->pEffect))
+ SRasterizerBlock *pBlock = Data.pRasterizer + Index;
+ if (pBlock->ApplyAssignments(GetTopLevelEntity()->pEffect))
{
pBlock->pAssignments[0].LastRecomputedTime = 0; // Force a recreate of this block the next time ApplyRenderStateBlock is called
}
@@ -4607,9 +4603,9 @@ lExit:
template<typename IBaseInterface>
bool TRasterizerVariable<IBaseInterface>::IsValid()
{
- uint32_t numElements = this->IsArray()? this->pType->Elements : 1;
+ uint32_t numElements = IsArray()? pType->Elements : 1;
bool valid = true;
- while( numElements > 0 && ( valid = this->Data.pRasterizer[ numElements-1 ].IsValid ) )
+ while( numElements > 0 && ( valid = Data.pRasterizer[ numElements-1 ].IsValid ) )
numElements--;
return valid;
}
@@ -4637,8 +4633,8 @@ HRESULT TSamplerVariable<IBaseInterface>::GetSampler(uint32_t Index, ID3D11Sampl
CHECK_OBJECT_SCALAR_BOUNDS(Index, ppSampler);
- _Analysis_assume_( this->Data.pSampler[Index].pD3DObject != 0 );
- *ppSampler = this->Data.pSampler[Index].pD3DObject;
+ _Analysis_assume_( Data.pSampler[Index].pD3DObject != 0 );
+ *ppSampler = Data.pSampler[Index].pD3DObject;
SAFE_ADDREF(*ppSampler);
lExit:
@@ -4654,21 +4650,21 @@ HRESULT TSamplerVariable<IBaseInterface>::SetSampler(uint32_t Index, ID3D11Sampl
CHECK_SCALAR_BOUNDS(Index);
// Replace all references to the old shader block with this one
- this->GetEffect()->ReplaceSamplerReference(&this->Data.pSampler[Index], pSampler);
+ GetEffect()->ReplaceSamplerReference(&Data.pSampler[Index], pSampler);
- if( !this->Data.pSampler[Index].IsUserManaged )
+ if( !Data.pSampler[Index].IsUserManaged )
{
// Save original state object in case we UndoSet
- assert( this->pMemberData[Index].Type == MDT_SamplerState );
- VB( this->pMemberData[Index].Data.pD3DEffectsManagedSamplerState == nullptr );
- this->pMemberData[Index].Data.pD3DEffectsManagedSamplerState = this->Data.pSampler[Index].pD3DObject;
- this->Data.pSampler[Index].pD3DObject = nullptr;
- this->Data.pSampler[Index].IsUserManaged = true;
+ assert( pMemberData[Index].Type == MDT_SamplerState );
+ VB( pMemberData[Index].Data.pD3DEffectsManagedSamplerState == nullptr );
+ pMemberData[Index].Data.pD3DEffectsManagedSamplerState = Data.pSampler[Index].pD3DObject;
+ Data.pSampler[Index].pD3DObject = nullptr;
+ Data.pSampler[Index].IsUserManaged = true;
}
SAFE_ADDREF( pSampler );
- SAFE_RELEASE( this->Data.pSampler[Index].pD3DObject );
- this->Data.pSampler[Index].pD3DObject = pSampler;
+ SAFE_RELEASE( Data.pSampler[Index].pD3DObject );
+ Data.pSampler[Index].pD3DObject = pSampler;
lExit:
return hr;
}
@@ -4680,19 +4676,19 @@ HRESULT TSamplerVariable<IBaseInterface>::UndoSetSampler(_In_ uint32_t Index)
CHECK_SCALAR_BOUNDS(Index);
- if( !this->Data.pSampler[Index].IsUserManaged )
+ if( !Data.pSampler[Index].IsUserManaged )
{
return S_FALSE;
}
// Replace all references to the old shader block with this one
- this->GetEffect()->ReplaceSamplerReference(&this->Data.pSampler[Index], this->pMemberData[Index].Data.pD3DEffectsManagedSamplerState);
+ GetEffect()->ReplaceSamplerReference(&Data.pSampler[Index], pMemberData[Index].Data.pD3DEffectsManagedSamplerState);
// Revert to original state object
- SAFE_RELEASE( this->Data.pSampler[Index].pD3DObject );
- this->Data.pSampler[Index].pD3DObject = this->pMemberData[Index].Data.pD3DEffectsManagedSamplerState;
- this->pMemberData[Index].Data.pD3DEffectsManagedSamplerState = nullptr;
- this->Data.pSampler[Index].IsUserManaged = false;
+ SAFE_RELEASE( Data.pSampler[Index].pD3DObject );
+ Data.pSampler[Index].pD3DObject = pMemberData[Index].Data.pD3DEffectsManagedSamplerState;
+ pMemberData[Index].Data.pD3DEffectsManagedSamplerState = nullptr;
+ Data.pSampler[Index].IsUserManaged = false;
lExit:
return hr;
@@ -4706,11 +4702,11 @@ HRESULT TSamplerVariable<IBaseInterface>::GetBackingStore(uint32_t Index, D3D11_
CHECK_OBJECT_SCALAR_BOUNDS(Index, pDesc);
- if( this->Data.pSampler[Index].IsUserManaged )
+ if( Data.pSampler[Index].IsUserManaged )
{
- if( this->Data.pSampler[Index].pD3DObject )
+ if( Data.pSampler[Index].pD3DObject )
{
- this->Data.pSampler[Index].pD3DObject->GetDesc( pDesc );
+ Data.pSampler[Index].pD3DObject->GetDesc( pDesc );
}
else
{
@@ -4719,8 +4715,8 @@ HRESULT TSamplerVariable<IBaseInterface>::GetBackingStore(uint32_t Index, D3D11_
}
else
{
- SSamplerBlock *pBlock = this->Data.pSampler + Index;
- if (pBlock->ApplyAssignments(this->GetTopLevelEntity()->pEffect))
+ SSamplerBlock *pBlock = Data.pSampler + Index;
+ if (pBlock->ApplyAssignments(GetTopLevelEntity()->pEffect))
{
pBlock->pAssignments[0].LastRecomputedTime = 0; // Force a recreate of this block the next time ApplyRenderStateBlock is called
}