platform/upstream/qtmultimedia.git
10 years agoAVFoundation: fix crash when no camera is available on the system.
Yoann Lopes [Fri, 7 Mar 2014 13:15:13 +0000 (14:15 +0100)]
AVFoundation: fix crash when no camera is available on the system.

Change-Id: I0b473babae4d1fae605667957deca21ba1dc0c09
Reviewed-by: Andy Nichols <andy.nichols@digia.com>
10 years agoCoreAudio: Set default audio category to Playback on iOS
Andy Nichols [Thu, 6 Mar 2014 11:33:41 +0000 (12:33 +0100)]
CoreAudio: Set default audio category to Playback on iOS

This fixes the issue that when we use QSoundEffect we dont need to get
permission to use the microphone.  This was because we were defaulting
to PlayAndRecord.  Now we only switch to the PlayAndRecord category when
we try and use an input device.

[ChangeLog][QtMultimedia][iOS] Using QSoundEffect (or SoundEffect in
QML) no longer requires permission to use the microphone.

Change-Id: I94535215497a718005c280bfd84b428b4bf1b16a
Reviewed-by: Yoann Lopes <yoann.lopes@digia.com>
10 years agoAVFoundation: Prevent Crash in QMediaPlayer
Andy Nichols [Wed, 5 Mar 2014 14:32:05 +0000 (15:32 +0100)]
AVFoundation: Prevent Crash in QMediaPlayer

Task-number: QTBUG-34213
Change-Id: I0883436175439abbb4ea964ed552a17b970ed05c
Reviewed-by: Michael Bruning <michael.bruning@digia.com>
Reviewed-by: Yoann Lopes <yoann.lopes@digia.com>
10 years agoRelease videoframe on painter stop()
Wouter Huysentruit [Mon, 3 Mar 2014 19:21:26 +0000 (20:21 +0100)]
Release videoframe on painter stop()

QVideoSurfaceGLPainter/QVideoSurfaceGlslPainter needs
to release the video frame on stop (just like
QVideoSurfaceGenericPainter already does).

Change-Id: Iaf3eb13eaf51fbc22fab6b1f80db8e8978ac328d
Reviewed-by: Yoann Lopes <yoann.lopes@digia.com>
10 years agotst_qcamerainfo: Fix weird symbol in license header
Sergio Ahumada [Wed, 5 Mar 2014 12:15:54 +0000 (13:15 +0100)]
tst_qcamerainfo: Fix weird symbol in license header

Change-Id: Idff0ffb96fa86dd7faa9ff9b86338c238d4edcb5
Reviewed-by: Yoann Lopes <yoann.lopes@digia.com>
10 years agoGStreamer: Remove tags when an invalid QVariant is assigned.
Andrew den Exter [Tue, 4 Mar 2014 08:03:20 +0000 (18:03 +1000)]
GStreamer: Remove tags when an invalid QVariant is assigned.

Clear the tag list before syncing with reference set so old values
are removed and explicitly remove invalid QVariants from the reference
set so that the type correction doesn't result in invalid values being
written instead.

Change-Id: I7d1bdc95cd2a2d601720db84c9b3ef629477bc99
Reviewed-by: Yoann Lopes <yoann.lopes@digia.com>
10 years agovideonode: imx6: clear texture cache when the format changes
Michael Olbrich [Wed, 26 Feb 2014 18:00:05 +0000 (19:00 +0100)]
videonode: imx6: clear texture cache when the format changes

The old textures won't match anyways. So there is no need to keep them.

Change-Id: Id3482333d10cf022d04076ec0f5c7df475c522ae
Signed-off-by: Michael Olbrich <m.olbrich@pengutronix.de>
Reviewed-by: Andy Nichols <andy.nichols@digia.com>
10 years agovideonode: imx6: cleanup pixel formats
Michael Olbrich [Wed, 26 Feb 2014 16:29:45 +0000 (17:29 +0100)]
videonode: imx6: cleanup pixel formats

All formats are now tested.

Also, don't use the alpha channel. This is not quite correct for formats
with alpha channel but for video probably a good idea.

Change-Id: I4a2404d7c96023bb1e3fca41e1f224d23347f290
Signed-off-by: Michael Olbrich <m.olbrich@pengutronix.de>
Reviewed-by: Andy Nichols <andy.nichols@digia.com>
10 years agoenable imx6 specific QSGVideoNode based on a config test
Michael Olbrich [Thu, 27 Feb 2014 16:19:29 +0000 (17:19 +0100)]
enable imx6 specific QSGVideoNode based on a config test

This way it also works custom mkspecs

Change-Id: I7414aac775b797da3487e9625c7212486118b532
Signed-off-by: Michael Olbrich <m.olbrich@pengutronix.de>
Reviewed-by: Andy Nichols <andy.nichols@digia.com>
10 years agoAVFoundation: Cleanup AVCaptureSession with proper reference counting
Andy Nichols [Tue, 4 Mar 2014 13:11:01 +0000 (14:11 +0100)]
AVFoundation: Cleanup AVCaptureSession with proper reference counting

The reference counting was not being done for AVCaptureSession so it was
being destroyed before we got a chance to properly clean it up (which
lead to crashes).  We also make sure to remove any observers from
AVCaptureSession now before destroying it.

Task-number: QTBUG-37109
Task-number: QTBUG-29955
Change-Id: Ia9b49ad1eab01b4f7424e2a1c699d903cd9bf902
Reviewed-by: Yoann Lopes <yoann.lopes@digia.com>
10 years agoAVFoundation: implement QCameraInfoControl.
Yoann Lopes [Fri, 7 Feb 2014 13:20:28 +0000 (14:20 +0100)]
AVFoundation: implement QCameraInfoControl.

Change-Id: I05f3daa5c4acb90e046e26d6d577ae40dfed0e30
Reviewed-by: Andy Nichols <andy.nichols@digia.com>
10 years agoAVFoundation: Call stop() on VideoSurface when changing sources
Andy Nichols [Mon, 3 Mar 2014 17:39:43 +0000 (18:39 +0100)]
AVFoundation: Call stop() on VideoSurface when changing sources

Before we were reusing the active surface when we switched videos.  This
leads to an inconsitency in states, and the sourceRect property of the
video surface does not get updated.

Task-number: QTBUG-28655
Change-Id: Ie29bf1d9b1c11b6f51a869253c730202001c07cf
Reviewed-by: Yoann Lopes <yoann.lopes@digia.com>
10 years agoAVFoundation: Fix y-inverted QML Videos
Andy Nichols [Mon, 3 Mar 2014 14:18:38 +0000 (15:18 +0100)]
AVFoundation: Fix y-inverted QML Videos

