/****************************************************************************
**
** Copyright (C) 2016 The Qt Company Ltd.
** Contact: https://www.qt.io/licensing/
**
** This file is part of Qt for Python.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
** Licensees holding valid commercial Qt licenses may use this file in
** accordance with the commercial license agreement provided with the
** Software or, alternatively, in accordance with the terms contained in
** a written agreement between you and The Qt Company. For licensing terms
** and conditions see https://www.qt.io/terms-conditions. For further
** information use the contact form at https://www.qt.io/contact-us.
**
** GNU Lesser General Public License Usage
** Alternatively, this file may be used under the terms of the GNU Lesser
** General Public License version 3 as published by the Free Software
** Foundation and appearing in the file LICENSE.LGPL3 included in the
** packaging of this file. Please review the following information to
** ensure the GNU Lesser General Public License version 3 requirements
** will be met: https://www.gnu.org/licenses/lgpl-3.0.html.
**
** GNU General Public License Usage
** Alternatively, this file may be used under the terms of the GNU
** General Public License version 2.0 or (at your option) the GNU General
** Public license version 3 or any later version approved by the KDE Free
** Qt Foundation. The licenses are as published by the Free Software
** Foundation and appearing in the file LICENSE.GPL2 and LICENSE.GPL3
** included in the packaging of this file. Please review the following
** information to ensure the GNU General Public License requirements will
** be met: https://www.gnu.org/licenses/gpl-2.0.html and
** https://www.gnu.org/licenses/gpl-3.0.html.
**
** $QT_END_LICENSE$
**
****************************************************************************/

//workaround to access protected functions
#define protected public

// default includes
#include <shiboken.h>
#ifndef QT_NO_VERSION_TAGGING
#  define QT_NO_VERSION_TAGGING
#endif
#include <QDebug>
#include <pysidesignal.h>
#include <pysideproperty.h>
#include <pyside.h>
#include <pysideqenum.h>
#include <feature_select.h>
QT_WARNING_DISABLE_DEPRECATED

#include <typeinfo>
#include <signalmanager.h>
#include <pysidemetafunction.h>
#include <iterator>

// module include
#include "pyside6_qtdatavisualization_python.h"

// main header
#include "q3dscene_wrapper.h"

// inner classes

#include <cctype>
#include <cstring>



template <class T>
static const char *typeNameOf(const T &t)
{
    const char *typeName =  typeid(t).name();
    auto size = std::strlen(typeName);
#if defined(Q_CC_MSVC) // MSVC: "class QPaintDevice * __ptr64"
    if (auto lastStar = strchr(typeName, '*')) {
        // MSVC: "class QPaintDevice * __ptr64"
        while (*--lastStar == ' ') {
        }
        size = lastStar - typeName + 1;
    }
#else // g++, Clang: "QPaintDevice *" -> "P12QPaintDevice"
    if (size > 2 && typeName[0] == 'P' && std::isdigit(typeName[1])) {
        ++typeName;
        --size;
    }
#endif
    char *result = new char[size + 1];
    result[size] = '\0';
    memcpy(result, typeName, size);
    return result;
}

// Native ---------------------------------------------------------

void Q3DSceneWrapper::resetPyMethodCache()
{
    std::fill_n(m_PyMethodCache, sizeof(m_PyMethodCache) / sizeof(m_PyMethodCache[0]), false);
}

Q3DSceneWrapper::Q3DSceneWrapper(QObject * parent) : Q3DScene(parent)
{
    resetPyMethodCache();
    // ... middle
}

void Q3DSceneWrapper::childEvent(QChildEvent * event)
{
    if (m_PyMethodCache[0]) {
        return this->::QObject::childEvent(event);
    }
    Shiboken::GilState gil;
    if (PyErr_Occurred())
        return;
    static PyObject *nameCache[2] = {};
    static const char *funcName = "childEvent";
    Shiboken::AutoDecRef pyOverride(Shiboken::BindingManager::instance().getOverride(this, nameCache, funcName));
    if (pyOverride.isNull()) {
        gil.release();
        m_PyMethodCache[0] = true;
        return this->::QObject::childEvent(event);
    }

    Shiboken::AutoDecRef pyArgs(Py_BuildValue("(N)",
        Shiboken::Conversions::pointerToPython(SbkPySide6_QtCoreTypes[SBK_QCHILDEVENT_IDX], event)
    ));
    bool invalidateArg1 = PyTuple_GET_ITEM(pyArgs, 0)->ob_refcnt == 1;

    Shiboken::AutoDecRef pyResult(PyObject_Call(pyOverride, pyArgs, nullptr));
    if (invalidateArg1)
        Shiboken::Object::invalidate(PyTuple_GET_ITEM(pyArgs, 0));
    if (pyResult.isNull()) {
        // An error happened in python code!
        PyErr_Print();
        return;
    }
}

void Q3DSceneWrapper::connectNotify(const QMetaMethod & signal)
{
    if (m_PyMethodCache[1]) {
        return this->::QObject::connectNotify(signal);
    }
    Shiboken::GilState gil;
    if (PyErr_Occurred())
        return;
    static PyObject *nameCache[2] = {};
    static const char *funcName = "connectNotify";
    Shiboken::AutoDecRef pyOverride(Shiboken::BindingManager::instance().getOverride(this, nameCache, funcName));
    if (pyOverride.isNull()) {
        gil.release();
        m_PyMethodCache[1] = true;
        return this->::QObject::connectNotify(signal);
    }

    Shiboken::AutoDecRef pyArgs(Py_BuildValue("(N)",
        Shiboken::Conversions::copyToPython(SbkPySide6_QtCoreTypes[SBK_QMETAMETHOD_IDX], &signal)
    ));

    Shiboken::AutoDecRef pyResult(PyObject_Call(pyOverride, pyArgs, nullptr));
    if (pyResult.isNull()) {
        // An error happened in python code!
        PyErr_Print();
        return;
    }
}

void Q3DSceneWrapper::customEvent(QEvent * event)
{
    if (m_PyMethodCache[2]) {
        return this->::QObject::customEvent(event);
    }
    Shiboken::GilState gil;
    if (PyErr_Occurred())
        return;
    static PyObject *nameCache[2] = {};
    static const char *funcName = "customEvent";
    Shiboken::AutoDecRef pyOverride(Shiboken::BindingManager::instance().getOverride(this, nameCache, funcName));
    if (pyOverride.isNull()) {
        gil.release();
        m_PyMethodCache[2] = true;
        return this->::QObject::customEvent(event);
    }

    Shiboken::AutoDecRef pyArgs(Py_BuildValue("(N)",
        Shiboken::Conversions::pointerToPython(SbkPySide6_QtCoreTypes[SBK_QEVENT_IDX], event)
    ));
    bool invalidateArg1 = PyTuple_GET_ITEM(pyArgs, 0)->ob_refcnt == 1;

    Shiboken::AutoDecRef pyResult(PyObject_Call(pyOverride, pyArgs, nullptr));
    if (invalidateArg1)
        Shiboken::Object::invalidate(PyTuple_GET_ITEM(pyArgs, 0));
    if (pyResult.isNull()) {
        // An error happened in python code!
        PyErr_Print();
        return;
    }
}

void Q3DSceneWrapper::disconnectNotify(const QMetaMethod & signal)
{
    if (m_PyMethodCache[3]) {
        return this->::QObject::disconnectNotify(signal);
    }
    Shiboken::GilState gil;
    if (PyErr_Occurred())
        return;
    static PyObject *nameCache[2] = {};
    static const char *funcName = "disconnectNotify";
    Shiboken::AutoDecRef pyOverride(Shiboken::BindingManager::instance().getOverride(this, nameCache, funcName));
    if (pyOverride.isNull()) {
        gil.release();
        m_PyMethodCache[3] = true;
        return this->::QObject::disconnectNotify(signal);
    }

    Shiboken::AutoDecRef pyArgs(Py_BuildValue("(N)",
        Shiboken::Conversions::copyToPython(SbkPySide6_QtCoreTypes[SBK_QMETAMETHOD_IDX], &signal)
    ));

    Shiboken::AutoDecRef pyResult(PyObject_Call(pyOverride, pyArgs, nullptr));
    if (pyResult.isNull()) {
        // An error happened in python code!
        PyErr_Print();
        return;
    }
}

