summaryrefslogtreecommitdiffstats
path: root/src/multimedia/controls
Commit message (Collapse)AuthorAgeFilesLines
* Rename QVideoWindowControl to QPlatformVideoSinkLars Knoll2021-04-063-349/+0
| | | | | | | | | | | | | | | | This class can nicely serve as the basis class for the platform specific new video sink API. For now it will support windowed rendering and the non windowed mode will get folded into this class in follow-up commits. Clean up the QVideoWidget code and always use QVideoSink there to make the transition easier to handle. This implies that QVideoWidget will right now only work in windowed mode. Change-Id: I6db4509ceaa142001ffd59b60406aa98c71f5fc0 Reviewed-by: Doris Verria <doris.verria@qt.io> Reviewed-by: Lars Knoll <lars.knoll@qt.io>
* Rename backend classes as a next step in consistent class namingDoris Verria2021-03-0515-2038/+0
| | | | | | | | Remove the Control* naming convention of the backend classes and rename to QPlatformFoo. Make headers private. Change-Id: Ic7310c7a22cfcf247d823eb984c09e8a9378c9a9 Reviewed-by: Lars Knoll <lars.knoll@qt.io>
* Get rid of sharpening and denoising in QCameraImageProcessingDoris Verria2021-03-052-21/+4
| | | | | | | Adjusting these values was only supported on v4l. Change-Id: Ie52e24e33d59a69983c99e4de6dec9d2716ff19d Reviewed-by: Lars Knoll <lars.knoll@qt.io>
* Get rid of QMediaStreamsControlLars Knoll2021-03-053-214/+0
| | | | | | | | The relevant API is now in QPlatformMediaPlayer. Change-Id: I72db49286ec343e2f1672d851108ac612068095b Reviewed-by: Lars Knoll <lars.knoll@qt.io> Reviewed-by: Doris Verria <doris.verria@qt.io>
* Remove manual metatype declarations and registrationsLars Knoll2021-03-025-21/+0
| | | | | | | | Those aren't needed in Qt 6 anymore. Change-Id: I1d19a0dd9c42cfa3fe6d88a56accbe3af2efdf47 Reviewed-by: Doris Verria <doris.verria@qt.io> Reviewed-by: Lars Knoll <lars.knoll@qt.io>
* Get rid of QVideoRendererControlLars Knoll2021-03-023-151/+0
| | | | | | | | | | It's a pure implementation detail in the backends now (and can in cases even get removed there). No need for an interface. Change-Id: Ib61cebe80d0369424d4ee681992e4abc80c11a14 Reviewed-by: Doris Verria <doris.verria@qt.io> Reviewed-by: Lars Knoll <lars.knoll@qt.io>
* Rename QMediaPlayerControl to QPlatformMediaPlayerLars Knoll2021-03-023-542/+1
| | | | | | | | | | | This is the start of a larger renaming excercise, that will hopefully bring us closer towards a final naming convention for files and classes in the multimedia backends. Change-Id: Ib6010e2923cbf82b6bd6cd247614b4405863cf70 Reviewed-by: Doris Verria <doris.verria@qt.io> Reviewed-by: Lars Knoll <lars.knoll@qt.io>
* Move the streams interface into QMediaPlayerControlLars Knoll2021-02-171-0/+4
| | | | | | Change-Id: Ib3ce50ed15e96d4edc5d64c9b0f514f591d75c64 Reviewed-by: Doris Verria <doris.verria@qt.io> Reviewed-by: Lars Knoll <lars.knoll@qt.io>
* And finally kill QMediaServiceLars Knoll2021-02-1717-92/+12
| | | | | | | | | This removes the past piece of the old service architecture from Qt Multimedia. Change-Id: I607f82a546b2a2e29024b987fed3ba6e3645ae48 Reviewed-by: Doris Verria <doris.verria@qt.io> Reviewed-by: Lars Knoll <lars.knoll@qt.io>
* Get rid of QMediaService for the capture interfaceLars Knoll2021-02-1715-141/+4
| | | | | | Change-Id: I69a3d379bd2f1adbc4d583fd8eadcd3eb624a3af Reviewed-by: Doris Verria <doris.verria@qt.io> Reviewed-by: Lars Knoll <lars.knoll@qt.io>
* Kill QMediaSource and QMediaSinkLars Knoll2021-02-174-4/+8
| | | | | | | | Those aren't used anymore, get rid of them. Change-Id: I5a17f18a3c87c2c13a9009b1f99ef9e708f7636a Reviewed-by: Doris Verria <doris.verria@qt.io> Reviewed-by: Lars Knoll <lars.knoll@qt.io>
* Get rid of QCamera::CaptureModeLars Knoll2021-02-172-39/+0
| | | | | | | | | | | Whether we capture still images or Video should only depend on the outputs we have attached to the camera (QMediaRecoder and QCameraImageCapture). There's no need for a separate enum here. Change-Id: I852f5c752abd1184680ca868cb90e995d6d68b27 Reviewed-by: Doris Verria <doris.verria@qt.io> Reviewed-by: Lars Knoll <lars.knoll@qt.io>
* Rework how to set a video output surfaceLars Knoll2021-02-172-0/+5
| | | | | | | | | | | | | | | | | | | | Setting a video output should not require QMediaService anymore. Reverse the logic, by making QAbstractVideoSurface the primary interface. Use runtime method lookup to get a pointer to the video surface from QVideoWidget/QGraphicsVideoItem. QAbstractVideoSurface is now the primary interface for setting up a video output. We will need to add some API there to allow for windows/fullscreen rendering. With this change, QVideoRendererControl/QVideoWindowControl can also be retired as an abstraction layer in the longer term. Change-Id: Iedff18c6b95fedc7cb914075a8c84081080deab1 Reviewed-by: Doris Verria <doris.verria@qt.io> Reviewed-by: Lars Knoll <lars.knoll@qt.io>
* Rework the metadata handlingLars Knoll2021-02-1210-472/+14
| | | | | | | | | | | Get rid of metadata reader and writer controls. Instead use a simple cross platform value class to store meta data. The backend can then convert to and from whatever the native API expects. Change-Id: I7cf84bfbe8eef2a88615a52ba5afeec50a0652c8 Reviewed-by: Doris Verria <doris.verria@qt.io> Reviewed-by: Lars Knoll <lars.knoll@qt.io>
* Remove camera locking APILars Knoll2021-02-122-38/+0
| | | | | | | | | | | | | QCamera::lock()/unlock() is something that's not needed these days anymore. cameras will automatically focus anyway, there's no real reason to lock the focus (or other properties) to some specific value in 99% of the cases. Plus it wasn't supported on Linux or macOS/iOS anyway. Change-Id: I437d29cbb768da3ece42eea8d753eeafa0c534ae Reviewed-by: Doris Verria <doris.verria@qt.io> Reviewed-by: Lars Knoll <lars.knoll@qt.io>
* Get rid of QImageEncoderControlLars Knoll2021-02-125-194/+18
| | | | | | | | Fold the settings into QImageCaptureControl. Change-Id: I9cf981dfa956b769167791bc830bbe1569004367 Reviewed-by: Doris Verria <doris.verria@qt.io> Reviewed-by: Lars Knoll <lars.knoll@qt.io>
* Cleanup QImageEncoderSettingsLars Knoll2021-02-122-15/+0
| | | | | | | | | | | Define a list of supported file formats, as with QMediaEncoderSettings. Implement support for detecting those on gstreamer. Remove the old interface in QCameraImageEncoderControl. Change-Id: Ic3d67dd19fe13336ba2017dc8055014274619ce6 Reviewed-by: Doris Verria <doris.verria@qt.io> Reviewed-by: Lars Knoll <lars.knoll@qt.io>
* Don't use QMediaService anymore to get the camera controlsLars Knoll2021-02-091-0/+7
| | | | | | | | Instead retrieve them from the camera control. Change-Id: Ic996a672f102f7dc3fc5e3b73f977d3864e9a129 Reviewed-by: Lars Knoll <lars.knoll@qt.io> Reviewed-by: Doris Verria <doris.verria@qt.io>
* Don't use the service to get the metadatawritercontrolLars Knoll2021-02-091-0/+3
| | | | | | | | Instead, ask the media recorder control for it. Change-Id: I1cf47af00dc29a282bce7767ce15ef203c44c585 Reviewed-by: Lars Knoll <lars.knoll@qt.io> Reviewed-by: Doris Verria <doris.verria@qt.io>
* Get rid of QCameraImageCapture::DriveModeLars Knoll2021-02-092-16/+0
| | | | | | | | | Nothing but single image capture was ever implemented, so the whole API was unused. Change-Id: I429040d3e2d74bddd6b76649ca6680acc9db126e Reviewed-by: Lars Knoll <lars.knoll@qt.io> Reviewed-by: Doris Verria <doris.verria@qt.io>
* Clean up zooming APILars Knoll2021-02-091-15/+7
| | | | | | | | | | | There is very little point these days in having properties for both optical and digital zoom. Most mobile cameras don't have a real optical zoom, but instead combine different cameras with different focal lengths. Change-Id: Icac48d949e767d7f3105c4d330e15273fe715fbe Reviewed-by: Lars Knoll <lars.knoll@qt.io> Reviewed-by: Doris Verria <doris.verria@qt.io>
* Use the new QMediaEncoderSettings in QMediaRecorderLars Knoll2021-02-098-641/+2
| | | | | | | | | | | | | Switch the backends for Android (compiles but untested), AFFoundation and GStreamer over to use the new QMediaEncoderSettings. Get rid of the old *EncoderControl classes and associated infrastructure. Change-Id: Ic75ff43eab55aeb0ab53d7248f7f5ff70b14c05f Reviewed-by: Doris Verria <doris.verria@qt.io> Reviewed-by: Lars Knoll <lars.knoll@qt.io>
* Get rid of QCameraViewFinderSettingsLars Knoll2021-01-291-6/+0
| | | | | | | | | | The outputs should control the camera settings that are required. Before one could define resolutions and framerates in several places, not it's the requested outputs that define it. Change-Id: Iab76abac84480e6200b9fc5b058fc2a02b0a8ce0 Reviewed-by: Doris Verria <doris.verria@qt.io> Reviewed-by: Lars Knoll <lars.knoll@qt.io>
* Cleanup resolution and frameRate handlingLars Knoll2021-01-292-9/+0
| | | | | | | | | | | The Camera determines the available resolutions and framerates. There's no point routing requests around that through the backend again, if we can get it from QCameraInfo in the first place. Change-Id: Ie00285811202bf93799155736de149c37561fd31 Reviewed-by: Doris Verria <doris.verria@qt.io> Reviewed-by: Lars Knoll <lars.knoll@qt.io>
* Remove QAudioProbe and QVideoProbeLars Knoll2021-01-295-331/+0
| | | | | | | | | | | | | | They worked very inconsistently between platforms (or not at all) and made the implementation quite a bit more complex. Longer term they will get replaced by adding the possibility to have multiple audio/video outputs and implementing monitoring output classes that can deliver QAudioBuffers and QVideoFrames to the app. Change-Id: Ic5b4506e7392d352d33b51f01ff0d5169d7b5129 Reviewed-by: Doris Verria <doris.verria@qt.io> Reviewed-by: Lars Knoll <lars.knoll@qt.io>
* Get rid of QVideoDeviceSelectorControlLars Knoll2021-01-294-275/+2
| | | | | | | | | | | Move the camera selection into QCameraControl directly and give it a more decent API using QCameraInfo. Remove the QCamer(name) constructor, as it could lead to invalid cameras being constructed. Change-Id: Ieb26f62684080eaf9a10770ec7df2cde2996bcff Reviewed-by: Lars Knoll <lars.knoll@qt.io>
* Remove the mediaChanged() signal from the media player controlLars Knoll2021-01-291-1/+0
| | | | | | | | | The front end has full control over this and handles the signal emission there. Change-Id: Icf1b164ce67d1f2036c106461302d53924c03ea1 Reviewed-by: Doris Verria <doris.verria@qt.io> Reviewed-by: Lars Knoll <lars.knoll@qt.io>
* Add support for selecting the audio output in QMediaPlayerLars Knoll2021-01-221-0/+4
| | | | | | | | | | | | | | | | Add API to select the audio output devive in QMediaPlayer. Implement it where possible. The gstreamer implementation still has issues, on rare occasions, the video stops playing when changing the audio output. There seems to be a race condition somewhere. Windows partially works, but the output device will not get updated after playback started. Change-Id: Ic6e99f7d2e3452915a9870dce45e2e01b079d3c2 Reviewed-by: Doris Verria <doris.verria@qt.io> Reviewed-by: Lars Knoll <lars.knoll@qt.io>
* Remove the unused QAudioOutputSelectorControlLars Knoll2021-01-223-204/+0
| | | | | | | | | | QMediaPlayer didn't use it and it was only implemented for WMF. Remove the control, but keep the code in WMF around for now, we'll need it to implement proper audio output selection in the player. Change-Id: I74f98ecde7e6e91ad8adea06e07d87f8604ff680 Reviewed-by: Doris Verria <doris.verria@qt.io> Reviewed-by: Lars Knoll <lars.knoll@qt.io>
* Get rid of QAudioInputSelectorControlLars Knoll2021-01-224-233/+3
| | | | | | | | | Use the new QMediaDeviceManager to get the list of available audio inputs instead. Simplify the API in QMediaRecorder. Change-Id: I0faf89a083b6778d0e172851fc8fb3f0d7569f54 Reviewed-by: Doris Verria <doris.verria@qt.io> Reviewed-by: Lars Knoll <lars.knoll@qt.io>
* Add a QMediaDeviceInfo class to enumerate input/output devicesLars Knoll2021-01-224-10/+76
| | | | | | | | | | | | | | | | | Use this as the starting point for a new QPA like backend infrastructure. Refactor places that use the device information to use the new infrastructure. Cleanup the audio subsystem part and port it over to the new infrastructure. Android and QNX are not ported yet. Change-Id: I99c459c998f1f05e1c40ad30c700011e41cef533 Reviewed-by: Doris Verria <doris.verria@qt.io> Reviewed-by: Lars Knoll <lars.knoll@qt.io>
* Get rid of the QMediaServiceFeaturesInterfaceLars Knoll2021-01-222-2/+6
| | | | | | | | Replace it by one virtual method in the media player control. Change-Id: I18778d2f56b9af8a16418c30c75c973e54b6add8 Reviewed-by: Doris Verria <doris.verria@qt.io> Reviewed-by: Lars Knoll <lars.knoll@qt.io>
* Get rid of QMediaContentLars Knoll2021-01-222-6/+6
| | | | | | | | | There's no need for it without playlist support in QMediaPlayer. Simply replace it with a QUrl. Change-Id: I28421772b106dad67d321f2c7053558ebfe2a592 Reviewed-by: Doris Verria <doris.verria@qt.io> Reviewed-by: Lars Knoll <lars.knoll@qt.io>
* Remove playlist support from QMediaPlayerLars Knoll2021-01-221-3/+0
| | | | | | | | | | Playlists can be trivially supported on top of QMediaPlayer, as the modified player example shows. There's no need to have all this complexity in QMediaPlayer itself. Change-Id: Iacdd58f7736809606669d150b1ba6046813b2207 Reviewed-by: Doris Verria <doris.verria@qt.io> Reviewed-by: Lars Knoll <lars.knoll@qt.io>
* Rename QMediaObject to QMediaSourceLars Knoll2021-01-228-10/+10
| | | | | | | | That actually describes what those classes are. Change-Id: I9ce01707bb260ff6452359e211f2c22b5740e61b Reviewed-by: Doris Verria <doris.verria@qt.io> Reviewed-by: Lars Knoll <lars.knoll@qt.io>
* Remove buffer format API in QCameraImageCaptureLars Knoll2021-01-213-181/+0
| | | | | | | | | | | | The only thing really supported here was JPEG, with the exception of gstreamer, where things were partially implemented. But this low level control doesn't really make sense anyway at this point. Get rid of it for now. Change-Id: Icdbc214a2e42ab92a1b34c539b039118402692bf Reviewed-by: Lars Knoll <lars.knoll@qt.io> Reviewed-by: Doris Verria <doris.verria@qt.io>
* Merge the viewfindersettingscontrol into QCameraControlLars Knoll2021-01-215-181/+29
| | | | | | Change-Id: I6410cc5fa9e787454a3ed61723b26238012aea6e Reviewed-by: Lars Knoll <lars.knoll@qt.io> Reviewed-by: Doris Verria <doris.verria@qt.io>
* Get rid of the old viewfindersettings backend interfaceLars Knoll2021-01-212-128/+17
| | | | | | Change-Id: Id7b82b445ac528a30dd67ead01ffa73af298d3d3 Reviewed-by: Lars Knoll <lars.knoll@qt.io> Reviewed-by: Doris Verria <doris.verria@qt.io>
* Remove empty destructors in the *Controls classesLars Knoll2021-01-2148-229/+0
| | | | | | Change-Id: I2c7266a6e068b1336e34ea8bf0cea46e77c29998 Reviewed-by: Lars Knoll <lars.knoll@qt.io> Reviewed-by: Doris Verria <doris.verria@qt.io>
* Get rid of QMediaControlLars Knoll2021-01-2148-96/+82
| | | | | | | | | | The class was serving no purpose that QObject doesn't offer, so remove that layer and use QObject as the base class for those controls. Change-Id: Icd434fabe88cbdba5fa54eafe6ba97ac08be61f3 Reviewed-by: Lars Knoll <lars.knoll@qt.io> Reviewed-by: Doris Verria <doris.verria@qt.io>
* Merge QCameraLocksControl into QCameraControlLars Knoll2021-01-215-210/+38
| | | | | Change-Id: I228b7ef5dbb3e782a4cf39605e2f33b3c93ba8a5 Reviewed-by: Lars Knoll <lars.knoll@qt.io>
* Merge QCameraZoomControl into QCameraFocusControlLars Knoll2021-01-215-276/+110
| | | | | | | The public API also only uses one class to control both. Change-Id: I55ba5ae168d77d7a05a21f22164aaf0752482020 Reviewed-by: Lars Knoll <lars.knoll@qt.io>
* Merge QCameraFlashControl into QCameraExposureControlLars Knoll2021-01-214-217/+7
| | | | | | | | | | They are exposwed through one class on the front-end side, no need to complicate the API with several interfaces on the backend side. Change-Id: I4ecdc96edf71353f1b6d31cab92b7df064033e9a Reviewed-by: Doris Verria <doris.verria@qt.io> Reviewed-by: Lars Knoll <lars.knoll@qt.io>
* Merge QCameraCaptureDestinationControl into QImageCaptureControlLars Knoll2021-01-214-192/+3
| | | | | | Change-Id: Idb30411d7474fb2fe9581aa94535c1638d71161c Reviewed-by: Doris Verria <doris.verria@qt.io> Reviewed-by: Lars Knoll <lars.knoll@qt.io>
* Remove unused ExtendedExposureParamLars Knoll2021-01-212-5/+1
| | | | | | Change-Id: Ibcd4d397cca13f58870cf08b751756cebd9c8030 Reviewed-by: Lars Knoll <lars.knoll@qt.io> Reviewed-by: Doris Verria <doris.verria@qt.io>
* Remove unused QCamerExposureControl::FlashPower/FlashCompensationLars Knoll2021-01-212-10/+0
| | | | | | Change-Id: I6f78042885441966809fabe0dd038e23eb14ebdb Reviewed-by: Lars Knoll <lars.knoll@qt.io> Reviewed-by: Doris Verria <doris.verria@qt.io>
* Kill QCameraExposure::MeteringModeLars Knoll2021-01-212-7/+0
| | | | | | | | This was not implemented in any of our plugins. Change-Id: I3118d56016d6b77e45a2ed911a630ca70ff1da3d Reviewed-by: Lars Knoll <lars.knoll@qt.io> Reviewed-by: Doris Verria <doris.verria@qt.io>
* First step in cleaning up the plugin loading codeLars Knoll2021-01-211-1/+1
| | | | | | | | | | | | | | Stop assuming that there are multiple plugins providing the same service. We'll have exactly one plugin for a service in the future and not provide several. The reason is that we will focus on having one good and functional multimedia backend per platform, not the mix of many semi-functional ones as we have today. Change-Id: I809d4c99a56a48369d0ba283af78b1c41740d92a Reviewed-by: Lars Knoll <lars.knoll@qt.io> Reviewed-by: Doris Verria <doris.verria@qt.io>
* Get rid of QCameraInfoControlLars Knoll2021-01-215-174/+20
| | | | | | | | | | | | | This was completely over-engineered. Simply implement this in the QVideoDeviceControl (as that one is only listing cameras anyway). Cleanup the convoluted code in the service provider classes while we're at it. Change-Id: I2a71eaf104af2a06016399d77c2d8b4bcd417b4a Reviewed-by: Lars Knoll <lars.knoll@qt.io> Reviewed-by: Doris Verria <doris.verria@qt.io>
* Get rid of the AudioRole controlsLars Knoll2021-01-207-392/+47
| | | | | | | | | They were only used by the media player, so merge the functionality into QMediaPlayer and QMediaPlayerControl. Change-Id: Icceef061b41475e7b4bf3ef1848e60db5aa1307b Reviewed-by: Doris Verria <doris.verria@qt.io> Reviewed-by: Lars Knoll <lars.knoll@qt.io>