The sample Camera2Base provides a good understanding on how capture a image from the camera but not the image streamed from the camera. You could try to capture every image but I think there's a better way to access the stream. My guess it's that the stream could be captured in the line within the 'case' statement in the code below, but I don't know how to do it.
private CameraCaptureSession.CaptureCallback mCaptureCallback = new CameraCaptureSession.CaptureCallback() { private void process(CaptureResult result) { switch (mState) { case STATE_PREVIEW: { // We have nothing to do when the camera preview is working normally. break; }
After capturing the image I need to be able to find the position of a laser red dot in it. I've never done image processing my guess it's to sweep the bitmap matrix looking to the color red-ish of the red dot and I wouldn't need help from any image processing library. What do you think on getting a image processing library to do this simple task? suppose that there's nothing else red on the image.