bool Q3DSceneWrapper::event(QEvent * event)
{
    if (m_PyMethodCache[4])
        return this->::QObject::event(event);
    Shiboken::GilState gil;
    if (PyErr_Occurred())
        return false;
    static PyObject *nameCache[2] = {};
    static const char *funcName = "event";
    Shiboken::AutoDecRef pyOverride(Shiboken::BindingManager::instance().getOverride(this, nameCache, funcName));
    if (pyOverride.isNull()) {
        gil.release();
        m_PyMethodCache[4] = true;
        return this->::QObject::event(event);
    }

    Shiboken::AutoDecRef pyArgs(Py_BuildValue("(N)",
        Shiboken::Conversions::pointerToPython(SbkPySide6_QtCoreTypes[SBK_QEVENT_IDX], event)
    ));
    bool invalidateArg1 = PyTuple_GET_ITEM(pyArgs, 0)->ob_refcnt == 1;

    Shiboken::AutoDecRef pyResult(PyObject_Call(pyOverride, pyArgs, nullptr));
    if (invalidateArg1)
        Shiboken::Object::invalidate(PyTuple_GET_ITEM(pyArgs, 0));
    if (pyResult.isNull()) {
        // An error happened in python code!
        PyErr_Print();
        return false;
    }
    // Check return type
    Shiboken::Conversions::PythonToCppConversion pythonToCpp =
        Shiboken::Conversions::pythonToCppConversion(Shiboken::Conversions::PrimitiveTypeConverter<bool>(), pyResult);
    if (!pythonToCpp) {
        Shiboken::warning(PyExc_RuntimeWarning, 2,
            "Invalid return value in function %s, expected %s, got %s.",
            "Q3DScene.event",
            "bool",
            Py_TYPE(pyResult)->tp_name);
        return false;
    }
    bool cppResult;
    pythonToCpp(pyResult, &cppResult);
    return cppResult;
}

bool Q3DSceneWrapper::eventFilter(QObject * watched, QEvent * event)
{
    if (m_PyMethodCache[5])
        return this->::QObject::eventFilter(watched, event);
    Shiboken::GilState gil;
    if (PyErr_Occurred())
        return false;
    static PyObject *nameCache[2] = {};
    static const char *funcName = "eventFilter";
    Shiboken::AutoDecRef pyOverride(Shiboken::BindingManager::instance().getOverride(this, nameCache, funcName));
    if (pyOverride.isNull()) {
        gil.release();
        m_PyMethodCache[5] = true;
        return this->::QObject::eventFilter(watched, event);
    }

    Shiboken::AutoDecRef pyArgs(Py_BuildValue("(NN)",
        Shiboken::Conversions::pointerToPython(SbkPySide6_QtCoreTypes[SBK_QOBJECT_IDX], watched),
        Shiboken::Conversions::pointerToPython(SbkPySide6_QtCoreTypes[SBK_QEVENT_IDX], event)
    ));
    bool invalidateArg2 = PyTuple_GET_ITEM(pyArgs, 1)->ob_refcnt == 1;

    Shiboken::AutoDecRef pyResult(PyObject_Call(pyOverride, pyArgs, nullptr));
    if (invalidateArg2)
        Shiboken::Object::invalidate(PyTuple_GET_ITEM(pyArgs, 1));
    if (pyResult.isNull()) {
        // An error happened in python code!
        PyErr_Print();
        return false;
    }
    // Check return type
    Shiboken::Conversions::PythonToCppConversion pythonToCpp =
        Shiboken::Conversions::pythonToCppConversion(Shiboken::Conversions::PrimitiveTypeConverter<bool>(), pyResult);
    if (!pythonToCpp) {
        Shiboken::warning(PyExc_RuntimeWarning, 2,
            "Invalid return value in function %s, expected %s, got %s.",
            "Q3DScene.eventFilter",
            "bool",
            Py_TYPE(pyResult)->tp_name);
        return false;
    }
    bool cppResult;
    pythonToCpp(pyResult, &cppResult);
    return cppResult;
}

void Q3DSceneWrapper::timerEvent(QTimerEvent * event)
{
    if (m_PyMethodCache[7]) {
        return this->::QObject::timerEvent(event);
    }
    Shiboken::GilState gil;
    if (PyErr_Occurred())
        return;
    static PyObject *nameCache[2] = {};
    static const char *funcName = "timerEvent";
    Shiboken::AutoDecRef pyOverride(Shiboken::BindingManager::instance().getOverride(this, nameCache, funcName));
    if (pyOverride.isNull()) {
        gil.release();
        m_PyMethodCache[7] = true;
        return this->::QObject::timerEvent(event);
    }

    Shiboken::AutoDecRef pyArgs(Py_BuildValue("(N)",
        Shiboken::Conversions::pointerToPython(SbkPySide6_QtCoreTypes[SBK_QTIMEREVENT_IDX], event)
    ));
    bool invalidateArg1 = PyTuple_GET_ITEM(pyArgs, 0)->ob_refcnt == 1;

    Shiboken::AutoDecRef pyResult(PyObject_Call(pyOverride, pyArgs, nullptr));
    if (invalidateArg1)
        Shiboken::Object::invalidate(PyTuple_GET_ITEM(pyArgs, 0));
    if (pyResult.isNull()) {
        // An error happened in python code!
        PyErr_Print();
        return;
    }
}

const QMetaObject *Q3DSceneWrapper::metaObject() const
{
    if (QObject::d_ptr->metaObject)
        return QObject::d_ptr->dynamicMetaObject();
    SbkObject *pySelf = Shiboken::BindingManager::instance().retrieveWrapper(this);
    if (pySelf == nullptr)
        return Q3DScene::metaObject();
    return PySide::SignalManager::retrieveMetaObject(reinterpret_cast<PyObject *>(pySelf));
}

int Q3DSceneWrapper::qt_metacall(QMetaObject::Call call, int id, void **args)
{
    int result = Q3DScene::qt_metacall(call, id, args);
    return result < 0 ? result : PySide::SignalManager::qt_metacall(this, call, id, args);
}

void *Q3DSceneWrapper::qt_metacast(const char *_clname)
{
    if (!_clname)
        return {};
    SbkObject *pySelf = Shiboken::BindingManager::instance().retrieveWrapper(this);
    if (pySelf && PySide::inherits(Py_TYPE(pySelf), _clname))
        return static_cast<void *>(const_cast< Q3DSceneWrapper *>(this));
    return Q3DScene::qt_metacast(_clname);
}

Q3DSceneWrapper::~Q3DSceneWrapper()
{
    SbkObject *wrapper = Shiboken::BindingManager::instance().retrieveWrapper(this);
    Shiboken::Object::destroy(wrapper, this);
}

// Target ---------------------------------------------------------

