61 questions
0
votes
0
answers
70
views
How can I take and save a picture from command line on android?
Basically... I am writing a script on termux(in case you don't know it, it would be basically the same than a script for adb) and I need to take and store a photography. I tried to start "android....
0
votes
0
answers
75
views
Why is android.media.action.IMAGE_CAPTUR not saving the picture?
:)
Basically I am writing a termux bash script to take care of my purchases in real life. And rn I am trying to automatically ask for a photo of a grocery ticket if the program detects the purchase ...
1
vote
1
answer
344
views
Accessing Camera inside WebView not working
I am using an onfido link inside webView for accessing camera, I have granted the permissions but the camera is not working and giving logs as "Access denied finding property 'vendor.camera.aux....
2
votes
1
answer
166
views
Launching ACTION_IMAGE_CAPTURE intent on Galaxy Tab 2 running Android 9 shows normal camera, with no accept / reject buttons
I'm doing some maintenance on an internal app that is run on a fleet of old Galaxy Tab 2 devices running Android 9. The app has some basic code that does a plain vanilla launch of the ...
0
votes
1
answer
543
views
I am capturing an image using CameraX in android on button click, but in some phones the captured image is rotated. Why so and how to correct it?
I am capturing the image to transform it into a square of a certain size. When I capture an image using different phones, in some of them the image captured is the same as the image shown in the ...
1
vote
1
answer
1k
views
Jetpack compose not showing bitmap image for very high quality image
When image bitmap is low quality I am able to load and display the image with coil but when image bitmap is very high quality the screen doesn't show anything and pressing back lets to crash the app.
...
0
votes
1
answer
1k
views
Image quality is very low after capture with camera in jetpack compose
I am making this camera app where I take the picture and upload to server. But after captured image that I am getting very low quality. Can we specify the image quality here?
val cameraLauncher = ...
3
votes
1
answer
632
views
CapturePhotoAsync function on Xamarin Forms works well on emulator but rotates images on debugging with actual device
The Xamarin Essentials MediaPicker function to capture with camera using the CapturePhotoAsync runs correctly on the emulator but behaves differently when a mobile phone is connected to debug the ...
0
votes
0
answers
78
views
android capture image from camera and display in another activity
I want to capture image on button click and display the same image in another activity. The below code is capturing image but displaying in the same activity. How can I take image to next activity? ...
0
votes
1
answer
125
views
ImageCapture cameraX orientation detect when is locked
I want to capture an Image and a Video using the CameraX library. By following the documentation i have no problem implementing the preview and the capture use cases. The code i use is the following.
...
1
vote
2
answers
2k
views
Android Image Capture action (aka ActivityResultContracts.TakePicture()) always returns landscape photos
I am trying to capture photos in my app using standard camera app intent (I am NOT interested in using JetpackX or other library to have a viewfinder in my app).
When I had the code in my Fragment ...
2
votes
0
answers
129
views
Taking photos and videos in app and sending the data between app components
This question is a bit on the broader side of things so I will not provide any specific code because it will be irrelevant.
I have an app that allows the user to take photos, and hopefully videos in ...
0
votes
0
answers
605
views
Activity Result APIs (TakePicture() camera): Failure delivering result ResultInfo (App Crash)
I have been struggling with the issue of having my activity being destroyed sometimes while taking a picture with the camera app., resulting in the below error and an app crash.
java.lang....
0
votes
0
answers
149
views
Android Landscape mode bug after Image capture
I found that on some devices the app gets bugged after taking a photo in landscape mode. My App is designed to be only in the vertical (portrait) mode, this is stated both in the manifest and in the ...
0
votes
0
answers
165
views
Android Image capture using URI and upload to MySQL database via PHP
I have made an android app to capture image from the default camera, and then compress it using bitmap.compress() and then upload it to my MySQL database using PHP. Now the issue is, using Bitmap I ...
0
votes
0
answers
403
views
Android App crash due to Image capture only in specific devices(One plus 6T)
I am building an Android app that includes collecting customer data in different categories ,in different screeens(Activities). The data entered by the user(all input fields) are stored in Global ...
3
votes
0
answers
2k
views
Write a photo taken from camera using MediaStore.ACTION_IMAGE_CAPTURE to external storage on Android 11
I'm trying to take a photo using Intent(MediaStore.ACTION_IMAGE_CAPTURE) and save it to the external cache. Before starting the Activity I ask for CAMERA, READ_EXTERNAL_STORAGE, WRITE_EXTERNAL_STORAGE ...
1
vote
0
answers
275
views
Failure delivering result ResultInfo{who=null, request=65538, result=-1, data=null} to activity
This is my line code that I use to save pictures from camera and gallery on device:
Camera Intent:
private void abrirCamera() {
ContentValues values = new ContentValues();
image_uri = ...
0
votes
1
answer
578
views
How to get ISO and Exposure time of captured photo with Android CameraX?
I use Android CameraX in my application for taking photos. When I capture a photo, I can either use the ImageCapture.OnImageCapturedCallback or the ImageCapture.OnImageSavedCallback according to the ...
4
votes
0
answers
1k
views
How to make copy of android.media.Image object?
I need to make a copy of "android.media.Image" object for a solution, but since the class is defined abstract we can not make instances of it ourselves.
I am getting my instance of this ...
0
votes
0
answers
52
views
How to save on Camera Photo on Custom Location?
I am currently using the following code here:
val cameraRequestCode = 1
val cameraPermissionCode = 1
var imageUri : Uri? = null
@RequiresApi(api = Build.VERSION_CODES.M)
override fun onActivityResult(...
4
votes
3
answers
1k
views
Windows photo viewer does not open bitmap compressed images from Android studio
I am using android custom camera to captured JPG images, But not able to preview them on windows photo viewer. Can anyone please advise. Images are visible using other applications like Ms Paint, ...
1
vote
0
answers
3k
views
Capture CameraX preview frame to Bitmap
I am trying to have a workaround with Google's Camera API - CameraX, because older devices do not support multiple use cases (ImageCapture and VideoCapture).
So i want to take a picture capturing ...
1
vote
1
answer
4k
views
Android Q: Intent(MediaStore.ACTION_IMAGE_CAPTURE) - No Activity found to handle Intent
I am trying to implement taking a photo from a camera on a project that targets Android Q.
From what I have found, I have implemented this:
val mediaFile = mediaManager.createImageFile() // creates a ...
0
votes
0
answers
237
views
ImageFile Found Null in One Plus Device While Capture Image From Camera
I'm trying to get an Image from the Camera and external storage. Then Send it to crop then save the image on the server. Other devices like Note 7 Pro and Samsung -G920F works fine with this code But ...
1
vote
2
answers
613
views
Android image capture, how to get the lowest quality picture to take less space
I am using Android's default camera to capture my intent. The images that come out are of really good quality and I cannot seem to find a way to lower the quality of the images.
Is that even possible ...
0
votes
1
answer
2k
views
File.createTempFile() adding random strings to file name
I am facing an issue which I do not understand. I am taking a picture then creating a PNG image file as per code that follows but somewhere down the line a random string is being added to the filename ...
1
vote
0
answers
241
views
Multiple images/pictures in onActivityResult
I have 2 buttons:
on 1 button I can take pictures
on the other button I can select pictures from the gallery.
The problem is when I take a picture it is displaying it, but when I take a another ...
1
vote
0
answers
96
views
Error while exiting the Camera2BasicFragment (Android custom camera using Camera2 API) to display captured image in next activity
I've used the sample code from Google to implement a custom camera using Camera2 API. I want to display the captured image in the next activity.
Camera2Basic sample code
However, I'm unable to ...
0
votes
1
answer
444
views
Camera2 api clicks multiple images on single click
I am using camera2 api to capture images in my android application. When i am clicking on button to capture image it clicks multiple images on just one click. This issue happens only on few devices. ...
0
votes
1
answer
1k
views
Glide couldn't load image that is capturing from camera in some android devices
In my android application , i am capturing image from camera and load it with glide. In some devices it is working properly but some devices like LG Q6 , MI note 4 it doesn't load properly. Please ...
1
vote
1
answer
595
views
Android-Image-Cropper Permission READ/WRITE_EXTERNAL_STORAGE issue
I'm using the library Android-Image-Cropper (which is great!) and there's something I can't quite understand.
I'm using the library for profile picture add/update using camera of from local ...
0
votes
1
answer
352
views
WebRTC picture capturing doesn't work on smartphones
I'm trying to get an image capture from the front or back camera of my smartphone using the WebRTC. I used one of WebRTC samples for that. This code works perfectly in browsers on the computer, but on ...
0
votes
0
answers
255
views
capture image from camera is not working only in android marshmallow otherwise its working fine in all latest or older versions
I am trying to capture image from camera .i have a code which is working fine all the devices except android marshmallow device. which returns the results to gallery recent folder. I have checked ...
1
vote
1
answer
335
views
Google Mobile Vision Low Image Quality
I try to take photo from camera with mobile vision library but taken image's qualities are low (Resolution 240x320)
I don't know where I should modify this feature(I guess it is related with ...
0
votes
2
answers
583
views
Intent object on onActivityreslut goes null on Image capture android
I am trying to set a image as profile picture on image view after capture using camera. image capturing is working fine and image is stored in device memory. But on onActivityResult code intent object ...
1
vote
4
answers
3k
views
Android: "Permission Error" on Capture using Camera
In Android the Camera action show a error:
java.lang.SecurityException: Permission Denial: starting Intent { act=android.media.action.IMAGE_CAPTURE cmp=android/com.android.internal.app....
-2
votes
1
answer
246
views
Unfrotunately app stopped onActivityResult
I am new to android development. This is a test app through which I am trying to invoke an image to my activity. Everything seems fine except when I am returning the camera Image in onACtivityResult()...
1
vote
2
answers
1k
views
ImageReader acquireLastestImage of different resolution than ImageReader itself on Galaxy S6
I'm trying to read an image from an ImageReader set to a particular resolution (obtained from CameraCharacteristics.SCALER_STREAM_CONFIGURATION_MAP of course), but the ImageReader.acquireLastestImage ...
1
vote
1
answer
46
views
Why this code of capturing picture from a device don't run properly?
I was just trying to write a code to capture an image and save that image in default directory with a name test.jpg. My device do capture the image but it runs the else part of the test case and shows ...
0
votes
1
answer
34
views
All vertical oriented images are strangely autorotated only on some devices
I have an app that take pictures from camera or gallery and shows the result in an imageview.
I only get the image with content provider and use this scale function
public Bitmap scaleim(Bitmap ...
0
votes
4
answers
487
views
In Multi Image Selector OnActivityResult() method is not getting called in Fragment
I am trying to make image selector for application.For that i am using multi-image-selector library which is perfeclty works when used in activity ,but here i want to use it in fragment.so in fragment ...
0
votes
1
answer
706
views
Android how to set the layout the same size of an imageview programmatically
I have two imageView size an relativelayout. Both images will be loaded programmatically and I want to set the size of the relativelayout equal to the size of imgBackground. How can I do that? I tried ...
0
votes
1
answer
452
views
Take a picture and get bytes without saving on disk
Is it possible to take a picture and get the image as byte array without saving it?
All I want is, take an in memory picture. I don't want to save it. Also i plan to use other camera activity to take ...
0
votes
0
answers
52
views
why custom camera capturing a portion of the screen?
Hi I am using custom camera view in my application, It was working fine in some devices, but in 1+3t device it's capturing only a portion of the screen.
I've searched a lot but couldn't get the answer....
1
vote
3
answers
6k
views
android: FATAL EXCEPTION: java.lang.SecurityException: Permission Denial: starting Intent { act=android.media.action.IMAGE_CAPTURE
I have tried everything I could find by researching. Nothing is working. I have an Activity with a FragmentDialog. In this dialog, I have an image view with a button. When this button is pressed, an ...
1
vote
4
answers
2k
views
onActivityResult returns null Intent
I am trying to capture image from camera. But it returns null Intent onActivityResult .
Here is my code
CaptureImageFromCamera.setOnClickListener(new View.OnClickListener() {
@Override
...
0
votes
4
answers
3k
views
How to configure ACTION_IMAGE_CAPTURE to store the photo in public external storage?
The Taking Photos Simply Documentation recommends to store image taken with device camera as "should be saved on the device in the public external storage". But how to do this? The provided example ...
0
votes
0
answers
33
views
How can I differentiate if a picture is made fron the internal or external camera
Hello I am trying to make an app and I need to differentiatie if a photo has been tanken forn the internal or external camera of my smartphone. I need this because my smartphone rotates the photos in ...
3
votes
4
answers
4k
views
Open Default Camera App Without Using action.Image_Capture
I want the user to be able to quickly open the default camera app (or one they have set as default) in my app. However, I do not want to use android.media.action.IMAGE_CAPTURE, as this will only show ...