Subtitle Options


There are five places for subtitles, listed innermost layer first.
1. in VCL: Video Coding Layer, as part of the frame video, called hardsub. e.g. by ffmpeg drawtext.
2. in SEI as part of NAL in ES, Network Abstraction Layer, e.g. CEA-708. ffmpeg cannot generate this kind.
3. in track in a video file, e.g. mp4.
ffmpeg -i Party.mp4 -i cap.srt -c:v copy -c:a copy -c:s mov_text -metadata:s:s:0 language=eng PartyCap.mp4
Here is a sample video, playable with vlc, by clicking Menu – Subtitle – Sub Track:
[ http://riowing.net/local/subtitle/track/PartyCap.mp4 ]
4. WebVtt: subtitle in separate file, segmented VTT or not, for both VOD and live.
This sample page is segmented VTT: http://riowing.net/local/subtitle/caption.htm
5. Subtitle as a layer in web page outside video player. e.g. outside JW Player.
This is no longer video technology but HTML

 

PartyCap

Advertisements

ffmpeg output thru http


ffmpeg can output to a remote host that runs web server, e.g nginx.
1. Configure nginx so that it can accept http PUT requests. three items:
Make sure nginx was built with –with-http_dav_module
nginx.conf: under location, add: dav_methods PUT;
Make sure nginx have write access to folder
2. Output to remote host
ffmpeg.exe -i SummerDance2016SC.mp4 -f hls -method PUT http://riowing.net/archive/put/SummerDance2016SC.m3u8

The other option to output to remote requires the remote host to run RTMP server.
The HLS URL generated for playing, of course, is:
http://riowing.net/archive/put/SummerDance2016SC.m3u8

SummerDance2016SC

Streaming to Youtube


We are streaming to YouTube for the first time today, at https://www.YouTube.com/c/RioWingR/live
Our staff is at Klein Memorial Stadium, Spring, TX, from 17:00 to 19:00 PDT, Oct.18, 2018, broadcasting this college football game.
The live game can also be viewed at YouTube app by searching channelĀ “Rio Wing live stream”.
The official way to view the game is at https://www.tsrnsports.com/schedule/?LocationId=2 , a division of MaxxSports.tv, and MaxxSports Android/iOS apps.
YouTube’s input is a RTMP URL, which looks like this: rtmp://a.rtmp.YouTube.com/live2/wa3k-p6y6-pmqv-YOUR
Some RTMP URLs can be used for both input (receiving from FFMPEG) and output (playable by VLC) such as nginx-rtmp-module. However, the RTMP URL from YouTube is only for input, and doesn’t work with players such as VLC.
YouTube RTMP server is quite picky on video; none of our IP cameras’s RTSP video is accepted by YouTube with “-vcodec copy”

YouTubeStream

Live Streaming Options


HLS/DASH:
HTTP segmentation based, high latency
As static HTTP content, well received by players, whether web or native based, and efficient on CDN
distributed by standard HTTP server.
RTSP:
Standard protocol for IP camera video output. Weak browser play support.
Requires router configuration when video source if behind NAT since streaming server have to pull video from video source.
Low latency
RTMP:
Popular with video source since source pushes to streaming server, and therefore no router work is needed when video source is behind NAT.
Low latency
WebRTC:
I believe this will be the protocol to deliver low latency video to browser.
supported by Chrome and Firefox. I don’t include IE/Safari plugin as it requires installation.
Support both VP8/VP9 and H.264 through OpenH264 and ffmpeg
Here is a little page that renders the laptop camera:
http://riowing.net/local/webRTC.htm tested on Edge (Chrome requires https or localhost)

Reference:
https://www.3cx.com/webrtc/which-browsers-support-webrtc
https://www.chromestatus.com/feature/6417796455989248