extern "C" {
static int
Sbk_Q3DScene_Init(PyObject *self, PyObject *args, PyObject *kwds)
{
    const QMetaObject *metaObject;
    SbkObject *sbkSelf = reinterpret_cast<SbkObject *>(self);
    PySide::Feature::Select(self);
    if (Shiboken::Object::isUserType(self) && !Shiboken::ObjectType::canCallConstructor(self->ob_type, Shiboken::SbkType< ::Q3DScene >()))
        return -1;

    ::Q3DSceneWrapper *cptr{};
    Shiboken::AutoDecRef errInfo{};
    static const char *fullName = "PySide6.QtDataVisualization.Q3DScene.__init__";
    SBK_UNUSED(fullName)
    int overloadId = -1;
    Shiboken::Conversions::PythonToCppConversion pythonToCpp[1];
    SBK_UNUSED(pythonToCpp)
    const Py_ssize_t numArgs = PyTuple_GET_SIZE(args);
    SBK_UNUSED(numArgs)
    PyObject *pyArgs[] = {0};

    // invalid argument lengths


    if (!PyArg_ParseTuple(args, "|O:Q3DScene", &(pyArgs[0])))
        return -1;


    // Overloaded function decisor
    // 0: Q3DScene::Q3DScene(QObject*)
    if (numArgs == 0) {
        overloadId = 0; // Q3DScene(QObject*)
    } else if (numArgs >= 1
        && (pythonToCpp[0] = Shiboken::Conversions::pythonToCppPointerConversion(SbkPySide6_QtCoreTypes[SBK_QOBJECT_IDX], (pyArgs[0])))) {
        overloadId = 0; // Q3DScene(QObject*)
    }

    // Function signature not found.
    if (overloadId == -1) goto Sbk_Q3DScene_Init_TypeError;

    // Call function/method
    {
        if (kwds && PyDict_Size(kwds) > 0) {
            PyObject *value{};
            Shiboken::AutoDecRef kwds_dup(PyDict_Copy(kwds));
            static PyObject *const key_parent = Shiboken::String::createStaticString("parent");
            if (PyDict_Contains(kwds, key_parent)) {
                value = PyDict_GetItem(kwds, key_parent);
                if (value && pyArgs[0]) {
                    errInfo.reset(key_parent);
                    Py_INCREF(errInfo.object());
                    goto Sbk_Q3DScene_Init_TypeError;
                }
                if (value) {
                    pyArgs[0] = value;
                    if (!(pythonToCpp[0] = Shiboken::Conversions::pythonToCppPointerConversion(SbkPySide6_QtCoreTypes[SBK_QOBJECT_IDX], (pyArgs[0]))))
                        goto Sbk_Q3DScene_Init_TypeError;
                }
                PyDict_DelItem(kwds_dup, key_parent);
            }
            if (PyDict_Size(kwds_dup) > 0) {
                errInfo.reset(kwds_dup.release());
                // fall through to handle extra keyword signals and properties
            }
        }
        if (!Shiboken::Object::isValid(pyArgs[0]))
            return -1;
        ::QObject *cppArg0 = nullptr;
        if (pythonToCpp[0])
            pythonToCpp[0](pyArgs[0], &cppArg0);

        if (!PyErr_Occurred()) {
            // Q3DScene(QObject*)
            void *addr = PySide::nextQObjectMemoryAddr();
            if (addr) {
                cptr = new (addr) ::Q3DSceneWrapper(cppArg0);
                PySide::setNextQObjectMemoryAddr(0);
            } else {
                cptr = new ::Q3DSceneWrapper(cppArg0);
            }

            Shiboken::Object::setParent(pyArgs[0], self);
        }
    }

    if (PyErr_Occurred() || !Shiboken::Object::setCppPointer(sbkSelf, Shiboken::SbkType< ::Q3DScene >(), cptr)) {
        delete cptr;
        return -1;
    }
    if (!cptr) goto Sbk_Q3DScene_Init_TypeError;

    Shiboken::Object::setValidCpp(sbkSelf, true);
    Shiboken::Object::setHasCppWrapper(sbkSelf, true);
    if (Shiboken::BindingManager::instance().hasWrapper(cptr)) {
        Shiboken::BindingManager::instance().releaseWrapper(Shiboken::BindingManager::instance().retrieveWrapper(cptr));
    }
    Shiboken::BindingManager::instance().registerWrapper(sbkSelf, cptr);

    // QObject setup
    PySide::Signal::updateSourceObject(self);
    metaObject = cptr->metaObject(); // <- init python qt properties
    if (!errInfo.isNull() && PyDict_Check(errInfo.object())) {
        if (!PySide::fillQtProperties(self, metaObject, errInfo))
            goto Sbk_Q3DScene_Init_TypeError;
    };


    return 1;

    Sbk_Q3DScene_Init_TypeError:
        Shiboken::setErrorAboutWrongArguments(args, fullName, errInfo);
        return -1;
}

static PyObject *Sbk_Q3DSceneFunc_activeCamera(PyObject *self)
{
    if (!Shiboken::Object::isValid(self))
        return {};
    auto cppSelf = reinterpret_cast< ::Q3DScene *>(Shiboken::Conversions::cppPointer(SbkPySide6_QtDataVisualizationTypes[SBK_Q3DSCENE_IDX], reinterpret_cast<SbkObject *>(self)));
    SBK_UNUSED(cppSelf)
    PyObject *pyResult{};
    Shiboken::AutoDecRef errInfo{};
    static const char *fullName = "PySide6.QtDataVisualization.Q3DScene.activeCamera";
    SBK_UNUSED(fullName)

    // Call function/method
    {

        if (!PyErr_Occurred()) {
            // activeCamera()const
            Q3DCamera * cppResult = const_cast<const ::Q3DScene *>(cppSelf)->activeCamera();
            pyResult = Shiboken::Conversions::pointerToPython(SbkPySide6_QtDataVisualizationTypes[SBK_Q3DCAMERA_IDX], cppResult);
            Shiboken::Object::setParent(self, pyResult);
        }
    }

    if (PyErr_Occurred() || !pyResult) {
        Py_XDECREF(pyResult);
        return {};
    }
    return pyResult;
}

static PyObject *Sbk_Q3DSceneFunc_activeLight(PyObject *self)
{
    if (!Shiboken::Object::isValid(self))
        return {};
    auto cppSelf = reinterpret_cast< ::Q3DScene *>(Shiboken::Conversions::cppPointer(SbkPySide6_QtDataVisualizationTypes[SBK_Q3DSCENE_IDX], reinterpret_cast<SbkObject *>(self)));
    SBK_UNUSED(cppSelf)
    PyObject *pyResult{};
    Shiboken::AutoDecRef errInfo{};
    static const char *fullName = "PySide6.QtDataVisualization.Q3DScene.activeLight";
    SBK_UNUSED(fullName)

    // Call function/method
    {

        if (!PyErr_Occurred()) {
            // activeLight()const
            Q3DLight * cppResult = const_cast<const ::Q3DScene *>(cppSelf)->activeLight();
            pyResult = Shiboken::Conversions::pointerToPython(SbkPySide6_QtDataVisualizationTypes[SBK_Q3DLIGHT_IDX], cppResult);
            Shiboken::Object::setParent(self, pyResult);
        }
    }

    if (PyErr_Occurred() || !pyResult) {
        Py_XDECREF(pyResult);
        return {};
    }
    return pyResult;
}

static PyObject *Sbk_Q3DSceneFunc_devicePixelRatio(PyObject *self)
{
    if (!Shiboken::Object::isValid(self))
        return {};
    auto cppSelf = reinterpret_cast< ::Q3DScene *>(Shiboken::Conversions::cppPointer(SbkPySide6_QtDataVisualizationTypes[SBK_Q3DSCENE_IDX], reinterpret_cast<SbkObject *>(self)));
    SBK_UNUSED(cppSelf)
    PyObject *pyResult{};
    Shiboken::AutoDecRef errInfo{};
    static const char *fullName = "PySide6.QtDataVisualization.Q3DScene.devicePixelRatio";
    SBK_UNUSED(fullName)

    // Call function/method
    {

        if (!PyErr_Occurred()) {
            // devicePixelRatio()const
            float cppResult = const_cast<const ::Q3DScene *>(cppSelf)->devicePixelRatio();
            pyResult = Shiboken::Conversions::copyToPython(Shiboken::Conversions::PrimitiveTypeConverter<float>(), &cppResult);
        }
    }

    if (PyErr_Occurred() || !pyResult) {
        Py_XDECREF(pyResult);
        return {};
    }
    return pyResult;
}

static PyObject *Sbk_Q3DSceneFunc_graphPositionQuery(PyObject *self)
{
    if (!Shiboken::Object::isValid(self))
        return {};
    auto cppSelf = reinterpret_cast< ::Q3DScene *>(Shiboken::Conversions::cppPointer(SbkPySide6_QtDataVisualizationTypes[SBK_Q3DSCENE_IDX], reinterpret_cast<SbkObject *>(self)));
    SBK_UNUSED(cppSelf)
    PyObject *pyResult{};
    Shiboken::AutoDecRef errInfo{};
    static const char *fullName = "PySide6.QtDataVisualization.Q3DScene.graphPositionQuery";
    SBK_UNUSED(fullName)

    // Call function/method
    {

        if (!PyErr_Occurred()) {
            // graphPositionQuery()const
            QPoint cppResult = const_cast<const ::Q3DScene *>(cppSelf)->graphPositionQuery();
            pyResult = Shiboken::Conversions::copyToPython(SbkPySide6_QtCoreTypes[SBK_QPOINT_IDX], &cppResult);
        }
    }

    if (PyErr_Occurred() || !pyResult) {
        Py_XDECREF(pyResult);
        return {};
    }
    return pyResult;
}

static PyObject *Sbk_Q3DSceneFunc_invalidSelectionPoint(PyObject *self)
{
    PyObject *pyResult{};
    Shiboken::AutoDecRef errInfo{};
    static const char *fullName = "PySide6.QtDataVisualization.Q3DScene.invalidSelectionPoint";
    SBK_UNUSED(fullName)

    // Call function/method
    {

        if (!PyErr_Occurred()) {
            // invalidSelectionPoint()
            QPoint cppResult = ::Q3DScene::invalidSelectionPoint();
            pyResult = Shiboken::Conversions::copyToPython(SbkPySide6_QtCoreTypes[SBK_QPOINT_IDX], &cppResult);
        }
    }

    if (PyErr_Occurred() || !pyResult) {
        Py_XDECREF(pyResult);
        return {};
    }
    return pyResult;
}

static PyObject *Sbk_Q3DSceneFunc_isPointInPrimarySubView(PyObject *self, PyObject *pyArg)
{
    if (!Shiboken::Object::isValid(self))
        return {};
    auto cppSelf = reinterpret_cast< ::Q3DScene *>(Shiboken::Conversions::cppPointer(SbkPySide6_QtDataVisualizationTypes[SBK_Q3DSCENE_IDX], reinterpret_cast<SbkObject *>(self)));
    SBK_UNUSED(cppSelf)
    PyObject *pyResult{};
    Shiboken::AutoDecRef errInfo{};
    static const char *fullName = "PySide6.QtDataVisualization.Q3DScene.isPointInPrimarySubView";
    SBK_UNUSED(fullName)
    int overloadId = -1;
    Shiboken::Conversions::PythonToCppConversion pythonToCpp;
    SBK_UNUSED(pythonToCpp)

    // Overloaded function decisor
    // 0: Q3DScene::isPointInPrimarySubView(QPoint)->bool
    if ((pythonToCpp = Shiboken::Conversions::pythonToCppReferenceConversion(SbkPySide6_QtCoreTypes[SBK_QPOINT_IDX], (pyArg)))) {
        overloadId = 0; // isPointInPrimarySubView(QPoint)
    }

    // Function signature not found.
    if (overloadId == -1) goto Sbk_Q3DSceneFunc_isPointInPrimarySubView_TypeError;

    // Call function/method
    {
        if (!Shiboken::Object::isValid(pyArg))
            return {};
        ::QPoint cppArg0_local;
        ::QPoint *cppArg0 = &cppArg0_local;
        if (pythonToCpp.isValue())
            pythonToCpp(pyArg, &cppArg0_local);
        else
            pythonToCpp(pyArg, &cppArg0);


        if (!PyErr_Occurred()) {
            // isPointInPrimarySubView(QPoint)
            bool cppResult = cppSelf->isPointInPrimarySubView(*cppArg0);
            pyResult = Shiboken::Conversions::copyToPython(Shiboken::Conversions::PrimitiveTypeConverter<bool>(), &cppResult);
        }
    }

    if (PyErr_Occurred() || !pyResult) {
        Py_XDECREF(pyResult);
        return {};
    }
    return pyResult;

    Sbk_Q3DSceneFunc_isPointInPrimarySubView_TypeError:
        Shiboken::setErrorAboutWrongArguments(pyArg, fullName, errInfo);
        return {};
}

static PyObject *Sbk_Q3DSceneFunc_isPointInSecondarySubView(PyObject *self, PyObject *pyArg)
{
    if (!Shiboken::Object::isValid(self))
        return {};
    auto cppSelf = reinterpret_cast< ::Q3DScene *>(Shiboken::Conversions::cppPointer(SbkPySide6_QtDataVisualizationTypes[SBK_Q3DSCENE_IDX], reinterpret_cast<SbkObject *>(self)));
    SBK_UNUSED(cppSelf)
    PyObject *pyResult{};
    Shiboken::AutoDecRef errInfo{};
    static const char *fullName = "PySide6.QtDataVisualization.Q3DScene.isPointInSecondarySubView";
    SBK_UNUSED(fullName)
    int overloadId = -1;
    Shiboken::Conversions::PythonToCppConversion pythonToCpp;
    SBK_UNUSED(pythonToCpp)

    // Overloaded function decisor
    // 0: Q3DScene::isPointInSecondarySubView(QPoint)->bool
    if ((pythonToCpp = Shiboken::Conversions::pythonToCppReferenceConversion(SbkPySide6_QtCoreTypes[SBK_QPOINT_IDX], (pyArg)))) {
        overloadId = 0; // isPointInSecondarySubView(QPoint)
    }

    // Function signature not found.
    if (overloadId == -1) goto Sbk_Q3DSceneFunc_isPointInSecondarySubView_TypeError;

    // Call function/method
    {
        if (!Shiboken::Object::isValid(pyArg))
            return {};
        ::QPoint cppArg0_local;
        ::QPoint *cppArg0 = &cppArg0_local;
        if (pythonToCpp.isValue())
            pythonToCpp(pyArg, &cppArg0_local);
        else
            pythonToCpp(pyArg, &cppArg0);


        if (!PyErr_Occurred()) {
            // isPointInSecondarySubView(QPoint)
            bool cppResult = cppSelf->isPointInSecondarySubView(*cppArg0);
            pyResult = Shiboken::Conversions::copyToPython(Shiboken::Conversions::PrimitiveTypeConverter<bool>(), &cppResult);
        }
    }

    if (PyErr_Occurred() || !pyResult) {
        Py_XDECREF(pyResult);
        return {};
    }
    return pyResult;

    Sbk_Q3DSceneFunc_isPointInSecondarySubView_TypeError:
        Shiboken::setErrorAboutWrongArguments(pyArg, fullName, errInfo);
        return {};
}

static PyObject *Sbk_Q3DSceneFunc_isSecondarySubviewOnTop(PyObject *self)
{
    if (!Shiboken::Object::isValid(self))
        return {};
    auto cppSelf = reinterpret_cast< ::Q3DScene *>(Shiboken::Conversions::cppPointer(SbkPySide6_QtDataVisualizationTypes[SBK_Q3DSCENE_IDX], reinterpret_cast<SbkObject *>(self)));
    SBK_UNUSED(cppSelf)
    PyObject *pyResult{};
    Shiboken::AutoDecRef errInfo{};
    static const char *fullName = "PySide6.QtDataVisualization.Q3DScene.isSecondarySubviewOnTop";
    SBK_UNUSED(fullName)

    // Call function/method
    {

        if (!PyErr_Occurred()) {
            // isSecondarySubviewOnTop()const
            bool cppResult = const_cast<const ::Q3DScene *>(cppSelf)->isSecondarySubviewOnTop();
            pyResult = Shiboken::Conversions::copyToPython(Shiboken::Conversions::PrimitiveTypeConverter<bool>(), &cppResult);
        }
    }

    if (PyErr_Occurred() || !pyResult) {
        Py_XDECREF(pyResult);
        return {};
    }
    return pyResult;
}

static PyObject *Sbk_Q3DSceneFunc_isSlicingActive(PyObject *self)
{
    if (!Shiboken::Object::isValid(self))
        return {};
    auto cppSelf = reinterpret_cast< ::Q3DScene *>(Shiboken::Conversions::cppPointer(SbkPySide6_QtDataVisualizationTypes[SBK_Q3DSCENE_IDX], reinterpret_cast<SbkObject *>(self)));
    SBK_UNUSED(cppSelf)
    PyObject *pyResult{};
    Shiboken::AutoDecRef errInfo{};
    static const char *fullName = "PySide6.QtDataVisualization.Q3DScene.isSlicingActive";
    SBK_UNUSED(fullName)

    // Call function/method
    {

        if (!PyErr_Occurred()) {
            // isSlicingActive()const
            bool cppResult = const_cast<const ::Q3DScene *>(cppSelf)->isSlicingActive();
            pyResult = Shiboken::Conversions::copyToPython(Shiboken::Conversions::PrimitiveTypeConverter<bool>(), &cppResult);
        }
    }

    if (PyErr_Occurred() || !pyResult) {
        Py_XDECREF(pyResult);
        return {};
    }
    return pyResult;
}

static PyObject *Sbk_Q3DSceneFunc_primarySubViewport(PyObject *self)
{
    if (!Shiboken::Object::isValid(self))
        return {};
    auto cppSelf = reinterpret_cast< ::Q3DScene *>(Shiboken::Conversions::cppPointer(SbkPySide6_QtDataVisualizationTypes[SBK_Q3DSCENE_IDX], reinterpret_cast<SbkObject *>(self)));
    SBK_UNUSED(cppSelf)
    PyObject *pyResult{};
    Shiboken::AutoDecRef errInfo{};
    static const char *fullName = "PySide6.QtDataVisualization.Q3DScene.primarySubViewport";
    SBK_UNUSED(fullName)

    // Call function/method
    {

        if (!PyErr_Occurred()) {
            // primarySubViewport()const
            QRect cppResult = const_cast<const ::Q3DScene *>(cppSelf)->primarySubViewport();
            pyResult = Shiboken::Conversions::copyToPython(SbkPySide6_QtCoreTypes[SBK_QRECT_IDX], &cppResult);
        }
    }

    if (PyErr_Occurred() || !pyResult) {
        Py_XDECREF(pyResult);
        return {};
    }
    return pyResult;
}

static PyObject *Sbk_Q3DSceneFunc_secondarySubViewport(PyObject *self)
{
    if (!Shiboken::Object::isValid(self))
        return {};
    auto cppSelf = reinterpret_cast< ::Q3DScene *>(Shiboken::Conversions::cppPointer(SbkPySide6_QtDataVisualizationTypes[SBK_Q3DSCENE_IDX], reinterpret_cast<SbkObject *>(self)));
    SBK_UNUSED(cppSelf)
    PyObject *pyResult{};
    Shiboken::AutoDecRef errInfo{};
    static const char *fullName = "PySide6.QtDataVisualization.Q3DScene.secondarySubViewport";
    SBK_UNUSED(fullName)

    // Call function/method
    {

        if (!PyErr_Occurred()) {
            // secondarySubViewport()const
            QRect cppResult = const_cast<const ::Q3DScene *>(cppSelf)->secondarySubViewport();
            pyResult = Shiboken::Conversions::copyToPython(SbkPySide6_QtCoreTypes[SBK_QRECT_IDX], &cppResult);
        }
    }

    if (PyErr_Occurred() || !pyResult) {
        Py_XDECREF(pyResult);
        return {};
    }
    return pyResult;
}

static PyObject *Sbk_Q3DSceneFunc_selectionQueryPosition(PyObject *self)
{
    if (!Shiboken::Object::isValid(self))
        return {};
    auto cppSelf = reinterpret_cast< ::Q3DScene *>(Shiboken::Conversions::cppPointer(SbkPySide6_QtDataVisualizationTypes[SBK_Q3DSCENE_IDX], reinterpret_cast<SbkObject *>(self)));
    SBK_UNUSED(cppSelf)
    PyObject *pyResult{};
    Shiboken::AutoDecRef errInfo{};
    static const char *fullName = "PySide6.QtDataVisualization.Q3DScene.selectionQueryPosition";
    SBK_UNUSED(fullName)

    // Call function/method
    {

        if (!PyErr_Occurred()) {
            // selectionQueryPosition()const
            QPoint cppResult = const_cast<const ::Q3DScene *>(cppSelf)->selectionQueryPosition();
            pyResult = Shiboken::Conversions::copyToPython(SbkPySide6_QtCoreTypes[SBK_QPOINT_IDX], &cppResult);
        }
    }

    if (PyErr_Occurred() || !pyResult) {
        Py_XDECREF(pyResult);
        return {};
    }
    return pyResult;
}

static PyObject *Sbk_Q3DSceneFunc_setActiveCamera(PyObject *self, PyObject *pyArg)
{
    if (!Shiboken::Object::isValid(self))
        return {};
    auto cppSelf = reinterpret_cast< ::Q3DScene *>(Shiboken::Conversions::cppPointer(SbkPySide6_QtDataVisualizationTypes[SBK_Q3DSCENE_IDX], reinterpret_cast<SbkObject *>(self)));
    SBK_UNUSED(cppSelf)
    Shiboken::AutoDecRef errInfo{};
    static const char *fullName = "PySide6.QtDataVisualization.Q3DScene.setActiveCamera";
    SBK_UNUSED(fullName)
    int overloadId = -1;
    Shiboken::Conversions::PythonToCppConversion pythonToCpp;
    SBK_UNUSED(pythonToCpp)

    // Overloaded function decisor
    // 0: Q3DScene::setActiveCamera(Q3DCamera*)
    if ((pythonToCpp = Shiboken::Conversions::pythonToCppPointerConversion(SbkPySide6_QtDataVisualizationTypes[SBK_Q3DCAMERA_IDX], (pyArg)))) {
        overloadId = 0; // setActiveCamera(Q3DCamera*)
    }

    // Function signature not found.
    if (overloadId == -1) goto Sbk_Q3DSceneFunc_setActiveCamera_TypeError;

    // Call function/method
    {
        if (!Shiboken::Object::isValid(pyArg))
            return {};
        ::Q3DCamera *cppArg0;
        pythonToCpp(pyArg, &cppArg0);

        if (!PyErr_Occurred()) {
            // setActiveCamera(Q3DCamera*)
            cppSelf->setActiveCamera(cppArg0);
        }
    }

    if (PyErr_Occurred()) {
        return {};
    }
    Py_RETURN_NONE;

    Sbk_Q3DSceneFunc_setActiveCamera_TypeError:
        Shiboken::setErrorAboutWrongArguments(pyArg, fullName, errInfo);
        return {};
}

static PyObject *Sbk_Q3DSceneFunc_setActiveLight(PyObject *self, PyObject *pyArg)
{
    if (!Shiboken::Object::isValid(self))
        return {};
    auto cppSelf = reinterpret_cast< ::Q3DScene *>(Shiboken::Conversions::cppPointer(SbkPySide6_QtDataVisualizationTypes[SBK_Q3DSCENE_IDX], reinterpret_cast<SbkObject *>(self)));
    SBK_UNUSED(cppSelf)
    Shiboken::AutoDecRef errInfo{};
    static const char *fullName = "PySide6.QtDataVisualization.Q3DScene.setActiveLight";
    SBK_UNUSED(fullName)
    int overloadId = -1;
    Shiboken::Conversions::PythonToCppConversion pythonToCpp;
    SBK_UNUSED(pythonToCpp)

    // Overloaded function decisor
    // 0: Q3DScene::setActiveLight(Q3DLight*)
    if ((pythonToCpp = Shiboken::Conversions::pythonToCppPointerConversion(SbkPySide6_QtDataVisualizationTypes[SBK_Q3DLIGHT_IDX], (pyArg)))) {
        overloadId = 0; // setActiveLight(Q3DLight*)
    }

    // Function signature not found.
    if (overloadId == -1) goto Sbk_Q3DSceneFunc_setActiveLight_TypeError;

    // Call function/method
    {
        if (!Shiboken::Object::isValid(pyArg))
            return {};
        ::Q3DLight *cppArg0;
        pythonToCpp(pyArg, &cppArg0);

        if (!PyErr_Occurred()) {
            // setActiveLight(Q3DLight*)
            cppSelf->setActiveLight(cppArg0);
        }
    }

    if (PyErr_Occurred()) {
        return {};
    }
    Py_RETURN_NONE;

    Sbk_Q3DSceneFunc_setActiveLight_TypeError:
        Shiboken::setErrorAboutWrongArguments(pyArg, fullName, errInfo);
        return {};
}

static PyObject *Sbk_Q3DSceneFunc_setDevicePixelRatio(PyObject *self, PyObject *pyArg)
{
    if (!Shiboken::Object::isValid(self))
        return {};
    auto cppSelf = reinterpret_cast< ::Q3DScene *>(Shiboken::Conversions::cppPointer(SbkPySide6_QtDataVisualizationTypes[SBK_Q3DSCENE_IDX], reinterpret_cast<SbkObject *>(self)));
    SBK_UNUSED(cppSelf)
    Shiboken::AutoDecRef errInfo{};
    static const char *fullName = "PySide6.QtDataVisualization.Q3DScene.setDevicePixelRatio";
    SBK_UNUSED(fullName)
    int overloadId = -1;
    Shiboken::Conversions::PythonToCppConversion pythonToCpp;
    SBK_UNUSED(pythonToCpp)

    // Overloaded function decisor
    // 0: Q3DScene::setDevicePixelRatio(float)
    if ((pythonToCpp = Shiboken::Conversions::pythonToCppConversion(Shiboken::Conversions::PrimitiveTypeConverter<float>(), (pyArg)))) {
        overloadId = 0; // setDevicePixelRatio(float)
    }

    // Function signature not found.
    if (overloadId == -1) goto Sbk_Q3DSceneFunc_setDevicePixelRatio_TypeError;

    // Call function/method
    {
        float cppArg0;
        pythonToCpp(pyArg, &cppArg0);

        if (!PyErr_Occurred()) {
            // setDevicePixelRatio(float)
            cppSelf->setDevicePixelRatio(cppArg0);
        }
    }

    if (PyErr_Occurred()) {
        return {};
    }
    Py_RETURN_NONE;

    Sbk_Q3DSceneFunc_setDevicePixelRatio_TypeError:
        Shiboken::setErrorAboutWrongArguments(pyArg, fullName, errInfo);
        return {};
}

static PyObject *Sbk_Q3DSceneFunc_setGraphPositionQuery(PyObject *self, PyObject *pyArg)
{
    if (!Shiboken::Object::isValid(self))
        return {};
    auto cppSelf = reinterpret_cast< ::Q3DScene *>(Shiboken::Conversions::cppPointer(SbkPySide6_QtDataVisualizationTypes[SBK_Q3DSCENE_IDX], reinterpret_cast<SbkObject *>(self)));
    SBK_UNUSED(cppSelf)
    Shiboken::AutoDecRef errInfo{};
    static const char *fullName = "PySide6.QtDataVisualization.Q3DScene.setGraphPositionQuery";
    SBK_UNUSED(fullName)
    int overloadId = -1;
    Shiboken::Conversions::PythonToCppConversion pythonToCpp;
    SBK_UNUSED(pythonToCpp)

    // Overloaded function decisor
    // 0: Q3DScene::setGraphPositionQuery(QPoint)
    if ((pythonToCpp = Shiboken::Conversions::pythonToCppReferenceConversion(SbkPySide6_QtCoreTypes[SBK_QPOINT_IDX], (pyArg)))) {
        overloadId = 0; // setGraphPositionQuery(QPoint)
    }

    // Function signature not found.
    if (overloadId == -1) goto Sbk_Q3DSceneFunc_setGraphPositionQuery_TypeError;

    // Call function/method
    {
        if (!Shiboken::Object::isValid(pyArg))
            return {};
        ::QPoint cppArg0_local;
        ::QPoint *cppArg0 = &cppArg0_local;
        if (pythonToCpp.isValue())
            pythonToCpp(pyArg, &cppArg0_local);
        else
            pythonToCpp(pyArg, &cppArg0);


        if (!PyErr_Occurred()) {
            // setGraphPositionQuery(QPoint)
            cppSelf->setGraphPositionQuery(*cppArg0);
        }
    }

    if (PyErr_Occurred()) {
        return {};
    }
    Py_RETURN_NONE;

    Sbk_Q3DSceneFunc_setGraphPositionQuery_TypeError:
        Shiboken::setErrorAboutWrongArguments(pyArg, fullName, errInfo);
        return {};
}

static PyObject *Sbk_Q3DSceneFunc_setPrimarySubViewport(PyObject *self, PyObject *pyArg)
{
    if (!Shiboken::Object::isValid(self))
        return {};
    auto cppSelf = reinterpret_cast< ::Q3DScene *>(Shiboken::Conversions::cppPointer(SbkPySide6_QtDataVisualizationTypes[SBK_Q3DSCENE_IDX], reinterpret_cast<SbkObject *>(self)));
    SBK_UNUSED(cppSelf)
    Shiboken::AutoDecRef errInfo{};
    static const char *fullName = "PySide6.QtDataVisualization.Q3DScene.setPrimarySubViewport";
    SBK_UNUSED(fullName)
    int overloadId = -1;
    Shiboken::Conversions::PythonToCppConversion pythonToCpp;
    SBK_UNUSED(pythonToCpp)

    // Overloaded function decisor
    // 0: Q3DScene::setPrimarySubViewport(QRect)
    if ((pythonToCpp = Shiboken::Conversions::pythonToCppReferenceConversion(SbkPySide6_QtCoreTypes[SBK_QRECT_IDX], (pyArg)))) {
        overloadId = 0; // setPrimarySubViewport(QRect)
    }

    // Function signature not found.
    if (overloadId == -1) goto Sbk_Q3DSceneFunc_setPrimarySubViewport_TypeError;

    // Call function/method
    {
        if (!Shiboken::Object::isValid(pyArg))
            return {};
        ::QRect cppArg0_local;
        ::QRect *cppArg0 = &cppArg0_local;
        if (pythonToCpp.isValue())
            pythonToCpp(pyArg, &cppArg0_local);
        else
            pythonToCpp(pyArg, &cppArg0);


        if (!PyErr_Occurred()) {
            // setPrimarySubViewport(QRect)
            cppSelf->setPrimarySubViewport(*cppArg0);
        }
    }

    if (PyErr_Occurred()) {
        return {};
    }
    Py_RETURN_NONE;

    Sbk_Q3DSceneFunc_setPrimarySubViewport_TypeError:
        Shiboken::setErrorAboutWrongArguments(pyArg, fullName, errInfo);
        return {};
}

static PyObject *Sbk_Q3DSceneFunc_setSecondarySubViewport(PyObject *self, PyObject *pyArg)
{
    if (!Shiboken::Object::isValid(self))
        return {};
    auto cppSelf = reinterpret_cast< ::Q3DScene *>(Shiboken::Conversions::cppPointer(SbkPySide6_QtDataVisualizationTypes[SBK_Q3DSCENE_IDX], reinterpret_cast<SbkObject *>(self)));
    SBK_UNUSED(cppSelf)
    Shiboken::AutoDecRef errInfo{};
    static const char *fullName = "PySide6.QtDataVisualization.Q3DScene.setSecondarySubViewport";
    SBK_UNUSED(fullName)
    int overloadId = -1;
    Shiboken::Conversions::PythonToCppConversion pythonToCpp;
    SBK_UNUSED(pythonToCpp)

    // Overloaded function decisor
    // 0: Q3DScene::setSecondarySubViewport(QRect)
    if ((pythonToCpp = Shiboken::Conversions::pythonToCppReferenceConversion(SbkPySide6_QtCoreTypes[SBK_QRECT_IDX], (pyArg)))) {
        overloadId = 0; // setSecondarySubViewport(QRect)
    }

    // Function signature not found.
    if (overloadId == -1) goto Sbk_Q3DSceneFunc_setSecondarySubViewport_TypeError;

    // Call function/method
    {
        if (!Shiboken::Object::isValid(pyArg))
            return {};
        ::QRect cppArg0_local;
        ::QRect *cppArg0 = &cppArg0_local;
        if (pythonToCpp.isValue())
            pythonToCpp(pyArg, &cppArg0_local);
        else
            pythonToCpp(pyArg, &cppArg0);


        if (!PyErr_Occurred()) {
            // setSecondarySubViewport(QRect)
            cppSelf->setSecondarySubViewport(*cppArg0);
        }
    }

    if (PyErr_Occurred()) {
        return {};
    }
    Py_RETURN_NONE;

    Sbk_Q3DSceneFunc_setSecondarySubViewport_TypeError:
        Shiboken::setErrorAboutWrongArguments(pyArg, fullName, errInfo);
        return {};
}

static PyObject *Sbk_Q3DSceneFunc_setSecondarySubviewOnTop(PyObject *self, PyObject *pyArg)
{
    if (!Shiboken::Object::isValid(self))
        return {};
    auto cppSelf = reinterpret_cast< ::Q3DScene *>(Shiboken::Conversions::cppPointer(SbkPySide6_QtDataVisualizationTypes[SBK_Q3DSCENE_IDX], reinterpret_cast<SbkObject *>(self)));
    SBK_UNUSED(cppSelf)
    Shiboken::AutoDecRef errInfo{};
    static const char *fullName = "PySide6.QtDataVisualization.Q3DScene.setSecondarySubviewOnTop";
    SBK_UNUSED(fullName)
    int overloadId = -1;
    Shiboken::Conversions::PythonToCppConversion pythonToCpp;
    SBK_UNUSED(pythonToCpp)

    // Overloaded function decisor
    // 0: Q3DScene::setSecondarySubviewOnTop(bool)
    if ((pythonToCpp = Shiboken::Conversions::pythonToCppConversion(Shiboken::Conversions::PrimitiveTypeConverter<bool>(), (pyArg)))) {
        overloadId = 0; // setSecondarySubviewOnTop(bool)
    }

    // Function signature not found.
    if (overloadId == -1) goto Sbk_Q3DSceneFunc_setSecondarySubviewOnTop_TypeError;

    // Call function/method
    {
        bool cppArg0;
        pythonToCpp(pyArg, &cppArg0);

        if (!PyErr_Occurred()) {
            // setSecondarySubviewOnTop(bool)
            cppSelf->setSecondarySubviewOnTop(cppArg0);
        }
    }

    if (PyErr_Occurred()) {
        return {};
    }
    Py_RETURN_NONE;

    Sbk_Q3DSceneFunc_setSecondarySubviewOnTop_TypeError:
        Shiboken::setErrorAboutWrongArguments(pyArg, fullName, errInfo);
        return {};
}

static PyObject *Sbk_Q3DSceneFunc_setSelectionQueryPosition(PyObject *self, PyObject *pyArg)
{
    if (!Shiboken::Object::isValid(self))
        return {};
    auto cppSelf = reinterpret_cast< ::Q3DScene *>(Shiboken::Conversions::cppPointer(SbkPySide6_QtDataVisualizationTypes[SBK_Q3DSCENE_IDX], reinterpret_cast<SbkObject *>(self)));
    SBK_UNUSED(cppSelf)
    Shiboken::AutoDecRef errInfo{};
    static const char *fullName = "PySide6.QtDataVisualization.Q3DScene.setSelectionQueryPosition";
    SBK_UNUSED(fullName)
    int overloadId = -1;
    Shiboken::Conversions::PythonToCppConversion pythonToCpp;
    SBK_UNUSED(pythonToCpp)

    // Overloaded function decisor
    // 0: Q3DScene::setSelectionQueryPosition(QPoint)
    if ((pythonToCpp = Shiboken::Conversions::pythonToCppReferenceConversion(SbkPySide6_QtCoreTypes[SBK_QPOINT_IDX], (pyArg)))) {
        overloadId = 0; // setSelectionQueryPosition(QPoint)
    }

    // Function signature not found.
    if (overloadId == -1) goto Sbk_Q3DSceneFunc_setSelectionQueryPosition_TypeError;

    // Call function/method
    {
        if (!Shiboken::Object::isValid(pyArg))
            return {};
        ::QPoint cppArg0_local;
        ::QPoint *cppArg0 = &cppArg0_local;
        if (pythonToCpp.isValue())
            pythonToCpp(pyArg, &cppArg0_local);
        else
            pythonToCpp(pyArg, &cppArg0);


        if (!PyErr_Occurred()) {
            // setSelectionQueryPosition(QPoint)
            cppSelf->setSelectionQueryPosition(*cppArg0);
        }
    }

    if (PyErr_Occurred()) {
        return {};
    }
    Py_RETURN_NONE;

    Sbk_Q3DSceneFunc_setSelectionQueryPosition_TypeError:
        Shiboken::setErrorAboutWrongArguments(pyArg, fullName, errInfo);
        return {};
}

static PyObject *Sbk_Q3DSceneFunc_setSlicingActive(PyObject *self, PyObject *pyArg)
{
    if (!Shiboken::Object::isValid(self))
        return {};
    auto cppSelf = reinterpret_cast< ::Q3DScene *>(Shiboken::Conversions::cppPointer(SbkPySide6_QtDataVisualizationTypes[SBK_Q3DSCENE_IDX], reinterpret_cast<SbkObject *>(self)));
    SBK_UNUSED(cppSelf)
    Shiboken::AutoDecRef errInfo{};
    static const char *fullName = "PySide6.QtDataVisualization.Q3DScene.setSlicingActive";
    SBK_UNUSED(fullName)
    int overloadId = -1;
    Shiboken::Conversions::PythonToCppConversion pythonToCpp;
    SBK_UNUSED(pythonToCpp)

    // Overloaded function decisor
    // 0: Q3DScene::setSlicingActive(bool)
    if ((pythonToCpp = Shiboken::Conversions::pythonToCppConversion(Shiboken::Conversions::PrimitiveTypeConverter<bool>(), (pyArg)))) {
        overloadId = 0; // setSlicingActive(bool)
    }

    // Function signature not found.
    if (overloadId == -1) goto Sbk_Q3DSceneFunc_setSlicingActive_TypeError;

    // Call function/method
    {
        bool cppArg0;
        pythonToCpp(pyArg, &cppArg0);

        if (!PyErr_Occurred()) {
            // setSlicingActive(bool)
            cppSelf->setSlicingActive(cppArg0);
        }
    }

    if (PyErr_Occurred()) {
        return {};
    }
    Py_RETURN_NONE;

    Sbk_Q3DSceneFunc_setSlicingActive_TypeError:
        Shiboken::setErrorAboutWrongArguments(pyArg, fullName, errInfo);
        return {};
}

static PyObject *Sbk_Q3DSceneFunc_viewport(PyObject *self)
{
    if (!Shiboken::Object::isValid(self))
        return {};
    auto cppSelf = reinterpret_cast< ::Q3DScene *>(Shiboken::Conversions::cppPointer(SbkPySide6_QtDataVisualizationTypes[SBK_Q3DSCENE_IDX], reinterpret_cast<SbkObject *>(self)));
    SBK_UNUSED(cppSelf)
    PyObject *pyResult{};
    Shiboken::AutoDecRef errInfo{};
    static const char *fullName = "PySide6.QtDataVisualization.Q3DScene.viewport";
    SBK_UNUSED(fullName)

    // Call function/method
    {

        if (!PyErr_Occurred()) {
            // viewport()const
            QRect cppResult = const_cast<const ::Q3DScene *>(cppSelf)->viewport();
            pyResult = Shiboken::Conversions::copyToPython(SbkPySide6_QtCoreTypes[SBK_QRECT_IDX], &cppResult);
        }
    }

    if (PyErr_Occurred() || !pyResult) {
        Py_XDECREF(pyResult);
        return {};
    }
    return pyResult;
}


static const char *Sbk_Q3DScene_PropertyStrings[] = {
    "activeCamera::",
    "activeLight::",
    "devicePixelRatio::",
    "graphPositionQuery::",
    "primarySubViewport::",
    "secondarySubViewport::",
    "secondarySubviewOnTop:isSecondarySubviewOnTop:",
    "selectionQueryPosition::",
    "slicingActive:isSlicingActive:",
    "viewport:",
    nullptr // Sentinel
};

static PyMethodDef Sbk_Q3DScene_methods[] = {
    {"activeCamera", reinterpret_cast<PyCFunction>(Sbk_Q3DSceneFunc_activeCamera), METH_NOARGS},
    {"activeLight", reinterpret_cast<PyCFunction>(Sbk_Q3DSceneFunc_activeLight), METH_NOARGS},
    {"devicePixelRatio", reinterpret_cast<PyCFunction>(Sbk_Q3DSceneFunc_devicePixelRatio), METH_NOARGS},
    {"graphPositionQuery", reinterpret_cast<PyCFunction>(Sbk_Q3DSceneFunc_graphPositionQuery), METH_NOARGS},
    {"invalidSelectionPoint", reinterpret_cast<PyCFunction>(Sbk_Q3DSceneFunc_invalidSelectionPoint), METH_NOARGS|METH_STATIC},
    {"isPointInPrimarySubView", reinterpret_cast<PyCFunction>(Sbk_Q3DSceneFunc_isPointInPrimarySubView), METH_O},
    {"isPointInSecondarySubView", reinterpret_cast<PyCFunction>(Sbk_Q3DSceneFunc_isPointInSecondarySubView), METH_O},
    {"isSecondarySubviewOnTop", reinterpret_cast<PyCFunction>(Sbk_Q3DSceneFunc_isSecondarySubviewOnTop), METH_NOARGS},
    {"isSlicingActive", reinterpret_cast<PyCFunction>(Sbk_Q3DSceneFunc_isSlicingActive), METH_NOARGS},
    {"primarySubViewport", reinterpret_cast<PyCFunction>(Sbk_Q3DSceneFunc_primarySubViewport), METH_NOARGS},
    {"secondarySubViewport", reinterpret_cast<PyCFunction>(Sbk_Q3DSceneFunc_secondarySubViewport), METH_NOARGS},
    {"selectionQueryPosition", reinterpret_cast<PyCFunction>(Sbk_Q3DSceneFunc_selectionQueryPosition), METH_NOARGS},
    {"setActiveCamera", reinterpret_cast<PyCFunction>(Sbk_Q3DSceneFunc_setActiveCamera), METH_O},
    {"setActiveLight", reinterpret_cast<PyCFunction>(Sbk_Q3DSceneFunc_setActiveLight), METH_O},
    {"setDevicePixelRatio", reinterpret_cast<PyCFunction>(Sbk_Q3DSceneFunc_setDevicePixelRatio), METH_O},
    {"setGraphPositionQuery", reinterpret_cast<PyCFunction>(Sbk_Q3DSceneFunc_setGraphPositionQuery), METH_O},
    {"setPrimarySubViewport", reinterpret_cast<PyCFunction>(Sbk_Q3DSceneFunc_setPrimarySubViewport), METH_O},
    {"setSecondarySubViewport", reinterpret_cast<PyCFunction>(Sbk_Q3DSceneFunc_setSecondarySubViewport), METH_O},
    {"setSecondarySubviewOnTop", reinterpret_cast<PyCFunction>(Sbk_Q3DSceneFunc_setSecondarySubviewOnTop), METH_O},
    {"setSelectionQueryPosition", reinterpret_cast<PyCFunction>(Sbk_Q3DSceneFunc_setSelectionQueryPosition), METH_O},
    {"setSlicingActive", reinterpret_cast<PyCFunction>(Sbk_Q3DSceneFunc_setSlicingActive), METH_O},
    {"viewport", reinterpret_cast<PyCFunction>(Sbk_Q3DSceneFunc_viewport), METH_NOARGS},

    {nullptr, nullptr} // Sentinel
};

static int Sbk_Q3DScene_setattro(PyObject *self, PyObject *name, PyObject *value)
{
    PySide::Feature::Select(self);
    if (value && PyCallable_Check(value)) {
        auto plain_inst = reinterpret_cast< ::Q3DScene *>(Shiboken::Conversions::cppPointer(SbkPySide6_QtDataVisualizationTypes[SBK_Q3DSCENE_IDX], reinterpret_cast<SbkObject *>(self)));
        auto inst = dynamic_cast<Q3DSceneWrapper *>(plain_inst);
        if (inst)
            inst->resetPyMethodCache();
    }
    Shiboken::AutoDecRef pp(reinterpret_cast<PyObject *>(PySide::Property::getObject(self, name)));
    if (!pp.isNull())
        return PySide::Property::setValue(reinterpret_cast<PySideProperty *>(pp.object()), self, value);
    return PyObject_GenericSetAttr(self, name, value);
}

} // extern "C"

