Skip to content

Instantly share code, notes, and snippets.

@ojw28
Created September 1, 2016 15:22
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save ojw28/acfea7a151e21cfad8a0faaadb0e460b to your computer and use it in GitHub Desktop.
Save ojw28/acfea7a151e21cfad8a0faaadb0e460b to your computer and use it in GitHub Desktop.
MediaSource videoSource = new ExtractorMediaSource(videoUri, ...);
MediaSource subtitleSource = new SingleSampleMediaSource(subtitleUri, ...);
// Plays the video with the sideloaded subtitle.
MergingMediaSource mergedSource = new MergingMediaSource(videoSource, subtitleSource);
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment