Interface MpegTrackConsumer

    • Method Summary

      All Methods Instance Methods Abstract Methods 
      Modifier and Type Method Description
      void close()
      Free all resources
      void consume​(java.nio.channels.ReadableByteChannel channel, int length)
      Consume one chunk from the track
      void flush()
      Indicates that no more input is coming.
      MpegTrackInfo getTrack()  
      void initialise()
      Initialise the consumer, called before first consume()
      void seekPerformed​(long requestedTimecode, long providedTimecode)
      Indicates that the next frame is not a direct continuation of the previous one
    • Method Detail

      • getTrack

        MpegTrackInfo getTrack()
        Returns:
        The associated MP4 track
      • initialise

        void initialise()
        Initialise the consumer, called before first consume()
      • seekPerformed

        void seekPerformed​(long requestedTimecode,
                           long providedTimecode)
        Indicates that the next frame is not a direct continuation of the previous one
        Parameters:
        requestedTimecode - Timecode in milliseconds to which the seek was requested to
        providedTimecode - Timecode in milliseconds to which the seek was actually performed to
      • flush

        void flush()
            throws java.lang.InterruptedException
        Indicates that no more input is coming. Flush any buffers to output.
        Throws:
        java.lang.InterruptedException - When interrupted externally (or for seek/stop).
      • consume

        void consume​(java.nio.channels.ReadableByteChannel channel,
                     int length)
              throws java.lang.InterruptedException
        Consume one chunk from the track
        Parameters:
        channel - Byte channel to consume from
        length - Lenth of the chunk in bytes
        Throws:
        java.lang.InterruptedException - When interrupted externally (or for seek/stop).
      • close

        void close()
        Free all resources