Code example for SurfaceView

Methods: setLayoutParams

0
							/ (float) widthRatio);
				} 
			} 
		} 
 
		surfaceView.setLayoutParams(new LinearLayout.LayoutParams(videoWidth,
				videoHeight));
	} 
 
	public void onBufferingUpdate(MediaPlayer mp, int bufferedPercent) {
		statusView.setText("MediaPlayer Buffering: " + bufferedPercent + "%");
		Log.v(LOGTAG, "MediaPlayer Buffering: " + bufferedPercent + "%");
	} 
 
	public boolean canPause() { 
		return true; 
	} 
 
	public boolean canSeekBackward() { 
		return true; 
	}