Qt
Internal/Contributor docs for the Qt SDK. Note: These are NOT official API docs; those are found at https://doc.qt.io/
Loading...
Searching...
No Matches
qohosmediacapturesession_p.h
Go to the documentation of this file.
1// Copyright (C) 2026 The Qt Company Ltd.
2// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR LGPL-3.0-only OR GPL-2.0-only OR GPL-3.0-only
3
4#ifndef QOHOSMEDIACAPTURESESSION_P_H
5#define QOHOSMEDIACAPTURESESSION_P_H
6
7//
8// W A R N I N G
9// -------------
10//
11// This file is not part of the Qt API. It exists purely as an
12// implementation detail. This header file may change from version to
13// version without notice, or even be removed.
14//
15// We mean it.
16//
17
18#include <private/qplatformmediacapture_p.h>
19
20#include <QtCore/qpointer.h>
21
23
24class QOhosCamera;
28
30{
32public:
35
36 QPlatformCamera *camera() override;
37 void setCamera(QPlatformCamera *camera) override;
39
41 void setImageCapture(QPlatformImageCapture *imageCapture) override;
42
44 void setMediaRecorder(QPlatformMediaRecorder *recorder) override;
45
46 void setAudioInput(QPlatformAudioInput *input) override;
47 void setAudioOutput(QPlatformAudioOutput *output) override;
48
49 QPlatformAudioInput *audioInput() const { return m_audioInput; }
50
51 void setVideoPreview(QVideoSink *sink) override;
52 QVideoSink *videoSink() const { return m_videoSink; }
53
54private:
55 QPointer<QOhosCamera> m_camera;
56 QPointer<QOhosImageCapture> m_imageCapture;
57 QPointer<QOhosMediaRecorder> m_recorder;
58 QPointer<QVideoSink> m_videoSink;
59 QPlatformAudioInput *m_audioInput{ nullptr };
60 QPlatformAudioOutput *m_audioOutput{ nullptr };
61};
62
63QT_END_NAMESPACE
64
65#endif // QOHOSMEDIACAPTURESESSION_P_H
The QCamera class provides interface for system camera devices.
Definition qcamera.h:25
int capture(const QString &fileName, bool toBuffer=false)
void recorderStateChanged(int state)
void setCamera(const QCameraDevice &camera)
void errorOccurred(int code, const QString &message)
qint64 recorderDuration() const
void imageCaptureError(int id, int error, const QString &message)
QImageEncoderSettings imageSettings() const
void imageSaved(int id, const QString &fileName)
void setActive(bool active)
void recorderErrorOccurred(int code, const QString &message)
QMediaRecorder::RecorderState recorderState() const
void onRecorderStateNotification(int state)
void setCameraFormat(const QCameraFormat &format)
void imageCaptured(int id, const QImage &preview)
void imageExposed(int id)
void readyForCaptureChanged(bool ready)
void recorderActualLocationChanged(const QUrl &url)
void onRecorderErrorNotification(int code, const QString &message)
QCameraDevice camera() const
QVideoSink * videoSink() const
QCameraFormat cameraFormat() const
void recorderDurationChanged(qint64 ms)
void setVideoSink(QVideoSink *sink)
bool startRecording(const QMediaEncoderSettings &settings, const QString &location)
void setImageSettings(const QImageEncoderSettings &settings)
void imageAvailable(int id, const QVideoFrame &frame)
bool setCameraFormat(const QCameraFormat &format) override
void setCaptureSession(QPlatformMediaCaptureSession *session) override
void setCamera(const QCameraDevice &camera) override
void setActive(bool active) override
bool isActive() const override
~QOhosCamera() override
QOhosCameraSession * session() const
QPlatformAudioInput * audioInput() const
void setCamera(QPlatformCamera *camera) override
void setAudioInput(QPlatformAudioInput *input) override
void setImageCapture(QPlatformImageCapture *imageCapture) override
void setVideoPreview(QVideoSink *sink) override
QPlatformCamera * camera() override
void setAudioOutput(QPlatformAudioOutput *output) override
void setMediaRecorder(QPlatformMediaRecorder *recorder) override
QOhosCameraSession * cameraSession() const
QPlatformMediaRecorder * mediaRecorder() override
QPlatformImageCapture * imageCapture() override
~QOhosMediaCaptureSession() override
Combined button and popup list for selecting options.