Coder Social home page Coder Social logo

multistream's Introduction

Multistream

This is a small little tool for multistreaming without a huge hassle.

Prerequisites

  • Requires FFMPEG installed on your path, Google it ;)
  • Requires Java 11 or greater. You can grab that here

Starting and Stoping

Double click either start.sh (for Unix/macOS (make sure to chmod +x!)) or start.bat (for Windows).

While that is open, you can set OBS to stream to rtmp://localhost:1935 (without a streamkey). Clicking "Start Streaming" in OBS will start all of the configured targets. Modify your bitrate and resolution how you normally would via OBS.

Clicking "Stop Streaming" will cause the configured targets to stop.

Performance

This program will just copy the audio/video information directly to the targets, which allows for much better performance when compared to other solutions because you're not encoding multiple streams.

Configuring

The program auto reloads the config when you click save, just make sure to restart your stream if it's active. If the config file doesn't exist a default one will be created.

debug

Enables debug logging, which can get really spammy really quickly.

disableColoredConsole

Disables color in the console, useful if your terminal application does not support color.

showPreview

Opens a preview window which is muted by default. Spam 0 on your keyboard to increase volume.

recordToFile

Dumps video to a new mkv file.

rtmpTargets

A list of rtmp server urls to use. Prefix with # to disable.

Here's an example of how to stream to Twitch: "rtmp://live-dfw.twitch.tv/app/STREAMKEY"

Here's an example of how to temporarily disable streaming to Twitch: "#rtmp://live-dfw.twitch.tv/app/STREAMKEY"

customTargets

A list of custom commands to run when the stream starts, video is piped into stdin using the nut container format. Prefix with # to disable.

Here's an example of how to stream to Caffeine via SRT:
"ffmpeg -hide_banner -v error -f nut -i pipe:0 -c copy -f mpegts SRT_URL_HERE"

Full Example Config

{
    "debug": false,
    "disableColoredConsole": false,
    "showPreview": false,
    "recordToFile": true,
    "rtmpTargets": ["rtmp://live-dfw.twitch.tv/app/STREAM_KEY", "rtmp://livepush.trovo.live/live/STREAM_KEY"],
    "customTargets": []
}

multistream's People

Contributors

e3ndr avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar

multistream's Issues

No connect

I'm on linux.
OBS does not want to connect to "rtmp://localhost:1935"
I checked with the following commands that everything was ok.
sudo lsof -i:1935
netstat -ltn
I don't put a key in obs.
obs3
obs1
obs2
obs

Windows - Closing a Console Does not Terminate FFMPEG

When running on Windows, if you close the console window while running the included bat script FFMPEG will not terminate. It will continue to run in the background and will keep opening every time you launch the BAT file. There is no indication on the Java app that there are other instances of on the same port or IP. It just won't work.

I have not seen if a CTRL + C will properly close FFMPEG so that might be worth looking into.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.