Class CallbackMediaListPlayerComponent

All Implemented Interfaces:
KeyListener, MouseListener, MouseMotionListener, MouseWheelListener, ImageObserver, MenuContainer, Serializable, EventListener, Accessible, MediaEventListener, MediaListEventListener, MediaPlayerEventListener, MediaPlayerComponent, MediaListPlayerEventListener

public class CallbackMediaListPlayerComponent extends CallbackMediaListPlayerComponentBase
Implementation of a callback "direct-rendering" media list player.

This component renders video frames received via native callbacks.

The component may be added directly to a user interface layout.

When the component is no longer needed, it should be released by invoking the CallbackMediaPlayerComponent.release() method.

See Also:
  • Constructor Details

    • CallbackMediaListPlayerComponent

      public CallbackMediaListPlayerComponent(MediaPlayerFactory mediaPlayerFactory, FullScreenStrategy fullScreenStrategy, InputEvents inputEvents, boolean lockBuffers, CallbackImagePainter imagePainter, RenderCallback renderCallback, BufferFormatCallback bufferFormatCallback, JComponent videoSurfaceComponent)
      Construct a callback media list player component.

      This component will provide a reasonable default implementation, but a client application is free to override these defaults with their own implementation.

      To rely on the defaults and have this component render the video, do not supply a renderCallback.

      If a client application wishes to perform its own rendering, provide a renderCallback, a BufferFormatCallback, and optionally (but likely) a videoSurfaceComponent if the client application wants the video surface they are rendering in to be incorporated into this component's layout.

      Parameters:
      mediaPlayerFactory - media player factory
      fullScreenStrategy - full screen strategy
      inputEvents - keyboard/mouse input event configuration
      lockBuffers - true if the native video buffer should be locked; false if not
      imagePainter - image painter (video renderer)
      renderCallback - render callback
      bufferFormatCallback - buffer format callback
      videoSurfaceComponent - lightweight video surface component
    • CallbackMediaListPlayerComponent

      public CallbackMediaListPlayerComponent(MediaPlayerFactory mediaPlayerFactory, FullScreenStrategy fullScreenStrategy, InputEvents inputEvents, boolean lockBuffers, CallbackImagePainter imagePainter)
      Construct a callback media list player component for intrinsic rendering (by this component).
      Parameters:
      mediaPlayerFactory - media player factory
      fullScreenStrategy - full screen strategy
      inputEvents - keyboard/mouse input event configuration
      lockBuffers - true if the native video buffer should be locked; false if not
      imagePainter - image painter (video renderer)
    • CallbackMediaListPlayerComponent

      public CallbackMediaListPlayerComponent(MediaPlayerFactory mediaPlayerFactory, FullScreenStrategy fullScreenStrategy, InputEvents inputEvents, boolean lockBuffers, RenderCallback renderCallback, BufferFormatCallback bufferFormatCallback, JComponent videoSurfaceComponent)
      Construct a callback media list player component for external rendering (by the client application).
      Parameters:
      mediaPlayerFactory - media player factory
      fullScreenStrategy - full screen strategy
      inputEvents - keyboard/mouse input event configuration
      lockBuffers - true if the native video buffer should be locked; false if not
      renderCallback - render callback
      bufferFormatCallback - buffer format callback
      videoSurfaceComponent - lightweight video surface component
    • CallbackMediaListPlayerComponent

      public CallbackMediaListPlayerComponent(MediaPlayerSpecs.CallbackMediaPlayerSpec spec)
      Construct a callback media list player component from a builder.
      Parameters:
      spec - builder
    • CallbackMediaListPlayerComponent

      public CallbackMediaListPlayerComponent(String... libvlcArgs)
      Construct a callback media list player component with LibVLC initialisation arguments and reasonable defaults.
      Parameters:
      libvlcArgs - LibVLC initialisation arguments
    • CallbackMediaListPlayerComponent

      public CallbackMediaListPlayerComponent()
      Construct a callback media list player component with reasonable defaults.
  • Method Details