Code example for Camera: Taking pictures with the camera

Methods: takePicture

0
 
				// get an image from the camera 
				mCamera.autoFocus(new AutoFocusCallback() {
 
					public void onAutoFocus(boolean success, Camera camera) {
						mCamera.takePicture(null, null, mPicture);
					} 
				}); 
			} 
		}); 
 
		Button cancelButton = (Button) findViewById(R.id.button_cancel);
		cancelButton.setOnClickListener(new View.OnClickListener() {
			public void onClick(View v) {
				pressed = false;
				setResult(RESULT_CANCELED);
				finish();
			} 
		}); 
	} 
Contextual code suggestions in your IDE  Get Codota for Java