- context
- the Context to use
- uri
- the Uri from which to get the datasource
- holder
- the SurfaceHolder to use for displaying the video
Documentation for this section has not yet been entered.
Convenience method to create a MediaPlayer for a given Uri. On success, MediaPlayer.Prepare will already have been called and must not be called again.
When done with the MediaPlayer, you should call MediaPlayer.Release, to free the resources. If not released, too many MediaPlayer instances will result in an exception.
Note that since MediaPlayer.Prepare is called automatically in this method, you cannot change the audio stream type (see MediaPlayer.SetAudioStreamType(Stream)), audio session ID (see MediaPlayer.AudioSessionId) or audio attributes (see MediaPlayer.SetAudioAttributes(AudioAttributes) of the new MediaPlayer.