Camera X in Java | Image Capture, Video Capture, Image Analysis

  Рет қаралды 40,711

Coding Reel

Coding Reel

Күн бұрын

Пікірлер: 58
@CodingReel
@CodingReel 3 жыл бұрын
Code is available at: github.com/Faisal-FS/CameraX-In-Java
@pepeg_4542
@pepeg_4542 2 жыл бұрын
This code is not the same as the one in the video
@etzumahkaya9583
@etzumahkaya9583 Жыл бұрын
code show anything
@vogu508
@vogu508 2 жыл бұрын
you are the only person on youtube maybe the entire internet who is giving out a very clear explanation for video capture in camerax in java. I thank you. I am not sure how good this will be in production and the log seems to have weird things that might become a problem later, but thats google/android's problem they have to figure out.
@sharpcooking6694
@sharpcooking6694 3 жыл бұрын
after a several hours search I found the right video for image analysis use case, thanks for this one
@CodingReel
@CodingReel 3 жыл бұрын
Glad it was helpful!
@hitesh2293
@hitesh2293 2 жыл бұрын
how are you accessing camera without permissions , like i tried the same code you have given but my app is showing me a black screen instead of cameraview
@CodingReel
@CodingReel 2 жыл бұрын
I have given the permissions manually from App info, permissions implementation is not covered in this one. As the main aim of this video is to show camera x implementation.
@tula1308
@tula1308 3 жыл бұрын
Greatest camerax tutorial in the world. I have to sub and like after watch =))
@EnsembleJams
@EnsembleJams Жыл бұрын
You are an absolute blessing for this
@akashmanna2099
@akashmanna2099 2 жыл бұрын
Great video
@232techtalk
@232techtalk Жыл бұрын
I thank you very much for this explanation. Is there a way that we can record a video for a certain seconds and then stop the record and save the video without the user having to stop the recording manually. Let's say we want to record only for 15seconds and after 15seconds the recording should stop. Thank you
@CodingReel
@CodingReel Жыл бұрын
Thanks for watching, yes you can do it. Just you need to start the countdown timer at the start of video capture and when the timer stops you can call the method stop video from its callback.
@sweetcookitalys5700
@sweetcookitalys5700 2 ай бұрын
because the folder is created but the photo is not there.
@animationcrust1993
@animationcrust1993 3 жыл бұрын
Thank you for this useful video...it helped a lot ☺️
@CodingReel
@CodingReel 3 жыл бұрын
Glad it was helpful!
@robertogarzone2647
@robertogarzone2647 2 жыл бұрын
Hi bro. Thanks for the video... I found a problem in the method preview.setSurfaceProvider because the method getSurfaceProvider is not recognized. How can I fix it?
@ece3616
@ece3616 Жыл бұрын
how can i add zoom in this
@youssefdirani
@youssefdirani 3 жыл бұрын
Thanks Faisal. BTW I'm a fan of no music ;)
@lidimarcbarbosa
@lidimarcbarbosa 2 жыл бұрын
Thank you very much! Is it possible to implement internal audio in the video recording? Greetings from Brazil
@CodingReel
@CodingReel 2 жыл бұрын
I dont understand for what use case you want to implement internal audio, can you explain further? We use internal audio for screen recording implementation.
@jacob-ql4bg
@jacob-ql4bg 2 жыл бұрын
Thanks a lot for your video.
@guchengz7073
@guchengz7073 2 жыл бұрын
Can i use MediaRecord replace VideoCapture? I want to have preview + imageAnalyzer + videoRecord + ImageCapture in my app.
@CodingReel
@CodingReel 2 жыл бұрын
Thanks for the comment, I haven't tried this thing yet. The reason it is not allowed because 3 parallel YUV outputs aren't supported. See for more details: stackoverflow.com/questions/61524671/is-it-possible-to-combine-preview-imageanalysis-and-videocapture-with-camerax
@antonizheng4521
@antonizheng4521 2 жыл бұрын
me have a problem, my camerax preview view still black screen not showing anything
@CodingReel
@CodingReel 2 жыл бұрын
Thanks for the comment, have you given the permissions from the app info for the camera and storage?
@matiasestebanromanfuentes6079
@matiasestebanromanfuentes6079 3 жыл бұрын
What version of android did you implement it for? everything is ok but it fails me when saving the photo
@CodingReel
@CodingReel 3 жыл бұрын
You have to give external storage permission from the App Info. Remember runtime permission implementation is not covered in this video.
@wavedass4655
@wavedass4655 3 жыл бұрын
android:requestLegacyExternalStorage="true" , Paste this in application section in MANIFEST file
@sangharshapps8600
@sangharshapps8600 3 жыл бұрын
Thanks for this video...
@prashantbhadoriya8494
@prashantbhadoriya8494 2 жыл бұрын
bro camera is not showing only the xml layout i made is showing in the page
@CodingReel
@CodingReel 2 жыл бұрын
Thanks for the comment, give permissions for the camera from the app info. Then it will show up.
@prashantbhadoriya8494
@prashantbhadoriya8494 2 жыл бұрын
@@CodingReel thanks bro it worked
@grigorabgaryan169
@grigorabgaryan169 3 жыл бұрын
Did you know that setting FPS on a VideoCapture Builder is not working? there's something wrong with using that restricted video capture api
@deependrabishwakarma4612
@deependrabishwakarma4612 2 жыл бұрын
how to perform image processing and return frame to the realtime preview ?
@CodingReel
@CodingReel 2 жыл бұрын
You can use the Image Analyzer callback and perform image processing on it. It will result in the realtime preview in camera.
@CodingReel
@CodingReel 2 жыл бұрын
Hi, Video has been published based upon your question. Thanks
@deependrabishwakarma4612
@deependrabishwakarma4612 2 жыл бұрын
@@CodingReel loads of thank you sir i really loved this tutorial, it was so helpful,
@nnasim5089
@nnasim5089 3 жыл бұрын
how is your code working? coz you have so many red lines errors in it>
@CodingReel
@CodingReel 3 жыл бұрын
these are not error lines, as the code build is also shown in the video
@tazvlucy
@tazvlucy 2 жыл бұрын
Hmm... I 'm failing to follow what you're typing after cameraProviderFuture.addListener(?).
@CodingReel
@CodingReel 2 жыл бұрын
this is the lamba expression for the implementation of functional interface. In simple words, it is just another way of implementing an interface.
@chorizoc
@chorizoc 3 жыл бұрын
After I press the recording button it says "error saving video:Mediamuxer creation failed"
@CodingReel
@CodingReel 3 жыл бұрын
Check if the permissions are given from the app info.
@programmerend4131
@programmerend4131 2 жыл бұрын
same issue
@programmerend4131
@programmerend4131 2 жыл бұрын
@@CodingReel permissions given
@hassanalhalabi7563
@hassanalhalabi7563 3 жыл бұрын
In case there is no SD card, how could I use the internal storage to store the Image?
@CodingReel
@CodingReel 3 жыл бұрын
You can use following to get the public directory: File photosDir = new File(Environment.getExternalStoragePublicDirectory(Environment.DIRECTORY_PHOTOS) + "/CameraXPhotos");
@SANTIAGOVEGA22
@SANTIAGOVEGA22 3 жыл бұрын
How to configure the flash on and off?
@CodingReel
@CodingReel 3 жыл бұрын
get camera control instance from camera and there is enableTorch method in it.
@SANTIAGOVEGA22
@SANTIAGOVEGA22 3 жыл бұрын
@@CodingReel thanks i was able to do it 😁
@neilHVC
@neilHVC 2 жыл бұрын
Thank you so much for this one. It was well explained but I was wondering how can Implement CameraX as a service?
@CodingReel
@CodingReel 2 жыл бұрын
Thanks for checking out. You can do it using foreground service.
@willfredo4049
@willfredo4049 3 жыл бұрын
failed to write temp file :(
@CodingReel
@CodingReel 3 жыл бұрын
Fix has been published, please check at: kzbin.info/www/bejne/eXOac6miqaeMnZo
@tradingchartexpert9636
@tradingchartexpert9636 3 жыл бұрын
Brother its to fast to understand for biggners
@CodingReel
@CodingReel 3 жыл бұрын
Thanks for comment, will try to add more explanation in next video. This video is code implementation of the Camera X, the theoretical part is not covered in it.
Android. Работаем с камерой через CameraX.
26:55
Sergey Arkhipov Java Tutorials
Рет қаралды 10 М.
How to Build a Camera App With CameraX - Taking Photos
29:35
Philipp Lackner
Рет қаралды 48 М.
How Strong Is Tape?
00:24
Stokes Twins
Рет қаралды 96 МЛН
Sigma Kid Mistake #funny #sigma
00:17
CRAZY GREAPA
Рет қаралды 30 МЛН
So Cute 🥰 who is better?
00:15
dednahype
Рет қаралды 19 МЛН
Support Multiple Screen Sizes - Android Studio Tutorial
8:20
Stevdza-San
Рет қаралды 99 М.
CameraX setup and permissions
9:12
Android Developers
Рет қаралды 13 М.
How to Build a Video Recorder With CameraX in Android
11:38
Philipp Lackner
Рет қаралды 11 М.
A Deep Dive into JVM Start-Up
22:03
Java
Рет қаралды 23 М.
How Strong Is Tape?
00:24
Stokes Twins
Рет қаралды 96 МЛН