1 | // Copyright (C) 2016 Klaralvdalens Datakonsult AB (KDAB). |
---|---|
2 | // SPDX-License-Identifier: LicenseRef-Qt-Commercial OR LGPL-3.0-only OR GPL-2.0-only OR GPL-3.0-only |
3 | |
4 | #include "techniquemanager_p.h" |
5 | #include <Qt3DCore/private/vector_helper_p.h> |
6 | |
7 | QT_BEGIN_NAMESPACE |
8 | |
9 | namespace Qt3DRender { |
10 | |
11 | namespace Render { |
12 | |
13 | TechniqueManager::TechniqueManager() |
14 | { |
15 | } |
16 | |
17 | // AspectThread |
18 | void TechniqueManager::addDirtyTechnique(Qt3DCore::QNodeId techniqueId) |
19 | { |
20 | if (!Qt3DCore::contains(destination: m_dirtyTechniques, element: techniqueId)) |
21 | m_dirtyTechniques.push_back(x: techniqueId); |
22 | } |
23 | |
24 | // AspectThread |
25 | std::vector<Qt3DCore::QNodeId> TechniqueManager::takeDirtyTechniques() |
26 | { |
27 | return Qt3DCore::moveAndClear(data&: m_dirtyTechniques); |
28 | } |
29 | |
30 | } // Render |
31 | } // Qt3DRender |
32 | |
33 | QT_END_NAMESPACE |
34 |