-
Notifications
You must be signed in to change notification settings - Fork 876
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
CaptureImage doesn't work most of the time on android #533
Comments
I've the same problem and have noticed it would take a picture if I obstruct the lens with for instance my finger. |
It wouldn't be a good solution, but it doens't work for me anyway. |
Yes, noticing the same...CaptureImage doesnt do anything at least on |
is there a previous version in which you know it did work? I don't mind downgrading for now, my camera request is super simple |
Experiencing same problem. Anyone have forced CameraKit work properly? @Tsabary I also moved from Fotoapparat to CameraKit in hope it will work. (Fotoapparat seems doesn't work on API 17) |
Hey guys, can you be more specific about the versions of CK you are using? This isn't a known widespread issue but obviously is affecting you. We will look into it once we know more! |
build.gradle
Also no errors/info in logcat. No error in CameraKitView.ErrorListener. |
Here are my details
I think the root of a lot of these issues are that the sample app has very deprecated code. Would be nice to have that on V1 |
I am using 3.11 now but the problem still existed when i was on 3.10. I am running my app on the emulator and on a OnePlus 5t. This is how my code is structured:
I've also tried instead of button clicked is always printed, where image captured almost never does (it rarely happens and inly on the emulator). |
Update: as per Murphy's law, things might actually be working for me now. It seems to be more consistent after I've added the empty brackets. I am still running tests but it is deffinitely working much better than it did before. |
Update: it stops working again. I can't get it to be stable. |
I was trying to debug this, but Android Studio claimed that the bytecode didn't match the source code for CameraKitView, so I've cloned branch v1.0.0-beta4, added the camerakit directory to my project and, with some effort, made it build as a subproject just like the demo app does in this repository instead of using the pre-built release. Good news: with the integrated project this works. So my guess is that the published build is out of date. I'm not sure I'd be able to tell you how I did the subproject integration, as it was quite a bit of trial and error (I'm new to Android development), using the gradle files in this repository as reference each time I had an error. |
Same problem here in my Google Pixel 1. I have implemented the captureImage function as instructed and Logcat didn't print anything strange...and that's strange hhhh. |
Same problem |
same problem |
Any insights? Dealing with this too... |
same problem, only with 3.11 |
Here is what I have found while testing on some devices:
Xiaomi Mi A10:
OnePlus 6:
|
same problem, SM-G935FD |
same problem here on Samsung Device ( Tab Active 2) |
Surprisingly enough, adding an errorListener to the CameraKitView has fixed the problem. |
@DarkMinstrel it doesn't seem to work for some devices. |
I have the same Problem. Sometimes it work. But most of the time it doesn't work. |
Same problem here |
Same problem, from MI 6(Android 8.0) |
This problem can be avoided by lowering the version to v1.0.0-beta3.10 |
same problem from oneplus3A and oneplus6 |
the same problem |
same for me. beta3.11 |
and 3.10 same problem. I even cleaned the project, rebuilt it, invalidated the caches and restarted. |
Same problem with implementation 'com.camerakit:camerakit:1.0.0-beta3.11' and kotlin on android 10 it doesn't capture any image. No errors are logged or thrown in listener. Are they working on it or is it discontinued??? |
Downgrading to beta 3.10 solved the issue for me |
Hi, I think it is discontinued, because Google Jetpack has integrated CameraX. So it wouldn't make sense to try to compete with it. CameraX has image analysis on top. I switched |
Downgrading to beta 3.10 solved the issue for me |
Downgrading to beta 3.10 also works for me on RedmiNote7!
|
Worked for me! Oh, happy days! |
worked for me too, Thanks |
Thanks
Thanks Work for me |
In the new version you should activate microphone permissions to take a photo 🤷🏻♂️ |
Is this a bug report?
(write your answer here)
Yes
Have you read the Contributing Guidelines?
Yes
(Write your answer here.)
Environment
Android Studio emulator / OnePlus 5t
Steps to Reproduce
(Write your steps here:)
Expected Behavior
(Write what you thought would happen.)
A photo would be taken
Actual Behavior
(Write what happened. Add screenshots!)
The action doesn't kick in at all. I've entered a few Logs, the first being immedietly after calling to capture image, but whenever that issue exists (which is almost always for me both at the emulator and OnePlus device, that Log never prints.
Reproducible Demo
https://stackoverflow.com/questions/55526362/capture-image-action-only-works-sometimes-without-clear-reason-why
You could see here the relevant part of the code. The log that should print "image captured" almost never prints (and a photo isn't taken). When a photo is taken, the log of course prints, but there is no reasoning behind when it would or wouldn't work. It seems that it is more likely to work on the emulator.
The text was updated successfully, but these errors were encountered: