From 97e9368e758e6ce75a61a2e47572a15524f1a812 Mon Sep 17 00:00:00 2001 From: ograycode Date: Sun, 19 May 2013 22:04:56 -0400 Subject: [PATCH] Simple set of the camera index to allow the user to change it after the object has been initialized. --- .../generator/src/java/android+CameraBridgeViewBase.java | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/modules/java/generator/src/java/android+CameraBridgeViewBase.java b/modules/java/generator/src/java/android+CameraBridgeViewBase.java index 6c5c3294ff..b15ae2bd8f 100644 --- a/modules/java/generator/src/java/android+CameraBridgeViewBase.java +++ b/modules/java/generator/src/java/android+CameraBridgeViewBase.java @@ -80,6 +80,14 @@ public abstract class CameraBridgeViewBase extends SurfaceView implements Surfac mMaxHeight = MAX_UNSPECIFIED; styledAttrs.recycle(); } + + /** + * Sets the camera index + * @param camera index + */ + public void setCameraIndex(int cameraIndex) { + this.mCameraIndex = cameraIndex; + } public interface CvCameraViewListener { /**