This commit is contained in:
rattatwinko
2025-05-25 20:42:58 +02:00
commit 8e9b2568b2
4902 changed files with 1152638 additions and 0 deletions

View File

@@ -0,0 +1,6 @@
# Automatically generated configuration for PyQt5.QtMultimedia.
sip-version = "6.8.6"
sip-abi-version = "12.15"
module-tags = ["Qt_5_15_14", "WS_X11"]
module-disabled-features = []

View File

@@ -0,0 +1,126 @@
// QtMultimediamod.sip generated by MetaSIP
//
// This file is part of the QtMultimedia Python extension module.
//
// Copyright (c) 2024 Riverbank Computing Limited <info@riverbankcomputing.com>
//
// This file is part of PyQt5.
//
// This file may be used under the terms of the GNU General Public License
// version 3.0 as published by the Free Software Foundation and appearing in
// the file LICENSE included in the packaging of this file. Please review the
// following information to ensure the GNU General Public License version 3.0
// requirements will be met: http://www.gnu.org/copyleft/gpl.html.
//
// If you do not wish to use this file under the terms of the GPL version 3.0
// then you may purchase a commercial license. For more information contact
// info@riverbankcomputing.com.
//
// This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE
// WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
%Module(name=PyQt5.QtMultimedia, keyword_arguments="Optional", use_limited_api=True)
%Import QtCore/QtCoremod.sip
%Import QtGui/QtGuimod.sip
%Import QtNetwork/QtNetworkmod.sip
%Copying
Copyright (c) 2024 Riverbank Computing Limited <info@riverbankcomputing.com>
This file is part of PyQt5.
This file may be used under the terms of the GNU General Public License
version 3.0 as published by the Free Software Foundation and appearing in
the file LICENSE included in the packaging of this file. Please review the
following information to ensure the GNU General Public License version 3.0
requirements will be met: http://www.gnu.org/copyleft/gpl.html.
If you do not wish to use this file under the terms of the GPL version 3.0
then you may purchase a commercial license. For more information contact
info@riverbankcomputing.com.
This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE
WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
%End
%DefaultSupertype sip.simplewrapper
%Include qabstractvideobuffer.sip
%Include qabstractvideofilter.sip
%Include qabstractvideosurface.sip
%Include qaudio.sip
%Include qaudiobuffer.sip
%Include qaudiodecoder.sip
%Include qaudiodecodercontrol.sip
%Include qaudiodeviceinfo.sip
%Include qaudioencodersettingscontrol.sip
%Include qaudioformat.sip
%Include qaudioinput.sip
%Include qaudioinputselectorcontrol.sip
%Include qaudiooutput.sip
%Include qaudiooutputselectorcontrol.sip
%Include qaudioprobe.sip
%Include qaudiorecorder.sip
%Include qaudiorolecontrol.sip
%Include qcamera.sip
%Include qcameracapturebufferformatcontrol.sip
%Include qcameracapturedestinationcontrol.sip
%Include qcameracontrol.sip
%Include qcameraexposure.sip
%Include qcameraexposurecontrol.sip
%Include qcamerafeedbackcontrol.sip
%Include qcameraflashcontrol.sip
%Include qcamerafocus.sip
%Include qcamerafocuscontrol.sip
%Include qcameraimagecapture.sip
%Include qcameraimagecapturecontrol.sip
%Include qcameraimageprocessing.sip
%Include qcameraimageprocessingcontrol.sip
%Include qcamerainfo.sip
%Include qcamerainfocontrol.sip
%Include qcameralockscontrol.sip
%Include qcameraviewfindersettings.sip
%Include qcameraviewfindersettingscontrol.sip
%Include qcamerazoomcontrol.sip
%Include qcustomaudiorolecontrol.sip
%Include qimageencodercontrol.sip
%Include qmediaaudioprobecontrol.sip
%Include qmediaavailabilitycontrol.sip
%Include qmediabindableinterface.sip
%Include qmediacontainercontrol.sip
%Include qmediacontent.sip
%Include qmediacontrol.sip
%Include qmediaencodersettings.sip
%Include qmediagaplessplaybackcontrol.sip
%Include qmediametadata.sip
%Include qmedianetworkaccesscontrol.sip
%Include qmediaobject.sip
%Include qmediaplayer.sip
%Include qmediaplayercontrol.sip
%Include qmediaplaylist.sip
%Include qmediarecorder.sip
%Include qmediarecordercontrol.sip
%Include qmediaresource.sip
%Include qmediaservice.sip
%Include qmediastreamscontrol.sip
%Include qmediatimerange.sip
%Include qmediavideoprobecontrol.sip
%Include qmetadatareadercontrol.sip
%Include qmetadatawritercontrol.sip
%Include qmultimedia.sip
%Include qradiodata.sip
%Include qradiodatacontrol.sip
%Include qradiotuner.sip
%Include qradiotunercontrol.sip
%Include qsound.sip
%Include qsoundeffect.sip
%Include qvideodeviceselectorcontrol.sip
%Include qvideoencodersettingscontrol.sip
%Include qvideoframe.sip
%Include qvideoprobe.sip
%Include qvideorenderercontrol.sip
%Include qvideosurfaceformat.sip
%Include qvideowindowcontrol.sip
%Include qpymultimedia_qlist.sip

View File

@@ -0,0 +1,83 @@
// qabstractvideobuffer.sip generated by MetaSIP
//
// This file is part of the QtMultimedia Python extension module.
//
// Copyright (c) 2024 Riverbank Computing Limited <info@riverbankcomputing.com>
//
// This file is part of PyQt5.
//
// This file may be used under the terms of the GNU General Public License
// version 3.0 as published by the Free Software Foundation and appearing in
// the file LICENSE included in the packaging of this file. Please review the
// following information to ensure the GNU General Public License version 3.0
// requirements will be met: http://www.gnu.org/copyleft/gpl.html.
//
// If you do not wish to use this file under the terms of the GPL version 3.0
// then you may purchase a commercial license. For more information contact
// info@riverbankcomputing.com.
//
// This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE
// WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
class QAbstractVideoBuffer
{
%TypeHeaderCode
#include <qabstractvideobuffer.h>
%End
public:
enum HandleType
{
NoHandle,
GLTextureHandle,
XvShmImageHandle,
CoreImageHandle,
QPixmapHandle,
%If (Qt_5_4_0 -)
EGLImageHandle,
%End
UserHandle,
};
enum MapMode
{
NotMapped,
ReadOnly,
WriteOnly,
ReadWrite,
};
QAbstractVideoBuffer(QAbstractVideoBuffer::HandleType type);
virtual ~QAbstractVideoBuffer();
QAbstractVideoBuffer::HandleType handleType() const;
virtual QAbstractVideoBuffer::MapMode mapMode() const = 0;
virtual SIP_PYOBJECT map(QAbstractVideoBuffer::MapMode mode, int *numBytes, int *bytesPerLine) = 0 /TypeHint="PyQt5.sip.voidptr"/ [uchar * (QAbstractVideoBuffer::MapMode mode, int *numBytes, int *bytesPerLine)];
%MethodCode
uchar *mem;
Py_BEGIN_ALLOW_THREADS
mem = sipCpp->map(a0, &a1, &a2);
Py_END_ALLOW_THREADS
if (mem)
{
if (a0 & QAbstractVideoBuffer::WriteOnly)
sipRes = sipConvertFromVoidPtrAndSize(mem, a1);
else
sipRes = sipConvertFromConstVoidPtrAndSize(mem, a1);
}
else
{
sipRes = Py_None;
Py_INCREF(sipRes);
}
%End
virtual void unmap() = 0;
virtual QVariant handle() const;
virtual void release();
private:
QAbstractVideoBuffer(const QAbstractVideoBuffer &);
};

View File

@@ -0,0 +1,64 @@
// qabstractvideofilter.sip generated by MetaSIP
//
// This file is part of the QtMultimedia Python extension module.
//
// Copyright (c) 2024 Riverbank Computing Limited <info@riverbankcomputing.com>
//
// This file is part of PyQt5.
//
// This file may be used under the terms of the GNU General Public License
// version 3.0 as published by the Free Software Foundation and appearing in
// the file LICENSE included in the packaging of this file. Please review the
// following information to ensure the GNU General Public License version 3.0
// requirements will be met: http://www.gnu.org/copyleft/gpl.html.
//
// If you do not wish to use this file under the terms of the GPL version 3.0
// then you may purchase a commercial license. For more information contact
// info@riverbankcomputing.com.
//
// This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE
// WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
%If (Qt_5_5_0 -)
class QVideoFilterRunnable
{
%TypeHeaderCode
#include <qabstractvideofilter.h>
%End
public:
enum RunFlag
{
LastInChain,
};
typedef QFlags<QVideoFilterRunnable::RunFlag> RunFlags;
virtual ~QVideoFilterRunnable() /ReleaseGIL/;
virtual QVideoFrame run(QVideoFrame *input, const QVideoSurfaceFormat &surfaceFormat, QVideoFilterRunnable::RunFlags flags) = 0 /ReleaseGIL/;
};
%End
%If (Qt_5_5_0 -)
QFlags<QVideoFilterRunnable::RunFlag> operator|(QVideoFilterRunnable::RunFlag f1, QFlags<QVideoFilterRunnable::RunFlag> f2);
%End
%If (Qt_5_5_0 -)
class QAbstractVideoFilter : public QObject
{
%TypeHeaderCode
#include <qabstractvideofilter.h>
%End
public:
explicit QAbstractVideoFilter(QObject *parent /TransferThis/ = 0);
virtual ~QAbstractVideoFilter();
bool isActive() const;
virtual QVideoFilterRunnable *createFilterRunnable() = 0 /ReleaseGIL/;
signals:
void activeChanged();
};
%End

View File

@@ -0,0 +1,167 @@
// qabstractvideosurface.sip generated by MetaSIP
//
// This file is part of the QtMultimedia Python extension module.
//
// Copyright (c) 2024 Riverbank Computing Limited <info@riverbankcomputing.com>
//
// This file is part of PyQt5.
//
// This file may be used under the terms of the GNU General Public License
// version 3.0 as published by the Free Software Foundation and appearing in
// the file LICENSE included in the packaging of this file. Please review the
// following information to ensure the GNU General Public License version 3.0
// requirements will be met: http://www.gnu.org/copyleft/gpl.html.
//
// If you do not wish to use this file under the terms of the GPL version 3.0
// then you may purchase a commercial license. For more information contact
// info@riverbankcomputing.com.
//
// This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE
// WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
class QAbstractVideoSurface : public QObject
{
%TypeHeaderCode
#include <qabstractvideosurface.h>
%End
%ConvertToSubClassCode
static struct class_graph {
const char *name;
sipTypeDef **type;
int yes, no;
} graph[] = {
#if QT_VERSION >= 0x050500
{sipName_QAbstractVideoFilter, &sipType_QAbstractVideoFilter, -1, 1},
#else
{0, 0, -1, 1},
#endif
{sipName_QAbstractVideoSurface, &sipType_QAbstractVideoSurface, -1, 2},
{sipName_QMediaObject, &sipType_QMediaObject, 18, 3},
{sipName_QMediaControl, &sipType_QMediaControl, 22, 4},
{sipName_QAudioInput, &sipType_QAudioInput, -1, 5},
{sipName_QAudioOutput, &sipType_QAudioOutput, -1, 6},
{sipName_QAudioProbe, &sipType_QAudioProbe, -1, 7},
{sipName_QMediaRecorder, &sipType_QMediaRecorder, 60, 8},
{sipName_QCameraExposure, &sipType_QCameraExposure, -1, 9},
{sipName_QCameraFocus, &sipType_QCameraFocus, -1, 10},
{sipName_QCameraImageCapture, &sipType_QCameraImageCapture, -1, 11},
{sipName_QCameraImageProcessing, &sipType_QCameraImageProcessing, -1, 12},
{sipName_QMediaPlaylist, &sipType_QMediaPlaylist, -1, 13},
{sipName_QMediaService, &sipType_QMediaService, -1, 14},
{sipName_QRadioData, &sipType_QRadioData, -1, 15},
{sipName_QSound, &sipType_QSound, -1, 16},
{sipName_QSoundEffect, &sipType_QSoundEffect, -1, 17},
{sipName_QVideoProbe, &sipType_QVideoProbe, -1, -1},
{sipName_QAudioDecoder, &sipType_QAudioDecoder, -1, 19},
{sipName_QCamera, &sipType_QCamera, -1, 20},
{sipName_QMediaPlayer, &sipType_QMediaPlayer, -1, 21},
{sipName_QRadioTuner, &sipType_QRadioTuner, -1, -1},
{sipName_QAudioDecoderControl, &sipType_QAudioDecoderControl, -1, 23},
{sipName_QAudioEncoderSettingsControl, &sipType_QAudioEncoderSettingsControl, -1, 24},
{sipName_QAudioInputSelectorControl, &sipType_QAudioInputSelectorControl, -1, 25},
{sipName_QAudioOutputSelectorControl, &sipType_QAudioOutputSelectorControl, -1, 26},
#if QT_VERSION >= 0x050600
{sipName_QAudioRoleControl, &sipType_QAudioRoleControl, -1, 27},
#else
{0, 0, -1, 27},
#endif
{sipName_QCameraCaptureBufferFormatControl, &sipType_QCameraCaptureBufferFormatControl, -1, 28},
{sipName_QCameraCaptureDestinationControl, &sipType_QCameraCaptureDestinationControl, -1, 29},
{sipName_QCameraControl, &sipType_QCameraControl, -1, 30},
{sipName_QCameraExposureControl, &sipType_QCameraExposureControl, -1, 31},
{sipName_QCameraFeedbackControl, &sipType_QCameraFeedbackControl, -1, 32},
{sipName_QCameraFlashControl, &sipType_QCameraFlashControl, -1, 33},
{sipName_QCameraFocusControl, &sipType_QCameraFocusControl, -1, 34},
{sipName_QCameraImageCaptureControl, &sipType_QCameraImageCaptureControl, -1, 35},
{sipName_QCameraImageProcessingControl, &sipType_QCameraImageProcessingControl, -1, 36},
{sipName_QCameraInfoControl, &sipType_QCameraInfoControl, -1, 37},
{sipName_QCameraLocksControl, &sipType_QCameraLocksControl, -1, 38},
{sipName_QCameraViewfinderSettingsControl, &sipType_QCameraViewfinderSettingsControl, -1, 39},
{sipName_QCameraViewfinderSettingsControl2, &sipType_QCameraViewfinderSettingsControl2, -1, 40},
{sipName_QCameraZoomControl, &sipType_QCameraZoomControl, -1, 41},
#if QT_VERSION >= 0x050b00
{sipName_QCustomAudioRoleControl, &sipType_QCustomAudioRoleControl, -1, 42},
#else
{0, 0, -1, 42},
#endif
{sipName_QImageEncoderControl, &sipType_QImageEncoderControl, -1, 43},
{sipName_QMediaAudioProbeControl, &sipType_QMediaAudioProbeControl, -1, 44},
{sipName_QMediaAvailabilityControl, &sipType_QMediaAvailabilityControl, -1, 45},
{sipName_QMediaContainerControl, &sipType_QMediaContainerControl, -1, 46},
{sipName_QMediaGaplessPlaybackControl, &sipType_QMediaGaplessPlaybackControl, -1, 47},
{sipName_QMediaNetworkAccessControl, &sipType_QMediaNetworkAccessControl, -1, 48},
{sipName_QMediaPlayerControl, &sipType_QMediaPlayerControl, -1, 49},
{sipName_QMediaRecorderControl, &sipType_QMediaRecorderControl, -1, 50},
{sipName_QMediaStreamsControl, &sipType_QMediaStreamsControl, -1, 51},
{sipName_QMediaVideoProbeControl, &sipType_QMediaVideoProbeControl, -1, 52},
{sipName_QMetaDataReaderControl, &sipType_QMetaDataReaderControl, -1, 53},
{sipName_QMetaDataWriterControl, &sipType_QMetaDataWriterControl, -1, 54},
{sipName_QRadioDataControl, &sipType_QRadioDataControl, -1, 55},
{sipName_QRadioTunerControl, &sipType_QRadioTunerControl, -1, 56},
{sipName_QVideoDeviceSelectorControl, &sipType_QVideoDeviceSelectorControl, -1, 57},
{sipName_QVideoEncoderSettingsControl, &sipType_QVideoEncoderSettingsControl, -1, 58},
{sipName_QVideoRendererControl, &sipType_QVideoRendererControl, -1, 59},
{sipName_QVideoWindowControl, &sipType_QVideoWindowControl, -1, -1},
{sipName_QAudioRecorder, &sipType_QAudioRecorder, -1, -1},
};
int i = 0;
sipType = NULL;
do
{
struct class_graph *cg = &graph[i];
if (cg->name != NULL && sipCpp->inherits(cg->name))
{
sipType = *cg->type;
i = cg->yes;
}
else
i = cg->no;
}
while (i >= 0);
%End
public:
enum Error
{
NoError,
UnsupportedFormatError,
IncorrectFormatError,
StoppedError,
ResourceError,
};
explicit QAbstractVideoSurface(QObject *parent /TransferThis/ = 0);
virtual ~QAbstractVideoSurface();
virtual QList<QVideoFrame::PixelFormat> supportedPixelFormats(QAbstractVideoBuffer::HandleType type = QAbstractVideoBuffer::NoHandle) const = 0;
virtual bool isFormatSupported(const QVideoSurfaceFormat &format) const;
virtual QVideoSurfaceFormat nearestFormat(const QVideoSurfaceFormat &format) const;
QVideoSurfaceFormat surfaceFormat() const;
virtual bool start(const QVideoSurfaceFormat &format);
virtual void stop();
bool isActive() const;
virtual bool present(const QVideoFrame &frame) = 0;
QAbstractVideoSurface::Error error() const;
signals:
void activeChanged(bool active);
void surfaceFormatChanged(const QVideoSurfaceFormat &format);
void supportedFormatsChanged();
protected:
void setError(QAbstractVideoSurface::Error error);
public:
QSize nativeResolution() const;
protected:
void setNativeResolution(const QSize &resolution);
signals:
void nativeResolutionChanged(const QSize &);
};

View File

@@ -0,0 +1,89 @@
// qaudio.sip generated by MetaSIP
//
// This file is part of the QtMultimedia Python extension module.
//
// Copyright (c) 2024 Riverbank Computing Limited <info@riverbankcomputing.com>
//
// This file is part of PyQt5.
//
// This file may be used under the terms of the GNU General Public License
// version 3.0 as published by the Free Software Foundation and appearing in
// the file LICENSE included in the packaging of this file. Please review the
// following information to ensure the GNU General Public License version 3.0
// requirements will be met: http://www.gnu.org/copyleft/gpl.html.
//
// If you do not wish to use this file under the terms of the GPL version 3.0
// then you may purchase a commercial license. For more information contact
// info@riverbankcomputing.com.
//
// This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE
// WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
namespace QAudio
{
%TypeHeaderCode
#include <qaudio.h>
%End
enum Error
{
NoError,
OpenError,
IOError,
UnderrunError,
FatalError,
};
enum State
{
ActiveState,
SuspendedState,
StoppedState,
IdleState,
%If (Qt_5_10_0 -)
InterruptedState,
%End
};
enum Mode
{
AudioInput,
AudioOutput,
};
%If (Qt_5_6_0 -)
enum Role
{
UnknownRole,
MusicRole,
VideoRole,
VoiceCommunicationRole,
AlarmRole,
NotificationRole,
RingtoneRole,
AccessibilityRole,
SonificationRole,
GameRole,
%If (Qt_5_11_0 -)
CustomRole,
%End
};
%End
%If (Qt_5_8_0 -)
enum VolumeScale
{
LinearVolumeScale,
CubicVolumeScale,
LogarithmicVolumeScale,
DecibelVolumeScale,
};
%End
%If (Qt_5_8_0 -)
qreal convertVolume(qreal volume, QAudio::VolumeScale from, QAudio::VolumeScale to);
%End
};

View File

@@ -0,0 +1,44 @@
// qaudiobuffer.sip generated by MetaSIP
//
// This file is part of the QtMultimedia Python extension module.
//
// Copyright (c) 2024 Riverbank Computing Limited <info@riverbankcomputing.com>
//
// This file is part of PyQt5.
//
// This file may be used under the terms of the GNU General Public License
// version 3.0 as published by the Free Software Foundation and appearing in
// the file LICENSE included in the packaging of this file. Please review the
// following information to ensure the GNU General Public License version 3.0
// requirements will be met: http://www.gnu.org/copyleft/gpl.html.
//
// If you do not wish to use this file under the terms of the GPL version 3.0
// then you may purchase a commercial license. For more information contact
// info@riverbankcomputing.com.
//
// This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE
// WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
class QAudioBuffer
{
%TypeHeaderCode
#include <qaudiobuffer.h>
%End
public:
QAudioBuffer();
QAudioBuffer(const QByteArray &data, const QAudioFormat &format, qint64 startTime = -1);
QAudioBuffer(int numFrames, const QAudioFormat &format, qint64 startTime = -1);
QAudioBuffer(const QAudioBuffer &other);
~QAudioBuffer();
bool isValid() const;
QAudioFormat format() const;
int frameCount() const;
int sampleCount() const;
int byteCount() const;
qint64 duration() const;
qint64 startTime() const;
const void *constData() const;
void *data();
};

View File

