Android samples: class SampleViewBase which uses native camera is renamed.

This commit is contained in:
Andrey Kamaev 2011-07-18 09:13:05 +00:00
parent 1e2880b7aa
commit cc3c034cf6
4 changed files with 6 additions and 7 deletions

View File

@ -11,13 +11,13 @@ import android.util.Log;
import android.view.SurfaceHolder;
import android.view.SurfaceView;
public abstract class SampleViewBase extends SurfaceView implements SurfaceHolder.Callback, Runnable {
public abstract class SampleCvViewBase extends SurfaceView implements SurfaceHolder.Callback, Runnable {
private static final String TAG = "Sample::SurfaceView";
private SurfaceHolder mHolder;
private VideoCapture mCamera;
public SampleViewBase(Context context) {
public SampleCvViewBase(Context context) {
super(context);
mHolder = getHolder();
mHolder.addCallback(this);

View File

@ -9,7 +9,7 @@ import android.view.SurfaceHolder;
import android.view.View;
import android.view.View.OnTouchListener;
public class puzzle15View extends SampleViewBase implements OnTouchListener {
public class puzzle15View extends SampleCvViewBase implements OnTouchListener {
private Mat mRgba;
private Mat mRgba15;
private Mat[] mCells;
@ -171,7 +171,6 @@ public class puzzle15View extends SampleViewBase implements OnTouchListener {
}
}
@Override
public boolean onTouch(View v, MotionEvent event) {
int cols = mRgba.cols();
int rows = mRgba.rows();

View File

@ -6,7 +6,7 @@ import android.content.Context;
import android.graphics.Bitmap;
import android.view.SurfaceHolder;
class Sample2View extends SampleViewBase {
class Sample2View extends SampleCvViewBase {
private Mat mRgba;
private Mat mGray;
private Mat mIntermediateMat;

View File

@ -11,13 +11,13 @@ import android.util.Log;
import android.view.SurfaceHolder;
import android.view.SurfaceView;
public abstract class SampleViewBase extends SurfaceView implements SurfaceHolder.Callback, Runnable {
public abstract class SampleCvViewBase extends SurfaceView implements SurfaceHolder.Callback, Runnable {
private static final String TAG = "Sample::SurfaceView";
private SurfaceHolder mHolder;
private VideoCapture mCamera;
public SampleViewBase(Context context) {
public SampleCvViewBase(Context context) {
super(context);
mHolder = getHolder();
mHolder.addCallback(this);