When the code that supports iOS was added, we introduced a bug where QML
videos would be played y-inverted on OS X.  This is because we made no
effort to y-invert the Framebuffer Object before rendering the texture
in the SceneGraph.  Now we render the video the the FBO y-inverted, so
there is no need to y-invert the resulting texture.

Task-number: QTBUG-35955
Change-Id: I41af1aaae57923b9972b5be5ec65f7d2a97d77c5
Reviewed-by: Yoann Lopes <yoann.lopes@digia.com>
10 years agoAVFoundation: Remove debug code
Andy Nichols [Mon, 3 Mar 2014 14:15:00 +0000 (15:15 +0100)]
AVFoundation: Remove debug code

Some debug code made it into the released code, so each time you used
the QWidget based video player the terminal would print data about the
window frame size.

Change-Id: I86eb00ce5edb23b7a2abf6a63893cd17aaeb0ee3
Reviewed-by: Yoann Lopes <yoann.lopes@digia.com>
10 years agoCoreAudio: Use the real default audio device for QSoundEffect
Andy Nichols [Sun, 2 Mar 2014 19:39:44 +0000 (20:39 +0100)]
CoreAudio: Use the real default audio device for QSoundEffect

There is an assumption in QtMultimedia that the first audio device
returned by QAudioDeviceInfo::availableDevices is the default device, so
we must make an effor to make sure this is true.  This commit should fix
the issue on OS X.

Task-number: QTBUG-36638
Change-Id: Id388d7218b465cb29d826f46ee825e982c5f7ffc
Reviewed-by: Yoann Lopes <yoann.lopes@digia.com>
10 years agoCoreAudio: Make it possible to set volume on of QAudioOutput
Andy Nichols [Sun, 2 Mar 2014 17:44:52 +0000 (18:44 +0100)]
CoreAudio: Make it possible to set volume on of QAudioOutput

QAudioOutput::setVolume stopped working for CoreAudio when it was ported
to live in it's own plugin.  This was because it was not possible to set
the volume of QAudioOutput in iOS.  Now the functionality has been
restored and added for iOS as well.  For OS X we use the old method of
setting the volume property of the AudioUnit.  On iOS it is not possible
to set the volume on a per AudioUnit basis, so we now manually modify
the buffer contents (the same we do for QAudioInput already).

Task-number: QTBUG-36756
Change-Id: I42b5892fe5534217043fa55e7b5b9a4ce824050d
Reviewed-by: Yoann Lopes <yoann.lopes@digia.com>
10 years agoAVFoundation: Improve config test
Andy Nichols [Sun, 2 Mar 2014 20:07:06 +0000 (21:07 +0100)]
AVFoundation: Improve config test

This should prevent the avfoundation plugin from being built on system
that can not support using it (ex. 32bit builds on OS X 10.7)

Task-number: QTBUG-36239
Change-Id: I9f861b7580b0e015ddbc1231440d677bf6eee1ec
Reviewed-by: Yoann Lopes <yoann.lopes@digia.com>
10 years agoCoreAudio: Allow more flexability when specifying SampleRates
Andy Nichols [Sun, 2 Mar 2014 15:19:37 +0000 (16:19 +0100)]
CoreAudio: Allow more flexability when specifying SampleRates

The available sample rates for a given device are the nominal sample
rates reported by the device.  It is possible to use other sample rates
and CoreAudio will take care of the conversion.  So what we will do is
report what rates are available for a device, but not explicitly require
those sample rates to have a valid format.

Task-number: QTBUG-36265
Change-Id: Idbbdeacbb6bc1fe434bcd8dec519ad70d4ccd545
Reviewed-by: Yoann Lopes <yoann.lopes@digia.com>
10 years agoPrefer to use normalised signal/slot signatures
Sergio Ahumada [Sun, 2 Mar 2014 10:43:58 +0000 (11:43 +0100)]
Prefer to use normalised signal/slot signatures

Change-Id: I48ae4b46f7a0342a1436ba78958b057e919e3a8a
Reviewed-by: Marc Mutz <marc.mutz@kdab.com>
10 years agoAdd missing virtual destructor for new class
Thiago Macieira [Sat, 1 Mar 2014 07:19:38 +0000 (23:19 -0800)]
Add missing virtual destructor for new class

qmediaserviceproviderplugin.h:166:28: error: ‘struct QMediaServiceCameraInfoInterface’ has virtual functions and accessible non-virtual destructor [-Werror=non-virtual-dtor]

Change-Id: I08c6718bfd87c5adeea9969afdd4766150163238
Reviewed-by: Jędrzej Nowacki <jedrzej.nowacki@digia.com>
Reviewed-by: Yoann Lopes <yoann.lopes@digia.com>
10 years agoAndroid: implement QCameraInfoControl.
Yoann Lopes [Mon, 3 Feb 2014 18:47:33 +0000 (19:47 +0100)]
Android: implement QCameraInfoControl.

VideoOutput will now take into account the camera sensor orientation to
adjust the viewport orientation, we don't need to apply a rotation on
the Android Camera anymore.

Change-Id: Ia7639f0a5711ab6cc6f80b9716bc1a6f389499b4
Reviewed-by: Christian Stromme <christian.stromme@digia.com>
10 years agoVideoOutput: fix autoOrientation with a camera source.
Yoann Lopes [Mon, 3 Feb 2014 20:38:56 +0000 (21:38 +0100)]
VideoOutput: fix autoOrientation with a camera source.

Don't assume the camera frames are always in the same orientation as the
display in its primary orientation. We now take into account the camera
sensor position and orientation to calculate the viewport orientation.

Change-Id: Ib333c87f1804d1010ada42cb757e4fab78d75a04
Reviewed-by: Christian Stromme <christian.stromme@digia.com>
10 years agoNew QCameraInfo class.
Yoann Lopes [Wed, 22 Jan 2014 15:18:42 +0000 (16:18 +0100)]
New QCameraInfo class.

The class allows to get the list of available cameras on the system as
well as getting some static information about them such as their unique
ID, display name, physical position and sensor orientation.

This makes QCamera::availableDevices() and QCamera::deviceDescription()
obsolete.

This patch contains the API, documentation and auto-tests but not the
actual implementation by each backend (except for retrieving the default
camera device).