@@ -0,0 +1,85 @@
// qaudiodecoder.sip generated by MetaSIP
//
// This file is part of the QtMultimedia Python extension module.
//
// Copyright (c) 2024 Riverbank Computing Limited <info@riverbankcomputing.com>
//
// This file is part of PyQt5.
//
// This file may be used under the terms of the GNU General Public License
// version 3.0 as published by the Free Software Foundation and appearing in
// the file LICENSE included in the packaging of this file. Please review the
// following information to ensure the GNU General Public License version 3.0
// requirements will be met: http://www.gnu.org/copyleft/gpl.html.
//
// If you do not wish to use this file under the terms of the GPL version 3.0
// then you may purchase a commercial license. For more information contact
// info@riverbankcomputing.com.
//
// This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE
// WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
class QAudioDecoder : public QMediaObject
{
%TypeHeaderCode
#include <qaudiodecoder.h>
%End
public:
enum State
{
StoppedState,
DecodingState,
};
enum Error
{
NoError,
ResourceError,
FormatError,
AccessDeniedError,
ServiceMissingError,
};
%If (Qt_5_6_1 -)
explicit QAudioDecoder(QObject *parent /TransferThis/ = 0);
%End
%If (- Qt_5_6_1)
QAudioDecoder(QObject *parent /TransferThis/ = 0);
%End
virtual ~QAudioDecoder();
static QMultimedia::SupportEstimate hasSupport(const QString &mimeType, const QStringList &codecs = QStringList());
QAudioDecoder::State state() const;
QString sourceFilename() const;
void setSourceFilename(const QString &fileName);
QIODevice *sourceDevice() const;
void setSourceDevice(QIODevice *device);
QAudioFormat audioFormat() const;
void setAudioFormat(const QAudioFormat &format);
QAudioDecoder::Error error() const;
QString errorString() const;
QAudioBuffer read() const;
bool bufferAvailable() const;
qint64 position() const;
qint64 duration() const;
public slots:
void start();
void stop();
signals:
void bufferAvailableChanged(bool);
void bufferReady();
void finished();
void stateChanged(QAudioDecoder::State newState);
void formatChanged(const QAudioFormat &format);
void error(QAudioDecoder::Error error);
void sourceChanged();
void positionChanged(qint64 position);
void durationChanged(qint64 duration);
public:
virtual bool bind(QObject *);
virtual void unbind(QObject *);
};

View File

@@ -0,0 +1,58 @@
// qaudiodecodercontrol.sip generated by MetaSIP
//
// This file is part of the QtMultimedia Python extension module.
//
// Copyright (c) 2024 Riverbank Computing Limited <info@riverbankcomputing.com>
//
// This file is part of PyQt5.
//
// This file may be used under the terms of the GNU General Public License
// version 3.0 as published by the Free Software Foundation and appearing in
// the file LICENSE included in the packaging of this file. Please review the
// following information to ensure the GNU General Public License version 3.0
// requirements will be met: http://www.gnu.org/copyleft/gpl.html.
//
// If you do not wish to use this file under the terms of the GPL version 3.0
// then you may purchase a commercial license. For more information contact
// info@riverbankcomputing.com.
//
// This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE
// WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
class QAudioDecoderControl : public QMediaControl
{
%TypeHeaderCode
#include <qaudiodecodercontrol.h>
%End
public:
virtual ~QAudioDecoderControl();
virtual QAudioDecoder::State state() const = 0;
virtual QString sourceFilename() const = 0;
virtual void setSourceFilename(const QString &fileName) = 0;
virtual QIODevice *sourceDevice() const = 0;
virtual void setSourceDevice(QIODevice *device) = 0;
virtual void start() = 0;
virtual void stop() = 0;
virtual QAudioFormat audioFormat() const = 0;
virtual void setAudioFormat(const QAudioFormat &format) = 0;
virtual QAudioBuffer read() = 0;
virtual bool bufferAvailable() const = 0;
virtual qint64 position() const = 0;
virtual qint64 duration() const = 0;
signals:
void stateChanged(QAudioDecoder::State newState);
void formatChanged(const QAudioFormat &format);
void sourceChanged();
void error(int error, const QString &errorString);
void bufferReady();
void bufferAvailableChanged(bool available);
void finished();
void positionChanged(qint64 position);
void durationChanged(qint64 duration);
protected:
explicit QAudioDecoderControl(QObject *parent /TransferThis/ = 0);
};

View File

@@ -0,0 +1,52 @@
// qaudiodeviceinfo.sip generated by MetaSIP
//
// This file is part of the QtMultimedia Python extension module.
//
// Copyright (c) 2024 Riverbank Computing Limited <info@riverbankcomputing.com>
//
// This file is part of PyQt5.
//
// This file may be used under the terms of the GNU General Public License
// version 3.0 as published by the Free Software Foundation and appearing in
// the file LICENSE included in the packaging of this file. Please review the
// following information to ensure the GNU General Public License version 3.0
// requirements will be met: http://www.gnu.org/copyleft/gpl.html.
//
// If you do not wish to use this file under the terms of the GPL version 3.0
// then you may purchase a commercial license. For more information contact
// info@riverbankcomputing.com.
//
// This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE
// WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
class QAudioDeviceInfo
{
%TypeHeaderCode
#include <qaudiodeviceinfo.h>
%End
public:
QAudioDeviceInfo();
QAudioDeviceInfo(const QAudioDeviceInfo &other);
~QAudioDeviceInfo();
bool isNull() const;
QString deviceName() const;
bool isFormatSupported(const QAudioFormat &format) const;
QAudioFormat preferredFormat() const;
QAudioFormat nearestFormat(const QAudioFormat &format) const;
QStringList supportedCodecs() const;
QList<int> supportedSampleSizes() const;
QList<QAudioFormat::Endian> supportedByteOrders() const;
QList<QAudioFormat::SampleType> supportedSampleTypes() const;
static QAudioDeviceInfo defaultInputDevice();
static QAudioDeviceInfo defaultOutputDevice();
static QList<QAudioDeviceInfo> availableDevices(QAudio::Mode mode);
QList<int> supportedSampleRates() const;
QList<int> supportedChannelCounts() const;
bool operator==(const QAudioDeviceInfo &other) const;
bool operator!=(const QAudioDeviceInfo &other) const;
%If (Qt_5_14_0 -)
QString realm() const;
%End
};

View File

@@ -0,0 +1,39 @@
// qaudioencodersettingscontrol.sip generated by MetaSIP
//
// This file is part of the QtMultimedia Python extension module.
//
// Copyright (c) 2024 Riverbank Computing Limited <info@riverbankcomputing.com>
//
// This file is part of PyQt5.
//
// This file may be used under the terms of the GNU General Public License
// version 3.0 as published by the Free Software Foundation and appearing in
// the file LICENSE included in the packaging of this file. Please review the
// following information to ensure the GNU General Public License version 3.0
// requirements will be met: http://www.gnu.org/copyleft/gpl.html.
//
// If you do not wish to use this file under the terms of the GPL version 3.0
// then you may purchase a commercial license. For more information contact
// info@riverbankcomputing.com.
//
// This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE
// WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
class QAudioEncoderSettingsControl : public QMediaControl
{
%TypeHeaderCode
#include <qaudioencodersettingscontrol.h>
%End
public:
virtual ~QAudioEncoderSettingsControl();
virtual QStringList supportedAudioCodecs() const = 0;
virtual QString codecDescription(const QString &codecName) const = 0;
virtual QList<int> supportedSampleRates(const QAudioEncoderSettings &settings, bool *continuous = 0) const = 0;
virtual QAudioEncoderSettings audioSettings() const = 0;
virtual void setAudioSettings(const QAudioEncoderSettings &settings) = 0;
protected:
explicit QAudioEncoderSettingsControl(QObject *parent /TransferThis/ = 0);
};

View File

@@ -0,0 +1,69 @@
// qaudioformat.sip generated by MetaSIP
//
// This file is part of the QtMultimedia Python extension module.
//
// Copyright (c) 2024 Riverbank Computing Limited <info@riverbankcomputing.com>
//
// This file is part of PyQt5.
//
// This file may be used under the terms of the GNU General Public License
// version 3.0 as published by the Free Software Foundation and appearing in
// the file LICENSE included in the packaging of this file. Please review the
// following information to ensure the GNU General Public License version 3.0
// requirements will be met: http://www.gnu.org/copyleft/gpl.html.
//
// If you do not wish to use this file under the terms of the GPL version 3.0
// then you may purchase a commercial license. For more information contact
// info@riverbankcomputing.com.
//
// This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE
// WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
class QAudioFormat
{
%TypeHeaderCode
#include <qaudioformat.h>
%End
public:
enum SampleType
{
Unknown,
SignedInt,
UnSignedInt,
Float,
};
enum Endian
{
BigEndian,
LittleEndian,
};
QAudioFormat();
QAudioFormat(const QAudioFormat &other);
~QAudioFormat();
bool operator==(const QAudioFormat &other) const;
bool operator!=(const QAudioFormat &other) const;
bool isValid() const;
void setSampleSize(int sampleSize);
int sampleSize() const;
void setCodec(const QString &codec);
QString codec() const;
void setByteOrder(QAudioFormat::Endian byteOrder);
QAudioFormat::Endian byteOrder() const;
void setSampleType(QAudioFormat::SampleType sampleType);
QAudioFormat::SampleType sampleType() const;
void setSampleRate(int sampleRate);
int sampleRate() const;
void setChannelCount(int channelCount);
int channelCount() const;
qint32 bytesForDuration(qint64 duration) const;
qint64 durationForBytes(qint32 byteCount) const;
qint32 bytesForFrames(qint32 frameCount) const;
qint32 framesForBytes(qint32 byteCount) const;
qint32 framesForDuration(qint64 duration) const;
qint64 durationForFrames(qint32 frameCount) const;
int bytesPerFrame() const;
};

View File

@@ -0,0 +1,58 @@
// qaudioinput.sip generated by MetaSIP
//
// This file is part of the QtMultimedia Python extension module.
//
// Copyright (c) 2024 Riverbank Computing Limited <info@riverbankcomputing.com>
//
// This file is part of PyQt5.
//
// This file may be used under the terms of the GNU General Public License
// version 3.0 as published by the Free Software Foundation and appearing in
// the file LICENSE included in the packaging of this file. Please review the
// following information to ensure the GNU General Public License version 3.0
// requirements will be met: http://www.gnu.org/copyleft/gpl.html.
//
// If you do not wish to use this file under the terms of the GPL version 3.0
// then you may purchase a commercial license. For more information contact
// info@riverbankcomputing.com.
//
// This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE
// WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
class QAudioInput : public QObject
{
%TypeHeaderCode
#include <qaudioinput.h>
%End
public:
QAudioInput(const QAudioFormat &format = QAudioFormat(), QObject *parent /TransferThis/ = 0);
QAudioInput(const QAudioDeviceInfo &audioDevice, const QAudioFormat &format = QAudioFormat(), QObject *parent /TransferThis/ = 0);
virtual ~QAudioInput();
QAudioFormat format() const;
void start(QIODevice *device);
QIODevice *start();
void stop();
void reset();
void suspend();
void resume();
void setBufferSize(int bytes);
int bufferSize() const;
int bytesReady() const;
int periodSize() const;
void setNotifyInterval(int milliSeconds);
int notifyInterval() const;
qint64 processedUSecs() const;
qint64 elapsedUSecs() const;
QAudio::Error error() const;
QAudio::State state() const;
signals:
void stateChanged(QAudio::State);
void notify();
public:
void setVolume(qreal volume);
qreal volume() const;
};

View File

@@ -0,0 +1,45 @@
// qaudioinputselectorcontrol.sip generated by MetaSIP
//
// This file is part of the QtMultimedia Python extension module.
//
// Copyright (c) 2024 Riverbank Computing Limited <info@riverbankcomputing.com>
//
// This file is part of PyQt5.
//
// This file may be used under the terms of the GNU General Public License
// version 3.0 as published by the Free Software Foundation and appearing in
// the file LICENSE included in the packaging of this file. Please review the
// following information to ensure the GNU General Public License version 3.0
// requirements will be met: http://www.gnu.org/copyleft/gpl.html.
//
// If you do not wish to use this file under the terms of the GPL version 3.0
// then you may purchase a commercial license. For more information contact
// info@riverbankcomputing.com.
//
// This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE
// WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
class QAudioInputSelectorControl : public QMediaControl
{
%TypeHeaderCode
#include <qaudioinputselectorcontrol.h>
%End
public:
virtual ~QAudioInputSelectorControl();
virtual QList<QString> availableInputs() const = 0;
virtual QString inputDescription(const QString &name) const = 0;
virtual QString defaultInput() const = 0;
virtual QString activeInput() const = 0;
public slots:
virtual void setActiveInput(const QString &name) = 0;
signals:
void activeInputChanged(const QString &name);
void availableInputsChanged();
protected:
explicit QAudioInputSelectorControl(QObject *parent /TransferThis/ = 0);
};

View File

@@ -0,0 +1,60 @@
// qaudiooutput.sip generated by MetaSIP
//
// This file is part of the QtMultimedia Python extension module.
//
// Copyright (c) 2024 Riverbank Computing Limited <info@riverbankcomputing.com>
//
// This file is part of PyQt5.
//
// This file may be used under the terms of the GNU General Public License
// version 3.0 as published by the Free Software Foundation and appearing in
// the file LICENSE included in the packaging of this file. Please review the
// following information to ensure the GNU General Public License version 3.0
// requirements will be met: http://www.gnu.org/copyleft/gpl.html.
//
// If you do not wish to use this file under the terms of the GPL version 3.0
// then you may purchase a commercial license. For more information contact
// info@riverbankcomputing.com.
//
// This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE
// WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
class QAudioOutput : public QObject
{
%TypeHeaderCode
#include <qaudiooutput.h>
%End
public:
QAudioOutput(const QAudioFormat &format = QAudioFormat(), QObject *parent /TransferThis/ = 0);
QAudioOutput(const QAudioDeviceInfo &audioDevice, const QAudioFormat &format = QAudioFormat(), QObject *parent /TransferThis/ = 0);
virtual ~QAudioOutput();
QAudioFormat format() const;
void start(QIODevice *device);
QIODevice *start();
void stop();
void reset();
void suspend();
void resume();
void setBufferSize(int bytes);
int bufferSize() const;
int bytesFree() const;
int periodSize() const;
void setNotifyInterval(int milliSeconds);
int notifyInterval() const;
qint64 processedUSecs() const;
qint64 elapsedUSecs() const;
QAudio::Error error() const;
QAudio::State state() const;
signals:
void stateChanged(QAudio::State);
void notify();
public:
void setVolume(qreal);
qreal volume() const;
QString category() const;
void setCategory(const QString &category);
};

View File

@@ -0,0 +1,45 @@
// qaudiooutputselectorcontrol.sip generated by MetaSIP
//
// This file is part of the QtMultimedia Python extension module.
//
// Copyright (c) 2024 Riverbank Computing Limited <info@riverbankcomputing.com>
//
// This file is part of PyQt5.
//
// This file may be used under the terms of the GNU General Public License
// version 3.0 as published by the Free Software Foundation and appearing in
// the file LICENSE included in the packaging of this file. Please review the
// following information to ensure the GNU General Public License version 3.0
// requirements will be met: http://www.gnu.org/copyleft/gpl.html.
//
// If you do not wish to use this file under the terms of the GPL version 3.0
// then you may purchase a commercial license. For more information contact
// info@riverbankcomputing.com.
//
// This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE
// WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
class QAudioOutputSelectorControl : public QMediaControl
{
%TypeHeaderCode
#include <qaudiooutputselectorcontrol.h>
%End
public:
virtual ~QAudioOutputSelectorControl();
virtual QList<QString> availableOutputs() const = 0;
virtual QString outputDescription(const QString &name) const = 0;
virtual QString defaultOutput() const = 0;
virtual QString activeOutput() const = 0;
public slots:
virtual void setActiveOutput(const QString &name) = 0;
signals:
void activeOutputChanged(const QString &name);
void availableOutputsChanged();
protected:
explicit QAudioOutputSelectorControl(QObject *parent /TransferThis/ = 0);
};

View File

@@ -0,0 +1,39 @@
// qaudioprobe.sip generated by MetaSIP
//
// This file is part of the QtMultimedia Python extension module.
//
// Copyright (c) 2024 Riverbank Computing Limited <info@riverbankcomputing.com>
//
// This file is part of PyQt5.
//
// This file may be used under the terms of the GNU General Public License
// version 3.0 as published by the Free Software Foundation and appearing in
// the file LICENSE included in the packaging of this file. Please review the
// following information to ensure the GNU General Public License version 3.0
// requirements will be met: http://www.gnu.org/copyleft/gpl.html.
//
// If you do not wish to use this file under the terms of the GPL version 3.0
// then you may purchase a commercial license. For more information contact
// info@riverbankcomputing.com.
//
// This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE
// WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
class QAudioProbe : public QObject
{
%TypeHeaderCode
#include <qaudioprobe.h>
%End
public:
explicit QAudioProbe(QObject *parent /TransferThis/ = 0);
virtual ~QAudioProbe();
bool setSource(QMediaObject *source);
bool setSource(QMediaRecorder *source);
bool isActive() const;
signals:
void audioBufferProbed(const QAudioBuffer &audioBuffer);
void flush();
};

View File

@@ -0,0 +1,48 @@
// qaudiorecorder.sip generated by MetaSIP
//
// This file is part of the QtMultimedia Python extension module.
//
// Copyright (c) 2024 Riverbank Computing Limited <info@riverbankcomputing.com>
//
// This file is part of PyQt5.
//
// This file may be used under the terms of the GNU General Public License
// version 3.0 as published by the Free Software Foundation and appearing in
// the file LICENSE included in the packaging of this file. Please review the
// following information to ensure the GNU General Public License version 3.0
// requirements will be met: http://www.gnu.org/copyleft/gpl.html.
//
// If you do not wish to use this file under the terms of the GPL version 3.0
// then you may purchase a commercial license. For more information contact
// info@riverbankcomputing.com.
//
// This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE
// WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
class QAudioRecorder : public QMediaRecorder
{
%TypeHeaderCode
#include <qaudiorecorder.h>
%End
public:
%If (Qt_5_6_1 -)
explicit QAudioRecorder(QObject *parent /TransferThis/ = 0);
%End
%If (- Qt_5_6_1)
QAudioRecorder(QObject *parent /TransferThis/ = 0);
%End
virtual ~QAudioRecorder();
QStringList audioInputs() const;
QString defaultAudioInput() const;
QString audioInputDescription(const QString &name) const;
QString audioInput() const;
public slots:
void setAudioInput(const QString &name);
signals:
void audioInputChanged(const QString &name);
void availableAudioInputsChanged();
};

View File

@@ -0,0 +1,44 @@
// qaudiorolecontrol.sip generated by MetaSIP
//
// This file is part of the QtMultimedia Python extension module.
//
// Copyright (c) 2024 Riverbank Computing Limited <info@riverbankcomputing.com>
//
// This file is part of PyQt5.
//
// This file may be used under the terms of the GNU General Public License
// version 3.0 as published by the Free Software Foundation and appearing in
// the file LICENSE included in the packaging of this file. Please review the
// following information to ensure the GNU General Public License version 3.0
// requirements will be met: http://www.gnu.org/copyleft/gpl.html.
//
// If you do not wish to use this file under the terms of the GPL version 3.0
// then you may purchase a commercial license. For more information contact
// info@riverbankcomputing.com.
//
// This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE
// WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
%If (Qt_5_6_0 -)
class QAudioRoleControl : public QMediaControl
{
%TypeHeaderCode
#include <qaudiorolecontrol.h>
%End
public:
virtual ~QAudioRoleControl();
virtual QAudio::Role audioRole() const = 0;
virtual void setAudioRole(QAudio::Role role) = 0;
virtual QList<QAudio::Role> supportedAudioRoles() const = 0;
signals:
void audioRoleChanged(QAudio::Role role);
protected:
explicit QAudioRoleControl(QObject *parent /TransferThis/ = 0);
};
%End

View File

