summaryrefslogtreecommitdiffstats
path: root/src/multimediaquick/mediaplayer.qdoc
diff options
context:
space:
mode:
Diffstat (limited to 'src/multimediaquick/mediaplayer.qdoc')
-rw-r--r--src/multimediaquick/mediaplayer.qdoc691
1 files changed, 0 insertions, 691 deletions
diff --git a/src/multimediaquick/mediaplayer.qdoc b/src/multimediaquick/mediaplayer.qdoc
deleted file mode 100644
index d25089ee8..000000000
--- a/src/multimediaquick/mediaplayer.qdoc
+++ /dev/null
@@ -1,691 +0,0 @@
-/****************************************************************************
-**
-** Copyright (C) 2021 The Qt Company Ltd.
-** Contact: https://www.qt.io/licensing/
-**
-** This file is part of the Qt Toolkit.
-**
-** $QT_BEGIN_LICENSE:LGPL$
-** Commercial License Usage
-** Licensees holding valid commercial Qt licenses may use this file in
-** accordance with the commercial license agreement provided with the
-** Software or, alternatively, in accordance with the terms contained in
-** a written agreement between you and The Qt Company. For licensing terms
-** and conditions see https://www.qt.io/terms-conditions. For further
-** information use the contact form at https://www.qt.io/contact-us.
-**
-** GNU Lesser General Public License Usage
-** Alternatively, this file may be used under the terms of the GNU Lesser
-** General Public License version 3 as published by the Free Software
-** Foundation and appearing in the file LICENSE.LGPL3 included in the
-** packaging of this file. Please review the following information to
-** ensure the GNU Lesser General Public License version 3 requirements
-** will be met: https://www.gnu.org/licenses/lgpl-3.0.html.
-**
-** GNU General Public License Usage
-** Alternatively, this file may be used under the terms of the GNU
-** General Public License version 2.0 or (at your option) the GNU General
-** Public license version 3 or any later version approved by the KDE Free
-** Qt Foundation. The licenses are as published by the Free Software
-** Foundation and appearing in the file LICENSE.GPL2 and LICENSE.GPL3
-** included in the packaging of this file. Please review the following
-** information to ensure the GNU General Public License requirements will
-** be met: https://www.gnu.org/licenses/gpl-2.0.html and
-** https://www.gnu.org/licenses/gpl-3.0.html.
-**
-** $QT_END_LICENSE$
-**
-****************************************************************************/
-
-/*!
- \qmltype MediaPlayer
- \instantiates QMediaPlayer
- \brief Add media playback to a scene.
-
- \inqmlmodule QtMultimedia
- \ingroup multimedia_qml
- \ingroup multimedia_audio_qml
- \ingroup multimedia_video_qml
-
- \qml
- Text {
- text: "Click Me!";
- font.pointSize: 24;
- width: 150; height: 50;
-
- MediaPlayer {
- id: playMusic
- source: "music.wav"
- }
- MouseArea {
- id: playArea
- anchors.fill: parent
- onPressed: { playMusic.play() }
- }
- }
- \endqml
-
- You can use MediaPlayer by itself to play audio content, or you can use it
- in conjunction with a Multimedia::VideoOutput for rendering video.
-
- \qml
- Item {
- MediaPlayer {
- id: mediaplayer
- source: "groovy_video.mp4"
- }
-
- VideoOutput {
- anchors.fill: parent
- source: mediaplayer
- }
-
- MouseArea {
- id: playArea
- anchors.fill: parent
- onPressed: mediaplayer.play();
- }
- }
- \endqml
-
- \sa VideoOutput
-*/
-
-/*!
- \since 5.15
- \qmlproperty QObject* QtMultimedia::MediaPlayer::videoOutput
-
- This property holds the target video output.
- Accepts one VideoOutput elements.
-
- \snippet multimedia-snippets/multiple-videooutputs.qml
-
- \sa QMediaPlayer::setVideoOutput()
-*/
-
-/*!
- \qmlproperty QAudioOutput* QtMultimedia::MediaPlayer::audioOutput
-
- This property holds the target audio output.
- Accepts one AudioOutput elements.
-
-
- \sa QMediaPlayer::setAudioOutput()
-*/
-
-/*!
- \qmlproperty enumeration QtMultimedia::MediaPlayer::availability
-
- Returns the media player's state, which can be one of the following:
-
- \table
- \header \li State value \li Description
- \row \li Available
- \li The media player is available to use.
- \row \li Busy
- \li The media player is usually available, but some other
- process is utilizing the hardware necessary to play media.
- \row \li Unavailable
- \li There are no supported media playback facilities.
- \row \li ResourceMissing
- \li There is one or more resources missing, so the media player cannot
- be used. It may be possible to try again at a later time.
- \endtable
- */
-
-/*!
- \qmlproperty enumeration QtMultimedia::MediaPlayer::audioRole
-
- This property holds the role of the audio stream. It can be set to specify
- the type of audio being played, allowing the system to make appropriate
- decisions when it comes to volume, routing or post-processing.
-
- The audio role must be set before setting the source property.
-
- Supported values can be retrieved with supportedAudioRoles().
-
- The value for an audio role can be one of the following:
- \table
- \header \li Role \li Description
- \row \li UnknownRole
- \li The role is unknown or undefined.
- \row \li MusicRole
- \li For music.
- \row \li VideoRole
- \li Soundtrack from a movie or a video.
- \row \li VoiceCommunicationRole
- \li Voice communications, such as telephony.
- \row \li AlarmRole
- \li Alarms or timers.
- \row \li NotificationRole
- \li Notification, such as an incoming e-mail or a chat request.
- \row \li RingtoneRole
- \li For ringtones.
- \row \li AccessibilityRole
- \li For accessibility, such as a screen reader.
- \row \li SonificationRole
- \li \l{Sonification}, such as with user interface sounds.
- \row \li GameRole
- \li For game audio.
- \endtable
-
- \since 5.6
-*/
-
-/*!
- \qmlmethod list<int> QtMultimedia::MediaPlayer::supportedAudioRoles()
-
- Returns a list of supported audio roles.
-
- If setting the audio role is not supported, an empty list is returned.
-
- \since 5.6
- \sa audioRole
-*/
-
-/*!
- \qmlmethod QtMultimedia::MediaPlayer::play()
-
- Starts playback of the media.
-
- Sets the \l playbackState property to PlayingState.
-*/
-
-/*!
- \qmlmethod QtMultimedia::MediaPlayer::pause()
-
- Pauses playback of the media.
-
- Sets the \l playbackState property to PausedState.
-*/
-
-/*!
- \qmlmethod QtMultimedia::MediaPlayer::stop()
-
- Stops playback of the media.
-
- Sets the \l playbackState property to StoppedState.
-*/
-
-/*!
- \qmlproperty url QtMultimedia::MediaPlayer::source
-
- This property holds the source URL of the media.
-
- Since Qt 5.12.2, the url scheme \c gst-pipeline provides custom pipelines
- for the GStreamer backend.
-
- If the pipeline contains a \c qtvideosink element,
- the current VideoOutput will be used for rendering video.
-
- \snippet multimedia-snippets/qtvideosink.qml complete
-
- \sa QMediaPlayer::setMedia()
-*/
-
-/*!
- \qmlproperty int QtMultimedia::MediaPlayer::loops
-
- This property holds the number of times the media is played. A value of
- \c 0 or \c 1 means the media will be played only once.
- Set the property to \c MediaPlayer.Infinite to enable infinite looping.
-
- The value can be changed while the media is playing, in which case it will
- update the remaining loops to the new value.
-
- The default property value is \c{1}.
-*/
-
-/*!
- \qmlproperty bool QtMultimedia::MediaPlayer::autoLoad
-
- This property controls if loading of media should begin immediately.
-
- Defaults to \b{true}.
-
- If set to \c{false}, the media will not be loaded until playback is started.
-
- The value of autoLoad will be overwritten to true, if \l autoPlay is set
- to \b{true}.
-*/
-
-/*!
- \qmlsignal QtMultimedia::MediaPlayer::playbackStateChanged()
-
- This signal is emitted when the \l playbackState property is altered.
-*/
-
-/*!
- \qmlproperty enumeration QtMultimedia::MediaPlayer::status
-
- This property holds the status of media loading. It can be one of the
- following:
-
- \table
- \header
- \li Property value
- \li Description
- \row \li NoMedia
- \li No media has been set.
- \row \li Loading
- \li The media is currently being loaded.
- \row \li Loaded
- \li The media has been loaded.
- \row \li Buffering
- \li The media is buffering data.
- \row \li Stalled
- \li Playback has been interrupted while the media is buffering data.
- \row \li Buffered
- \li The media has buffered data.
- \row \li EndOfMedia
- \li The media has played to the end.
- \row \li InvalidMedia
- \li The media cannot be played.
- \row \li UnknownStatus
- \li The status of the media is unknown.
- \endtable
-*/
-
-/*!
- \qmlproperty enumeration QtMultimedia::MediaPlayer::playbackState
-
- This property holds the state of media playback.It can be one of the
- following:
-
- \table
- \header \li Property value
- \li Description
- \row \li PlayingState
- \li The media is currently playing.
- \row \li PausedState
- \li Playback of the media has been suspended.
- \row \li StoppedState
- \li Playback of the media is yet to begin.
- \endtable
-*/
-
-/*!
- \qmlproperty bool QtMultimedia::MediaPlayer::autoPlay
-
- This property controls whether the media will begin to play on start up.
-
- The property defaults to \c{false}.
-
- If autoPlay is set to \c{true}, the value of \l{autoLoad} will be overwritten
- to true.
-*/
-
-/*!
- \qmlproperty int QtMultimedia::MediaPlayer::duration
-
- This property holds the duration of the media in milliseconds.
-
- If the media doesn't have a fixed duration (a live stream for example) this
- will be set to \c{0}.
-*/
-
-/*!
- \qmlproperty int QtMultimedia::MediaPlayer::position
-
- This property holds the current playback position in milliseconds.
-
- If the \l seekable property is true, this property can be set to
- milliseconds.
-
- Setting the position may be asynchronous, so this may not be updated
- immediately.
-*/
-
-/*!
- \qmlproperty real QtMultimedia::MediaPlayer::volume
-
- This property holds the audio volume of the media player.
-
- The volume is scaled linearly from \c 0.0 (silence) to \c 1.0 (full volume).
- Values outside this range will be clamped: a value lower than 0.0 is set to
- 0.0, a value higher than 1.0 will set to 1.0.
-
- The default volume is \c{1.0}.
-
- UI \l{volume controls} should usually be scaled non-linearly. For example,
- using a logarithmic scale will produce linear changes in perceived \l{loudness},
- which is what a user would normally expect from a volume control.
-
- See \l {QAudio::convertVolume()}{QtMultimedia.convertVolume()}
- for more details.
-*/
-
-/*!
- \qmlproperty bool QtMultimedia::MediaPlayer::muted
-
- This property holds whether the audio output is muted.
-
- Defaults to \c{false}.
-*/
-
-/*!
- \qmlproperty bool QtMultimedia::MediaPlayer::hasAudio
-
- This property holds whether the media contains audio.
-*/
-
-/*!
- \qmlproperty bool QtMultimedia::MediaPlayer::hasVideo
-
- This property holds whether the media contains video.
-*/
-
-/*!
- \qmlproperty real QtMultimedia::MediaPlayer::bufferProgress
-
- This property holds how much of the data buffer is currently filled,
- from \c 0.0 (empty) to \c 1.0 (full).
-
- Playback can start or resume only when the buffer is entirely filled.
- When the buffer is filled, \c MediaPlayer.Buffered is true.
- When buffer progress is between \c 0.0 and \c 0.1, \c MediaPlayer.Buffering
- is set to \c{true}.
-
- A value lower than \c 1.0 implies that the property \c MediaPlayer.Stalled
- is \c{true}.
-
- \sa status
-*/
-
-/*!
- \qmlproperty bool QtMultimedia::MediaPlayer::seekable
-
- This property holds whether position of the audio can be changed.
-
- If true, calling the \l setPosition() method will cause playback to seek to the new
- position.
-*/
-
-/*!
- \qmlproperty real QtMultimedia::MediaPlayer::playbackRate
-
- This property holds the rate at which audio is played at as a multiple of
- the normal rate.
-
- Defaults to \c{1.0}.
-*/
-
-/*!
- \qmlproperty enumeration QtMultimedia::MediaPlayer::error
-
- This property holds the error state of the audio. It can be one of the
- following.
-
- \table
- \header \li Value \li Description
- \row \li NoError
- \li There is no current error.
- \row \li ResourceError
- \li The audio cannot be played due to a problem allocating resources.
- \row \li FormatError
- \li The audio format is not supported.
- \row \li NetworkError
- \li The audio cannot be played due to network issues.
- \row \li AccessDenied
- \li The audio cannot be played due to insufficient permissions.
- \row \li ServiceMissing
- \li The audio cannot be played because the media service could not be
- instantiated.
- \endtable
-*/
-
-/*!
- \qmlproperty string QtMultimedia::MediaPlayer::errorString
-
- This property holds a string describing the current error condition in more
- detail.
-*/
-
-/*!
- \qmlsignal QtMultimedia::MediaPlayer::errorOccurred(error, errorString)
-
- This signal is emitted when an \a error has occurred. The \a errorString
- parameter may contain more detailed information about the error.
-
- \sa QMediaPlayer::Error
-*/
-
-/*!
- \qmlproperty variant QtMultimedia::MediaPlayer::mediaSource
-
- This property holds the native media object.
-
- It can be used to get a pointer to the QMediaPlayer object in order to
- integrate with C++ code.
-
- \code
- QObject *qmlMediaPlayer; // The QML MediaPlayer object
- QMediaPlayer *player = qvariant_cast<QMediaPlayer *>(qmlMediaPlayer->property("mediaSource"));
- \endcode
-
- \note This property is not accessible from QML.
-*/
-
-/*!
- \since 6.2
- \qmlproperty int QtMultimedia::MediaPlayer::activeAudioTrack
-
- This property holds the track number of the currently active audio track.
- Set to \c{-1} to disable audio track.
-
- The default property value is \c{0}: the first audio track.
-*/
-
-/*!
- \since 6.2
- \qmlproperty int QtMultimedia::MediaPlayer::activeVideoTrack
-
- This property holds the track number of the currently active video audio track.
- Set to \c{-1} to disable video track.
-
- The default property value is \c{0}: the first video track.
-*/
-
-/*!
- \since 6.2
- \qmlproperty int QtMultimedia::MediaPlayer::activeSubtitleTrack
-
- This property holds the track number of the currently active subtitle track.
- Set to \c{-1} to disable subtitle track.
-
- The default property value is \c{-1}: no subtitles active.
-*/
-
-/*!
- \since 6.2
- \qmlproperty QList<QMediaMetaData> QtMultimedia::MediaPlayer::audioTracks
-
- This property holds a list of metadata.
- Each index refers to a audio track.
-
- The metadata holds 2 properties;
- \list
- \li \l{QtMultimedia::MediaPlayer::metaData.language}{Language}
- \li \l{QtMultimedia::MediaPlayer::metaData.mediaType}{MimeType}
- \endlist
-
- \sa {MetaData}
-*/
-
-/*!
- \since 6.2
- \qmlproperty QList<QMediaMetaData> QtMultimedia::MediaPlayer::videoTracks
-
- This property holds a list of metadata.
- Each index refers to a video track.
-
- The metadata holds 2 properties;
- \list
- \li \l{QtMultimedia::MediaPlayer::metaData.language}{Language}
- \li \l{QtMultimedia::MediaPlayer::metaData.mediaType}{MimeType}
- \endlist
-
- \sa {MetaData}
-*/
-
-/*!
- \since 6.2
- \qmlproperty QList<QMediaMetaData> QtMultimedia::MediaPlayer::subtitleTracks
-
- This property holds a list of metadata.
- Each index refers to a subtitle track.
-
- The metadata holds 2 properties;
- \list
- \li \l{QtMultimedia::MediaPlayer::metaData.language}{Language}
- \li \l{QtMultimedia::MediaPlayer::metaData.mediaType}{MimeType}
- \endlist
-
- \sa {MetaData}
-*/
-
-/*!
- \qmlpropertygroup QtMultimedia::MediaPlayer::metaData
- \qmlproperty variant QtMultimedia::MediaPlayer::metaData.title
- \qmlproperty variant QtMultimedia::MediaPlayer::metaData.subTitle
- \qmlproperty variant QtMultimedia::MediaPlayer::metaData.author
- \qmlproperty variant QtMultimedia::MediaPlayer::metaData.comment
- \qmlproperty variant QtMultimedia::MediaPlayer::metaData.description
- \qmlproperty variant QtMultimedia::MediaPlayer::metaData.category
- \qmlproperty variant QtMultimedia::MediaPlayer::metaData.genre
- \qmlproperty variant QtMultimedia::MediaPlayer::metaData.year
- \qmlproperty variant QtMultimedia::MediaPlayer::metaData.date
- \qmlproperty variant QtMultimedia::MediaPlayer::metaData.userRating
- \qmlproperty variant QtMultimedia::MediaPlayer::metaData.keywords
- \qmlproperty variant QtMultimedia::MediaPlayer::metaData.language
- \qmlproperty variant QtMultimedia::MediaPlayer::metaData.publisher
- \qmlproperty variant QtMultimedia::MediaPlayer::metaData.copyright
- \qmlproperty variant QtMultimedia::MediaPlayer::metaData.parentalRating
- \qmlproperty variant QtMultimedia::MediaPlayer::metaData.ratingOrganization
- \qmlproperty variant QtMultimedia::MediaPlayer::metaData.size
- \qmlproperty variant QtMultimedia::MediaPlayer::metaData.mediaType
- \qmlproperty variant QtMultimedia::MediaPlayer::metaData.audioBitRate
- \qmlproperty variant QtMultimedia::MediaPlayer::metaData.audioCodec
- \qmlproperty variant QtMultimedia::MediaPlayer::metaData.averageLevel
- \qmlproperty variant QtMultimedia::MediaPlayer::metaData.channelCount
- \qmlproperty variant QtMultimedia::MediaPlayer::metaData.peakValue
- \qmlproperty variant QtMultimedia::MediaPlayer::metaData.sampleRate
- \qmlproperty variant QtMultimedia::MediaPlayer::metaData.albumTitle
- \qmlproperty variant QtMultimedia::MediaPlayer::metaData.albumArtist
- \qmlproperty variant QtMultimedia::MediaPlayer::metaData.contributingArtist
- \qmlproperty variant QtMultimedia::MediaPlayer::metaData.composer
- \qmlproperty variant QtMultimedia::MediaPlayer::metaData.conductor
- \qmlproperty variant QtMultimedia::MediaPlayer::metaData.lyrics
- \qmlproperty variant QtMultimedia::MediaPlayer::metaData.mood
- \qmlproperty variant QtMultimedia::MediaPlayer::metaData.trackNumber
- \qmlproperty variant QtMultimedia::MediaPlayer::metaData.trackCount
- \qmlproperty variant QtMultimedia::MediaPlayer::metaData.coverArtUrlSmall
- \qmlproperty variant QtMultimedia::MediaPlayer::metaData.coverArtUrlLarge
- \qmlproperty variant QtMultimedia::MediaPlayer::metaData.resolution
- \qmlproperty variant QtMultimedia::MediaPlayer::metaData.videoFrameRate
- \qmlproperty variant QtMultimedia::MediaPlayer::metaData.videoBitRate
- \qmlproperty variant QtMultimedia::MediaPlayer::metaData.videoCodec
- \qmlproperty variant QtMultimedia::MediaPlayer::metaData.posterUrl
- \qmlproperty variant QtMultimedia::MediaPlayer::metaData.chapterNumber
- \qmlproperty variant QtMultimedia::MediaPlayer::metaData.director
- \qmlproperty variant QtMultimedia::MediaPlayer::metaData.leadPerformer
- \qmlproperty variant QtMultimedia::MediaPlayer::metaData.writer
-
- These properties hold the meta data for the current media.
-
- \table
- \header \li Property name
- \li Description
- \row \li \c metaData.title
- \li The title of the media.
- \row \li \c metaData.subTitle
- \li The sub-title of the media.
- \row \li \c metaData.author
- \li The author of the media.
- \row \li \c metaData.comment
- \li A user comment about the media.
- \row \li \c metaData.description
- \li A description of the media.
- \row \li \c metaData.category
- \li The category of the media.
- \row \li \c metaData.genre
- \li The genre of the media.
- \row \li \c metaData.year
- \li The year of release of the media.
- \row \li \c metaData.date
- \li The date of the media.
- \row \li \c metaData.userRating
- \li A user rating of the media in the range of 0 to 100.
- \row \li \c metaData.keywords
- \li A list of keywords describing the media.
- \row \li \c metaData.language
- \li The language of the media, as an \l{ISO 639-2 code}.
- \row \li \c metaData.publisher
- \li The publisher of the media.
- \row \li \c metaData.copyright
- \li The media's copyright notice.
- \row \li \c metaData.parentalRating
- \li The parental rating of the media.
- \row \li \c metaData.ratingOrganization
- \li The name of the rating organization responsible for the parental rating
- of the media.
- \row \li \c metaData.size
- \li The size of the media in bytes.
- \row \li \c metaData.mediaType
- \li The type of the media.
- \row \li \c metaData.audioBitRate
- \li The bit rate of the media's audio stream in bits per second.
- \row \li \c metaData.audioCodec
- \li The encoding of the media audio stream.
- \row \li \c metaData.averageLevel
- \li The average volume level of the media.
- \row \li \c metaData.channelCount
- \li The number of channels in the media's audio stream.
- \row \li \c metaData.peakValue
- \li The peak volume of media's audio stream.
- \row \li \c metaData.sampleRate
- \li The sample rate of the media's audio stream in hertz.
- \row \li \c metaData.albumTitle
- \li The title of the album the media belongs to.
- \row \li \c metaData.albumArtist
- \li The name of the principal artist of the album the media belongs to.
- \row \li \c metaData.contributingArtist
- \li The names of artists contributing to the media.
- \row \li \c metaData.composer
- \li The composer of the media.
- \row \li \c metaData.conductor
- \li The conductor of the media.
- \row \li \c metaData.lyrics
- \li The lyrics to the media.
- \row \li \c metaData.mood
- \li The mood of the media.
- \row \li \c metaData.trackNumber
- \li The track number of the media.
- \row \li \c metaData.trackCount
- \li The number of tracks on the album containing the media.
- \row \li \c metaData.coverArtUrlSmall
- \li The URL of a small cover art image.
- \row \li \c metaData.coverArtUrlLarge
- \li The URL of a large cover art image.
- \row \li \c metaData.resolution
- \li The dimension of an image or video.
- \row \li \c metaData.videoFrameRate
- \li The frame rate of the media's video stream.
- \row \li \c metaData.videoBitRate
- \li The bit rate of the media's video stream in bits per second.
- \row \li \c metaData.videoCodec
- \li The encoding of the media's video stream.
- \row \li \c metaData.posterUrl
- \li The URL of a poster image.
- \row \li \c metaData.chapterNumber
- \li The chapter number of the media.
- \row \li \c metaData.director
- \li The director of the media.
- \row \li \c metaData.leadPerformer
- \li The lead performer in the media.
- \row \li \c metaData.writer
- \li The writer of the media.
- \endtable
-
- \sa {QMediaMetaData}
-*/