![]() |
Qt
Internal/Contributor docs for the Qt SDK. Note: These are NOT official API docs; those are found at https://doc.qt.io/
|
#include <qmediarecorder_p.h>
Public Member Functions | |
QMediaRecorderPrivate () | |
\qmltype MediaRecorder \nativetype QMediaRecorder |
Static Public Member Functions | |
static QString | msgFailedStartRecording () |
Public Attributes | |
QMediaCaptureSession * | captureSession = nullptr |
QPlatformMediaRecorder * | control = nullptr |
QString | initErrorMessage |
bool | autoStop = false |
bool | settingsChanged = false |
QMediaEncoderSettings | encoderSettings |
QMediaRecorder * | q_ptr = nullptr |
Definition at line 29 of file qmediarecorder_p.h.
QMediaRecorderPrivate::QMediaRecorderPrivate | ( | ) |
\qmltype MediaRecorder \nativetype QMediaRecorder
For encoding and recording media generated in a CaptureSession.
\inqmlmodule QtMultimedia
Use the MediaRecorder element within a CaptureSession to encode and record: \list
Performance of video encoding and recording is limited by the hardware, the operating system, the installed graphic drivers, and the input video format. If Camera
, ScreenCapture
, or WindowCapture
produces video frames faster than MediaRecorder
can encode and record them, the recorder may drop some frames. This is likely to occur if the input frame resolution is high, 4K for example, and hardware-accelerated encoding is unavailable.
\qml CaptureSession { id: captureSession camera: Camera { id: camera active: true } audioInput: AudioInput {} recorder: MediaRecorder { id: recorder } } \endqml
The code below shows how the recording can be started and stopped. \qml CameraButton { text: "Record" visible: recorder.recorderState !== MediaRecorder.RecordingState onClicked: recorder.record() }
CameraButton { id: stopButton text: "Stop" visible: recorder.recorderState === MediaRecorder.RecordingState onClicked: recorder.stop() } \endqml
Definition at line 122 of file qmediarecorder.cpp.
|
static |
Definition at line 131 of file qmediarecorder.cpp.
bool QMediaRecorderPrivate::autoStop = false |
Definition at line 41 of file qmediarecorder_p.h.
QMediaCaptureSession* QMediaRecorderPrivate::captureSession = nullptr |
Definition at line 38 of file qmediarecorder_p.h.
QPlatformMediaRecorder* QMediaRecorderPrivate::control = nullptr |
Definition at line 39 of file qmediarecorder_p.h.
Referenced by QAccessibleQuickControl::QAccessibleQuickControl().
QMediaEncoderSettings QMediaRecorderPrivate::encoderSettings |
Definition at line 45 of file qmediarecorder_p.h.
QString QMediaRecorderPrivate::initErrorMessage |
Definition at line 40 of file qmediarecorder_p.h.
QMediaRecorder* QMediaRecorderPrivate::q_ptr = nullptr |
Definition at line 47 of file qmediarecorder_p.h.
bool QMediaRecorderPrivate::settingsChanged = false |
Definition at line 43 of file qmediarecorder_p.h.