@@ -0,0 +1,203 @@
// qcamera.sip generated by MetaSIP
//
// This file is part of the QtMultimedia Python extension module.
//
// Copyright (c) 2024 Riverbank Computing Limited <info@riverbankcomputing.com>
//
// This file is part of PyQt5.
//
// This file may be used under the terms of the GNU General Public License
// version 3.0 as published by the Free Software Foundation and appearing in
// the file LICENSE included in the packaging of this file. Please review the
// following information to ensure the GNU General Public License version 3.0
// requirements will be met: http://www.gnu.org/copyleft/gpl.html.
//
// If you do not wish to use this file under the terms of the GPL version 3.0
// then you may purchase a commercial license. For more information contact
// info@riverbankcomputing.com.
//
// This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE
// WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
class QCamera : public QMediaObject
{
%TypeHeaderCode
#include <qcamera.h>
%End
public:
enum Status
{
UnavailableStatus,
UnloadedStatus,
LoadingStatus,
UnloadingStatus,
LoadedStatus,
StandbyStatus,
StartingStatus,
StoppingStatus,
ActiveStatus,
};
enum State
{
UnloadedState,
LoadedState,
ActiveState,
};
enum CaptureMode
{
CaptureViewfinder,
CaptureStillImage,
CaptureVideo,
};
typedef QFlags<QCamera::CaptureMode> CaptureModes;
enum Error
{
NoError,
CameraError,
InvalidRequestError,
ServiceMissingError,
NotSupportedFeatureError,
};
enum LockStatus
{
Unlocked,
Searching,
Locked,
};
enum LockChangeReason
{
UserRequest,
LockAcquired,
LockFailed,
LockLost,
LockTemporaryLost,
};
enum LockType
{
NoLock,
LockExposure,
LockWhiteBalance,
LockFocus,
};
typedef QFlags<QCamera::LockType> LockTypes;
%If (Qt_5_3_0 -)
enum Position
{
UnspecifiedPosition,
BackFace,
FrontFace,
};
%End
%If (Qt_5_6_1 -)
explicit QCamera(QObject *parent /TransferThis/ = 0);
%End
%If (- Qt_5_6_1)
QCamera(QObject *parent /TransferThis/ = 0);
%End
QCamera(const QByteArray &device, QObject *parent /TransferThis/ = 0);
%If (Qt_5_3_0 -)
QCamera(const QCameraInfo &cameraInfo, QObject *parent /TransferThis/ = 0);
%End
%If (Qt_5_3_0 -)
QCamera(QCamera::Position position, QObject *parent /TransferThis/ = 0);
%End
virtual ~QCamera();
static QList<QByteArray> availableDevices();
static QString deviceDescription(const QByteArray &device);
virtual QMultimedia::AvailabilityStatus availability() const;
QCamera::State state() const;
QCamera::Status status() const;
QCamera::CaptureModes captureMode() const;
bool isCaptureModeSupported(QCamera::CaptureModes mode) const;
QCameraExposure *exposure() const;
QCameraFocus *focus() const;
QCameraImageProcessing *imageProcessing() const;
void setViewfinder(QVideoWidget *viewfinder);
void setViewfinder(QGraphicsVideoItem *viewfinder);
void setViewfinder(QAbstractVideoSurface *surface);
QCamera::Error error() const;
QString errorString() const;
QCamera::LockTypes supportedLocks() const;
QCamera::LockTypes requestedLocks() const;
QCamera::LockStatus lockStatus() const;
QCamera::LockStatus lockStatus(QCamera::LockType lock) const;
public slots:
void setCaptureMode(QCamera::CaptureModes mode);
void load();
void unload();
void start();
void stop();
void searchAndLock();
void unlock();
void searchAndLock(QCamera::LockTypes locks);
void unlock(QCamera::LockTypes locks);
signals:
void stateChanged(QCamera::State);
void captureModeChanged(QCamera::CaptureModes);
void statusChanged(QCamera::Status);
void locked();
void lockFailed();
void lockStatusChanged(QCamera::LockStatus, QCamera::LockChangeReason);
void lockStatusChanged(QCamera::LockType, QCamera::LockStatus, QCamera::LockChangeReason);
void error(QCamera::Error);
%If (Qt_5_15_0 -)
void errorOccurred(QCamera::Error);
%End
public:
%If (Qt_5_5_0 -)
struct FrameRateRange
{
%TypeHeaderCode
#include <qcamera.h>
%End
FrameRateRange(qreal minimum, qreal maximum);
FrameRateRange();
qreal minimumFrameRate;
qreal maximumFrameRate;
};
%End
%If (Qt_5_5_0 -)
QCameraViewfinderSettings viewfinderSettings() const;
%End
%If (Qt_5_5_0 -)
void setViewfinderSettings(const QCameraViewfinderSettings &settings);
%End
%If (Qt_5_5_0 -)
QList<QCameraViewfinderSettings> supportedViewfinderSettings(const QCameraViewfinderSettings &settings = QCameraViewfinderSettings()) const;
%End
%If (Qt_5_5_0 -)
QList<QSize> supportedViewfinderResolutions(const QCameraViewfinderSettings &settings = QCameraViewfinderSettings()) const;
%End
%If (Qt_5_5_0 -)
QList<QCamera::FrameRateRange> supportedViewfinderFrameRateRanges(const QCameraViewfinderSettings &settings = QCameraViewfinderSettings()) const;
%End
%If (Qt_5_5_0 -)
QList<QVideoFrame::PixelFormat> supportedViewfinderPixelFormats(const QCameraViewfinderSettings &settings = QCameraViewfinderSettings()) const;
%End
};
QFlags<QCamera::LockType> operator|(QCamera::LockType f1, QFlags<QCamera::LockType> f2);
%If (Qt_5_5_0 -)
bool operator==(const QCamera::FrameRateRange &r1, const QCamera::FrameRateRange &r2);
%End
%If (Qt_5_5_0 -)
bool operator!=(const QCamera::FrameRateRange &r1, const QCamera::FrameRateRange &r2);
%End

View File

@@ -0,0 +1,40 @@
// qcameracapturebufferformatcontrol.sip generated by MetaSIP
//
// This file is part of the QtMultimedia Python extension module.
//
// Copyright (c) 2024 Riverbank Computing Limited <info@riverbankcomputing.com>
//
// This file is part of PyQt5.
//
// This file may be used under the terms of the GNU General Public License
// version 3.0 as published by the Free Software Foundation and appearing in
// the file LICENSE included in the packaging of this file. Please review the
// following information to ensure the GNU General Public License version 3.0
// requirements will be met: http://www.gnu.org/copyleft/gpl.html.
//
// If you do not wish to use this file under the terms of the GPL version 3.0
// then you may purchase a commercial license. For more information contact
// info@riverbankcomputing.com.
//
// This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE
// WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
class QCameraCaptureBufferFormatControl : public QMediaControl
{
%TypeHeaderCode
#include <qcameracapturebufferformatcontrol.h>
%End
public:
virtual ~QCameraCaptureBufferFormatControl();
virtual QList<QVideoFrame::PixelFormat> supportedBufferFormats() const = 0;
virtual QVideoFrame::PixelFormat bufferFormat() const = 0;
virtual void setBufferFormat(QVideoFrame::PixelFormat format) = 0;
signals:
void bufferFormatChanged(QVideoFrame::PixelFormat format);
protected:
explicit QCameraCaptureBufferFormatControl(QObject *parent /TransferThis/ = 0);
};

View File

@@ -0,0 +1,40 @@
// qcameracapturedestinationcontrol.sip generated by MetaSIP
//
// This file is part of the QtMultimedia Python extension module.
//
// Copyright (c) 2024 Riverbank Computing Limited <info@riverbankcomputing.com>
//
// This file is part of PyQt5.
//
// This file may be used under the terms of the GNU General Public License
// version 3.0 as published by the Free Software Foundation and appearing in
// the file LICENSE included in the packaging of this file. Please review the
// following information to ensure the GNU General Public License version 3.0
// requirements will be met: http://www.gnu.org/copyleft/gpl.html.
//
// If you do not wish to use this file under the terms of the GPL version 3.0
// then you may purchase a commercial license. For more information contact
// info@riverbankcomputing.com.
//
// This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE
// WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
class QCameraCaptureDestinationControl : public QMediaControl
{
%TypeHeaderCode
#include <qcameracapturedestinationcontrol.h>
%End
public:
virtual ~QCameraCaptureDestinationControl();
virtual bool isCaptureDestinationSupported(QCameraImageCapture::CaptureDestinations destination) const = 0;
virtual QCameraImageCapture::CaptureDestinations captureDestination() const = 0;
virtual void setCaptureDestination(QCameraImageCapture::CaptureDestinations destination) = 0;
signals:
void captureDestinationChanged(QCameraImageCapture::CaptureDestinations destination);
protected:
explicit QCameraCaptureDestinationControl(QObject *parent /TransferThis/ = 0);
};

View File

@@ -0,0 +1,56 @@
// qcameracontrol.sip generated by MetaSIP
//
// This file is part of the QtMultimedia Python extension module.
//
// Copyright (c) 2024 Riverbank Computing Limited <info@riverbankcomputing.com>
//
// This file is part of PyQt5.
//
// This file may be used under the terms of the GNU General Public License
// version 3.0 as published by the Free Software Foundation and appearing in
// the file LICENSE included in the packaging of this file. Please review the
// following information to ensure the GNU General Public License version 3.0
// requirements will be met: http://www.gnu.org/copyleft/gpl.html.
//
// If you do not wish to use this file under the terms of the GPL version 3.0
// then you may purchase a commercial license. For more information contact
// info@riverbankcomputing.com.
//
// This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE
// WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
class QCameraControl : public QMediaControl
{
%TypeHeaderCode
#include <qcameracontrol.h>
%End
public:
enum PropertyChangeType
{
CaptureMode,
ImageEncodingSettings,
VideoEncodingSettings,
Viewfinder,
ViewfinderSettings,
};
virtual ~QCameraControl();
virtual QCamera::State state() const = 0;
virtual void setState(QCamera::State state) = 0;
virtual QCamera::Status status() const = 0;
virtual QCamera::CaptureModes captureMode() const = 0;
virtual void setCaptureMode(QCamera::CaptureModes) = 0;
virtual bool isCaptureModeSupported(QCamera::CaptureModes mode) const = 0;
virtual bool canChangeProperty(QCameraControl::PropertyChangeType changeType, QCamera::Status status) const = 0;
signals:
void stateChanged(QCamera::State);
void statusChanged(QCamera::Status);
void error(int error, const QString &errorString);
void captureModeChanged(QCamera::CaptureModes mode);
protected:
explicit QCameraControl(QObject *parent /TransferThis/ = 0);
};

View File

@@ -0,0 +1,155 @@
// qcameraexposure.sip generated by MetaSIP
//
// This file is part of the QtMultimedia Python extension module.
//
// Copyright (c) 2024 Riverbank Computing Limited <info@riverbankcomputing.com>
//
// This file is part of PyQt5.
//
// This file may be used under the terms of the GNU General Public License
// version 3.0 as published by the Free Software Foundation and appearing in
// the file LICENSE included in the packaging of this file. Please review the
// following information to ensure the GNU General Public License version 3.0
// requirements will be met: http://www.gnu.org/copyleft/gpl.html.
//
// If you do not wish to use this file under the terms of the GPL version 3.0
// then you may purchase a commercial license. For more information contact
// info@riverbankcomputing.com.
//
// This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE
// WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
class QCameraExposure : public QObject
{
%TypeHeaderCode
#include <qcameraexposure.h>
%End
public:
enum FlashMode
{
FlashAuto,
FlashOff,
FlashOn,
FlashRedEyeReduction,
FlashFill,
FlashTorch,
FlashVideoLight,
FlashSlowSyncFrontCurtain,
FlashSlowSyncRearCurtain,
FlashManual,
};
typedef QFlags<QCameraExposure::FlashMode> FlashModes;
enum ExposureMode
{
ExposureAuto,
ExposureManual,
ExposurePortrait,
ExposureNight,
ExposureBacklight,
ExposureSpotlight,
ExposureSports,
ExposureSnow,
ExposureBeach,
ExposureLargeAperture,
ExposureSmallAperture,
%If (Qt_5_5_0 -)
ExposureAction,
%End
%If (Qt_5_5_0 -)
ExposureLandscape,
%End
%If (Qt_5_5_0 -)
ExposureNightPortrait,
%End
%If (Qt_5_5_0 -)
ExposureTheatre,
%End
%If (Qt_5_5_0 -)
ExposureSunset,
%End
%If (Qt_5_5_0 -)
ExposureSteadyPhoto,
%End
%If (Qt_5_5_0 -)
ExposureFireworks,
%End
%If (Qt_5_5_0 -)
ExposureParty,
%End
%If (Qt_5_5_0 -)
ExposureCandlelight,
%End
%If (Qt_5_5_0 -)
ExposureBarcode,
%End
ExposureModeVendor,
};
enum MeteringMode
{
MeteringMatrix,
MeteringAverage,
MeteringSpot,
};
bool isAvailable() const;
QCameraExposure::FlashModes flashMode() const;
bool isFlashModeSupported(QCameraExposure::FlashModes mode) const;
bool isFlashReady() const;
QCameraExposure::ExposureMode exposureMode() const;
bool isExposureModeSupported(QCameraExposure::ExposureMode mode) const;
qreal exposureCompensation() const;
QCameraExposure::MeteringMode meteringMode() const;
bool isMeteringModeSupported(QCameraExposure::MeteringMode mode) const;
QPointF spotMeteringPoint() const;
void setSpotMeteringPoint(const QPointF &point);
int isoSensitivity() const;
qreal aperture() const;
qreal shutterSpeed() const;
int requestedIsoSensitivity() const;
qreal requestedAperture() const;
qreal requestedShutterSpeed() const;
QList<int> supportedIsoSensitivities(bool *continuous = 0) const;
QList<qreal> supportedApertures(bool *continuous = 0) const;
QList<qreal> supportedShutterSpeeds(bool *continuous = 0) const;
public slots:
void setFlashMode(QCameraExposure::FlashModes mode);
void setExposureMode(QCameraExposure::ExposureMode mode);
void setMeteringMode(QCameraExposure::MeteringMode mode);
void setExposureCompensation(qreal ev);
void setManualIsoSensitivity(int iso);
void setAutoIsoSensitivity();
void setManualAperture(qreal aperture);
void setAutoAperture();
void setManualShutterSpeed(qreal seconds);
void setAutoShutterSpeed();
signals:
void flashReady(bool);
void apertureChanged(qreal);
void apertureRangeChanged();
void shutterSpeedChanged(qreal);
void shutterSpeedRangeChanged();
void isoSensitivityChanged(int);
void exposureCompensationChanged(qreal);
private:
explicit QCameraExposure(QCamera *parent /TransferThis/ = 0);
protected:
%If (Qt_5_14_0 -)
virtual ~QCameraExposure();
%End
private:
%If (- Qt_5_14_0)
virtual ~QCameraExposure();
%End
};
QFlags<QCameraExposure::FlashMode> operator|(QCameraExposure::FlashMode f1, QFlags<QCameraExposure::FlashMode> f2);

View File

@@ -0,0 +1,60 @@
// qcameraexposurecontrol.sip generated by MetaSIP
//
// This file is part of the QtMultimedia Python extension module.
//
// Copyright (c) 2024 Riverbank Computing Limited <info@riverbankcomputing.com>
//
// This file is part of PyQt5.
//
// This file may be used under the terms of the GNU General Public License
// version 3.0 as published by the Free Software Foundation and appearing in
// the file LICENSE included in the packaging of this file. Please review the
// following information to ensure the GNU General Public License version 3.0
// requirements will be met: http://www.gnu.org/copyleft/gpl.html.
//
// If you do not wish to use this file under the terms of the GPL version 3.0
// then you may purchase a commercial license. For more information contact
// info@riverbankcomputing.com.
//
// This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE
// WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
class QCameraExposureControl : public QMediaControl
{
%TypeHeaderCode
#include <qcameraexposurecontrol.h>
%End
public:
virtual ~QCameraExposureControl();
enum ExposureParameter
{
ISO,
Aperture,
ShutterSpeed,
ExposureCompensation,
FlashPower,
FlashCompensation,
TorchPower,
SpotMeteringPoint,
ExposureMode,
MeteringMode,
ExtendedExposureParameter,
};
virtual bool isParameterSupported(QCameraExposureControl::ExposureParameter parameter) const = 0;
virtual QVariantList supportedParameterRange(QCameraExposureControl::ExposureParameter parameter, bool *continuous) const = 0;
virtual QVariant requestedValue(QCameraExposureControl::ExposureParameter parameter) const = 0;
virtual QVariant actualValue(QCameraExposureControl::ExposureParameter parameter) const = 0;
virtual bool setValue(QCameraExposureControl::ExposureParameter parameter, const QVariant &value) = 0;
signals:
void requestedValueChanged(int parameter);
void actualValueChanged(int parameter);
void parameterRangeChanged(int parameter);
protected:
explicit QCameraExposureControl(QObject *parent /TransferThis/ = 0);
};

View File

@@ -0,0 +1,54 @@
// qcamerafeedbackcontrol.sip generated by MetaSIP
//
// This file is part of the QtMultimedia Python extension module.
//
// Copyright (c) 2024 Riverbank Computing Limited <info@riverbankcomputing.com>
//
// This file is part of PyQt5.
//
// This file may be used under the terms of the GNU General Public License
// version 3.0 as published by the Free Software Foundation and appearing in
// the file LICENSE included in the packaging of this file. Please review the
// following information to ensure the GNU General Public License version 3.0
// requirements will be met: http://www.gnu.org/copyleft/gpl.html.
//
// If you do not wish to use this file under the terms of the GPL version 3.0
// then you may purchase a commercial license. For more information contact
// info@riverbankcomputing.com.
//
// This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE
// WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
class QCameraFeedbackControl : public QMediaControl
{
%TypeHeaderCode
#include <qcamerafeedbackcontrol.h>
%End
public:
enum EventType
{
ViewfinderStarted,
ViewfinderStopped,
ImageCaptured,
ImageSaved,
ImageError,
RecordingStarted,
RecordingInProgress,
RecordingStopped,
AutoFocusInProgress,
AutoFocusLocked,
AutoFocusFailed,
};
virtual ~QCameraFeedbackControl();
virtual bool isEventFeedbackLocked(QCameraFeedbackControl::EventType) const = 0;
virtual bool isEventFeedbackEnabled(QCameraFeedbackControl::EventType) const = 0;
virtual bool setEventFeedbackEnabled(QCameraFeedbackControl::EventType, bool) = 0;
virtual void resetEventFeedback(QCameraFeedbackControl::EventType) = 0;
virtual bool setEventFeedbackSound(QCameraFeedbackControl::EventType, const QString &filePath) = 0;
protected:
explicit QCameraFeedbackControl(QObject *parent /TransferThis/ = 0);
};

View File

@@ -0,0 +1,41 @@
// qcameraflashcontrol.sip generated by MetaSIP
//
// This file is part of the QtMultimedia Python extension module.
//
// Copyright (c) 2024 Riverbank Computing Limited <info@riverbankcomputing.com>
//
// This file is part of PyQt5.
//
// This file may be used under the terms of the GNU General Public License
// version 3.0 as published by the Free Software Foundation and appearing in
// the file LICENSE included in the packaging of this file. Please review the
// following information to ensure the GNU General Public License version 3.0
// requirements will be met: http://www.gnu.org/copyleft/gpl.html.
//
// If you do not wish to use this file under the terms of the GPL version 3.0
// then you may purchase a commercial license. For more information contact
// info@riverbankcomputing.com.
//
// This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE
// WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
class QCameraFlashControl : public QMediaControl
{
%TypeHeaderCode
#include <qcameraflashcontrol.h>
%End
public:
virtual ~QCameraFlashControl();
virtual QCameraExposure::FlashModes flashMode() const = 0;
virtual void setFlashMode(QCameraExposure::FlashModes mode) = 0;
virtual bool isFlashModeSupported(QCameraExposure::FlashModes mode) const = 0;
virtual bool isFlashReady() const = 0;
signals:
void flashReady(bool);
protected:
explicit QCameraFlashControl(QObject *parent /TransferThis/ = 0);
};

View File

@@ -0,0 +1,114 @@
// qcamerafocus.sip generated by MetaSIP
//
// This file is part of the QtMultimedia Python extension module.
//
// Copyright (c) 2024 Riverbank Computing Limited <info@riverbankcomputing.com>
//
// This file is part of PyQt5.
//
// This file may be used under the terms of the GNU General Public License
// version 3.0 as published by the Free Software Foundation and appearing in
// the file LICENSE included in the packaging of this file. Please review the
// following information to ensure the GNU General Public License version 3.0
// requirements will be met: http://www.gnu.org/copyleft/gpl.html.
//
// If you do not wish to use this file under the terms of the GPL version 3.0
// then you may purchase a commercial license. For more information contact
// info@riverbankcomputing.com.
//
// This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE
// WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
class QCameraFocusZone
{
%TypeHeaderCode
#include <qcamerafocus.h>
%End
public:
enum FocusZoneStatus
{
Invalid,
Unused,
Selected,
Focused,
};
QCameraFocusZone(const QCameraFocusZone &other);
bool operator==(const QCameraFocusZone &other) const;
bool operator!=(const QCameraFocusZone &other) const;
~QCameraFocusZone();
bool isValid() const;
QRectF area() const;
QCameraFocusZone::FocusZoneStatus status() const;
};
typedef QList<QCameraFocusZone> QCameraFocusZoneList;
class QCameraFocus : public QObject
{
%TypeHeaderCode
#include <qcamerafocus.h>
%End
public:
enum FocusMode
{
ManualFocus,
HyperfocalFocus,
InfinityFocus,
AutoFocus,
ContinuousFocus,
MacroFocus,
};
typedef QFlags<QCameraFocus::FocusMode> FocusModes;
enum FocusPointMode
{
FocusPointAuto,
FocusPointCenter,
FocusPointFaceDetection,
FocusPointCustom,
};
bool isAvailable() const;
QCameraFocus::FocusModes focusMode() const;
void setFocusMode(QCameraFocus::FocusModes mode);
bool isFocusModeSupported(QCameraFocus::FocusModes mode) const;
QCameraFocus::FocusPointMode focusPointMode() const;
void setFocusPointMode(QCameraFocus::FocusPointMode mode);
bool isFocusPointModeSupported(QCameraFocus::FocusPointMode) const;
QPointF customFocusPoint() const;
void setCustomFocusPoint(const QPointF &point);
QCameraFocusZoneList focusZones() const;
qreal maximumOpticalZoom() const;
qreal maximumDigitalZoom() const;
qreal opticalZoom() const;
qreal digitalZoom() const;
void zoomTo(qreal opticalZoom, qreal digitalZoom);
signals:
void opticalZoomChanged(qreal);
void digitalZoomChanged(qreal);
void focusZonesChanged();
void maximumOpticalZoomChanged(qreal);
void maximumDigitalZoomChanged(qreal);
private:
QCameraFocus(QCamera *camera);
protected:
%If (Qt_5_14_0 -)
virtual ~QCameraFocus();
%End
private:
%If (- Qt_5_14_0)
virtual ~QCameraFocus();
%End
QCameraFocus(const QCameraFocus &);
};
QFlags<QCameraFocus::FocusMode> operator|(QCameraFocus::FocusMode f1, QFlags<QCameraFocus::FocusMode> f2);

View File

@@ -0,0 +1,49 @@
// qcamerafocuscontrol.sip generated by MetaSIP
//
// This file is part of the QtMultimedia Python extension module.
//
// Copyright (c) 2024 Riverbank Computing Limited <info@riverbankcomputing.com>
//
// This file is part of PyQt5.
//
// This file may be used under the terms of the GNU General Public License
// version 3.0 as published by the Free Software Foundation and appearing in
// the file LICENSE included in the packaging of this file. Please review the
// following information to ensure the GNU General Public License version 3.0
// requirements will be met: http://www.gnu.org/copyleft/gpl.html.
//
// If you do not wish to use this file under the terms of the GPL version 3.0
// then you may purchase a commercial license. For more information contact
// info@riverbankcomputing.com.
//
// This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE
// WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
class QCameraFocusControl : public QMediaControl
{
%TypeHeaderCode
#include <qcamerafocuscontrol.h>
%End
public:
virtual ~QCameraFocusControl();
virtual QCameraFocus::FocusModes focusMode() const = 0;
virtual void setFocusMode(QCameraFocus::FocusModes mode) = 0;
virtual bool isFocusModeSupported(QCameraFocus::FocusModes mode) const = 0;
virtual QCameraFocus::FocusPointMode focusPointMode() const = 0;
virtual void setFocusPointMode(QCameraFocus::FocusPointMode mode) = 0;
virtual bool isFocusPointModeSupported(QCameraFocus::FocusPointMode mode) const = 0;
virtual QPointF customFocusPoint() const = 0;
virtual void setCustomFocusPoint(const QPointF &point) = 0;
virtual QCameraFocusZoneList focusZones() const = 0;
signals:
void focusModeChanged(QCameraFocus::FocusModes mode);
void focusPointModeChanged(QCameraFocus::FocusPointMode mode);
void customFocusPointChanged(const QPointF &point);
void focusZonesChanged();
protected:
explicit QCameraFocusControl(QObject *parent /TransferThis/ = 0);
};

