OWL Spout Sender/ Receiver

An integration of Spout into Unreal Engine with up to 32bit color support, alpha channel support and zero-latency/ compression output from all major Unreal tools like nDisplay, Media Capture, Composure, Media Plate, Render Target etc.

Last updated 3 days ago

Overview

Spout is a protocol which allows you to share a video texture being rendered on your GPU between two (or more) software programs running on the same machine.

This means that it doesn’t require encoding, and so has zero-latency (max 1 frame), compression and CPU overhead.

Spout is supported by a wide range of creative software like OBS Studio, TouchDesigner, Resolume, MadMapper, LightAct, Assimilate FX etc.

We have integrated Spout into a wide range of Unreal inputs and outputs to suit a wide variety of different media workflows and can be used in Editor, Runtime or Packaged modes:

  • You can live output from any of the OWL Capture formats (Viewport, Cinecam, 360 Camera) direct to Spout using our Media Output Wizard.

  • You can live input Spout into an Unreal Media Plate, Plane or Material using our Media Input Wizard.

  • If you want to use Spout with Unreal native tools like nDisplay, Media Capture, Composure, Media Plate etc. you can use our Unreal Media Framework integration.

  • If you want to send or receive an Unreal Render Target, you can do so using the OWL Spout Sender/ Receiver Manager.

Spout Sender

You can live-stream from Unreal Engine via Spout either from a Render Target or from Unreal's Media Framework which can be used with nDisplay, Composure, Media Capture and other useful tools.

Performance

  • Using Spout won’t affect the performance of your project/ game.

  • That’s because it just shares the pixels that are already being rendered on your GPU, rather than having to use the CPU/ GPU to encode/ decode them.

  • The main downside of Spout is that it’s limited to a single machine, because the different software programs are literally sharing the video texture that is being rendered on the GPU.

  • Spout has no resolution cap so this will only be determined by what your GPU can render at your target resolution.

  • Spout has no FPS cap so you can share very high FPS outputs (>120FPS).

  • Spout can send up to 32bit color from Unreal.

    • Your output will be set by default to RGBA16f (16bit color with alpha channel).

    • You can change this by opening the Render Target and selecting a different Render Target Format:

    • N.B. Not all Spout Receivers can handle 32bit color (for example OBS Studio is 8bit only).

Sender Set-Up

Features

  • You can use three different methods (listed below) to send Spout from Unreal using Off World Live, all of them include these features:

  • Active: A tickbox you can use to turn your Sender on/ off.

    • You can leave these open if you want as they don’t create any CPU/ GPU overhead.

  • Name/ Standalone Name: This is the name you will see in your Spout receiver software.

    • If you are using Unreal in Standalone mode then you can set this value.

  • Fix Gamma: Unreal works in Linear colorspace and then applies an sRGB conversion to the Editor UI.

    • If you want an output that looks identical to your Editor Viewport then keep this ticked.

    • If you want the raw color values from the Render Target then untick.

  • Source Render Target: This is only present in the OWL Spout Sender Manager.

    • It is a Render Target from a Camera or Unreal output that will be sent via Spout.

    • If you are using the Unreal Media Framework integration, the Render Target will be selected automatically.

Media Output Wizard

You can use this method to output from any of the OWL Capture formats to Spout:

  1. In the Off World Live Unreal Editor drop down select the Media Output Wizard:

  2. Select the settings you need (if you want alpha channel you need to set this on the Camera) and then click Create:

  3. If you go to your Spout Receiver you will now see the output you have created.

  4. You will also have added a Spout Sender Manager Actor and OWL Capture Actor of which you can use the Details panel to modify your content:

Unreal Media Framework

You can use this method to output from any of the Unreal creative tools (nDisplay, Composure, Media Capture etc.) to Spout:

  1. Right click in the Content Browser and select OWL Spout Output:

  2. A new Spout Media Output Actor will be created in the Content Browser:

  3. Double click the Actor to change its properties:

    • Number of Texture Buffers: will set the number of textures used to transfer the texture from the GPU to system memory.

      • A smaller number is most likely to block the GPU (wait for the transfer to complete).

      • A larger number is most likely to increase latency.

    • Has Priority: enables the sender to take precedence if multiple senders try to use the same name.

      • This is useful when you want this sender to be the main or fallback sender.

  4. Now in Unreal creative tools like nDisplay you can go to the Media Output dropdown and select the OWL Spout Output as a Media Output option:

  5. You need to create a new Spout Media Output Actor for each separate Spout output you want to send.

Spout Sender Manager

