I want to use the OpenGL ES for the Android camera preview and Save the captured Image.
I like to use the OpenGL ES in Android camera to give some effect to the Android camera. So please anyone tell me how to do it?
you need to implement the android.hardware.Camera.PreviewCallback
interface and override the method
public synchronized void onPreviewFrame(byte[] data, Camera camera) {
myOpenGLObject.receiveFrames(data);
}
to read the frames received from the camera callback. I suggest you to have a look into the andar source http://code.google.com/p/andar/. Especially the class CameraPreviewHandler.java.
I hope this answers your question.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With