View File

@@ -0,0 +1,91 @@
// qcameraimagecapture.sip generated by MetaSIP
//
// This file is part of the QtMultimedia Python extension module.
//
// Copyright (c) 2024 Riverbank Computing Limited <info@riverbankcomputing.com>
//
// This file is part of PyQt5.
//
// This file may be used under the terms of the GNU General Public License
// version 3.0 as published by the Free Software Foundation and appearing in
// the file LICENSE included in the packaging of this file. Please review the
// following information to ensure the GNU General Public License version 3.0
// requirements will be met: http://www.gnu.org/copyleft/gpl.html.
//
// If you do not wish to use this file under the terms of the GPL version 3.0
// then you may purchase a commercial license. For more information contact
// info@riverbankcomputing.com.
//
// This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE
// WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
class QCameraImageCapture : public QObject, public QMediaBindableInterface
{
%TypeHeaderCode
#include <qcameraimagecapture.h>
%End
public:
enum Error
{
NoError,
NotReadyError,
ResourceError,
OutOfSpaceError,
NotSupportedFeatureError,
FormatError,
};
enum DriveMode
{
SingleImageCapture,
};
enum CaptureDestination
{
CaptureToFile,
CaptureToBuffer,
};
typedef QFlags<QCameraImageCapture::CaptureDestination> CaptureDestinations;
QCameraImageCapture(QMediaObject *mediaObject, QObject *parent /TransferThis/ = 0);
virtual ~QCameraImageCapture();
bool isAvailable() const;
QMultimedia::AvailabilityStatus availability() const;
virtual QMediaObject *mediaObject() const;
QCameraImageCapture::Error error() const;
QString errorString() const;
bool isReadyForCapture() const;
QStringList supportedImageCodecs() const;
QString imageCodecDescription(const QString &codecName) const;
QList<QSize> supportedResolutions(const QImageEncoderSettings &settings = QImageEncoderSettings(), bool *continuous = 0) const;
QImageEncoderSettings encodingSettings() const;
void setEncodingSettings(const QImageEncoderSettings &settings);
QList<QVideoFrame::PixelFormat> supportedBufferFormats() const;
QVideoFrame::PixelFormat bufferFormat() const;
void setBufferFormat(const QVideoFrame::PixelFormat format);
bool isCaptureDestinationSupported(QCameraImageCapture::CaptureDestinations destination) const;
QCameraImageCapture::CaptureDestinations captureDestination() const;
void setCaptureDestination(QCameraImageCapture::CaptureDestinations destination);
public slots:
int capture(const QString &file = QString()) /ReleaseGIL/;
void cancelCapture();
signals:
void error(int id, QCameraImageCapture::Error error, const QString &errorString);
void readyForCaptureChanged(bool);
void bufferFormatChanged(QVideoFrame::PixelFormat);
void captureDestinationChanged(QCameraImageCapture::CaptureDestinations);
void imageExposed(int id);
void imageCaptured(int id, const QImage &preview);
void imageMetadataAvailable(int id, const QString &key, const QVariant &value);
void imageAvailable(int id, const QVideoFrame &image);
void imageSaved(int id, const QString &fileName);
protected:
virtual bool setMediaObject(QMediaObject *);
};
QFlags<QCameraImageCapture::CaptureDestination> operator|(QCameraImageCapture::CaptureDestination f1, QFlags<QCameraImageCapture::CaptureDestination> f2);

View File

@@ -0,0 +1,48 @@
// qcameraimagecapturecontrol.sip generated by MetaSIP
//
// This file is part of the QtMultimedia Python extension module.
//
// Copyright (c) 2024 Riverbank Computing Limited <info@riverbankcomputing.com>
//
// This file is part of PyQt5.
//
// This file may be used under the terms of the GNU General Public License
// version 3.0 as published by the Free Software Foundation and appearing in
// the file LICENSE included in the packaging of this file. Please review the
// following information to ensure the GNU General Public License version 3.0
// requirements will be met: http://www.gnu.org/copyleft/gpl.html.
//
// If you do not wish to use this file under the terms of the GPL version 3.0
// then you may purchase a commercial license. For more information contact
// info@riverbankcomputing.com.
//
// This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE
// WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
class QCameraImageCaptureControl : public QMediaControl
{
%TypeHeaderCode
#include <qcameraimagecapturecontrol.h>
%End
public:
virtual ~QCameraImageCaptureControl();
virtual bool isReadyForCapture() const = 0;
virtual QCameraImageCapture::DriveMode driveMode() const = 0;
virtual void setDriveMode(QCameraImageCapture::DriveMode mode) = 0;
virtual int capture(const QString &fileName) = 0;
virtual void cancelCapture() = 0;
signals:
void readyForCaptureChanged(bool ready);
void imageExposed(int requestId);
void imageCaptured(int requestId, const QImage &preview);
void imageMetadataAvailable(int id, const QString &key, const QVariant &value);
void imageAvailable(int requestId, const QVideoFrame &buffer);
void imageSaved(int requestId, const QString &fileName);
void error(int id, int error, const QString &errorString);
protected:
explicit QCameraImageCaptureControl(QObject *parent /TransferThis/ = 0);
};

View File

@@ -0,0 +1,106 @@
// qcameraimageprocessing.sip generated by MetaSIP
//
// This file is part of the QtMultimedia Python extension module.
//
// Copyright (c) 2024 Riverbank Computing Limited <info@riverbankcomputing.com>
//
// This file is part of PyQt5.
//
// This file may be used under the terms of the GNU General Public License
// version 3.0 as published by the Free Software Foundation and appearing in
// the file LICENSE included in the packaging of this file. Please review the
// following information to ensure the GNU General Public License version 3.0
// requirements will be met: http://www.gnu.org/copyleft/gpl.html.
//
// If you do not wish to use this file under the terms of the GPL version 3.0
// then you may purchase a commercial license. For more information contact
// info@riverbankcomputing.com.
//
// This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE
// WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
class QCameraImageProcessing : public QObject
{
%TypeHeaderCode
#include <qcameraimageprocessing.h>
%End
public:
enum WhiteBalanceMode
{
WhiteBalanceAuto,
WhiteBalanceManual,
WhiteBalanceSunlight,
WhiteBalanceCloudy,
WhiteBalanceShade,
WhiteBalanceTungsten,
WhiteBalanceFluorescent,
WhiteBalanceFlash,
WhiteBalanceSunset,
WhiteBalanceVendor,
};
bool isAvailable() const;
QCameraImageProcessing::WhiteBalanceMode whiteBalanceMode() const;
void setWhiteBalanceMode(QCameraImageProcessing::WhiteBalanceMode mode);
bool isWhiteBalanceModeSupported(QCameraImageProcessing::WhiteBalanceMode mode) const;
qreal manualWhiteBalance() const;
void setManualWhiteBalance(qreal colorTemperature);
qreal contrast() const;
void setContrast(qreal value);
qreal saturation() const;
void setSaturation(qreal value);
qreal sharpeningLevel() const;
void setSharpeningLevel(qreal value);
qreal denoisingLevel() const;
void setDenoisingLevel(qreal value);
private:
QCameraImageProcessing(QCamera *camera);
protected:
%If (Qt_5_14_0 -)
virtual ~QCameraImageProcessing();
%End
private:
%If (- Qt_5_14_0)
virtual ~QCameraImageProcessing();
%End
QCameraImageProcessing(const QCameraImageProcessing &);
public:
%If (Qt_5_5_0 -)
enum ColorFilter
{
ColorFilterNone,
ColorFilterGrayscale,
ColorFilterNegative,
ColorFilterSolarize,
ColorFilterSepia,
ColorFilterPosterize,
ColorFilterWhiteboard,
ColorFilterBlackboard,
ColorFilterAqua,
ColorFilterVendor,
};
%End
%If (Qt_5_5_0 -)
QCameraImageProcessing::ColorFilter colorFilter() const;
%End
%If (Qt_5_5_0 -)
void setColorFilter(QCameraImageProcessing::ColorFilter filter);
%End
%If (Qt_5_5_0 -)
bool isColorFilterSupported(QCameraImageProcessing::ColorFilter filter) const;
%End
%If (Qt_5_7_0 -)
qreal brightness() const;
%End
%If (Qt_5_7_0 -)
void setBrightness(qreal value);
%End
};

View File

@@ -0,0 +1,57 @@
// qcameraimageprocessingcontrol.sip generated by MetaSIP
//
// This file is part of the QtMultimedia Python extension module.
//
// Copyright (c) 2024 Riverbank Computing Limited <info@riverbankcomputing.com>
//
// This file is part of PyQt5.
//
// This file may be used under the terms of the GNU General Public License
// version 3.0 as published by the Free Software Foundation and appearing in
// the file LICENSE included in the packaging of this file. Please review the
// following information to ensure the GNU General Public License version 3.0
// requirements will be met: http://www.gnu.org/copyleft/gpl.html.
//
// If you do not wish to use this file under the terms of the GPL version 3.0
// then you may purchase a commercial license. For more information contact
// info@riverbankcomputing.com.
//
// This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE
// WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
class QCameraImageProcessingControl : public QMediaControl
{
%TypeHeaderCode
#include <qcameraimageprocessingcontrol.h>
%End
public:
virtual ~QCameraImageProcessingControl();
enum ProcessingParameter
{
WhiteBalancePreset,
ColorTemperature,
Contrast,
Saturation,
Brightness,
Sharpening,
Denoising,
ContrastAdjustment,
SaturationAdjustment,
BrightnessAdjustment,
SharpeningAdjustment,
DenoisingAdjustment,
ColorFilter,
ExtendedParameter,
};
virtual bool isParameterSupported(QCameraImageProcessingControl::ProcessingParameter) const = 0;
virtual bool isParameterValueSupported(QCameraImageProcessingControl::ProcessingParameter parameter, const QVariant &value) const = 0;
virtual QVariant parameter(QCameraImageProcessingControl::ProcessingParameter parameter) const = 0;
virtual void setParameter(QCameraImageProcessingControl::ProcessingParameter parameter, const QVariant &value) = 0;
protected:
explicit QCameraImageProcessingControl(QObject *parent /TransferThis/ = 0);
};

View File

@@ -0,0 +1,47 @@
// qcamerainfo.sip generated by MetaSIP
//
// This file is part of the QtMultimedia Python extension module.
//
// Copyright (c) 2024 Riverbank Computing Limited <info@riverbankcomputing.com>
//
// This file is part of PyQt5.
//
// This file may be used under the terms of the GNU General Public License
// version 3.0 as published by the Free Software Foundation and appearing in
// the file LICENSE included in the packaging of this file. Please review the
// following information to ensure the GNU General Public License version 3.0
// requirements will be met: http://www.gnu.org/copyleft/gpl.html.
//
// If you do not wish to use this file under the terms of the GPL version 3.0
// then you may purchase a commercial license. For more information contact
// info@riverbankcomputing.com.
//
// This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE
// WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
%If (Qt_5_3_0 -)
class QCameraInfo
{
%TypeHeaderCode
#include <qcamerainfo.h>
%End
public:
explicit QCameraInfo(const QByteArray &name = QByteArray());
explicit QCameraInfo(const QCamera &camera);
QCameraInfo(const QCameraInfo &other);
~QCameraInfo();
bool isNull() const;
QString deviceName() const;
QString description() const;
QCamera::Position position() const;
int orientation() const;
static QCameraInfo defaultCamera();
static QList<QCameraInfo> availableCameras(QCamera::Position position = QCamera::UnspecifiedPosition);
bool operator==(const QCameraInfo &other) const;
bool operator!=(const QCameraInfo &other) const;
};
%End

View File

@@ -0,0 +1,36 @@
// qcamerainfocontrol.sip generated by MetaSIP
//
// This file is part of the QtMultimedia Python extension module.
//
// Copyright (c) 2024 Riverbank Computing Limited <info@riverbankcomputing.com>
//
// This file is part of PyQt5.
//
// This file may be used under the terms of the GNU General Public License
// version 3.0 as published by the Free Software Foundation and appearing in
// the file LICENSE included in the packaging of this file. Please review the
// following information to ensure the GNU General Public License version 3.0
// requirements will be met: http://www.gnu.org/copyleft/gpl.html.
//
// If you do not wish to use this file under the terms of the GPL version 3.0
// then you may purchase a commercial license. For more information contact
// info@riverbankcomputing.com.
//
// This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE
// WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
class QCameraInfoControl : public QMediaControl
{
%TypeHeaderCode
#include <qcamerainfocontrol.h>
%End
public:
virtual ~QCameraInfoControl();
virtual QCamera::Position cameraPosition(const QString &deviceName) const = 0;
virtual int cameraOrientation(const QString &deviceName) const = 0;
protected:
explicit QCameraInfoControl(QObject *parent /TransferThis/ = 0);
};

View File

@@ -0,0 +1,41 @@
// qcameralockscontrol.sip generated by MetaSIP
//
// This file is part of the QtMultimedia Python extension module.
//
// Copyright (c) 2024 Riverbank Computing Limited <info@riverbankcomputing.com>
//
// This file is part of PyQt5.
//
// This file may be used under the terms of the GNU General Public License
// version 3.0 as published by the Free Software Foundation and appearing in
// the file LICENSE included in the packaging of this file. Please review the
// following information to ensure the GNU General Public License version 3.0
// requirements will be met: http://www.gnu.org/copyleft/gpl.html.
//
// If you do not wish to use this file under the terms of the GPL version 3.0
// then you may purchase a commercial license. For more information contact
// info@riverbankcomputing.com.
//
// This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE
// WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
class QCameraLocksControl : public QMediaControl
{
%TypeHeaderCode
#include <qcameralockscontrol.h>
%End
public:
virtual ~QCameraLocksControl();
virtual QCamera::LockTypes supportedLocks() const = 0;
virtual QCamera::LockStatus lockStatus(QCamera::LockType lock) const = 0;
virtual void searchAndLock(QCamera::LockTypes locks) = 0;
virtual void unlock(QCamera::LockTypes locks) = 0;
signals:
void lockStatusChanged(QCamera::LockType type, QCamera::LockStatus status, QCamera::LockChangeReason reason);
protected:
explicit QCameraLocksControl(QObject *parent /TransferThis/ = 0);
};

View File

@@ -0,0 +1,57 @@
// qcameraviewfindersettings.sip generated by MetaSIP
//
// This file is part of the QtMultimedia Python extension module.
//
// Copyright (c) 2024 Riverbank Computing Limited <info@riverbankcomputing.com>
//
// This file is part of PyQt5.
//
// This file may be used under the terms of the GNU General Public License
// version 3.0 as published by the Free Software Foundation and appearing in
// the file LICENSE included in the packaging of this file. Please review the
// following information to ensure the GNU General Public License version 3.0
// requirements will be met: http://www.gnu.org/copyleft/gpl.html.
//
// If you do not wish to use this file under the terms of the GPL version 3.0
// then you may purchase a commercial license. For more information contact
// info@riverbankcomputing.com.
//
// This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE
// WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
%If (Qt_5_5_0 -)
class QCameraViewfinderSettings
{
%TypeHeaderCode
#include <qcameraviewfindersettings.h>
%End
public:
QCameraViewfinderSettings();
QCameraViewfinderSettings(const QCameraViewfinderSettings &other);
~QCameraViewfinderSettings();
void swap(QCameraViewfinderSettings &other /Constrained/);
bool isNull() const;
QSize resolution() const;
void setResolution(const QSize &);
void setResolution(int width, int height);
qreal minimumFrameRate() const;
void setMinimumFrameRate(qreal rate);
qreal maximumFrameRate() const;
void setMaximumFrameRate(qreal rate);
QVideoFrame::PixelFormat pixelFormat() const;
void setPixelFormat(QVideoFrame::PixelFormat format);
QSize pixelAspectRatio() const;
void setPixelAspectRatio(const QSize &ratio);
void setPixelAspectRatio(int horizontal, int vertical);
};
%End
%If (Qt_5_5_0 -)
bool operator==(const QCameraViewfinderSettings &lhs, const QCameraViewfinderSettings &rhs);
%End
%If (Qt_5_5_0 -)
bool operator!=(const QCameraViewfinderSettings &lhs, const QCameraViewfinderSettings &rhs);
%End

View File

@@ -0,0 +1,63 @@
// qcameraviewfindersettingscontrol.sip generated by MetaSIP
//
// This file is part of the QtMultimedia Python extension module.
//
// Copyright (c) 2024 Riverbank Computing Limited <info@riverbankcomputing.com>
//
// This file is part of PyQt5.
//
// This file may be used under the terms of the GNU General Public License
// version 3.0 as published by the Free Software Foundation and appearing in
// the file LICENSE included in the packaging of this file. Please review the
// following information to ensure the GNU General Public License version 3.0
// requirements will be met: http://www.gnu.org/copyleft/gpl.html.
//
// If you do not wish to use this file under the terms of the GPL version 3.0
// then you may purchase a commercial license. For more information contact
// info@riverbankcomputing.com.
//
// This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE
// WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
class QCameraViewfinderSettingsControl : public QMediaControl
{
%TypeHeaderCode
#include <qcameraviewfindersettingscontrol.h>
%End
public:
enum ViewfinderParameter
{
Resolution,
PixelAspectRatio,
MinimumFrameRate,
MaximumFrameRate,
PixelFormat,
UserParameter,
};
virtual ~QCameraViewfinderSettingsControl();
virtual bool isViewfinderParameterSupported(QCameraViewfinderSettingsControl::ViewfinderParameter parameter) const = 0;
virtual QVariant viewfinderParameter(QCameraViewfinderSettingsControl::ViewfinderParameter parameter) const = 0;
virtual void setViewfinderParameter(QCameraViewfinderSettingsControl::ViewfinderParameter parameter, const QVariant &value) = 0;
protected:
explicit QCameraViewfinderSettingsControl(QObject *parent /TransferThis/ = 0);
};
class QCameraViewfinderSettingsControl2 : public QMediaControl
{
%TypeHeaderCode
#include <qcameraviewfindersettingscontrol.h>
%End
public:
virtual ~QCameraViewfinderSettingsControl2();
virtual QList<QCameraViewfinderSettings> supportedViewfinderSettings() const = 0;
virtual QCameraViewfinderSettings viewfinderSettings() const = 0;
virtual void setViewfinderSettings(const QCameraViewfinderSettings &settings) = 0;
protected:
explicit QCameraViewfinderSettingsControl2(QObject *parent /TransferThis/ = 0);
};

View File

@@ -0,0 +1,49 @@
// qcamerazoomcontrol.sip generated by MetaSIP
//
// This file is part of the QtMultimedia Python extension module.
//
// Copyright (c) 2024 Riverbank Computing Limited <info@riverbankcomputing.com>
//
// This file is part of PyQt5.
//
// This file may be used under the terms of the GNU General Public License
// version 3.0 as published by the Free Software Foundation and appearing in
// the file LICENSE included in the packaging of this file. Please review the
// following information to ensure the GNU General Public License version 3.0
// requirements will be met: http://www.gnu.org/copyleft/gpl.html.
//
// If you do not wish to use this file under the terms of the GPL version 3.0
// then you may purchase a commercial license. For more information contact
// info@riverbankcomputing.com.
//
// This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE
// WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
class QCameraZoomControl : public QMediaControl
{
%TypeHeaderCode
#include <qcamerazoomcontrol.h>
%End
public:
virtual ~QCameraZoomControl();
virtual qreal maximumOpticalZoom() const = 0;
virtual qreal maximumDigitalZoom() const = 0;
virtual qreal requestedOpticalZoom() const = 0;
virtual qreal requestedDigitalZoom() const = 0;
virtual qreal currentOpticalZoom() const = 0;
virtual qreal currentDigitalZoom() const = 0;
virtual void zoomTo(qreal optical, qreal digital) = 0;
signals:
void maximumOpticalZoomChanged(qreal);
void maximumDigitalZoomChanged(qreal);
void requestedOpticalZoomChanged(qreal opticalZoom);
void requestedDigitalZoomChanged(qreal digitalZoom);
void currentOpticalZoomChanged(qreal opticalZoom);
void currentDigitalZoomChanged(qreal digitalZoom);
protected:
explicit QCameraZoomControl(QObject *parent /TransferThis/ = 0);
};

View File

@@ -0,0 +1,44 @@
// qcustomaudiorolecontrol.sip generated by MetaSIP
//
// This file is part of the QtMultimedia Python extension module.
//
// Copyright (c) 2024 Riverbank Computing Limited <info@riverbankcomputing.com>
//
// This file is part of PyQt5.
//
// This file may be used under the terms of the GNU General Public License
// version 3.0 as published by the Free Software Foundation and appearing in
// the file LICENSE included in the packaging of this file. Please review the
// following information to ensure the GNU General Public License version 3.0
// requirements will be met: http://www.gnu.org/copyleft/gpl.html.
//
// If you do not wish to use this file under the terms of the GPL version 3.0
// then you may purchase a commercial license. For more information contact
// info@riverbankcomputing.com.
//
// This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE
// WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
%If (Qt_5_11_0 -)
class QCustomAudioRoleControl : public QMediaControl
{
%TypeHeaderCode
#include <qcustomaudiorolecontrol.h>
%End
public:
virtual ~QCustomAudioRoleControl();
virtual QString customAudioRole() const = 0;
virtual void setCustomAudioRole(const QString &role) = 0;
virtual QStringList supportedCustomAudioRoles() const = 0;
signals:
void customAudioRoleChanged(const QString &role);
protected:
explicit QCustomAudioRoleControl(QObject *parent /TransferThis/ = 0);
};
%End

