Skip to content

How to add custom preview thumbnail #531

Answered by luwes
debjits1 asked this question in Q&A
Discussion options

You must be logged in to vote

Thanks for the question!

JSON format is not supported for now, Media Chrome picks up preview thumbnails from a .vtt file like in the example here,
https://github.com/muxinc/media-chrome/blob/main/examples/vanilla/advanced.html#L42-L47

Requires a video track similar to

          <track
            label="thumbnails"
            default
            kind="metadata"
            src="https://image.mux.com/A3VXy02VoUinw01pwyomEO3bHnG4P32xzV7u1j1FSzjNg/storyboard.vtt"
          />

For the best experience and performance the preview image is one big sprite image so it only needs 1 request and Media Chrome will show the correct coordinates based on the xywh hash at the end of the URL.

the contents…

Replies: 1 comment 2 replies

Comment options

You must be logged in to vote
2 replies
@gkatsev
Comment options

@gkatsev
Comment options

Answer selected by dylanjha
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
3 participants