Media
A Media
object contains the metadata and files for Media from the Svrf API.
Name | Type | Description |
---|---|---|
id | string | The unique ID of this Media. |
title | string | The title of the Media, suitable for displaying. |
description | string | A description of the Media. |
authors | string[] | The Media's authors. This should be displayed when possible. |
site | string | The site that this Media came from. This should be displayed |
canonical | string | The canonical page this Media can be found at via Svrf. |
url | string | The original page this Media is located at. |
embedUrl | string | A player that can be embedded using an <iframe> tag to play the Media. |
embedHtml | string | An <iframe> tag that embeds a player that plays the Media. |
type | string | The type of the Media. This should influence the media controls |
adult | boolean | Whether the Media is adult content. |
width | number | The width, in pixels, of the Media's source. |
height | number | The height, in pixels, of the Media's source. |
duration | number | The duration of the Media in seconds. |
metadata | object | Metadata about the Media. |
metadata.isFaceFilter | boolean | For 3D Media, denotes that this model can be applied as a face filter overlay on a video of a face. |
metadata.hasBlendShapes | boolean | For 3D Media, denotes that this model contains blend shapes, but having to calculate and apply weights to them is not |
metadata.requiresBlendShapes | boolean | For 3D Media, denotes that calculating and applying blend shape weights to this model is required for the correct experience. If your platform cannot detect and calculate blend shape weights you MUST NOT present these models to your users. |
files | object | Various sizes of images and resolutions for the Media. They will never be larger than the Media source's original resolution. |
files.images | object | Resized jpeg stills of the Media. For video, these will be stills from 1/3 of the video's duration. Resolutions larger than the original size will not be included (the original is included as max). For stereoscopic content, this will be a monoscopic version of the top or left channel. |
files.videos | object | Resized mp4 (H.264) videos of the Media. Only included if the Media is video. Resolutions larger than the original size will not be included (the original is included as max). For stereoscopic content, this will be a monoscopic version of the top or left channel. |
files.stereo | object | Resized versions of the Media, matching the Media's type, in stereo. Only included if the Media is stereoscopic. Resolutions larger than the original size will not be included (the original is included as max). |
files.gltf | object | A map of file names to urls where those files are hosted. The file names are relative and their name hierarchy should be respected when saving them locally. |
files.glb | string | This is the binary glTF format that should be used by clients if the Media is a 3D object. This is the preferred format to use on end-user devices. |
files.glb-draco | string | This is the binary glTF format, with additional DRACO compression, that should be used by clients if the Media is a 3D object. Your renderer must support the KHR_draco_mesh_compression extension to use this model. |