View File

@@ -0,0 +1,39 @@
// qimageencodercontrol.sip generated by MetaSIP
//
// This file is part of the QtMultimedia Python extension module.
//
// Copyright (c) 2024 Riverbank Computing Limited <info@riverbankcomputing.com>
//
// This file is part of PyQt5.
//
// This file may be used under the terms of the GNU General Public License
// version 3.0 as published by the Free Software Foundation and appearing in
// the file LICENSE included in the packaging of this file. Please review the
// following information to ensure the GNU General Public License version 3.0
// requirements will be met: http://www.gnu.org/copyleft/gpl.html.
//
// If you do not wish to use this file under the terms of the GPL version 3.0
// then you may purchase a commercial license. For more information contact
// info@riverbankcomputing.com.
//
// This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE
// WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
class QImageEncoderControl : public QMediaControl
{
%TypeHeaderCode
#include <qimageencodercontrol.h>
%End
public:
virtual ~QImageEncoderControl();
virtual QStringList supportedImageCodecs() const = 0;
virtual QString imageCodecDescription(const QString &codec) const = 0;
virtual QList<QSize> supportedResolutions(const QImageEncoderSettings &settings, bool *continuous = 0) const = 0;
virtual QImageEncoderSettings imageSettings() const = 0;
virtual void setImageSettings(const QImageEncoderSettings &settings) = 0;
protected:
explicit QImageEncoderControl(QObject *parent /TransferThis/ = 0);
};

View File

@@ -0,0 +1,38 @@
// qmediaaudioprobecontrol.sip generated by MetaSIP
//
// This file is part of the QtMultimedia Python extension module.
//
// Copyright (c) 2024 Riverbank Computing Limited <info@riverbankcomputing.com>
//
// This file is part of PyQt5.
//
// This file may be used under the terms of the GNU General Public License
// version 3.0 as published by the Free Software Foundation and appearing in
// the file LICENSE included in the packaging of this file. Please review the
// following information to ensure the GNU General Public License version 3.0
// requirements will be met: http://www.gnu.org/copyleft/gpl.html.
//
// If you do not wish to use this file under the terms of the GPL version 3.0
// then you may purchase a commercial license. For more information contact
// info@riverbankcomputing.com.
//
// This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE
// WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
class QMediaAudioProbeControl : public QMediaControl
{
%TypeHeaderCode
#include <qmediaaudioprobecontrol.h>
%End
public:
virtual ~QMediaAudioProbeControl();
signals:
void audioBufferProbed(const QAudioBuffer &buffer);
void flush();
protected:
explicit QMediaAudioProbeControl(QObject *parent /TransferThis/ = 0);
};

View File

@@ -0,0 +1,38 @@
// qmediaavailabilitycontrol.sip generated by MetaSIP
//
// This file is part of the QtMultimedia Python extension module.
//
// Copyright (c) 2024 Riverbank Computing Limited <info@riverbankcomputing.com>
//
// This file is part of PyQt5.
//
// This file may be used under the terms of the GNU General Public License
// version 3.0 as published by the Free Software Foundation and appearing in
// the file LICENSE included in the packaging of this file. Please review the
// following information to ensure the GNU General Public License version 3.0
// requirements will be met: http://www.gnu.org/copyleft/gpl.html.
//
// If you do not wish to use this file under the terms of the GPL version 3.0
// then you may purchase a commercial license. For more information contact
// info@riverbankcomputing.com.
//
// This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE
// WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
class QMediaAvailabilityControl : public QMediaControl
{
%TypeHeaderCode
#include <qmediaavailabilitycontrol.h>
%End
public:
virtual ~QMediaAvailabilityControl();
virtual QMultimedia::AvailabilityStatus availability() const = 0;
signals:
void availabilityChanged(QMultimedia::AvailabilityStatus availability);
protected:
explicit QMediaAvailabilityControl(QObject *parent /TransferThis/ = 0);
};

View File

@@ -0,0 +1,35 @@
// qmediabindableinterface.sip generated by MetaSIP
//
// This file is part of the QtMultimedia Python extension module.
//
// Copyright (c) 2024 Riverbank Computing Limited <info@riverbankcomputing.com>
//
// This file is part of PyQt5.
//
// This file may be used under the terms of the GNU General Public License
// version 3.0 as published by the Free Software Foundation and appearing in
// the file LICENSE included in the packaging of this file. Please review the
// following information to ensure the GNU General Public License version 3.0
// requirements will be met: http://www.gnu.org/copyleft/gpl.html.
//
// If you do not wish to use this file under the terms of the GPL version 3.0
// then you may purchase a commercial license. For more information contact
// info@riverbankcomputing.com.
//
// This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE
// WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
class QMediaBindableInterface
{
%TypeHeaderCode
#include <qmediabindableinterface.h>
%End
public:
virtual ~QMediaBindableInterface();
virtual QMediaObject *mediaObject() const = 0;
protected:
virtual bool setMediaObject(QMediaObject *object) = 0;
};

View File

@@ -0,0 +1,38 @@
// qmediacontainercontrol.sip generated by MetaSIP
//
// This file is part of the QtMultimedia Python extension module.
//
// Copyright (c) 2024 Riverbank Computing Limited <info@riverbankcomputing.com>
//
// This file is part of PyQt5.
//
// This file may be used under the terms of the GNU General Public License
// version 3.0 as published by the Free Software Foundation and appearing in
// the file LICENSE included in the packaging of this file. Please review the
// following information to ensure the GNU General Public License version 3.0
// requirements will be met: http://www.gnu.org/copyleft/gpl.html.
//
// If you do not wish to use this file under the terms of the GPL version 3.0
// then you may purchase a commercial license. For more information contact
// info@riverbankcomputing.com.
//
// This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE
// WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
class QMediaContainerControl : public QMediaControl
{
%TypeHeaderCode
#include <qmediacontainercontrol.h>
%End
public:
virtual ~QMediaContainerControl();
virtual QStringList supportedContainers() const = 0;
virtual QString containerFormat() const = 0;
virtual void setContainerFormat(const QString &format) = 0;
virtual QString containerDescription(const QString &formatMimeType) const = 0;
protected:
explicit QMediaContainerControl(QObject *parent /TransferThis/ = 0);
};

View File

@@ -0,0 +1,49 @@
// qmediacontent.sip generated by MetaSIP
//
// This file is part of the QtMultimedia Python extension module.
//
// Copyright (c) 2024 Riverbank Computing Limited <info@riverbankcomputing.com>
//
// This file is part of PyQt5.
//
// This file may be used under the terms of the GNU General Public License
// version 3.0 as published by the Free Software Foundation and appearing in
// the file LICENSE included in the packaging of this file. Please review the
// following information to ensure the GNU General Public License version 3.0
// requirements will be met: http://www.gnu.org/copyleft/gpl.html.
//
// If you do not wish to use this file under the terms of the GPL version 3.0
// then you may purchase a commercial license. For more information contact
// info@riverbankcomputing.com.
//
// This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE
// WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
class QMediaContent
{
%TypeHeaderCode
#include <qmediacontent.h>
%End
public:
QMediaContent();
QMediaContent(const QUrl &contentUrl);
QMediaContent(const QNetworkRequest &contentRequest);
QMediaContent(const QMediaResource &contentResource);
QMediaContent(const QMediaResourceList &resources);
QMediaContent(const QMediaContent &other);
QMediaContent(QMediaPlaylist *playlist, const QUrl &contentUrl = QUrl());
~QMediaContent();
bool operator==(const QMediaContent &other) const;
bool operator!=(const QMediaContent &other) const;
bool isNull() const;
QUrl canonicalUrl() const;
QNetworkRequest canonicalRequest() const;
QMediaResource canonicalResource() const;
QMediaResourceList resources() const;
QMediaPlaylist *playlist() const;
%If (Qt_5_14_0 -)
QNetworkRequest request() const;
%End
};

View File

@@ -0,0 +1,39 @@
// qmediacontrol.sip generated by MetaSIP
//
// This file is part of the QtMultimedia Python extension module.
//
// Copyright (c) 2024 Riverbank Computing Limited <info@riverbankcomputing.com>
//
// This file is part of PyQt5.
//
// This file may be used under the terms of the GNU General Public License
// version 3.0 as published by the Free Software Foundation and appearing in
// the file LICENSE included in the packaging of this file. Please review the
// following information to ensure the GNU General Public License version 3.0
// requirements will be met: http://www.gnu.org/copyleft/gpl.html.
//
// If you do not wish to use this file under the terms of the GPL version 3.0
// then you may purchase a commercial license. For more information contact
// info@riverbankcomputing.com.
//
// This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE
// WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
class QMediaControl : public QObject
{
%TypeHeaderCode
#include <qmediacontrol.h>
%End
public:
virtual ~QMediaControl();
protected:
%If (Qt_5_6_1 -)
explicit QMediaControl(QObject *parent /TransferThis/ = 0);
%End
%If (- Qt_5_6_1)
QMediaControl(QObject *parent /TransferThis/ = 0);
%End
};

View File

@@ -0,0 +1,110 @@
// qmediaencodersettings.sip generated by MetaSIP
//
// This file is part of the QtMultimedia Python extension module.
//
// Copyright (c) 2024 Riverbank Computing Limited <info@riverbankcomputing.com>
//
// This file is part of PyQt5.
//
// This file may be used under the terms of the GNU General Public License
// version 3.0 as published by the Free Software Foundation and appearing in
// the file LICENSE included in the packaging of this file. Please review the
// following information to ensure the GNU General Public License version 3.0
// requirements will be met: http://www.gnu.org/copyleft/gpl.html.
//
// If you do not wish to use this file under the terms of the GPL version 3.0
// then you may purchase a commercial license. For more information contact
// info@riverbankcomputing.com.
//
// This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE
// WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
class QAudioEncoderSettings
{
%TypeHeaderCode
#include <qmediaencodersettings.h>
%End
public:
QAudioEncoderSettings();
QAudioEncoderSettings(const QAudioEncoderSettings &other);
~QAudioEncoderSettings();
bool operator==(const QAudioEncoderSettings &other) const;
bool operator!=(const QAudioEncoderSettings &other) const;
bool isNull() const;
QMultimedia::EncodingMode encodingMode() const;
void setEncodingMode(QMultimedia::EncodingMode);
QString codec() const;
void setCodec(const QString &codec);
int bitRate() const;
void setBitRate(int bitrate);
int channelCount() const;
void setChannelCount(int channels);
int sampleRate() const;
void setSampleRate(int rate);
QMultimedia::EncodingQuality quality() const;
void setQuality(QMultimedia::EncodingQuality quality);
QVariant encodingOption(const QString &option) const;
QVariantMap encodingOptions() const;
void setEncodingOption(const QString &option, const QVariant &value);
void setEncodingOptions(const QVariantMap &options);
};
class QVideoEncoderSettings
{
%TypeHeaderCode
#include <qmediaencodersettings.h>
%End
public:
QVideoEncoderSettings();
QVideoEncoderSettings(const QVideoEncoderSettings &other);
~QVideoEncoderSettings();
bool operator==(const QVideoEncoderSettings &other) const;
bool operator!=(const QVideoEncoderSettings &other) const;
bool isNull() const;
QMultimedia::EncodingMode encodingMode() const;
void setEncodingMode(QMultimedia::EncodingMode);
QString codec() const;
void setCodec(const QString &);
QSize resolution() const;
void setResolution(const QSize &);
void setResolution(int width, int height);
qreal frameRate() const;
void setFrameRate(qreal rate);
int bitRate() const;
void setBitRate(int bitrate);
QMultimedia::EncodingQuality quality() const;
void setQuality(QMultimedia::EncodingQuality quality);
QVariant encodingOption(const QString &option) const;
QVariantMap encodingOptions() const;
void setEncodingOption(const QString &option, const QVariant &value);
void setEncodingOptions(const QVariantMap &options);
};
class QImageEncoderSettings
{
%TypeHeaderCode
#include <qmediaencodersettings.h>
%End
public:
QImageEncoderSettings();
QImageEncoderSettings(const QImageEncoderSettings &other);
~QImageEncoderSettings();
bool operator==(const QImageEncoderSettings &other) const;
bool operator!=(const QImageEncoderSettings &other) const;
bool isNull() const;
QString codec() const;
void setCodec(const QString &);
QSize resolution() const;
void setResolution(const QSize &);
void setResolution(int width, int height);
QMultimedia::EncodingQuality quality() const;
void setQuality(QMultimedia::EncodingQuality quality);
QVariant encodingOption(const QString &option) const;
QVariantMap encodingOptions() const;
void setEncodingOption(const QString &option, const QVariant &value);
void setEncodingOptions(const QVariantMap &options);
};

View File

@@ -0,0 +1,44 @@
// qmediagaplessplaybackcontrol.sip generated by MetaSIP
//
// This file is part of the QtMultimedia Python extension module.
//
// Copyright (c) 2024 Riverbank Computing Limited <info@riverbankcomputing.com>
//
// This file is part of PyQt5.
//
// This file may be used under the terms of the GNU General Public License
// version 3.0 as published by the Free Software Foundation and appearing in
// the file LICENSE included in the packaging of this file. Please review the
// following information to ensure the GNU General Public License version 3.0
// requirements will be met: http://www.gnu.org/copyleft/gpl.html.
//
// If you do not wish to use this file under the terms of the GPL version 3.0
// then you may purchase a commercial license. For more information contact
// info@riverbankcomputing.com.
//
// This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE
// WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
class QMediaGaplessPlaybackControl : public QMediaControl
{
%TypeHeaderCode
#include <qmediagaplessplaybackcontrol.h>
%End
public:
virtual ~QMediaGaplessPlaybackControl();
virtual QMediaContent nextMedia() const = 0;
virtual void setNextMedia(const QMediaContent &media) = 0;
virtual bool isCrossfadeSupported() const = 0;
virtual qreal crossfadeTime() const = 0;
virtual void setCrossfadeTime(qreal crossfadeTime) = 0;
signals:
void crossfadeTimeChanged(qreal crossfadeTime);
void nextMediaChanged(const QMediaContent &media);
void advancedToNextMedia();
protected:
explicit QMediaGaplessPlaybackControl(QObject *parent /TransferThis/ = 0);
};

View File

@@ -0,0 +1,120 @@
// qmediametadata.sip generated by MetaSIP
//
// This file is part of the QtMultimedia Python extension module.
//
// Copyright (c) 2024 Riverbank Computing Limited <info@riverbankcomputing.com>
//
// This file is part of PyQt5.
//
// This file may be used under the terms of the GNU General Public License
// version 3.0 as published by the Free Software Foundation and appearing in
// the file LICENSE included in the packaging of this file. Please review the
// following information to ensure the GNU General Public License version 3.0
// requirements will be met: http://www.gnu.org/copyleft/gpl.html.
//
// If you do not wish to use this file under the terms of the GPL version 3.0
// then you may purchase a commercial license. For more information contact
// info@riverbankcomputing.com.
//
// This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE
// WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
namespace QMediaMetaData
{
%TypeHeaderCode
#include <qmediametadata.h>
%End
const QString Title;
const QString SubTitle;
const QString Author;
const QString Comment;
const QString Description;
const QString Category;
const QString Genre;
const QString Year;
const QString Date;
const QString UserRating;
const QString Keywords;
const QString Language;
const QString Publisher;
const QString Copyright;
const QString ParentalRating;
const QString RatingOrganization;
const QString Size;
const QString MediaType;
const QString Duration;
const QString AudioBitRate;
const QString AudioCodec;
const QString AverageLevel;
const QString ChannelCount;
const QString PeakValue;
const QString SampleRate;
const QString AlbumTitle;
const QString AlbumArtist;
const QString ContributingArtist;
const QString Composer;
const QString Conductor;
const QString Lyrics;
const QString Mood;
const QString TrackNumber;
const QString TrackCount;
const QString CoverArtUrlSmall;
const QString CoverArtUrlLarge;
const QString Resolution;
const QString PixelAspectRatio;
const QString VideoFrameRate;
const QString VideoBitRate;
const QString VideoCodec;
const QString PosterUrl;
const QString ChapterNumber;
const QString Director;
const QString LeadPerformer;
const QString Writer;
const QString CameraManufacturer;
const QString CameraModel;
const QString Event;
const QString Subject;
const QString Orientation;
const QString ExposureTime;
const QString FNumber;
const QString ExposureProgram;
const QString ISOSpeedRatings;
const QString ExposureBiasValue;
const QString DateTimeOriginal;
const QString DateTimeDigitized;
const QString SubjectDistance;
const QString MeteringMode;
const QString LightSource;
const QString Flash;
const QString FocalLength;
const QString ExposureMode;
const QString WhiteBalance;
const QString DigitalZoomRatio;
const QString FocalLengthIn35mmFilm;
const QString SceneCaptureType;
const QString GainControl;
const QString Contrast;
const QString Saturation;
const QString Sharpness;
const QString DeviceSettingDescription;
const QString GPSLatitude;
const QString GPSLongitude;
const QString GPSAltitude;
const QString GPSTimeStamp;
const QString GPSSatellites;
const QString GPSStatus;
const QString GPSDOP;
const QString GPSSpeed;
const QString GPSTrack;
const QString GPSTrackRef;
const QString GPSImgDirection;
const QString GPSImgDirectionRef;
const QString GPSMapDatum;
const QString GPSProcessingMethod;
const QString GPSAreaInformation;
const QString PosterImage;
const QString CoverArtImage;
const QString ThumbnailImage;
};

View File

@@ -0,0 +1,39 @@
// qmedianetworkaccesscontrol.sip generated by MetaSIP
//
// This file is part of the QtMultimedia Python extension module.
//
// Copyright (c) 2024 Riverbank Computing Limited <info@riverbankcomputing.com>
//
// This file is part of PyQt5.
//
// This file may be used under the terms of the GNU General Public License
// version 3.0 as published by the Free Software Foundation and appearing in
// the file LICENSE included in the packaging of this file. Please review the
// following information to ensure the GNU General Public License version 3.0
// requirements will be met: http://www.gnu.org/copyleft/gpl.html.
//
// If you do not wish to use this file under the terms of the GPL version 3.0
// then you may purchase a commercial license. For more information contact
// info@riverbankcomputing.com.
//
// This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE
// WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
class QMediaNetworkAccessControl : public QMediaControl
{
%TypeHeaderCode
#include <qmedianetworkaccesscontrol.h>
%End
public:
virtual ~QMediaNetworkAccessControl();
virtual void setConfigurations(const QList<QNetworkConfiguration> &configuration) = 0;
virtual QNetworkConfiguration currentConfiguration() const = 0;
signals:
void configurationChanged(const QNetworkConfiguration &configuration);
protected:
explicit QMediaNetworkAccessControl(QObject *parent /TransferThis/ = 0);
};

View File

@@ -0,0 +1,54 @@
// qmediaobject.sip generated by MetaSIP
//
// This file is part of the QtMultimedia Python extension module.
//
// Copyright (c) 2024 Riverbank Computing Limited <info@riverbankcomputing.com>
//
// This file is part of PyQt5.
//
// This file may be used under the terms of the GNU General Public License
// version 3.0 as published by the Free Software Foundation and appearing in
// the file LICENSE included in the packaging of this file. Please review the
// following information to ensure the GNU General Public License version 3.0
// requirements will be met: http://www.gnu.org/copyleft/gpl.html.
//
// If you do not wish to use this file under the terms of the GPL version 3.0
// then you may purchase a commercial license. For more information contact
// info@riverbankcomputing.com.
//
// This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE
// WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
class QMediaObject : public QObject
{
%TypeHeaderCode
#include <qmediaobject.h>
%End
public:
virtual ~QMediaObject();
virtual bool isAvailable() const;
virtual QMultimedia::AvailabilityStatus availability() const;
virtual QMediaService *service() const;
int notifyInterval() const;
void setNotifyInterval(int milliSeconds);
virtual bool bind(QObject *);
virtual void unbind(QObject *);
bool isMetaDataAvailable() const;
QVariant metaData(const QString &key) const;
QStringList availableMetaData() const;
signals:
void notifyIntervalChanged(int milliSeconds);
void metaDataAvailableChanged(bool available);
void metaDataChanged();
void metaDataChanged(const QString &key, const QVariant &value);
void availabilityChanged(QMultimedia::AvailabilityStatus availability /Constrained/);
void availabilityChanged(bool available);
protected:
QMediaObject(QObject *parent /TransferThis/, QMediaService *service);
void addPropertyWatch(const QByteArray &name);
void removePropertyWatch(const QByteArray &name);
};

View File

