×

Discussion Board

Results 1 to 9 of 9
  1. #1
    Regular Contributor
    Join Date
    Jul 2007
    Posts
    151

    How to get image from camera

    Hi, all
    I want to get image from camera when the camera opening that i don't call the captureImage function(likes meescan application). I used qml camera. Is there any method?
    Or, if qml can not support this, is QCamera support? How should i do?
    Keep Smiling To Life!

    Dynasty1215

  2. #2
    Nokia Developer Moderator
    Join Date
    Mar 2003
    Location
    Lempäälä/Finland
    Posts
    29,169

    Re: How to get image from camera

    quick searching landed me at: http://doc.qt.nokia.com/qtmobility/d...ve-camera.html so next time you could speed up your development by simple searching as well.

  3. #3
    Regular Contributor
    Join Date
    Jul 2007
    Posts
    151

    Re: How to get image from camera

    Thx, @symbianyucca
    I saw the example. But ,I think it is not useful for me.
    I want get the image "auto"(not call the captureImage() function) from the camera.
    I don't find any info about this.
    I download a application "MeeScan" from the Nokia Ovi Store, the app achieve this. It can open the camera, it has any user interaction. but it can get a barcode image, and then can decode the image.
    I want to achieve that result.
    Plz give me some help. Thx
    Keep Smiling To Life!

    Dynasty1215

  4. #4
    Registered User
    Join Date
    Oct 2010
    Posts
    256

    Re: How to get image from camera

    The way the video frame is handled in N9/50, makes the effect that MeeScan uses (real time) a bit tricky to achieve. It involves UYVY to RGB16 conversion among other things (the only supported frame format is QVideoFrame::Format_UYVY). (Thou, I remember reading somewhere that the automatic conversion can be enabled, but good performace is achived only with certain resolutions, and there is no documentation. This is something that I read, I have not tested it!). Do some googling...

  5. #5
    Nokia Developer Moderator
    Join Date
    Mar 2003
    Location
    Lempäälä/Finland
    Posts
    29,169

    Re: How to get image from camera

    Basically you don't need user action to call a function, you woulkd basically need to make your own logic for taking the image automatically. And start the logic when the application starts..

  6. #6
    Regular Contributor
    Join Date
    Jul 2007
    Posts
    151

    Re: How to get image from camera

    @jetrix74
    You says may be right. But that is complex. I tried it , not sucessed.
    @symbianyucca
    You says the logic means application call the captureImage() function auto(likes used a timer), then i can access the image from camera?
    If you mean is this, it don't conform my requirement.
    I want to the camera likes a video out put , the camera don't stop or pause, in this case, i obtain the image from camera.
    Give some help?
    Keep Smiling To Life!

    Dynasty1215

  7. #7
    Nokia Developer Moderator
    Join Date
    Mar 2003
    Location
    Lempäälä/Finland
    Posts
    29,169

    Re: How to get image from camera

    Yep, when you are making applications, you are actually required to do some programming. As well as you need to check the documentations of the APIs you are thinking of using to see whether they fit your requirements. and if you are not sure, you need to test the API. this is called R&D which means Research & development.

    So please try what has been suggested, and if you face problems, then ask help for the detailed issues.

  8. #8
    Regular Contributor
    Join Date
    Jul 2007
    Posts
    151

    Re: How to get image from camera

    Hi, I used the QAbstractVideoSurface to solved it. I had some problmes below
    1.
    If i used
    surface = new myVideoSurface();
    camera->setViewfinder(surface);

    QVideoRendererControl control = qobject_cast<QVideoRendererControl>(camera_->service()->requestControl(“com.nokia.Qt.QVideoRendererControl/1.0”));

    the control is not null, call control->setSurface(surface);
    then the framework can call the supportedPixelFormats start function
    But that not display anything on the screen; and there are errors:
    Failed to start video surface
    Internal data flow error

    2.If i used
    viewfinder = new QCameraViewfinder();
    viewfinder->show();
    camera_->setViewfinder(viewfinder);
    the screen display the camera’s graphics
    But then call
    QVideoRendererControl control = qobject_cast<QVideoRendererControl>(camera_->service()->requestControl(“com.nokia.Qt.QVideoRendererControl/1.0”));
    the control is null.
    that the framework not call the supportedPixelFormats start function.

    Have othres have the same problem? plz give helps.
    Thx.
    Keep Smiling To Life!

    Dynasty1215

  9. #9
    Registered User
    Join Date
    Oct 2010
    Posts
    256

    Re: How to get image from camera

    Have you read this?: http://qt-project.org/forums/viewthread/8375/#49400 (notice the license type of the conversion code snipped if you decide to go for it (qgraphicsvideoitem_maemo5.cpp))

Similar Threads

  1. Replies: 8
    Last Post: 2012-02-16, 09:40
  2. Camera Wrapper library Face camera capture image reversed
    By waelfarouk in forum Symbian Media (Closed)
    Replies: 1
    Last Post: 2011-05-13, 18:10
  3. over lay image on camera
    By izeko in forum Mobile Java General
    Replies: 2
    Last Post: 2010-12-08, 08:38
  4. Failed to get image from camera - N95
    By prchakal in forum Symbian
    Replies: 2
    Last Post: 2010-05-22, 06:14
  5. the best way to get an image from the camera
    By s4028469 in forum Symbian Media (Closed)
    Replies: 10
    Last Post: 2007-08-30, 10:13

Posting Permissions

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