/*
 * Interface wrapper code.
 *
 * Generated by SIP 6.7.0
 *
 * Copyright (c) 2022 Riverbank Computing Limited <info@riverbankcomputing.com>
 * 
 * This file is part of PyQt6.
 * 
 * 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 28 "/build/pyqt6/src/PyQt6-6.4.0/sip/QtMultimedia/qcameradevice.sip"
#include <qcameradevice.h>
#line 29 "/build/pyqt6/src/PyQt6-6.4.0/build/QtMultimedia/sipQtMultimediaQCameraFormat.cpp"

#line 26 "/build/pyqt6/src/PyQt6-6.4.0/sip/QtCore/qsize.sip"
#include <qsize.h>
#line 33 "/build/pyqt6/src/PyQt6-6.4.0/build/QtMultimedia/sipQtMultimediaQCameraFormat.cpp"
#line 28 "/build/pyqt6/src/PyQt6-6.4.0/sip/QtMultimedia/qvideoframeformat.sip"
#include <qvideoframeformat.h>
#line 36 "/build/pyqt6/src/PyQt6-6.4.0/build/QtMultimedia/sipQtMultimediaQCameraFormat.cpp"


PyDoc_STRVAR(doc_QCameraFormat_pixelFormat, "pixelFormat(self) -> QVideoFrameFormat.PixelFormat");

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

    {
        const  ::QCameraFormat *sipCpp;

        if (sipParseArgs(&sipParseErr, sipArgs, "B", &sipSelf, sipType_QCameraFormat, &sipCpp))
        {
             ::QVideoFrameFormat::PixelFormat sipRes;

            sipRes = sipCpp->pixelFormat();

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

    sipNoMethod(sipParseErr, sipName_QCameraFormat, sipName_pixelFormat, doc_QCameraFormat_pixelFormat);

    return SIP_NULLPTR;
}


PyDoc_STRVAR(doc_QCameraFormat_resolution, "resolution(self) -> QSize");

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

    {
        const  ::QCameraFormat *sipCpp;

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

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

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

    sipNoMethod(sipParseErr, sipName_QCameraFormat, sipName_resolution, doc_QCameraFormat_resolution);

    return SIP_NULLPTR;
}


PyDoc_STRVAR(doc_QCameraFormat_minFrameRate, "minFrameRate(self) -> float");

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

    {
        const  ::QCameraFormat *sipCpp;

        if (sipParseArgs(&sipParseErr, sipArgs, "B", &sipSelf, sipType_QCameraFormat, &sipCpp))
        {
            float sipRes;

            sipRes = sipCpp->minFrameRate();

            return PyFloat_FromDouble((double)sipRes);
        }
    }

    sipNoMethod(sipParseErr, sipName_QCameraFormat, sipName_minFrameRate, doc_QCameraFormat_minFrameRate);

    return SIP_NULLPTR;
}


PyDoc_STRVAR(doc_QCameraFormat_maxFrameRate, "maxFrameRate(self) -> float");

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

    {
        const  ::QCameraFormat *sipCpp;

        if (sipParseArgs(&sipParseErr, sipArgs, "B", &sipSelf, sipType_QCameraFormat, &sipCpp))
        {
            float sipRes;

            sipRes = sipCpp->maxFrameRate();

            return PyFloat_FromDouble((double)sipRes);
        }
    }

    sipNoMethod(sipParseErr, sipName_QCameraFormat, sipName_maxFrameRate, doc_QCameraFormat_maxFrameRate);

    return SIP_NULLPTR;
}


PyDoc_STRVAR(doc_QCameraFormat_isNull, "isNull(self) -> bool");

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

    {
        const  ::QCameraFormat *sipCpp;

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

            sipRes = sipCpp->isNull();

            return PyBool_FromLong(sipRes);
        }
    }

    sipNoMethod(sipParseErr, sipName_QCameraFormat, sipName_isNull, doc_QCameraFormat_isNull);

    return SIP_NULLPTR;
}


extern "C" {static PyObject *slot_QCameraFormat___ne__(PyObject *,PyObject *);}
static PyObject *slot_QCameraFormat___ne__(PyObject *sipSelf,PyObject *sipArg)
{
     ::QCameraFormat *sipCpp = reinterpret_cast< ::QCameraFormat *>(sipGetCppPtr((sipSimpleWrapper *)sipSelf,sipType_QCameraFormat));

    if (!sipCpp)
        return SIP_NULLPTR;

    PyObject *sipParseErr = SIP_NULLPTR;

    {
        const  ::QCameraFormat* a0;

        if (sipParseArgs(&sipParseErr, sipArg, "1J9", sipType_QCameraFormat, &a0))
        {
            bool sipRes;

            sipRes = sipCpp-> ::QCameraFormat::operator!=(*a0);

            return PyBool_FromLong(sipRes);
        }
    }

    Py_XDECREF(sipParseErr);

    if (sipParseErr == Py_None)
        return SIP_NULLPTR;

    return sipPySlotExtend(&sipModuleAPI_QtMultimedia, ne_slot, sipType_QCameraFormat, sipSelf, sipArg);
}


extern "C" {static PyObject *slot_QCameraFormat___eq__(PyObject *,PyObject *);}
static PyObject *slot_QCameraFormat___eq__(PyObject *sipSelf,PyObject *sipArg)
{
     ::QCameraFormat *sipCpp = reinterpret_cast< ::QCameraFormat *>(sipGetCppPtr((sipSimpleWrapper *)sipSelf,sipType_QCameraFormat));

    if (!sipCpp)
        return SIP_NULLPTR;

    PyObject *sipParseErr = SIP_NULLPTR;

    {
        const  ::QCameraFormat* a0;

        if (sipParseArgs(&sipParseErr, sipArg, "1J9", sipType_QCameraFormat, &a0))
        {
            bool sipRes;

            sipRes = sipCpp-> ::QCameraFormat::operator==(*a0);

            return PyBool_FromLong(sipRes);
        }
    }

    Py_XDECREF(sipParseErr);

    if (sipParseErr == Py_None)
        return SIP_NULLPTR;

    return sipPySlotExtend(&sipModuleAPI_QtMultimedia, eq_slot, sipType_QCameraFormat, sipSelf, sipArg);
}


/* Call the instance's destructor. */
extern "C" {static void release_QCameraFormat(void *, int);}
static void release_QCameraFormat(void *sipCppV, int)
{
    delete reinterpret_cast< ::QCameraFormat *>(sipCppV);
}


