Javascript SDK
Last updated
Last updated
You can use Streams JS SDK to send messages from the client side to your application.
Embed the script code between the <head> </head>
tags inside the page you embedded your Streams Link via iframe.
Then you will be able to use the JS methods to create your custom user experience for your application Stream.
Demo HTML
Client-side Integration Functionalities and events have support for all types of Streaming you can use inside Vagon Streams.
Connection status, returns boolean.
Sends the related message to your application.
Updates the streaming resolution and matches the iframe height and width when initiated.
Keeps the browser window focused on the streaming iframe. In case you are facing issues with keyboard inputs, you can use this method.
If your visitors are using your Applications on mobile/tablet devices, you can also allow them to type with the on-screen keyboard inside Vagon Streams.
When the focus changes from the text input, you can hide the on-screen keyboard button from the screen as well.
Activates 360 View cursor mode inside an active Stream.
Disable 360 View cursor mode inside an active Stream.
Reset Idle Timer by sending a simulated user input when the Idle Duration Limit is active.
Shut down the Stream Machine and terminate the related session immediately.
Quality parameters can be set as "standard", "moderate" or "high". Session will be refreshed automatically after the quality is set.
Triggers the onSessionInformation
event, data must be collected via onSessionInformation
event.
Set the sound of your Stream link between 0 to 1.
All events except onApplicationMessage, onConnected and onDisconnected are only available in Enterprise Plan.
Prints out the message sent from the application, for application-side integration please check Unreal Engine and Unity SDKs.
Prints out the message when the pointer lock (360 View Mode) state changes.
Prints out the message during the Stream initialization process.
Prints out the message during the pixel streaming asset preparation process. Only available in Pixel Streaming enabled Streams.
Prints out the message when application is on installing state.
Prints out the message when user is connected.
Prints out the message when user is disconnected.
Prints out the message when user is inactive. Only available when Idle Duration Limit is active.
Prints out the message when app installation is failed.
Prints out the message when connection is failed.
Prints out the message when connection is failed.
Sample Session Data
You can use both EmitUI and functionalities for Unreal Engine Pixel Streaming enabled Stream links.