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
qquick3dambientsound_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 LGPL-3.0-only OR GPL-3.0-only
3
#
ifndef
QQUICK3DAMBIENTSOUND_H
4
#
define
QQUICK3DAMBIENTSOUND_H
5
6
//
7
// W A R N I N G
8
// -------------
9
//
10
// This file is not part of the Qt API. It exists purely as an
11
// implementation detail. This header file may change from version to
12
// version without notice, or even be removed.
13
//
14
// We mean it.
15
//
16
17
#
include
<
QtQuick3D
/
private
/
qquick3dnode_p
.
h
>
18
#
include
<
QtCore
/
qurl
.
h
>
19
#
include
<
QtGui
/
qvector3d
.
h
>
20
21
QT_BEGIN_NAMESPACE
22
23
class
QAmbientSound;
24
25
class
QQuick3DAmbientSound
:
public
QObject
26
{
27
Q_OBJECT
28
Q_PROPERTY(QUrl source READ source WRITE setSource NOTIFY sourceChanged)
29
Q_PROPERTY
(
float
volume
READ
volume
WRITE
setVolume
NOTIFY
volumeChanged
)
30
Q_PROPERTY
(
int
loops
READ
loops
WRITE
setLoops
NOTIFY
loopsChanged
)
31
Q_PROPERTY
(
bool
autoPlay
READ
autoPlay
WRITE
setAutoPlay
NOTIFY
autoPlayChanged
)
32
QML_NAMED_ELEMENT
(
AmbientSound
)
33
34
public
:
35
QQuick3DAmbientSound
();
36
~
QQuick3DAmbientSound
()
override
;
37
38
void
setSource
(
const
QUrl &source);
39
QUrl
source
()
const
;
40
41
void
setVolume
(
float
volume);
42
float
volume
()
const
;
43
44
enum
Loops
45
{
46
Infinite
= -1,
47
Once
= 1
48
};
49
Q_ENUM
(
Loops
)
50
51
int
loops
()
const
;
52
void
setLoops
(
int
loops);
53
54
bool
autoPlay
()
const
;
55
void
setAutoPlay
(
bool
autoPlay);
56
57
public
Q_SLOTS
:
58
void
play
();
59
void
pause
();
60
void
stop
();
61
62
Q_SIGNALS
:
63
void
sourceChanged
();
64
void
volumeChanged
();
65
void
loopsChanged
();
66
void
autoPlayChanged
();
67
68
private
:
69
QAmbientSound *m_sound =
nullptr
;
70
};
71
72
QT_END_NAMESPACE
73
74
#
endif
QQuick3DAmbientSound
Definition
qquick3dambientsound_p.h:26
QQuick3DAmbientSound::autoPlayChanged
void autoPlayChanged()
QQuick3DAmbientSound::setAutoPlay
void setAutoPlay(bool autoPlay)
Definition
qquick3dambientsound.cpp:107
QQuick3DAmbientSound::setLoops
void setLoops(int loops)
Definition
qquick3dambientsound.cpp:89
QQuick3DAmbientSound::setSource
void setSource(const QUrl &source)
Definition
qquick3dambientsound.cpp:56
QQuick3DAmbientSound::pause
void pause()
\qmlmethod void AmbientSound::pause()
Definition
qquick3dambientsound.cpp:127
QQuick3DAmbientSound::loops
int loops() const
\qmlproperty int AmbientSound::loops
Definition
qquick3dambientsound.cpp:84
QQuick3DAmbientSound::loopsChanged
void loopsChanged()
QQuick3DAmbientSound::stop
void stop()
\qmlmethod void AmbientSound::stop()
Definition
qquick3dambientsound.cpp:138
QQuick3DAmbientSound::~QQuick3DAmbientSound
~QQuick3DAmbientSound() override
Definition
qquick3dambientsound.cpp:41
QQuick3DAmbientSound::autoPlay
bool autoPlay() const
\qmlproperty bool AmbientSound::autoPlay
Definition
qquick3dambientsound.cpp:102
QQuick3DAmbientSound::Loops
Loops
Definition
qquick3dambientsound_p.h:45
QQuick3DAmbientSound::Infinite
@ Infinite
Definition
qquick3dambientsound_p.h:46
QQuick3DAmbientSound::Once
@ Once
Definition
qquick3dambientsound_p.h:47
QQuick3DAmbientSound::source
QUrl source() const
\qmlproperty url AmbientSound::source
Definition
qquick3dambientsound.cpp:51
QQuick3DAmbientSound::setVolume
void setVolume(float volume)
\qmlproperty real AmbientSound::volume
Definition
qquick3dambientsound.cpp:66
QQuick3DAmbientSound::volumeChanged
void volumeChanged()
QQuick3DAmbientSound::volume
float volume() const
Definition
qquick3dambientsound.cpp:71
QT_BEGIN_NAMESPACE
Combined button and popup list for selecting options.
Definition
qsequentialanimationgroup.cpp:47
qtmultimedia
src
spatialaudioquick3d
qquick3dambientsound_p.h
Generated on
for Qt by
1.18.0