Qt
Internal/Contributor docs for the Qt SDK. <b>Note:</b> These are NOT official API docs; those are found <a href='https://doc.qt.io/'>here</a>.
Loading...
Searching...
No Matches
androidmediarecorder_p.h
Go to the documentation of this file.
1// Copyright (C) 2021 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 ANDROIDMEDIARECORDER_H
5#define ANDROIDMEDIARECORDER_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 <qobject.h>
19#include <QtCore/qjniobject.h>
20#include <qsize.h>
21
23
24class AndroidCamera;
27
65
67{
69public:
78
88
96
99 Camera = 1
100 };
101
112
115
116 void release();
117 bool prepare();
118 void reset();
119
120 bool start();
121 void stop();
122
123 void setAudioChannels(int numChannels);
124 void setAudioEncoder(AudioEncoder encoder);
125 void setAudioEncodingBitRate(int bitRate);
126 void setAudioSamplingRate(int samplingRate);
128 bool isAudioSourceSet() const;
129 bool setAudioInput(const QByteArray &id);
130
132 void setVideoEncoder(VideoEncoder encoder);
133 void setVideoEncodingBitRate(int bitRate);
134 void setVideoFrameRate(int rate);
135 void setVideoSize(const QSize &size);
137
138 void setOrientationHint(int degrees);
139
141 void setOutputFile(const QString &path);
142
145
146 static bool registerNativeMethods();
147
149 void error(int what, int extra);
150 void info(int what, int extra);
151
152private:
153 jlong m_id;
154 QJniObject m_mediaRecorder;
155 bool m_isAudioSourceSet = false;
156 bool m_isVideoSourceSet = false;
157};
158
160
161#endif // ANDROIDMEDIARECORDER_H
int getValue(Field field) const
static bool hasProfile(jint cameraId, Quality quality)
static AndroidCamcorderProfile get(jint cameraId, Quality quality)
bool setAudioInput(const QByteArray &id)
void setCamera(AndroidCamera *camera)
void setAudioEncodingBitRate(int bitRate)
void setVideoEncoder(VideoEncoder encoder)
void setAudioChannels(int numChannels)
void error(int what, int extra)
void setOutputFormat(OutputFormat format)
void setOrientationHint(int degrees)
void setAudioSamplingRate(int samplingRate)
void setAudioEncoder(AudioEncoder encoder)
void setVideoEncodingBitRate(int bitRate)
void setOutputFile(const QString &path)
void setVideoSize(const QSize &size)
void info(int what, int extra)
void setVideoSource(VideoSource source)
void setSurfaceTexture(AndroidSurfaceTexture *texture)
void setSurfaceHolder(AndroidSurfaceHolder *holder)
void setAudioSource(AudioSource source)
\inmodule QtCore
Definition qbytearray.h:57
\inmodule QtCore
\inmodule QtCore
Definition qobject.h:103
\inmodule QtCore
Definition qsize.h:25
\macro QT_RESTRICTED_CAST_FROM_ASCII
Definition qstring.h:129
QCamera * camera
Definition camera.cpp:19
Combined button and popup list for selecting options.
GLenum GLuint GLintptr GLsizeiptr size
[1]
GLenum GLuint texture
GLint GLsizei GLsizei GLenum format
GLsizei GLsizei GLchar * source
GLuint GLenum * rate
GLsizei const GLchar *const * path
#define Q_OBJECT
#define Q_SIGNALS