@@ -0,0 +1,164 @@
// qmediaplayer.sip generated by MetaSIP
//
// This file is part of the QtMultimedia Python extension module.
//
// Copyright (c) 2024 Riverbank Computing Limited <info@riverbankcomputing.com>
//
// This file is part of PyQt5.
//
// This file may be used under the terms of the GNU General Public License
// version 3.0 as published by the Free Software Foundation and appearing in
// the file LICENSE included in the packaging of this file. Please review the
// following information to ensure the GNU General Public License version 3.0
// requirements will be met: http://www.gnu.org/copyleft/gpl.html.
//
// If you do not wish to use this file under the terms of the GPL version 3.0
// then you may purchase a commercial license. For more information contact
// info@riverbankcomputing.com.
//
// This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE
// WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
class QGraphicsVideoItem /External/;
class QVideoWidget /External/;
class QMediaPlayer : public QMediaObject
{
%TypeHeaderCode
#include <qmediaplayer.h>
%End
public:
enum State
{
StoppedState,
PlayingState,
PausedState,
};
enum MediaStatus
{
UnknownMediaStatus,
NoMedia,
LoadingMedia,
LoadedMedia,
StalledMedia,
BufferingMedia,
BufferedMedia,
EndOfMedia,
InvalidMedia,
};
enum Flag
{
LowLatency,
StreamPlayback,
VideoSurface,
};
typedef QFlags<QMediaPlayer::Flag> Flags;
enum Error
{
NoError,
ResourceError,
FormatError,
NetworkError,
AccessDeniedError,
ServiceMissingError,
};
QMediaPlayer(QObject *parent /TransferThis/ = 0, QMediaPlayer::Flags flags = QMediaPlayer::Flags());
virtual ~QMediaPlayer();
static QMultimedia::SupportEstimate hasSupport(const QString &mimeType, const QStringList &codecs = QStringList(), QMediaPlayer::Flags flags = QMediaPlayer::Flags());
static QStringList supportedMimeTypes(QMediaPlayer::Flags flags = QMediaPlayer::Flags());
void setVideoOutput(QVideoWidget *);
void setVideoOutput(QGraphicsVideoItem *);
void setVideoOutput(QAbstractVideoSurface *surface);
%If (Qt_5_15_0 -)
void setVideoOutput(const QVector<QAbstractVideoSurface *> &surfaces);
%End
QMediaContent media() const;
const QIODevice *mediaStream() const;
QMediaPlaylist *playlist() const;
QMediaContent currentMedia() const;
QMediaPlayer::State state() const;
QMediaPlayer::MediaStatus mediaStatus() const;
qint64 duration() const;
qint64 position() const;
int volume() const;
bool isMuted() const;
bool isAudioAvailable() const;
bool isVideoAvailable() const;
int bufferStatus() const;
bool isSeekable() const;
qreal playbackRate() const;
QMediaPlayer::Error error() const;
QString errorString() const;
QNetworkConfiguration currentNetworkConfiguration() const;
virtual QMultimedia::AvailabilityStatus availability() const;
public slots:
void play();
void pause();
void stop();
void setPosition(qint64 position);
void setVolume(int volume);
void setMuted(bool muted);
void setPlaybackRate(qreal rate);
void setMedia(const QMediaContent &media, QIODevice *stream = 0);
void setPlaylist(QMediaPlaylist *playlist);
void setNetworkConfigurations(const QList<QNetworkConfiguration> &configurations);
signals:
void mediaChanged(const QMediaContent &media);
void currentMediaChanged(const QMediaContent &media);
void stateChanged(QMediaPlayer::State newState);
void mediaStatusChanged(QMediaPlayer::MediaStatus status);
void durationChanged(qint64 duration);
void positionChanged(qint64 position);
void volumeChanged(int volume);
void mutedChanged(bool muted);
void audioAvailableChanged(bool available);
void videoAvailableChanged(bool videoAvailable);
void bufferStatusChanged(int percentFilled);
void seekableChanged(bool seekable);
void playbackRateChanged(qreal rate);
void error(QMediaPlayer::Error error);
void networkConfigurationChanged(const QNetworkConfiguration &configuration);
public:
virtual bool bind(QObject *);
virtual void unbind(QObject *);
%If (Qt_5_6_0 -)
QAudio::Role audioRole() const;
%End
%If (Qt_5_6_0 -)
void setAudioRole(QAudio::Role audioRole);
%End
%If (Qt_5_6_0 -)
QList<QAudio::Role> supportedAudioRoles() const;
%End
signals:
%If (Qt_5_6_0 -)
void audioRoleChanged(QAudio::Role role);
%End
public:
%If (Qt_5_11_0 -)
QString customAudioRole() const;
%End
%If (Qt_5_11_0 -)
void setCustomAudioRole(const QString &audioRole);
%End
%If (Qt_5_11_0 -)
QStringList supportedCustomAudioRoles() const;
%End
signals:
%If (Qt_5_11_0 -)
void customAudioRoleChanged(const QString &role);
%End
};

View File

@@ -0,0 +1,72 @@
// qmediaplayercontrol.sip generated by MetaSIP
//
// This file is part of the QtMultimedia Python extension module.
//
// Copyright (c) 2024 Riverbank Computing Limited <info@riverbankcomputing.com>
//
// This file is part of PyQt5.
//
// This file may be used under the terms of the GNU General Public License
// version 3.0 as published by the Free Software Foundation and appearing in
// the file LICENSE included in the packaging of this file. Please review the
// following information to ensure the GNU General Public License version 3.0
// requirements will be met: http://www.gnu.org/copyleft/gpl.html.
//
// If you do not wish to use this file under the terms of the GPL version 3.0
// then you may purchase a commercial license. For more information contact
// info@riverbankcomputing.com.
//
// This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE
// WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
class QMediaPlayerControl : public QMediaControl
{
%TypeHeaderCode
#include <qmediaplayercontrol.h>
%End
public:
virtual ~QMediaPlayerControl();
virtual QMediaPlayer::State state() const = 0;
virtual QMediaPlayer::MediaStatus mediaStatus() const = 0;
virtual qint64 duration() const = 0;
virtual qint64 position() const = 0;
virtual void setPosition(qint64 position) = 0;
virtual int volume() const = 0;
virtual void setVolume(int volume) = 0;
virtual bool isMuted() const = 0;
virtual void setMuted(bool mute) = 0;
virtual int bufferStatus() const = 0;
virtual bool isAudioAvailable() const = 0;
virtual bool isVideoAvailable() const = 0;
virtual bool isSeekable() const = 0;
virtual QMediaTimeRange availablePlaybackRanges() const = 0;
virtual qreal playbackRate() const = 0;
virtual void setPlaybackRate(qreal rate) = 0;
virtual QMediaContent media() const = 0;
virtual const QIODevice *mediaStream() const = 0;
virtual void setMedia(const QMediaContent &media, QIODevice *stream) = 0;
virtual void play() = 0;
virtual void pause() = 0;
virtual void stop() = 0;
signals:
void mediaChanged(const QMediaContent &content);
void durationChanged(qint64 duration);
void positionChanged(qint64 position);
void stateChanged(QMediaPlayer::State newState);
void mediaStatusChanged(QMediaPlayer::MediaStatus status);
void volumeChanged(int volume);
void mutedChanged(bool mute);
void audioAvailableChanged(bool audioAvailable);
void videoAvailableChanged(bool videoAvailable);
void bufferStatusChanged(int percentFilled);
void seekableChanged(bool seekable);
void availablePlaybackRangesChanged(const QMediaTimeRange &ranges);
void playbackRateChanged(qreal rate);
void error(int error, const QString &errorString);
protected:
explicit QMediaPlayerControl(QObject *parent /TransferThis/ = 0);
};

View File

@@ -0,0 +1,104 @@
// qmediaplaylist.sip generated by MetaSIP
//
// This file is part of the QtMultimedia Python extension module.
//
// Copyright (c) 2024 Riverbank Computing Limited <info@riverbankcomputing.com>
//
// This file is part of PyQt5.
//
// This file may be used under the terms of the GNU General Public License
// version 3.0 as published by the Free Software Foundation and appearing in
// the file LICENSE included in the packaging of this file. Please review the
// following information to ensure the GNU General Public License version 3.0
// requirements will be met: http://www.gnu.org/copyleft/gpl.html.
//
// If you do not wish to use this file under the terms of the GPL version 3.0
// then you may purchase a commercial license. For more information contact
// info@riverbankcomputing.com.
//
// This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE
// WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
class QMediaPlaylist : public QObject, public QMediaBindableInterface
{
%TypeHeaderCode
#include <qmediaplaylist.h>
%End
public:
enum PlaybackMode
{
CurrentItemOnce,
CurrentItemInLoop,
Sequential,
Loop,
Random,
};
enum Error
{
NoError,
FormatError,
FormatNotSupportedError,
NetworkError,
AccessDeniedError,
};
%If (Qt_5_6_1 -)
explicit QMediaPlaylist(QObject *parent /TransferThis/ = 0);
%End
%If (- Qt_5_6_1)
QMediaPlaylist(QObject *parent /TransferThis/ = 0);
%End
virtual ~QMediaPlaylist();
virtual QMediaObject *mediaObject() const;
QMediaPlaylist::PlaybackMode playbackMode() const;
void setPlaybackMode(QMediaPlaylist::PlaybackMode mode);
int currentIndex() const;
QMediaContent currentMedia() const;
int nextIndex(int steps = 1) const;
int previousIndex(int steps = 1) const;
QMediaContent media(int index) const;
int mediaCount() const;
bool isEmpty() const;
bool isReadOnly() const;
bool addMedia(const QMediaContent &content);
bool addMedia(const QList<QMediaContent> &items);
bool insertMedia(int index, const QMediaContent &content);
bool insertMedia(int index, const QList<QMediaContent> &items);
bool removeMedia(int pos);
bool removeMedia(int start, int end);
bool clear();
void load(const QNetworkRequest &request, const char *format = 0) /ReleaseGIL/;
void load(const QUrl &location, const char *format = 0) /ReleaseGIL/;
void load(QIODevice *device, const char *format = 0) /ReleaseGIL/;
bool save(const QUrl &location, const char *format = 0) /ReleaseGIL/;
bool save(QIODevice *device, const char *format) /ReleaseGIL/;
QMediaPlaylist::Error error() const;
QString errorString() const;
%If (Qt_5_7_0 -)
bool moveMedia(int from, int to);
%End
public slots:
void shuffle();
void next();
void previous();
void setCurrentIndex(int index);
signals:
void currentIndexChanged(int index);
void playbackModeChanged(QMediaPlaylist::PlaybackMode mode);
void currentMediaChanged(const QMediaContent &);
void mediaAboutToBeInserted(int start, int end);
void mediaInserted(int start, int end);
void mediaAboutToBeRemoved(int start, int end);
void mediaRemoved(int start, int end);
void mediaChanged(int start, int end);
void loaded();
void loadFailed();
protected:
virtual bool setMediaObject(QMediaObject *object);
};

View File

@@ -0,0 +1,118 @@
// qmediarecorder.sip generated by MetaSIP
//
// This file is part of the QtMultimedia Python extension module.
//
// Copyright (c) 2024 Riverbank Computing Limited <info@riverbankcomputing.com>
//
// This file is part of PyQt5.
//
// This file may be used under the terms of the GNU General Public License
// version 3.0 as published by the Free Software Foundation and appearing in
// the file LICENSE included in the packaging of this file. Please review the
// following information to ensure the GNU General Public License version 3.0
// requirements will be met: http://www.gnu.org/copyleft/gpl.html.
//
// If you do not wish to use this file under the terms of the GPL version 3.0
// then you may purchase a commercial license. For more information contact
// info@riverbankcomputing.com.
//
// This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE
// WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
class QMediaRecorder : public QObject, public QMediaBindableInterface
{
%TypeHeaderCode
#include <qmediarecorder.h>
%End
public:
enum State
{
StoppedState,
RecordingState,
PausedState,
};
enum Status
{
UnavailableStatus,
UnloadedStatus,
LoadingStatus,
LoadedStatus,
StartingStatus,
RecordingStatus,
PausedStatus,
FinalizingStatus,
};
enum Error
{
NoError,
ResourceError,
FormatError,
OutOfSpaceError,
};
QMediaRecorder(QMediaObject *mediaObject, QObject *parent /TransferThis/ = 0);
virtual ~QMediaRecorder();
virtual QMediaObject *mediaObject() const;
bool isAvailable() const;
QMultimedia::AvailabilityStatus availability() const;
QUrl outputLocation() const;
bool setOutputLocation(const QUrl &location);
QUrl actualLocation() const;
QMediaRecorder::State state() const;
QMediaRecorder::Status status() const;
QMediaRecorder::Error error() const;
QString errorString() const;
qint64 duration() const;
bool isMuted() const;
qreal volume() const;
QStringList supportedContainers() const;
QString containerDescription(const QString &format) const;
QStringList supportedAudioCodecs() const;
QString audioCodecDescription(const QString &codecName) const;
QList<int> supportedAudioSampleRates(const QAudioEncoderSettings &settings = QAudioEncoderSettings(), bool *continuous = 0) const;
QStringList supportedVideoCodecs() const;
QString videoCodecDescription(const QString &codecName) const;
QList<QSize> supportedResolutions(const QVideoEncoderSettings &settings = QVideoEncoderSettings(), bool *continuous = 0) const;
QList<qreal> supportedFrameRates(const QVideoEncoderSettings &settings = QVideoEncoderSettings(), bool *continuous = 0) const;
QAudioEncoderSettings audioSettings() const;
QVideoEncoderSettings videoSettings() const;
QString containerFormat() const;
void setAudioSettings(const QAudioEncoderSettings &audioSettings);
void setVideoSettings(const QVideoEncoderSettings &videoSettings);
void setContainerFormat(const QString &container);
void setEncodingSettings(const QAudioEncoderSettings &audio, const QVideoEncoderSettings &video = QVideoEncoderSettings(), const QString &container = QString());
bool isMetaDataAvailable() const;
bool isMetaDataWritable() const;
QVariant metaData(const QString &key) const;
void setMetaData(const QString &key, const QVariant &value);
QStringList availableMetaData() const;
public slots:
void record();
void pause();
void stop();
void setMuted(bool muted);
void setVolume(qreal volume);
signals:
void stateChanged(QMediaRecorder::State state);
void statusChanged(QMediaRecorder::Status status);
void durationChanged(qint64 duration);
void mutedChanged(bool muted);
void volumeChanged(qreal volume);
void actualLocationChanged(const QUrl &location);
void error(QMediaRecorder::Error error);
void metaDataAvailableChanged(bool available);
void metaDataWritableChanged(bool writable);
void metaDataChanged(const QString &key, const QVariant &value);
void metaDataChanged();
void availabilityChanged(QMultimedia::AvailabilityStatus availability /Constrained/);
void availabilityChanged(bool available);
protected:
virtual bool setMediaObject(QMediaObject *object);
};

View File

@@ -0,0 +1,56 @@
// qmediarecordercontrol.sip generated by MetaSIP
//
// This file is part of the QtMultimedia Python extension module.
//
// Copyright (c) 2024 Riverbank Computing Limited <info@riverbankcomputing.com>
//
// This file is part of PyQt5.
//
// This file may be used under the terms of the GNU General Public License
// version 3.0 as published by the Free Software Foundation and appearing in
// the file LICENSE included in the packaging of this file. Please review the
// following information to ensure the GNU General Public License version 3.0
// requirements will be met: http://www.gnu.org/copyleft/gpl.html.
//
// If you do not wish to use this file under the terms of the GPL version 3.0
// then you may purchase a commercial license. For more information contact
// info@riverbankcomputing.com.
//
// This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE
// WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
class QMediaRecorderControl : public QMediaControl
{
%TypeHeaderCode
#include <qmediarecordercontrol.h>
%End
public:
virtual ~QMediaRecorderControl();
virtual QUrl outputLocation() const = 0;
virtual bool setOutputLocation(const QUrl &location) = 0;
virtual QMediaRecorder::State state() const = 0;
virtual QMediaRecorder::Status status() const = 0;
virtual qint64 duration() const = 0;
virtual bool isMuted() const = 0;
virtual qreal volume() const = 0;
virtual void applySettings() = 0;
signals:
void stateChanged(QMediaRecorder::State state);
void statusChanged(QMediaRecorder::Status status);
void durationChanged(qint64 position);
void mutedChanged(bool muted);
void volumeChanged(qreal volume);
void actualLocationChanged(const QUrl &location);
void error(int error, const QString &errorString);
public slots:
virtual void setState(QMediaRecorder::State state) = 0;
virtual void setMuted(bool muted) = 0;
virtual void setVolume(qreal volume) = 0;
protected:
explicit QMediaRecorderControl(QObject *parent /TransferThis/ = 0);
};

View File

@@ -0,0 +1,62 @@
// qmediaresource.sip generated by MetaSIP
//
// This file is part of the QtMultimedia Python extension module.
//
// Copyright (c) 2024 Riverbank Computing Limited <info@riverbankcomputing.com>
//
// This file is part of PyQt5.
//
// This file may be used under the terms of the GNU General Public License
// version 3.0 as published by the Free Software Foundation and appearing in
// the file LICENSE included in the packaging of this file. Please review the
// following information to ensure the GNU General Public License version 3.0
// requirements will be met: http://www.gnu.org/copyleft/gpl.html.
//
// If you do not wish to use this file under the terms of the GPL version 3.0
// then you may purchase a commercial license. For more information contact
// info@riverbankcomputing.com.
//
// This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE
// WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
class QMediaResource
{
%TypeHeaderCode
#include <qmediaresource.h>
%End
public:
QMediaResource();
QMediaResource(const QUrl &url, const QString &mimeType = QString());
QMediaResource(const QNetworkRequest &request, const QString &mimeType = QString());
QMediaResource(const QMediaResource &other);
~QMediaResource();
bool isNull() const;
bool operator==(const QMediaResource &other) const;
bool operator!=(const QMediaResource &other) const;
QUrl url() const;
QNetworkRequest request() const;
QString mimeType() const;
QString language() const;
void setLanguage(const QString &language);
QString audioCodec() const;
void setAudioCodec(const QString &codec);
QString videoCodec() const;
void setVideoCodec(const QString &codec);
qint64 dataSize() const;
void setDataSize(const qint64 size);
int audioBitRate() const;
void setAudioBitRate(int rate);
int sampleRate() const;
void setSampleRate(int frequency);
int channelCount() const;
void setChannelCount(int channels);
int videoBitRate() const;
void setVideoBitRate(int rate);
QSize resolution() const;
void setResolution(const QSize &resolution);
void setResolution(int width, int height);
};
typedef QList<QMediaResource> QMediaResourceList;

View File

@@ -0,0 +1,36 @@
// qmediaservice.sip generated by MetaSIP
//
// This file is part of the QtMultimedia Python extension module.
//
// Copyright (c) 2024 Riverbank Computing Limited <info@riverbankcomputing.com>
//
// This file is part of PyQt5.
//
// This file may be used under the terms of the GNU General Public License
// version 3.0 as published by the Free Software Foundation and appearing in
// the file LICENSE included in the packaging of this file. Please review the
// following information to ensure the GNU General Public License version 3.0
// requirements will be met: http://www.gnu.org/copyleft/gpl.html.
//
// If you do not wish to use this file under the terms of the GPL version 3.0
// then you may purchase a commercial license. For more information contact
// info@riverbankcomputing.com.
//
// This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE
// WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
class QMediaService : public QObject
{
%TypeHeaderCode
#include <qmediaservice.h>
%End
public:
virtual ~QMediaService();
virtual QMediaControl *requestControl(const char *name) = 0;
virtual void releaseControl(QMediaControl *control) = 0;
protected:
QMediaService(QObject *parent /TransferThis/);
};

View File

@@ -0,0 +1,52 @@
// qmediastreamscontrol.sip generated by MetaSIP
//
// This file is part of the QtMultimedia Python extension module.
//
// Copyright (c) 2024 Riverbank Computing Limited <info@riverbankcomputing.com>
//
// This file is part of PyQt5.
//
// This file may be used under the terms of the GNU General Public License
// version 3.0 as published by the Free Software Foundation and appearing in
// the file LICENSE included in the packaging of this file. Please review the
// following information to ensure the GNU General Public License version 3.0
// requirements will be met: http://www.gnu.org/copyleft/gpl.html.
//
// If you do not wish to use this file under the terms of the GPL version 3.0
// then you may purchase a commercial license. For more information contact
// info@riverbankcomputing.com.
//
// This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE
// WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
class QMediaStreamsControl : public QMediaControl
{
%TypeHeaderCode
#include <qmediastreamscontrol.h>
%End
public:
enum StreamType
{
UnknownStream,
VideoStream,
AudioStream,
SubPictureStream,
DataStream,
};
virtual ~QMediaStreamsControl();
virtual int streamCount() = 0;
virtual QMediaStreamsControl::StreamType streamType(int streamNumber) = 0;
virtual QVariant metaData(int streamNumber, const QString &key) = 0;
virtual bool isActive(int streamNumber) = 0;
virtual void setActive(int streamNumber, bool state) = 0;
signals:
void streamsChanged();
void activeStreamsChanged();
protected:
explicit QMediaStreamsControl(QObject *parent /TransferThis/ = 0);
};

View File

@@ -0,0 +1,78 @@
// qmediatimerange.sip generated by MetaSIP
//
// This file is part of the QtMultimedia Python extension module.
//
// Copyright (c) 2024 Riverbank Computing Limited <info@riverbankcomputing.com>
//
// This file is part of PyQt5.
//
// This file may be used under the terms of the GNU General Public License
// version 3.0 as published by the Free Software Foundation and appearing in
// the file LICENSE included in the packaging of this file. Please review the
// following information to ensure the GNU General Public License version 3.0
// requirements will be met: http://www.gnu.org/copyleft/gpl.html.
//
// If you do not wish to use this file under the terms of the GPL version 3.0
// then you may purchase a commercial license. For more information contact
// info@riverbankcomputing.com.
//
// This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE
// WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
class QMediaTimeInterval
{
%TypeHeaderCode
#include <qmediatimerange.h>
%End
public:
QMediaTimeInterval();
QMediaTimeInterval(qint64 start, qint64 end);
QMediaTimeInterval(const QMediaTimeInterval &);
qint64 start() const;
qint64 end() const;
bool contains(qint64 time) const;
bool isNormal() const;
QMediaTimeInterval normalized() const;
QMediaTimeInterval translated(qint64 offset) const;
};
bool operator==(const QMediaTimeInterval &, const QMediaTimeInterval &);
bool operator!=(const QMediaTimeInterval &, const QMediaTimeInterval &);
class QMediaTimeRange
{
%TypeHeaderCode
#include <qmediatimerange.h>
%End
public:
QMediaTimeRange();
QMediaTimeRange(qint64 start, qint64 end);
QMediaTimeRange(const QMediaTimeInterval &);
QMediaTimeRange(const QMediaTimeRange &range);
~QMediaTimeRange();
qint64 earliestTime() const;
qint64 latestTime() const;
QList<QMediaTimeInterval> intervals() const;
bool isEmpty() const;
bool isContinuous() const;
bool contains(qint64 time) const;
void addInterval(qint64 start, qint64 end);
void addInterval(const QMediaTimeInterval &interval);
void addTimeRange(const QMediaTimeRange &);
void removeInterval(qint64 start, qint64 end);
void removeInterval(const QMediaTimeInterval &interval);
void removeTimeRange(const QMediaTimeRange &);
QMediaTimeRange &operator+=(const QMediaTimeRange &);
QMediaTimeRange &operator+=(const QMediaTimeInterval &);
QMediaTimeRange &operator-=(const QMediaTimeRange &);
QMediaTimeRange &operator-=(const QMediaTimeInterval &);
void clear();
};
bool operator==(const QMediaTimeRange &, const QMediaTimeRange &);
bool operator!=(const QMediaTimeRange &, const QMediaTimeRange &);
QMediaTimeRange operator+(const QMediaTimeRange &, const QMediaTimeRange &);
QMediaTimeRange operator-(const QMediaTimeRange &, const QMediaTimeRange &);

