/*
 * 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 "sipAPIQtGui.h"

#line 28 "/build/pyqt5/src/PyQt5-5.15.7/sip/QtGui/qopenglshaderprogram.sip"
#include <qopenglshaderprogram.h>
#line 29 "/build/pyqt5/src/PyQt5-5.15.7/build/QtGui/sipQtGuiQOpenGLShader.cpp"

#line 28 "/build/pyqt5/src/PyQt5-5.15.7/sip/QtGui/qopenglshaderprogram.sip"
#include <qopenglshaderprogram.h>
#line 33 "/build/pyqt5/src/PyQt5-5.15.7/build/QtGui/sipQtGuiQOpenGLShader.cpp"
#line 28 "/build/pyqt5/src/PyQt5-5.15.7/sip/QtCore/qobject.sip"
#include <qobject.h>
#line 36 "/build/pyqt5/src/PyQt5-5.15.7/build/QtGui/sipQtGuiQOpenGLShader.cpp"
#line 46 "/build/pyqt5/src/PyQt5-5.15.7/sip/QtGui/qopenglcontext.sip"
#include <qopenglcontext.h>
#line 39 "/build/pyqt5/src/PyQt5-5.15.7/build/QtGui/sipQtGuiQOpenGLShader.cpp"
#line 27 "/build/pyqt5/src/PyQt5-5.15.7/sip/QtCore/qstring.sip"
#include <qstring.h>
#line 42 "/build/pyqt5/src/PyQt5-5.15.7/build/QtGui/sipQtGuiQOpenGLShader.cpp"
#line 30 "/build/pyqt5/src/PyQt5-5.15.7/sip/QtCore/qbytearray.sip"
#include <qbytearray.h>
#line 45 "/build/pyqt5/src/PyQt5-5.15.7/build/QtGui/sipQtGuiQOpenGLShader.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 50 "/build/pyqt5/src/PyQt5-5.15.7/build/QtGui/sipQtGuiQOpenGLShader.cpp"
#line 26 "/build/pyqt5/src/PyQt5-5.15.7/sip/QtCore/qmetaobject.sip"
#include <qmetaobject.h>
#line 53 "/build/pyqt5/src/PyQt5-5.15.7/build/QtGui/sipQtGuiQOpenGLShader.cpp"
#line 26 "/build/pyqt5/src/PyQt5-5.15.7/sip/QtCore/qcoreevent.sip"
#include <qcoreevent.h>
#line 56 "/build/pyqt5/src/PyQt5-5.15.7/build/QtGui/sipQtGuiQOpenGLShader.cpp"
#line 247 "/build/pyqt5/src/PyQt5-5.15.7/sip/QtCore/qcoreevent.sip"
#include <qcoreevent.h>
#line 59 "/build/pyqt5/src/PyQt5-5.15.7/build/QtGui/sipQtGuiQOpenGLShader.cpp"
#line 235 "/build/pyqt5/src/PyQt5-5.15.7/sip/QtCore/qcoreevent.sip"
#include <qcoreevent.h>
#line 62 "/build/pyqt5/src/PyQt5-5.15.7/build/QtGui/sipQtGuiQOpenGLShader.cpp"
#line 26 "/build/pyqt5/src/PyQt5-5.15.7/sip/QtCore/qvariant.sip"
#include <qvariant.h>
#line 65 "/build/pyqt5/src/PyQt5-5.15.7/build/QtGui/sipQtGuiQOpenGLShader.cpp"
#line 38 "/build/pyqt5/src/PyQt5-5.15.7/sip/QtCore/qpycore_qlist.sip"
#include <qlist.h>
#line 68 "/build/pyqt5/src/PyQt5-5.15.7/build/QtGui/sipQtGuiQOpenGLShader.cpp"
#line 149 "/build/pyqt5/src/PyQt5-5.15.7/sip/QtCore/qpycore_qlist.sip"
#include <qlist.h>
#line 71 "/build/pyqt5/src/PyQt5-5.15.7/build/QtGui/sipQtGuiQOpenGLShader.cpp"
#line 26 "/build/pyqt5/src/PyQt5-5.15.7/sip/QtCore/qnamespace.sip"
#include <qnamespace.h>
#line 74 "/build/pyqt5/src/PyQt5-5.15.7/build/QtGui/sipQtGuiQOpenGLShader.cpp"
#line 26 "/build/pyqt5/src/PyQt5-5.15.7/sip/QtCore/qthread.sip"
#include <qthread.h>
#line 77 "/build/pyqt5/src/PyQt5-5.15.7/build/QtGui/sipQtGuiQOpenGLShader.cpp"
#line 26 "/build/pyqt5/src/PyQt5-5.15.7/sip/QtCore/qnamespace.sip"
#include <qnamespace.h>
#line 80 "/build/pyqt5/src/PyQt5-5.15.7/build/QtGui/sipQtGuiQOpenGLShader.cpp"
#line 26 "/build/pyqt5/src/PyQt5-5.15.7/sip/QtCore/qregexp.sip"
#include <qregexp.h>
#line 83 "/build/pyqt5/src/PyQt5-5.15.7/build/QtGui/sipQtGuiQOpenGLShader.cpp"
#line 26 "/build/pyqt5/src/PyQt5-5.15.7/sip/QtCore/qregularexpression.sip"
#include <qregularexpression.h>
#line 86 "/build/pyqt5/src/PyQt5-5.15.7/build/QtGui/sipQtGuiQOpenGLShader.cpp"
#line 26 "/build/pyqt5/src/PyQt5-5.15.7/sip/QtCore/qobjectdefs.sip"
#include <qobjectdefs.h>
#line 89 "/build/pyqt5/src/PyQt5-5.15.7/build/QtGui/sipQtGuiQOpenGLShader.cpp"


class sipQOpenGLShader : public  ::QOpenGLShader
{
public:
    sipQOpenGLShader( ::QOpenGLShader::ShaderType, ::QObject*);
    virtual ~sipQOpenGLShader();

    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 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:
    sipQOpenGLShader(const sipQOpenGLShader &);
    sipQOpenGLShader &operator = (const sipQOpenGLShader &);

    char sipPyMethods[7];
};

sipQOpenGLShader::sipQOpenGLShader( ::QOpenGLShader::ShaderType a0, ::QObject*a1):  ::QOpenGLShader(a0,a1), sipPySelf(SIP_NULLPTR)
{
    memset(sipPyMethods, 0, sizeof (sipPyMethods));
}

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

const QMetaObject *sipQOpenGLShader::metaObject() const
{
    if (sipGetInterpreter())
        return QObject::d_ptr->metaObject ? QObject::d_ptr->dynamicMetaObject() : sip_QtGui_qt_metaobject(sipPySelf,sipType_QOpenGLShader);

    return  ::QOpenGLShader::metaObject();
}

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

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

    return _id;
}

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

    return (sip_QtGui_qt_metacast(sipPySelf, sipType_QOpenGLShader, _clname, &sipCpp) ? sipCpp :  ::QOpenGLShader::qt_metacast(_clname));
}

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

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

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

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

    return sipVH_QtGui_5(sipGILState, sipImportedVirtErrorHandlers_QtGui_QtCore[0].iveh_handler, sipPySelf, sipMeth, a0);
}

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

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

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

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

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

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

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

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

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

    sipVH_QtGui_3(sipGILState, sipImportedVirtErrorHandlers_QtGui_QtCore[0].iveh_handler, sipPySelf, sipMeth, a0);
}

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

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

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

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

    sipVH_QtGui_2(sipGILState, sipImportedVirtErrorHandlers_QtGui_QtCore[0].iveh_handler, sipPySelf, sipMeth, a0);
}

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

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

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

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

    sipVH_QtGui_1(sipGILState, sipImportedVirtErrorHandlers_QtGui_QtCore[0].iveh_handler, sipPySelf, sipMeth, a0);
}

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

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

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

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

    sipVH_QtGui_0(sipGILState, sipImportedVirtErrorHandlers_QtGui_QtCore[0].iveh_handler, sipPySelf, sipMeth, a0);
}

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

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

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

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

    sipVH_QtGui_0(sipGILState, sipImportedVirtErrorHandlers_QtGui_QtCore[0].iveh_handler, sipPySelf, sipMeth, a0);
}


PyDoc_STRVAR(doc_QOpenGLShader_shaderType, "shaderType(self) -> QOpenGLShader.ShaderType");

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

    {
        const  ::QOpenGLShader *sipCpp;

        if (sipParseArgs(&sipParseErr, sipArgs, "B", &sipSelf, sipType_QOpenGLShader, &sipCpp))
        {
             ::QOpenGLShader::ShaderType*sipRes;

            sipRes = new  ::QOpenGLShader::ShaderType(sipCpp->shaderType());

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

    sipNoMethod(sipParseErr, sipName_QOpenGLShader, sipName_shaderType, doc_QOpenGLShader_shaderType);

    return SIP_NULLPTR;
}


PyDoc_STRVAR(doc_QOpenGLShader_compileSourceCode, "compileSourceCode(self, Union[QByteArray, bytes, bytearray]) -> bool\n"
"compileSourceCode(self, str) -> bool");

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

    {
        const  ::QByteArray* a0;
        int a0State = 0;
         ::QOpenGLShader *sipCpp;

        if (sipParseArgs(&sipParseErr, sipArgs, "BJ1", &sipSelf, sipType_QOpenGLShader, &sipCpp, sipType_QByteArray, &a0, &a0State))
        {
            bool sipRes;

            sipRes = sipCpp->compileSourceCode(*a0);
            sipReleaseType(const_cast< ::QByteArray *>(a0), sipType_QByteArray, a0State);

            return PyBool_FromLong(sipRes);
        }
    }

    {
        const  ::QString* a0;
        int a0State = 0;
         ::QOpenGLShader *sipCpp;

        if (sipParseArgs(&sipParseErr, sipArgs, "BJ1", &sipSelf, sipType_QOpenGLShader, &sipCpp, sipType_QString, &a0, &a0State))
        {
            bool sipRes;

            sipRes = sipCpp->compileSourceCode(*a0);
            sipReleaseType(const_cast< ::QString *>(a0), sipType_QString, a0State);

            return PyBool_FromLong(sipRes);
        }
    }

    sipNoMethod(sipParseErr, sipName_QOpenGLShader, sipName_compileSourceCode, doc_QOpenGLShader_compileSourceCode);

    return SIP_NULLPTR;
}


PyDoc_STRVAR(doc_QOpenGLShader_compileSourceFile, "compileSourceFile(self, str) -> bool");

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

    {
        const  ::QString* a0;
        int a0State = 0;
         ::QOpenGLShader *sipCpp;

        if (sipParseArgs(&sipParseErr, sipArgs, "BJ1", &sipSelf, sipType_QOpenGLShader, &sipCpp, sipType_QString, &a0, &a0State))
        {
            bool sipRes;

            sipRes = sipCpp->compileSourceFile(*a0);
            sipReleaseType(const_cast< ::QString *>(a0), sipType_QString, a0State);

            return PyBool_FromLong(sipRes);
        }
    }

    sipNoMethod(sipParseErr, sipName_QOpenGLShader, sipName_compileSourceFile, doc_QOpenGLShader_compileSourceFile);

    return SIP_NULLPTR;
}


PyDoc_STRVAR(doc_QOpenGLShader_sourceCode, "sourceCode(self) -> QByteArray");

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

    {
        const  ::QOpenGLShader *sipCpp;

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

            sipRes = new  ::QByteArray(sipCpp->sourceCode());

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

    sipNoMethod(sipParseErr, sipName_QOpenGLShader, sipName_sourceCode, doc_QOpenGLShader_sourceCode);

    return SIP_NULLPTR;
}


PyDoc_STRVAR(doc_QOpenGLShader_isCompiled, "isCompiled(self) -> bool");

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

    {
        const  ::QOpenGLShader *sipCpp;

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

            sipRes = sipCpp->isCompiled();

            return PyBool_FromLong(sipRes);
        }
    }

    sipNoMethod(sipParseErr, sipName_QOpenGLShader, sipName_isCompiled, doc_QOpenGLShader_isCompiled);

    return SIP_NULLPTR;
}


PyDoc_STRVAR(doc_QOpenGLShader_log, "log(self) -> str");

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

    {
        const  ::QOpenGLShader *sipCpp;

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

            sipRes = new  ::QString(sipCpp->log());

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

    sipNoMethod(sipParseErr, sipName_QOpenGLShader, sipName_log, doc_QOpenGLShader_log);

    return SIP_NULLPTR;
}


PyDoc_STRVAR(doc_QOpenGLShader_shaderId, "shaderId(self) -> int");

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

    {
        const  ::QOpenGLShader *sipCpp;

        if (sipParseArgs(&sipParseErr, sipArgs, "B", &sipSelf, sipType_QOpenGLShader, &sipCpp))
        {
             ::GLuint sipRes;

            sipRes = sipCpp->shaderId();

            return PyLong_FromUnsignedLong(sipRes);
        }
    }

    sipNoMethod(sipParseErr, sipName_QOpenGLShader, sipName_shaderId, doc_QOpenGLShader_shaderId);

    return SIP_NULLPTR;
}


PyDoc_STRVAR(doc_QOpenGLShader_hasOpenGLShaders, "hasOpenGLShaders(Union[QOpenGLShader.ShaderType, QOpenGLShader.ShaderTypeBit], context: QOpenGLContext = None) -> bool");

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

    {
         ::QOpenGLShader::ShaderType* a0;
        int a0State = 0;
         ::QOpenGLContext* a1 = 0;

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

        if (sipParseKwdArgs(&sipParseErr, sipArgs, sipKwds, sipKwdList, SIP_NULLPTR, "J1|J8", sipType_QOpenGLShader_ShaderType, &a0, &a0State, sipType_QOpenGLContext, &a1))
        {
            bool sipRes;

            sipRes =  ::QOpenGLShader::hasOpenGLShaders(*a0,a1);
            sipReleaseType(a0, sipType_QOpenGLShader_ShaderType, a0State);

            return PyBool_FromLong(sipRes);
        }
    }

    sipNoMethod(sipParseErr, sipName_QOpenGLShader, sipName_hasOpenGLShaders, doc_QOpenGLShader_hasOpenGLShaders);

    return SIP_NULLPTR;
}


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

    if (targetType == sipType_QOpenGLShader)
        return sipCppV;

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

    return SIP_NULLPTR;
}


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

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


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

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


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

    {
         ::QOpenGLShader::ShaderType* a0;
        int a0State = 0;
         ::QObject* a1 = 0;

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

        if (sipParseKwdArgs(sipParseErr, sipArgs, sipKwds, sipKwdList, sipUnused, "J1|JH", sipType_QOpenGLShader_ShaderType, &a0, &a0State, sipType_QObject, &a1, sipOwner))
        {
            sipCpp = new sipQOpenGLShader(*a0,a1);
            sipReleaseType(a0, sipType_QOpenGLShader_ShaderType, a0State);

            sipCpp->sipPySelf = sipSelf;

            return sipCpp;
        }
    }

    return SIP_NULLPTR;
}


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


static PyMethodDef methods_QOpenGLShader[] = {
    {sipName_compileSourceCode, meth_QOpenGLShader_compileSourceCode, METH_VARARGS, doc_QOpenGLShader_compileSourceCode},
    {sipName_compileSourceFile, meth_QOpenGLShader_compileSourceFile, METH_VARARGS, doc_QOpenGLShader_compileSourceFile},
    {sipName_hasOpenGLShaders, SIP_MLMETH_CAST(meth_QOpenGLShader_hasOpenGLShaders), METH_VARARGS|METH_KEYWORDS, doc_QOpenGLShader_hasOpenGLShaders},
    {sipName_isCompiled, meth_QOpenGLShader_isCompiled, METH_VARARGS, doc_QOpenGLShader_isCompiled},
    {sipName_log, meth_QOpenGLShader_log, METH_VARARGS, doc_QOpenGLShader_log},
    {sipName_shaderId, meth_QOpenGLShader_shaderId, METH_VARARGS, doc_QOpenGLShader_shaderId},
    {sipName_shaderType, meth_QOpenGLShader_shaderType, METH_VARARGS, doc_QOpenGLShader_shaderType},
    {sipName_sourceCode, meth_QOpenGLShader_sourceCode, METH_VARARGS, doc_QOpenGLShader_sourceCode}
};

static sipEnumMemberDef enummembers_QOpenGLShader[] = {
    {sipName_Compute, static_cast<int>( ::QOpenGLShader::Compute), 158},
    {sipName_Fragment, static_cast<int>( ::QOpenGLShader::Fragment), 158},
    {sipName_Geometry, static_cast<int>( ::QOpenGLShader::Geometry), 158},
    {sipName_TessellationControl, static_cast<int>( ::QOpenGLShader::TessellationControl), 158},
    {sipName_TessellationEvaluation, static_cast<int>( ::QOpenGLShader::TessellationEvaluation), 158},
    {sipName_Vertex, static_cast<int>( ::QOpenGLShader::Vertex), 158},
};

PyDoc_STRVAR(doc_QOpenGLShader, "\1QOpenGLShader(Union[QOpenGLShader.ShaderType, QOpenGLShader.ShaderTypeBit], parent: QObject = None)");


static pyqt5ClassPluginDef plugin_QOpenGLShader = {
    & ::QOpenGLShader::staticMetaObject,
    0,
    SIP_NULLPTR,
    SIP_NULLPTR
};


sipClassTypeDef sipTypeDef_QtGui_QOpenGLShader = {
    {
        -1,
        SIP_NULLPTR,
        SIP_NULLPTR,
        SIP_TYPE_SCC|SIP_TYPE_SUPER_INIT|SIP_TYPE_LIMITED_API|SIP_TYPE_CLASS,
        sipNameNr_QOpenGLShader,
        SIP_NULLPTR,
        &plugin_QOpenGLShader
    },
    {
        sipNameNr_QOpenGLShader,
        {0, 0, 1},
        8, methods_QOpenGLShader,
        6, enummembers_QOpenGLShader,
        0, SIP_NULLPTR,
        {SIP_NULLPTR, SIP_NULLPTR, SIP_NULLPTR, SIP_NULLPTR, SIP_NULLPTR, SIP_NULLPTR, SIP_NULLPTR, SIP_NULLPTR, SIP_NULLPTR, SIP_NULLPTR},
    },
    doc_QOpenGLShader,
    -1,
    -1,
    supers_QOpenGLShader,
    SIP_NULLPTR,
    init_type_QOpenGLShader,
    SIP_NULLPTR,
    SIP_NULLPTR,
    SIP_NULLPTR,
    SIP_NULLPTR,
    dealloc_QOpenGLShader,
    SIP_NULLPTR,
    SIP_NULLPTR,
    SIP_NULLPTR,
    release_QOpenGLShader,
    cast_QOpenGLShader,
    SIP_NULLPTR,
    SIP_NULLPTR,
    SIP_NULLPTR,
    SIP_NULLPTR,
    SIP_NULLPTR,
    SIP_NULLPTR,
    SIP_NULLPTR,
    sizeof ( ::QOpenGLShader),
};
