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
qquick3dparticlerepeller_p.h
Go to the documentation of this file.
1
// Copyright (C) 2022 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
QQUICK3DPARTICLEREPELLER_H
7
#
define
QQUICK3DPARTICLEREPELLER_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
<
QtQuick3DParticles
/
private
/
qquick3dparticleaffector_p
.
h
>
21
22
QT_BEGIN_NAMESPACE
23
24
class
Q_QUICK3DPARTICLES_EXPORT
QQuick3DParticleRepeller
:
public
QQuick3DParticleAffector
25
{
26
Q_OBJECT
27
Q_PROPERTY(
float
radius READ radius WRITE setRadius NOTIFY radiusChanged)
28
Q_PROPERTY(
float
outerRadius READ outerRadius WRITE setOuterRadius NOTIFY outerRadiusChanged)
29
Q_PROPERTY(
float
strength READ strength WRITE setStrength NOTIFY strengthChanged)
30
QML_NAMED_ELEMENT(Repeller3D)
31
QML_ADDED_IN_VERSION(6, 4)
32
public
:
33
QQuick3DParticleRepeller(QQuick3DNode *parent =
nullptr
);
34
35
float
radius()
const
;
36
float
outerRadius()
const
;
37
float
strength()
const
;
38
39
public
Q_SLOTS:
40
void
setRadius(
float
radius);
41
void
setOuterRadius(
float
radius);
42
void
setStrength(
float
strength);
43
44
Q_SIGNALS:
45
void
radiusChanged();
46
void
outerRadiusChanged();
47
void
strengthChanged();
48
49
protected
:
50
void
prepareToAffect() override;
51
void
affectParticle(
const
QQuick3DParticleData &sd, QQuick3DParticleDataCurrent *d,
float
time) override;
52
53
private
:
54
float
m_radius = 0.0f;
55
float
m_outerRadius = 50.0f;
56
float
m_strength = 50.0f;
57
};
58
59
QT_END_NAMESPACE
60
61
#
endif
QQuick3DParticleRepeller
Definition
qquick3dparticlerepeller_p.h:25
QT_BEGIN_NAMESPACE
Combined button and popup list for selecting options.
Definition
qsequentialanimationgroup.cpp:47
qt_smoothstep
static float qt_smoothstep(float edge0, float edge1, float x)
Definition
qquick3dparticlerepeller.cpp:91
qtquick3d
src
quick3dparticles
qquick3dparticlerepeller_p.h
Generated on
for Qt by
1.18.0