AtomLyIntegration
Signed-off-by: Esteban Papp <81431996+amznestebanpapp@users.noreply.github.com>
This commit is contained in:
+1
-1
@@ -238,7 +238,7 @@ namespace AZ
|
||||
|
||||
uint32_t AssetCollectionAsyncLoaderTestComponent::GetCountOfPendingAssets() const
|
||||
{
|
||||
return m_pendingAssets.size();
|
||||
return static_cast<uint32_t>(m_pendingAssets.size());
|
||||
}
|
||||
|
||||
bool AssetCollectionAsyncLoaderTestComponent::ValidateAssetWasLoaded(const AZStd::string& assetPath) const
|
||||
|
||||
@@ -331,7 +331,7 @@ void AZ::FFont::DrawStringUInternal(
|
||||
m_vertexBuffer[vertexOffset + 3].color.dcolor = packedColor;
|
||||
m_vertexBuffer[vertexOffset + 3].st = tc3;
|
||||
|
||||
uint16_t startingIndex = vertexOffset - startingVertexCount;
|
||||
uint16_t startingIndex = static_cast<uint16_t>(vertexOffset - startingVertexCount);
|
||||
m_indexBuffer[indexOffset + 0] = startingIndex + 0;
|
||||
m_indexBuffer[indexOffset + 1] = startingIndex + 1;
|
||||
m_indexBuffer[indexOffset + 2] = startingIndex + 2;
|
||||
@@ -697,12 +697,12 @@ uint32_t AZ::FFont::WriteTextQuadsToBuffers(SVF_P2F_C4B_T2F_F4B* verts, uint16_t
|
||||
vertexData[vertexOffset + 3].texIndex2 = 0;
|
||||
vertexData[vertexOffset + 3].pad = 0;
|
||||
|
||||
indexData[indexOffset + 0] = vertexOffset + 0;
|
||||
indexData[indexOffset + 1] = vertexOffset + 1;
|
||||
indexData[indexOffset + 2] = vertexOffset + 2;
|
||||
indexData[indexOffset + 3] = vertexOffset + 2;
|
||||
indexData[indexOffset + 4] = vertexOffset + 3;
|
||||
indexData[indexOffset + 5] = vertexOffset + 0;
|
||||
indexData[indexOffset + 0] = static_cast<uint16_t>(vertexOffset + 0);
|
||||
indexData[indexOffset + 1] = static_cast<uint16_t>(vertexOffset + 1);
|
||||
indexData[indexOffset + 2] = static_cast<uint16_t>(vertexOffset + 2);
|
||||
indexData[indexOffset + 3] = static_cast<uint16_t>(vertexOffset + 2);
|
||||
indexData[indexOffset + 4] = static_cast<uint16_t>(vertexOffset + 3);
|
||||
indexData[indexOffset + 5] = static_cast<uint16_t>(vertexOffset + 0);
|
||||
|
||||
vertexOffset += 4;
|
||||
indexOffset += 6;
|
||||
@@ -1331,7 +1331,7 @@ unsigned int AZ::FFont::GetEffectId(const char* effectName) const
|
||||
{
|
||||
if (!strcmp(m_effects[i].m_name.c_str(), effectName))
|
||||
{
|
||||
return i;
|
||||
return static_cast<unsigned int>(i);
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -1341,7 +1341,7 @@ unsigned int AZ::FFont::GetEffectId(const char* effectName) const
|
||||
|
||||
unsigned int AZ::FFont::GetNumEffects() const
|
||||
{
|
||||
return m_effects.size();
|
||||
return static_cast<unsigned int>(m_effects.size());
|
||||
}
|
||||
|
||||
const char* AZ::FFont::GetEffectName(unsigned int effectId) const
|
||||
|
||||
+1
-1
@@ -207,7 +207,7 @@ namespace AZ::Render
|
||||
createVertex(-0.5f, 0.5f, 0.f, 1.f)
|
||||
};
|
||||
AZStd::array<Indice, 6> indices = {0, 1, 2, 0, 2, 3};
|
||||
dynamicDraw->DrawIndexed(&vertices, vertices.size(), &indices, indices.size(), RHI::IndexFormat::Uint16, drawSrg);
|
||||
dynamicDraw->DrawIndexed(&vertices, static_cast<uint32_t>(vertices.size()), &indices, static_cast<uint32_t>(indices.size()), RHI::IndexFormat::Uint16, drawSrg);
|
||||
}
|
||||
|
||||
QString AtomViewportDisplayIconsSystemComponent::FindAssetPath(const QString& path) const
|
||||
|
||||
+1
-1
@@ -54,7 +54,7 @@ namespace AZ
|
||||
{
|
||||
transformedVertices.push_back(transform.TransformPoint(Vector3(vertex.GetX(), vertex.GetY(), 0.0f)));
|
||||
}
|
||||
GetFeatureProcessor()->SetPolygonPoints(GetLightHandle(), transformedVertices.data(), transformedVertices.size(), GetTransform().GetBasisZ());
|
||||
GetFeatureProcessor()->SetPolygonPoints(GetLightHandle(), transformedVertices.data(), static_cast<uint32_t>(transformedVertices.size()), GetTransform().GetBasisZ());
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -213,7 +213,7 @@ namespace AZ
|
||||
{
|
||||
EditorMeshStatsForLod stats;
|
||||
const auto& meshes = lodAsset->GetMeshes();
|
||||
stats.m_meshCount = meshes.size();
|
||||
stats.m_meshCount = static_cast<AZ::u32>(meshes.size());
|
||||
for (const auto& mesh : meshes)
|
||||
{
|
||||
stats.m_vertCount += mesh.GetVertexCount();
|
||||
|
||||
@@ -58,7 +58,7 @@ namespace AZ
|
||||
{
|
||||
if (m_modelAsset.IsReady())
|
||||
{
|
||||
lodCount = m_modelAsset->GetLodCount();
|
||||
lodCount = static_cast<uint32_t>(m_modelAsset->GetLodCount());
|
||||
}
|
||||
else
|
||||
{
|
||||
@@ -66,7 +66,7 @@ namespace AZ
|
||||
Data::Instance<RPI::Model> model = Data::InstanceDatabase<RPI::Model>::Instance().Find(Data::InstanceId::CreateFromAssetId(m_modelAsset.GetId()));
|
||||
if (model)
|
||||
{
|
||||
lodCount = model->GetLodCount();
|
||||
lodCount = static_cast<uint32_t>(model->GetLodCount());
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -212,7 +212,7 @@ namespace AZ
|
||||
for (uint32_t vertexIndex = 0; vertexIndex < vertexCount; ++vertexIndex)
|
||||
{
|
||||
const uint32_t originalVertex = sourceOriginalVertex[vertexIndex + vertexStart];
|
||||
const uint32_t influenceCount = AZStd::GetMin<uint32_t>(MaxSupportedSkinInfluences, sourceSkinningInfo->GetNumInfluences(originalVertex));
|
||||
const uint32_t influenceCount = AZStd::GetMin<uint32_t>(MaxSupportedSkinInfluences, static_cast<uint32_t>(sourceSkinningInfo->GetNumInfluences(originalVertex)));
|
||||
uint32_t influenceIndex = 0;
|
||||
float weightError = 1.0f;
|
||||
|
||||
@@ -379,7 +379,7 @@ namespace AZ
|
||||
size_t skinnedMeshSubmeshIndex = 0;
|
||||
for (size_t jointIndex = 0; jointIndex < numJoints; ++jointIndex)
|
||||
{
|
||||
const EMotionFX::Mesh* mesh = actor->GetMesh(lodIndex, jointIndex);
|
||||
const EMotionFX::Mesh* mesh = actor->GetMesh(static_cast<uint32>(lodIndex), static_cast<uint32>(jointIndex));
|
||||
if (!mesh || mesh->GetIsCollisionMesh())
|
||||
{
|
||||
continue;
|
||||
@@ -405,7 +405,7 @@ namespace AZ
|
||||
|
||||
for (size_t subMeshIndex = 0; subMeshIndex < numSubMeshes; ++subMeshIndex)
|
||||
{
|
||||
const EMotionFX::SubMesh* subMesh = mesh->GetSubMesh(subMeshIndex);
|
||||
const EMotionFX::SubMesh* subMesh = mesh->GetSubMesh(static_cast<uint32>(subMeshIndex));
|
||||
const size_t vertexCount = subMesh->GetNumVertices();
|
||||
|
||||
// Skip empty sub-meshes and sub-meshes that would put the total vertex count beyond the supported range
|
||||
@@ -509,7 +509,7 @@ namespace AZ
|
||||
|
||||
if (morphBufferAssetView)
|
||||
{
|
||||
ProcessMorphsForLod(actor, morphBufferAssetView->GetBufferAsset(), lodIndex, fullFileName, skinnedMeshLod);
|
||||
ProcessMorphsForLod(actor, morphBufferAssetView->GetBufferAsset(), static_cast<uint32_t>(lodIndex), fullFileName, skinnedMeshLod);
|
||||
}
|
||||
|
||||
// Set colors after morphs are set, so that we know whether or not they are dynamic (if they exist)
|
||||
@@ -594,7 +594,7 @@ namespace AZ
|
||||
descriptor.m_bufferData = boneTransforms.data();
|
||||
descriptor.m_bufferName = AZStd::string::format("BoneTransformBuffer_%s", actorInstance->GetActor()->GetName());
|
||||
descriptor.m_byteCount = boneTransforms.size() * sizeof(float);
|
||||
descriptor.m_elementSize = floatsPerBone * sizeof(float);
|
||||
descriptor.m_elementSize = static_cast<uint32_t>(floatsPerBone * sizeof(float));
|
||||
descriptor.m_poolType = RPI::CommonBufferPoolType::ReadOnly;
|
||||
return RPI::BufferSystemInterface::Get()->CreateBufferFromCommonPool(descriptor);
|
||||
}
|
||||
|
||||
@@ -163,7 +163,7 @@ namespace AZ
|
||||
const AZ::Color skeletonColor(0.604f, 0.804f, 0.196f, 1.0f);
|
||||
RPI::AuxGeomDraw::AuxGeomDynamicDrawArguments lineArgs;
|
||||
lineArgs.m_verts = m_auxVertices.data();
|
||||
lineArgs.m_vertCount = m_auxVertices.size();
|
||||
lineArgs.m_vertCount = static_cast<uint32_t>(m_auxVertices.size());
|
||||
lineArgs.m_colors = &skeletonColor;
|
||||
lineArgs.m_colorCount = 1;
|
||||
lineArgs.m_depthTest = RPI::AuxGeomDraw::DepthTest::Off;
|
||||
@@ -204,9 +204,9 @@ namespace AZ
|
||||
|
||||
RPI::AuxGeomDraw::AuxGeomDynamicDrawArguments lineArgs;
|
||||
lineArgs.m_verts = m_auxVertices.data();
|
||||
lineArgs.m_vertCount = m_auxVertices.size();
|
||||
lineArgs.m_vertCount = static_cast<uint32_t>(m_auxVertices.size());
|
||||
lineArgs.m_colors = m_auxColors.data();
|
||||
lineArgs.m_colorCount = m_auxColors.size();
|
||||
lineArgs.m_colorCount = static_cast<uint32_t>(m_auxColors.size());
|
||||
lineArgs.m_depthTest = RPI::AuxGeomDraw::DepthTest::Off;
|
||||
auxGeom->DrawLines(lineArgs);
|
||||
}
|
||||
@@ -786,7 +786,7 @@ namespace AZ
|
||||
|
||||
for (size_t lodIndex = 0; lodIndex < m_skinnedMeshInputBuffers->GetLodCount(); ++lodIndex)
|
||||
{
|
||||
EMotionFX::MorphSetup* morphSetup = actor->GetMorphSetup(lodIndex);
|
||||
EMotionFX::MorphSetup* morphSetup = actor->GetMorphSetup(static_cast<uint32>(lodIndex));
|
||||
if (morphSetup)
|
||||
{
|
||||
const AZStd::vector<AZ::RPI::MorphTargetMetaAsset::MorphTarget>& metaDatas = actor->GetMorphTargetMetaAsset()->GetMorphTargets();
|
||||
@@ -836,7 +836,7 @@ namespace AZ
|
||||
// Set the weights for any active masks
|
||||
for (size_t i = 0; i < m_wrinkleMaskWeights.size(); ++i)
|
||||
{
|
||||
wrinkleMaskObjectSrg->SetConstant(wrinkleMaskWeightsIndex, m_wrinkleMaskWeights[i], i);
|
||||
wrinkleMaskObjectSrg->SetConstant(wrinkleMaskWeightsIndex, m_wrinkleMaskWeights[i], static_cast<uint32_t>(i));
|
||||
}
|
||||
AZ_Error("AtomActorInstance", m_wrinkleMaskWeights.size() <= s_maxActiveWrinkleMasks, "The skinning shader supports no more than %d active morph targets with wrinkle masks.", s_maxActiveWrinkleMasks);
|
||||
}
|
||||
|
||||
@@ -230,7 +230,7 @@ namespace AZ
|
||||
void DebugConsole::BrowseInputHistory(ImGuiInputTextCallbackData* data)
|
||||
{
|
||||
const int previousHistoryIndex = m_currentHistoryIndex;
|
||||
const int maxHistoryIndex = m_textInputHistory.size() - 1;
|
||||
const int maxHistoryIndex = static_cast<int>(m_textInputHistory.size() - 1);
|
||||
switch (data->EventKey)
|
||||
{
|
||||
// Browse backwards through the history.
|
||||
|
||||
Reference in New Issue
Block a user