static int Sbk_Q3DScene_traverse(PyObject *self, visitproc visit, void *arg)
{
    return SbkObject_TypeF()->tp_traverse(self, visit, arg);
}
static int Sbk_Q3DScene_clear(PyObject *self)
{
    return reinterpret_cast<PyTypeObject *>(SbkObject_TypeF())->tp_clear(self);
}
// Class Definition -----------------------------------------------
extern "C" {
static PyTypeObject *_Sbk_Q3DScene_Type = nullptr;
static PyTypeObject *Sbk_Q3DScene_TypeF(void)
{
    return _Sbk_Q3DScene_Type;
}

static PyType_Slot Sbk_Q3DScene_slots[] = {
    {Py_tp_base,        nullptr}, // inserted by introduceWrapperType
    {Py_tp_dealloc,     reinterpret_cast<void *>(&SbkDeallocWrapper)},
    {Py_tp_repr,        nullptr},
    {Py_tp_hash,        nullptr},
    {Py_tp_call,        nullptr},
    {Py_tp_str,         nullptr},
    {Py_tp_getattro,    nullptr},
    {Py_tp_setattro,    reinterpret_cast<void *>(Sbk_Q3DScene_setattro)},
    {Py_tp_traverse,    reinterpret_cast<void *>(Sbk_Q3DScene_traverse)},
    {Py_tp_clear,       reinterpret_cast<void *>(Sbk_Q3DScene_clear)},
    {Py_tp_richcompare, nullptr},
    {Py_tp_iter,        nullptr},
    {Py_tp_iternext,    nullptr},
    {Py_tp_methods,     reinterpret_cast<void *>(Sbk_Q3DScene_methods)},
    {Py_tp_getset,      nullptr},
    {Py_tp_init,        reinterpret_cast<void *>(Sbk_Q3DScene_Init)},
    {Py_tp_new,         reinterpret_cast<void *>(SbkObjectTpNew)},
    {0, nullptr}
};
static PyType_Spec Sbk_Q3DScene_spec = {
    "2:PySide6.QtDataVisualization.Q3DScene",
    sizeof(SbkObject),
    0,
    Py_TPFLAGS_DEFAULT|Py_TPFLAGS_BASETYPE|Py_TPFLAGS_HAVE_GC,
    Sbk_Q3DScene_slots
};

} //extern "C"

