Videos are sequences of images with audio. They are great way to enhance an AR scene and create more interactive experiences.

Supported formats

Onirix supports AVI and MP4 video containers. Libavcodec is used internally to read and decode video files, so supported video codecs are libavcodec supported ones.

Feature Support
Video container AVI, MP4
Video codec Supported codecs
Video size Up to 50MB
Video duration Up to 2min
Video resolution Up to 4K (will be downscaled to a width of 720px)

When a new video is uploaded, a conversion process will run to resize and re-encode it so it can be run on mobile devices.

Video properties

When adding a video to the scene, Studio will automatically create a "click" event to play it when clicked. You can remove this event or create new ones to manage its playback.

You can also set up the following properties from the right side panel:

  • Autoplay: Plays automatically when element loads if enabled.
  • Positional: Uses positional audio if enabled. It will sound louder when close.
  • Loop: Plays again when finish and every time.

The autoplay property, when using WebAR in Safari (iOS) will only work if the video does not contain an audio track. This is a Safari limitation, as stated in webkit documentation.

Chroma key videos (transparent)

When it comes to create 2D animations, chroma key videos are your best choice.

A chroma key video, is a regular video where you can replace a color (typically from the background) with transparency, in order to create 2D animations with any shape.

Here there are the steps to "mark" a video as a chroma key video:

  1. Upload it as a regular video asset
  2. Navigate to the global Assets screen

  1. Open the video preview by clicking on its asset card
  2. Enable the chroma video switch in the right side of the emerging dialog. After that, two new inputs will appear:
  • Color: The color you want to replace with transparency (usually green or black).
  • Tolerance: You may want to adjust this value depending on the amount of noise of the background.


Try yourself: demo of image tracking with video (Golden Gate bridge)


Battery repair (scene-tracking)

Leia hologram (image-tracking)