Skip to content

Commit 68831e6

Browse files
GLTF Loader/Builder: minor updates
1 parent 42660fe commit 68831e6

File tree

2 files changed

+6
-6
lines changed

2 files changed

+6
-6
lines changed

AssetLoader/interface/GLTFBuilder.hpp

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*
2-
* Copyright 2019-2024 Diligent Graphics LLC
2+
* Copyright 2019-2025 Diligent Graphics LLC
33
*
44
* Licensed under the Apache License, Version 2.0 (the "License");
55
* you may not use this file except in compliance with the License.
@@ -444,7 +444,7 @@ Mesh* ModelBuilder::LoadMesh(const GltfModelType& GltfModel,
444444
if (GltfPrimitive.GetIndicesId() >= 0)
445445
{
446446
IndexCount = ConvertIndexData(GltfModel, GltfPrimitive.GetIndicesId(), VertexStart);
447-
// For indexed primitives, the vertex offset is baked into the indices,
447+
// Vertex offset is baked into the indices
448448
VertexStart = 0;
449449
}
450450

@@ -462,8 +462,8 @@ Mesh* ModelBuilder::LoadMesh(const GltfModelType& GltfModel,
462462
NewMesh.Primitives.emplace_back(
463463
IndexStart,
464464
IndexCount,
465-
VertexCount,
466465
VertexStart,
466+
VertexCount,
467467
static_cast<Uint32>(MaterialId),
468468
PosMin,
469469
PosMax //

AssetLoader/interface/GLTFLoader.hpp

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -409,23 +409,23 @@ struct Primitive
409409
{
410410
const Uint32 FirstIndex;
411411
const Uint32 IndexCount;
412-
const Uint32 VertexCount;
413412
const Uint32 FirstVertex;
413+
const Uint32 VertexCount;
414414
const Uint32 MaterialId;
415415

416416
const BoundBox BB;
417417

418418
Primitive(Uint32 _FirstIndex,
419419
Uint32 _IndexCount,
420-
Uint32 _VertexCount,
421420
Uint32 _FirstVertex,
421+
Uint32 _VertexCount,
422422
Uint32 _MaterialId,
423423
const float3& _BBMin,
424424
const float3& _BBMax) :
425425
FirstIndex{_FirstIndex},
426426
IndexCount{_IndexCount},
427-
VertexCount{_VertexCount},
428427
FirstVertex{_FirstVertex},
428+
VertexCount{_VertexCount},
429429
MaterialId{_MaterialId},
430430
BB{_BBMin, _BBMax}
431431
{

0 commit comments

Comments
 (0)