×

Discussion Board

Results 1 to 4 of 4
  1. #1
    Registered User
    Join Date
    May 2011
    Posts
    9

    Question JSR 234: Not able to set autofocus

    Hi,

    I am using JSR 234 and hardware is N97mini.

    Creating a sample camera application and want to set auto-focus. just followed the JSR 234 documentation coming with the sdk. the code snippet is as below:

    Player p;
    CameraControl cameraControl;
    FocusControl focusControl;
    // Use autofocus if it is available:
    focusControl = (FocusControl) // always getting focuscontrol as NULL
    p.getControl("javax.microedition.amms.control.camera.FocusControl");
    if(focusControl != null) {
    if(focusControl.isAutoFocusSupported()) {
    try {
    focusControl.setFocus(FocusControl.AUTO);
    } catch(MediaException e) {
    //Shouldn't happen.
    }
    }
    }
    else
    {
    //control comes here as focuscontrol is set as null

    }


    the problem is :
    focusControl = (FocusControl) p.getControl("javax.microedition.amms.control.camera.FocusControl");
    after above call focuscontrol is set as NULL.


    can anybody help me to fix this issue.

  2. #2
    Super Contributor
    Join Date
    Apr 2003
    Location
    USA, CA
    Posts
    7,191

    Re: JSR 234: Not able to set autofocus

    N97 Mini does not support camera features of the AMMS API
    https://www.developer.nokia.com/Devi...ions/N97_mini/
    In fact none of the Nokia Symbian phones support that

    Hartti

  3. #3
    Registered User
    Join Date
    May 2011
    Posts
    9

    Re: JSR 234: Not able to set autofocus

    Thank you Hartti,

    so does it means i can't develop a camera app with autofocus enabled for Symbian devices?
    Can you please suggest the device family i can target.
    My application requires autofocus enabled.

    Regards,
    Indela

  4. #4
    Super Contributor
    Join Date
    Apr 2003
    Location
    USA, CA
    Posts
    7,191

    Re: JSR 234: Not able to set autofocus

    On Symbian phones you are better of using Qt / Symbian C++ for this project. You have much better control of the camera hardware that way.

    If you want to use Java ME, there are a number of Series 40 phones which support that API. You can either check that through the expert search of device specifications or see the correct platform version from here
    http://www.developer.nokia.com/Commu..._Nokia_devices

    Hartti

Similar Threads

  1. Not able to set custom image as container's skin
    By pooja_1650 in forum Symbian
    Replies: 0
    Last Post: 2009-08-15, 22:29
  2. Replies: 5
    Last Post: 2009-08-11, 10:12
  3. Not able to set the created SMS date ..
    By keerthi.ck06 in forum Symbian
    Replies: 10
    Last Post: 2009-05-22, 14:26
  4. Not able to set Gauge on Alert
    By sandeep.gadhvi1185 in forum Mobile Java General
    Replies: 2
    Last Post: 2008-07-22, 14:30
  5. using JSR 234 and not getting the display
    By abirb in forum Mobile Java General
    Replies: 3
    Last Post: 2008-02-15, 18:56

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
×