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
multimedia-overview.qdoc
Go to the documentation of this file.
1// Copyright (C) 2021 The Qt Company Ltd.
2// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR GFDL-1.3-no-invariants-only
3
4
5
6/*!
7\page multimediaoverview.html
8\title Multimedia Overview
9\brief A set of APIs for working with audio, video and camera devices.
10\ingroup explanations-graphicsandmultimedia
11
12Multimedia support in Qt is provided by the \l{Qt Multimedia} module. The Qt
13Multimedia module provides a rich feature set that enables you to easily take
14advantage of a platform's multimedia capabilities, such as media playback and
15the use of camera devices.
16
17\section1 Features
18
19Here are some things you can do with the Qt Multimedia APIs:
20
21\list
22\li Access raw audio devices for input and output.
23\li Play low latency sound effects.
24\li Play 3D spatial audio.
25\li Play media files in playlists (such as compressed audio or video files).
26\li Record audio and compress it.
27\li Use a camera, including viewfinder, image capture, and movie recording
28\li Decode audio media files into memory for processing.
29\endlist
30
31\section1 Multimedia Components
32
33The Qt Multimedia APIs are categorized into three main components. More
34information specific to each component is available in the overview pages. You
35can also take a look at some \l{Multimedia Recipes}{recipes}.
36
37\list
38\li \l {Audio Overview}
39\li \l {Video Overview}
40\li \l {Camera Overview}
41\li \l {Spatial Audio Overview} (Technology Preview)
42\endlist
43
44\section1 Multimedia Recipes
45
46For some quick recipes, see this table:
47
48\table 70%
49 \header
50 \li Use case
51 \li Examples
52 \li QML Types
53 \li C++ Classes
54 \row
55 \li Playing a sound effect
56 \li
57 \li \l{SoundEffect}
58 \li QSoundEffect
59 \row
60 \li Playing 3D sound
61 \li \l{Spatial Audio Panning Example}{audiopanning}
62 \li SpatialSound, AudioEngine
63 \li QSpatialSound, QAudioEngine
64 \row
65 \li Playing encoded audio (MP3, AAC etc)
66 \li \l{Media Player Example}{player}
67 \li \l{MediaPlayer}
68 \li QMediaPlayer
69 \row
70 \li Playing raw audio data with low latency
71 \li \l{Audio Output Example}{audiooutput}
72 \li
73 \li QAudioSink
74 \row
75 \li Accessing raw audio input data
76 \li \l{Spectrum Example}{spectrum},
77 \l{Audio Source Example}{audiosource}
78 \li
79 \li QAudioSource
80 \row
81 \li Recording encoded audio data
82 \li \l{Audio Recorder Example}{audiorecorder}
83 \li \l{CaptureSession}, \l{AudioInput}, \l{MediaRecorder}
84 \li QMediaCaptureSession, QAudioInput, QMediaRecorder
85 \row
86 \li Discovering audio and video devices
87 \li \l{Audio Devices Example}{audiodevices}
88 \li \l{MediaDevices}, \l{audioDevice}, \l{cameraDevice}
89 \li QMediaDevices, QAudioDevice, QCameraDevice
90 \row
91 \li Video Playback
92 \li \l{Media Player Example}{player},
93 \l{QML Media Player Example}{mediaplayer}
94 \li \l MediaPlayer, \l VideoOutput, \l Video
95 \li QMediaPlayer, QVideoWidget, QGraphicsVideoItem
96 \row
97 \li Capturing audio and video
98 \li \l {Camera Example}{camera},
99 \l {QML Video Recorder}{recorder}
100 \li \l CaptureSession, \l Camera, \l AudioInput \l VideoOutput
101 \li QMediaCaptureSession, QCamera, QAudioInput, QVideoWidget
102 \row
103 \li Capturing photos
104 \li \l {Camera Example}{camera},
105 \l {QML Video Recorder}{recorder}
106 \li \l CaptureSession, \l Camera, \l ImageCapture
107 \li QMediaCaptureSession, QCamera, QImageCapture
108 \row
109 \li Capturing movies
110 \li \l {Camera Example}{camera},
111 \l {QML Video Recorder}{recorder}
112 \li \l CaptureSession, \l Camera, \l MediaRecorder
113 \li QMediaCaptureSession, QCamera, QMediaRecorder
114\endtable
115
116\section1 Limitations
117
118The Qt Multimedia APIs build upon the multimedia framework of the underlying
119platform. This can mean that support for various codecs, or containers will vary
120between machines. This support depends on what the end user has installed.
121See \l{Supported Media Formats} for more detail.
122
123\note Qt Multimedia APIs depend on functionality provided by QCoreApplication,
124and multimedia objects created using the Qt Multimedia APIs can only be used
125during the lifetime of this application object. It is therefore important to
126create a QCoreApplication, QGuiApplication, or QApplication before accessing
127any of the Qt Multimedia APIs. If the application object is recreated, make
128sure that any Qt Multimedia objects are also recreated.
129
130\section1 Changes from Previous Versions
131
132If you previously used Qt Multimedia in Qt 5, see
133\l{Changes to Qt Multimedia} for more information on what has changed, and what
134you might need to change when porting code to Qt 6.
135
136\section1 Reference Documentation
137
138\list
139 \li \l{Qt Multimedia C++ Classes}{C++ Classes}
140 \li \l{Qt Multimedia QML Types}{QML Types}
141\endlist
142*/