summaryrefslogtreecommitdiffstats
Commit message (Collapse)AuthorAgeFilesLines
* Android: Release the surface texture when not in useChristian Strømme2014-04-121-2/+8
| | | | | | | | | | | With some Android versions the preview texture is released when the application is suspended. If we don't release the texture in our code, the preview will be empty when the application resumes. Task-number: QTBUG-38165 Change-Id: I72244727081d8f94ee5f6cb0ab660ca59f4bb2de Reviewed-by: Yoann Lopes <yoann.lopes@digia.com>
* Android: Use Q_GLOBAL_STATIC instead of a static QMapChristian Strømme2014-04-091-5/+6
| | | | | Change-Id: I7b65e0874051c4ef504914a0bd66e8471ec34fa7 Reviewed-by: Yoann Lopes <yoann.lopes@digia.com>
* Android: Fix the signature for setOnInfoListener.Christian Strømme2014-04-091-1/+1
| | | | | | | | The argument part of the signature should be OnInfoListener and not OnErrorListener. Change-Id: I735fe1b0338b66c2f729254ed9e3251136781cbe Reviewed-by: Yoann Lopes <yoann.lopes@digia.com>
* Fix some MediaPlayer properties returning wrong values.Yoann Lopes2014-04-092-23/+23
| | | | | | | | Once the QML component is complete, don't cache any value anymore and always ask the backend for the actual value. Change-Id: I2c3ad55618e0532f713cfcc8258a70a1114fc975 Reviewed-by: Christian Stromme <christian.stromme@digia.com>
* WMF: improve changing playback rate on a media player.Yoann Lopes2014-04-092-6/+48
| | | | | | | | | | | | | | | | | | | | | | When going back to normal rate after playing in fast forward (greater than 2x), playback seemed frozen for some amount of time (up to 8 seconds). When playing in fast forward, only key frames are shown, ignoring all the others. When returning to a normal rate, the source reader will usually be pointing to a key frame in the future compared to the player clock position, meaning that all the frames in between won't be shown until the player clock catches up with the latest key frame that was read. When leaving fast-forward, we now reset the position on the player to force the source reader to point back to the frame at the current clock position and avoid the seamingly frozen playback. Also, emit playbackRateChanged() signal when changing the playback rate. Change-Id: I4f04f0f250083378e94fb4a47f9f917abeaaf24e Reviewed-by: Christian Stromme <christian.stromme@digia.com>
* GStreamer: correctly get metadata from live sources.Yoann Lopes2014-04-092-23/+11
| | | | | | | | | | For some unknown reason, "iradio-mode" was set to false on the source element, which was preventing new metadata to be received when playing live streams. Task-number: QTBUG-37640 Change-Id: Ib90297e81e26a99c3dfc753bdcd5cbd1ee2f6764 Reviewed-by: Christian Stromme <christian.stromme@digia.com>
* WMF: more reliable video seeking.Yoann Lopes2014-04-081-10/+15
| | | | | | | | | | When seeking, the presentation clock can enter an undefined state until it is started again from the new position. Wait for the clock to be restarted before scheduling the prerolled frames, otherwise these frames might get a wrong presentation time. Change-Id: I02cb3338239775b7ef5d206ec5aa1b26719ac978 Reviewed-by: Christian Stromme <christian.stromme@digia.com>
* Android: Fix QtMediaRecorderChristian Strømme2014-04-083-12/+17
| | | | | | | | | | Don't extend the MediaRecorder class as this causes ART to fail when it doesn't find the postEventFromNative() function. Task-number: QTBUG-38166 Change-Id: Ia38ce4558a2cc95a9b4cd05b9f926d41e53fdc0d Reviewed-by: Yoann Lopes <yoann.lopes@digia.com>
* Android: Use androidSdkVersion() to get the API level.Christian Strømme2014-04-081-31/+39
| | | | | Change-Id: Idc0b09ab2dc5d93e8da8dab3bd0e99e27fbc57e1 Reviewed-by: Yoann Lopes <yoann.lopes@digia.com>
* Android: Remove inheritance to QJNIObject in the Camera wrapperChristian Strømme2014-04-081-22/+25
| | | | | | | The QJNIObject was never intended to be used as a base class. Change-Id: I4986aeaebecd6e4136fed311e69368e20da4d060 Reviewed-by: Yoann Lopes <yoann.lopes@digia.com>
* Android: Fix MediaRecorder wrapperChristian Strømme2014-04-082-24/+25
| | | | | | | The QJNIObject was never intended to be used as a base class. Change-Id: I8311f909a37aeae6040eba4471b379cfc732297b Reviewed-by: Yoann Lopes <yoann.lopes@digia.com>
* WMF: don't return undefined value in Release() function.Yoann Lopes2014-04-081-1/+1
| | | | | | | | The function was returning a member variable after the object was deleted. Return a local copy instead. Change-Id: I077e7e1c184ed0cfd4899a80c9147a2939c93cd7 Reviewed-by: Christian Stromme <christian.stromme@digia.com>
* WMF: support playback rate in our custom video sink.Yoann Lopes2014-04-081-15/+99
| | | | | Change-Id: Ic8fde3398813df68d2f77b2542f1fa507c8ea674 Reviewed-by: Christian Stromme <christian.stromme@digia.com>
* QNX: Fix MediaPlayer states handlingFabian Bumberger2014-04-071-3/+4
| | | | | | | | Task-number: QTBUG-37753 Change-Id: I61ff490f061dedd8a9bdc22d76969d9afb9a6795 Reviewed-by: Bernd Weimer <bweimer@blackberry.com> Reviewed-by: Yoann Lopes <yoann.lopes@digia.com> Reviewed-by: Rafael Roquetto <rafael.roquetto@kdab.com>
* Tell glib not to complain about the use of API recently deprecatedThiago Macieira2014-04-071-0/+1
| | | | | | | | | | | | | | | | | When building with glib 2.32 or later, without this #define, it prints a warning saying: function "g_value_get_char" was declared deprecated ("Use 'g_value_get_schar' instead") Since g_value_get_schar is new in 2.32, we can't use it without #ifdef around the call point. Since the old and new functions are identical in behavior, just ask glib not to complain about the use of old functions. I don't know which is the minimum version of glib we require, so I went for the lowest available macro. Change-Id: I33f9aa8497fc6bd50fffb3c59ee7e8e7fcdfe110 Reviewed-by: Yoann Lopes <yoann.lopes@digia.com>
* let videonode plugins declare that they extend QtQuickOswald Buddenhagen2014-04-072-0/+2
| | | | | Change-Id: I4facc9ca0616927f7b1101cecb989fece38c2f7a Reviewed-by: Yoann Lopes <yoann.lopes@digia.com>
* make MODULE_PLUGIN_TYPES assignment actually have an effectOswald Buddenhagen2014-04-071-5/+6
| | | | | | | it must be done before load()ing qt_plugin.prf. Change-Id: I0ad31f8d9761b2d059d656c9e4f674c8a7cc88a6 Reviewed-by: Yoann Lopes <yoann.lopes@digia.com>
* DirectShow: fix media seeking while stopped.Yoann Lopes2014-04-072-0/+14
| | | | | | | | | | When changing the position of a media player while stopped, playback was automatically resuming. We now cache the value and actually set the position only when starting playback. Task-number: QTBUG-38068 Change-Id: Ib35302e01967d70350125f9ad920551df2a3c25b Reviewed-by: Christian Stromme <christian.stromme@digia.com>
* GStreamer: cleanup system includes.Yoann Lopes2014-04-079-89/+12
| | | | | | | | | | | | Replaced some linux includes with <private/qcore_unix_p.h> to be more portable. Use qt_safe_open() and qt_safe_close() instead of ::open() and ::close(). Task-number: QTBUG-38061 Change-Id: Idb3f50d070ec1701cafba98e79e2e85824653a3a Reviewed-by: Lisandro Damián Nicanor Pérez Meyer <perezmeyer@gmail.com> Reviewed-by: Christian Stromme <christian.stromme@digia.com>
* Add support for running on big-endian systemsDmitry Shachnev2014-04-033-8/+16
| | | | | | | | Now qtmultimedia test suite passes on powerpc. Change-Id: I540dff93195115ad1dc5725af7293e3b8540403f Reviewed-by: Thiago Macieira <thiago.macieira@intel.com> Reviewed-by: Yoann Lopes <yoann.lopes@digia.com>
* GStreamer: each QMediaPlayer now has its own volume by default.Yoann Lopes2014-04-032-13/+49
| | | | | | | | | | | | | | | | | | | | | | | | We were using the volume property of GStreamer's playbin element to set the volume. This could behave differently depending on the system configuration; it could affect the system volume or the media player own audio stream. We now use a 'volume' element to do software attenuation on the audio data sent to the audio sink, it allows each QMediaPlayer to always have its own volume. To preserve the previous behavior, developers can set the QT_GSTREAMER_USE_PLAYBIN_VOLUME environment variable to true. [ChangeLog][QtMultimedia][GStreamer] QMediaPlayer::setVolume() doesn't change the system volume anymore (it could be the case before depending on the system configuration). Set the QT_GSTREAMER_USE_PLAYBIN_VOLUME environment variable to true to restore that behavior. Task-number: QTBUG-30317 Task-number: QTBUG-36511 Change-Id: Ia0249962a74ac21fb110fcb634c08706f8d5767a Reviewed-by: Wouter Huysentruit <wouter_huysentruit@hotmail.com> Reviewed-by: Christian Stromme <christian.stromme@digia.com>
* Fix unit testsBernd Weimer2014-04-022-5/+4
| | | | | | | | | | Random playback mode is not good for testing index changed signal, because the same media might be played successively. Calling show() might result in showFullScreen() on some platforms, which is not expected by some video widget tests. Change-Id: Ib47433fc6411b6dfa244a245aae508df5627ec62 Reviewed-by: Yoann Lopes <yoann.lopes@digia.com>
* BlackBerry: Fix the rotation of the viewfinderFabian Bumberger2014-04-023-4/+27
| | | | | | | | | | | | This fixes the rotation of the viewfinder. We have to adjust the orientation depending on the primary screen orientation. On a keyboard device, the viewfinder would not rotate at all (same if auto orientation is turned off). Task-number: QTBUG-37894 Change-Id: I2bf955fb3303ed236d3234154ded94fe78607455 Reviewed-by: Yoann Lopes <yoann.lopes@digia.com> Reviewed-by: Bernd Weimer <bweimer@blackberry.com> Reviewed-by: Rafael Roquetto <rafael.roquetto@kdab.com>
* Fix memory leak in SampleGrabberCallbackLiang Jian2014-04-021-0/+3
| | | | | | | | | Add virtual destructor to SampleGrabberCallback to let it properly destruct its subclass when calling 'detete this' Change-Id: I5f74f82314e22225a0a153c7f4bca531a79dd8f9 Reviewed-by: Friedemann Kleint <Friedemann.Kleint@digia.com> Reviewed-by: Yoann Lopes <yoann.lopes@digia.com>
* Fix SourceResolver::State object leakLiang Jian2014-04-011-1/+1
| | | | | | | | Initialize m_cRef to 0 in constructor of SourceResolver::State, otherwise it will be leaked Change-Id: I703ef8e91ad88112102ede7e8321d0eca795b840 Reviewed-by: Yoann Lopes <yoann.lopes@digia.com>
* Fix QSGGeometry object leakLiang Jian2014-04-011-0/+1
| | | | | | | | Set QSGNode::OwnsGeometry flag to QSGVideoNode, otherwise the QSGGeometry object created in QSGVideoNode::setTexturedRectGeometry() will be leaked. Change-Id: I383b4fe2ff8c7921d2c9c101d4d90fac5a08365a Reviewed-by: Yoann Lopes <yoann.lopes@digia.com>
* QNX: Remove most of the CPU overhead for video renderingFabian Bumberger2014-04-016-63/+236
| | | | | | | | | | | | | | This patch uses the GL_OES_EGL_image extension to create a OpenGL Texture handle for a libscreen pixmap. If the extension is not available it uses the "old" technique as fallback where the image data is copied into a QImage. This reduces the CPU load by more than 70% and allows HD videos to be played jitter-free. Task-number: QTBUG-37752 Change-Id: I4cad22c39390e4cf9eb5be5f0bfe446544a11b9e Reviewed-by: Bernd Weimer <bweimer@blackberry.com> Reviewed-by: Sean Harmer <sean.harmer@kdab.com>
* CoreAudio: fix supported channel count.Yoann Lopes2014-04-013-43/+6
| | | | | | | | | | | We were using the number of channels actually used by audio devices as the maximum channel count. This is wrong as CoreAudio can automatically split or merge channels in order to accommodate the device. We now assume all channel configurations are valid. Task-number: QTBUG-37956 Change-Id: Ia8e8bbea8543caa7fecda305be74a2953b92fd25 Reviewed-by: Andy Nichols <andy.nichols@digia.com>
* Doc: Fix some documentation warningsSergio Ahumada2014-04-011-1/+1
| | | | | | | | | - Can't link to 'QSlider' - Can't link to 'QImage' Change-Id: Ifa1a27ca5224959d6dbb4c0055a56114740469f0 Reviewed-by: Sze Howe Koh <szehowe.koh@gmail.com> Reviewed-by: Jędrzej Nowacki <jedrzej.nowacki@digia.com>
* fix: 'm_state' was not declared in this scopeZhang Xingtao2014-03-281-1/+1
| | | | | | | | | Error occurred when building with DEBUG_PLAYBIN defined. It should be m_currentState from context. Change-Id: Iad59966ca19c9d1b589fc8641599494436a0a5f3 Reviewed-by: Liang Qi <liang.qi@digia.com> Reviewed-by: Jing Bai <doris.bai@gmail.com>
* CoreAudio: Mismatched new[]/delete in several places.Dyami Caliri2014-03-272-4/+4
| | | | | | | | | | The CoreAudio plugin code in QtMultimedia had several different places where an array was allocated with "new[]" and deleted with "delete". Fixed by deleting with "delete[]". Task-number: QTBUG-37861 Change-Id: Id85bc07a054ad161b0403cc0fe5c56ec5b41d4e3 Reviewed-by: Andy Nichols <andy.nichols@digia.com>
* Android: Clean-up in jmultimediautils class.Christian Strømme2014-03-273-36/+15
| | | | | | | Remove unused code. Change-Id: I2c0db45dd95e6a79387bba1b1ccd4b62b7d22aec Reviewed-by: Yoann Lopes <yoann.lopes@digia.com>
* Android: Fix MetadataRetriver wrapperChristian Strømme2014-03-273-23/+29
| | | | | | | The QJNIObject was never intended to be used as a base class. Change-Id: Ic4effd5e1c89a08515c756bd5092fb1e1eead688 Reviewed-by: Yoann Lopes <yoann.lopes@digia.com>
* Android: Fix QtSurfaceTextureChristian Strømme2014-03-2710-169/+80
| | | | | | | | | | | | Don't extend SurfaceTexture as this causes ART to fail when it doesn't find the postEventFromNative() function. The postEventFromNative() function was implemented sometime after API 11, so to avoid this situation we can use composition instead. Task-number: QTBUG-37605 Change-Id: Ie1013d218291ba0035f1bb18a0c0655fd2170bfd Reviewed-by: Yoann Lopes <yoann.lopes@digia.com>
* Android: Don't call release() unless it's necessary.Christian Strømme2014-03-271-1/+3
| | | | | | | | If the mediaplayer is in either Idle or Uninitialized state, then there is no need to call release again. Change-Id: Idb6f2d9ea7aad7a9036e7e9a534c3bd296324068 Reviewed-by: Yoann Lopes <yoann.lopes@digia.com>
* Blackberry: implement QCameraInfoControl.Yoann Lopes2014-03-279-3/+180
| | | | | | | We also now correctly report the default camera to be the rear camera. Change-Id: Ie96b2950344194637c8feace77246f036c9a3757 Reviewed-by: Fabian Bumberger <fbumberger@rim.com>
* Android: Fix reload check in onStateChanged().Christian Strømme2014-03-271-1/+3
| | | | | | | The condition was missing the Uninitialized flag. Change-Id: I555f4eae6cc33bee0a4925e626dd56041e4b0471 Reviewed-by: Yoann Lopes <yoann.lopes@digia.com>
* Doc: fix two typosZhang Xingtao2014-03-262-2/+2
| | | | | | Change-Id: I5f417384ce75d8dc2063f92d0116f516f261e4aa Reviewed-by: Frederik Gladhorn <frederik.gladhorn@digia.com> Reviewed-by: Yoann Lopes <yoann.lopes@digia.com>
* Fix enums for QML camera types.Yoann Lopes2014-03-246-41/+98
| | | | | | | | | | | | | | CameraExposure, CameraFlash and CameraFocus had signals and functions using enum-type arguments declared in QDeclarativeCamera. This doesn't work since an enum and a function using it both need to be declared in the same class in order to work from QML. The relevant enums have been duplicated (not moved, in order to preserve QML source compatibility) from QDeclarativeCamera to QDeclarativeCameraExposure, QDeclarativeCameraFlash and QDeclarativeCameraFocus. Change-Id: Ib307d7c6c9dbc59b1b82782913397160be38d4cd Reviewed-by: Christian Stromme <christian.stromme@digia.com>
* Improved declarative-camera example.v5.3.0-beta1Yoann Lopes2014-03-212-20/+20
| | | | | | | | | - Fix setting the white balance preset, it was never actually set on the camera - Improved the zoom control style Change-Id: I95c2851e5ad8409dd79306492271f221a61cb10d Reviewed-by: Christian Stromme <christian.stromme@digia.com>
* GStreamer: fix memory leaks.Yoann Lopes2014-03-2120-41/+134
| | | | | | | Many GStreamer objects were not properly managed or never released. Change-Id: I38b3854e8b9e2264b5b647f331d3bb16b886e2d6 Reviewed-by: Andrew den Exter <andrew.den.exter@qinetic.com.au>
* GStreamer: don't try to seek when it's not supported.Yoann Lopes2014-03-211-2/+2
| | | | | | | This eliminates warnings on the console. Change-Id: I6a0509dba4a0f7ec6fad33f8803be746f425a616 Reviewed-by: Andy Nichols <andy.nichols@digia.com>
* Android: Make the Mediaplayer more robustChristian Strømme2014-03-218-337/+614
| | | | | | | | | | | | In some cases the the Android media player would get into a unexpected state and we where then not able to recover. With this patch we monitor the state changes more closely and recover when possible. Task-number: QTBUG-35651 Change-Id: I142c63fbbf716d3f94ebdcf016a7cadad7b13207 Reviewed-by: Yoann Lopes <yoann.lopes@digia.com>
* Mac: Re-enable qcamerabackend testAndy Nichols2014-03-201-1/+0
| | | | | | | | | The cause of the tests flakyness has been resolved, so it should be re-enabled. Task-number: QTBUG-36040 Change-Id: Ic4d18ea891ed5b6c5f4acbb4d05322b910b87d29 Reviewed-by: Yoann Lopes <yoann.lopes@digia.com>
* AVFoundation: Add QVideoWindowControl supportAndy Nichols2014-03-204-2/+378
| | | | | | | | | | | | | | | | This adds the capability to render videos directly to native window surfaces when using the AVFoundation plugin. This adds limited support for displaying videos from QML on iOS. These videos are displayed in a CALayer above the QQuickWindow, so it will not be possible to render any QtQuick items on top of a video using the QVideoWindowControl to provide video. [ChangeLog][QtMultimedia][iOS] Add limited support for playing videos in QtQuick on iOS (Videos are played on top of scene with limited transform support). Change-Id: I80381d9a07b45b6fa1959678166e6da0004f8c19 Reviewed-by: Yoann Lopes <yoann.lopes@digia.com>
* Fix VideoOutput::autoOrientation documentation.Yoann Lopes2014-03-201-1/+1
| | | | | | | The type was reported to be int instead of bool. Change-Id: I3a76cb76ca70b50060c768f87cf84d8e436d8d7f Reviewed-by: Christian Stromme <christian.stromme@digia.com>
* QNX: Evaluate mm-renderer buffer statusBernd Weimer2014-03-194-15/+38
| | | | | | | | | | | | | | In the playing (or paused) state the media status should reflect the buffer state, it should not stay in the loaded media state. Mm-renderer differentiates between buffer "status" and "level". Unfortunately, QMediaPlayer's buffer status maps to mm-renderer's buffer level. Change-Id: I22ea8dc83cee975fc4aa1a6de4f172def042a9a8 QT-BUG: 37166 Reviewed-by: Rafael Roquetto <rafael.roquetto@kdab.com> Reviewed-by: Fabian Bumberger <fbumberger@rim.com>
* Tidy up Audio documentation.Mitch Curtis2014-03-193-22/+21
| | | | | Change-Id: I864ba13375d7b8b035686c11687e76fbf672c431 Reviewed-by: Yoann Lopes <yoann.lopes@digia.com>
* Prevent crash when there is no camera device availableAndy Shaw2014-03-191-2/+3
| | | | | | | | | If you try to use QAudioInputSelectorControl with the iOS Simulator then it would crash as there is no camera device available. This prevents a crash from happening in that case. Change-Id: I3904f3d299a11a6df21e66a1138a4319cc0b8a5c Reviewed-by: Andy Nichols <andy.nichols@digia.com>
* Doc: Document signals (not handlers) under \qmlsignalSze Howe Koh2014-03-189-52/+124
| | | | | | | | | Append the handler names to the end of the corresponding signal doc. Task-number: QTBUG-35846 Change-Id: I325cdab75ef18a19c9f29d6333039c31baa8daf6 Reviewed-by: Jerome Pasion <jerome.pasion@digia.com> Reviewed-by: Jędrzej Nowacki <jedrzej.nowacki@digia.com>