You can use this method if you want to output a Render Target via Spout.

  1. Find the OWLSpoutSenderManager Actor in the Place Actors panel and drag it into your scene.

  2. In World Outliner select OWLSpoutSenderManager so it opens in your Details panel and add a new Array element using the + sign.

  3. You will need to select/ create a Render Target by clicking the drop down next to the thumbnail:

  4. You will now see your Unreal Engine feed in your other Spout program (ie OBS Studio).

  5. If you want to output more Render Targets, just add another Array element.

  6. You can use blueprints to switch the Render Target which can be useful for live-editing between different camera angles while sending to a single Spout receiver.

Sending to Other Software

Numerous creative media software solutions support Spout. Some of the main Unreal workflows are shown below.

OBS Studio

  • To receive Spout in OBS Studio you need our Spout OBS plugin installed.

  • You can only receive 8bit color currently.

  1. Ensure your Spout Sender is active in Unreal.

  2. In OBS, click the + button in Sources and select Spout2 Capture:

  3. In the window that opens you should automatically see your Spout Sender. If you have more than one, you can use the drop down to select between them:

  4. If you are sending alpha channel, ensure that premultipled alpha is selected in your Composite mode:

TouchDesigner

  • You can see how to receive Spout in TouchDesigner here.

  • You can receive up to 32bit color with alpha channel.

  • See this tutorial for how to live-stream textures from TouchDesigner to Unreal Engine for:

    1. Instancing geometry data from TouchDesigner to Unreal Engine Niagara systems

    2. Streaming tracking data as textures via Spout

    3. Point clouds in Unreal Engine via Spout texture sampling

  • You can also see this masterclass from Function Store on how to recreate instanced geometry in Unreal Engine with data generated real-time in TouchDesigner.

Resolume

  • You can see how to receive Spout in Resolume here.

  • You can receive up to 16bit color with alpha channel.

Spout Receiver

You can live-stream to Unreal Engine via Spout either into a Render Target or in to Unreal's Media Framework which can be used with nDisplay, Composure, Media Plate and other useful tools:

Performance

  • Using Spout won’t affect the performance of your project/ game.

  • That’s because it just shares the pixels that are already being rendered on your GPU, rather than having to use the CPU/ GPU to encode/ decode them.

  • The main downside of Spout is that it’s limited to a single machine, because the different software programs are literally sharing the video texture that is being rendered on the GPU.

  • Spout can receive up to 32bit color in Unreal, this is done automatically depending what you select in your Sender.

  • If you have multiple inputs then you will start to see a performance decline because, although they don’t need to be decoded, they still need to be rendered in Unreal.

  • Spout has no resolution cap so this will only be determined by what your GPU can render at your target resolution.

    • However, receiving large textures >8K is likely to be very intensive for your VRAM capacity so you need to ensure your GPU has the specs to do so.

Receiver Set-Up

Features

  • You can use three different methods (listed below) to receive Spout into Unreal using Off World Live, all of them include these features:

  • Active: A tickbox you can use to turn your Receiver on/ off.

    • You can leave these open if you want as they don’t create any CPU/ GPU overhead.

  • Name: This dropdown list will show all Spout Senders that are currently active on your machine.

  • Fix Gamma: Unreal works in Linear colorspace and then applies an sRGB conversion to the Editor UI.

    • If you want color consistency with your Unreal Viewport tick this option and we will convert the Spout input to Linear so Unreal can convert it back.

    • Keep this unticked if you want to use the Spout input as data such as from TouchDesigner, otherwise it will be distorted by the conversion.

  • Upgrade 8bit to 16: If you are receiving an 8bit color texture then the gamma conversion above can result in loss of colors.

    • This tickbox converts the input to 16bit before the gamme conversion so the colors remain the same.

  • Render Target: This is only in the OWL NDI Receiver Manager.

    • If you are using the Unreal Media Framework or Media Plane then the Render Target is handled in the background.

Media Input Wizard

This is the fastest way to set up an Spout input to Unreal with compatibility to an Unreal Media Plate (clean media and no anti-aliasing), Plane or Material.

  1. In the Off World Live Unreal Editor drop down select the Media Input Wizard:

  2. A pop-up will appear in which you can select the Media source you want as well as where you want to display the media:

  3. Click Create and the Spout Receiver will automatically be generated in your scene.

    1. If you select Unreal Media Plate, you will generate an Spout Media Source Actor which you can manage in the Assets section of the Media Plate or your Content Browser.

    2. If you select Plane or Material, you will generate an OWL Spout Receiver Manager Actor which you can manage using its Details panel (see below).

