[Solved]fix digital zoom on maemo5 gdigicam camerabin



  • Hi
    I am using gdigicam api to access the camera of the maemo5 device and take a picture..
    I require that the digital zoom be fixed to a particular level...
    For that I am writing the following code
    @
    GDigicamCamerabinZoomHelper *z_helper=g_slice_new(GDigicamCamerabinZoomHelper);
    z_helper->value=3;
    gboolean digital=0;
    if(!g_digicam_manager_set_zoom(manager,z_helper->value,&digital,NULL,z_helper))
    qDebug() << "Unable to set zoom level";
    @

    This is inside the function where I initialize the gstreamer bin..
    Then I play the bin in a later function after checking whether the shutter (in case of n900) is open or closed
    The problem is that the zoom aint working

    This is surprising because similar kind of code I used to lock the autofocus when the camera shutter button is half pressed and it works perfect including all the other settings like exposure compensation and flash mode....
    @
    void StillCam::setLock(GDigicamLock lock) {
    qDebug() << "In set lock function.";
    GDigicamCamerabinLocksHelper *helper=g_slice_new(GDigicamCamerabinLocksHelper);

    helper->locks=lock;
    
    if(!g_digicam_manager_set_locks(manager,helper->locks,NULL,helper)) {
        qDebug() << "Error: unabble to set lock";
    
    }
    g_slice_free(GDigicamCamerabinLocksHelper,helper);
    

    }
    @

    PLEASE HELP!!



  • It is now working... I had accidentally used a non static slot for g_signal_connect wherein i was manipulating the zoom.....
    Making the slot static did the trick ;)


Log in to reply
 

Looks like your connection to Qt Forum was lost, please wait while we try to reconnect.