Menu

Open Camera Image Orientation

Dinesh
2014-07-24
2014-07-29
  • Dinesh

    Dinesh - 2014-07-24

    Hi everyone!

    I am using opencamera source for my android project. and its perfect to use.

    1) But while i am taking pictures, the orientation is getting changed automatically. And also this is not happening always. Sometimes it takes the picture correctly. I need to read the characters in the image by OCR. Since the orientation changes, the OCR cannot done. Kindly advise where exactly the orientation is set in the source code.

    2)And also kindly provide an idea about image view & edit after image taken by opencamera. If i call the default gallery app by using "intent.setAction(Intent.ACTION_EDIT);",
    i cannot able to get the image uri of the edited image. Is there any possible way to get the image back?

    Thanks in advance.

     
    • Mark

      Mark - 2014-07-25
      1. There's a call to parameters.setRotation(current_rotation); in Preview.takePictureWhenFocused() which controls the orientation of the resultant photo.

      2. If in MainActivity.clickedGallery() I set REVIEW_ACTION to Intent.ACTION_EDIT, it launches a photo editor allowing me to edit the last photo taken. Or if you mean getting a URI of the image after editing, I'm not sure. Theoretically it should still be the most recent image/video, so doing the method in MainActivity.clickedGallery() to obtain the most recent URI may work, but I don't know if there's a more direct way.

       
  • Anonymous

    Anonymous - 2014-07-25

    Whats your android project? Where do you plan to publish it
    ?

     
  • Dinesh

    Dinesh - 2014-07-29

    My Project is to take the pictures through a camera and to edit the the image by cropping and to read the characters in the cropped images by OCR.

     

Anonymous
Anonymous

Add attachments
Cancel