Hmm I don't know. My python script basically just runs ffmpeg in a shell. It uses nethogs (in Ubunu) to measure how much bandwidth ffmpeg is using. If it drops below a certain level the script restarts the ffmpeg process. I also have different buttons for manually starting and stopping each of the 5 camera streams. Plus turning the auto-restart on and off.
It wouldn't be hard at all to make a script that would let you switch which input stream to use for the destination. The ffmpeg process would restart though so there would be a very short interruption in the sending to the destination rtmp address. Basically I'm using python to manage ffmpeg sessions. I"m not using a rtmp library in python. I don't know if there is one. On Sun, Mar 31, 2019 at 2:47 AM qw <[email protected]> wrote: > Hi, > > > Does python's rtmp lib support switch two input rtmp streams, and relay > one of them to destination rtmp address? > > > Thanks! > > > Regards > > > Andrew > > > > At 2019-03-31 00:09:17, "Michael Shaffer" <[email protected]> wrote: > >I haven't used Nginx but I think it does rtmp relay. I used a python > script > >for relaying from my ip cameras to youtube.. > > > >On Sat, Mar 30, 2019 at 12:08 PM Michael Shaffer <[email protected]> > >wrote: > > > >> Nginx > >> > >> On Sat, Mar 30, 2019 at 12:05 PM qw <[email protected]> wrote: > >> > >>> Hi, > >>> > >>> > >>> Is there some active popular rtmp server that can relay rtmp stream? > >>> > >>> > >>> > >>> Thanks! > >>> > >>> > >>> Regards > >>> > >>> > >>> Andrew > >>> > >>> > >>> > >>> > >>> At 2019-03-30 23:52:45, "Michael Shaffer" <[email protected]> > wrote: > >>> >I don't think so. I think you have to use an older version of ffmpeg. > I > >>> >could never get ffserver to work right.. > >>> > > >>> >On Sat, Mar 30, 2019 at 11:49 AM qw <[email protected]> wrote: > >>> > > >>> >> Hi, > >>> >> > >>> >> > >>> >> does ffmpeg 4 still support ffserver? > >>> >> > >>> >> > >>> >> > >>> >> Regards > >>> >> > >>> >> > >>> >> Andrew > >>> >> _______________________________________________ > >>> >> ffmpeg-user mailing list > >>> >> [email protected] > >>> >> https://ffmpeg.org/mailman/listinfo/ffmpeg-user > >>> >> > >>> >> To unsubscribe, visit link above, or email > >>> >> [email protected] with subject "unsubscribe". > >>> >_______________________________________________ > >>> >ffmpeg-user mailing list > >>> >[email protected] > >>> >https://ffmpeg.org/mailman/listinfo/ffmpeg-user > >>> > > >>> >To unsubscribe, visit link above, or email > >>> >[email protected] with subject "unsubscribe". > >>> _______________________________________________ > >>> ffmpeg-user mailing list > >>> [email protected] > >>> https://ffmpeg.org/mailman/listinfo/ffmpeg-user > >>> > >>> To unsubscribe, visit link above, or email > >>> [email protected] with subject "unsubscribe". > >> > >> > >_______________________________________________ > >ffmpeg-user mailing list > >[email protected] > >https://ffmpeg.org/mailman/listinfo/ffmpeg-user > > > >To unsubscribe, visit link above, or email > >[email protected] with subject "unsubscribe". > _______________________________________________ > ffmpeg-user mailing list > [email protected] > https://ffmpeg.org/mailman/listinfo/ffmpeg-user > > To unsubscribe, visit link above, or email > [email protected] with subject "unsubscribe". _______________________________________________ ffmpeg-user mailing list [email protected] https://ffmpeg.org/mailman/listinfo/ffmpeg-user To unsubscribe, visit link above, or email [email protected] with subject "unsubscribe".
