Showing (embedded) closed captions in MP4

122 views Asked by At

I am using mediaelement.js to place a video onto the web page. For those unfamiliar with it, it is a video player element that takes in a single source video and displays in various formats (HTML5 or flash) based upon browser capabilities

The mp4 that I am using has the captions embedded into itself. Is there a way with HTML5 or mediaelement.js to display these captions. I know that I can pull an external track:

<track kind="subtitles" src="subtitles.srt" srclang="en" />

but since it is embedded I would prefer to use those. This is what my code looks like:

<video width="640" height="360" style="width:100%; height: 100%;" src="myvid.mp4" type="video/mp4" id="video1"  controls="controls">
    <source src="myvid.mp4" type="video/mp4" />
    <object width="640" height="360" type="application/x-shockwave-flash" data="flashmediaelement.swf">
        <param name="movie" value="flashmediaelement.swf" />
        <param name="flashvars" value="controls=true&amp;file=myvid.mp4 />
        <!-- Image fall back for non-HTML5 browser with JavaScript turned off and no Flash player installed -->
        No video playback capabilities
    </object>
</video>
0

There are 0 answers