diff options
author | Konstantin Ritt <ritt.ks@gmail.com> | 2015-03-16 04:13:32 +0400 |
---|---|---|
committer | Konstantin Ritt <ritt.ks@gmail.com> | 2015-03-16 11:06:14 +0000 |
commit | 137265904638da501a175f1332ec880d77bfd214 (patch) | |
tree | 91dcac9b73bdd9c0130f28365b1b0dbee7a40312 /src/render/io/gltfparser.cpp | |
parent | 5dc05523555c35d3ea043ed2405dcdf9e6b62ba4 (diff) |
[.*SceneParser] Minor clean-up
Change-Id: I171a3e44383f2f5160b24113de6d92725ed19fe9
Reviewed-by: Paul Lemire <paul.lemire@kdab.com>
Diffstat (limited to 'src/render/io/gltfparser.cpp')
-rw-r--r-- | src/render/io/gltfparser.cpp | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/src/render/io/gltfparser.cpp b/src/render/io/gltfparser.cpp index 570ceab77..d3848473e 100644 --- a/src/render/io/gltfparser.cpp +++ b/src/render/io/gltfparser.cpp @@ -309,13 +309,13 @@ void GLTFParser::setSource(const QUrl &source) * Returns true if the extension of \a path is supported by the * GLTF parser. */ -bool GLTFParser::isExtensionSupported(const QUrl &source) +bool GLTFParser::isExtensionSupported(const QUrl &source) const { const QString path = QUrlHelper::urlToLocalFileOrQrc(source); return GLTFParser::isGLTFPath(path); } -QMeshDataPtr GLTFParser::mesh(QString id) +QMeshDataPtr GLTFParser::mesh(const QString &id) { parse(); if (m_meshDict.contains(id)) @@ -336,7 +336,7 @@ QEntity* GLTFParser::defaultScene() return scene(m_defaultScene); } -QEntity* GLTFParser::scene(QString id) +QEntity* GLTFParser::scene(const QString &id) { parse(); @@ -359,7 +359,7 @@ QEntity* GLTFParser::scene(QString id) return sceneEntity; } -QEntity* GLTFParser::node(QString id) +QEntity* GLTFParser::node(const QString &id) { QJsonObject nodes = m_json.object().value(KEY_NODES).toObject(); if (!nodes.contains(id)) { @@ -460,7 +460,7 @@ QEntity* GLTFParser::node(QString id) #undef far #endif -QCameraLens* GLTFParser::camera(QString id) +QCameraLens* GLTFParser::camera(const QString &id) { parse(); QJsonObject cams = m_json.object().value(KEY_CAMERAS).toObject(); @@ -496,7 +496,7 @@ QCameraLens* GLTFParser::camera(QString id) } } -QMaterial* GLTFParser::material(QString id) +QMaterial* GLTFParser::material(const QString &id) { parse(); @@ -1048,7 +1048,7 @@ bool GLTFParserMesh::GLTFParserMeshFunctor::operator ==(const QAbstractMeshFunct return false; } -} // of namespace Qt3D +} // namespace Qt3D QT_END_NAMESPACE |