Name
VIDEO -- preload a video for later use (V5.0)
Synopsis
@VIDEO id, filename$[, table]
Function
Use this preprocessor command to preload a video which you want to play later using PlayVideo().

Video formats that are supported on all platforms are CDXL and formats you have a plugin for. Depending on the platform Hollywood is running on, more video formats might be supported. On Windows Hollywood is able to open all video formats for which you have a DirectShow codec installed. On macOS Hollywood can open all video formats that are supported by AV Foundation (or QuickTime on older Macs).

The third argument is optional. It is a table that can be used to set further options for the opening operation. The following fields of the table can be used:

Link:
Set this field to False if you do not want to have this video linked to your executable/applet when you compile your script. This field defaults to True which means that the video is linked to your to your executable/applet when Hollywood is in compile mode.

Loader:
This tag allows you to specify one or more format loaders that should be asked to load this video. This must be set to a string containing the name(s) of one or more loader(s). Defaults to default. This means that Hollywood will first ask all plugins whether they would like to handle the video file, then it will check its inbuilt loaders (currently only CDXL), and finally it will ask the video interface of the host OS to play this video. If you want to customize this order, use this tag. See Loaders and adapters for details. (V6.0)

Adapter:
This tag allows you to specify one or more file adapters that should be asked to open the specified file. This must be set to a string containing the name(s) of one or more adapter(s). Defaults to default. See Loaders and adapters for details. (V6.0)

If you want to open the video manually, please use the OpenVideo() command.

Inputs
id
a value that is used to identify this video later in the code
filename$
the file you want to have loaded
table
optional: a table containing further options
Example
@VIDEO 1, "intro.avi"
The code above opens "intro.avi" so that it can be played later using PlayVideo().

Show TOC