static void *Sbk_Q3DScene_typeDiscovery(void *cptr, PyTypeObject *instanceType)
{
    if (instanceType == Shiboken::SbkType< ::QObject >())
        return dynamic_cast< ::Q3DScene *>(reinterpret_cast< ::QObject *>(cptr));
    return {};
}


// Type conversion functions.

// Python to C++ pointer conversion - returns the C++ object of the Python wrapper (keeps object identity).
static void Q3DScene_PythonToCpp_Q3DScene_PTR(PyObject *pyIn, void *cppOut)
{
    Shiboken::Conversions::pythonToCppPointer(Sbk_Q3DScene_TypeF(), pyIn, cppOut);
}
static PythonToCppFunc is_Q3DScene_PythonToCpp_Q3DScene_PTR_Convertible(PyObject *pyIn)
{
    if (pyIn == Py_None)
        return Shiboken::Conversions::nonePythonToCppNullPtr;
    if (PyObject_TypeCheck(pyIn, reinterpret_cast<PyTypeObject *>(Sbk_Q3DScene_TypeF())))
        return Q3DScene_PythonToCpp_Q3DScene_PTR;
    return {};
}

// C++ to Python pointer conversion - tries to find the Python wrapper for the C++ object (keeps object identity).
static PyObject *Q3DScene_PTR_CppToPython_Q3DScene(const void *cppIn)
{
    return PySide::getWrapperForQObject(reinterpret_cast<::Q3DScene *>(const_cast<void *>(cppIn)), Sbk_Q3DScene_TypeF());

}

// The signatures string for the functions.
// Multiple signatures have their index "n:" in front.
static const char *Q3DScene_SignatureStrings[] = {
    "PySide6.QtDataVisualization.Q3DScene(self,parent:PySide6.QtCore.QObject=nullptr)",
    "PySide6.QtDataVisualization.Q3DScene.activeCamera(self)->PySide6.QtDataVisualization.Q3DCamera",
    "PySide6.QtDataVisualization.Q3DScene.activeLight(self)->PySide6.QtDataVisualization.Q3DLight",
    "PySide6.QtDataVisualization.Q3DScene.devicePixelRatio(self)->float",
    "PySide6.QtDataVisualization.Q3DScene.graphPositionQuery(self)->PySide6.QtCore.QPoint",
    "PySide6.QtDataVisualization.Q3DScene.invalidSelectionPoint()->PySide6.QtCore.QPoint",
    "PySide6.QtDataVisualization.Q3DScene.isPointInPrimarySubView(self,point:PySide6.QtCore.QPoint)->bool",
    "PySide6.QtDataVisualization.Q3DScene.isPointInSecondarySubView(self,point:PySide6.QtCore.QPoint)->bool",
    "PySide6.QtDataVisualization.Q3DScene.isSecondarySubviewOnTop(self)->bool",
    "PySide6.QtDataVisualization.Q3DScene.isSlicingActive(self)->bool",
    "PySide6.QtDataVisualization.Q3DScene.primarySubViewport(self)->PySide6.QtCore.QRect",
    "PySide6.QtDataVisualization.Q3DScene.secondarySubViewport(self)->PySide6.QtCore.QRect",
    "PySide6.QtDataVisualization.Q3DScene.selectionQueryPosition(self)->PySide6.QtCore.QPoint",
    "PySide6.QtDataVisualization.Q3DScene.setActiveCamera(self,camera:PySide6.QtDataVisualization.Q3DCamera)",
    "PySide6.QtDataVisualization.Q3DScene.setActiveLight(self,light:PySide6.QtDataVisualization.Q3DLight)",
    "PySide6.QtDataVisualization.Q3DScene.setDevicePixelRatio(self,pixelRatio:float)",
    "PySide6.QtDataVisualization.Q3DScene.setGraphPositionQuery(self,point:PySide6.QtCore.QPoint)",
    "PySide6.QtDataVisualization.Q3DScene.setPrimarySubViewport(self,primarySubViewport:PySide6.QtCore.QRect)",
    "PySide6.QtDataVisualization.Q3DScene.setSecondarySubViewport(self,secondarySubViewport:PySide6.QtCore.QRect)",
    "PySide6.QtDataVisualization.Q3DScene.setSecondarySubviewOnTop(self,isSecondaryOnTop:bool)",
    "PySide6.QtDataVisualization.Q3DScene.setSelectionQueryPosition(self,point:PySide6.QtCore.QPoint)",
    "PySide6.QtDataVisualization.Q3DScene.setSlicingActive(self,isSlicing:bool)",
    "PySide6.QtDataVisualization.Q3DScene.viewport(self)->PySide6.QtCore.QRect",
    nullptr}; // Sentinel

