Commit Graph

2028 Commits

Author SHA1 Message Date
Liang Qi
5232c993a1 Merge remote-tracking branch 'origin/5.5.1' into 5.5
Change-Id: I9c55b5a63321475a468fb3a1b6ab775a9fe12689
2015-10-13 10:09:34 +02:00
Simon Hausmann
3727a588ee Merge "Merge remote-tracking branch 'origin/5.5' into 5.6" into refs/staging/5.6 2015-10-06 18:07:28 +00:00
Friedemann Kleint
c2c7171682 Add missing "We mean it" comments to private headers.
Task-number: QTBUG-48595
Change-Id: I1370d9229b0606582cbd828de84ee2717dca3daf
Reviewed-by: Yoann Lopes <yoann.lopes@theqtcompany.com>
2015-10-06 13:32:07 +00:00
Liang Qi
87e5e24f52 Merge remote-tracking branch 'origin/5.5' into 5.6
Change-Id: I1373622a6d1fd0e2d35df2da79860a373056387f
2015-10-02 13:48:43 +02:00
Samuel Nevala
c5ebfb0c19 winrt: Fix frozen UI caused by camera search and lock focus.
Instead of yielding thread process events while waiting for focus to
complete.

Change-Id: I6b5f08bc175af37430c851f151fce5c3bfe238ad
Task-Id: QTBUG-48534
Reviewed-by: Andrew Knight <andrew.knight@intopalo.com>
2015-10-01 05:01:37 +00:00
Samuel Nevala
12512d557f Revert: "winrt: fix camera preview on Lumia 630"
This reverts commit be0a231be4. Moving
blitting away from the camera device removed the need to lock buffer.

Change-Id: I3a0e983d9ff2135e32e3e352c443ca653c1dd017
Reviewed-by: Oliver Wolff <oliver.wolff@theqtcompany.com>
Reviewed-by: Andrew Knight <andrew.knight@intopalo.com>
2015-09-30 09:46:26 +00:00
Samuel Nevala
f6082d4632 winrt: Fix Lumia 1520 black viewfinder.
The latest Denim update broke VideoProcessorBlt for Lumia 1520. After
the update, the blit results in a black target texture. As a
workaround, don't use DirectVideo, but leave format conversion and
drawing to the EGL Node.

Task-Id: QTBUG-48331
Change-Id: I1dab6b58d52d0e24fbffb91f23772906a576047a
Reviewed-by: Andrew Knight <andrew.knight@intopalo.com>
2015-09-29 20:07:44 +00:00
Samuel Nevala
572f3f80fc winrt: Optimize camera viewfinder pipeline.
Move blitting from the camera device to render side device.

Change-Id: Iadb89f4285f1fc242dbd825e60e258e7a9cfba58
Reviewed-by: Oliver Wolff <oliver.wolff@theqtcompany.com>
Reviewed-by: Andrew Knight <andrew.knight@intopalo.com>
2015-09-29 15:42:31 +00:00
Edward Welbourne
83a68761f2 Purge spurious execute permissions.
Source code and graphics are not for running.

Change-Id: I3b015b3cefd70329036c044f1b6c478d50453054
Reviewed-by: Frederik Gladhorn <frederik.gladhorn@theqtcompany.com>
Reviewed-by: Jędrzej Nowacki <jedrzej.nowacki@theqtcompany.com>
2015-09-29 14:23:05 +00:00
Samuel Nevala
e489e7b5b1 winrt: Introduce DirectX pipeline bypass.
Qt Windows Runtime camera uses DirectVideo to convert NV12 format
texture to BGRA format texture. As the EGL Node can draw using NV12
already, allow video render control to choose which path to take. By
default use DirectVideo. Bypass can be used as fallback when
DirectVideo cannot be used or is not working.

Task-Id: QTBUG-48331
Change-Id: I0cb87a7c4523bfb60610e6b41ab3fb05aff092a1
Reviewed-by: Andrew Knight <andrew.knight@intopalo.com>
2015-09-29 08:12:34 +00:00
Levy, Lawrence-Jacques
416db33110 Declare videonode dependency on Qt5MultimediaQuick_p
Change-Id: I896fda1689dba502380956c0b7a8a4e6b05a1e3a
Reviewed-by: Julien Brianceau <jbriance@cisco.com>
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@theqtcompany.com>
Reviewed-by: Yoann Lopes <yoann.lopes@theqtcompany.com>
2015-09-21 17:11:13 +00:00
Yoann Lopes
46a83d5b86 AVFoundation: render camera frames using OpenGL textures on iOS.
OpenGL textures can easily be created from a CVImageBuffer using
Apple APIs. It avoids having to map the buffer to main memory and
therefore greatly improves rendering performances.

