What are you trying to achieve or the steps to reproduce?
On my Moto G7, as well as other Android devices that I've tested, Fotoapparat has a low frame rate, as evidenced by two things. The CameraView that previews the frames the camera is capturing is choppy, and a println that I added in my FrameProcessor shows the callback is only invoked 2-4 times every second.
By contrast, I did a quick implementation using the Android CameraX framework, and the camera preview was very smooth, and the equivalent of the frame processor was getting 20-30 callbacks per second. Same exact device, same exact use case.
Are there any knobs I can tweak in order to get better performance out of Fotoapparat. It is clear that my device is capable of better performance, it can get that out of the CameraX framework.
What are you trying to achieve or the steps to reproduce?
On my Moto G7, as well as other Android devices that I've tested, Fotoapparat has a low frame rate, as evidenced by two things. The CameraView that previews the frames the camera is capturing is choppy, and a
println
that I added in myFrameProcessor
shows the callback is only invoked 2-4 times every second.By contrast, I did a quick implementation using the Android CameraX framework, and the camera preview was very smooth, and the equivalent of the frame processor was getting 20-30 callbacks per second. Same exact device, same exact use case.
How did you initialize FA?
Are there any knobs I can tweak in order to get better performance out of Fotoapparat. It is clear that my device is capable of better performance, it can get that out of the CameraX framework.
Context: