summaryrefslogtreecommitdiffstats
Commit message (Collapse)AuthorAgeFilesLines
* Minor refactor of built-in QSGVideoNodes.v5.5.0-beta1Yoann Lopes2015-04-3014-285/+291
| | | | | | | | | | | - Load shader source from resource files. - Correctly report material types: each material can use different shaders depending on the video pixel format but it was reporting a unique material type. This was causing the node to keep using the same shader even if its pixel format changed. Change-Id: Ib903ecd6e7dd1dd56d7cefe255ab7049933df17d Reviewed-by: Gunnar Sletta <gunnar@sletta.org>
* winrt: fix camera sample queue thread safetyPeng Wu2015-04-231-5/+18
| | | | | | | | | | | Replace sample buffer QVector with C array to avoid reallocations. The resource needs to be protected, so use atomic indexes to prevent writing into the same array element that is being read. Task-number: QTBUG-45667 Change-Id: Ifd30dd128765ea4794fe8614f25ef596bba891ee Reviewed-by: Andrew Knight <qt@panimo.net> Reviewed-by: Maurice Kalinowski <maurice.kalinowski@theqtcompany.com>
* Remove warning about missing qmake variable on Android.Christian Strømme2015-04-221-1/+1
| | | | | | | gstreamer on Android is not supported, so we don't need to check for it. Change-Id: I7ccde2b9878f9f435828195a5ac1b76a9a6985d1 Reviewed-by: Yoann Lopes <yoann.lopes@theqtcompany.com>
* winrt: fix camera preview on Lumia 630Peng Wu2015-04-161-1/+41
| | | | | | | | | | | | Certain devices give black frames when blitting to the target texture for image preview. However, a workaround has been found that simply mapping the buffer forces the frames to be rendered properly. As this degrades performance on devices with hardware buffers, a blacklist is introduced to specify which devices require this workaround. Task-number: QTBUG-44838 Change-Id: I137a1dc4e5126e7cf9ee00cb2d7e7722bf917efa Reviewed-by: Andrew Knight <qt@panimo.net>
* Update plugins.qmltypesYoann Lopes2015-04-151-5/+74
| | | | | | Change-Id: Iaa05756066c8040fe110707eee6b7d71b2a1aa84 Task-number: QTBUG-44300 Reviewed-by: Alex Blasche <alexander.blasche@theqtcompany.com>
* [QSoundBuffer] Replace isReady() with state() statesKonstantin Ritt2015-04-156-18/+36
| | | | | | | | | The two-state "isReady" is not enough for checking if loading was already requested. This also makes it abvious we're accepting load() after error. Change-Id: I8181f99e8b36be484ec791862941b5b2ec78eb1f Reviewed-by: Yoann Lopes <yoann.lopes@theqtcompany.com>
* Update copyright headersLiang Qi2015-04-152-14/+14
| | | | | | | Just do bbfccc713546f9e7341fbe1af7482cafbdc4ea25 for new added files. Change-Id: Ibbcd515d5e7577a8a3b33163094f9153072c8846 Reviewed-by: Yoann Lopes <yoann.lopes@theqtcompany.com>
* Merge remote-tracking branch 'origin/5.4' into 5.5Liang Qi2015-04-1540-531/+869
|\ | | | | | | | | | | | | | | Conflicts: src/multimedia/playback/playlistfileparser.cpp src/plugins/windowsaudio/qwindowsaudiodeviceinfo.cpp Change-Id: I52950def2b8283ae15797d05d4ead6a1256eba19
| * DirectShow: correctly update camera list.Yoann Lopes2015-04-144-77/+66
| | | | | | | | | | | | | | | | | | | | | | | | | | 8923c0ff fixed the list not being updated after plugging/unplugging a camera from the system. However, it was only a partial fix affecting only QCameraInfo::availableCameras(). DSVideoDeviceControl was still internally keeping a list of cameras that was never updated, causing the QCamera constructor to not take into account new or removed cameras. Change-Id: Ie5e79c46002017b1e85bfc53c6391a2a747361a0 Task-number: QTBUG-39708 Reviewed-by: Christian Stromme <christian.stromme@theqtcompany.com>
| * WindowsAudio: improve supported formats detection.Yoann Lopes2015-04-149-247/+293
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | QAudioDeviceInfo::isFormatSupported() now tries to open the device with that format to theck if it is supported. We were before simply checking that its parameters were included in the list of supported values, which might be incomplete. In addition, since the Windows API to check device capabilities is quite limited, we now test additional common formats and add them to the supported formats if the device can open them. Task-number: QTBUG-42648 Change-Id: Idd0affbd6d91d4fd027a6a4c86c2f3fe008a118f Reviewed-by: Christian Stromme <christian.stromme@theqtcompany.com>
| * Fix incorrect signal/slot connection in QDeclarativeTorch.Yoann Lopes2015-04-141-1/+1
| | | | | | | | | | Change-Id: Id8cb716e25a2c08111f99112fbf319fb8331d64d Reviewed-by: Christian Stromme <christian.stromme@theqtcompany.com>
| * WMF: fix reported sample type of 8-bit audio formats.Yoann Lopes2015-04-142-12/+18
| | | | | | | | | | | | | | | | | | | | Always report 8-bit PCM data as unsigned integer. Even though there's no API to actually know that, it's standard on Windows. 8-bit is unsigned and 16-bit is signed. Task-number: QTBUG-45540 Change-Id: I4a3c09084de688ea7afc3bc147508184fb582224 Reviewed-by: Christian Stromme <christian.stromme@theqtcompany.com>
| * CoreAudio: fix crash on iOS 5.Yoann Lopes2015-04-141-29/+86
| | | | | | | | | | | | | | | | | | | | The plugin was using some iOS 6 APIs, even though we're supposed to support iOS 5. Add version checks for all these APIs. Task-number: QTBUG-44790 Change-Id: I9268963b7d3601222451ce0c948c2d024d37c86f Reviewed-by: Christian Stromme <christian.stromme@theqtcompany.com>
| * AVFoundation: fix QCameraInfo::availableCameras() on OS X.Yoann Lopes2015-04-104-38/+59
| | | | | | | | | | | | | | | | | | | | Cameras can be dynamically added or removed on OS X. Make sure the cache is updated often enough so QCameraInfo::availableCameras() return an up to date list. Task-number: QTBUG-39708 Change-Id: Id806d52278e1a29163fcc6707da7f86c0f3e7c0d Reviewed-by: Timur Pocheptsov <Timur.Pocheptsov@digia.com>
| * Updated plugins.qmltypes.Yoann Lopes2015-04-091-19/+241
| | | | | | | | | | | | | | Task-number: QTBUG-44300 Change-Id: Id6c8dce17e03c79f29581bd49be184a8d3e7f21b Reviewed-by: Kai Koehne <kai.koehne@theqtcompany.com> Reviewed-by: Alex Blasche <alexander.blasche@theqtcompany.com>
| * Make the QtMultimedia singleton type a QObject.Yoann Lopes2015-04-093-43/+43
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | It was a QJSValue for the sake of being as lightweight as possible and because we don't actually need any of the QObject features for that type in its current state. However, this implies that type information is not available at runtime. This is a problem for qmlplugindump which currently crashes because it always expects every QML type to have an associated meta object. We can safely make that type a QObject since it doesn't affect source compatibility in any way. This type was bound to become a QObject at some point anyway. Task-number: QTBUG-44299 Change-Id: I2d9b874f15ffc94ed95ef74fadc3b1fd193fe1ef Reviewed-by: Alex Blasche <alexander.blasche@theqtcompany.com>
| * Fix type of Camera's errorCode property.Yoann Lopes2015-04-081-1/+1
| | | | | | | | | | | | | | It's supposed to be of type enumeration (Error) and not QString. Change-Id: Ia3ce112efa3e87614c79b89d05313b0faa557289 Reviewed-by: Andrew Knight <qt@panimo.net>
| * Fix compile issue when building with -no-widgetsAndy Shaw2015-04-073-7/+6
| | | | | | | | | | Change-Id: I49a9aa684b0dfbe0e3d9e576aad06d65d6c3ecdd Reviewed-by: Yoann Lopes <yoann.lopes@theqtcompany.com>
| * Fix audioengine example.Yoann Lopes2015-04-075-29/+16
| | | | | | | | | | | | | | | | | | | | | | | | - Add missing audio files - Fix 'Unable to assign double to QVector3D' warning - Don't show decimal part of the volume Task-number: QTBUG-41841 Task-number: QTBUG-44304 Change-Id: Ie24284242bbac0d10bd85841932c506d7634a514 Reviewed-by: Venugopal Shivashankar <venugopal.shivashankar@digia.com> Reviewed-by: Christian Stromme <christian.stromme@theqtcompany.com>
| * Fix BlackBerry -qtnamespace buildSergio Martins2015-04-011-0/+2
| | | | | | | | | | | | Change-Id: I717dad59a466cb7a7480bc772d8f6308ca669d54 Task-number: QTBUG-43569 Reviewed-by: Rafael Roquetto <rafael.roquetto@kdab.com>
| * WMF: don't resume playback after doing a seek while paused.Andy Shaw2015-03-311-2/+9
| | | | | | | | | | | | | | Task-number: QTBUG-32746 Change-Id: I5a9ee96324e0ddc65311f47dc887bcb91b036fd2 Reviewed-by: Andy Shaw <andy.shaw@digia.com> Reviewed-by: Yoann Lopes <yoann.lopes@theqtcompany.com>
| * Add missing documentation for AudioSample::source.Yoann Lopes2015-03-241-0/+5
| | | | | | | | | | Change-Id: Iabfb7749bf42413fc19b53b907027caad931092c Reviewed-by: Christian Stromme <christian.stromme@theqtcompany.com>
| * GStreamer: don't use ximagesink in QGstreamerVideoWidget.Yoann Lopes2015-03-241-3/+0
| | | | | | | | | | | | | | | | | | | | | | | | | | | | When xvimagesink is not available, we were falling back to ximagesink. That element doesn't provide some important features: it doesn't scale frames to the window size and doesn't support brightness, contrast, hue and saturation adjustments. That kind of makes it useless, at least on its own. We would need to use at least a 'videoscale' element together with it to have it working properly. We're better off letting QVideoWidget fall back to QVideoRendererControl when xvimagesink is not available. Change-Id: Ic8c62fbefa3227430e3bae24630c8b3944aabb47 Reviewed-by: Christian Stromme <christian.stromme@theqtcompany.com>
| * WMF: report the surface's supported formats in the correct order.Yoann Lopes2015-03-241-2/+5
| | | | | | | | | | | | | | | | | | QAbstractVideoSurface::supportedFormats() returns the formats in descending order of preference while IMFMediaTypeHandler expects the list to be in ascending order. Change-Id: I0ecb5a3b228c0cad78c1a84091e3c3cf272f7ebc Reviewed-by: Christian Stromme <christian.stromme@theqtcompany.com>
| * Fix order of QSGVideoNode_RGB's supported formats.Yoann Lopes2015-03-181-1/+1
| | | | | | | | | | | | | | | | RGB565 should not be the first pick. As a matter of fact it should be the last pick. Change-Id: I4b96fb02093e70d9c642efd79c48358ec7a664b0 Reviewed-by: Christian Stromme <christian.stromme@theqtcompany.com>
| * WMF: fix RGB24 format matching.Yoann Lopes2015-03-181-1/+2
| | | | | | | | | | | | | | | | | | MFVideoFormat_RGB24 has a BGR layout and should therefore be matched to QVideoFrame::Format_BGR24, not Format_RGB24. Task-number: QTBUG-42323 Change-Id: I1749b575b1738168e3d3c0d055dee10f6d870c0c Reviewed-by: Christian Stromme <christian.stromme@theqtcompany.com>
| * Use proper d_ptr for QPlaylistFileParser.Yoann Lopes2015-03-182-21/+15
| | | | | | | | | | | | Task-number: QTBUG-42473 Change-Id: Iff8f14ed6ab99c8e7844b9e43009b82b442f5238 Reviewed-by: Christian Stromme <christian.stromme@theqtcompany.com>
* | Camera flash control - version for iOS/OS XTimur Pocheptsov2015-04-135-2/+317
| | | | | | | | | | | | | | | | | | | | AVCaptureDevice has API to work with camera flash on both iOS and OS X (quite limited on OS X though) - so camera flash control can be implemented in AVFoundation plugin. Task-number: QTBUG-37996 Change-Id: Ie9aaed09a709e7d09ccc1cedded93a69fea93975 Reviewed-by: Yoann Lopes <yoann.lopes@theqtcompany.com>
* | [QtAudioEngine] Fix C&P typo in the SoundInstance docsKonstantin Ritt2015-04-131-2/+2
| | | | | | | | | | Change-Id: Iffe26a13f58c1e4cffe81099d5f0ef204f582999 Reviewed-by: Yoann Lopes <yoann.lopes@theqtcompany.com>
* | [QDeclarativeSound] Pass QString by const-refKonstantin Ritt2015-04-132-2/+2
| | | | | | | | | | | | Change-Id: Ic600e62420c2e3ccc66f037e0fe44374e505c0d1 Reviewed-by: Sérgio Martins <sergio.martins@kdab.com> Reviewed-by: Yoann Lopes <yoann.lopes@theqtcompany.com>
* | [AudioEngine] Minor code clean-upKonstantin Ritt2015-04-132-144/+146
| | | | | | | | | | | | | | | | Move StaticSoundBufferAL declaration to .h file and replace inherits("StaticSoundBufferAL") check with qobject_cast. Change-Id: Icedc2796cf31b3a92335112a77cac24a5a34ac15 Reviewed-by: Yoann Lopes <yoann.lopes@theqtcompany.com>
* | [AudioEngine] Do not crash on destruction after sample loading errorKonstantin Ritt2015-04-131-4/+19
| | | | | | | | | | | | | | | | | | m_sampleLoader must be destroyed AFTER releasing the buffers it holds. Also properly release sample on error and be safer while destroying the buffer. Change-Id: I5e39c6c815b8760f72cc5fdc61fad020d3cd1cc1 Reviewed-by: Yoann Lopes <yoann.lopes@theqtcompany.com>
* | [AudioEngine] Minor improvement to the docu snippetsKonstantin Ritt2015-04-132-2/+4
| | | | | | | | | | | | | | | | | | | | Without mentioning the playType property, it is unclear for the user not familiar with AudioEngine why there are several PlayVariation-s binded to a single Sound element. Also fix a simply typo. Change-Id: Ie6b4bff759318c70c94e75797cc6991cb9b918ca Reviewed-by: Yoann Lopes <yoann.lopes@theqtcompany.com>
* | [DirectShow] Fix potential memory access violationKonstantin Ritt2015-04-131-0/+3
| | | | | | | | | | Change-Id: I5da495d255e6fdd3a70c1ed486afb61f157c923e Reviewed-by: Yoann Lopes <yoann.lopes@theqtcompany.com>
* | [DirectShow] Fix potention undefined behavior on destructionKonstantin Ritt2015-04-134-3/+8
| | | | | | | | | | | | | | | | | | The exact warning is: > deleting object of polymorphic class type which has non-virtual destructor might cause undefined behavior Change-Id: I8f259def3f1f7f776fb31ace9dfcc7145426f5c0 Reviewed-by: Yoann Lopes <yoann.lopes@theqtcompany.com>
* | Made audio output example easier to understand. No real code changesd3fault2015-04-102-8/+10
| | | | | | | | | | | | | | | | | | | | Maybe it's just me, but every time I try to read the "toggleMode" method in the audio output example, I get confused on whether I'm switching to/ from push/pull mode, and even what pushing and pulling entails. The name of the push timer also seemed backwards (which added to the confusion). Change-Id: I5ff7d18f72490c22b91a948ad7513b402a01c5e4 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-0725-165/+304
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 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>
* | Fix debug stream operators.Friedemann Kleint2015-04-079-125/+151
| | | | | | | | | | | | | | | | | | | | - Use QDebugStateSaver to restore space setting in stream operators instead of returning dbg.space() which breaks formatting on streams that already have nospace() set. - Fix some single character string constants, streamline code. Change-Id: I18ae7324b172ea801aa9b5fe56ddf6fe527fdde9 Reviewed-by: Yoann Lopes <yoann.lopes@theqtcompany.com>
* | Fix incorrect warning in QML AudioEngine.Yoann Lopes2015-04-071-0/+1
| | | | | | | | | | | | | | | | We need to do an early return when an AudioCategory is successfully added to an AudioEngine, otherwise a warning is incorrectly shown. Change-Id: If310c694a703242aff7f1c5ae04ad3e40c3f1acd Reviewed-by: Christian Stromme <christian.stromme@theqtcompany.com>
* | GStreamer 1.0: fix frames being presented too many times.Yoann Lopes2015-04-071-9/+8
| | | | | | | | | | | | | | | | | | | | | | Presenting a frame originates from a gstreamer thread, we block there until the frame is actually presented in the main thread. The problem is that it was presented over and over again until the gstreamer thread was unblocked. Make sure a given frame is presented only once. Change-Id: I46f246740313968637add802f509ebffcc5c19b8 Reviewed-by: Andrew den Exter <andrew.den.exter@qinetic.com.au>
* | Don't error out when presenting empty frames in QSGVideoItemSurface.Yoann Lopes2015-04-071-4/+0
| | | | | | | | | | | | | | | | | | There's no good reason to do so. Backends can actually provide empty frames, for example when flushing the pipeline or after stopping playback. Change-Id: I687c12b667e31b25e91c3201f59c52a8969d8e05 Reviewed-by: Andrew den Exter <andrew.den.exter@qinetic.com.au>
* | GStreamer: implement unlock() in QGstVideoRendererSink.Yoann Lopes2015-04-074-1/+46
| | | | | | | | | | | | | | | | | | | | | | | | There are cases where blocking operations happening in the video sink need to be unblocked, that's why GstBaseSink has an unlock() virtual function. Since our custom video sink blocks when starting and when rendering a frame (while waiting for the main thread to actually do these operations), we need to implement the unlock() function in order to unblock these operations when requested by GstBaseSink. Change-Id: I5cb19ea689e655f572729d931cefec8a4266c94e Reviewed-by: Andrew den Exter <andrew.den.exter@qinetic.com.au>
* | GStreamer 1.0: show preroll frames.Yoann Lopes2015-04-072-3/+5
| | | | | | | | | | | | | | | | | | | | We need to implement the show_frame() function from GstVideoSink, which handles both preroll and normal frames, instead of just GstBaseSink.render(), which is called only for normal frames. This was changed for GStreamer 0.10 by 3b20608f. Change-Id: I4823a575d499cd0d6f9f4cb62e0420e070a05214 Reviewed-by: Andrew den Exter <andrew.den.exter@qinetic.com.au>
* | Remove stray <QtNetwork> includesAndrew Knight2015-03-305-4/+9
| | | | | | | | | | | | | | | | Module includes slow down the build when PCH is disabled, so don't use them. Change-Id: Ic0bf0d938ef06dea9dba6897df592311230a6529 Reviewed-by: Yoann Lopes <yoann.lopes@theqtcompany.com>
* | Fix QNX 6.6 build by using qSqrt() and qLn()Sergio Martins2015-03-281-2/+2
| | | | | | | | | | | | | | | | spectrumanalyser.cpp: In member function 'void SpectrumAnalyserThread::calculateSpectrum(const QByteArray&, int, int)': spectrumanalyser.cpp:138:59: error: 'sqrt' was not declared in this scope Change-Id: Ib43c693d73d2342059092094cfc3f48a0f73b4bc Reviewed-by: Giuseppe D'Angelo <giuseppe.dangelo@kdab.com>
* | Fix inconsistent overrides. [-Winconsistent-missing-override]Sergio Martins2015-03-222-16/+16
| | | | | | | | | | Change-Id: Icb3e2a640c122424704a8e4b10172ecc7602845a Reviewed-by: Marc Mutz <marc.mutz@kdab.com>
* | Add NV12/NV21 support into SG videonode.Timur Pocheptsov2015-03-204-62/+177
| | | | | | | | | | | | | | | | | | Add new fragment shaders and update declarative render (video node) to support NV12/NV21 pixel format. Task-number: QTBUG-45021 Change-Id: I5d52007f0da56165752268d06efca156f7496b42 Reviewed-by: Yoann Lopes <yoann.lopes@theqtcompany.com>
* | AVFCameraViewfinderSettings - add NV12 formatTimur Pocheptsov2015-03-203-29/+94
| | | | | | | | | | | | | | | | | | Add QVideoFrame::Format_NV12 (AVFoundation has kCVPixelFormatType_420YpCbCr8BiPlanarVideoRange and kCVPixelFormatType_420YpCbCr8BiPlanarFullRange). Report it (set it) only if it's supported by renderer's surface. Add bi-planar format support into CVPixelBufferVideoBuffer. Change-Id: Ibc1c2be056bddf5cf3b595570fc40c626ee3ccf5 Reviewed-by: Yoann Lopes <yoann.lopes@theqtcompany.com>
* | Fix WinRT Audio elements cannot play Qt resouce audio filesPeng Wu2015-03-171-1/+1
| | | | | | | | | | | | | | | | | | | | URL argument of Windows media API SetSourceFromByteStream can not be empty. Initial proper value for playing audio stream case. Task-number: QTBUG-42263 Change-Id: If0bb44b60d517228bfe8b6cb30afeeb4a8ac62d3 Reviewed-by: Andrew Knight <qt@panimo.net> Reviewed-by: Yoann Lopes <yoann.lopes@theqtcompany.com>