[ChangeLog][QtMultimedia] Added new QCameraInfo class
[ChangeLog][QtMultimedia] QCamera: availableDevices() and
deviceDescription() are deprecated, use QCameraInfo instead

Change-Id: I64fd65729ab26a789468979ed5444ee90bb82cd0
Reviewed-by: Christian Stromme <christian.stromme@digia.com>
10 years agoQSoundEffect: fix changing the loop count while playing.
Yoann Lopes [Thu, 20 Feb 2014 18:42:20 +0000 (19:42 +0100)]
QSoundEffect: fix changing the loop count while playing.

The running count was not updated with the new value.

Auto-test added and documentation updated to be more clear about this
behavior.

Task-number: QTBUG-36643

Change-Id: I29e98ca4679f950a75133b21873738bcb72d23d4
Reviewed-by: Christian Stromme <christian.stromme@digia.com>
10 years agoandroid: add missing feature tags.
Yoann Lopes [Fri, 21 Feb 2014 13:18:34 +0000 (14:18 +0100)]
android: add missing feature tags.

Adding the CAMERA and RECORD_AUDIO permissions implicitely makes some
features a hard requirement for the app.
By adding these features in the .pro file, androiddeployqt will mark
them as unrequired in the final package.

Change-Id: Ie9357d05626cb12272001d63b04e230737fbf1bc
Reviewed-by: Eskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@digia.com>
10 years agoQNX: Use window group of top-level window for mmr
Frank Osterfeld [Thu, 28 Nov 2013 16:06:17 +0000 (17:06 +0100)]
QNX: Use window group of top-level window for mmr

Pass the top-level window's window group to mm-renderer,
as required by mmr.

Change-Id: I2a2e8b4aa48f5c2292b03593c6d528068f383b5c
Reviewed-by: Bernd Weimer <bweimer@blackberry.com>
Reviewed-by: Rafael Roquetto <rafael.roquetto@kdab.com>
Reviewed-by: Fabian Bumberger <fbumberger@rim.com>
10 years agoMerge remote-tracking branch 'origin/dev' into stable
Oswald Buddenhagen [Wed, 19 Feb 2014 09:04:30 +0000 (10:04 +0100)]
Merge remote-tracking branch 'origin/dev' into stable

Change-Id: I84b36fa41f3d5f8fea2dec2545f72ebe6a0c7908

10 years agoFix linking problem when built with -no-opengl
Andy Shaw [Mon, 10 Feb 2014 23:24:58 +0000 (00:24 +0100)]
Fix linking problem when built with -no-opengl

When -no-opengl was used then it was not automatically pulling in the
needed Windows libraries as it was not loading opengl.prf to get them
from.

Change-Id: I9b73e5ee01da964a64c71b6261ff4ed98ce6f1a9
Reviewed-by: Yoann Lopes <yoann.lopes@digia.com>
10 years agoUse QVERIFY2 for elapsed time in tst_QMediaPlayerBackend::seekPauseSeek().
Friedemann Kleint [Mon, 17 Feb 2014 13:19:44 +0000 (14:19 +0100)]
Use QVERIFY2 for elapsed time in tst_QMediaPlayerBackend::seekPauseSeek().

The test has been observed to fail sometimes, try to obtain values.

Change-Id: Id0374b7ad3d593c099500e771bc4d8cc50f26651
Reviewed-by: Yoann Lopes <yoann.lopes@digia.com>
10 years agoAVFoundation: mirror viewfinder frames of front-facing cameras.
Yoann Lopes [Fri, 7 Feb 2014 13:23:32 +0000 (14:23 +0100)]
AVFoundation: mirror viewfinder frames of front-facing cameras.

Change-Id: I95920aa459ff0931819cb6f8278ab296db542601
Reviewed-by: Andy Nichols <andy.nichols@digia.com>
10 years agoMerge remote-tracking branch 'origin/stable' into dev
Frederik Gladhorn [Wed, 12 Feb 2014 13:11:35 +0000 (14:11 +0100)]
Merge remote-tracking branch 'origin/stable' into dev

Change-Id: Ie93615076177662e75d46f3d13beeb88d424b4a6

10 years agoadding zero-copy-QSGVideoNode for imx6 upstream/5.2.2
Thomas Senyk [Tue, 28 Jan 2014 13:49:32 +0000 (14:49 +0100)]
adding zero-copy-QSGVideoNode for imx6

On imx6 there is a platform-specific API to implement
memory-mapping from gstreamer-buffer to opengl-texture.

This plugin uses this API to avoid CPU-based-memory-copy.

This allows fluid video-playback up to 1080p with very little CPU load.
Before even 720p used one cpu-core completely and wasn't fluid.

Change-Id: I0c33eb5d475393a65459291ce9290fa0753de4a5
Reviewed-by: Andy Nichols <andy.nichols@digia.com>
10 years agoAdd meta-data mappings for GPS and camera make and model to camerabin.
Andrew den Exter [Fri, 7 Feb 2014 03:17:03 +0000 (13:17 +1000)]
Add meta-data mappings for GPS and camera make and model to camerabin.

This enables writing gps positioning information to captured images.

Change-Id: I663f7b94b5e6040865358df1ae45d67b73c54f92
Reviewed-by: Yoann Lopes <yoann.lopes@digia.com>
10 years agoFix gstreamer crash when meta-data is of incorrect type.
Andrew den Exter [Tue, 28 Jan 2014 01:28:19 +0000 (11:28 +1000)]
Fix gstreamer crash when meta-data is of incorrect type.

GStreamer tags are typed and the correct type must be used when inserting
a value into a GstTagList or subsequent merges or data accesses can crash
because of invalid casts.

Found while adding additional mappings for GPS values.

Change-Id: I95ab40a480a4685bf4e69064315557faa9de288e
Reviewed-by: Yoann Lopes <yoann.lopes@digia.com>
10 years agoReplace win32-g++ with mingw scope
Kai Koehne [Fri, 17 Jan 2014 13:41:08 +0000 (14:41 +0100)]
Replace win32-g++ with mingw scope

Commit 773dd01 in qtbase introduced a general mingw platform scope, which
is cleaner and more flexible than matching the spec name.

(see 278152fff for a similar commit in qtbase).

Change-Id: Ib46b9e83f690b0b26933b73764c7d7d4b031d792
Reviewed-by: Yoann Lopes <yoann.lopes@digia.com>
10 years agoQAudioOutput: Don't guess media role if one has not been provided in setCategory.
Robin Burchell [Thu, 16 Jan 2014 14:28:06 +0000 (15:28 +0100)]
QAudioOutput: Don't guess media role if one has not been provided in setCategory.

