Qt
Internal/Contributor docs for the Qt SDK. Note: These are NOT official API docs; those are found at https://doc.qt.io/
Toggle main menu visibility
Loading...
Searching...
No Matches
qtquick3dassetutilsglobal_p.h
Go to the documentation of this file.
1
// Copyright (C) 2021 The Qt Company Ltd.
2
// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR GPL-3.0-only
3
// Qt-Security score:significant reason:default
4
5
6
#
ifndef
QTQUICK3DASSETUTILSGLOBAL_P_H
7
#
define
QTQUICK3DASSETUTILSGLOBAL_P_H
8
9
//
10
// W A R N I N G
11
// -------------
12
//
13
// This file is not part of the Qt API. It exists purely as an
14
// implementation detail. This header file may change from version to
15
// version without notice, or even be removed.
16
//
17
// We mean it.
18
//
19
20
#
include
<
QtCore
/
qglobal
.
h
>
21
#
include
<
QtCore
/
qstring
.
h
>
22
#
include
<
QtCore
/
qhash
.
h
>
23
#
include
<
QtQuick3DAssetUtils
/
qtquick3dassetutilsexports
.
h
>
24
#
include
<
QtQuick3DRuntimeRender
/
private
/
qssgrendergraphobject_p
.
h
>
25
26
QT_BEGIN_NAMESPACE
27
28
void
Q_QUICK3DASSETUTILS_EXPORT qml_register_types_QtQuick3D_AssetUtils();
29
30
class
QQuick3DObject;
31
32
// Key used by QSSRtObjectMap for runtime object lookup.
33
//
34
// Only 'name' participates in operator== and qHash, so QMultiHash buckets
35
// are partitioned by name. The 'path' field is intentionally excluded from
36
// hash/equality to enable a two-phase lookup: first retrieve all entries
37
// with a matching name via equal_range(), then filter by 'path' manually.
38
// Do NOT add 'path' to operator== or qHash — that would break the path-based
39
// lookup in QQuick3DRuntimeLoader::query().
40
class
QSSGRuntimeObjectNameKey
41
{
42
public
:
43
QString
name
;
44
QString
path
;
45
46
friend
bool
operator
==(
const
QSSGRuntimeObjectNameKey
&lhs,
const
QSSGRuntimeObjectNameKey
&rhs)
noexcept
47
{
48
return
lhs.name == rhs.name;
49
}
50
51
friend
size_t
qHash
(
const
QSSGRuntimeObjectNameKey
&key, size_t seed = 0)
noexcept
52
{
53
return
qHash(key.name, seed);
54
}
55
56
};
57
58
using
QSSGRuntimeObjectTypeKey = QSSGRenderGraphObject::BaseType;
59
60
using
QSSGRuntimeObjectNameMap = QMultiHash<QSSGRuntimeObjectNameKey, QPointer<QQuick3DObject>>;
61
using
QSSGRuntimeObjectTypeMap = QMultiHash<QSSGRuntimeObjectTypeKey, QPointer<QQuick3DObject>>;
62
63
QT_END_NAMESPACE
64
65
#
endif
// QTQUICK3DASSETUTILSGLOBAL_P_H
QQuick3DRuntimeLoader
Definition
qquick3druntimeloader_p.h:35
QSSGRuntimeObjectNameKey
Definition
qtquick3dassetutilsglobal_p.h:41
QSSGRuntimeObjectNameKey::path
QString path
Definition
qtquick3dassetutilsglobal_p.h:44
QSSGRuntimeObjectNameKey::operator==
friend bool operator==(const QSSGRuntimeObjectNameKey &lhs, const QSSGRuntimeObjectNameKey &rhs) noexcept
Definition
qtquick3dassetutilsglobal_p.h:46
QSSGRuntimeObjectNameKey::name
QString name
Definition
qtquick3dassetutilsglobal_p.h:43
QSSGRuntimeObjectNameKey::qHash
friend size_t qHash(const QSSGRuntimeObjectNameKey &key, size_t seed=0) noexcept
Definition
qtquick3dassetutilsglobal_p.h:51
QT_BEGIN_NAMESPACE
Combined button and popup list for selecting options.
Definition
qsequentialanimationgroup.cpp:47
boxBoundsRecursive
static void boxBoundsRecursive(const QQuick3DNode *baseNode, const QQuick3DNode *node, QQuick3DBounds3 &accBounds)
Definition
qquick3druntimeloader.cpp:194
applyToModels
static void applyToModels(QQuick3DObject *obj, Func &&lambda)
Definition
qquick3druntimeloader.cpp:215
queryFilterToBaseType
static QSSGRenderGraphObject::BaseType queryFilterToBaseType(QQuick3DRuntimeLoader::QueryFilter filter)
Definition
qquick3druntimeloader.cpp:502
qtquick3d
src
assetutils
qtquick3dassetutilsglobal_p.h
Generated on
for Qt by
1.18.0