Skip to content

Commit 0dd03ac

Browse files
authored
Update README.md
1 parent 4bff594 commit 0dd03ac

File tree

1 file changed

+81
-42
lines changed

1 file changed

+81
-42
lines changed

Diff for: README.md

+81-42
Original file line numberDiff line numberDiff line change
@@ -172,61 +172,100 @@ To get the list of supported commands with your version of the code, run `python
172172
Sample help output: ( what's shown below may not be up-to-date)
173173

174174
```
175-
usage: publish.py [-h] [--streamid STREAMID] [--server SERVER]
176-
[--bitrate BITRATE] [--width WIDTH] [--height HEIGHT]
177-
[--framerate FRAMERATE] [--test] [--hdmi] [--v4l2 V4L2]
178-
[--rpicam] [--nvidiacsi] [--alsa ALSA] [--pulse PULSE]
179-
[--raw] [--h264] [--nvidia] [--rpi] [--novideo] [--noaudio]
180-
[--pipeline PIPELINE]
181-
182-
optional arguments:
175+
usage: publish.py [-h] [--streamid STREAMID] [--room ROOM] [--rtmp RTMP] [--whip WHIP] [--bitrate BITRATE]
176+
[--audiobitrate AUDIOBITRATE] [--width WIDTH] [--height HEIGHT] [--framerate FRAMERATE]
177+
[--server SERVER] [--puuid PUUID] [--test] [--hdmi] [--camlink] [--z1] [--z1passthru]
178+
[--apple APPLE] [--v4l2 V4L2] [--libcamera] [--rpicam] [--format FORMAT] [--rotate ROTATE]
179+
[--nvidiacsi] [--alsa ALSA] [--pulse PULSE] [--zerolatency] [--raw] [--bt601] [--h264] [--x264]
180+
[--openh264] [--vp8] [--vp9] [--aom] [--av1] [--rav1e] [--qsv] [--omx] [--vorbis] [--nvidia] [--rpi]
181+
[--multiviewer] [--noqos] [--nored] [--novideo] [--noaudio] [--led] [--pipeline PIPELINE]
182+
[--record RECORD] [--view VIEW] [--save] [--midi] [--filesrc FILESRC] [--filesrc2 FILESRC2]
183+
[--pipein PIPEIN] [--ndiout NDIOUT] [--fdsink FDSINK] [--framebuffer FRAMEBUFFER] [--debug]
184+
[--buffer BUFFER] [--password [PASSWORD]] [--hostname HOSTNAME] [--video-pipeline VIDEO_PIPELINE]
185+
[--audio-pipeline AUDIO_PIPELINE] [--timestamp] [--clockstamp]
186+
187+
options:
183188
-h, --help show this help message and exit
184189
--streamid STREAMID Stream ID of the peer to connect to
185-
--server SERVER Handshake server to use, eg:
186-
"wss://wss.vdo.ninja:443"
187-
--bitrate BITRATE Sets the video bitrate. This is not adaptive, so
188-
packet loss and insufficient bandwidth will cause
189-
frame loss
190-
--width WIDTH Sets the video width. Make sure that your input
191-
supports it.
192-
--height HEIGHT Sets the video height. Make sure that your input
193-
supports it.
190+
--room ROOM optional - Room name of the peer to join
191+
--rtmp RTMP Use RTMP instead; pass the rtmp:// publishing address here to use
192+
--whip WHIP Use WHIP output instead; pass the https://whip.publishing/address here to use
193+
--bitrate BITRATE Sets the video bitrate; kbps. If error correction (red) is on, the total bandwidth used may be
194+
up to 2X higher than the bitrate
195+
--audiobitrate AUDIOBITRATE
196+
Sets the audio bitrate; kbps.
197+
--width WIDTH Sets the video width. Make sure that your input supports it.
198+
--height HEIGHT Sets the video height. Make sure that your input supports it.
194199
--framerate FRAMERATE
195-
Sets the video framerate. Make sure that your input
196-
supports it.
200+
Sets the video framerate. Make sure that your input supports it.
201+
--server SERVER Handshake server to use, eg: "wss://wss.vdo.ninja:443"
202+
--puuid PUUID Specify a custom publisher UUID value; not required
197203
--test Use test sources.
198-
--rtmp Use RTMP instead of webRTC; pass "rtmp://xxxx.com/live/xxx-xxxx-xxx"
199-
--whip Use WHIP output instead of VDO.Ninja; pass "https://some.whipdomain.com/streamtoken"
200204
--hdmi Try to setup a HDMI dongle
201-
--camlink Try to use Elgato Camlink as source
205+
--camlink Try to setup an Elgato Cam Link
206+
--z1 Try to setup a Theta Z1 360 camera
207+
--z1passthru Try to setup a Theta Z1 360 camera, but do not transcode
208+
--apple APPLE Sets Apple Video Foundation media device; takes a device index value (0,1,2,3,etc)
202209
--v4l2 V4L2 Sets the V4L2 input device.
203-
--rpicam Sets the RaspberryPi input device.
210+
--libcamera Use libcamera as the input source
211+
--rpicam Sets the RaspberryPi CSI input device. If this fails, try --rpi --raw or just --raw instead.
212+
--format FORMAT The capture format type: YUYV, I420, BGR, or even JPEG/H264
213+
--rotate ROTATE Rotates the camera in degrees; 0 (default), 90, 180, 270 are possible values.
204214
--nvidiacsi Sets the input to the nvidia csi port.
205215
--alsa ALSA Use alsa audio input.
206216
--pulse PULSE Use pulse audio (or pipewire) input.
217+
--zerolatency A mode designed for the lowest audio output latency
207218
--raw Opens the V4L2 device with raw capabilities.
208-
--bt601 Changes the input color profile when in raw mode to BT601
209-
--h264 For PC, instead of VP8, use x264.
210-
--vp8 VP8 encoder instead of h264; likely software-based
211-
--aom Use AV1-AOM software encoding for publishing
212-
--av1 Whatever AV1 encoder the script can find; more can be added on request
213-
--qsv Intel quicksync avi encoder
214-
--nvidia Creates a pipeline optimized for Nvidia (Jetson?) hardware encoders
215-
--rpi Creates a pipeline optimized for Raspberry Pi (0,1,2,3,4) hardware encoders (⚠️RPi-5 doesn't have a hardware encoder)
219+
--bt601 Use colormetery bt601 mode; enables raw mode also
220+
--h264 Prioritize h264 over vp8
221+
--x264 Prioritizes x264 encoder over hardware encoder
222+
--openh264 Prioritizes OpenH264 encoder over hardware encoder
223+
--vp8 Prioritizes vp8 codec over h264; software encoder
224+
--vp9 Prioritizes vp9 codec over h264; software encoder
225+
--aom Prioritizes AV1-AOM codec; software encoder
226+
--av1 Auto selects an AV1 codec for encoding; hardware or software
227+
--rav1e rav1e AV1 encoder used
228+
--qsv Intel quicksync AV1 encoder used
229+
--omx Try to use the OMX driver for encoding video; not recommended
230+
--vorbis Try to use the OMX driver for encoding video; not recommended
231+
--nvidia Creates a pipeline optimised for nvidia hardware.
232+
--rpi Creates a pipeline optimised for raspberry pi hardware encoder. This wont work with the
233+
Raspberry Pi 5, as it has no hardware encoder..
234+
--multiviewer Allows for multiple viewers to watch a single encoded stream; will use more CPU and bandwidth.
235+
--noqos Do not try to automatically reduce video bitrate if packet loss gets too high. The default
236+
will reduce the bitrate if needed.
237+
--nored Disable error correction redundency for transmitted video. This may reduce the bandwidth used
238+
by half, but it will be more sensitive to packet loss
216239
--novideo Disables video input.
217240
--noaudio Disables audio input.
218-
--omx An alternative hardware encoder for the RPi; glitches, but faster?
241+
--led Enable GPIO pin 12 as an LED indicator light; for Raspberry Pi.
219242
--pipeline PIPELINE A full custom pipeline
220-
--record STREAMID Specify a remote stream ID to record; this will disable publishing mode
221-
--midi MIDI transport; can forward/recieve MIDI to remote browser/device
222-
--save Will save a local copy of the outbound stream to disk (MKV format)
223-
--rotate DEGREES Will rotate the video by 90, 180 , or 270 degrees
224-
--multiviewer Allows for multiple viewers at a time; this can increase bandwidth usage of course
225-
--nored Disable error correction. If you don't disable it, the bandwidth may be up to 2x higher than the target video bitrate. I do not recommend removing, unless you're on a pristine connection.
226-
--noqos This will disable the qos feature. The QOS feature will lower the bitrate of the video encoder if heavy packet loss is detected. It won't lower it more than 5x (20% of target), but I find this works well to combat times where the network bandwidth is insufficient.
227-
--pipein Lets you pipe data in from a unix pipe, something like: `ffmpeg -i input.mp4 -o - | python3 publish.py --pipein auto`
228-
--libcamera Use libcamera as a source; this may be needed if using third party cameras like those from Arducam
229-
243+
--record RECORD Specify a stream ID to record to disk. System will not publish a stream when enabled.
244+
--view VIEW Specify a stream ID to play out to the local display/audio.
245+
--save Save a copy of the outbound stream to disk. Publish Live + Store the video.
246+
--midi Transparent MIDI bridge mode; no video or audio.
247+
--filesrc FILESRC Provide a media file (local file location) as a source instead of physical device; it can be a
248+
transparent webm or whatever. It will be transcoded, which offers the best results.
249+
--filesrc2 FILESRC2 Provide a media file (local file location) as a source instead of physical device; it can be a
250+
transparent webm or whatever. It will not be transcoded, so be sure its encoded correctly.
251+
Specify if --vp8 or --vp9, else --h264 is assumed.
252+
--pipein PIPEIN Pipe a media stream in as the input source. Pass `auto` for auto-decode,pass codec type for
253+
pass-thru (mpegts,h264,vp8,vp9), or use `raw`
254+
--ndiout NDIOUT VDO.Ninja to NDI output; requires the NDI Gstreamer plugin installed
255+
--fdsink FDSINK VDO.Ninja to the stdout pipe; common for piping data between command line processes
256+
--framebuffer FRAMEBUFFER
257+
VDO.Ninja to local frame buffer; performant and Numpy/OpenCV friendly
258+
--debug Show added debug information from Gsteamer and other aspects of the app
259+
--buffer BUFFER The jitter buffer latency in milliseconds; default is 200ms. (gst +v1.18)
260+
--password [PASSWORD]
261+
Specify a custom password. If setting to false, password/encryption will be disabled.
262+
--hostname HOSTNAME Your URL for vdo.ninja, if self-hosting the website code
263+
--video-pipeline VIDEO_PIPELINE
264+
Custom GStreamer video source pipeline
265+
--audio-pipeline AUDIO_PIPELINE
266+
Custom GStreamer audio source pipeline
267+
--timestamp Add a timestamp to the video output, if possible
268+
--clockstamp Add a clock overlay to the video output, if possible
230269
```
231270

232271
##### Changing video input sources

0 commit comments

Comments
 (0)