Trying to heuristically guess this kind of thing is almost always a bad idea.
Expect the creator of the output to explicitly tell us the category instead
of guessing.

This fixes QAudioOutput not respecting system volume on Sailfish.

Change-Id: If1d05192f513eb54fdfbd1df217286f329b2bfe8
Reviewed-by: Yoann Lopes <yoann.lopes@digia.com>
10 years agoQSoundEffect: Don't try guess a media role if one has not been provided.
Robin Burchell [Thu, 16 Jan 2014 14:28:02 +0000 (15:28 +0100)]
QSoundEffect: Don't try guess a media role if one has not been provided.

Trying to heuristically guess this kind of thing is almost always a bad idea.
Expect the creator of the output to explicitly tell us the category instead
of guessing.

Change-Id: I5f2988e2456685f3622e0ab136951b1742215f71
Reviewed-by: Yoann Lopes <yoann.lopes@digia.com>
10 years agoNormalize signal & slot signatures in connection
Thiago Macieira [Sun, 2 Feb 2014 22:07:07 +0000 (14:07 -0800)]
Normalize signal & slot signatures in connection

Profiling shows Qt Creator spends 2% of its load time normalizing

Change-Id: I1a4bef16be79ced35c47da865153ebe1bee22f9c
Reviewed-by: Yoann Lopes <yoann.lopes@digia.com>
10 years agoEnsure the backend has had its geometry updated.
Roger Maclean [Fri, 31 Jan 2014 19:58:54 +0000 (14:58 -0500)]
Ensure the backend has had its geometry updated.

When trying to play video in an overlay window, the video fails to
be displayed because everything that would cause updateGeometry to be
called on the backend has already occurred prior to the backend having
been created.

Change-Id: Ida3c8feea69b497a18e9f44d7143bed03380d6ae
Reviewed-by: Yoann Lopes <yoann.lopes@digia.com>
10 years agoDon't mirror the image from the camera unless it has been flipped
Andy Shaw [Fri, 31 Jan 2014 07:23:47 +0000 (08:23 +0100)]
Don't mirror the image from the camera unless it has been flipped

The camera itself can have a mode set that causes the image to be flipped
so instead of always mirroring the image that is taken from the camera we
check for the supported modes first and then check the mode and only
mirror if it is set. Otherwise we assume that it does not need
horizontally flipping but that it needs vertically flipping which seems to
be the standard for cameras on Windows.

[ChangeLog][QtMultimedia][Windows] Fixed the incorrect mirroring of the
image from the camera
Task-number: QTBUG-30365

Change-Id: I166b1f354e8d91c9a6c64f64164d782b52df98d8
Reviewed-by: Yoann Lopes <yoann.lopes@digia.com>
10 years agoExclude win32 plugins from WinRT build
Maurice Kalinowski [Tue, 28 Jan 2014 11:54:22 +0000 (12:54 +0100)]
Exclude win32 plugins from WinRT build

Change-Id: Icd07ad6805341f763a7abcfc8a24104c5d672ad7
Reviewed-by: Yoann Lopes <yoann.lopes@digia.com>
10 years agoMove win32 and Alsa audio backends into plugins.
Christian Strømme [Fri, 22 Nov 2013 23:14:15 +0000 (00:14 +0100)]
Move win32 and Alsa audio backends into plugins.

Change-Id: I9835cf5ee97900569f26421a19543b485e933051
Reviewed-by: Yoann Lopes <yoann.lopes@digia.com>
10 years agoAlsa: fix crash when detecting devices.
Yoann Lopes [Thu, 30 Jan 2014 15:32:53 +0000 (16:32 +0100)]
Alsa: fix crash when detecting devices.

Some old versions of Alsa crash when snd_device_name_hint(-1, ...) is
called. This patch works around the problem by iterating manually over all
the available sound cards.

Change-Id: Ic380a371acc15013d137553ff30d68bed5af664e
Reviewed-by: Christian Stromme <christian.stromme@digia.com>
10 years agoAndroid: add missing information in frames retrieved with QVideoProbe.
Yoann Lopes [Thu, 30 Jan 2014 13:01:55 +0000 (14:01 +0100)]
Android: add missing information in frames retrieved with QVideoProbe.

The number of bytes per line was missing.

Change-Id: I0afbdcfd6d7195b7beb3fd09f4ed262f756be848
Reviewed-by: Denis Kormalev <dkormalev@ics.com>
Reviewed-by: Christian Stromme <christian.stromme@digia.com>
10 years agoMerge "Merge remote-tracking branch 'origin/stable' into dev" into refs/staging/dev
Yoann Lopes [Thu, 30 Jan 2014 13:32:29 +0000 (14:32 +0100)]
Merge "Merge remote-tracking branch 'origin/stable' into dev" into refs/staging/dev

10 years agowhitespace fixes
Oswald Buddenhagen [Fri, 17 Jan 2014 18:27:51 +0000 (19:27 +0100)]
whitespace fixes

remove trailing spaces & expand tabs.

Change-Id: I05ef110abed90f13b47752760ffb4567a11a6a5e
Reviewed-by: Yoann Lopes <yoann.lopes@digia.com>
Reviewed-by: Tony Sarajärvi <tony.sarajarvi@digia.com>
10 years agoAndroid: fix crash in QAndroidCaptureSession.
Yoann Lopes [Tue, 21 Jan 2014 15:23:41 +0000 (16:23 +0100)]
Android: fix crash in QAndroidCaptureSession.

Don't try to apply video recording settings until a camera is actually
started.

Change-Id: I5348b91669835b9d776f56a3f49e3f8a11533d15
Reviewed-by: Christian Stromme <christian.stromme@digia.com>
10 years agoFix MSVC-warning about truncation of constant in tst_qaudiobuffer.cpp.
Friedemann Kleint [Fri, 24 Jan 2014 13:53:06 +0000 (14:53 +0100)]
Fix MSVC-warning about truncation of constant in tst_qaudiobuffer.cpp.

Change-Id: If9e239be38f8d15542ab9bf3a74bccf0a43b4e69
Reviewed-by: Yoann Lopes <yoann.lopes@digia.com>
10 years agoFix MSVC-warnings about unsafe bool operations in tst_qcamera.cpp.
Friedemann Kleint [Fri, 24 Jan 2014 13:49:08 +0000 (14:49 +0100)]
Fix MSVC-warnings about unsafe bool operations in tst_qcamera.cpp.

qglobal.h(501) : warning C4804: '-' : unsafe use of type 'bool' in operation
global/qglobal.h(501) : warning C4800: 'int' : forcing value to bool 'true' or 'false' (performance warning)
tst_qcamera.cpp(507) : see reference to function template instantiation 'T qAbs<bool>(const T &)' being compiled

Change-Id: Ifd467b5536a0d386f592ae339129b3ebfb7b8838
Reviewed-by: Yoann Lopes <yoann.lopes@digia.com>
10 years agoFix MSVC-warnings about unused variable meta in tst_qdeclarativevideooutput.cpp.
Friedemann Kleint [Fri, 24 Jan 2014 13:44:20 +0000 (14:44 +0100)]
Fix MSVC-warnings about unused variable meta in tst_qdeclarativevideooutput.cpp.

Change-Id: If324fd2e65acb7650b1d8dee4964a2c2bb17f876
Reviewed-by: Yoann Lopes <yoann.lopes@digia.com>
10 years agoMerge remote-tracking branch 'origin/release' into stable
Frederik Gladhorn [Mon, 27 Jan 2014 17:58:47 +0000 (18:58 +0100)]
Merge remote-tracking branch 'origin/release' into stable

Change-Id: If97b68b56071e241c659ddd231f28e433954d7be

10 years agoMerge remote-tracking branch 'origin/stable' into dev
Frederik Gladhorn [Mon, 27 Jan 2014 17:54:20 +0000 (18:54 +0100)]
Merge remote-tracking branch 'origin/stable' into dev

Change-Id: I83d589c55e8463cce23068dc81096aa66ec596a5

10 years agoFix sending End Of Stream on gst plugin
Daniel Nicoletti [Mon, 27 Jan 2014 13:44:22 +0000 (11:44 -0200)]
Fix sending End Of Stream on gst plugin

When streaming to gst a typefind operation
is performed which jumps around to find which
codec the file provides, this fix the call to
send an EOS before we try to read and not after
which causes confusion to gst.

Task-number: QTBUG-32963
Change-Id: I2658b6a4e960430c8ab422a3bee5e11956663116
Reviewed-by: Yoann Lopes <yoann.lopes@digia.com>
10 years agoFixes mediaplayer crashes on OSX
tom [Fri, 24 Jan 2014 10:54:43 +0000 (11:54 +0100)]
Fixes mediaplayer crashes on OSX

Fixes the "libqavfmediaplayer.dylib 0x0000000110fa7c8c -[AVFMediaPlayerSessionObserver unloadMedia]" crash on Macs.
The problem was: writing to memory that had already been released. If not sure, one should always check if the objects exist before deleting it.

Solution tested on OSX 10.7, 10.8, 10.9

[ChangeLog][qtmultimedia][avfmediaplayersession]

Task-number: QTBUG-34213
Change-Id: Iac108711851c348e96e73542b4e71653007eeb54
Reviewed-by: Andy Nichols <andy.nichols@digia.com>
10 years agoUpdate changelog for 5.2.1
Thiago Macieira [Wed, 22 Jan 2014 20:57:56 +0000 (12:57 -0800)]
Update changelog for 5.2.1

Change-Id: Id1df662afb2ec0e7eb7055bbc2c5c523a5bda125
Reviewed-by: Lars Knoll <lars.knoll@digia.com>
Reviewed-by: Yoann Lopes <yoann.lopes@digia.com>
10 years agoMerge remote-tracking branch 'origin/release' into stable
Frederik Gladhorn [Wed, 22 Jan 2014 10:36:50 +0000 (11:36 +0100)]
Merge remote-tracking branch 'origin/release' into stable

Change-Id: Ifcb0e0bac29c11980ea2a9d67b12e1b79c4bd9f6

10 years agoAndroid: fixed video rendering with multiple media players.
Yoann Lopes [Mon, 20 Jan 2014 16:20:26 +0000 (17:20 +0100)]
Android: fixed video rendering with multiple media players.

It seems all Android media players share the same video buffers, which
results in textures containing frames for the wrong media player.
When getting a new frame, we now copy it into a FBO in order to avoid
that another media player overwrites the frame being shown on screen.

Task-number: QTBUG-35868
Change-Id: I6701cf7368a3ef9e73d649c3ece1f206cafd5bb3
Reviewed-by: Christian Stromme <christian.stromme@digia.com>
10 years agoAllow plugins to override the QML VideoOutput type.
Andrew den Exter [Thu, 5 Dec 2013 05:38:14 +0000 (15:38 +1000)]
Allow plugins to override the QML VideoOutput type.

Move QDeclarativeVideoOutput to the private QtMultimediaQuickTools
library to make the QDeclarativeVideoOutputBackend interface
implementable by a plugin.

Change-Id: I763c483a1fc9ec56dc7b8be0bc71523f029a36ee
Reviewed-by: Yoann Lopes <yoann.lopes@digia.com>
10 years agoAndroid: fixes custom camera focus point.
Yoann Lopes [Wed, 15 Jan 2014 19:55:03 +0000 (20:55 +0100)]
Android: fixes custom camera focus point.

The custom focus point passed to the camera was in viewport orientation
but should be in sensor orientation. The two might differ.

Task-number: QTBUG-36208
Change-Id: Id272402090c2814e02abc527c0f6a6e932a60081
Reviewed-by: Christian Stromme <christian.stromme@digia.com>
10 years agoMerge remote-tracking branch 'origin/stable' into dev
Frederik Gladhorn [Fri, 17 Jan 2014 16:20:59 +0000 (17:20 +0100)]
Merge remote-tracking branch 'origin/stable' into dev

Conflicts:
.qmake.conf

Change-Id: Id367a610a3aefd288bfe287a3bf64606e582deb9

10 years agoAndroid: optimized NV21 top ARGB32 conversion.
Yoann Lopes [Tue, 14 Jan 2014 17:42:09 +0000 (18:42 +0100)]
Android: optimized NV21 top ARGB32 conversion.

Now based on fixed-point arithmetic and uses pre-generated lookup tables
for YUV coefficients and RGB clamping.
The new implementation is on average 2x-3x faster than the previous one
(tested on the Samsung Galaxy S4).

Change-Id: I1daf12f7f9b2f2334e90e0ede79e6d83800f1db6
Reviewed-by: Denis Kormalev <dkormalev@ics.com>
Reviewed-by: Christian Stromme <christian.stromme@digia.com>
10 years agoFix incorrect/missing application of recording settings in camerabin.
Andrew den Exter [Tue, 10 Dec 2013 07:20:59 +0000 (17:20 +1000)]
Fix incorrect/missing application of recording settings in camerabin.

