/*
 * Interface wrapper code.
 *
 * Generated by SIP 6.6.2
 *
 * Copyright (c) 2022 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.
 */

#include "sipAPIQtMultimedia.h"

#line 26 "/build/pyqt5/src/PyQt5-5.15.7/sip/QtMultimedia/qabstractvideosurface.sip"
#include <qabstractvideosurface.h>
#line 29 "/build/pyqt5/src/PyQt5-5.15.7/build/QtMultimedia/sipQtMultimediaQAbstractVideoSurface.cpp"

#line 28 "/build/pyqt5/src/PyQt5-5.15.7/sip/QtCore/qobject.sip"
#include <qobject.h>
#line 33 "/build/pyqt5/src/PyQt5-5.15.7/build/QtMultimedia/sipQtMultimediaQAbstractVideoSurface.cpp"
#line 26 "/build/pyqt5/src/PyQt5-5.15.7/sip/QtCore/qsize.sip"
#include <qsize.h>
#line 36 "/build/pyqt5/src/PyQt5-5.15.7/build/QtMultimedia/sipQtMultimediaQAbstractVideoSurface.cpp"
#line 26 "/build/pyqt5/src/PyQt5-5.15.7/sip/QtMultimedia/qvideosurfaceformat.sip"
#include <qvideosurfaceformat.h>
#line 39 "/build/pyqt5/src/PyQt5-5.15.7/build/QtMultimedia/sipQtMultimediaQAbstractVideoSurface.cpp"
#line 26 "/build/pyqt5/src/PyQt5-5.15.7/sip/QtMultimedia/qvideoframe.sip"
#include <qvideoframe.h>
#line 42 "/build/pyqt5/src/PyQt5-5.15.7/build/QtMultimedia/sipQtMultimediaQAbstractVideoSurface.cpp"
#line 27 "/build/pyqt5/src/PyQt5-5.15.7/sip/QtMultimedia/qpymultimedia_qlist.sip"
#include <qvideoframe.h>
#line 45 "/build/pyqt5/src/PyQt5-5.15.7/build/QtMultimedia/sipQtMultimediaQAbstractVideoSurface.cpp"
#line 26 "/build/pyqt5/src/PyQt5-5.15.7/sip/QtMultimedia/qabstractvideobuffer.sip"
#include <qabstractvideobuffer.h>
#line 48 "/build/pyqt5/src/PyQt5-5.15.7/build/QtMultimedia/sipQtMultimediaQAbstractVideoSurface.cpp"
#line 26 "/build/pyqt5/src/PyQt5-5.15.7/sip/QtCore/qobjectdefs.sip"
#include <qobjectdefs.h>
#line 146 "/build/pyqt5/src/PyQt5-5.15.7/sip/QtCore/qobjectdefs.sip"
#include <qobjectdefs.h>
#line 53 "/build/pyqt5/src/PyQt5-5.15.7/build/QtMultimedia/sipQtMultimediaQAbstractVideoSurface.cpp"
#line 26 "/build/pyqt5/src/PyQt5-5.15.7/sip/QtCore/qmetaobject.sip"
#include <qmetaobject.h>
#line 56 "/build/pyqt5/src/PyQt5-5.15.7/build/QtMultimedia/sipQtMultimediaQAbstractVideoSurface.cpp"
#line 26 "/build/pyqt5/src/PyQt5-5.15.7/sip/QtCore/qcoreevent.sip"
#include <qcoreevent.h>
#line 59 "/build/pyqt5/src/PyQt5-5.15.7/build/QtMultimedia/sipQtMultimediaQAbstractVideoSurface.cpp"
#line 247 "/build/pyqt5/src/PyQt5-5.15.7/sip/QtCore/qcoreevent.sip"
#include <qcoreevent.h>
#line 62 "/build/pyqt5/src/PyQt5-5.15.7/build/QtMultimedia/sipQtMultimediaQAbstractVideoSurface.cpp"
#line 235 "/build/pyqt5/src/PyQt5-5.15.7/sip/QtCore/qcoreevent.sip"
#include <qcoreevent.h>
#line 65 "/build/pyqt5/src/PyQt5-5.15.7/build/QtMultimedia/sipQtMultimediaQAbstractVideoSurface.cpp"
#line 27 "/build/pyqt5/src/PyQt5-5.15.7/sip/QtCore/qstring.sip"
#include <qstring.h>
#line 68 "/build/pyqt5/src/PyQt5-5.15.7/build/QtMultimedia/sipQtMultimediaQAbstractVideoSurface.cpp"
#line 26 "/build/pyqt5/src/PyQt5-5.15.7/sip/QtCore/qvariant.sip"
#include <qvariant.h>
#line 71 "/build/pyqt5/src/PyQt5-5.15.7/build/QtMultimedia/sipQtMultimediaQAbstractVideoSurface.cpp"
#line 38 "/build/pyqt5/src/PyQt5-5.15.7/sip/QtCore/qpycore_qlist.sip"
#include <qlist.h>
#line 74 "/build/pyqt5/src/PyQt5-5.15.7/build/QtMultimedia/sipQtMultimediaQAbstractVideoSurface.cpp"
#line 30 "/build/pyqt5/src/PyQt5-5.15.7/sip/QtCore/qbytearray.sip"
#include <qbytearray.h>
#line 77 "/build/pyqt5/src/PyQt5-5.15.7/build/QtMultimedia/sipQtMultimediaQAbstractVideoSurface.cpp"
#line 149 "/build/pyqt5/src/PyQt5-5.15.7/sip/QtCore/qpycore_qlist.sip"
#include <qlist.h>
#line 80 "/build/pyqt5/src/PyQt5-5.15.7/build/QtMultimedia/sipQtMultimediaQAbstractVideoSurface.cpp"
#line 26 "/build/pyqt5/src/PyQt5-5.15.7/sip/QtCore/qnamespace.sip"
#include <qnamespace.h>
#line 83 "/build/pyqt5/src/PyQt5-5.15.7/build/QtMultimedia/sipQtMultimediaQAbstractVideoSurface.cpp"
#line 26 "/build/pyqt5/src/PyQt5-5.15.7/sip/QtCore/qthread.sip"
#include <qthread.h>
#line 86 "/build/pyqt5/src/PyQt5-5.15.7/build/QtMultimedia/sipQtMultimediaQAbstractVideoSurface.cpp"
#line 26 "/build/pyqt5/src/PyQt5-5.15.7/sip/QtCore/qnamespace.sip"
#include <qnamespace.h>
#line 89 "/build/pyqt5/src/PyQt5-5.15.7/build/QtMultimedia/sipQtMultimediaQAbstractVideoSurface.cpp"
#line 26 "/build/pyqt5/src/PyQt5-5.15.7/sip/QtCore/qregexp.sip"
#include <qregexp.h>
#line 92 "/build/pyqt5/src/PyQt5-5.15.7/build/QtMultimedia/sipQtMultimediaQAbstractVideoSurface.cpp"
#line 26 "/build/pyqt5/src/PyQt5-5.15.7/sip/QtCore/qregularexpression.sip"
#include <qregularexpression.h>
#line 95 "/build/pyqt5/src/PyQt5-5.15.7/build/QtMultimedia/sipQtMultimediaQAbstractVideoSurface.cpp"
#line 26 "/build/pyqt5/src/PyQt5-5.15.7/sip/QtCore/qobjectdefs.sip"
#include <qobjectdefs.h>
#line 98 "/build/pyqt5/src/PyQt5-5.15.7/build/QtMultimedia/sipQtMultimediaQAbstractVideoSurface.cpp"


