The Hyperbeam client-side SDK for Unity WebGL.

Looking for the Unity Desktop Application SDK? Request access here.




Required Setup

In order to setup the WebGL SDK you will need a custom WebGL Template in unity. We provide an example one in our API download under Assets/WebGLTemplates/HyperbeamTemplate you can either modify that or copy the steps below into your own template.

Custom Template

In index.html add the folling section.

  import Hyperbeam from "./Hyperbeam.js"
  window.Hyperbeam = Hyperbeam

after the call to createUnityInstance make sure to set the Unity Instance to a variable called unityInstance

createUnityInstance(canvas, config).then((gameInstance) => {
  unityInstance = gameInstance

Starting up the Hyperbeam Stream

To start the hyperbeam stream in untiy attach the HyperbeamController script to an object. Then call HyperbeamController.StartHyperbeamStream(embedUrl) to learn how to display the stream please look at HyperbeamVideoSource