a norns mod to share the screen in near-real-time via the NDI streaming video protocol.
(acrostic in OBS)
(takt in OBS with Color Correction/Color Add)
(awake on iOS NDI Monitor)
(nydl in OBS with Color Correction/Color Add)
Show us your screens! There are lots of ways to do it, from downward-facing cameras to mirrors to VNC to norns.online. This strategy offers a different set of ease-of-use/efficiency/integration tradeoffs that might be interesting to folks projecting, livestreaming, or recording a norns-based performance alongside other video sources.
Earlier related discussions:
NDI is fast, and includes zeroconf-based discovery of stream sources. Many popular streaming and video art tools support discovering and receiving NDI streams, including OBS Studio*, Resolume, Max/MSP/Jitter*, and Touch Designer.
(* requires a plugin)
In NDI’s standard latency mode, a 30fps stream over a local wi-fi network is about a frame behind the norns screen. So far, in informal testing with a Pi CM3+ factory norns, using this mod appears to increase the CPU load by just 1-2%. When using clients like OBS that support NDI’s optional low-latency mode, the network update can be practically simultaneous with the norns screen update.
One disadvantage of NDI is that it’s not a completely open, unencumbered standard (but it is at least royalty-free.)
Alternatives to NDI include RTMP, HLS, or SRT; those may be better for certain purposes and the general structure of this mod could be adapted to other protocols.
- norns 220321
- one or more devices to receive the NDI stream
- From the maiden console, enter:
- In the norns menu, navigate to to SYSTEM > MODS, scroll to NDI-MOD, and turn enc 3
clockwise to add a
+next to the mod name. Hit button 2 to back out, and select
SYSTEM > RESTART to relaunch with the mod loaded.
This will add about 3MB of files to
~/dust/code/ndi-mod. To uninstall everything, disable the mod by reversing the above process, then SYSTEM > RESTART again. Then, go to the maiden library, scroll to
ndi-mod in the installed section, and click remove.
- User’s Guide - viewing NDI streams with OBS Studio, Resolume, Max/MSP/Jitter, Touch Designer, and mobile devices.
- Scripting - customizing the mod behavior from norns scripts and/or the maiden console, including using offscreen images to create additional NDI streams.
- Developing - building and hacking on the mod
At startup the mod hooks
screen.update() and hands the buffer from the Cairo surface to the NDI library, which will encode it and broadcast it from a separate thread. Heavily indebted to @ngwese’s norns-event-demo sample app for illustrating how to incorporate C code into a Lua mod.
- This came together pretty quickly, it’s been tested thoroughly on a couple different systems but there still may be gremlins.
- This mod may conflict with other mods that hook
Scripts that use offscreen cairo surfaces may produce unexpected results.As of version 0.2, this mod behaves with scripts that create offscreen images. You can even share offscreen images as secondary NDI streams!
- Known issues/future thoughts on GitHub.