Don't set profiles if no settings are specified.
Apply all settings before starting a pipeline as the mode can switch
without being restarted and incompatible video recording settings can
prevent the pipeline starting even in image capture mode.
Set audio encoding settings and encoder profiles if they are supplied.

Change-Id: I06febf977c2cae306383f9dbaae0f81f531b4757
Reviewed-by: Yoann Lopes <yoann.lopes@digia.com>
10 years agoFix writing orientation and date exif tags in camerabin.
Andrew den Exter [Thu, 5 Dec 2013 07:30:04 +0000 (17:30 +1000)]
Fix writing orientation and date exif tags in camerabin.

Orientation tags need to be transformed from the string tag returned
by gstreamer to the orientation in degrees.  Date tags need to be
inserted with gst_date_time_new_local_time.  Finally setting a tag
value shouldn't clear all other tags.

Change-Id: I28922148251084c12cf6c93d9b097fa5df41da9d
Reviewed-by: Yoann Lopes <yoann.lopes@digia.com>
10 years agoRemove workaround for resolved gstreamer bug.
Andrew den Exter [Tue, 10 Dec 2013 04:59:38 +0000 (14:59 +1000)]
Remove workaround for resolved gstreamer bug.

Reloading the capture pipeline before recording is unnecessary and
introduces a big pause. Don't do it.

https://bugzilla.gnome.org/show_bug.cgi?id=649832 was resolved in gstreamer 0.10.23

Change-Id: I0de02af52dcc193bce7a4e3e61407ae1c2d3818c
Reviewed-by: Yoann Lopes <yoann.lopes@digia.com>
10 years agoAllow the user to specify the viewfinder resolution instead of guessing
Andrew den Exter [Tue, 10 Dec 2013 04:25:47 +0000 (14:25 +1000)]
Allow the user to specify the viewfinder resolution instead of guessing

Guessing badly prevents the camerabin pipeline from loading at all and
the fallbacks used are not representive of the capabilities of most
cameras. So either stay out of the process and let gstreamer negotiate
a resolution if it can, or use a resolution supplied through the viewfinder
settings control by someone hopefully better informed.

Task-number: QTBUG-30842
Change-Id: Iec2dcc2476f38822f9e0d02301e46a1f49b7c6da
Reviewed-by: Yoann Lopes <yoann.lopes@digia.com>
10 years agoBump MODULE_VERSION to 5.2.2
Sergio Ahumada [Wed, 15 Jan 2014 21:58:16 +0000 (22:58 +0100)]
Bump MODULE_VERSION to 5.2.2

Change-Id: I662277a4ed9341f188e5e3f1abab50c6f5f85577
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
10 years agoAndroid: fixes some issues with JCamera.
Yoann Lopes [Wed, 15 Jan 2014 17:35:07 +0000 (18:35 +0100)]
Android: fixes some issues with JCamera.

- Quit the worker thread only when the worker is deleted. This makes
sure all events are processed before terminating the worker.
- Correctly cache the preview size even when it's an invalid one.

Task-number: QTBUG-36204
Change-Id: I76055984e8ece3f7f40dba7dd89d28a4faa1e72e
Reviewed-by: Denis Kormalev <dkormalev@ics.com>
Reviewed-by: Christian Stromme <christian.stromme@digia.com>
10 years agoFix build without Qml and Quick modules.
Yoann Lopes [Thu, 16 Jan 2014 14:20:59 +0000 (15:20 +0100)]
Fix build without Qml and Quick modules.

Conditionally enable auto-tests that depend on the Quick and Qml
modules.

Task-number: QTBUG-35911
Change-Id: I8b9d304ea630093d423b48a4ebc53ef6f4280244
Reviewed-by: Mitch Curtis <mitch.curtis@digia.com>
10 years agoFix build error on BlackBerry10
Wolfgang Bremer [Thu, 16 Jan 2014 11:45:01 +0000 (12:45 +0100)]
Fix build error on BlackBerry10

The variable type was changed to QStringRef but the
the conversion to QStringRef was left out.

Change-Id: I973b0eb5795fa7bcf89ceac809fb3ff607a85913
Reviewed-by: Peter Hartmann <phartmann@blackberry.com>
Reviewed-by: Jędrzej Nowacki <jedrzej.nowacki@digia.com>
10 years agoUse QStringRef instead of QString whenever possible.
Jędrzej Nowacki [Wed, 15 Jan 2014 15:56:12 +0000 (16:56 +0100)]
Use QStringRef instead of QString whenever possible.

That way we reduce count of temporary QString instances.

Change-Id: Id806c68ea616828c2355c07b8576616fa6a8da17
Reviewed-by: Yoann Lopes <yoann.lopes@digia.com>
10 years agoBlackBerry: Changed documentation
Bernd Weimer [Fri, 10 Jan 2014 09:32:22 +0000 (10:32 +0100)]
BlackBerry: Changed documentation

Changed platform notes title to be able to reference it from elsewhere.

Change-Id: I0edcebc6aa04e7a063cbe8b386ca8b38e0ae22a9
Reviewed-by: Thomas McGuire <thomas.mcguire@kdab.com>
10 years agoOnly acquire resources as required in gstreamer backend.
Andrew den Exter [Wed, 11 Dec 2013 04:29:57 +0000 (14:29 +1000)]
Only acquire resources as required in gstreamer backend.

Make resources required for capture optional and disable just the
capture features if they are not available, so the camera viewfinder
can be displayed and images captured without blocking the music
playback and the other way around.

Change-Id: Ic9692195156d994ccd4a911ae41d2242a00d575b
Reviewed-by: John Brooks <john.brooks@dereferenced.net>
Reviewed-by: Yoann Lopes <yoann.lopes@digia.com>
10 years agoFix playback with exotic gstreamer pipelines.
Andrew den Exter [Tue, 10 Dec 2013 07:59:52 +0000 (17:59 +1000)]
Fix playback with exotic gstreamer pipelines.

Extend the list of raw video formats, and allow the playbin flags to
be overridden by an environment variable when the default isn't
suitable for whatever reason.

Change-Id: I4c7d821b0ce29f5ad2dc0341e378ffd17c489e98
Reviewed-by: John Brooks <john.brooks@dereferenced.net>
Reviewed-by: Yoann Lopes <yoann.lopes@digia.com>
10 years agoFix recording settings being discarded by the Camera QML type.
Andrew den Exter [Tue, 10 Dec 2013 07:50:01 +0000 (17:50 +1000)]
Fix recording settings being discarded by the Camera QML type.

