Code example for MediaMetadataRetriever

Methods: getEmbeddedPicture, getFrameAtTime

0
	 * found set that image as the first image to be displayed on the screen 
	 * else the function selects the frame at time 3000 to be displayed at the 
	 * screen 
	 */ 
	private void setDisplayImage() { 
		byte[] byteArrayImageData = mediaRetriever.getEmbeddedPicture();
		if (byteArrayImageData != null) {
			bitmap = BitmapFactory.decodeByteArray(byteArrayImageData, 0,
					byteArrayImageData.length);
		} else { 
			bitmap = mediaRetriever.getFrameAtTime(3000);
		} 
		imageView.setImageBitmap(bitmap);
	} 
 
	/** 
	 * @param status 
	 *            its 1 if the user presses NEXT button or its 0 if user presses 
	 *            PREVIOUS This function first check that what button user has 
	 *            pressed . Then using the "position" value it checks , between 
	 *            what interval the position lies and calls changeImageView