summaryrefslogtreecommitdiffstats
path: root/src/render/io/gltfparser.cpp
diff options
context:
space:
mode:
authorPaul Lemire <paul.lemire@kdab.com>2014-10-20 08:59:46 +0200
committerPaul Lemire <paul.lemire@kdab.com>2014-10-22 10:45:27 +0200
commit62f9d57d8e4e9dc77f3eceb9f9c8413998143ca5 (patch)
tree0a893df288bbabb0d0f59b5cb238d9302cbd1e50 /src/render/io/gltfparser.cpp
parent5d31b5f774475f87a00447c4eac6eb96e9651675 (diff)
QMeshData: enum for primitives
Each value in the enums maps directly to the correct GLint for a given primitive patch. This allows to still return an int to be used directly by the renderer. This should also fix compilation error of ES2. Change-Id: I7ec54dcb2cbb02b67fa6225bb80fb7e691687e2c Reviewed-by: Sean Harmer <sean.harmer@kdab.com>
Diffstat (limited to 'src/render/io/gltfparser.cpp')
-rw-r--r--src/render/io/gltfparser.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/render/io/gltfparser.cpp b/src/render/io/gltfparser.cpp
index f41a5ed23..649482412 100644
--- a/src/render/io/gltfparser.cpp
+++ b/src/render/io/gltfparser.cpp
@@ -700,7 +700,7 @@ void GLTFParser::processJSONMesh( QString id, QJsonObject jsonObj )
continue;
}
- QMeshDataPtr md( new QMeshData( type ) );
+ QMeshDataPtr md( new QMeshData( static_cast<QMeshData::PrimitiveTypes>(type) ) );
m_meshMaterialDict[md.data()] = material;
QJsonObject attrs = primObj.value(KEY_ATTRIBUTES).toObject();