public class

MediaPlayerFragment

extends Fragment
implements TextureView.SurfaceTextureListener MediaController.MediaPlayerControl
java.lang.Object
   ↳ android.app.Fragment
     ↳ io.kickflip.sdk.fragment.MediaPlayerFragment

Class Overview

MediaPlayerFragment demonstrates playing an HLS Stream, and fetching stream metadata via the .m3u8 manifest to decorate the display for Live streams.

Summary

[Expand]
Inherited Constants
From interface android.content.ComponentCallbacks2
Public Constructors
MediaPlayerFragment()
Public Methods
boolean canPause()
boolean canSeekBackward()
boolean canSeekForward()
int getAudioSessionId()
int getBufferPercentage()
int getCurrentPosition()
int getDuration()
boolean isPlaying()
static MediaPlayerFragment newInstance(String mediaUrl)
void onCreate(Bundle savedInstanceState)
View onCreateView(LayoutInflater inflater, ViewGroup container, Bundle savedInstanceState)
void onPause()
void onResume()
void onSurfaceTextureAvailable(SurfaceTexture surfaceTexture, int width, int height)
boolean onSurfaceTextureDestroyed(SurfaceTexture surface)
void onSurfaceTextureSizeChanged(SurfaceTexture surface, int width, int height)
void onSurfaceTextureUpdated(SurfaceTexture surface)
void pause()
void seekTo(int pos)
void start()
[Expand]
Inherited Methods
From class android.app.Fragment
From class java.lang.Object
From interface android.content.ComponentCallbacks
From interface android.content.ComponentCallbacks2
From interface android.view.TextureView.SurfaceTextureListener
From interface android.view.View.OnCreateContextMenuListener
From interface android.widget.MediaController.MediaPlayerControl

Public Constructors

public MediaPlayerFragment ()

Public Methods

public boolean canPause ()

public boolean canSeekBackward ()

public boolean canSeekForward ()

public int getAudioSessionId ()

public int getBufferPercentage ()

public int getCurrentPosition ()

public int getDuration ()

public boolean isPlaying ()

public static MediaPlayerFragment newInstance (String mediaUrl)

public void onCreate (Bundle savedInstanceState)

public View onCreateView (LayoutInflater inflater, ViewGroup container, Bundle savedInstanceState)

public void onPause ()

public void onResume ()

public void onSurfaceTextureAvailable (SurfaceTexture surfaceTexture, int width, int height)

public boolean onSurfaceTextureDestroyed (SurfaceTexture surface)

public void onSurfaceTextureSizeChanged (SurfaceTexture surface, int width, int height)

public void onSurfaceTextureUpdated (SurfaceTexture surface)

public void pause ()

public void seekTo (int pos)

public void start ()