Query existing settings from the recorder instead of locally cached
settings as some other agent may have applied some settings separately
and those would otherwise be discarded.

Change-Id: I0ebeaf06c6f7306c5987aa269032842b538a6a8b
Reviewed-by: John Brooks <john.brooks@dereferenced.net>
Reviewed-by: Yoann Lopes <yoann.lopes@digia.com>
10 years agoFix configuration of camera settings in camerabin backend.
Andrew den Exter [Thu, 5 Dec 2013 06:17:19 +0000 (16:17 +1000)]
Fix configuration of camera settings in camerabin backend.

Enable gstphotography interfaces if the compile check passes, and
implement missing pieces of whitebalance and focus configuration.

Change-Id: Icd24dfd148204f8d8218176593c3120427a13e1e
Reviewed-by: John Brooks <john.brooks@dereferenced.net>
Reviewed-by: Yoann Lopes <yoann.lopes@digia.com>
10 years agoAllow the camerabin source selection to be overridden.
Andrew den Exter [Tue, 10 Dec 2013 03:11:07 +0000 (13:11 +1000)]
Allow the camerabin source selection to be overridden.

Prefer the default camera-source element if there is one or an element
identified by an environment variable to a static list of possible
elements which may not be appropriate for the target environment.

Change-Id: I53816c949307953780f9046eb11e09effe059be0
Reviewed-by: John Brooks <john.brooks@dereferenced.net>
Reviewed-by: Andy Nichols <andy.nichols@digia.com>
Reviewed-by: Yoann Lopes <yoann.lopes@digia.com>
10 years agodon't error out on static builds
Oswald Buddenhagen [Tue, 7 Jan 2014 15:54:44 +0000 (16:54 +0100)]
don't error out on static builds

commit daa8e22 made it actually work, but apparently forgot to re-enable
it.

Task-number: QTBUG-35843
Change-Id: Ib782634a4b1916e25e22f0b4c4f7bf42bf92b52f
Reviewed-by: David Faure <david.faure@kdab.com>
Reviewed-by: Yoann Lopes <yoann.lopes@digia.com>
10 years agoMerge remote-tracking branch 'origin/stable' into dev
Frederik Gladhorn [Fri, 10 Jan 2014 17:30:14 +0000 (18:30 +0100)]
Merge remote-tracking branch 'origin/stable' into dev

Change-Id: I7dc36a224702721b67ffa2cf7f9ce2a6b047f88e

10 years agoBlackBerry: Fixed volume setting
Bernd Weimer [Wed, 8 Jan 2014 15:09:13 +0000 (16:09 +0100)]
BlackBerry: Fixed volume setting

Mute status is taken into account when setting the volume.

Change-Id: Id2b9c7f6a1e5b6e4f5d4c82830544394c714b48f
Reviewed-by: Thomas McGuire <thomas.mcguire@kdab.com>
10 years agoMark tst_qcamerabackend test as insignificant on Mac OS X
Simon Hausmann [Wed, 8 Jan 2014 16:59:46 +0000 (17:59 +0100)]
Mark tst_qcamerabackend test as insignificant on Mac OS X

It has failed 6 times during qt5.git stable integrations since September 2013

See also QTBUG-36040

Change-Id: I6abd5b2723d2346a4831ab28fa040c14615148b0
Reviewed-by: Yoann Lopes <yoann.lopes@digia.com>
10 years agoAndroid: QVideoProbe support for camera
Denis Kormalev [Wed, 8 Jan 2014 13:06:59 +0000 (17:06 +0400)]
Android: QVideoProbe support for camera

QMediaVideoProbeControl sublclass added to capture service to make
QVideoProbe work with Android camera.

[ChangeLog][QtMultimedia][Android] QVideoProbe support for camera

Task-number: QTBUG-35416
Change-Id: I14d0a0e8abd14ee8f577e2901b976b8ed46eb320
Reviewed-by: Yoann Lopes <yoann.lopes@digia.com>
10 years agoMerge "Merge remote-tracking branch 'origin/stable' into dev" into refs/staging/dev
Frederik Gladhorn [Tue, 7 Jan 2014 14:15:15 +0000 (15:15 +0100)]
Merge "Merge remote-tracking branch 'origin/stable' into dev" into refs/staging/dev

10 years agoFix some typos in documentation.
Jeff Tranter [Thu, 2 Jan 2014 18:36:12 +0000 (13:36 -0500)]
Fix some typos in documentation.

Fix some spelling and grammatical errors in comments that show up in Qt documentation. No changes to code.

Change-Id: Ieb7be17bd1d50751f00620f7ac28d09355856ac0
Reviewed-by: Yoann Lopes <yoann.lopes@digia.com>
Reviewed-by: Sze Howe Koh <szehowe.koh@gmail.com>
10 years agoFix whitespace issue in the QVideoFrame auto test.
Christian Strømme [Fri, 3 Jan 2014 15:43:55 +0000 (16:43 +0100)]
Fix whitespace issue in the QVideoFrame auto test.

The test was failing because it was expecting a trailing whitespace
directly after the serialization of the meta-data map.

Change-Id: I62aa022492c721d408d23a98e8a3cfa173f45e68
Reviewed-by: Yoann Lopes <yoann.lopes@digia.com>
10 years agoMerge remote-tracking branch 'origin/stable' into dev
Frederik Gladhorn [Mon, 6 Jan 2014 15:30:18 +0000 (16:30 +0100)]
Merge remote-tracking branch 'origin/stable' into dev

Change-Id: Iefedab3cfc470affbd3118a4e9eb3c892945cd2a

10 years agoFixed some documentation for VideoOutput qml type.
Yoann Lopes [Mon, 16 Dec 2013 19:00:24 +0000 (20:00 +0100)]
Fixed some documentation for VideoOutput qml type.

mapPointToSource() and mapPointToSourceNormalized() were documented with
the wrong name.

Change-Id: Ia128f698a02f1c865bc27443ef2c6cef8fc7a720
Reviewed-by: Christian Stromme <christian.stromme@digia.com>
10 years agoPulseAudio: fix crash when failing to create a context.
Yoann Lopes [Fri, 13 Dec 2013 14:37:50 +0000 (15:37 +0100)]
PulseAudio: fix crash when failing to create a context.