We could do the same on OSX, but there, the textures are always of
the GL_TEXTURE_RECTANGLE target type and changes need to be
done to the QVideoFrame API and to the video node implementations
to support that.

Change-Id: I6dde7e8d7a27460e41523cd474c3c741affc1480
Reviewed-by: James Turner <james.turner@kdab.com>
Reviewed-by: Christian Stromme <christian.stromme@theqtcompany.com>
2015-09-17 13:10:28 +00:00
Yoann Lopes
0b192ce23e Fix QML revisions registration for 5.6.
And update plugins.qmltypes file.

Change-Id: I9b3cbeda4c8a0ce88a88f5a16fae6834dc8363d7
Reviewed-by: Marco Benelli <marco.benelli@theqtcompany.com>
Reviewed-by: Christian Stromme <christian.stromme@theqtcompany.com>
2015-09-15 14:36:40 +00:00
Marco Benelli
99f6cf5f28 Fixed revisions of camera-related meta objects.
Change-Id: I91fe90122d53ce12322cecac8282ef9622869b71
Reviewed-by: Yoann Lopes <yoann.lopes@theqtcompany.com>
2015-09-15 13:02:34 +00:00
Yoann Lopes
c595fc74ab Add 5.5.1 change file.
Change-Id: Icb8094e4d6ae94be43b726a25881350a6f266ef4
Reviewed-by: Christian Stromme <christian.stromme@theqtcompany.com>
2015-09-15 11:33:17 +00:00
Yoann Lopes
9c5292927e AVFoundation: implemented QMediaPlayer::seekable.
Change-Id: Iaca8daa2460062954497b3e510dd1828953c80fd
Reviewed-by: Christian Stromme <christian.stromme@theqtcompany.com>
2015-09-15 09:10:25 +00:00
Yoann Lopes
e9cf6670fe AVFoundation: fix rendering when player reached EndOfMedia.
Once the media player reached the end of the media, it shouldn't be
rendering frames anymore. This could happen when seeking after reaching
the end.
The output layer is now cleared on EndOfMedia to make sure that doesn't
happen.

Change-Id: I18a21eaff6c63a2bd54d4c2953f89eb1722f66d5
Reviewed-by: Christian Stromme <christian.stromme@theqtcompany.com>
2015-09-15 09:10:21 +00:00
Yoann Lopes
fdac8d9c74 AVFoundation: correctly unload current media.
When loading a new media, we should unload the previous media.
This makes sure all properties set right after loading a new media
(e.g. position, volume) are correctly set on the new AVPlayer and
not on the old one.

Change-Id: I4cd71b785ccdb4cd0772cedffc3c25665f402776
Reviewed-by: Christian Stromme <christian.stromme@theqtcompany.com>
2015-09-15 09:10:16 +00:00
Yoann Lopes
bede0a838d AVFoundation: store seek requests before media is loaded.
And actually seek once the media is loaded.

Task-number: QTBUG-48057
Change-Id: I9446a1e66a48f9a94c039be9af81689ed04bc56c
Reviewed-by: Christian Stromme <christian.stromme@theqtcompany.com>
2015-09-15 09:10:12 +00:00
Yoann Lopes
6a6a69b7d8 AVFoundation: fix initial volume.
The volume level set before loading a media was never actually set on
AVPlayer.
Regression introduced by 4e07ff99 on OSX.

Task-number: QTBUG-48154
Change-Id: I599e3d55b35d7196aebc4753a367a29049f99d33
Reviewed-by: Christian Stromme <christian.stromme@theqtcompany.com>
2015-09-15 09:09:42 +00:00
Yoann Lopes
95fa47f747 AVFoundation: fix playback rate.
Calling play on the AVPlayer internally resets the playback rate, which
means any playback rate set before calling play was ignored.
We now always call setRate to start playback to avoid resetting the
rate with play.
Aslo fixed the playbackRateChanged() signal that was never emitted.

