Qt
Internal/Contributor docs for the Qt SDK. <b>Note:</b> These are NOT official API docs; those are found <a href='https://doc.qt.io/'>here</a>.
Loading...
Searching...
No Matches
qssgshadermapkey_p.h
Go to the documentation of this file.
1// Copyright (C) 2008-2012 NVIDIA Corporation.
2// Copyright (C) 2019 The Qt Company Ltd.
3// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR GPL-3.0-only
4
5#ifndef QSSGSHADERMAPKEY_P_H
6#define QSSGSHADERMAPKEY_P_H
7
8//
9// W A R N I N G
10// -------------
11//
12// This file is not part of the Qt API. It exists purely as an
13// implementation detail. This header file may change from version to
14// version without notice, or even be removed.
15//
16// We mean it.
17//
18
19#include <QtQuick3DRuntimeRender/private/qtquick3druntimerenderglobal_p.h>
20#include <QtQuick3DRuntimeRender/private/qssgrendershaderkeys_p.h>
21#include <QtQuick3DRuntimeRender/private/qssgrendershadercache_p.h>
22
47
49{
50 if (a.m_name != b.m_name)
51 return false;
52
53 const QSSGShaderDefaultMaterialKey *keyA = a.m_materialKeyOrig ? a.m_materialKeyOrig : &a.m_materialKeyCopy;
54 const QSSGShaderDefaultMaterialKey *keyB = b.m_materialKeyOrig ? b.m_materialKeyOrig : &b.m_materialKeyCopy;
55 if (!(*keyA == *keyB))
56 return false;
57
58 return (a.m_featuresOrig == b.m_featuresOrig);
59}
60
61inline size_t qHash(const QSSGShaderMapKey &key, size_t seed)
62{
63 return key.m_hashCode ^ seed;
64}
65
66#endif
\inmodule QtCore
Definition qbytearray.h:57
#define Q_DECL_NOTHROW
GLboolean GLboolean GLboolean b
GLuint64 key
GLboolean GLboolean GLboolean GLboolean a
[7]
static Q_CONSTINIT QBasicAtomicInteger< unsigned > seed
Definition qrandom.cpp:196
size_t qHash(const QSSGShaderMapKey &key, size_t seed)
bool operator==(const QSSGShaderMapKey &a, const QSSGShaderMapKey &b) Q_DECL_NOTHROW
QSSGShaderDefaultMaterialKey m_materialKeyCopy
const QSSGShaderFeatures m_featuresOrig
const QSSGShaderDefaultMaterialKey * m_materialKeyOrig
QSSGShaderMapKey(const QByteArray &inName, const QSSGShaderFeatures &inFeatures, const QSSGShaderDefaultMaterialKey &inMaterialKey)