How to use CameraEffect in Androidx

132 Views Asked by At

I wanted to implement an app that performs continuous capture like the one implemented in Grafika. I want to use androidx to do this, and I've come to the understanding that I could use the CameraEffect API on the Preview use case to somehow get the frames, save them in a buffer, and display the preview. My question is, how can I use CameraEffect? I tried looking for examples of CameraEffect and found the one on the AndroidX GitHub repository for the integration tests (link).

One problem is that if I copy the code for implementing my own surface processor, I get an error (can only be called from within the same library group (referenced groupId=androidx.camera from groupId=Jetpack)). Can anyone tell me if the approach I am taking is correct and, if so, how I can fix/use the example?

0

There are 0 best solutions below