class sipQAbstractVideoSurface : public  ::QAbstractVideoSurface
{
public:
    sipQAbstractVideoSurface( ::QObject*);
    virtual ~sipQAbstractVideoSurface();

    int qt_metacall(QMetaObject::Call, int, void **) SIP_OVERRIDE;
    void *qt_metacast(const char *) SIP_OVERRIDE;
    const QMetaObject *metaObject() const SIP_OVERRIDE;

    /*
     * There is a protected method for every virtual method visible from
     * this class.
     */
protected:
    bool present(const  ::QVideoFrame&) SIP_OVERRIDE;
    void stop() SIP_OVERRIDE;
    bool start(const  ::QVideoSurfaceFormat&) SIP_OVERRIDE;
     ::QVideoSurfaceFormat nearestFormat(const  ::QVideoSurfaceFormat&) const SIP_OVERRIDE;
    bool isFormatSupported(const  ::QVideoSurfaceFormat&) const SIP_OVERRIDE;
     ::QList< ::QVideoFrame::PixelFormat> supportedPixelFormats( ::QAbstractVideoBuffer::HandleType) const SIP_OVERRIDE;
    bool event( ::QEvent*) SIP_OVERRIDE;
    bool eventFilter( ::QObject*, ::QEvent*) SIP_OVERRIDE;
    void timerEvent( ::QTimerEvent*) SIP_OVERRIDE;
    void childEvent( ::QChildEvent*) SIP_OVERRIDE;
    void customEvent( ::QEvent*) SIP_OVERRIDE;
    void connectNotify(const  ::QMetaMethod&) SIP_OVERRIDE;
    void disconnectNotify(const  ::QMetaMethod&) SIP_OVERRIDE;

public:
    sipSimpleWrapper *sipPySelf;

private:
    sipQAbstractVideoSurface(const sipQAbstractVideoSurface &);
    sipQAbstractVideoSurface &operator = (const sipQAbstractVideoSurface &);

    char sipPyMethods[13];
};

sipQAbstractVideoSurface::sipQAbstractVideoSurface( ::QObject*a0):  ::QAbstractVideoSurface(a0), sipPySelf(SIP_NULLPTR)
{
    memset(sipPyMethods, 0, sizeof (sipPyMethods));
}

sipQAbstractVideoSurface::~sipQAbstractVideoSurface()
{
    sipInstanceDestroyedEx(&sipPySelf);
}

const QMetaObject *sipQAbstractVideoSurface::metaObject() const
{
    if (sipGetInterpreter())
        return QObject::d_ptr->metaObject ? QObject::d_ptr->dynamicMetaObject() : sip_QtMultimedia_qt_metaobject(sipPySelf,sipType_QAbstractVideoSurface);

    return  ::QAbstractVideoSurface::metaObject();
}

int sipQAbstractVideoSurface::qt_metacall(QMetaObject::Call _c,int _id,void **_a)
{
    _id =  ::QAbstractVideoSurface::qt_metacall(_c,_id,_a);

    if (_id >= 0)
    {
        SIP_BLOCK_THREADS
        _id = sip_QtMultimedia_qt_metacall(sipPySelf,sipType_QAbstractVideoSurface,_c,_id,_a);
        SIP_UNBLOCK_THREADS
    }

    return _id;
}

void *sipQAbstractVideoSurface::qt_metacast(const char *_clname)
{
    void *sipCpp;

    return (sip_QtMultimedia_qt_metacast(sipPySelf, sipType_QAbstractVideoSurface, _clname, &sipCpp) ? sipCpp :  ::QAbstractVideoSurface::qt_metacast(_clname));
}