Task-number: QTBUG-45570
Change-Id: I3a77e1db31c57f1e3491287bdf977731b9d73509
Reviewed-by: Christian Stromme <christian.stromme@theqtcompany.com>
2015-09-15 09:09:11 +00:00
Yoann Lopes
29ce8886b3 Android: allow to map video buffers.
Since we internally use a fbo, use QOpenGLFramebufferObject::toImage()
to grab the pixel data and enable the use of map() on frames retrieved
using QAbstractVideoFilter.

Change-Id: If96e992e12e26091524913bb24926fa21d9d58cc
Reviewed-by: Laszlo Agocs <laszlo.agocs@theqtcompany.com>
2015-09-08 10:18:01 +00:00
Nico Vertriest
da6d287e46 Doc: minor corrections
Change-Id: Idcaac01294642e7e79f6e2b8bcfd2c9559274790
Task-number: QTBUG-43810
Reviewed-by: Martin Smith <martin.smith@digia.com>
2015-09-07 13:47:07 +00:00
Friedemann Kleint
8a5f74ddf2 Add 'resourcepolicy' to MODULE_PLUGIN_TYPES of multimedia.pro.
Fix warning:
WARNING: Project ERROR: No module claims plugin type resourcepolicy
discovered when running lupdate to create the translations.

Change-Id: I9fdde3e86219164cabbfe10672899eb2984f06d2
Reviewed-by: Robin Burchell <robin.burchell@viroteck.net>
2015-09-03 04:33:38 +00:00
Yoann Lopes
edc415be47 Fix crash in QSoundEffect when using it from a non-GUI thread.
The internal QIODevice used as data source was not set as child of the
parent QSoundEffectPrivate. If moveToThread() was called on the
QSoundEffect, the QIODevice would still receive events on the main
thread, leading to race conditions.

Task-number: QTBUG-46359
Change-Id: I180da2fb498108b316fd9b5b5cc84376b360fa3f
Reviewed-by: Christian Stromme <christian.stromme@theqtcompany.com>
2015-08-25 14:12:04 +00:00
Yoann Lopes
4eb4a3ada3 Fix QML Camera::supportedViewfinderFrameRateRanges().
Pass the resolution argument as a QJSValue instead of a QSize.
This allows to be more flexible and doesn't require the QML argument
to be an actual QML 'size' value. It can be any object with the
'width' and 'height' properties.

Added missing auto-tests for supportedViewfinderResolutions()
and supportedViewfinderFrameRateRanges().

Change-Id: I6c8ae72e6dab8c9d12bbada5b8e7f45e96e9289d
Task-number: QTBUG-47630
Reviewed-by: Simon Hausmann <simon.hausmann@theqtcompany.com>
2015-08-25 11:18:51 +00:00
Yoann Lopes
ded4d7b006 Fix possible crashes in QDeclarativeRadioData.
It would crash when accessing any of its properties when there is no
radio backend available.

Task-number: QTBUG-47859
Change-Id: Ic7c0a70ca3e9a4768359b3429ea812caece09fce
Reviewed-by: Christian Stromme <christian.stromme@theqtcompany.com>
2015-08-25 08:56:17 +00:00
Yoann Lopes
f5e18c6239 Fix MediaPlayer::playlist documentation.
Added missing '\since 5.6' tag.

Change-Id: I46e0ea8bad85fb1f51f5502766c13549c6dad9d5
Reviewed-by: Christian Stromme <christian.stromme@theqtcompany.com>
2015-08-24 13:05:46 +00:00
Yoann Lopes
3477104e0d Fix QCamera::lockStatus() documentation.
Change-Id: I1f7c063ef1e465ba658f637754b10b7af44b8373
Reviewed-by: Christian Stromme <christian.stromme@theqtcompany.com>
2015-08-24 13:05:40 +00:00
Yoann Lopes
a2244c9b7a Merge remote-tracking branch 'origin/5.5' into 5.6
Conflicts:
	src/imports/multimedia/qdeclarativeaudio.cpp

