P
P
pixal2018-05-20 18:42:37
RTMP
pixal, 2018-05-20 18:42:37

Is there a video encoder for broadcasting from Raspberry pi 3 to YouTube or VK?

I need to arrange a broadcast from RPI to VK

Answer the question

In order to leave comments, you need to log in

1 answer(s)
P
Paul Nice, 2018-05-21
@Paul_Nice

Grab ffmpeg and try something like

#! /bin/bash
#
# Пуш HD видео в youtube с помощью http://ffmpeg.org/

VBR="2500k"                                    # Bitrate для видео в кбит/с
FPS="30"                                       # FPS 
QUAL="medium"                                  # пресет для FFMPEG
YOUTUBE_URL="rtmp://a.rtmp.youtube.com/live2"  # RTMP пуш URL

SOURCE="udp://239.255.139.0:1234"              # Source UDP
KEY="...."                                     # ключ трансляции
ffmpeg \
    -i "$SOURCE" -deinterlace \
    -vcodec libx264 -pix_fmt yuv420p -preset $QUAL -r $FPS -g $(($FPS * 2)) -b:v $VBR \
    -acodec libmp3lame -ar 44100 -threads 6 -qscale 3 -b:a 712000 -bufsize 512k \
-f flv "$YOUTUBE_URL/$KEY"

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question