Don't try to call a function on a null PulseAudio context.
If pa_context_new() fails, we now try again to connect to the pulse
audio daemon later.

Task-number: QTBUG-35456
Change-Id: I0b848d3f25f57651ab31b9eca7ceb1bc9df2f682
Reviewed-by: Christian Stromme <christian.stromme@digia.com>
10 years agoGStreamer: add missing breaks in QGstreamerRecorderControl.
Yoann Lopes [Tue, 10 Dec 2013 16:38:45 +0000 (17:38 +0100)]
GStreamer: add missing breaks in QGstreamerRecorderControl.

Task-number: QTBUG-34914
Change-Id: I8237201cb656a3cde23e3d750939fe11e35519cd
Reviewed-by: Robin Burchell <robin+qt@viroteck.net>
10 years agoCorrect QSoundEffect::supportedMimeTypes() documentation.
Mitch Curtis [Thu, 2 Jan 2014 09:25:04 +0000 (10:25 +0100)]
Correct QSoundEffect::supportedMimeTypes() documentation.

Change-Id: I154b124949ee4f07ea413d8cdb419fcc08cb8324
Reviewed-by: Topi Reiniö <topi.reinio@digia.com>
10 years agoMerge remote-tracking branch 'origin/stable' into dev
Frederik Gladhorn [Mon, 23 Dec 2013 14:37:30 +0000 (15:37 +0100)]
Merge remote-tracking branch 'origin/stable' into dev

Change-Id: I0429a7186bef08918b777d6aa662685c57bad091

10 years agoAndroid: camera moved to a dedicated thread
Denis Kormalev [Mon, 16 Dec 2013 08:54:17 +0000 (12:54 +0400)]
Android: camera moved to a dedicated thread

Actual camera work moved to JCameraWorker which lives in dedicated
thread. JCamera now acts as proxy calling JCameraWorker methods with
invokeMethod (when it is needed).

[ChangeLog][QtMultimedia][Android] camera operations moved to a
dedicated thread

Task-number: QTBUG-35564
Change-Id: Ie4edcbf0869d56b0fef4ad0c820450cc77657fdd
Reviewed-by: Yoann Lopes <yoann.lopes@digia.com>
10 years agoMerge remote-tracking branch 'origin/stable' into dev
Frederik Gladhorn [Mon, 16 Dec 2013 14:36:55 +0000 (15:36 +0100)]
Merge remote-tracking branch 'origin/stable' into dev

Change-Id: I4fea8b03bc8baaa97e95413f05d13f0f505705d3

10 years agoAndroid: fix camera preview
Denis Kormalev [Thu, 5 Dec 2013 13:09:07 +0000 (17:09 +0400)]
Android: fix camera preview

At some(?) devices we can't rely on one shot preview callback because
it receives data only after we start new previewing session. And this
cause situation when imageCaptured signal is never emitted.
This fix applies preview callback with already allocated buffers and
collects all preview images in these buffers. When we capture image -
we can simply fetch last preview image (if there was any) from c++ part.

Task-number: QTBUG-34993
Change-Id: I608750c344ca3c089f4673df4907e0f47e57e2ba
Reviewed-by: Yoann Lopes <yoann.lopes@digia.com>
10 years agoWMF: remove dead code.
Yoann Lopes [Mon, 9 Dec 2013 13:09:40 +0000 (14:09 +0100)]
WMF: remove dead code.

Change-Id: Ib3b595263e64336cc5d0482edd890e7b4e534927
Reviewed-by: Christian Stromme <christian.stromme@digia.com>
10 years agoWMF: fix some crashes.
Yoann Lopes [Thu, 5 Dec 2013 14:55:06 +0000 (15:55 +0100)]
WMF: fix some crashes.

Task-number: QTBUG-30827
Change-Id: Iafc53f7095ad9c086b3982afb2af045c54497dc9
Reviewed-by: Christian Stromme <christian.stromme@digia.com>
10 years agoAndroid: automatically deploy playlist plugins.
Yoann Lopes [Mon, 9 Dec 2013 16:07:27 +0000 (17:07 +0100)]
Android: automatically deploy playlist plugins.

Include the playlistformats directory for automatic plugin deployment.

Change-Id: Ie61a4b1c1637a493e1bdb7354b33060728ccabda
Reviewed-by: Christian Stromme <christian.stromme@digia.com>
10 years agoAndroid add support for qrc in mediaplayer.
Christian Strømme [Thu, 28 Nov 2013 14:07:21 +0000 (15:07 +0100)]
Android add support for qrc in mediaplayer.

[ChangeLog][QtMultimedia][Android] Enable mediaplayer to read files
from the Qt Resource system.

Task-number: QTBUG-31422

Change-Id: Iaaefb35566b623b78b9f8aa22daf6ac92fb35e67
Reviewed-by: Yoann Lopes <yoann.lopes@digia.com>
10 years agoUse the backend to notify the QCamera state changes.
Yoann Lopes [Thu, 5 Dec 2013 16:47:49 +0000 (17:47 +0100)]
Use the backend to notify the QCamera state changes.

We were emitting the stateChanged() signal no matter what was actually
done by the backend. QCamera now emits this signal only if the backend
actually changed the state.

Task-number: QTBUG-35070
Change-Id: I9f32361cd815dbcc366ad30033692f9ae732ec46
Reviewed-by: Christian Stromme <christian.stromme@digia.com>
10 years agoAndroid: fix camera viewfinder orientation.
Yoann Lopes [Fri, 29 Nov 2013 16:16:44 +0000 (17:16 +0100)]
Android: fix camera viewfinder orientation.

The camera sensor on Android devices might be in a different orientation
than the device natural orientation. There is no API in Qt to know about
the camera orientation, so correcting the viewfinder orientation is not
possible without making guesses. This patch makes sure the viewfinder
orientation always matches the device natural orientation. For example,
if the camera is mounted in landscape, and the device natural
orientation is portrait, the viewfinder will automatically be rotated 90
degrees counter-clockwise.

Task-number: QTBUG-35086
Change-Id: Ia890872971d72657debe709f61edba27d09dec65
Reviewed-by: Christian Stromme <christian.stromme@digia.com>
10 years agoMerge remote-tracking branch 'origin/stable' into dev
Frederik Gladhorn [Thu, 5 Dec 2013 17:45:33 +0000 (18:45 +0100)]
Merge remote-tracking branch 'origin/stable' into dev

Change-Id: I9c1abddf20e85cc0f29f2da26c398b7180e4f479