bool sipQAbstractVideoSurface::present(const  ::QVideoFrame& a0)
{
    sip_gilstate_t sipGILState;
    PyObject *sipMeth;

    sipMeth = sipIsPyMethod(&sipGILState, &sipPyMethods[0], &sipPySelf, sipName_QAbstractVideoSurface, sipName_present);

    if (!sipMeth)
        return 0;

    extern bool sipVH_QtMultimedia_15(sip_gilstate_t, sipVirtErrorHandlerFunc, sipSimpleWrapper *, PyObject *, const  ::QVideoFrame&);

    return sipVH_QtMultimedia_15(sipGILState, sipImportedVirtErrorHandlers_QtMultimedia_QtCore[0].iveh_handler, sipPySelf, sipMeth, a0);
}

void sipQAbstractVideoSurface::stop()
{
    sip_gilstate_t sipGILState;
    PyObject *sipMeth;

    sipMeth = sipIsPyMethod(&sipGILState, &sipPyMethods[1], &sipPySelf, SIP_NULLPTR, sipName_stop);

    if (!sipMeth)
    {
         ::QAbstractVideoSurface::stop();
        return;
    }

    extern void sipVH_QtMultimedia_2(sip_gilstate_t, sipVirtErrorHandlerFunc, sipSimpleWrapper *, PyObject *);

    sipVH_QtMultimedia_2(sipGILState, sipImportedVirtErrorHandlers_QtMultimedia_QtCore[0].iveh_handler, sipPySelf, sipMeth);
}

bool sipQAbstractVideoSurface::start(const  ::QVideoSurfaceFormat& a0)
{
    sip_gilstate_t sipGILState;
    PyObject *sipMeth;

    sipMeth = sipIsPyMethod(&sipGILState, &sipPyMethods[2], &sipPySelf, SIP_NULLPTR, sipName_start);

    if (!sipMeth)
        return  ::QAbstractVideoSurface::start(a0);

    extern bool sipVH_QtMultimedia_13(sip_gilstate_t, sipVirtErrorHandlerFunc, sipSimpleWrapper *, PyObject *, const  ::QVideoSurfaceFormat&);

    return sipVH_QtMultimedia_13(sipGILState, sipImportedVirtErrorHandlers_QtMultimedia_QtCore[0].iveh_handler, sipPySelf, sipMeth, a0);
}

 ::QVideoSurfaceFormat sipQAbstractVideoSurface::nearestFormat(const  ::QVideoSurfaceFormat& a0) const
{
    sip_gilstate_t sipGILState;
    PyObject *sipMeth;

    sipMeth = sipIsPyMethod(&sipGILState, const_cast<char *>(&sipPyMethods[3]), const_cast<sipSimpleWrapper **>(&sipPySelf), SIP_NULLPTR, sipName_nearestFormat);

    if (!sipMeth)
        return  ::QAbstractVideoSurface::nearestFormat(a0);

    extern  ::QVideoSurfaceFormat sipVH_QtMultimedia_14(sip_gilstate_t, sipVirtErrorHandlerFunc, sipSimpleWrapper *, PyObject *, const  ::QVideoSurfaceFormat&);

    return sipVH_QtMultimedia_14(sipGILState, sipImportedVirtErrorHandlers_QtMultimedia_QtCore[0].iveh_handler, sipPySelf, sipMeth, a0);
}

bool sipQAbstractVideoSurface::isFormatSupported(const  ::QVideoSurfaceFormat& a0) const
{
    sip_gilstate_t sipGILState;
    PyObject *sipMeth;

    sipMeth = sipIsPyMethod(&sipGILState, const_cast<char *>(&sipPyMethods[4]), const_cast<sipSimpleWrapper **>(&sipPySelf), SIP_NULLPTR, sipName_isFormatSupported);

    if (!sipMeth)
        return  ::QAbstractVideoSurface::isFormatSupported(a0);

    extern bool sipVH_QtMultimedia_13(sip_gilstate_t, sipVirtErrorHandlerFunc, sipSimpleWrapper *, PyObject *, const  ::QVideoSurfaceFormat&);

    return sipVH_QtMultimedia_13(sipGILState, sipImportedVirtErrorHandlers_QtMultimedia_QtCore[0].iveh_handler, sipPySelf, sipMeth, a0);
}

 ::QList< ::QVideoFrame::PixelFormat> sipQAbstractVideoSurface::supportedPixelFormats( ::QAbstractVideoBuffer::HandleType a0) const
{
    sip_gilstate_t sipGILState;
    PyObject *sipMeth;

    sipMeth = sipIsPyMethod(&sipGILState, const_cast<char *>(&sipPyMethods[5]), const_cast<sipSimpleWrapper **>(&sipPySelf), sipName_QAbstractVideoSurface, sipName_supportedPixelFormats);

    if (!sipMeth)
        return  ::QList< ::QVideoFrame::PixelFormat>();

    extern  ::QList< ::QVideoFrame::PixelFormat> sipVH_QtMultimedia_12(sip_gilstate_t, sipVirtErrorHandlerFunc, sipSimpleWrapper *, PyObject *,  ::QAbstractVideoBuffer::HandleType);

    return sipVH_QtMultimedia_12(sipGILState, sipImportedVirtErrorHandlers_QtMultimedia_QtCore[0].iveh_handler, sipPySelf, sipMeth, a0);
}

bool sipQAbstractVideoSurface::event( ::QEvent*a0)
{
    sip_gilstate_t sipGILState;
    PyObject *sipMeth;

    sipMeth = sipIsPyMethod(&sipGILState, &sipPyMethods[6], &sipPySelf, SIP_NULLPTR, sipName_event);

    if (!sipMeth)
        return  ::QAbstractVideoSurface::event(a0);

    extern bool sipVH_QtMultimedia_10(sip_gilstate_t, sipVirtErrorHandlerFunc, sipSimpleWrapper *, PyObject *,  ::QEvent*);

    return sipVH_QtMultimedia_10(sipGILState, sipImportedVirtErrorHandlers_QtMultimedia_QtCore[0].iveh_handler, sipPySelf, sipMeth, a0);
}

bool sipQAbstractVideoSurface::eventFilter( ::QObject*a0, ::QEvent*a1)
{
    sip_gilstate_t sipGILState;
    PyObject *sipMeth;

    sipMeth = sipIsPyMethod(&sipGILState, &sipPyMethods[7], &sipPySelf, SIP_NULLPTR, sipName_eventFilter);

    if (!sipMeth)
        return  ::QAbstractVideoSurface::eventFilter(a0,a1);

    extern bool sipVH_QtMultimedia_9(sip_gilstate_t, sipVirtErrorHandlerFunc, sipSimpleWrapper *, PyObject *,  ::QObject*, ::QEvent*);

    return sipVH_QtMultimedia_9(sipGILState, sipImportedVirtErrorHandlers_QtMultimedia_QtCore[0].iveh_handler, sipPySelf, sipMeth, a0, a1);
}

void sipQAbstractVideoSurface::timerEvent( ::QTimerEvent*a0)
{
    sip_gilstate_t sipGILState;
    PyObject *sipMeth;

    sipMeth = sipIsPyMethod(&sipGILState, &sipPyMethods[8], &sipPySelf, SIP_NULLPTR, sipName_timerEvent);

    if (!sipMeth)
    {
         ::QAbstractVideoSurface::timerEvent(a0);
        return;
    }

    extern void sipVH_QtMultimedia_8(sip_gilstate_t, sipVirtErrorHandlerFunc, sipSimpleWrapper *, PyObject *,  ::QTimerEvent*);

    sipVH_QtMultimedia_8(sipGILState, sipImportedVirtErrorHandlers_QtMultimedia_QtCore[0].iveh_handler, sipPySelf, sipMeth, a0);
}

void sipQAbstractVideoSurface::childEvent( ::QChildEvent*a0)
{
    sip_gilstate_t sipGILState;
    PyObject *sipMeth;

    sipMeth = sipIsPyMethod(&sipGILState, &sipPyMethods[9], &sipPySelf, SIP_NULLPTR, sipName_childEvent);

    if (!sipMeth)
    {
         ::QAbstractVideoSurface::childEvent(a0);
        return;
    }

    extern void sipVH_QtMultimedia_7(sip_gilstate_t, sipVirtErrorHandlerFunc, sipSimpleWrapper *, PyObject *,  ::QChildEvent*);

    sipVH_QtMultimedia_7(sipGILState, sipImportedVirtErrorHandlers_QtMultimedia_QtCore[0].iveh_handler, sipPySelf, sipMeth, a0);
}

void sipQAbstractVideoSurface::customEvent( ::QEvent*a0)
{
    sip_gilstate_t sipGILState;
    PyObject *sipMeth;

    sipMeth = sipIsPyMethod(&sipGILState, &sipPyMethods[10], &sipPySelf, SIP_NULLPTR, sipName_customEvent);

    if (!sipMeth)
    {
         ::QAbstractVideoSurface::customEvent(a0);
        return;
    }

    extern void sipVH_QtMultimedia_6(sip_gilstate_t, sipVirtErrorHandlerFunc, sipSimpleWrapper *, PyObject *,  ::QEvent*);

    sipVH_QtMultimedia_6(sipGILState, sipImportedVirtErrorHandlers_QtMultimedia_QtCore[0].iveh_handler, sipPySelf, sipMeth, a0);
}

void sipQAbstractVideoSurface::connectNotify(const  ::QMetaMethod& a0)
{
    sip_gilstate_t sipGILState;
    PyObject *sipMeth;

    sipMeth = sipIsPyMethod(&sipGILState, &sipPyMethods[11], &sipPySelf, SIP_NULLPTR, sipName_connectNotify);

    if (!sipMeth)
    {
         ::QAbstractVideoSurface::connectNotify(a0);
        return;
    }

    extern void sipVH_QtMultimedia_5(sip_gilstate_t, sipVirtErrorHandlerFunc, sipSimpleWrapper *, PyObject *, const  ::QMetaMethod&);

    sipVH_QtMultimedia_5(sipGILState, sipImportedVirtErrorHandlers_QtMultimedia_QtCore[0].iveh_handler, sipPySelf, sipMeth, a0);
}

void sipQAbstractVideoSurface::disconnectNotify(const  ::QMetaMethod& a0)
{
    sip_gilstate_t sipGILState;
    PyObject *sipMeth;

    sipMeth = sipIsPyMethod(&sipGILState, &sipPyMethods[12], &sipPySelf, SIP_NULLPTR, sipName_disconnectNotify);

    if (!sipMeth)
    {
         ::QAbstractVideoSurface::disconnectNotify(a0);
        return;
    }

    extern void sipVH_QtMultimedia_5(sip_gilstate_t, sipVirtErrorHandlerFunc, sipSimpleWrapper *, PyObject *, const  ::QMetaMethod&);

    sipVH_QtMultimedia_5(sipGILState, sipImportedVirtErrorHandlers_QtMultimedia_QtCore[0].iveh_handler, sipPySelf, sipMeth, a0);
}


PyDoc_STRVAR(doc_QAbstractVideoSurface_supportedPixelFormats, "supportedPixelFormats(self, type: QAbstractVideoBuffer.HandleType = QAbstractVideoBuffer.NoHandle) -> List[QVideoFrame.PixelFormat]");

