VideoThumbnailTile
Generates a sprite of video thumbnails.
imgproxy: video_thumbnail_tile (alias vtt) · Availability: imgproxy Pro only
use SomehowDigital\ImgProxy\Url;use SomehowDigital\ImgProxy\Option\VideoThumbnailTile;
$url = Url::create() ->source('https://example.com/image.jpg') ->options(new VideoThumbnailTile(5, 4, 4, 200, 150));
$url->build();// _/vtt:5:4:4:200:150/plain/https%3A%2F%2Fexample.com%2Fimage.jpgThe option appears in the URL as vtt:5:4:4:200:150.
Parameters
Section titled “Parameters”| Parameter | Type | Default | Description |
|---|---|---|---|
$step |
int |
required | Seconds between frames. 0 disables the sprite; a negative value is calculated automatically. |
$columns |
int |
required | Columns of the sprite. |
$rows |
int |
required | Rows of the sprite. |
$width |
int |
required | Width of a tile. |
$height |
int |
required | Height of a tile. |
$extend |
bool |
— | Extend tiles that are smaller than the tile size. |
$trim |
bool |
— | Trim the tiles. |
$fill |
bool |
— | Fill the tile size by cropping. |
$horizontal |
float |
— | Horizontal focus, from 0 to 1. imgproxy uses 0.5 when left out. |
$vertical |
float |
— | Vertical focus, from 0 to 1. imgproxy uses 0.5 when left out. |
A dash means the argument can be left out. Trailing arguments that are left out or null are dropped from the URL, while a null before a given argument leaves an empty slot, so the following arguments keep their position.