summaryrefslogtreecommitdiffstats
Commit message (Collapse)AuthorAgeFilesLines
* Update dependencies on '6.5.2' in qt/qtmultimediav6.5.26.5.2Qt Submodule Update Bot2023-07-071-4/+4
| | | | | Change-Id: I0b1bc99cb4280d492eb6ca261b0f0dd421b602cb Reviewed-by: Qt Submodule Update Bot <qt_submodule_update_bot@qt-project.org>
* Update dependencies on '6.5.2' in qt/qtmultimediaQt Submodule Update Bot2023-06-301-4/+4
| | | | | Change-Id: I0a9826ec37fc5d02cfcb8b454dd4a7b3e8691b15 Reviewed-by: Qt Submodule Update Bot <qt_submodule_update_bot@qt-project.org>
* Update dependencies on '6.5.2' in qt/qtmultimediaQt Submodule Update Bot2023-06-211-4/+4
| | | | | Change-Id: Ia5a4ea3b0f722130f572effb8ccfbce2ccdcea01 Reviewed-by: Qt Submodule Update Bot <qt_submodule_update_bot@qt-project.org>
* Update dependencies on '6.5.2' in qt/qtmultimediaQt Submodule Update Bot2023-06-201-4/+4
| | | | | Change-Id: Icb67fdc113848be8035e85c0dcab99ec9d16d341 Reviewed-by: Qt Submodule Update Bot <qt_submodule_update_bot@qt-project.org>
* Update dependencies on '6.5.2' in qt/qtmultimediaQt Submodule Update Bot2023-06-171-4/+4
| | | | | Change-Id: I9ffa61e35c878e5abefcf81c6a358fb6ede917ef Reviewed-by: Qt Submodule Update Bot <qt_submodule_update_bot@qt-project.org>
* Update dependencies on '6.5' in qt/qtmultimediaQt Submodule Update Bot2023-06-131-4/+4
| | | | | Change-Id: Ia1c7ebc07289a1412536df4869750fcd7bf35ccb Reviewed-by: Qt Submodule Update Bot <qt_submodule_update_bot@qt-project.org>
* Fix namespace build on Windows for IAudioClient3Pavel Dubsky2023-06-131-1/+1
| | | | | | | | | | | | | Forward declaration of IAudioClient3 interface was placed inside Qt namespace declaration that failed non-empty namespace builds. This fix moves the forward declaration outside Qt namespace. Task-number: QTBUG-114442 Change-Id: Ia02db31aaa20002bf7b44fe47d71ecb02b72246a Reviewed-by: Jøger Hansegård <joger.hansegard@qt.io> Reviewed-by: Lars Knoll <lars@knoll.priv.no> (cherry picked from commit 44918d9966c65a39ea988bf4aa7f64246da3d820) Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
* Update dependencies on '6.5' in qt/qtmultimediaQt Submodule Update Bot2023-06-121-4/+4
| | | | | Change-Id: I6bf6975b709a26577c9ceefde893cddc99c9384f Reviewed-by: Qt Submodule Update Bot <qt_submodule_update_bot@qt-project.org>
* Replace QComPtr with Microsoft's WRL::ComPtr in QtMultimediaJøger Hansegård2023-06-1226-335/+278
| | | | | | | | | | | | | | This way we can rely on a 'standard' implementation that behaves the same way as other COM smart pointers, and we don't have to maintain our own implementation any longer. This also fixes a latent bug that could cause double release when facing circular dependencies between COM objects. Change-Id: I339faac2f5045c0379b61ad72be033510eca4958 Reviewed-by: Lars Knoll <lars@knoll.priv.no> Reviewed-by: Pavel Dubsky <pavel.dubsky@qt.io> (cherry picked from commit a93ee88315035c366d87e1bc2e07ddd24e67ffb9)
* Prettify calling of QMediaDevice signalsArtem Dyomin2023-06-1211-60/+30
| | | | | | | | | | | | | | | | | | | The idea is inheriting QPlatformMediaDevices from QObject and connect it to QMediaDevice instances instead of manual collecting and managing pointers. Advantages: - avoid UB behavior with static object destruction order in case a user makes any QMediaDevices static. - align the signals parent: send singals from the QMediaDevice instance Task-number: QTBUG-110071 Change-Id: I7c30694210864ff8c6c90c7299abdbf383f398fa Reviewed-by: Pavel Dubsky <pavel.dubsky@qt.io> Reviewed-by: Lars Knoll <lars@knoll.priv.no> Reviewed-by: Jøger Hansegård <joger.hansegard@qt.io> (cherry picked from commit a9471cbff3bf9d978620e6e962ea196acdd8dc0b) Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
* Improve v4l2 cameras update logicArtem Dyomin2023-06-123-30/+52
| | | | | | | | | | | The idea is to get rid of extra videoInputsUpdated signals, which was emitted whenever the '/dev' directory is changed. Task-number: QTBUG-110071 Change-Id: Ic2675db05eda05ac8355bfca77438bf09cb863bf Reviewed-by: Lars Knoll <lars@knoll.priv.no> (cherry picked from commit a8553a1f7f6e434688c162487e60d6a65e28b728) Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
* Introduce a QComPtr friendly factory function for COM objectsJøger Hansegård2023-06-124-3/+12
| | | | | | | | | | | | | | | | In QtMultimedia, some COM objects are constructed with `new`, and they are constructed with a reference count of 1. By introducing a factory function for COM objects, we avoid the need to think too much when creating COM objects without using CoCreateInstance. This pattern is in line with Windows Runtime Library's WRL::Make and WinRT's winrt::make_self helper functions. Change-Id: Ife134fed1a85a614eedd9d8a17d53857d10fcedf Reviewed-by: Lars Knoll <lars@knoll.priv.no> Reviewed-by: Pavel Dubsky <pavel.dubsky@qt.io> Reviewed-by: Artem Dyomin <artem.dyomin@qt.io> (cherry picked from commit 690206fcf6b92199f540ccc79db28d363ebe443e)
* Update dependencies on '6.5' in qt/qtmultimediaQt Submodule Update Bot2023-06-091-4/+4
| | | | | Change-Id: I95e46a79e7b516c3a8ffe4f9d45093c3e8c02c3d Reviewed-by: Qt Submodule Update Bot <qt_submodule_update_bot@qt-project.org>
* Replace qFatal with qCriticalArtem Dyomin2023-06-082-4/+5
| | | | | | | | | | | | The default message handler may abort the application on qFatal, it's not expected behavior in the cases. Task-number: QTBUG-114202 Change-Id: Ia96b5099e6552ded979c2de75546bdabbf58decb Reviewed-by: Jøger Hansegård <joger.hansegard@qt.io> Reviewed-by: Lars Knoll <lars@knoll.priv.no> (cherry picked from commit 1382b19e4bbd1f0f07de13f68ff1a9d8306ef818) Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
* Split QComPtr reset() function into a reset() and an attach() functionJøger Hansegård2023-06-085-6/+20
| | | | | | | | | | | | | | | The name 'reset' does not specify well how ownership is handled when reset to a new pointer value. A better name for this is 'attach', which indicates that AddRef is not called. 'reset' now just resets the pointer to a default constructed state. This is a step towards replacing QComPtr out with WRL::ComPtr which is used elsewhere in Qt. Change-Id: Ic72beba8cf212669f5dfa2e01f36754ffb0ad94e Reviewed-by: Lars Knoll <lars@knoll.priv.no> Reviewed-by: Pavel Dubsky <pavel.dubsky@qt.io> (cherry picked from commit b9a3961ff5966af372acad83f9dcee7f082a21c7)
* Doc: Use correct module identifiers in \qmlproperty commandsTopi Reinio2023-06-082-3/+3
| | | | | | | Change-Id: I64ca7ae3aa206dee3ef78da33ad7c1a729a51cef Reviewed-by: Andreas Eliasson <andreas.eliasson@qt.io> (cherry picked from commit 9f0cf421d25168fdace773af0b5da9c51896d7ef) Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
* Add CMakeUserPresets.json to .gitignore in QtMultimediaJøger Hansegård2023-06-071-0/+1
| | | | | | | | | | | | | | | | | The CMakeUserPresets.json file can be used to simplify configuring Qt, particularly with tools such as Visual Studio and Visual Studio Code. As opposed to the CMakePresets.json, the CMakeUserPresets.json should only contain user specific configurations, and should never be checked into source code management system. This was added to the top level repo in but to ease working with QtMultimedia as a module, it should also be included here. Change-Id: I003017c6049860fa306a2353aab00381378878d7 Reviewed-by: Lars Knoll <lars@knoll.priv.no> Reviewed-by: Artem Dyomin <artem.dyomin@qt.io> (cherry picked from commit 7ba25183a415c3fbaccdb5101a90b7ca85a64b3f) Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
* Fix detection of the default audio input on LinuxArtem Dyomin2023-06-071-1/+1
| | | | | | | | | | | For detection of the default audio output audio source name should be taken instead of audio sink name. Task-number: QTBUG-112219 Change-Id: I111de8c5a42de372117a0a5ae9bc7995c9629700 Reviewed-by: Lars Knoll <lars@knoll.priv.no> (cherry picked from commit a33d0422f2d2e1e29c6276ac708fdaf9f7306dc1) Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
* Remove conanfile.pyTor Arne Vestbø2023-06-071-36/+0
| | | | | | | | | | The conan experiment has ended, and the file is only bitrotting nowadays. Change-Id: I2d0d1f5145b4880e0f1eade36220142dd764bb12 Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io> (cherry picked from commit 22980bc6e851b7ea20a1af41fa29741c670bf6b5) Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
* Replace Q_OS_OSX with Q_OS_MACOSTor Arne Vestbø2023-06-074-13/+13
| | | | | | | Change-Id: I23fab7187d527bac1376a32d6b25a4ff01470944 Reviewed-by: Alexandru Croitor <alexandru.croitor@qt.io> (cherry picked from commit 56024013d898696b209ac1c74ec2abe638675446) Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
* Align QComPtr constructor ownership with other COM smart pointersJøger Hansegård2023-06-073-3/+9
| | | | | | | | | | | | | | | COM smart pointers such as CComPtr, _com_ptr_t and WRL::ComPtr all calls AddRef when constructed with a valid interface pointer. To make the QComPtr less 'special', it should also call AddRef when assigned a valid pointer. This is a step towards replacing QComPtr out with WRL::ComPtr which is used elsewhere in Qt. Change-Id: I97574c28267537f11b6d73c28da9ccf54a6cdcf1 Reviewed-by: Pavel Dubsky <pavel.dubsky@qt.io> Reviewed-by: Lars Knoll <lars@knoll.priv.no> (cherry picked from commit 94c88e90d81a4e0966211dc837e54225db6b0a62) Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
* Limit VideoEncoder memory usage when encoder is unable to keep upJøger Hansegård2023-06-072-4/+18
| | | | | | | | | | | | | | | | | | | | | | | | | | | The qffmpegencoder has an internal queue that buffers video frames when the encoder is unable to keep up with the frame source. This helps stabilizing the frame rate in case of intermittent encoder hiccups, but if the encoder is consistently unable to keep up with the frame source, the queue will grow and eventually the process will run out of memory. With 4K resolution images, the data rate is approx 2 GB/second, and if the frames are located on the GPU, the GPU will run out of memory in a matter of seconds. To prevent this, we introduce a max size of the VideoEncoder frame queue. In this change proposal, we use an arbitrarily chosen limit of 10 frames. This should be enough to recover from short intermittent encoder hiccups, without using too much memory (~300 MB at 4K resolution). If a new frame arrives from the video source, and the queue is full, we now drop the frame. This strategy prevents blocking any video source thread (as opposed to blocking if the queue is full.) Fixes: QTBUG-114055 Change-Id: I29714267696454dfd371e0fd6ed3112c9b7356b0 Reviewed-by: Lars Knoll <lars@knoll.priv.no> (cherry picked from commit ed7f8234dd38afef3344ed6b225677bac3b2a12e) Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
* Update dependencies on '6.5' in qt/qtmultimediaQt Submodule Update Bot2023-06-071-4/+4
| | | | | Change-Id: I940a3540ab68627f00436a5a69fb6e57344706f6 Reviewed-by: Qt Submodule Update Bot <qt_submodule_update_bot@qt-project.org>
* wasm: fix multimedia devices discoveryLorn Potter2023-06-061-1/+4
| | | | | | | | | | Previously, this assumed user would create a capture session. Fixes: QTBUG-114061 Change-Id: I28aa683618edd3f5f409e52e2a491784f8f5c884 Reviewed-by: Morten Johan Sørvig <morten.sorvig@qt.io> (cherry picked from commit 6a7221f050522e9dd3e0e11826940b50cde36436) Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
* Avoid flooding log during DXGI screen capture error handlingJøger Hansegård2023-06-061-2/+2
| | | | | | | | | | | | | | | | Due to an error handling bug, the DXGI screen capture would flood the log when facing lost duplication interface. This can happen for example when pushing Ctr+Alt+Del while screen capturing is ongoing. This change does not implement recovery after lost duplication interface, but prevents flooding the log by avoiding repeatedly calling IDXGIOutputDuplication::ReleaseFrame Task-number: QTBUG-113460 Change-Id: Iad5761cc4cfe5189460944528b35fd136085631f Reviewed-by: Lars Knoll <lars@knoll.priv.no> (cherry picked from commit 59a50bebb386c83a829ffabd7392c1de2bdb9f5c) Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
* Update dependencies on '6.5' in qt/qtmultimediaQt Submodule Update Bot2023-06-061-4/+4
| | | | | Change-Id: If74a16ed5c67b398b64fa7090cca0252868ffc0b Reviewed-by: Qt Submodule Update Bot <qt_submodule_update_bot@qt-project.org>
* Docs: Expand and update the QML Camera example documentationNicholas Bennett2023-06-067-17/+135
| | | | | | | | | | | | | Added images, code snippets, and restructured the documentation to talk about the changes since the documentation was initially created. Fixes: QTBUG-113572 Change-Id: I20d09c6a468404ed6f2a8aaabd695d8a92160d62 Reviewed-by: Rami Potinkara <rami.potinkara@qt.io> Reviewed-by: Mats Honkamaa <mats.honkamaa@qt.io> (cherry picked from commit 24422051dfacaa8036ba45ad23f449922540296b) Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
* Fix the spectrum example build with QMake on AndroidVille Voutilainen2023-06-051-1/+2
| | | | | | | Task-number: QTBUG-109537 Change-Id: I9b5a08e9d8f91b0afa32d3f8b50e5c375115f009 Reviewed-by: Assam Boudjelthia <assam.boudjelthia@qt.io> (cherry picked from commit b8e1cc5584fba6c236756df382774b46965ba40d)
* Add missing ScreenCapture to the documented functionality listArtem Dyomin2023-06-021-0/+6
| | | | | | | Change-Id: I50c7c6b331a9f00bc3777b45bef51ed6fd000889 Reviewed-by: Lars Knoll <lars@knoll.priv.no> (cherry picked from commit 84de5ebf95b13455d12af0b7269b1a9afa9e98e4) Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
* Docs: Update CameraSession's AudioOutput descriptionBartlomiej Moskal2023-06-021-0/+5
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | Accoring to the QTBUG-109659, documentation should clearly point that setting AudioOutput is used for audio routing. It is already mentioned in: - qml-qtmultimedia-capturesession[0] "Route audio to an output device by assigning an AudioOutput object to the audioOutput property." - qmediacapturesession[1] "A preview of the captured media can be (...) heard by routing the audio to an output device using setAudioOutput()." But there was no mention about it for audioOutput setter. This commit add information about audio routing in audioOutput setter description. [0]https://doc.qt.io/qt-6/qml-qtmultimedia-capturesession.html#details [1]https://doc.qt.io/qt-6/qmediacapturesession.html#details Task-number: QTBUG-109659 Change-Id: I07cd697200d533b649be04a91dd03dca3ac8adc5 Reviewed-by: Nicholas Bennett <nicholas.bennett@qt.io> (cherry picked from commit 3245781b12e90d87ae009d679e801b5388300c5d) Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
* Improve naming of screen capture integration testsJøger Hansegård2023-06-022-11/+11
| | | | | | | | | | | | | | | | | | | | | | | | | | | | Reviewing test logs and maintaining tests can be easier if the tests are explicit in what they test. It can therefore be useful to document in the tests what function is being tested, what the expectation is, and which conditions applies to a test. The proposed naming turns the tests into requirements, and can be read as (Require that) FunctionName DoesWhat UnderWhichConditions. For example: setWindow_selectsWindow_whenWindowIsOverlapped Here, the function under test is setWindow. When it is called, we expect that the window is selected (when capturing). The condition is that the window is overlapped. In some cases, the test may not test a single function, where the proposal is to do as best as we can to document what functionality is tested, what the expectation is, and under what conditions the test is performed. Task-number: QTBUG-113460 Change-Id: Ie001e464a4c92d468b5b58160b1cdaa2aea858ee Reviewed-by: Lars Knoll <lars@knoll.priv.no> Reviewed-by: Artem Dyomin <artem.dyomin@qt.io> (cherry picked from commit 2d65ac72a38ca8e280758db7430756dc1a468628)
* Multimedia: Fix compiler warning warning C4723: potential divide by 0Jøger Hansegård2023-06-011-5/+6
| | | | | | | | | | | | | cl.exe 19.35.32217.1 for x64 emits warning C4723: potential divide by 0 in RelWithDebInfo build of QtMultimedia.dll. The reason is likely that the compiler can not rule out that the QAudioFormat::bytesPerSample returns a different value from the point of check to the point of read. Change-Id: Ifcc2db06310c94a7b90514f54d4d9e9c94c63072 Reviewed-by: Lars Knoll <lars@knoll.priv.no> Reviewed-by: Artem Dyomin <artem.dyomin@qt.io> (cherry picked from commit dda06373eba84999a89e539035860fc45f2fa5f5) Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
* declarative-camera: Fit camera output to window on desktop as wellTor Arne Vestbø2023-06-011-5/+1
| | | | | | | | | | | | | It's no different from the mobile modes. Change-Id: I21a00b63b816e9a2e0b75f96e75007549a2cb8d0 Reviewed-by: Samuel Mira <samuel.mira@qt.io> Reviewed-by: Artem Dyomin <artem.dyomin@qt.io> Reviewed-by: Lars Knoll <lars@knoll.priv.no> Reviewed-by: Pavel Dubsky <pavel.dubsky@qt.io> Reviewed-by: Jøger Hansegård <joger.hansegard@qt.io> (cherry picked from commit 8b9a271ddd6c1b0621d2f4f8577bcc1db205dd79) Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
* Clean up pulse audio and fix some threading issuesArtem Dyomin2023-06-016-191/+147
| | | | | | | | | | | | | | | | | - improve threading handling, so auto tests flakiness has been fixed. (additional fixes required, namely atomic states comare_exchange) - improve pulse audio operations managing with RAII - remove a hack with a callback based on QObject::destroyed connection, the hack appeared to cause memory leak time to time. - the main logic is not changed The patch has been decoupled from codereview.qt-project.org/c/qt/qtmultimedia/+/474485 Change-Id: I68002c243dea874c4300b14b1fbd6b618392ab4f Reviewed-by: Lars Knoll <lars@knoll.priv.no> (cherry picked from commit 93e7d81cdea07ad1e364e1a6d107022298be35ab) Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
* Fix QAudioSink::stateChanged signal emittingArtem Dyomin2023-05-311-1/+6
| | | | | | | | | | | | | | | 1. Ensure sending the signal from QAudioSink's thread. 2. QAudioSink backends emit signals from different threads what may cause a case when queued events are outdated and should be filtered. The patch has been decoupled from the big change codereview.qt-project.org/c/qt/qtmultimedia/+/474485 Task-number: QTBUG-113194 Change-Id: I68002c243dea814c4309b14b1fbd7b618392ab11 Reviewed-by: Lars Knoll <lars@knoll.priv.no> (cherry picked from commit e243338d6465f185ba7a78a3dfb8f426a637d2cf) Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
* Fix 6.5 ScreenCapture documentationArtem Dyomin2023-05-315-23/+18
| | | | | | | | | | | | | | 1. Remove not documented WindowCaptureNotSupported enum value. The signal will not be used if we go with QWindowCapture in 6.6. See codereview.qt-project.org/c/qt/qtmultimedia/+/477647 2. Remove qml ScreenCapture::window property that was mistakenly documented but was not exposed in API. 3. Remove term "window" from the 6.5 documentation. Change-Id: I1d540550b6cd064041c8b9574791a399078faf48 Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@qt.io> Reviewed-by: Lars Knoll <lars@knoll.priv.no> Reviewed-by: Jøger Hansegård <joger.hansegard@qt.io>
* Revert "Add IMPORTED_LINK_INTERFACE_LANGUAGES to WMF::WMF target"Amir Masoud Abdol2023-05-311-2/+1
| | | | | | | | | | | This reverts commit 148cf063e4efb87fc1ff07429b5723ff35ad0ef0. Reason for revert: It was not fixing the issue. Change-Id: I3f57721f4f24a7cd537cfb44d0b12dae9f533096 Reviewed-by: Alexandru Croitor <alexandru.croitor@qt.io> (cherry picked from commit fc1cc250d6d226dd627cefc4be617231d229e2cf) Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
* Move the static variable declaration inside a functionAmir Masoud Abdol2023-05-312-4/+4
| | | | | | | | | | | | | | In both files, it doesn't look like that we need these variable in more than one functions. So, we can move them in their respective functions. P.S. If not fixed, this breaks the Unity Build since it will result in a duplicate symbol declaration error. Change-Id: I2e0babeb2422b3d3e4f953c93fb9c5a5ba11366a Reviewed-by: Alexandru Croitor <alexandru.croitor@qt.io> Reviewed-by: Artem Dyomin <artem.dyomin@qt.io> (cherry picked from commit 1cce84af3ecb4a570ab36fbe48357934d4d94ba0) Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
* Update dependencies on '6.5' in qt/qtmultimediaQt Submodule Update Bot2023-05-311-4/+4
| | | | | Change-Id: I406e3d5c9f8eb5506390a05bf303361d82c8ffa1 Reviewed-by: Qt Submodule Update Bot <qt_submodule_update_bot@qt-project.org>
* Fix some qmediaplayer tests flackinessArtem Dyomin2023-05-306-29/+37
| | | | | | | | | | | | | | | | Outputs should be removed after QMediaPlayer to avoid having broken references inside the player. Handling of the outputs deleting will be done under the task QTBUG-114072 with new specific unit test case. This patch fixes tests flakiness that improves CI behavior. Task-number: QTBUG-114072 Change-Id: I0f4f4a2e9152a2a4dd9572d8060586ee6fb1d647 Reviewed-by: Lars Knoll <lars@knoll.priv.no> Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org> (cherry picked from commit f93fa5ab5196aa5135bd404d15bf5884546a6feb) Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
* Fix inaccuracy in QAudioSink documentationArtem Dyomin2023-05-301-2/+3
| | | | | | | Change-Id: I4ae1304615bf8ec55fbe5f41dc280cbc83f1185e Reviewed-by: Lars Knoll <lars@knoll.priv.no> (cherry picked from commit 74ce8e208fd098cacdd044d4688607fdea82cb42) Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
* Add audio engine warm-up on WindowsPavel Dubsky2023-05-3010-4/+157
| | | | | | | | | | | | | | | | | | | | | | | | | Current implementation has the following audio problem on Windows: if any of the classes that support audio playback are used (QMediaPlayer or QSoundEffect) sound is cutting off (part of the sound is missing usually beginning). If there're some other applications playing sounds in the system while we try to play our sound then everyting works fine. Apparently this happens due to warm up delays for system audio engine and if there're other applications available they're simply keeping it alive and it's already fully initialized and ready to be used by us when we need it. As a workaround to this problem an unused audio device is created that is fully initialized and set to play (nothing) but is actually present for any subsequently created audio devices that are ready from the start without any delays. Task-number: QTBUG-112512 Change-Id: I660a48e8ac1a1ebd1cfb6a9ff76605c3b4742e17 Reviewed-by: Artem Dyomin <artem.dyomin@qt.io> Reviewed-by: Lars Knoll <lars@knoll.priv.no> Reviewed-by: Jøger Hansegård <joger.hansegard@qt.io> (cherry picked from commit 5aa899abb67ebdbcc9d0feb994385f1ab12656f7) Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
* Release DXGI duplication frame as late as possible to favor performanceJøger Hansegård2023-05-301-9/+16
| | | | | | | | | | | | | | | | | | According to Microsoft documentation for the IDXGIOutputDuplication::ReleaseFrame: "For performance reasons, we recommend that you release the frame just before you call the IDXGIOutputDuplication::AcquireNextFrame method to acquire the next frame." This has no measurable impact on GPU usage or performance of the screen capture, but because this design simplifies error handling/cleanup, we can just as well follow the guidelines. Task-number: QTBUG-113460 Change-Id: I0f95c5792b29942a957f57971081520501a1e0a5 Reviewed-by: Lars Knoll <lars@knoll.priv.no> (cherry picked from commit cfc5b97daee9ac38b6fa8ec52be292e0790220ce) Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
* Make getNextFrame function part of DXGI grabberJøger Hansegård2023-05-301-37/+37
| | | | | | | | | | | | | | | Moving the function inside the grabber class will allow us to keep some state around. This will be used for example to improve the grabber performance by avoiding releasing the grabbed frame too frequently. Task-number: QTBUG-113460 Change-Id: If883071926b8e7ec9d8a4a156aabcaee8d3370cc Reviewed-by: Artem Dyomin <artem.dyomin@qt.io> Reviewed-by: Lars Knoll <lars@knoll.priv.no> (cherry picked from commit 9b38bc514c658117a4ee0cb3bfbe6010ff864914) Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
* Commonize popup behavior between camera settings and device listNicholas Bennett2023-05-301-0/+1
| | | | | | | | | | | | | | | | Currently when you select a device in the in the device list popup it does not close the popup, unlike with the camera settings popup list This leads to some user-confusion regarding expected behavior of the example. I replicated the emission of the selected() signal as used in the camera settings popup to fix this. Change-Id: I1ef5faf75dff702f61991b9ac1735364b187b10b Reviewed-by: Artem Dyomin <artem.dyomin@qt.io> Reviewed-by: Lars Knoll <lars@knoll.priv.no> (cherry picked from commit 75bbf7224fef52d5d838ae4de2f7c4bcd05c40d3) Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
* Remove std::unary_function usageArtem Dyomin2023-05-301-2/+2
| | | | | | | | | | | | std::unary_function was removed with c++17 Task-number: QTBUG-113782 Change-Id: I4e330cd1f89dc14936acbccdeee8378ea4938870 Reviewed-by: Lars Knoll <lars@knoll.priv.no> Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org> Reviewed-by: Pavel Dubsky <pavel.dubsky@qt.io> (cherry picked from commit 82f7f3de0e90bb7d1447cb710ffd2e1b315ae479) Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
* Update dependencies on '6.5' in qt/qtmultimediaQt Submodule Update Bot2023-05-291-4/+4
| | | | | Change-Id: I165d67c39a81603c22ae571fadba7ae7e1434f8e Reviewed-by: Qt Submodule Update Bot <qt_submodule_update_bot@qt-project.org>
* wasm: fix switching camerasLorn Potter2023-05-261-7/+11
| | | | | | | | Fixes: QTBUG-113263 Change-Id: If2a740b4224e6f618896f23ce28dc2b02aa2d6d1 Reviewed-by: Morten Johan Sørvig <morten.sorvig@qt.io> (cherry picked from commit da90f218005e9f2acae2bf8cce721b01c1a98598) Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
* Update dependencies on '6.5' in qt/qtmultimediaQt Submodule Update Bot2023-05-251-4/+4
| | | | | Change-Id: I80a2444268921ae072f7ec308577a748d976d709 Reviewed-by: Qt Submodule Update Bot <qt_submodule_update_bot@qt-project.org>
* Exclude source files from QFFmpegMediaPlugin when building for AndroidAmir Masoud Abdol2023-05-241-0/+5
| | | | | | | | | | | | | | Several symbols are redefined in these source files, e.g., AndroidImageFormat, AndroidImage, QtVideoDeviceManager. Excluding two out of three of these files is sufficient for resolving the conflict; however, I have added the third one as well, as a precautionary measure because the names are quite common and may lead to similar issues later. Task-number: QTBUG-109394 Change-Id: Ib0d3b0ec41762ab8e391efcbdce5c494ff5b296c Reviewed-by: Joerg Bornemann <joerg.bornemann@qt.io> (cherry picked from commit e844a4212b4ea4605282dc059a7944ae6000182f) Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>