View File

@@ -0,0 +1,38 @@
// qmediavideoprobecontrol.sip generated by MetaSIP
//
// This file is part of the QtMultimedia Python extension module.
//
// Copyright (c) 2024 Riverbank Computing Limited <info@riverbankcomputing.com>
//
// This file is part of PyQt5.
//
// This file may be used under the terms of the GNU General Public License
// version 3.0 as published by the Free Software Foundation and appearing in
// the file LICENSE included in the packaging of this file. Please review the
// following information to ensure the GNU General Public License version 3.0
// requirements will be met: http://www.gnu.org/copyleft/gpl.html.
//
// If you do not wish to use this file under the terms of the GPL version 3.0
// then you may purchase a commercial license. For more information contact
// info@riverbankcomputing.com.
//
// This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE
// WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
class QMediaVideoProbeControl : public QMediaControl
{
%TypeHeaderCode
#include <qmediavideoprobecontrol.h>
%End
public:
virtual ~QMediaVideoProbeControl();
signals:
void videoFrameProbed(const QVideoFrame &frame);
void flush();
protected:
explicit QMediaVideoProbeControl(QObject *parent /TransferThis/ = 0);
};

View File

@@ -0,0 +1,42 @@
// qmetadatareadercontrol.sip generated by MetaSIP
//
// This file is part of the QtMultimedia Python extension module.
//
// Copyright (c) 2024 Riverbank Computing Limited <info@riverbankcomputing.com>
//
// This file is part of PyQt5.
//
// This file may be used under the terms of the GNU General Public License
// version 3.0 as published by the Free Software Foundation and appearing in
// the file LICENSE included in the packaging of this file. Please review the
// following information to ensure the GNU General Public License version 3.0
// requirements will be met: http://www.gnu.org/copyleft/gpl.html.
//
// If you do not wish to use this file under the terms of the GPL version 3.0
// then you may purchase a commercial license. For more information contact
// info@riverbankcomputing.com.
//
// This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE
// WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
class QMetaDataReaderControl : public QMediaControl
{
%TypeHeaderCode
#include <qmetadatareadercontrol.h>
%End
public:
virtual ~QMetaDataReaderControl();
virtual bool isMetaDataAvailable() const = 0;
virtual QVariant metaData(const QString &key) const = 0;
virtual QStringList availableMetaData() const = 0;
signals:
void metaDataChanged();
void metaDataChanged(const QString &key, const QVariant &value);
void metaDataAvailableChanged(bool available);
protected:
explicit QMetaDataReaderControl(QObject *parent /TransferThis/ = 0);
};

View File

@@ -0,0 +1,45 @@
// qmetadatawritercontrol.sip generated by MetaSIP
//
// This file is part of the QtMultimedia Python extension module.
//
// Copyright (c) 2024 Riverbank Computing Limited <info@riverbankcomputing.com>
//
// This file is part of PyQt5.
//
// This file may be used under the terms of the GNU General Public License
// version 3.0 as published by the Free Software Foundation and appearing in
// the file LICENSE included in the packaging of this file. Please review the
// following information to ensure the GNU General Public License version 3.0
// requirements will be met: http://www.gnu.org/copyleft/gpl.html.
//
// If you do not wish to use this file under the terms of the GPL version 3.0
// then you may purchase a commercial license. For more information contact
// info@riverbankcomputing.com.
//
// This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE
// WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
class QMetaDataWriterControl : public QMediaControl
{
%TypeHeaderCode
#include <qmetadatawritercontrol.h>
%End
public:
virtual ~QMetaDataWriterControl();
virtual bool isWritable() const = 0;
virtual bool isMetaDataAvailable() const = 0;
virtual QVariant metaData(const QString &key) const = 0;
virtual void setMetaData(const QString &key, const QVariant &value) = 0;
virtual QStringList availableMetaData() const = 0;
signals:
void metaDataChanged();
void metaDataChanged(const QString &key, const QVariant &value);
void writableChanged(bool writable);
void metaDataAvailableChanged(bool available);
protected:
explicit QMetaDataWriterControl(QObject *parent /TransferThis/ = 0);
};

View File

@@ -0,0 +1,61 @@
// qmultimedia.sip generated by MetaSIP
//
// This file is part of the QtMultimedia Python extension module.
//
// Copyright (c) 2024 Riverbank Computing Limited <info@riverbankcomputing.com>
//
// This file is part of PyQt5.
//
// This file may be used under the terms of the GNU General Public License
// version 3.0 as published by the Free Software Foundation and appearing in
// the file LICENSE included in the packaging of this file. Please review the
// following information to ensure the GNU General Public License version 3.0
// requirements will be met: http://www.gnu.org/copyleft/gpl.html.
//
// If you do not wish to use this file under the terms of the GPL version 3.0
// then you may purchase a commercial license. For more information contact
// info@riverbankcomputing.com.
//
// This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE
// WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
namespace QMultimedia
{
%TypeHeaderCode
#include <qmultimedia.h>
%End
enum SupportEstimate
{
NotSupported,
MaybeSupported,
ProbablySupported,
PreferredService,
};
enum EncodingQuality
{
VeryLowQuality,
LowQuality,
NormalQuality,
HighQuality,
VeryHighQuality,
};
enum EncodingMode
{
ConstantQualityEncoding,
ConstantBitRateEncoding,
AverageBitRateEncoding,
TwoPassEncoding,
};
enum AvailabilityStatus
{
Available,
ServiceMissing,
Busy,
ResourceError,
};
};

View File

@@ -0,0 +1,443 @@
// This is the SIP interface definition for the QList based mapped types
// specific to the QtMultimedia module.
//
// Copyright (c) 2024 Riverbank Computing Limited <info@riverbankcomputing.com>
//
// This file is part of PyQt5.
//
// This file may be used under the terms of the GNU General Public License
// version 3.0 as published by the Free Software Foundation and appearing in
// the file LICENSE included in the packaging of this file. Please review the
// following information to ensure the GNU General Public License version 3.0
// requirements will be met: http://www.gnu.org/copyleft/gpl.html.
//
// If you do not wish to use this file under the terms of the GPL version 3.0
// then you may purchase a commercial license. For more information contact
// info@riverbankcomputing.com.
//
// This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE
// WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
%MappedType QList<QVideoFrame::PixelFormat>
/TypeHintIn="Iterable[QVideoFrame.PixelFormat]",
TypeHintOut="List[QVideoFrame.PixelFormat]", TypeHintValue="[]"/
{
%TypeHeaderCode
#include <qvideoframe.h>
%End
%ConvertFromTypeCode
PyObject *l = PyList_New(sipCpp->size());
if (!l)
return 0;
for (int i = 0; i < sipCpp->size(); ++i)
{
PyObject *eobj = sipConvertFromEnum(sipCpp->at(i),
sipType_QVideoFrame_PixelFormat);
if (!eobj)
{
Py_DECREF(l);
return 0;
}
PyList_SetItem(l, i, eobj);
}
return l;
%End
%ConvertToTypeCode
PyObject *iter = PyObject_GetIter(sipPy);
if (!sipIsErr)
{
PyErr_Clear();
Py_XDECREF(iter);
return (iter
#if PY_MAJOR_VERSION < 3
&& !PyString_Check(sipPy)
#endif
&& !PyUnicode_Check(sipPy));
}
if (!iter)
{
*sipIsErr = 1;
return 0;
}
QList<QVideoFrame::PixelFormat> *ql = new QList<QVideoFrame::PixelFormat>;
for (Py_ssize_t i = 0; ; ++i)
{
PyErr_Clear();
PyObject *itm = PyIter_Next(iter);
if (!itm)
{
if (PyErr_Occurred())
{
delete ql;
Py_DECREF(iter);
*sipIsErr = 1;
return 0;
}
break;
}
int v = sipConvertToEnum(itm, sipType_QVideoFrame_PixelFormat);
if (PyErr_Occurred())
{
PyErr_Format(PyExc_TypeError,
"index %zd has type '%s' but 'QVideoFrame.PixelFormat' is expected",
i, sipPyTypeName(Py_TYPE(itm)));
Py_DECREF(itm);
delete ql;
Py_DECREF(iter);
*sipIsErr = 1;
return 0;
}
ql->append(static_cast<QVideoFrame::PixelFormat>(v));
Py_DECREF(itm);
}
Py_DECREF(iter);
*sipCppPtr = ql;
return sipGetState(sipTransferObj);
%End
};
%MappedType QList<QAudioFormat::Endian>
/TypeHintIn="Iterable[QAudioFormat.Endian]",
TypeHintOut="List[QAudioFormat.Endian]", TypeHintValue="[]"/
{
%TypeHeaderCode
#include <qaudioformat.h>
%End
%ConvertFromTypeCode
PyObject *l = PyList_New(sipCpp->size());
if (!l)
return 0;
for (int i = 0; i < sipCpp->size(); ++i)
{
PyObject *eobj = sipConvertFromEnum(sipCpp->at(i),
sipType_QAudioFormat_Endian);
if (!eobj)
{
Py_DECREF(l);
return 0;
}
PyList_SetItem(l, i, eobj);
}
return l;
%End
%ConvertToTypeCode
PyObject *iter = PyObject_GetIter(sipPy);
if (!sipIsErr)
{
PyErr_Clear();
Py_XDECREF(iter);
return (iter
#if PY_MAJOR_VERSION < 3
&& !PyString_Check(sipPy)
#endif
&& !PyUnicode_Check(sipPy));
}
if (!iter)
{
*sipIsErr = 1;
return 0;
}
QList<QAudioFormat::Endian> *ql = new QList<QAudioFormat::Endian>;
for (Py_ssize_t i = 0; ; ++i)
{
PyErr_Clear();
PyObject *itm = PyIter_Next(iter);
if (!itm)
{
if (PyErr_Occurred())
{
delete ql;
Py_DECREF(iter);
*sipIsErr = 1;
return 0;
}
break;
}
int v = sipConvertToEnum(itm, sipType_QAudioFormat_Endian);
if (PyErr_Occurred())
{
PyErr_Format(PyExc_TypeError,
"index %zd has type '%s' but 'QAudioFormat.Endian' is expected",
i, sipPyTypeName(Py_TYPE(itm)));
Py_DECREF(itm);
delete ql;
Py_DECREF(iter);
*sipIsErr = 1;
return 0;
}
ql->append(static_cast<QAudioFormat::Endian>(v));
Py_DECREF(itm);
}
Py_DECREF(iter);
*sipCppPtr = ql;
return sipGetState(sipTransferObj);
%End
};
%MappedType QList<QAudioFormat::SampleType>
/TypeHintIn="Iterable[QAudioFormat.SampleType]",
TypeHintOut="List[QAudioFormat.SampleType]", TypeHintValue="[]"/
{
%TypeHeaderCode
#include <qaudioformat.h>
%End
%ConvertFromTypeCode
PyObject *l = PyList_New(sipCpp->size());
if (!l)
return 0;
for (int i = 0; i < sipCpp->size(); ++i)
{
PyObject *eobj = sipConvertFromEnum(sipCpp->at(i),
sipType_QAudioFormat_SampleType);
if (!eobj)
{
Py_DECREF(l);
return 0;
}
PyList_SetItem(l, i, eobj);
}
return l;
%End
%ConvertToTypeCode
PyObject *iter = PyObject_GetIter(sipPy);
if (!sipIsErr)
{
PyErr_Clear();
Py_XDECREF(iter);
return (iter
#if PY_MAJOR_VERSION < 3
&& !PyString_Check(sipPy)
#endif
&& !PyUnicode_Check(sipPy));
}
if (!iter)
{
*sipIsErr = 1;
return 0;
}
QList<QAudioFormat::SampleType> *ql = new QList<QAudioFormat::SampleType>;
for (Py_ssize_t i = 0; ; ++i)
{
PyErr_Clear();
PyObject *itm = PyIter_Next(iter);
if (!itm)
{
if (PyErr_Occurred())
{
delete ql;
Py_DECREF(iter);
*sipIsErr = 1;
return 0;
}
break;
}
int v = sipConvertToEnum(itm, sipType_QAudioFormat_SampleType);
if (PyErr_Occurred())
{
PyErr_Format(PyExc_TypeError,
"index %zd has type '%s' but 'QAudioFormat.SampleType' is expected",
i, sipPyTypeName(Py_TYPE(itm)));
Py_DECREF(itm);
delete ql;
Py_DECREF(iter);
*sipIsErr = 1;
return 0;
}
ql->append(static_cast<QAudioFormat::SampleType>(v));
Py_DECREF(itm);
}
Py_DECREF(iter);
*sipCppPtr = ql;
return sipGetState(sipTransferObj);
%End
};
%If (Qt_5_6_0 -)
%MappedType QList<QAudio::Role>
/TypeHintIn="Iterable[QAudio.Role]",
TypeHintOut="List[QAudio.Role]", TypeHintValue="[]"/
{
%TypeHeaderCode
#include <qaudio.h>
%End
%ConvertFromTypeCode
PyObject *l = PyList_New(sipCpp->size());
if (!l)
return 0;
for (int i = 0; i < sipCpp->size(); ++i)
{
PyObject *eobj = sipConvertFromEnum(sipCpp->at(i),
sipType_QAudio_Role);
if (!eobj)
{
Py_DECREF(l);
return 0;
}
PyList_SetItem(l, i, eobj);
}
return l;
%End
%ConvertToTypeCode
PyObject *iter = PyObject_GetIter(sipPy);
if (!sipIsErr)
{
PyErr_Clear();
Py_XDECREF(iter);
return (iter
#if PY_MAJOR_VERSION < 3
&& !PyString_Check(sipPy)
#endif
&& !PyUnicode_Check(sipPy));
}
if (!iter)
{
*sipIsErr = 1;
return 0;
}
QList<QAudio::Role> *ql = new QList<QAudio::Role>;
for (Py_ssize_t i = 0; ; ++i)
{
PyErr_Clear();
PyObject *itm = PyIter_Next(iter);
if (!itm)
{
if (PyErr_Occurred())
{
delete ql;
Py_DECREF(iter);
*sipIsErr = 1;
return 0;
}
break;
}
int v = sipConvertToEnum(itm, sipType_QAudio_Role);
if (PyErr_Occurred())
{
PyErr_Format(PyExc_TypeError,
"index %zd has type '%s' but 'QAudio.Role' is expected",
i, sipPyTypeName(Py_TYPE(itm)));
Py_DECREF(itm);
delete ql;
Py_DECREF(iter);
*sipIsErr = 1;
return 0;
}
ql->append(static_cast<QAudio::Role>(v));
Py_DECREF(itm);
}
Py_DECREF(iter);
*sipCppPtr = ql;
return sipGetState(sipTransferObj);
%End
};
%End

View File

@@ -0,0 +1,117 @@
// qradiodata.sip generated by MetaSIP
//
// This file is part of the QtMultimedia Python extension module.
//
// Copyright (c) 2024 Riverbank Computing Limited <info@riverbankcomputing.com>
//
// This file is part of PyQt5.
//
// This file may be used under the terms of the GNU General Public License
// version 3.0 as published by the Free Software Foundation and appearing in
// the file LICENSE included in the packaging of this file. Please review the
// following information to ensure the GNU General Public License version 3.0
// requirements will be met: http://www.gnu.org/copyleft/gpl.html.
//
// If you do not wish to use this file under the terms of the GPL version 3.0
// then you may purchase a commercial license. For more information contact
// info@riverbankcomputing.com.
//
// This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE
// WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
class QRadioData : public QObject, public QMediaBindableInterface
{
%TypeHeaderCode
#include <qradiodata.h>
%End
public:
enum Error
{
NoError,
ResourceError,
OpenError,
OutOfRangeError,
};
enum ProgramType
{
Undefined,
News,
CurrentAffairs,
Information,
Sport,
Education,
Drama,
Culture,
Science,
Varied,
PopMusic,
RockMusic,
EasyListening,
LightClassical,
SeriousClassical,
OtherMusic,
Weather,
Finance,
ChildrensProgrammes,
SocialAffairs,
Religion,
PhoneIn,
Travel,
Leisure,
JazzMusic,
CountryMusic,
NationalMusic,
OldiesMusic,
FolkMusic,
Documentary,
AlarmTest,
Alarm,
Talk,
ClassicRock,
AdultHits,
SoftRock,
Top40,
Soft,
Nostalgia,
Classical,
RhythmAndBlues,
SoftRhythmAndBlues,
Language,
ReligiousMusic,
ReligiousTalk,
Personality,
Public,
College,
};
QRadioData(QMediaObject *mediaObject, QObject *parent /TransferThis/ = 0);
virtual ~QRadioData();
virtual QMediaObject *mediaObject() const;
QMultimedia::AvailabilityStatus availability() const;
QString stationId() const;
QRadioData::ProgramType programType() const;
QString programTypeName() const;
QString stationName() const;
QString radioText() const;
bool isAlternativeFrequenciesEnabled() const;
QRadioData::Error error() const;
QString errorString() const;
public slots:
void setAlternativeFrequenciesEnabled(bool enabled);
signals:
void stationIdChanged(QString stationId);
void programTypeChanged(QRadioData::ProgramType programType);
void programTypeNameChanged(QString programTypeName);
void stationNameChanged(QString stationName);
void radioTextChanged(QString radioText);
void alternativeFrequenciesEnabledChanged(bool enabled);
void error(QRadioData::Error error);
protected:
virtual bool setMediaObject(QMediaObject *);
};

View File

@@ -0,0 +1,52 @@
// qradiodatacontrol.sip generated by MetaSIP
//
// This file is part of the QtMultimedia Python extension module.
//
// Copyright (c) 2024 Riverbank Computing Limited <info@riverbankcomputing.com>
//
// This file is part of PyQt5.
//
// This file may be used under the terms of the GNU General Public License
// version 3.0 as published by the Free Software Foundation and appearing in
// the file LICENSE included in the packaging of this file. Please review the
// following information to ensure the GNU General Public License version 3.0
// requirements will be met: http://www.gnu.org/copyleft/gpl.html.
//
// If you do not wish to use this file under the terms of the GPL version 3.0
// then you may purchase a commercial license. For more information contact
// info@riverbankcomputing.com.
//
// This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE
// WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
class QRadioDataControl : public QMediaControl
{
%TypeHeaderCode
#include <qradiodatacontrol.h>
%End
public:
virtual ~QRadioDataControl();
virtual QString stationId() const = 0;
virtual QRadioData::ProgramType programType() const = 0;
virtual QString programTypeName() const = 0;
virtual QString stationName() const = 0;
virtual QString radioText() const = 0;
virtual void setAlternativeFrequenciesEnabled(bool enabled) = 0;
virtual bool isAlternativeFrequenciesEnabled() const = 0;
virtual QRadioData::Error error() const = 0;
virtual QString errorString() const = 0;
signals:
void stationIdChanged(QString stationId);
void programTypeChanged(QRadioData::ProgramType programType);
void programTypeNameChanged(QString programTypeName);
void stationNameChanged(QString stationName);
void radioTextChanged(QString radioText);
void alternativeFrequenciesEnabledChanged(bool enabled);
void error(QRadioData::Error err);
protected:
explicit QRadioDataControl(QObject *parent /TransferThis/ = 0);
};

View File

@@ -0,0 +1,116 @@
// qradiotuner.sip generated by MetaSIP
//
// This file is part of the QtMultimedia Python extension module.
//
// Copyright (c) 2024 Riverbank Computing Limited <info@riverbankcomputing.com>
//
// This file is part of PyQt5.
//
// This file may be used under the terms of the GNU General Public License
// version 3.0 as published by the Free Software Foundation and appearing in
// the file LICENSE included in the packaging of this file. Please review the
// following information to ensure the GNU General Public License version 3.0
// requirements will be met: http://www.gnu.org/copyleft/gpl.html.
//
// If you do not wish to use this file under the terms of the GPL version 3.0
// then you may purchase a commercial license. For more information contact
// info@riverbankcomputing.com.
//
// This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE
// WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
class QRadioTuner : public QMediaObject
{
%TypeHeaderCode
#include <qradiotuner.h>
%End
public:
enum State
{
ActiveState,
StoppedState,
};
enum Band
{
AM,
FM,
SW,
LW,
FM2,
};
enum Error
{
NoError,
ResourceError,
OpenError,
OutOfRangeError,
};
enum StereoMode
{
ForceStereo,
ForceMono,
Auto,
};
enum SearchMode
{
SearchFast,
SearchGetStationId,
};
%If (Qt_5_6_1 -)
explicit QRadioTuner(QObject *parent /TransferThis/ = 0);
%End
%If (- Qt_5_6_1)
QRadioTuner(QObject *parent /TransferThis/ = 0);
%End
virtual ~QRadioTuner();
virtual QMultimedia::AvailabilityStatus availability() const;
QRadioTuner::State state() const;
QRadioTuner::Band band() const;
bool isBandSupported(QRadioTuner::Band b) const;
int frequency() const;
int frequencyStep(QRadioTuner::Band band) const;
QPair<int, int> frequencyRange(QRadioTuner::Band band) const;
bool isStereo() const;
void setStereoMode(QRadioTuner::StereoMode mode);
QRadioTuner::StereoMode stereoMode() const;
int signalStrength() const;
int volume() const;
bool isMuted() const;
bool isSearching() const;
bool isAntennaConnected() const;
QRadioTuner::Error error() const;
QString errorString() const;
QRadioData *radioData() const;
public slots:
void searchForward();
void searchBackward();
void searchAllStations(QRadioTuner::SearchMode searchMode = QRadioTuner::SearchFast);
void cancelSearch();
void setBand(QRadioTuner::Band band);
void setFrequency(int frequency);
void setVolume(int volume);
void setMuted(bool muted);
void start();
void stop();
signals:
void stateChanged(QRadioTuner::State state);
void bandChanged(QRadioTuner::Band band);
void frequencyChanged(int frequency);
void stereoStatusChanged(bool stereo);
void searchingChanged(bool searching);
void signalStrengthChanged(int signalStrength);
void volumeChanged(int volume);
void mutedChanged(bool muted);
void stationFound(int frequency, QString stationId);
void antennaConnectedChanged(bool connectionStatus);
void error(QRadioTuner::Error error);
};