extern "C" {static PyObject *meth_QAbstractVideoSurface_supportedPixelFormats(PyObject *, PyObject *, PyObject *);}
static PyObject *meth_QAbstractVideoSurface_supportedPixelFormats(PyObject *sipSelf, PyObject *sipArgs, PyObject *sipKwds)
{
    PyObject *sipParseErr = SIP_NULLPTR;
    PyObject *sipOrigSelf = sipSelf;

    {
         ::QAbstractVideoBuffer::HandleType a0 = QAbstractVideoBuffer::NoHandle;
        const  ::QAbstractVideoSurface *sipCpp;

        static const char *sipKwdList[] = {
            sipName_type,
        };

        if (sipParseKwdArgs(&sipParseErr, sipArgs, sipKwds, sipKwdList, SIP_NULLPTR, "B|E", &sipSelf, sipType_QAbstractVideoSurface, &sipCpp, sipType_QAbstractVideoBuffer_HandleType, &a0))
        {
             ::QList< ::QVideoFrame::PixelFormat>*sipRes;

            if (!sipOrigSelf)
            {
                sipAbstractMethod(sipName_QAbstractVideoSurface, sipName_supportedPixelFormats);
                return SIP_NULLPTR;
            }

            sipRes = new  ::QList< ::QVideoFrame::PixelFormat>(sipCpp->supportedPixelFormats(a0));

            return sipConvertFromNewType(sipRes,sipType_QList_0100QVideoFrame_PixelFormat,SIP_NULLPTR);
        }
    }

    sipNoMethod(sipParseErr, sipName_QAbstractVideoSurface, sipName_supportedPixelFormats, doc_QAbstractVideoSurface_supportedPixelFormats);

    return SIP_NULLPTR;
}


PyDoc_STRVAR(doc_QAbstractVideoSurface_isFormatSupported, "isFormatSupported(self, QVideoSurfaceFormat) -> bool");

extern "C" {static PyObject *meth_QAbstractVideoSurface_isFormatSupported(PyObject *, PyObject *);}
static PyObject *meth_QAbstractVideoSurface_isFormatSupported(PyObject *sipSelf, PyObject *sipArgs)
{
    PyObject *sipParseErr = SIP_NULLPTR;
    bool sipSelfWasArg = (!sipSelf || sipIsDerivedClass((sipSimpleWrapper *)sipSelf));

    {
        const  ::QVideoSurfaceFormat* a0;
        const  ::QAbstractVideoSurface *sipCpp;

        if (sipParseArgs(&sipParseErr, sipArgs, "BJ9", &sipSelf, sipType_QAbstractVideoSurface, &sipCpp, sipType_QVideoSurfaceFormat, &a0))
        {
            bool sipRes;

            sipRes = (sipSelfWasArg ? sipCpp-> ::QAbstractVideoSurface::isFormatSupported(*a0) : sipCpp->isFormatSupported(*a0));

            return PyBool_FromLong(sipRes);
        }
    }

    sipNoMethod(sipParseErr, sipName_QAbstractVideoSurface, sipName_isFormatSupported, doc_QAbstractVideoSurface_isFormatSupported);

    return SIP_NULLPTR;
}


PyDoc_STRVAR(doc_QAbstractVideoSurface_nearestFormat, "nearestFormat(self, QVideoSurfaceFormat) -> QVideoSurfaceFormat");

extern "C" {static PyObject *meth_QAbstractVideoSurface_nearestFormat(PyObject *, PyObject *);}
static PyObject *meth_QAbstractVideoSurface_nearestFormat(PyObject *sipSelf, PyObject *sipArgs)
{
    PyObject *sipParseErr = SIP_NULLPTR;
    bool sipSelfWasArg = (!sipSelf || sipIsDerivedClass((sipSimpleWrapper *)sipSelf));

    {
        const  ::QVideoSurfaceFormat* a0;
        const  ::QAbstractVideoSurface *sipCpp;

        if (sipParseArgs(&sipParseErr, sipArgs, "BJ9", &sipSelf, sipType_QAbstractVideoSurface, &sipCpp, sipType_QVideoSurfaceFormat, &a0))
        {
             ::QVideoSurfaceFormat*sipRes;

            sipRes = new  ::QVideoSurfaceFormat((sipSelfWasArg ? sipCpp-> ::QAbstractVideoSurface::nearestFormat(*a0) : sipCpp->nearestFormat(*a0)));

            return sipConvertFromNewType(sipRes,sipType_QVideoSurfaceFormat,SIP_NULLPTR);
        }
    }

    sipNoMethod(sipParseErr, sipName_QAbstractVideoSurface, sipName_nearestFormat, doc_QAbstractVideoSurface_nearestFormat);

    return SIP_NULLPTR;
}


PyDoc_STRVAR(doc_QAbstractVideoSurface_surfaceFormat, "surfaceFormat(self) -> QVideoSurfaceFormat");

extern "C" {static PyObject *meth_QAbstractVideoSurface_surfaceFormat(PyObject *, PyObject *);}
static PyObject *meth_QAbstractVideoSurface_surfaceFormat(PyObject *sipSelf, PyObject *sipArgs)
{
    PyObject *sipParseErr = SIP_NULLPTR;

    {
        const  ::QAbstractVideoSurface *sipCpp;

        if (sipParseArgs(&sipParseErr, sipArgs, "B", &sipSelf, sipType_QAbstractVideoSurface, &sipCpp))
        {
             ::QVideoSurfaceFormat*sipRes;

            sipRes = new  ::QVideoSurfaceFormat(sipCpp->surfaceFormat());

            return sipConvertFromNewType(sipRes,sipType_QVideoSurfaceFormat,SIP_NULLPTR);
        }
    }

    sipNoMethod(sipParseErr, sipName_QAbstractVideoSurface, sipName_surfaceFormat, doc_QAbstractVideoSurface_surfaceFormat);

    return SIP_NULLPTR;
}


PyDoc_STRVAR(doc_QAbstractVideoSurface_start, "start(self, QVideoSurfaceFormat) -> bool");

