Questions tagged [android-camera-intent]

Questions related about calling the camera app from the local device, without the camera permission.

The camera intent is a way to make photos or videos with the camera app of the device without implementing a custom camera activity.

Here is a basic example for such a call:

// create Intent to take a picture and return control to the calling application
Intent intent = new Intent(MediaStore.ACTION_IMAGE_CAPTURE);

fileUri = getOutputMediaFileUri(MEDIA_TYPE_IMAGE); // create a file to save the image
intent.putExtra(MediaStore.EXTRA_OUTPUT, fileUri); // set the image file name

// start the image capture Intent
startActivityForResult(intent, CAPTURE_IMAGE_ACTIVITY_REQUEST_CODE);

See the full code on the documentation.

971 questions
6
votes
4 answers

Save clicked images into custom folder(Preferably internal to the app ) instead of gallery

I am trying to incorporate the camera functionality into the application. I am able to save pictures into the custom folder, but the problem is that the images are getting saved into camera folder(where the camera pics get saved) also. So there is a…
Rookie
  • 8,660
  • 17
  • 58
  • 91
6
votes
2 answers

What are some of the Android camera api parameters optimizations for efficiently taking pictures when camera is moved by user?

I am creating an Android app which is sort of like stop-motion app which is intended to efficiently take pictures even during movement. I wanted to set very low shutter speed and high aperture for getting better pictures particularly when camera is…
6
votes
1 answer

How to get Image Path just captured from camera

below is my code but is not give me image path in onActivity result Uri selectedImageUri = data.getData(); selectedImagePath = getPath(selectedImageUri); Log.w("jay", "Camera Image Path :" + selectedImagePath); …
Jaykumar Donga
  • 380
  • 1
  • 3
  • 18
6
votes
1 answer

Camera intent for ACTION_IMAGE_CAPTURE does not appear on Samsung Galaxy Nexus(4.0.2)

I use following code take a Picture from camera and to obtain picture's path. ... Intent cameraIntent = new Intent(android.provider.MediaStore.ACTION_IMAGE_CAPTURE); startActivityForResult(cameraIntent, CAMERA_IMAGE_CAPTURE); // image…
tesk_terrus
  • 63
  • 1
  • 1
  • 4
5
votes
1 answer

Android how to set captured video to .mp4 instead of .3gp

I'm using the default camera to capture video: Intent intent = new Intent(MediaStore.ACTION_VIDEO_CAPTURE); intent.putExtra(MediaStore.EXTRA_VIDEO_QUALITY,…
TOMKA
  • 1,096
  • 13
  • 24
5
votes
1 answer

stop saving image when open camera using Intent through from my application

possible duplicate Stop saving photos using Android native camera Hello everyone, I am open camera using Intent through like this way Intent cameraIntent = new Intent(MediaStore.ACTION_IMAGE_CAPTURE); startActivityForResult(cameraIntent,…
Pratik
  • 30,639
  • 18
  • 84
  • 159
5
votes
1 answer

android picture from camera being taken at a really small size

Im trying to capture an image from the camera, compress it, then store it to the SD card. If I directly save it to the SD card using the code directly below, I get the full image. But if i try and load the image in the system, i get a super small…
jfisk
  • 6,125
  • 20
  • 77
  • 113
5
votes
1 answer

App crashes when launching camera to take picture on Redmi 7A

My app automatically crashes when I launch camera to take picture on Redmi 7A. Following are the crash logs: E/CAM_CameraIntentManager: checkCallerLegality: Unknown caller: com.qikcircle.eclinic Please help it really does not show what exactly…
5
votes
1 answer

How to save photo Camera-App in Public directory

I would like to achieve the following: From MyApp, start the phone's Camera app via an intent Phone's Camera app saves photo in a public directory (DCIM or DCIM/Camera) Saved photo has a filename of my choosing. Saved photo is available in Gallery…
Ivo Renkema
  • 2,188
  • 1
  • 29
  • 40
5
votes
2 answers

Not able to find solution for detecting camera button for different devices in Espresso script to be run on Firebase Test Lab

I have to create a script using Espresso to test my app in Firebase test lab. My app uses Camera to capture images and I have opened the default camera app. For testing on my device I give package name for the testing device that I am using. The…
5
votes
4 answers

Using camera to take photo and save to gallery

I have went through several documentation and stacks, however I'm not quite sure how do I implement this... And help or sample codes would really help me understand more. Here are the sets of codes that runs the camera and it's working perfectly…
user6487002
5
votes
3 answers

intent.resolveActivity() is NULL on a device with the camera (4.2.2)

Using this piece of code is suggested and it states Notice that the startActivityForResult() method is protected by a condition that calls resolveActivity(), which returns the first activity component that can handle the intent. Performing this…
sandalone
  • 41,141
  • 63
  • 222
  • 338
5
votes
2 answers

Android: take camera picture intent remove confirmation dialog

it's possible to disable/remove this photo confirmation dialog: I need somehow skip this dialog but I still want use an Intent. I found this android: Take camera picture without "save" / "delete" confirmation but I don't want use SurfaceView .
5
votes
3 answers

Android camera intent should not allow to save the image to gallery and store it in specified path

when i use this code -> Intent cameraIntent = new Intent(android.provider.MediaStore.ACTION_IMAGE_CAPTURE); cameraIntent.putExtra(MediaStore.EXTRA_OUTPUT, uri); I am able to save the image to specified path but it is also saving to the…
Umakant Angadi
  • 79
  • 2
  • 10
5
votes
1 answer

How to lock the orientation to Portrait when using intent ACTION_IMAGE_CAPTURE?

I know I can set the orientation of the activity in the manifest, but when this activity is calling the MediaStore.ACTION_IMAGE_CAPTURE to open the camera and take a photo, the user can still take photos in landscape mode. Can I lock the orientation…
Apostrofix
  • 2,140
  • 8
  • 44
  • 71