Code example for ZoomControls

Methods: setIsZoomInEnabledsetIsZoomOutEnabled

	private void computeBaseMatrix() 
		Drawable d = imageView.getDrawable();
		if (d != null) {
			// The base matrix is the matrix that displays the entire image bitmap. 
			// It orients the image when orientation is set and scales in X and Y independently,  
			// so that src matches dst exactly. 
			// This may change the aspect ratio of the src. 
			Rect r = new Rect();
			int intrinsicWidth = d.getIntrinsicWidth();
			int intrinsicHeight = d.getIntrinsicHeight();
			int dwidth = intrinsicWidth;
			int dheight = intrinsicHeight;
Experience pair programming with AI  Get Codota for Java