extern "C" {static PyObject *meth_QAbstractVideoSurface_start(PyObject *, PyObject *);}
static PyObject *meth_QAbstractVideoSurface_start(PyObject *sipSelf, PyObject *sipArgs)
{
    PyObject *sipParseErr = SIP_NULLPTR;
    bool sipSelfWasArg = (!sipSelf || sipIsDerivedClass((sipSimpleWrapper *)sipSelf));

    {
        const  ::QVideoSurfaceFormat* a0;
         ::QAbstractVideoSurface *sipCpp;

        if (sipParseArgs(&sipParseErr, sipArgs, "BJ9", &sipSelf, sipType_QAbstractVideoSurface, &sipCpp, sipType_QVideoSurfaceFormat, &a0))
        {
            bool sipRes;

            sipRes = (sipSelfWasArg ? sipCpp-> ::QAbstractVideoSurface::start(*a0) : sipCpp->start(*a0));

            return PyBool_FromLong(sipRes);
        }
    }

    sipNoMethod(sipParseErr, sipName_QAbstractVideoSurface, sipName_start, doc_QAbstractVideoSurface_start);

    return SIP_NULLPTR;
}


PyDoc_STRVAR(doc_QAbstractVideoSurface_stop, "stop(self)");

extern "C" {static PyObject *meth_QAbstractVideoSurface_stop(PyObject *, PyObject *);}
static PyObject *meth_QAbstractVideoSurface_stop(PyObject *sipSelf, PyObject *sipArgs)
{
    PyObject *sipParseErr = SIP_NULLPTR;
    bool sipSelfWasArg = (!sipSelf || sipIsDerivedClass((sipSimpleWrapper *)sipSelf));

    {
         ::QAbstractVideoSurface *sipCpp;

        if (sipParseArgs(&sipParseErr, sipArgs, "B", &sipSelf, sipType_QAbstractVideoSurface, &sipCpp))
        {
            (sipSelfWasArg ? sipCpp-> ::QAbstractVideoSurface::stop() : sipCpp->stop());

            Py_INCREF(Py_None);
            return Py_None;
        }
    }

    sipNoMethod(sipParseErr, sipName_QAbstractVideoSurface, sipName_stop, doc_QAbstractVideoSurface_stop);

    return SIP_NULLPTR;
}


PyDoc_STRVAR(doc_QAbstractVideoSurface_isActive, "isActive(self) -> bool");

extern "C" {static PyObject *meth_QAbstractVideoSurface_isActive(PyObject *, PyObject *);}
static PyObject *meth_QAbstractVideoSurface_isActive(PyObject *sipSelf, PyObject *sipArgs)
{
    PyObject *sipParseErr = SIP_NULLPTR;

    {
        const  ::QAbstractVideoSurface *sipCpp;

        if (sipParseArgs(&sipParseErr, sipArgs, "B", &sipSelf, sipType_QAbstractVideoSurface, &sipCpp))
        {
            bool sipRes;

            sipRes = sipCpp->isActive();

            return PyBool_FromLong(sipRes);
        }
    }

    sipNoMethod(sipParseErr, sipName_QAbstractVideoSurface, sipName_isActive, doc_QAbstractVideoSurface_isActive);

    return SIP_NULLPTR;
}


PyDoc_STRVAR(doc_QAbstractVideoSurface_present, "present(self, QVideoFrame) -> bool");

extern "C" {static PyObject *meth_QAbstractVideoSurface_present(PyObject *, PyObject *);}
static PyObject *meth_QAbstractVideoSurface_present(PyObject *sipSelf, PyObject *sipArgs)
{
    PyObject *sipParseErr = SIP_NULLPTR;
    PyObject *sipOrigSelf = sipSelf;

    {
        const  ::QVideoFrame* a0;
         ::QAbstractVideoSurface *sipCpp;

        if (sipParseArgs(&sipParseErr, sipArgs, "BJ9", &sipSelf, sipType_QAbstractVideoSurface, &sipCpp, sipType_QVideoFrame, &a0))
        {
            bool sipRes;

            if (!sipOrigSelf)
            {
                sipAbstractMethod(sipName_QAbstractVideoSurface, sipName_present);
                return SIP_NULLPTR;
            }

            sipRes = sipCpp->present(*a0);

            return PyBool_FromLong(sipRes);
        }
    }

    sipNoMethod(sipParseErr, sipName_QAbstractVideoSurface, sipName_present, doc_QAbstractVideoSurface_present);

    return SIP_NULLPTR;
}


PyDoc_STRVAR(doc_QAbstractVideoSurface_error, "error(self) -> QAbstractVideoSurface.Error");

extern "C" {static PyObject *meth_QAbstractVideoSurface_error(PyObject *, PyObject *);}
static PyObject *meth_QAbstractVideoSurface_error(PyObject *sipSelf, PyObject *sipArgs)
{
    PyObject *sipParseErr = SIP_NULLPTR;

    {
        const  ::QAbstractVideoSurface *sipCpp;

        if (sipParseArgs(&sipParseErr, sipArgs, "B", &sipSelf, sipType_QAbstractVideoSurface, &sipCpp))
        {
             ::QAbstractVideoSurface::Error sipRes;

            sipRes = sipCpp->error();

            return sipConvertFromEnum(static_cast<int>(sipRes), sipType_QAbstractVideoSurface_Error);
        }
    }

    sipNoMethod(sipParseErr, sipName_QAbstractVideoSurface, sipName_error, doc_QAbstractVideoSurface_error);

    return SIP_NULLPTR;
}


PyDoc_STRVAR(doc_QAbstractVideoSurface_setError, "setError(self, QAbstractVideoSurface.Error)");

