- changed status to resolved
cmd/vidforward: write functionality to send slate as h264 down revid for an RTMP endpoint
To enable persistent broadcasts, we’d like to be able to send h264 still images to RTMP endpoints for cameras that are down, either because it’s nighttime or for maintenance/problems etc. Initially for prototyping, we’ll provide a raw .h264 file representation of the image in our binary directory that we’ll load and continually write to the pipeline (eventually we can use the control API to send the image through vidgrind; this will be nice for non engineers that want to update the slate). We’ll have to modify how we configure vidforward with “active broadcast” information as there’ll now be 3 possible states i.e. active, slate or inactive. It might be worth sorting the control API before we do this; over using the current variable based configuration mechanism.
Side note, we can use ffmpeg to generate our h264 from an image.
No audio (-t 10 means 10 second duration):
ffmpeg -loop 1 -framerate 24 -i input.jpg -c:v libx264 -preset slow -tune stillimage -crf 24 -vf format=yuv420p -t 10 -movflags +faststart output.mp4
With audio (I think the “-shortest” flag makes this as long as the audio is):
ffmpeg -loop 1 -framerate 24 -i input.jpg -i audio.mp3 -c:v libx264 -preset slow -tune stillimage -crf 24 -vf format=yuv420p -c:a aac -shortest -movflags +faststart output.mp4
Comments (2)
-
reporter -
reporter - edited description
- Log in to comment
Merged in write-slate (pull request #487)
cmd/vidforward: add slate image write functionality
Resolves issue
#379Approved-by: Alan Noble Approved-by: Russell Stanley Approved-by: Trek Hopton
→ <<cset 0e6fb9546103>>