aboutsummaryrefslogtreecommitdiffstats
path: root/examples/multimedia/camera/videosettings.py
diff options
context:
space:
mode:
authorShyamnath Premnadh <Shyamnath.Premnadh@qt.io>2023-09-22 12:16:03 +0200
committerShyamnath Premnadh <Shyamnath.Premnadh@qt.io>2023-10-02 18:20:53 +0200
commit20bd006663ca640baf19bcc5a4f80899cd6eb2da (patch)
treef68df85196c22ace84c1082db049d5536073cefd /examples/multimedia/camera/videosettings.py
parent0f98cb69d4e8a2beec64102abef97b46aa7626ba (diff)
Example Revamp: Camera
- Changes as per e3c0c190136a55634451024cfa3ac8024c74caa3 - New UI for Android as per the corresponding Qt example - Add the new permission API functions to request and check for Android runtime permissions - Update .pyproject file Task-number: PYSIDE-1612 Task-number: PYSIDE-2206 Pick-to: 6.6 Change-Id: I8b9c41c6cd12388addb5a8a4049c1126b62e098b Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
Diffstat (limited to 'examples/multimedia/camera/videosettings.py')
-rw-r--r--examples/multimedia/camera/videosettings.py9
1 files changed, 8 insertions, 1 deletions
diff --git a/examples/multimedia/camera/videosettings.py b/examples/multimedia/camera/videosettings.py
index 5aab973b6..2359bd55b 100644
--- a/examples/multimedia/camera/videosettings.py
+++ b/examples/multimedia/camera/videosettings.py
@@ -1,11 +1,18 @@
# Copyright (C) 2023 The Qt Company Ltd.
# SPDX-License-Identifier: LicenseRef-Qt-Commercial OR BSD-3-Clause
+import os
from PySide6.QtMultimedia import (QCameraFormat, QMediaFormat, QMediaRecorder,
QVideoFrameFormat)
from PySide6.QtWidgets import QDialog
-from ui_videosettings import Ui_VideoSettingsUi
+is_android = os.environ.get('ANDROID_ARGUMENT')
+
+if is_android:
+ from ui_videosettings_mobile import Ui_VideoSettingsUi
+else:
+ from ui_videosettings import Ui_VideoSettingsUi
+
def box_value(box):