extern "C" {static PyObject *meth_QAbstractVideoSurface_setError(PyObject *, PyObject *);}
static PyObject *meth_QAbstractVideoSurface_setError(PyObject *sipSelf, PyObject *sipArgs)
{
    PyObject *sipParseErr = SIP_NULLPTR;

    {
         ::QAbstractVideoSurface::Error a0;
         ::QAbstractVideoSurface *sipCpp;

        if (sipParseArgs(&sipParseErr, sipArgs, "pE", &sipSelf, sipType_QAbstractVideoSurface, &sipCpp, sipType_QAbstractVideoSurface_Error, &a0))
        {
            sipCpp->setError(a0);

            Py_INCREF(Py_None);
            return Py_None;
        }
    }

    sipNoMethod(sipParseErr, sipName_QAbstractVideoSurface, sipName_setError, doc_QAbstractVideoSurface_setError);

    return SIP_NULLPTR;
}


PyDoc_STRVAR(doc_QAbstractVideoSurface_nativeResolution, "nativeResolution(self) -> QSize");

extern "C" {static PyObject *meth_QAbstractVideoSurface_nativeResolution(PyObject *, PyObject *);}
static PyObject *meth_QAbstractVideoSurface_nativeResolution(PyObject *sipSelf, PyObject *sipArgs)
{
    PyObject *sipParseErr = SIP_NULLPTR;

    {
        const  ::QAbstractVideoSurface *sipCpp;

        if (sipParseArgs(&sipParseErr, sipArgs, "B", &sipSelf, sipType_QAbstractVideoSurface, &sipCpp))
        {
             ::QSize*sipRes;

            sipRes = new  ::QSize(sipCpp->nativeResolution());

            return sipConvertFromNewType(sipRes,sipType_QSize,SIP_NULLPTR);
        }
    }

    sipNoMethod(sipParseErr, sipName_QAbstractVideoSurface, sipName_nativeResolution, doc_QAbstractVideoSurface_nativeResolution);

    return SIP_NULLPTR;
}


PyDoc_STRVAR(doc_QAbstractVideoSurface_setNativeResolution, "setNativeResolution(self, QSize)");

extern "C" {static PyObject *meth_QAbstractVideoSurface_setNativeResolution(PyObject *, PyObject *);}
static PyObject *meth_QAbstractVideoSurface_setNativeResolution(PyObject *sipSelf, PyObject *sipArgs)
{
    PyObject *sipParseErr = SIP_NULLPTR;

    {
        const  ::QSize* a0;
         ::QAbstractVideoSurface *sipCpp;

        if (sipParseArgs(&sipParseErr, sipArgs, "pJ9", &sipSelf, sipType_QAbstractVideoSurface, &sipCpp, sipType_QSize, &a0))
        {
            sipCpp->setNativeResolution(*a0);

            Py_INCREF(Py_None);
            return Py_None;
        }
    }

    sipNoMethod(sipParseErr, sipName_QAbstractVideoSurface, sipName_setNativeResolution, doc_QAbstractVideoSurface_setNativeResolution);

    return SIP_NULLPTR;
}


/* Cast a pointer to a type somewhere in its inheritance hierarchy. */
extern "C" {static void *cast_QAbstractVideoSurface(void *, const sipTypeDef *);}
static void *cast_QAbstractVideoSurface(void *sipCppV, const sipTypeDef *targetType)
{
     ::QAbstractVideoSurface *sipCpp = reinterpret_cast< ::QAbstractVideoSurface *>(sipCppV);

    if (targetType == sipType_QAbstractVideoSurface)
        return sipCppV;

    if (targetType == sipType_QObject)
        return static_cast< ::QObject *>(sipCpp);

    return SIP_NULLPTR;
}


/* Call the instance's destructor. */
extern "C" {static void release_QAbstractVideoSurface(void *, int);}
static void release_QAbstractVideoSurface(void *sipCppV, int)
{
     ::QAbstractVideoSurface *sipCpp = reinterpret_cast< ::QAbstractVideoSurface *>(sipCppV);

    if (QThread::currentThread() == sipCpp->thread())
        delete sipCpp;
    else
        sipCpp->deleteLater();
}


extern "C" {static void dealloc_QAbstractVideoSurface(sipSimpleWrapper *);}
static void dealloc_QAbstractVideoSurface(sipSimpleWrapper *sipSelf)
{
    if (sipIsDerivedClass(sipSelf))
        reinterpret_cast<sipQAbstractVideoSurface *>(sipGetAddress(sipSelf))->sipPySelf = SIP_NULLPTR;

    if (sipIsOwnedByPython(sipSelf))
    {
        release_QAbstractVideoSurface(sipGetAddress(sipSelf), sipIsDerivedClass(sipSelf));
    }
}


extern "C" {static void *init_type_QAbstractVideoSurface(sipSimpleWrapper *, PyObject *, PyObject *, PyObject **, PyObject **, PyObject **);}
static void *init_type_QAbstractVideoSurface(sipSimpleWrapper *sipSelf, PyObject *sipArgs, PyObject *sipKwds, PyObject **sipUnused, PyObject **sipOwner, PyObject **sipParseErr)
{
    sipQAbstractVideoSurface *sipCpp = SIP_NULLPTR;

    {
         ::QObject* a0 = 0;

        static const char *sipKwdList[] = {
            sipName_parent,
        };

        if (sipParseKwdArgs(sipParseErr, sipArgs, sipKwds, sipKwdList, sipUnused, "|JH", sipType_QObject, &a0, sipOwner))
        {
            sipCpp = new sipQAbstractVideoSurface(a0);

            sipCpp->sipPySelf = sipSelf;

            return sipCpp;
        }
    }

    return SIP_NULLPTR;
}


/* Define this type's super-types. */
static sipEncodedTypeDef supers_QAbstractVideoSurface[] = {{9, 0, 1}};


