Skip to content

Embedding the Player

Georgi Marinov edited this page Sep 4, 2017 · 5 revisions

Let's look at how you can embed Vizor content onto any website.

First, you have to publish your Vizor experience. After publishing, you can find the embed code under the Share button in Vizor player.

The player embed code will attempt to size the player to fit the available dimensions in its container element, whilst preserving aspect.

You can change some parameters to control behaviour of the embed.

  • autoplay=true - can we preload 20Mb without asking? Depends on the visitor. This makes the scene play without waiting. We won't judge.

  • noheader=true - This removes the controls (VR, Fullscreen, Share and edit-buttons).

  • data-aspect - The iframe normally tries to resize to 16:9 aspect ratio every time. To change the proportion, put in your desired width:height, e.g. data-aspect="1.33".

Example

In code.

<script src="//patches.vizor.io/scripts/embed.js" 
data-vizorurl="//patches.vizor.io/embed/matt/hmd-bake-spinner?autoplay=true&noheader=false" 
data-aspect="1.33"></script>
Clone this wiki locally