Change-Id: I57c6252b084e4ed796f6f308b2e0c717d0f59b13
2015-08-24 14:36:13 +02:00
Yoann Lopes
008d20e0ec Android: minor refactor of the camera frame callback.
Change-Id: I6b281c9b2d02cf223e66e04e31fdd0268aa277fc
Reviewed-by: Christian Stromme <christian.stromme@theqtcompany.com>
2015-08-20 07:03:54 +00:00
Yoann Lopes
2e54790a59 Android: fix video probes when recording the camera.
The preview frame callback is cleared by the Android Camera whenever a
MediaRecorder is set up. We need to reset the callback after starting
the media recorder.

Change-Id: I604320b11eb3a7f6f8d7d3167d5aae371999be14
Reviewed-by: Christian Stromme <christian.stromme@theqtcompany.com>
2015-08-20 07:01:10 +00:00
Friedemann Kleint
31fce88b3f Fix 2 more tr()-contexts of messages in QPlaylistFileParserPrivate.
Use QPlaylistFileParser instead of QObject.

Change-Id: I5dd4b56f7f580ca4089db67bbfabdd58ef7e2778
Reviewed-by: Yoann Lopes <yoann.lopes@theqtcompany.com>
2015-08-19 16:20:20 +00:00
Yoann Lopes
28a20861fd QMediaPlayer: clear current playlist on deletion.
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>
2015-08-19 11:32:35 +00:00
Friedemann Kleint
aad6e64352 Fix tr()-context of messages in QPlaylistFileParserPrivate.
Use QPlaylistFileParser instead of QObject.

Change-Id: I83f6b0384fc60b356a8ae8b316d2aaa768e7ac4d
Reviewed-by: Yoann Lopes <yoann.lopes@theqtcompany.com>
2015-08-19 11:16:09 +00:00
Friedemann Kleint
9c9a240220 Make QWinRTImageEncoderControl a Q_OBJECT.
Fix lupdate warning:

qtmultimedia/src/plugins/winrt/qwinrtimageencodercontrol.cpp:60: Class 'QWinRTImageEncoderControl' lacks Q_OBJECT macro

when parsing the tr() in
QWinRTImageEncoderControl::imageCodecDescription().

Change-Id: I004c05c8cea620e30bff7a2b35b83eed01b7ed4c
Reviewed-by: Andrew Knight <andrew.knight@intopalo.com>
2015-08-19 07:12:11 +00:00
Yoann Lopes
cd3d540522 GStreamer: refactored widget and window control.
Instead of always using xvimagesink as GStreamer backend for the
widget and window control (works only with X11), we now try to
pick a video sink that fits the current configuration.
It first tries a set of known video sinks that can work with
the Qt platform plugin in use. If none is available, it
dynamically picks a video sink available on the system that can be
used with our backend.

Even if the video sink is now picked in a smarter way, xcb is still
the only supported platform plugin. The reason is that it's the
only Unix plugin which can provide a valid native window handle.
Additional work is needed to support other plugins like wayland
or directfb.

Change-Id: I3843dea363d6a0b85a6cc1f2952783b743e48ac6
Reviewed-by: Christian Stromme <christian.stromme@theqtcompany.com>
2015-08-18 13:16:50 +00:00
Yoann Lopes
13e40d522f Fix QCamera viewfinder capabilities functions..
- Filtering the results for a specific pixel aspect ratio would return
  wrong values.
- Correctly sort the frame rate ranges returned by
  supportedViewfinderFrameRateRanges().

Added missing auto-tests for all viewfinder capabilities functions.

Change-Id: Idfb40d4139cc48a5996ce2ddd98131a2f5be76bb
Reviewed-by: Christian Stromme <christian.stromme@theqtcompany.com>
2015-08-18 12:58:00 +00:00
Samuel Nevala
1b957a05fe winrt: Fix aspect ratio deviation between preview and encoding streams
The source texture size from camera was wrong due to a missing
IMediaDeviceController::SetMediaStreamPropertiesAsync call for the
preview media type. Therefore Viewfinder and StillImage capture modes
behave tha same from QCamera point of view. By default, the camera
takes the lowest capture resolution and the lowest preview
resolution with a matching aspect ratio. If the capture resolution
is set, the preview resolution is set to the lowest possible resolution
with a matching aspect ratio. Until viewfinder settings are implemented
for WinRT, there is no way for user to change the viewfinder resolution.

