Videos are sequences of images with audio. They are great way to enhance an AR scene and create more interactive experiences.
|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.
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.
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:
- Upload it as a regular video asset
- Navigate to the global Assets screen
- Open the video preview by clicking on its asset card
- 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.