Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 3272196
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 17, 20262026-05-17T18:48:05+00:00 2026-05-17T18:48:05+00:00

I’m using the phone’s camera in an Android app to take a photo. I’m

  • 0

I’m using the phone’s camera in an Android app to take a photo. I’m using Intents to use the built-in camera application and I’m using the following code:

Intent intent = new Intent("android.media.action.IMAGE_CAPTURE");
intent.putExtra(MediaStore.EXTRA_OUTPUT, Uri.fromFile(new File(FILEPATH)));
startActivityForResult(intent, ACTIVITY_NATIVE_CAMERA_AQUIRE);

It works fine and the camera is brought up. I can take a photo and the phone presents me with three options: Cancel, Retake, OK. The first two work, pressing cancel returns the user to the app, but pressing OK and nothing happens. Apparently onActivityResult isn’t being called, and the camera just stays on the screen. Nothing in the debugger either.

Running the app on a Nexus One with Android 2.2.1. Same problem on the emulator running Android 2.0.

Edit: Tested on a HTC Desire running Android 2.2 with HTC’s Sense UI: works perfectly. Nothing on the emalator nor Google N1.

Edit2: It seems that the HTC Desire image aquiring activity works better in the sense that it does return, but it disregards the EXTRA_OUTPUT -setting and returns only a small image in the onActivityResult -call. Checking on the ddms console while the phone is hooked to the computer I see that the phone is storing the image on the SD card, but the path is not passed back to my application. It is starting to look like there is no reliable way to use the camera intent, and get back a reasonably-sized image. Bad, bad, bad.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-17T18:48:06+00:00Added an answer on May 17, 2026 at 6:48 pm

    After a bit of research, testing and sheer luck I managed to solve this issue.

    If the EXTRA_OUTPUT -option for the Intent contains a file URI that points to the internal memory of the device, the call will fail. How it fails, depends on the device. The HTC Desire works ok on the surface, but fails to return the full-sized image. Google N1 on the other hand refuses to leave from the camera activity.

    When I changed the file URI to point to the memory card, it worked perfectly for both the Desire and Google N1.

    So summing it up: the path to store the full sized image MUST point to the SD card.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I am using Paperclip to handle profile photo uploads in my app. They upload
I'm using v2.0 of ClassTextile.php, with the following call: $testimonial_text = $textile->TextileRestricted($_POST['testimonial']); ... and
We're building an app, our first using Rails 3, and we're having to build
I ran into a problem. Wrote the following code snippet: teksti = teksti.Trim() teksti
I'm new to using the Perl treebuilder module for HTML parsing and can't figure
That's pretty much it. I'm using Nokogiri to scrape a web page what has
link Im having trouble converting the html entites into html characters, (&# 8217;) i
I am trying to understand how to use SyndicationItem to display feed which is
I am reading a book about Javascript and jQuery and using one of the
I have a string like this: La Torre Eiffel paragonata all’Everest What PHP function

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.