static PyMethodDef methods_QAbstractVideoSurface[] = {
    {sipName_error, meth_QAbstractVideoSurface_error, METH_VARARGS, doc_QAbstractVideoSurface_error},
    {sipName_isActive, meth_QAbstractVideoSurface_isActive, METH_VARARGS, doc_QAbstractVideoSurface_isActive},
    {sipName_isFormatSupported, meth_QAbstractVideoSurface_isFormatSupported, METH_VARARGS, doc_QAbstractVideoSurface_isFormatSupported},
    {sipName_nativeResolution, meth_QAbstractVideoSurface_nativeResolution, METH_VARARGS, doc_QAbstractVideoSurface_nativeResolution},
    {sipName_nearestFormat, meth_QAbstractVideoSurface_nearestFormat, METH_VARARGS, doc_QAbstractVideoSurface_nearestFormat},
    {sipName_present, meth_QAbstractVideoSurface_present, METH_VARARGS, doc_QAbstractVideoSurface_present},
    {sipName_setError, meth_QAbstractVideoSurface_setError, METH_VARARGS, doc_QAbstractVideoSurface_setError},
    {sipName_setNativeResolution, meth_QAbstractVideoSurface_setNativeResolution, METH_VARARGS, doc_QAbstractVideoSurface_setNativeResolution},
    {sipName_start, meth_QAbstractVideoSurface_start, METH_VARARGS, doc_QAbstractVideoSurface_start},
    {sipName_stop, meth_QAbstractVideoSurface_stop, METH_VARARGS, doc_QAbstractVideoSurface_stop},
    {sipName_supportedPixelFormats, SIP_MLMETH_CAST(meth_QAbstractVideoSurface_supportedPixelFormats), METH_VARARGS|METH_KEYWORDS, doc_QAbstractVideoSurface_supportedPixelFormats},
    {sipName_surfaceFormat, meth_QAbstractVideoSurface_surfaceFormat, METH_VARARGS, doc_QAbstractVideoSurface_surfaceFormat}
};

static sipEnumMemberDef enummembers_QAbstractVideoSurface[] = {
    {sipName_IncorrectFormatError, static_cast<int>( ::QAbstractVideoSurface::IncorrectFormatError), 5},
    {sipName_NoError, static_cast<int>( ::QAbstractVideoSurface::NoError), 5},
    {sipName_ResourceError, static_cast<int>( ::QAbstractVideoSurface::ResourceError), 5},
    {sipName_StoppedError, static_cast<int>( ::QAbstractVideoSurface::StoppedError), 5},
    {sipName_UnsupportedFormatError, static_cast<int>( ::QAbstractVideoSurface::UnsupportedFormatError), 5},
};

PyDoc_STRVAR(doc_QAbstractVideoSurface, "\1QAbstractVideoSurface(parent: QObject = None)");


/* Define this type's signals. */
static const pyqt5QtSignal signals_QAbstractVideoSurface[] = {
    {"nativeResolutionChanged(QSize)", "\1nativeResolutionChanged(self, QSize)", SIP_NULLPTR, SIP_NULLPTR},
    {"supportedFormatsChanged()", "\1supportedFormatsChanged(self)", SIP_NULLPTR, SIP_NULLPTR},
    {"surfaceFormatChanged(QVideoSurfaceFormat)", "\1surfaceFormatChanged(self, QVideoSurfaceFormat)", SIP_NULLPTR, SIP_NULLPTR},
    {"activeChanged(bool)", "\1activeChanged(self, bool)", SIP_NULLPTR, SIP_NULLPTR},
    {SIP_NULLPTR, SIP_NULLPTR, SIP_NULLPTR, SIP_NULLPTR}
};


static pyqt5ClassPluginDef plugin_QAbstractVideoSurface = {
    & ::QAbstractVideoSurface::staticMetaObject,
    0,
    signals_QAbstractVideoSurface,
    SIP_NULLPTR
};


sipClassTypeDef sipTypeDef_QtMultimedia_QAbstractVideoSurface = {
    {
        -1,
        SIP_NULLPTR,
        SIP_NULLPTR,
        SIP_TYPE_ABSTRACT|SIP_TYPE_SCC|SIP_TYPE_SUPER_INIT|SIP_TYPE_LIMITED_API|SIP_TYPE_CLASS,
        sipNameNr_QAbstractVideoSurface,
        SIP_NULLPTR,
        &plugin_QAbstractVideoSurface
    },
    {
        sipNameNr_QAbstractVideoSurface,
        {0, 0, 1},
        12, methods_QAbstractVideoSurface,
        5, enummembers_QAbstractVideoSurface,
        0, SIP_NULLPTR,
        {SIP_NULLPTR, SIP_NULLPTR, SIP_NULLPTR, SIP_NULLPTR, SIP_NULLPTR, SIP_NULLPTR, SIP_NULLPTR, SIP_NULLPTR, SIP_NULLPTR, SIP_NULLPTR},
    },
    doc_QAbstractVideoSurface,
    -1,
    -1,
    supers_QAbstractVideoSurface,
    SIP_NULLPTR,
    init_type_QAbstractVideoSurface,
    SIP_NULLPTR,
    SIP_NULLPTR,
    SIP_NULLPTR,
    SIP_NULLPTR,
    dealloc_QAbstractVideoSurface,
    SIP_NULLPTR,
    SIP_NULLPTR,
    SIP_NULLPTR,
    release_QAbstractVideoSurface,
    cast_QAbstractVideoSurface,
    SIP_NULLPTR,
    SIP_NULLPTR,
    SIP_NULLPTR,
    SIP_NULLPTR,
    SIP_NULLPTR,
    SIP_NULLPTR,
    SIP_NULLPTR,
    sizeof ( ::QAbstractVideoSurface),
};
