Repository navigation
Introducing the Subtitle Feature #1916
Replies: 1 comment
|
Hello @getroot I am implementing a subtitle feature using the latest version of OvenMediaEngine and it works great overall - thank you for this addition. I have a question about timing continuity when sending subtitles via the API. My use case: I use multiple speech-to-text providers, some of which emit partial transcripts every ~500ms. On the player side this creates a nice word-by-word streaming effect. I send each partial result via the API with a calculated durationMs to control how long each cue stays on screen. The problem is that I cannot perfectly synchronize with OME's internal clock. As a result:
What I need is for each new cue to start exactly at the moment the previous one ends — i.e. continuous display with no gap and no overlap. Is there a way to achieve this? For example, a mode where a new subtitle cue can start exactly at the end of the previous ? Thank you for your help. |
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
OvenMediaEngine now allows you to insert subtitles in real time during live streaming via API. Of course, multilingual subtitles are supported.
You can already test it on the master branch, and it will be officially supported in the next release (0.19.1).
For details, see: https://docs.ovenmediaengine.com/dev/subtitles
In the future, we also plan to support this feature in WebRTC. However, the priority will depend on how many users actually need subtitles in WebRTC.
If you need the WebRTC + Subtitle feature, please let us know.
[Note]
hls.js currently does not properly support subtitles with LL-HLS. We have submitted a report about this:
video-dev/hls.js#7522
Until this is resolved, subtitles may not be displayed correctly when playing LL-HLS in OvenPlayer. In the meantime, you can test normally by adding ?_HLS_lagacy=YES to the URL, which switches LL-HLS to a mode that does not use partial segments.
Alternatively, you can test subtitles correctly using other players such as Shaka Player, Safari, or THEOplayer.
All reactions