void init_Q3DScene(PyObject *module)
{
    _Sbk_Q3DScene_Type = Shiboken::ObjectType::introduceWrapperType(
        module,
        "Q3DScene",
        "Q3DScene*",
        &Sbk_Q3DScene_spec,
        &Shiboken::callCppDestructor< ::Q3DScene >,
        SbkPySide6_QtCoreTypes[SBK_QOBJECT_IDX],
        0,
        0);
    auto *pyType = Sbk_Q3DScene_TypeF(); // references _Sbk_Q3DScene_Type
    InitSignatureStrings(pyType, Q3DScene_SignatureStrings);
    SbkObjectType_SetPropertyStrings(reinterpret_cast<PyTypeObject *>(_Sbk_Q3DScene_Type), Sbk_Q3DScene_PropertyStrings);
    SbkPySide6_QtDataVisualizationTypes[SBK_Q3DSCENE_IDX]
        = Sbk_Q3DScene_TypeF();

    // Register Converter
    SbkConverter *converter = Shiboken::Conversions::createConverter(Sbk_Q3DScene_TypeF(),
        Q3DScene_PythonToCpp_Q3DScene_PTR,
        is_Q3DScene_PythonToCpp_Q3DScene_PTR_Convertible,
        Q3DScene_PTR_CppToPython_Q3DScene);

    Shiboken::Conversions::registerConverterName(converter, "Q3DScene");
    Shiboken::Conversions::registerConverterName(converter, "Q3DScene*");
    Shiboken::Conversions::registerConverterName(converter, "Q3DScene&");
    Shiboken::Conversions::registerConverterName(converter, typeid(::Q3DScene).name());
    Shiboken::Conversions::registerConverterName(converter, typeid(::Q3DSceneWrapper).name());


    Shiboken::ObjectType::setTypeDiscoveryFunctionV2(Sbk_Q3DScene_TypeF(), &Sbk_Q3DScene_typeDiscovery);

    PySide::Signal::registerSignals(Sbk_Q3DScene_TypeF(), &::Q3DScene::staticMetaObject);
    Shiboken::ObjectType::setSubTypeInitHook(Sbk_Q3DScene_TypeF(), &PySide::initQObjectSubType);
    PySide::initDynamicMetaObject(Sbk_Q3DScene_TypeF(), &::Q3DScene::staticMetaObject, sizeof(Q3DSceneWrapper));
}
