| Modifier and Type | Class and Description |
|---|---|
static interface |
AWindow.SurfaceCallback |
IVLCVout.Callback, IVLCVout.OnNewVideoLayoutListener| Constructor and Description |
|---|
AWindow(AWindow.SurfaceCallback surfaceCallback)
Create an AWindow
You call this directly only if you use the libvlc_media_player native API (and not the Java
MediaPlayer class).
|
| Modifier and Type | Method and Description |
|---|---|
void |
addCallback(IVLCVout.Callback callback)
Add a callback to receive
IVLCVout.Callback.onSurfacesCreated(org.videolan.libvlc.IVLCVout) and
IVLCVout.Callback.onSurfacesDestroyed(IVLCVout) events. |
boolean |
areViewsAttached()
Return true if views are attached.
|
void |
attachViews()
Attach views without an OnNewVideoLayoutListener
|
void |
attachViews(IVLCVout.OnNewVideoLayoutListener onNewVideoLayoutListener)
Attach views with an OnNewVideoLayoutListener
This must be called afters views are set and before the MediaPlayer is first started.
|
void |
detachViews()
Detach views previously attached.
|
void |
removeCallback(IVLCVout.Callback callback)
Remove a callback.
|
void |
sendMouseEvent(int action,
int button,
int x,
int y)
Send a mouse event to the native vout.
|
void |
setSubtitlesSurface(android.view.Surface subtitlesSurface,
android.view.SurfaceHolder surfaceHolder)
Set a surface used for subtitles out.
|
void |
setSubtitlesSurface(android.graphics.SurfaceTexture subtitlesSurfaceTexture)
Set a SurfaceTexture used for subtitles out.
|
void |
setSubtitlesView(android.view.SurfaceView subtitlesSurfaceView)
Set a surfaceView used for subtitles out.
|
void |
setSubtitlesView(android.view.TextureView subtitlesTextureView)
Set a TextureView used for subtitles out.
|
void |
setVideoSurface(android.view.Surface videoSurface,
android.view.SurfaceHolder surfaceHolder)
Set a surface used for video out.
|
void |
setVideoSurface(android.graphics.SurfaceTexture videoSurfaceTexture)
Set a SurfaceTexture used for video out.
|
void |
setVideoView(android.view.SurfaceView videoSurfaceView)
Set a surfaceView used for video out.
|
void |
setVideoView(android.view.TextureView videoTextureView)
Set a TextureView used for video out.
|
void |
setWindowSize(int width,
int height)
Send the the window size to the native vout.
|
public AWindow(AWindow.SurfaceCallback surfaceCallback)
surfaceCallback - public void setVideoView(android.view.SurfaceView videoSurfaceView)
IVLCVoutsetVideoView in interface IVLCVoutIVLCVout.attachViews()public void setVideoView(android.view.TextureView videoTextureView)
IVLCVoutsetVideoView in interface IVLCVoutIVLCVout.attachViews()public void setVideoSurface(android.view.Surface videoSurface,
android.view.SurfaceHolder surfaceHolder)
IVLCVoutsetVideoSurface in interface IVLCVoutvideoSurface - if surfaceHolder is null, this surface must be valid and attached.surfaceHolder - optional, used to configure buffers geometry before Android ICS
and to get notified when surface is destroyed.IVLCVout.attachViews()public void setVideoSurface(android.graphics.SurfaceTexture videoSurfaceTexture)
IVLCVoutsetVideoSurface in interface IVLCVoutvideoSurfaceTexture - this surface must be valid and attached.IVLCVout.attachViews()public void setSubtitlesView(android.view.SurfaceView subtitlesSurfaceView)
IVLCVoutsetSubtitlesView in interface IVLCVoutIVLCVout.attachViews()public void setSubtitlesView(android.view.TextureView subtitlesTextureView)
IVLCVoutsetSubtitlesView in interface IVLCVoutIVLCVout.attachViews()public void setSubtitlesSurface(android.view.Surface subtitlesSurface,
android.view.SurfaceHolder surfaceHolder)
IVLCVoutsetSubtitlesSurface in interface IVLCVoutsubtitlesSurface - if surfaceHolder is null, this surface must be valid and attached.surfaceHolder - optional, used to configure buffers geometry before Android ICS
and to get notified when surface is destroyed.IVLCVout.attachViews()public void setSubtitlesSurface(android.graphics.SurfaceTexture subtitlesSurfaceTexture)
IVLCVoutsetSubtitlesSurface in interface IVLCVoutsubtitlesSurfaceTexture - this surface must be valid and attached.IVLCVout.attachViews()public void attachViews(IVLCVout.OnNewVideoLayoutListener onNewVideoLayoutListener)
IVLCVoutattachViews in interface IVLCVoutIVLCVout.OnNewVideoLayoutListener,
IVLCVout.setVideoView(SurfaceView),
IVLCVout.setVideoView(TextureView),
IVLCVout.setVideoSurface(Surface, SurfaceHolder),
IVLCVout.setSubtitlesView(SurfaceView),
IVLCVout.setSubtitlesView(TextureView),
IVLCVout.setSubtitlesSurface(Surface, SurfaceHolder)public void attachViews()
IVLCVoutattachViews in interface IVLCVoutIVLCVout.attachViews(OnNewVideoLayoutListener)public void detachViews()
IVLCVoutdetachViews in interface IVLCVoutpublic boolean areViewsAttached()
IVLCVoutareViewsAttached in interface IVLCVoutpublic void sendMouseEvent(int action,
int button,
int x,
int y)
IVLCVoutsendMouseEvent in interface IVLCVoutaction - see ACTION_* in MotionEvent.button - see BUTTON_* in MotionEvent.x - x coordinate.y - y coordinate.public void setWindowSize(int width,
int height)
IVLCVoutsetWindowSize in interface IVLCVoutwidth - width of the window.height - height of the window.public void addCallback(IVLCVout.Callback callback)
IVLCVoutIVLCVout.Callback.onSurfacesCreated(org.videolan.libvlc.IVLCVout) and
IVLCVout.Callback.onSurfacesDestroyed(IVLCVout) events.addCallback in interface IVLCVoutpublic void removeCallback(IVLCVout.Callback callback)
IVLCVoutremoveCallback in interface IVLCVout