summaryrefslogtreecommitdiffstats
path: root/examples/multimedia/declarative-camera/VideoPreview.qml
diff options
context:
space:
mode:
authorLars Knoll <lars.knoll@qt.io>2021-06-07 12:21:09 +0200
committerLars Knoll <lars.knoll@qt.io>2021-06-11 15:12:36 +0200
commitfc9cc90818a56b919ea1e50838bd13376b268bfe (patch)
treea18fb6dddd5e873d1e9fdf2bb944132070833a42 /examples/multimedia/declarative-camera/VideoPreview.qml
parent923a000261717ba6c898205bc4a5973b34bed2c5 (diff)
Use QAudioOutput in QMediaPlayer
Adjust QMediaPlayer to the new audio output architecture. One now needs to explicitly add a QAudioOutput to the media player to get audio playback. While this requires two more lines of code to set up the media player, it does make the API consistent between audio and video and also consistent with what we have in QMediaCaptureSession. Adjusted auto tests where required and ported all platforms. Change-Id: I247e915e4862dee6d6bce367b83664b1d1d69726 Reviewed-by: Volker Hilsheimer <volker.hilsheimer@qt.io>
Diffstat (limited to 'examples/multimedia/declarative-camera/VideoPreview.qml')
-rw-r--r--examples/multimedia/declarative-camera/VideoPreview.qml2
1 files changed, 2 insertions, 0 deletions
diff --git a/examples/multimedia/declarative-camera/VideoPreview.qml b/examples/multimedia/declarative-camera/VideoPreview.qml
index 5a2f90829..f47bfd009 100644
--- a/examples/multimedia/declarative-camera/VideoPreview.qml
+++ b/examples/multimedia/declarative-camera/VideoPreview.qml
@@ -67,6 +67,8 @@ Item {
}
videoOutput: output
+ audioOutput: AudioOutput {
+ }
}
VideoOutput {