Expand | ||||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| ||||||||||||||
|
BrightSign players support the MPCDI specification for warping and edge blending. This page outlines how to display media—including images, video, and HTML—using MPCDI. Note that some knowledge of BrightScript is required to develop MPCDI applications on BrightSign players.
...
SetMpcdi(parameters As roAssociativeArray) As Boolean
Enables MPCDI using an associatve associative array of parameters. This method returns true
if MPCDI has been enabled and false
if it could not be enabled. The associative array must contain the following parameters:
[region
roAssociativeArray] region: An associative array of parameters containing region data:[xresolution
int] xresolution: The viewport width, which corresponds to the<XResolution>
attribute in the<region>
tag of the mpcdi.xml configuration file[yresolution
int] yresolution: The viewport height, which corresponds to the<YResolution>
attribute in the<region>
tag of the mpcdi.xml configuration file[x
float] x: The region coordinate horizontal position, which corresponds to the<x>
attribute in the<region>
tag of the mpcdi.xml configuration file[y
float] y: The region coordinate vertical position, which corresponds to the<y>
attribute in the<region>
tag of the mpcdi.xml configuration file[xsize
float] xsize: The region coordinate width, which corresponds to the<xsize>
attribute in the<region>
tag of the mpcdi.xml configuration file[ysize
float] ysize: The region coordinate hieght, which corresponds to the<ysize>
attribute in the<region>
tag of the mpcdi.xml configuration file
[blendmaps
roArray] blendmaps: An array containing one or two entries describing blend map data. The array must contain an entry describing alpha map parameters, and may contain a second entry describing beta map parameters. Each entry must have the following parameters:[mapname
string] mapname: The map name, which can be either "alpha" or "beta"[width
int] width: The map width, as provided in the map .png file[height
int] height: The map height, as provided in the map .png file[comdepth
int] comdepth: The number of components held in the map, which corresponds to the<alphaMap>
or<betaMap>
tag in the mpcdi.xml configuration file[size
int] size: The size of the decoded .png file data (in bytes)[gammacorrection
float] gammacorrection: The gamma correction value, which corresponds to the<gammaEmbedded>
attribute in the<alphaMap>
tag of the mpcid.xml configuration file (this setting does not apply to a beta map)[data
roByteArray] data: The decoded .png data
[warp
roAssociativeArray] warp: An associative array of parameters containing warp data:[width
int] width: The width of the geometry warp map, which is provided in the .pfm file[height
int] height: The height of the geometry warp map, which is provied in the .pfm file[data
roArray] data: The extracted .pfm file data as an array of float values
...
Code Block |
---|
[mpcdi_enabled, widget_count, filename.mpcdi, mode, ip_media_filename] |
[string] mpcdi_enabled
string: A flag that determines whether MPCDI is enabled ("on") or disabled ("off")[int] widget_count
int: The number of widgets to display on screen (1, 2, or 3). If you specify a single widget, the image/video widget will be displayed as full screen.[string] filename.mpcdi
string: The name of the .mpcdi file[mode
string] mode: The mode of the image/video widget ("image" or "video")[string] ip_media_filename
string: The name of the media file to display in the image/video widget.
...