Class WebVTTParser


public class WebVTTParser extends Object
Implementation of a parser for WebVTT style captions. This parser is not complete, and is loosely based off of the current WebVTT parser in the Google ExoPlayer project.
See Also:
  • Constructor Details

    • WebVTTParser

      public WebVTTParser()
  • Method Details

    • parse

      public static WebVTTDocument parse(InputStream stream, String encoding) throws IOException
      The main parser for WebVTT cue files pre KitKat.
      stream - the input stream containing caption data
      encoding - the string encoding used, mostly UTF-8
      a populated WebVTTDocument with the caption texts.
      IOException - Things to work on in the future: X-TIMESTAMP-MAP parsing (MPEGTS parsing for HLS syncing with PES timing data) Region and Styling parsing