Unreal Media Framework

You can use this method to input Spout to any of the Unreal creative workflows like nDisplay, Composure, Media Plate etc.

  1. Right click the Content Browser and select Spout Media Source:

  2. This will create a Spout Media Source Actor. Double click to access it’s properties.

  3. In the pop-up you can select the Spout input feed as well as any other features you need:

  4. Dragging the OWL Spout Media Source directly in to the viewport will create a new Unreal Media Plate Actor with the Source already assigned.

    1. Click the Open button in the Details panel of the Media plate to make it play:

  5. If you want to add a Spout Source to an existing Unreal Media Plate:

    1. Navigate to the Media Plate Details panel, find the Playlist section and then select the Spout Media Source from the Asset dropdown:

Spout Receiver Manager

You should use the OWL Spout Receiver Manager if you want to output a Render Target from Unreal via NDI.

  1. In World Outliner select OWLSpoutReceiverManager so it opens in your Details panel.

  2. In the Details panel, go to Off World Live Spout Receiver Settings and add a Spout Receiver Array element and click the arrow in the right hand corner to open it:

  3. Once set up, your Spout source will be sending to a Render Target in Unreal which you can use as you need:

  4. To receive multiple input feeds, just add additional Array Elements.

  5. You can control the Active tick-box via Blueprints to manage which cameras are rendering simultaneously and so reduce computational load.

Receiving from Other Software

Numerous creative media software solutions support Spout. Some of the main Unreal workflows are shown below.

OBS Studio

  • To send Spout from OBS Studio you need our Spout OBS plugin installed.

  • You can only send in 8bit color at present.

  • There are two ways to send, via a Filter and using Tools.

  • A filter is recommended because it allows you to send any OBS source as an individual layer and it supports alpha channel output, which allows you to add a chromakey in OBS.

  • If you want to send your whole OBS Canvas then Tools is best.

Filter

  1. Click on the OBS Source you want to send from so it is highlighted blue and then click the Filters button:

  2. In the window that opens click the + button in Effect Filters and select Spout Filter:

  3. Add a name if you need and your Spout output will now be active:

  4. For example, in your Unreal Media Plate you should now see the Spout input (if not, select it from the drop down in your Spout settings):

Tools

  1. In your OBS toolbar go to Tools> Spout Output Settings:

  2. Click AutoStart if you want Spout to always output when you open OBS. Otherwise just tick Start to begin sending your Canvas via Spout (your output will continue to send until you press Stop):

  3. For example, in your Unreal Media Plate you should now see the Spout input (if not, select it from the drop down in your Spout settings):

TouchDesigner

  • You can see how to send Spout from TouchDesigner here.

  • You can send up to 32bit color with alpha channel which will be received correctly in Unreal.

Resolume

  • You can see how to send Spout from Resolume here.

  • You can send up to 16bit color with alpha channel from Resolume.

Distributing with your Project/ App

Spout will work automatically when shared to third party users in projects/ apps (provided you have the correct license).

Blueprints

Switch between Senders

Troubleshooting

Spout has a Demo Sender/ Receiver which can be very helpful when debugging your issues which can be downloaded here.

Black Texture

The most common problem is when your Sender/ Receiver can be selected but the texture shows as black. To resolve this:

  • Download the demo Spout sender/ receiver here to see whether it is the Sender program or the Receiver program that is not working with Spout.

  • Ensure that Unreal Engine and your other program are running on the same GPU (this is an issue with some laptops). To deal with this:

    1. Check Windows Task Manager to see which GPU your programs are running on - guide here

    2. Use the guide here to force your program to use a specific GPU.

  • Ensure that the programs you are sharing between are also in High Performance mode if your computer has any performance throttling (this can be common on laptops).

  • For outputs to OBS on certain laptops you may also need to change your OBS settings here.

Frame Rate Drop when in Background

  • By default, Unreal throttles the CPU when Unreal is in the background vs other software.

    • To change this, go to Editor Preferences and untick Use Less CPU when in Background:

Audio not Playing when Editor in Background

  • By default, Unreal will stop audio playing when the Editor is in the background vs other software.

    • To change this, pick the Engine version you need in your File Explorer and go to the file path:

    • In Config go to BaseEngine.ini and open the notepad:

    • Search for UnfocusedVolumeMultiplier and change the value from 0.0 to 1.0:

    • Save the file and close and re-open Unreal. Your audio will now play continuously no matter if Unreal is in the background or minimised.