/development/samples/HoneycombGallery/src/com/example/android/hcgallery/ |
D | CameraFragment.java | 44 Camera mCamera; field in CameraFragment 99 mCamera = Camera.open(mCurrentCamera); in onResume() 101 mPreview.setCamera(mCamera); in onResume() 110 if (mCamera != null) { in onPause() 112 mCamera.release(); in onPause() 113 mCamera = null; in onPause() 133 if (mCamera != null) { in onOptionsItemSelected() 134 mCamera.stopPreview(); in onOptionsItemSelected() 136 mCamera.release(); in onOptionsItemSelected() 137 mCamera = null; in onOptionsItemSelected() [all …]
|
/development/samples/ApiDemos/src/com/example/android/apis/graphics/ |
D | CameraPreview.java | 48 Camera mCamera; field in CameraPreview 86 mCamera = Camera.open(); in onResume() 88 mPreview.setCamera(mCamera); in onResume() 97 if (mCamera != null) { in onPause() 99 mCamera.release(); in onPause() 100 mCamera = null; in onPause() 130 if (mCamera != null) { in onOptionsItemSelected() 131 mCamera.stopPreview(); in onOptionsItemSelected() 133 mCamera.release(); in onOptionsItemSelected() 134 mCamera = null; in onOptionsItemSelected() [all …]
|
/development/samples/browseable/RuntimePermissionsBasic/src/com.example.android.basicpermissions/camera/ |
D | CameraPreviewActivity.java | 48 private Camera mCamera; field in CameraPreviewActivity 55 mCamera = getCameraInstance(CAMERA_ID); in onCreate() 59 if (mCamera == null || cameraInfo == null) { in onCreate() 72 mPreview = new CameraPreview(this, mCamera, cameraInfo, displayRotation); in onCreate() 99 if (mCamera != null) { in releaseCamera() 100 mCamera.release(); // release the camera for other applications in releaseCamera() 101 mCamera = null; in releaseCamera()
|
D | CameraPreview.java | 40 private Camera mCamera; field in CameraPreview 52 mCamera = camera; in CameraPreview() 65 mCamera.setPreviewDisplay(holder); in surfaceCreated() 66 mCamera.startPreview(); in surfaceCreated() 89 mCamera.stopPreview(); in surfaceChanged() 97 mCamera.setDisplayOrientation(orientation); in surfaceChanged() 100 mCamera.setPreviewDisplay(mHolder); in surfaceChanged() 101 mCamera.startPreview(); in surfaceChanged()
|
/development/samples/browseable/RuntimePermissions/src/com.example.android.system.runtimepermissions/camera/ |
D | CameraPreviewFragment.java | 52 private Camera mCamera; field in CameraPreviewFragment 63 mCamera = getCameraInstance(CAMERA_ID); in onCreateView() 66 if (mCamera != null) { in onCreateView() 72 if (mCamera == null || cameraInfo == null) { in onCreateView() 85 mPreview = new CameraPreview(getActivity(), mCamera, cameraInfo, displayRotation); in onCreateView() 112 if (mCamera != null) { in releaseCamera() 113 mCamera.release(); // release the camera for other applications in releaseCamera() 114 mCamera = null; in releaseCamera()
|
D | CameraPreview.java | 40 private Camera mCamera; field in CameraPreview 52 mCamera = camera; in CameraPreview() 65 mCamera.setPreviewDisplay(holder); in surfaceCreated() 66 mCamera.startPreview(); in surfaceCreated() 89 mCamera.stopPreview(); in surfaceChanged() 97 mCamera.setDisplayOrientation(orientation); in surfaceChanged() 100 mCamera.setPreviewDisplay(mHolder); in surfaceChanged() 101 mCamera.startPreview(); in surfaceChanged()
|
/development/samples/browseable/MediaRecorder/src/com.example.android.mediarecorder/ |
D | MainActivity.java | 46 private Camera mCamera; field in MainActivity 86 mCamera.lock(); // take camera access back from MediaRecorder in onCaptureClick() 127 mCamera.lock(); in releaseMediaRecorder() 132 if (mCamera != null){ in releaseCamera() 134 mCamera.release(); in releaseCamera() 135 mCamera = null; in releaseCamera() 143 mCamera = CameraHelper.getDefaultCameraInstance(); in prepareVideoRecorder() 148 Camera.Parameters parameters = mCamera.getParameters(); in prepareVideoRecorder() 161 mCamera.setParameters(parameters); in prepareVideoRecorder() 165 mCamera.setPreviewTexture(mPreview.getSurfaceTexture()); in prepareVideoRecorder() [all …]
|
/development/samples/devbytes/graphics/FoldingLayout/src/com/example/android/foldinglayout/ |
D | FoldingLayoutActivity.java | 102 private Camera mCamera; field in FoldingLayoutActivity 189 mCamera = Camera.open(); 191 if (mCamera == null && Camera.getNumberOfCameras() > 1) { 192 mCamera = mCamera.open(Camera.CameraInfo.CAMERA_FACING_FRONT); 195 if (mCamera == null) { 200 mCamera.setPreviewTexture(surfaceTexture); 201 mCamera.setDisplayOrientation(90); 202 mCamera.startPreview(); 215 if (mCamera != null) { 216 mCamera.stopPreview(); [all …]
|
/development/samples/ApiDemos/src/com/example/android/apis/animation/ |
D | Rotate3dAnimation.java | 35 private Camera mCamera; field in Rotate3dAnimation 65 mCamera = new Camera(); in initialize() 75 final Camera camera = mCamera; in applyTransformation()
|