static PyObject *meth_QCameraFocus_setFocusPointMode(PyObject *sipSelf, PyObject *sipArgs)
{
    PyObject *sipParseErr = NULL;

    {
        QCameraFocus::FocusPointMode a0;
        QCameraFocus *sipCpp;

        if (sipParseArgs(&sipParseErr, sipArgs, "BE", &sipSelf, sipType_QCameraFocus, &sipCpp, sipType_QCameraFocus_FocusPointMode, &a0))
        {
            sipCpp->setFocusPointMode(a0);

            Py_INCREF(Py_None);
            return Py_None;
        }
    }

    /* Raise an exception if the arguments couldn't be parsed. */
    sipNoMethod(sipParseErr, sipName_QCameraFocus, sipName_setFocusPointMode, doc_QCameraFocus_setFocusPointMode);

    return NULL;
}
示例#2
0
void CameraControl::setupCamera(QCamera * camera)
{
    this->camera = camera;

    QCameraFocus * focus = camera->focus();
    focus->setFocusMode(QCameraFocus::ContinuousFocus);
    focus->setFocusPointMode(QCameraFocus::FocusPointAuto);

    camera->imageProcessing()->setWhiteBalanceMode(QCameraImageProcessing::WhiteBalanceAuto);
    camera->setCaptureMode(QCamera::CaptureViewfinder);

    QCameraExposure * exposure = camera->exposure();
    exposure->setExposureMode(QCameraExposure::ExposureAuto);
    exposure->setExposureCompensation(0);
    exposure->setMeteringMode(QCameraExposure::MeteringSpot);

    imageCapture = new QCameraImageCapture(camera, this);

    connect(imageCapture, SIGNAL(imageSaved(int, QString)), this, SLOT(onSavedImageCaptured(int, QString)));

    //camera->load();
    //camera->start();
}
static PyObject *meth_QCameraFocus_zoomTo(PyObject *sipSelf, PyObject *sipArgs)
{
    PyObject *sipParseErr = NULL;

    {
        qreal a0;
        qreal a1;
        QCameraFocus *sipCpp;

        if (sipParseArgs(&sipParseErr, sipArgs, "Bdd", &sipSelf, sipType_QCameraFocus, &sipCpp, &a0, &a1))
        {
            sipCpp->zoomTo(a0,a1);

            Py_INCREF(Py_None);
            return Py_None;
        }
    }

    /* Raise an exception if the arguments couldn't be parsed. */
    sipNoMethod(sipParseErr, sipName_QCameraFocus, sipName_zoomTo, doc_QCameraFocus_zoomTo);

    return NULL;
}
static PyObject *meth_QCameraFocus_setCustomFocusPoint(PyObject *sipSelf, PyObject *sipArgs)
{
    PyObject *sipParseErr = NULL;

    {
        const QPointF* a0;
        int a0State = 0;
        QCameraFocus *sipCpp;

        if (sipParseArgs(&sipParseErr, sipArgs, "BJ1", &sipSelf, sipType_QCameraFocus, &sipCpp, sipType_QPointF, &a0, &a0State))
        {
            sipCpp->setCustomFocusPoint(*a0);
            sipReleaseType(const_cast<QPointF *>(a0),sipType_QPointF,a0State);

            Py_INCREF(Py_None);
            return Py_None;
        }
    }

    /* Raise an exception if the arguments couldn't be parsed. */
    sipNoMethod(sipParseErr, sipName_QCameraFocus, sipName_setCustomFocusPoint, doc_QCameraFocus_setCustomFocusPoint);

    return NULL;
}