Change-Id: I4b76ceb46bd4c366561f5206d913b97c0d0df211
Task-Id: QTBUG-47465
Reviewed-by: Oliver Wolff <oliver.wolff@theqtcompany.com>
2015-08-18 10:52:15 +00:00
Ricardo Salveti de Araujo
e0b9217d27 Avoid races when sending EOS
In order to avoid races when sending EOS, we need to make sure that the
pipeline is in playing state first.

Task-number: QTBUG-45707
Change-Id: I518e89badf38bea8ab8e2cead9a1ca09659af8b2
Reviewed-by: Timo Jyrinki <timo.jyrinki@canonical.com>
Reviewed-by: Yoann Lopes <yoann.lopes@theqtcompany.com>
2015-08-18 09:49:09 +00:00
Yoann Lopes
c9533b5aaf GStreamer: added convenience function in QGstUtils.
-> qt_gst_element_get_factory_name(GstElement *elem)

Change-Id: Icf806488b49fbcdecdd605b6316bd1ef8796a883
Reviewed-by: Christian Stromme <christian.stromme@theqtcompany.com>
2015-08-13 13:26:26 +00:00
Thiago Macieira
8b85c5a28e Add the GPLv3 license text
LGPLv3 refers to it but does not include it in its body.

Change-Id: Ib056b47dde3341ef9a52ffff13eed18cf3504738
Reviewed-by: Lars Knoll <lars.knoll@theqtcompany.com>
2015-08-13 15:07:55 +02:00
Yoann Lopes
8ba1e65291 Fix camera plugin selection.
When requesting a camera plugin for a given device id, it should fall
back to any available plugin if that device id is not found.

Change-Id: I685294c7fdcaa72bce70178b0aae2ec92e79e107
Reviewed-by: Christian Stromme <christian.stromme@theqtcompany.com>
2015-08-12 14:07:21 +00:00
Christian Strømme
dc1712d4b2 Remove obsolete check in QMediaService
The macro QT_NO_MEMBER_TEMPLATES was removed eons ago.

Change-Id: Ifc4f3ac8bcf1e9b42fad5dcfb101e3446a254abc
Reviewed-by: Yoann Lopes <yoann.lopes@theqtcompany.com>
2015-08-12 11:34:44 +00:00
Loïc Molinari
b05e9d99c2 Bind the playlist connected to a player.
Change-Id: I3c2e00773c88f671bdffcfe8c8175330ca405d4a
Reviewed-by: Yoann Lopes <yoann.lopes@theqtcompany.com>
2015-08-12 09:43:53 +00:00
Venugopal Shivashankar
ae9095d5bc Doc: Corrected a typo.
Change-Id: I53ab7ddf0a8c0416dce19bf2b642e7e294f3c868
Reviewed-by: Yoann Lopes <yoann.lopes@theqtcompany.com>
2015-08-11 13:53:38 +00:00
Yoann Lopes
68a09d3093 Fix documentation for QML metaData property.
For Audio, Video, MediaPlayer and Camera types.
Group the sub properties as a \qmlproperty group, which makes
the doc much clearer.

Change-Id: Id990d7b14a4c3f86768c6b3b4990845f84839944
Reviewed-by: Venugopal Shivashankar <venugopal.shivashankar@digia.com>
2015-08-11 13:36:41 +00:00
Yoann Lopes
6df6cacbb0 Fix qdoc warnings.
Change-Id: Ie351f33f88270186b7df0f9cd671fa4e31624231
Reviewed-by: Topi Reiniö <topi.reinio@digia.com>
2015-08-11 13:14:28 +00:00
Yoann Lopes
b8553dae1d Doc: update qml module version to 5.5.
And remove import statements from snippets.

Change-Id: I109beabd445186f96f0750b6f23fb623c125181e
Task-number: QTBUG-47620
Reviewed-by: Venugopal Shivashankar <venugopal.shivashankar@digia.com>
Reviewed-by: Topi Reiniö <topi.reinio@digia.com>
2015-08-11 13:07:34 +00:00
Yoann Lopes
a00c588c70 Improve documentation for mediaObject property.
In Camera and MediaPlayer types.

Change-Id: Iaf17dc7e5f7075ce7eeefcf7992b970d1ea99e83
Reviewed-by: Venugopal Shivashankar <venugopal.shivashankar@digia.com>
2015-08-11 09:44:08 +00:00