extern "C" {static void *array_QCameraFormat(Py_ssize_t);}
static void *array_QCameraFormat(Py_ssize_t sipNrElem)
{
    return new  ::QCameraFormat[sipNrElem];
}


extern "C" {static void array_delete_QCameraFormat(void *);}
static void array_delete_QCameraFormat(void *sipCpp)
{
    delete[] reinterpret_cast< ::QCameraFormat *>(sipCpp);
}


extern "C" {static void assign_QCameraFormat(void *, Py_ssize_t, void *);}
static void assign_QCameraFormat(void *sipDst, Py_ssize_t sipDstIdx, void *sipSrc)
{
    reinterpret_cast< ::QCameraFormat *>(sipDst)[sipDstIdx] = *reinterpret_cast< ::QCameraFormat *>(sipSrc);
}


extern "C" {static void *copy_QCameraFormat(const void *, Py_ssize_t);}
static void *copy_QCameraFormat(const void *sipSrc, Py_ssize_t sipSrcIdx)
{
    return new  ::QCameraFormat(reinterpret_cast<const  ::QCameraFormat *>(sipSrc)[sipSrcIdx]);
}


extern "C" {static void dealloc_QCameraFormat(sipSimpleWrapper *);}
static void dealloc_QCameraFormat(sipSimpleWrapper *sipSelf)
{
    if (sipIsOwnedByPython(sipSelf))
    {
        release_QCameraFormat(sipGetAddress(sipSelf), 0);
    }
}


