It can work for videos that have captions/subtitles (YouTube can even auto-generate them). Each caption has a time range that is supposed to be displayed for:
WEBVTT
00:01.000 --> 00:04.000
- Never drink liquid nitrogen.
00:05.000 --> 00:09.000
- It will perforate your stomach.
- You could die.
We could simply skip every range that doesn't have captions (subtitles?). Fortunately, the cloning algorithm already implements skipping according to an array of time ranges, so it's a matter of bootstrapping stuff:
Fadi suggested this.
It can work for videos that have captions/subtitles (YouTube can even auto-generate them). Each caption has a time range that is supposed to be displayed for:
We could simply skip every range that doesn't have captions (subtitles?). Fortunately, the cloning algorithm already implements skipping according to an array of time ranges, so it's a matter of bootstrapping stuff:
https://github.com/WofWca/jumpcutter/blob/90931ad3b1979aa1be141e3c8dc6b8ceea891bfb/src/entry-points/content/ElementPlaybackControllerCloning/ElementPlaybackControllerCloning.ts#L427
See https://developer.mozilla.org/en-US/docs/Web/Guide/Audio_and_video_delivery/Adding_captions_and_subtitles_to_HTML5_video for more on captions in browsers.