summaryrefslogtreecommitdiffstats
path: root/src/multimedia/playback/qmediaplayer.cpp
Commit message (Collapse)AuthorAgeFilesLines
* Fix build for -no-feature-temporaryfileStephan Binner2017-05-081-0/+4
| | | | | | | | | If a backend does not support streaming then playing from qrc is impossible for -no-feature-temporaryfile case. Change-Id: Ibb0518c4afe0598c6f3a1c03b75cc00e76b8eead Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@qt.io> Reviewed-by: Christian Stromme <christian.stromme@qt.io>
* Merge remote-tracking branch 'origin/5.7' into 5.8Liang Qi2016-11-111-10/+10
|\ | | | | | | | | | | | | | | | | | | Conflicts: qtmultimedia.pro src/multimedia/playback/qmediaplayer.cpp src/plugins/directshow/directshow.pro tests/auto/integration/qmediaplayerbackend/BLACKLIST Change-Id: I6dacdcbb223c1d12dd72eb308a67170983c709b3
| * Merge remote-tracking branch 'origin/5.6' into 5.7Liang Qi2016-11-041-10/+10
| |\ | | | | | | | | | Change-Id: Ib038c5e3ebb48c0e46569a35d530fa5ceaf06a32
| | * Reduce size of QMediaPlayerPrivateChristian Stromme2016-10-191-10/+10
| | | | | | | | | | | | | | | | | | | | | | | | Rearranged the data members to reduce the object size (-16 bytes on 64 bit systems). Change-Id: I0f285fafc42633fff42eba1ddc68c6f9bee2cec8 Reviewed-by: Yoann Lopes <yoann.lopes@qt.io>
* | | Merge remote-tracking branch 'origin/5.7' into 5.8Yoann Lopes2016-10-111-2/+2
|\| | | | | | | | | | | Change-Id: I8cfa9cb233675bb7ff842118d96ec8ac0b97964f
| * | Merge remote-tracking branch 'origin/5.6' into 5.7Liang Qi2016-10-041-2/+2
| |\| | | | | | | | | | | | | | | | | | | Conflicts: tests/auto/integration/qaudiooutput/tst_qaudiooutput.cpp Change-Id: I4a30fc030c25e7b8da3eb9f386c4a5fa468df141
| | * Doc: Add comment about stream requirementsChristian Strømme2016-09-281-2/+2
| | | | | | | | | | | | | | | Change-Id: I92e16722dc5cc8df23cf4ed0d048a0d2a23956eb Reviewed-by: Yoann Lopes <yoann.lopes@qt.io>
* | | Improve audio volume documentationYoann Lopes2016-08-221-2/+8
| | | | | | | | | | | | | | | | | | | | | | | | Added information about volume scales. Change-Id: Ica8367396147e3e1c814b3575faa5cf0503be031 Reviewed-by: Venugopal Shivashankar <Venugopal.Shivashankar@qt.io> Reviewed-by: Christian Stromme <christian.stromme@qt.io>
* | | Merge remote-tracking branch 'origin/5.7' into devLiang Qi2016-08-171-7/+9
|\| | | | | | | | | | | Change-Id: Ib8d05d6e21c7beb19f618cd1edc52d248b1e43b8
| * | Merge remote-tracking branch 'origin/5.6' into 5.7Liang Qi2016-08-131-7/+9
| |\| | | | | | | | | | Change-Id: I3204cdf695f4b47730a88a7c41fc7a6de967b161
| | * Fix playing a playlist containing an invalid media as first itemYoann Lopes2016-08-121-7/+9
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | When a playlist contains an invalid media, QMediaPlayer normally continues to the next media. If an invalid media was first in the list, the backend would never go into PlayingState, which would then cause the media player to never start the next item in the list (thinking it's stopped). We now always transition to PlayingState when starting playback of a playlist, regardless of the backend going into that state or not. Change-Id: I4227f937e7a619afbd8adbe2fccedfa5d43ad89a Reviewed-by: Christian Stromme <christian.stromme@qt.io>
* | | Pass by QUrl by const-ref, it's non-trivial.Sergio Martins2016-03-021-2/+2
|/ / | | | | | | | | | | | | [-Wclazy-function-args-by-ref] Change-Id: Iac68ca2d3d53951190db6d24ebbbcb60e8bbd789 Reviewed-by: David Faure <david.faure@kdab.com>
* / Updated license headersAntti Kokko2016-01-191-14/+20
|/ | | | | | | | | | | From Qt 5.7 -> LGPL v2.1 isn't an option anymore, see http://blog.qt.io/blog/2016/01/13/new-agreement-with-the-kde-free-qt-foundation/ Updated license headers to use new LGPL header instead of LGPL21 one (in those files which will be under LGPL v3) Change-Id: I324f65c61171f36641472964d095d72e452afb3a Reviewed-by: Jani Heikkinen <jani.heikkinen@theqtcompany.com> Reviewed-by: Lars Knoll <lars.knoll@theqtcompany.com>
* Merge remote-tracking branch 'origin/5.5' into 5.6Yoann Lopes2015-08-241-0/+4
|\ | | | | | | | | | | | | Conflicts: src/imports/multimedia/qdeclarativeaudio.cpp Change-Id: I57c6252b084e4ed796f6f308b2e0c717d0f59b13
| * QMediaPlayer: clear current playlist on deletion.Yoann Lopes2015-08-191-0/+2
| | | | | | | | | | | | | | | | | | | | Makes sure the current playlist is unbound when QMediaPlayer is destroyed. Change-Id: If25efa67bf79af0326f6125d9615165a2c7dd6bb Reviewed-by: Jim Hodapp <jim.hodapp@canonical.com> Reviewed-by: Loïc Molinari <loic.molinari@canonical.com> Reviewed-by: Christian Stromme <christian.stromme@theqtcompany.com>
| * Bind the playlist connected to a player.Loïc Molinari2015-08-121-0/+2
| | | | | | | | | | Change-Id: I3c2e00773c88f671bdffcfe8c8175330ca405d4a Reviewed-by: Yoann Lopes <yoann.lopes@theqtcompany.com>
* | Add audio role API to QMediaPlayer.Jim Hodapp2015-08-101-0/+67
|/ | | | | | Change-Id: Ia5e3e2fe714f10b6aad62f0a4801c607905c7e0d Task-number: QTBUG-41054 Reviewed-by: Yoann Lopes <yoann.lopes@theqtcompany.com>
* Fix tr()-context of message in QMediaPlayerPrivate.Friedemann Kleint2015-04-091-1/+1
| | | | | | | QObject::tr() should be avoided. Change-Id: I583ff7f6fec664030f5637fe216dfd44c1b1f2ac Reviewed-by: Yoann Lopes <yoann.lopes@theqtcompany.com>
* QMediaPlayer: handle resource files in a cross-platform way.Yoann Lopes2015-04-071-32/+125
| | | | | | | | | | | | | | | | | | | | It was the backend's responsibility to handle resource files in an appropriate way. In practice, it was either not handled at all, or implemented in an almost identical manner in every backend that does handle it. This is now dealt with in QMediaPlayer, always passing to the backend something it will be able to play. If the backend has the StreamPlayback capability, we pass a QFile from which it streams the data. If it doesn't, we copy the resource to a temporary file and pass its path to the backend. Task-number: QTBUG-36175 Task-number: QTBUG-42263 Task-number: QTBUG-43839 Change-Id: I57b355c72692d02661baeaf74e66581ca0a0bd1d Reviewed-by: Andrew Knight <qt@panimo.net> Reviewed-by: Peng Wu <peng.wu@intopalo.com> Reviewed-by: Christian Stromme <christian.stromme@theqtcompany.com>
* Merge remote-tracking branch 'origin/5.4' into devFrederik Gladhorn2015-02-131-1/+1
|\ | | | | | | Change-Id: I5575a4ba13212c9bfe73a3de3ef17c6528beafc3
| * Fix some typosSergio Ahumada2015-02-111-1/+1
| | | | | | | | | | Change-Id: Iaf8f50741d3103480668b4a654a202d8a363bc45 Reviewed-by: Yoann Lopes <yoann.lopes@theqtcompany.com>
* | Update copyright headersAntti Kokko2015-02-121-7/+7
|/ | | | | | | | | Qt copyrights are now in The Qt Company, so we could update the source code headers accordingly. In the same go we should also fix the links to point to qt.io. Change-Id: I1c6faa4f59f8eca54f01ef20941fa60161dd7872 Reviewed-by: Yoann Lopes <yoann.lopes@theqtcompany.com>
* Update license headers and add new license filesAntti Kokko2014-08-241-19/+11
| | | | | | | | | - Renamed LICENSE.LGPL to LICENSE.LGPLv21 - Added LICENSE.LGPLv3 & LICENSE.GPLv2 - Removed LICENSE.GPL Change-Id: Ied06887225df341064c12bcc14c259ae74116f2e Reviewed-by: Jani Heikkinen <jani.heikkinen@digia.com>
* Use Q_CONSTRUCTOR_FUNCTION macro to register multimedia meta types.Yoann Lopes2014-05-301-11/+7
| | | | | | Task-number: QTBUG-39131 Change-Id: I2493c9e3e6f0065d0441a74ff240d7d91fbe059c Reviewed-by: Christian Stromme <christian.stromme@digia.com>
* Improve documentation for the QMediaPlayer::bufferStatus property.Yoann Lopes2014-05-151-3/+5
| | | | | | | | The corresponding properties in the Audio and MediaPlayer QML elements are also updated. Change-Id: I7104d274d431e7712db2f045c375756e8c2ac03a Reviewed-by: Jerome Pasion <jerome.pasion@digia.com>
* Doc: Document asynchronous nature of QMediaPlayer::setMedia()Sze Howe Koh2013-11-231-0/+5
| | | | | | | | | | | | The function name can be interpreted to mean that it loads the media. Users have made this mistake before: http://comments.gmane.org/gmane.comp.lib.qt.user/9189 https://bugreports.qt-project.org/browse/QTBUG-28514 Change-Id: I9e9b36405d67d40db42b77d8eeb8f9d528ee16e2 Reviewed-by: Jerome Pasion <jerome.pasion@digia.com> Reviewed-by: Yoann Lopes <yoann.lopes@digia.com>
* Fix typo in QMediaPlayer docs.Mitch Curtis2013-05-311-1/+1
| | | | | Change-Id: I0b9110488a2d116cea73abe30f80fc1f487029aa Reviewed-by: Jerome Pasion <jerome.pasion@digia.com>
* Doc: Fixed random QDoc warningsVenugopal Shivashankar2013-01-151-2/+2
| | | | | | | | | | | | | - Fixed \snippet paths - Minor language edits - Removed unnecessary multiple page commands in a single comment block. For example, \fn and \qmlsignal in a single comment block is not allowed. Such instances must be documented in separate comment blocks. Change-Id: I65f4518499e2600c4e1807356d4116c575e48c19 Reviewed-by: Andy Nichols <andy.nichols@digia.com> Reviewed-by: Jerome Pasion <jerome.pasion@digia.com>
* Update copyright year in Digia's license headersSergio Ahumada2013-01-101-1/+1
| | | | | | Change-Id: Ia8c1c38aba1544603fada8c414cc856f365fd15b Reviewed-by: Akseli Salovaara <akseli.salovaara@digia.com> Reviewed-by: Sergio Ahumada <sergio.ahumada@digia.com>
* Rename namespace QtMultimedia -> QMultimediaSze Howe Koh2012-11-061-3/+3
| | | | | | | | | | | | | | | | Main code, examples, tests and docs updated. Method: 1. Mass find+replace "QtMultimedia::" -> "QMultimedia::" 2. Hand-modified declaration in qtmedianamespace.h/cpp For consistency (with minimal disruption), namespaces with a "Qt" prefix will be renamed. Part of the Header Consistency Project (http://lists.qt-project.org/pipermail/development/2012-October/007570.html) Change-Id: I1fbc43a1aa91d996aa61869fcd8d05186bf7cf6d Reviewed-by: Lars Knoll <lars.knoll@digia.com> Reviewed-by: Stephen Kelly <stephen.kelly@kdab.com>
* Rename namespace QtMultimedia::MetaData -> QMediaMetaDataSze Howe Koh2012-11-061-1/+1
| | | | | | | | | | | | | | | | | | Main code, examples, tests and docs updated. Method: 1. Remove unused forward-declarations, "class QMediaMetaData" 2. Mass find+replace "QtMultimedia::MetaData" -> "QMediaMetaData" 3. Un-nest from the QtMultimedia namespace in qtmedianamespace.h For consistency (with minimal disruption), namespaces with a "Qt" prefix will be renamed. Also, Qt guidelines don't include nested namespaces (http://lists.qt-project.org/pipermail/development/2012-October/006756.html) Part of the Header Consistency Project (http://lists.qt-project.org/pipermail/development/2012-October/007570.html) Change-Id: I40e59c1cf58c1792725e735e9285c51bc5f226b1 Reviewed-by: Lars Knoll <lars.knoll@digia.com> Reviewed-by: Stephen Kelly <stephen.kelly@kdab.com>
* Change copyrights from Nokia to DigiaIikka Eklund2012-09-241-24/+24
| | | | | | | | | Change copyrights and license headers from Nokia to Digia Change-Id: Id77334cfb15de096941c88e32d04ca07b4eb4709 Reviewed-by: Janne Anttila <janne.anttila@digia.com> Reviewed-by: Sergio Ahumada <sergio.ahumada@digia.com> Reviewed-by: Lars Knoll <lars.knoll@digia.com>
* Rename availabilityError to availability.Michael Goddard2012-06-291-4/+4
| | | | | | | It's perhaps clearer in the usual case. Change-Id: Id3cef82ac83f8c9b538b3315281664ce1c6a2b96 Reviewed-by: Ling Hu <ling.hu@nokia.com>
* A number of documentation fixes.Michael Goddard2012-06-071-1/+1
| | | | | | | | | | | | | | * Remove references to private QMediaServiceProvider class and point new backend writers to irc/mailing lists * Wrong or missing parameter names * Fix a few links * Correct a few property data types * Various other things to keep qdoc happier Change-Id: I5c8800d65c00f0783541afef35990bd3918acab7 Reviewed-by: Angus Cummings <angus.cummings@nokia.com> Reviewed-by: Ling Hu <ling.hu@nokia.com> Reviewed-by: Daniel Kovacic <daniel.kovacic@nokia.com>
* Clarify the metadata functionality of QMediaPlayer.Michael Goddard2012-06-071-2/+10
| | | | | | | | | | | By linking to QMediaObject functions. Also clean that up a bit so it's a bit more useful for people looking for higher level functionality. Change-Id: Ie452122c4d55f88326a7b71c5882dfe38f489791 Reviewed-by: Angus Cummings <angus.cummings@nokia.com> Reviewed-by: Ling Hu <ling.hu@nokia.com> Reviewed-by: Dmytro Poplavskiy <dmytro.poplavskiy@nokia.com> Reviewed-by: Daniel Kovacic <daniel.kovacic@nokia.com>
* Very minor C++ doc changesAngus Cummings2012-05-161-2/+2
| | | | | | | | | Reordering some enum's so values are listed ascending Replace 'The' with 'the' in some briefs Change-Id: Ibc5042389687598ddaaf11e72acaa688b85fd4cf Reviewed-by: Dmytro Poplavskiy <dmytro.poplavskiy@nokia.com> Reviewed-by: Ling Hu <ling.hu@nokia.com>
* QtMultimedia: Fix compiler warnings.Friedemann Kleint2012-04-241-2/+0
| | | | | Change-Id: Ic0edfa95c03103550d22bfdf88c33fdbd6f41e3c Reviewed-by: Friedemann Kleint <Friedemann.Kleint@nokia.com>
* QMediaPlaylist: Added ability to load from provided QNetworkRequest.Lev Zelenskiy2012-03-211-1/+1
| | | | | Change-Id: I7d8fc8a432810ff87650808b9ca6af53f7356d4e Reviewed-by: Dmytro Poplavskiy <dmytro.poplavskiy@nokia.com>
* QMediaPlayer frontend: changes to playlist support.Lev Zelenskiy2012-03-211-81/+322
| | | | | | | | | Allow to load playlists using setMedia(). Use QNetworkMediaPlaylistProvider for playlist parsing. Updated unit tests. Change-Id: If4dba07be8b2e8a9e9549d5bed58e552dfb958b7 Reviewed-by: Dmytro Poplavskiy <dmytro.poplavskiy@nokia.com>
* Don't request renderer control if null surface is set as video output.Dmytro Poplavskiy2012-03-121-1/+8
| | | | | | | | | | | | | QCamera and QMediaPlayer are likely to wait for valid surface to be passed to the renderer control before startup, so after player->setVideoOutput(nullSurface) player will not start playback. If the renderer control was already requested before for valid surface it should be released when the null surface is assigned. Change-Id: I3f78f2d82e61fae5f305874874c0ffbc4cb7dc1d Reviewed-by: Jonas Rabbe <jonas.rabbe@nokia.com>
* Move most of playlist API to private.Lev Zelenskiy2012-03-061-2/+2
| | | | | | | Moved objects either not needed to be public or require API review/redesign. Change-Id: Ibeb8b8c9c9a74bea32191c119fa4daaffde57c17 Reviewed-by: Dmytro Poplavskiy <dmytro.poplavskiy@nokia.com>
* Expose availability from the backend to C++ and QML.Michael Goddard2012-03-021-0/+11
| | | | | | | | | | | | | | The availabilityError property was static based on the service, but it can change at run time, so add the plumbing to allow the backend to report it itself. Also make sure that both QML and C++ expose the availability. The radio tuner and data controls previously had properties (but no signals) for availability - these have been removed. Change-Id: I9240cf93e2a51b14cd38642f9312ae3c75f05361 Reviewed-by: Ling Hu <ling.hu@nokia.com>
* Moved QMediaServiceProvider to private header.Dmytro Poplavskiy2012-02-061-1/+1
| | | | | | | It's not intended to be used by applications. Change-Id: I2acc26180ebb5c2419438169827f39aaf4578389 Reviewed-by: Michael Goddard <michael.goddard@nokia.com>
* QMediaPlayer::setPosition: do not check isSeekable and do not bound by durationLev Zelenskiy2012-02-061-2/+2
| | | | | | | | | | | To allow setPosition to be called in stopped state we no longer check if the player is in seekable state and allow position to be greater than duration. Unit test has been updated accordingly. Change-Id: I29447ffe797a7cc3dcc80d20b2527e9eda493ab6 Reviewed-by: Michael Goddard <michael.goddard@nokia.com> Reviewed-by: Dmytro Poplavskiy <dmytro.poplavskiy@nokia.com>
* Remove "All rights reserved" line from license headers.Jason McDonald2012-01-301-1/+1
| | | | | | | | | | As in the past, to avoid rewriting various autotests that contain line-number information, an extra blank line has been inserted at the end of the license text to ensure that this commit does not change the total number of lines in the license header. Change-Id: I20e5215108c6ebd5f8474fed5c3665118e4791e6 Reviewed-by: Rohan McGovern <rohan.mcgovern@nokia.com>
* Fix some static analysis defects.Michael Goddard2012-01-251-0/+1
| | | | | | | | | A few silly errors, a few unlikely errors, a few changes that should not have resulted in a problem but makes the code clearer. Change-Id: Id2c82e9317d53822e4da13c94dec9595ea33b07a Reviewed-by: Ling Hu <ling.hu@nokia.com> Reviewed-by: Dmytro Poplavskiy <dmytro.poplavskiy@nokia.com>
* Removed QMediaServiceProvider parameter from media objects constructors.Dmytro Poplavskiy2012-01-241-10/+8
| | | | | | | | | | | | | QMediaServiceProvider should be removed from the public API, to provide media objects with a custom media service. A protected QMediaPlayer/QCamera/QRadioTuner/etc constructor with QMediaService* parameter is a cleaner and more flexible solution. Change-Id: I335cce4bbebe0e548c3df338f206e7be7c93c3dd Reviewed-by: Michael Goddard <michael.goddard@nokia.com> Reviewed-by: Jonas Rabbe <jonas.rabbe@nokia.com>
* Update obsolete contact address.Jason McDonald2012-01-231-1/+1
| | | | | | | Replace Nokia contact email address with Qt Project website. Change-Id: Ie8cd560b6d9a2c6e552b6be1ad8bc96c80a6535c Reviewed-by: Rohan McGovern <rohan.mcgovern@nokia.com>
* Fix up a few doc issuesMichael Goddard2012-01-171-2/+1
| | | | | | | | | | | | | * lingering references to Mobility * missing group tags on some classes meant they went missing * put classes into functional groups as well (e.g. audio, camera) * added some of the qdoc files to OTHER_FILES so they show up in Creator There are still a lot of warnings since it seems like qdoc is not processing the controls directory. Change-Id: I036f8826ae63f8273b3e649cb32c091d964ce830 Reviewed-by: Jonas Rabbe <jonas.rabbe@nokia.com>
* Remove antiquated \since lines in docs.Michael Goddard2012-01-161-45/+0
| | | | | | | They aren't useful in the case of QtMultimedia{Kit} Change-Id: If1b0b6625763c85907fb05beb9c440046472ddef Reviewed-by: Jonas Rabbe <jonas.rabbe@nokia.com>