View File

@@ -0,0 +1,73 @@
// qradiotunercontrol.sip generated by MetaSIP
//
// This file is part of the QtMultimedia Python extension module.
//
// Copyright (c) 2024 Riverbank Computing Limited <info@riverbankcomputing.com>
//
// This file is part of PyQt5.
//
// This file may be used under the terms of the GNU General Public License
// version 3.0 as published by the Free Software Foundation and appearing in
// the file LICENSE included in the packaging of this file. Please review the
// following information to ensure the GNU General Public License version 3.0
// requirements will be met: http://www.gnu.org/copyleft/gpl.html.
//
// If you do not wish to use this file under the terms of the GPL version 3.0
// then you may purchase a commercial license. For more information contact
// info@riverbankcomputing.com.
//
// This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE
// WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
class QRadioTunerControl : public QMediaControl
{
%TypeHeaderCode
#include <qradiotunercontrol.h>
%End
public:
virtual ~QRadioTunerControl();
virtual QRadioTuner::State state() const = 0;
virtual QRadioTuner::Band band() const = 0;
virtual void setBand(QRadioTuner::Band b) = 0;
virtual bool isBandSupported(QRadioTuner::Band b) const = 0;
virtual int frequency() const = 0;
virtual int frequencyStep(QRadioTuner::Band b) const = 0;
virtual QPair<int, int> frequencyRange(QRadioTuner::Band b) const = 0;
virtual void setFrequency(int frequency) = 0;
virtual bool isStereo() const = 0;
virtual QRadioTuner::StereoMode stereoMode() const = 0;
virtual void setStereoMode(QRadioTuner::StereoMode mode) = 0;
virtual int signalStrength() const = 0;
virtual int volume() const = 0;
virtual void setVolume(int volume) = 0;
virtual bool isMuted() const = 0;
virtual void setMuted(bool muted) = 0;
virtual bool isSearching() const = 0;
virtual bool isAntennaConnected() const;
virtual void searchForward() = 0;
virtual void searchBackward() = 0;
virtual void searchAllStations(QRadioTuner::SearchMode searchMode = QRadioTuner::SearchFast) = 0;
virtual void cancelSearch() = 0;
virtual void start() = 0;
virtual void stop() = 0;
virtual QRadioTuner::Error error() const = 0;
virtual QString errorString() const = 0;
signals:
void stateChanged(QRadioTuner::State state);
void bandChanged(QRadioTuner::Band band);
void frequencyChanged(int frequency);
void stereoStatusChanged(bool stereo);
void searchingChanged(bool searching);
void signalStrengthChanged(int signalStrength);
void volumeChanged(int volume);
void mutedChanged(bool muted);
void error(QRadioTuner::Error err);
void stationFound(int frequency, QString stationId);
void antennaConnectedChanged(bool connectionStatus);
protected:
explicit QRadioTunerControl(QObject *parent /TransferThis/ = 0);
};

View File

@@ -0,0 +1,47 @@
// qsound.sip generated by MetaSIP
//
// This file is part of the QtMultimedia Python extension module.
//
// Copyright (c) 2024 Riverbank Computing Limited <info@riverbankcomputing.com>
//
// This file is part of PyQt5.
//
// This file may be used under the terms of the GNU General Public License
// version 3.0 as published by the Free Software Foundation and appearing in
// the file LICENSE included in the packaging of this file. Please review the
// following information to ensure the GNU General Public License version 3.0
// requirements will be met: http://www.gnu.org/copyleft/gpl.html.
//
// If you do not wish to use this file under the terms of the GPL version 3.0
// then you may purchase a commercial license. For more information contact
// info@riverbankcomputing.com.
//
// This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE
// WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
class QSound : public QObject
{
%TypeHeaderCode
#include <qsound.h>
%End
public:
enum Loop
{
Infinite,
};
QSound(const QString &filename, QObject *parent /TransferThis/ = 0);
virtual ~QSound();
static void play(const QString &filename);
int loops() const;
int loopsRemaining() const;
void setLoops(int);
QString fileName() const;
bool isFinished() const;
public slots:
void play();
void stop();
};

View File

@@ -0,0 +1,78 @@
// qsoundeffect.sip generated by MetaSIP
//
// This file is part of the QtMultimedia Python extension module.
//
// Copyright (c) 2024 Riverbank Computing Limited <info@riverbankcomputing.com>
//
// This file is part of PyQt5.
//
// This file may be used under the terms of the GNU General Public License
// version 3.0 as published by the Free Software Foundation and appearing in
// the file LICENSE included in the packaging of this file. Please review the
// following information to ensure the GNU General Public License version 3.0
// requirements will be met: http://www.gnu.org/copyleft/gpl.html.
//
// If you do not wish to use this file under the terms of the GPL version 3.0
// then you may purchase a commercial license. For more information contact
// info@riverbankcomputing.com.
//
// This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE
// WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
class QSoundEffect : public QObject
{
%TypeHeaderCode
#include <qsoundeffect.h>
%End
public:
enum Loop
{
Infinite,
};
enum Status
{
Null,
Loading,
Ready,
Error,
};
explicit QSoundEffect(QObject *parent /TransferThis/ = 0);
%If (Qt_5_13_0 -)
QSoundEffect(const QAudioDeviceInfo &audioDevice, QObject *parent /TransferThis/ = 0);
%End
virtual ~QSoundEffect();
static QStringList supportedMimeTypes();
QUrl source() const;
void setSource(const QUrl &url);
int loopCount() const;
int loopsRemaining() const;
void setLoopCount(int loopCount);
qreal volume() const;
void setVolume(qreal volume);
bool isMuted() const;
void setMuted(bool muted);
bool isLoaded() const;
bool isPlaying() const;
QSoundEffect::Status status() const;
QString category() const;
void setCategory(const QString &category);
signals:
void sourceChanged();
void loopCountChanged();
void loopsRemainingChanged();
void volumeChanged();
void mutedChanged();
void loadedChanged();
void playingChanged();
void statusChanged();
void categoryChanged();
public slots:
void play();
void stop();
};

View File

@@ -0,0 +1,47 @@
// qvideodeviceselectorcontrol.sip generated by MetaSIP
//
// This file is part of the QtMultimedia Python extension module.
//
// Copyright (c) 2024 Riverbank Computing Limited <info@riverbankcomputing.com>
//
// This file is part of PyQt5.
//
// This file may be used under the terms of the GNU General Public License
// version 3.0 as published by the Free Software Foundation and appearing in
// the file LICENSE included in the packaging of this file. Please review the
// following information to ensure the GNU General Public License version 3.0
// requirements will be met: http://www.gnu.org/copyleft/gpl.html.
//
// If you do not wish to use this file under the terms of the GPL version 3.0
// then you may purchase a commercial license. For more information contact
// info@riverbankcomputing.com.
//
// This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE
// WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
class QVideoDeviceSelectorControl : public QMediaControl
{
%TypeHeaderCode
#include <qvideodeviceselectorcontrol.h>
%End
public:
virtual ~QVideoDeviceSelectorControl();
virtual int deviceCount() const = 0;
virtual QString deviceName(int index) const = 0;
virtual QString deviceDescription(int index) const = 0;
virtual int defaultDevice() const = 0;
virtual int selectedDevice() const = 0;
public slots:
virtual void setSelectedDevice(int index) = 0;
signals:
void selectedDeviceChanged(int index);
void selectedDeviceChanged(const QString &name);
void devicesChanged();
protected:
explicit QVideoDeviceSelectorControl(QObject *parent /TransferThis/ = 0);
};

View File

@@ -0,0 +1,40 @@
// qvideoencodersettingscontrol.sip generated by MetaSIP
//
// This file is part of the QtMultimedia Python extension module.
//
// Copyright (c) 2024 Riverbank Computing Limited <info@riverbankcomputing.com>
//
// This file is part of PyQt5.
//
// This file may be used under the terms of the GNU General Public License
// version 3.0 as published by the Free Software Foundation and appearing in
// the file LICENSE included in the packaging of this file. Please review the
// following information to ensure the GNU General Public License version 3.0
// requirements will be met: http://www.gnu.org/copyleft/gpl.html.
//
// If you do not wish to use this file under the terms of the GPL version 3.0
// then you may purchase a commercial license. For more information contact
// info@riverbankcomputing.com.
//
// This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE
// WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
class QVideoEncoderSettingsControl : public QMediaControl
{
%TypeHeaderCode
#include <qvideoencodersettingscontrol.h>
%End
public:
virtual ~QVideoEncoderSettingsControl();
virtual QList<QSize> supportedResolutions(const QVideoEncoderSettings &settings, bool *continuous = 0) const = 0;
virtual QList<double> supportedFrameRates(const QVideoEncoderSettings &settings, bool *continuous = 0) const = 0;
virtual QStringList supportedVideoCodecs() const = 0;
virtual QString videoCodecDescription(const QString &codec) const = 0;
virtual QVideoEncoderSettings videoSettings() const = 0;
virtual void setVideoSettings(const QVideoEncoderSettings &settings) = 0;
protected:
explicit QVideoEncoderSettingsControl(QObject *parent /TransferThis/ = 0);
};

View File

@@ -0,0 +1,154 @@
// qvideoframe.sip generated by MetaSIP
//
// This file is part of the QtMultimedia Python extension module.
//
// Copyright (c) 2024 Riverbank Computing Limited <info@riverbankcomputing.com>
//
// This file is part of PyQt5.
//
// This file may be used under the terms of the GNU General Public License
// version 3.0 as published by the Free Software Foundation and appearing in
// the file LICENSE included in the packaging of this file. Please review the
// following information to ensure the GNU General Public License version 3.0
// requirements will be met: http://www.gnu.org/copyleft/gpl.html.
//
// If you do not wish to use this file under the terms of the GPL version 3.0
// then you may purchase a commercial license. For more information contact
// info@riverbankcomputing.com.
//
// This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE
// WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
class QVideoFrame
{
%TypeHeaderCode
#include <qvideoframe.h>
%End
public:
enum FieldType
{
ProgressiveFrame,
TopField,
BottomField,
InterlacedFrame,
};
enum PixelFormat
{
Format_Invalid,
Format_ARGB32,
Format_ARGB32_Premultiplied,
Format_RGB32,
Format_RGB24,
Format_RGB565,
Format_RGB555,
Format_ARGB8565_Premultiplied,
Format_BGRA32,
Format_BGRA32_Premultiplied,
Format_BGR32,
Format_BGR24,
Format_BGR565,
Format_BGR555,
Format_BGRA5658_Premultiplied,
Format_AYUV444,
Format_AYUV444_Premultiplied,
Format_YUV444,
Format_YUV420P,
Format_YV12,
Format_UYVY,
Format_YUYV,
Format_NV12,
Format_NV21,
Format_IMC1,
Format_IMC2,
Format_IMC3,
Format_IMC4,
Format_Y8,
Format_Y16,
Format_Jpeg,
Format_CameraRaw,
Format_AdobeDng,
%If (Qt_5_13_0 -)
Format_ABGR32,
%End
%If (Qt_5_14_0 -)
Format_YUV422P,
%End
Format_User,
};
QVideoFrame();
QVideoFrame(QAbstractVideoBuffer *buffer, const QSize &size, QVideoFrame::PixelFormat format);
QVideoFrame(int bytes, const QSize &size, int bytesPerLine, QVideoFrame::PixelFormat format);
QVideoFrame(const QImage &image);
QVideoFrame(const QVideoFrame &other);
~QVideoFrame();
bool isValid() const;
QVideoFrame::PixelFormat pixelFormat() const;
QAbstractVideoBuffer::HandleType handleType() const;
QSize size() const;
int width() const;
int height() const;
QVideoFrame::FieldType fieldType() const;
void setFieldType(QVideoFrame::FieldType);
bool isMapped() const;
bool isReadable() const;
bool isWritable() const;
QAbstractVideoBuffer::MapMode mapMode() const;
bool map(QAbstractVideoBuffer::MapMode mode);
void unmap();
int bytesPerLine() const;
%If (Qt_5_4_0 -)
int bytesPerLine(int plane) const;
%End
SIP_PYOBJECT bits() /TypeHint="PyQt5.sip.voidptr"/;
%MethodCode
uchar *mem;
Py_BEGIN_ALLOW_THREADS
mem = sipCpp->bits();
Py_END_ALLOW_THREADS
if (mem)
{
sipRes = sipConvertFromVoidPtrAndSize(mem, sipCpp->mappedBytes());
}
else
{
sipRes = Py_None;
Py_INCREF(sipRes);
}
%End
%If (Qt_5_4_0 -)
void *bits(int plane) [uchar * (int plane)];
%End
int mappedBytes() const;
QVariant handle() const;
qint64 startTime() const;
void setStartTime(qint64 time);
qint64 endTime() const;
void setEndTime(qint64 time);
static QVideoFrame::PixelFormat pixelFormatFromImageFormat(QImage::Format format);
static QImage::Format imageFormatFromPixelFormat(QVideoFrame::PixelFormat format);
QVariantMap availableMetaData() const;
QVariant metaData(const QString &key) const;
void setMetaData(const QString &key, const QVariant &value);
%If (Qt_5_4_0 -)
int planeCount() const;
%End
%If (Qt_5_5_0 -)
bool operator==(const QVideoFrame &other) const;
%End
%If (Qt_5_5_0 -)
bool operator!=(const QVideoFrame &other) const;
%End
%If (Qt_5_13_0 -)
QAbstractVideoBuffer *buffer() const;
%End
%If (Qt_5_15_0 -)
QImage image() const;
%End
};

View File

@@ -0,0 +1,39 @@
// qvideoprobe.sip generated by MetaSIP
//
// This file is part of the QtMultimedia Python extension module.
//
// Copyright (c) 2024 Riverbank Computing Limited <info@riverbankcomputing.com>
//
// This file is part of PyQt5.
//
// This file may be used under the terms of the GNU General Public License
// version 3.0 as published by the Free Software Foundation and appearing in
// the file LICENSE included in the packaging of this file. Please review the
// following information to ensure the GNU General Public License version 3.0
// requirements will be met: http://www.gnu.org/copyleft/gpl.html.
//
// If you do not wish to use this file under the terms of the GPL version 3.0
// then you may purchase a commercial license. For more information contact
// info@riverbankcomputing.com.
//
// This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE
// WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
class QVideoProbe : public QObject
{
%TypeHeaderCode
#include <qvideoprobe.h>
%End
public:
explicit QVideoProbe(QObject *parent /TransferThis/ = 0);
virtual ~QVideoProbe();
bool setSource(QMediaObject *source);
bool setSource(QMediaRecorder *source);
bool isActive() const;
signals:
void videoFrameProbed(const QVideoFrame &videoFrame);
void flush();
};

View File

@@ -0,0 +1,36 @@
// qvideorenderercontrol.sip generated by MetaSIP
//
// This file is part of the QtMultimedia Python extension module.
//
// Copyright (c) 2024 Riverbank Computing Limited <info@riverbankcomputing.com>
//
// This file is part of PyQt5.
//
// This file may be used under the terms of the GNU General Public License
// version 3.0 as published by the Free Software Foundation and appearing in
// the file LICENSE included in the packaging of this file. Please review the
// following information to ensure the GNU General Public License version 3.0
// requirements will be met: http://www.gnu.org/copyleft/gpl.html.
//
// If you do not wish to use this file under the terms of the GPL version 3.0
// then you may purchase a commercial license. For more information contact
// info@riverbankcomputing.com.
//
// This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE
// WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
class QVideoRendererControl : public QMediaControl
{
%TypeHeaderCode
#include <qvideorenderercontrol.h>
%End
public:
virtual ~QVideoRendererControl();
virtual QAbstractVideoSurface *surface() const = 0;
virtual void setSurface(QAbstractVideoSurface *surface) = 0;
protected:
explicit QVideoRendererControl(QObject *parent /TransferThis/ = 0);
};

View File

@@ -0,0 +1,81 @@
// qvideosurfaceformat.sip generated by MetaSIP
//
// This file is part of the QtMultimedia Python extension module.
//
// Copyright (c) 2024 Riverbank Computing Limited <info@riverbankcomputing.com>
//
// This file is part of PyQt5.
//
// This file may be used under the terms of the GNU General Public License
// version 3.0 as published by the Free Software Foundation and appearing in
// the file LICENSE included in the packaging of this file. Please review the
// following information to ensure the GNU General Public License version 3.0
// requirements will be met: http://www.gnu.org/copyleft/gpl.html.
//
// If you do not wish to use this file under the terms of the GPL version 3.0
// then you may purchase a commercial license. For more information contact
// info@riverbankcomputing.com.
//
// This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE
// WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
class QVideoSurfaceFormat
{
%TypeHeaderCode
#include <qvideosurfaceformat.h>
%End
public:
enum Direction
{
TopToBottom,
BottomToTop,
};
enum YCbCrColorSpace
{
YCbCr_Undefined,
YCbCr_BT601,
YCbCr_BT709,
YCbCr_xvYCC601,
YCbCr_xvYCC709,
YCbCr_JPEG,
};
QVideoSurfaceFormat();
QVideoSurfaceFormat(const QSize &size, QVideoFrame::PixelFormat format, QAbstractVideoBuffer::HandleType type = QAbstractVideoBuffer::NoHandle);
QVideoSurfaceFormat(const QVideoSurfaceFormat &format);
~QVideoSurfaceFormat();
bool operator==(const QVideoSurfaceFormat &format) const;
bool operator!=(const QVideoSurfaceFormat &format) const;
bool isValid() const;
QVideoFrame::PixelFormat pixelFormat() const;
QAbstractVideoBuffer::HandleType handleType() const;
QSize frameSize() const;
void setFrameSize(const QSize &size);
void setFrameSize(int width, int height);
int frameWidth() const;
int frameHeight() const;
QRect viewport() const;
void setViewport(const QRect &viewport);
QVideoSurfaceFormat::Direction scanLineDirection() const;
void setScanLineDirection(QVideoSurfaceFormat::Direction direction);
qreal frameRate() const;
void setFrameRate(qreal rate);
QSize pixelAspectRatio() const;
void setPixelAspectRatio(const QSize &ratio);
void setPixelAspectRatio(int width, int height);
QVideoSurfaceFormat::YCbCrColorSpace yCbCrColorSpace() const;
void setYCbCrColorSpace(QVideoSurfaceFormat::YCbCrColorSpace colorSpace);
QSize sizeHint() const;
QList<QByteArray> propertyNames() const;
QVariant property(const char *name) const;
void setProperty(const char *name, const QVariant &value);
%If (Qt_5_11_0 -)
bool isMirrored() const;
%End
%If (Qt_5_11_0 -)
void setMirrored(bool mirrored);
%End
};

View File

@@ -0,0 +1,60 @@
// qvideowindowcontrol.sip generated by MetaSIP
//
// This file is part of the QtMultimedia Python extension module.
//
// Copyright (c) 2024 Riverbank Computing Limited <info@riverbankcomputing.com>
//
// This file is part of PyQt5.
//
// This file may be used under the terms of the GNU General Public License
// version 3.0 as published by the Free Software Foundation and appearing in
// the file LICENSE included in the packaging of this file. Please review the
// following information to ensure the GNU General Public License version 3.0
// requirements will be met: http://www.gnu.org/copyleft/gpl.html.
//
// If you do not wish to use this file under the terms of the GPL version 3.0
// then you may purchase a commercial license. For more information contact
// info@riverbankcomputing.com.
//
// This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE
// WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
class QVideoWindowControl : public QMediaControl
{
%TypeHeaderCode
#include <qvideowindowcontrol.h>
%End
public:
virtual ~QVideoWindowControl();
virtual WId winId() const = 0;
virtual void setWinId(WId id) = 0;
virtual QRect displayRect() const = 0;
virtual void setDisplayRect(const QRect &rect) = 0;
virtual bool isFullScreen() const = 0;
virtual void setFullScreen(bool fullScreen) = 0;
virtual void repaint() = 0;
virtual QSize nativeSize() const = 0;
virtual Qt::AspectRatioMode aspectRatioMode() const = 0;
virtual void setAspectRatioMode(Qt::AspectRatioMode mode) = 0;
virtual int brightness() const = 0;
virtual void setBrightness(int brightness) = 0;
virtual int contrast() const = 0;
virtual void setContrast(int contrast) = 0;
virtual int hue() const = 0;
virtual void setHue(int hue) = 0;
virtual int saturation() const = 0;
virtual void setSaturation(int saturation) = 0;
signals:
void fullScreenChanged(bool fullScreen);
void brightnessChanged(int brightness);
void contrastChanged(int contrast);
void hueChanged(int hue);
void saturationChanged(int saturation);
void nativeSizeChanged();
protected:
explicit QVideoWindowControl(QObject *parent /TransferThis/ = 0);
};