extern "C" {static void *init_type_QCameraFormat(sipSimpleWrapper *, PyObject *, PyObject *, PyObject **, PyObject **, PyObject **);}
static void *init_type_QCameraFormat(sipSimpleWrapper *, PyObject *sipArgs, PyObject *sipKwds, PyObject **sipUnused, PyObject **, PyObject **sipParseErr)
{
     ::QCameraFormat *sipCpp = SIP_NULLPTR;

    {
        if (sipParseKwdArgs(sipParseErr, sipArgs, sipKwds, SIP_NULLPTR, sipUnused, ""))
        {
            sipCpp = new  ::QCameraFormat();

            return sipCpp;
        }
    }

    {
        const  ::QCameraFormat* a0;

        if (sipParseKwdArgs(sipParseErr, sipArgs, sipKwds, SIP_NULLPTR, sipUnused, "J9", sipType_QCameraFormat, &a0))
        {
            sipCpp = new  ::QCameraFormat(*a0);

            return sipCpp;
        }
    }

    return SIP_NULLPTR;
}


/* Define this type's Python slots. */
static sipPySlotDef slots_QCameraFormat[] = {
    {(void *)slot_QCameraFormat___ne__, ne_slot},
    {(void *)slot_QCameraFormat___eq__, eq_slot},
    {0, (sipPySlotType)0}
};


static PyMethodDef methods_QCameraFormat[] = {
    {sipName_isNull, meth_QCameraFormat_isNull, METH_VARARGS, doc_QCameraFormat_isNull},
    {sipName_maxFrameRate, meth_QCameraFormat_maxFrameRate, METH_VARARGS, doc_QCameraFormat_maxFrameRate},
    {sipName_minFrameRate, meth_QCameraFormat_minFrameRate, METH_VARARGS, doc_QCameraFormat_minFrameRate},
    {sipName_pixelFormat, meth_QCameraFormat_pixelFormat, METH_VARARGS, doc_QCameraFormat_pixelFormat},
    {sipName_resolution, meth_QCameraFormat_resolution, METH_VARARGS, doc_QCameraFormat_resolution}
};

PyDoc_STRVAR(doc_QCameraFormat, "\1QCameraFormat()\n"
"QCameraFormat(QCameraFormat)");


sipClassTypeDef sipTypeDef_QtMultimedia_QCameraFormat = {
    {
        SIP_NULLPTR,
        SIP_TYPE_SUPER_INIT|SIP_TYPE_LIMITED_API|SIP_TYPE_CLASS,
        sipNameNr_QCameraFormat,
        SIP_NULLPTR,
        SIP_NULLPTR
    },
    {
        sipNameNr_QCameraFormat,
        {0, 0, 1},
        5, methods_QCameraFormat,
        0, SIP_NULLPTR,
        {SIP_NULLPTR, SIP_NULLPTR, SIP_NULLPTR, SIP_NULLPTR, SIP_NULLPTR, SIP_NULLPTR, SIP_NULLPTR, SIP_NULLPTR, SIP_NULLPTR, SIP_NULLPTR},
    },
    doc_QCameraFormat,
    -1,
    sipNameNr_PyQt6_sip_simplewrapper,
    SIP_NULLPTR,
    slots_QCameraFormat,
    init_type_QCameraFormat,
    SIP_NULLPTR,
    SIP_NULLPTR,
    SIP_NULLPTR,
    SIP_NULLPTR,
    dealloc_QCameraFormat,
    assign_QCameraFormat,
    array_QCameraFormat,
    copy_QCameraFormat,
    release_QCameraFormat,
    SIP_NULLPTR,
    SIP_NULLPTR,
    SIP_NULLPTR,
    SIP_NULLPTR,
    SIP_NULLPTR,
    SIP_NULLPTR,
    SIP_NULLPTR,
    array_delete_QCameraFormat,
    sizeof ( ::QCameraFormat),
};
