ON THIS PAGE

The videooutput object allows you to configure and retrieve non-persistent settings related to a video output (the video mode itself is configured with the videomodeconfiguration object).

[
    GarbageCollected,
    constructor(DOMString interfaceName)
] interface VideoOutputConfiguration : EventTarget {
    attribute DOMString type;
    Promise<Size> getVideoResolution();
    Promise<Size> getGraphicsResolution();
    Promise<Size> getOutputResolution();
    Promise<> adjustGraphicsColor(ColorProperties);
    Promise<EdidIdentity> getEdidIdentity();
    Promise<DOMString> getEdid();
    Promise<> setMultiScreenBezel(int xPercentage, int yPercentage);
    Promise<> setBackgroundColor(int color);
    Promise<> setPowerSaveMode(bool enable);
    Promise<> set3dMode(int mode);
    Promise<> setSyncDomain(DOMString domain);
	Promise<bool> isAttached();
    [type == "hdmi"] Promise<OutputStatus> getOutputStatus();
    [type == "hdmi"] Promise<> disableAudio(bool disable);
    [type == "hdmi"] Promise<TxHdcpStatus> getTxHdcpStatus();
    [type == "hdmi"] Promise<> forceHdcpOn(bool);
    EventHandler hotplugevent;
};

interface EdidIdentity {
    attribute DOMString manufacturer;
    attribute int product;
    attribute int serialNumber;
    attribute int weekOfManufacture;
    attribute int yearOfManufacture;
    attribute DOMString monitorName;
    attribute DOMString textString;
    attribute DOMString serialNumberString;
    attribute bool bt2020RgbSupport;
    attribute bool bt2020YccSupport;
    attribute bool sdrEotfSupport;
    attribute bool hdrEotfSupport;
    attribute bool hdrSt2084Support;
	attribute bool unstable;
}

interface OutputStatus {
    attribute bool outputPresent;
    attribute bool outputPowered;
    attribute bool unstable;
    attribute DOMString audioFormat;
    attribute int audioSampleRate;
    attribute int audioBitsPerSample;
    attribute int audioChannelCount;
    attribute DOMString eotf;
};

interface Size {
    attribute int width;
    attribute int height;
};

interface ColorProperties {
    attribute int constrast;
    attribute int saturation;
    attribute int hue;
    attribute int brightness;
};


interface TxHdcpStatus {
	attribute DOMString state;
};

Object Creation

To create a videooutput object, first load the brightsign/videooutput module using the Require() method. Then create an instance of the videooutput class with a string value specifying the video output to configure (currently accepted values are "hdmi" and "vga").

var VideoOutputClass = require("@brightsign/videooutput");
var videoOutputHDMI = new VideoOutputClass("hdmi");

VideoOutputConfiguration

Use this interface to perform operations on the video output.

Events

Methods

getVideoResolution()
Promise<Size> getVideoResolution() 

Returns the current resoultion of the video plane.

getGraphicsResolution()
Promise<Size> getGraphicsResolution() 

Returns the current resoultion of the graphics plane.

getOutputResolution()
Promise<Size> getOutputResolution() 

Returns the current video-output resolution.

In most cases, the values returned by the getVideoResolution(), getGraphicsResolution(), and getOutputResolution () methods will be identical. The "GraphicsResolution" and "VideoResolution" values will differ when a 4K video mode is selected and full-resolution graphics is not enabled: The graphics plane remains at HD (1920x1080), while the video plane expands to 4K (e.g. to 3840x2160). The "OutputResolution" value will differ from the other two values when the video output is upscaled: For example, when upscaling from HD to 4K, the "GraphicsResolution" and "VideoResolution" values will remain at 1920x1080, while the "OutputResolution" values will indicate 3840x2160.

adjustGraphicsColor()
Promise<> adjustGraphicsColor(ColorProperties) 

Adjusts the video and graphics output of the player using the options in the passed ColorProperties instance.

getEdidIdentity()
Promise<EdidIdentity> getEdidIdentity()

Returns EDID information from a compatible monitor/television as an EdidIdentity interface.

getEdid()
Promise<DOMString> getEdid()

Returns EDID information from a compatible monitor/television as a hex-encoded string

setMultiScreenBezel()
Promise<> setMultiScreenBezel(int xPercentage, int yPercentage)

Adjusts the size of the bezel used in calculations for multiscreen displays, allowing for users to compensate for the width of their screen bezels. The calculations for the percentages are as follows:

xPercentage = (width_of_bezel_between_active_screens / width_of_active_screen) * 100

yPercentage = (height_of_bezel_between_active_screens / height_of_active_screen) * 100

The bezel measurement is therefore the total of the top and bottom bezels in the y case, or the left and right bezels in the x case. When this value is set correctly, images spread across multiple screens take account of the bezel widths, leading to better alignment of images.

setBackgroundColor()
Promise<> setBackgroundColor(int color)

Specifies the background color using an #rrggbb hex value (8 bits for each color).

setPowerSaveMode()
Promise<> setPowerSaveMode(bool enable)

Disables HDMI output and the syncs for VGA output if passed true. The absence of a signal will cause some monitors to go into standby mode.

set3dMode()
Promise<> set3dMode(int mode)

Sets the 3D video output mode, which is specified by passing one the following parameters:

setSyncDomain() 
Promise<> setSyncDomain(DOMString domain)

Enables Genlock synchronization on the specified BSSyncManager/roSyncManager domain. To disable Genlock on the domain, pass an empty string to this method. To reconfigure an active Genlock synchronization, call SetSyncDomain() again using the domain name of the new or edited sync-manager instance.

isAttached()
Promise<bool> isAttached()

Returns true if the HDMI/VGA video connector is attached to an output device (i.e. the display EDID can be read successfully).

This method will always return false if setPowerSaveMode(true) has been called on the output.

getOutputStatus()
[type == "hdmi"] Promise<OutputStatus> getOutputStatus()

Returns an OutputStatus interface containing information about an attached HDMI display device.

disableAudio()
[type == "hdmi"] Promise<> disableAudio(bool disable)

Disables HDMI audio output if passed true.

getTxHdcpStatus()
[type == "hdmi"] Promise<TxHdcpStatus> getTxHdcpStatus()

Returns a TxHdcpStatus interface indcating the current HDCP status of the HDMI output. 

forceHdcpOn()
[type == "hdmi"] Promise<> forceHdcpOn(bool)

Forces HDCP authentication on the HDMI output if passed true. Passing false to this method will prevent forced authentication attempts with subsequent hotplug events. This method will return false if the player does not support HDCP or if forceHDCPOn() has already been called with the same value.

EdidIdentity

This interface contains EDID information about an attached display:

OutputStatus

This interface contains information about an attached HDMI display device.

Size

This interface represents a video resolution.

ColorProperties

This interface is passed to the adjustGraphicsColor() method. Each of the following parameters has a default value of 0 and can accept a range of values between -1000 and 1000.

TxHdcpStatus

This interface is returned by the getTxHdcpStatus() method.

Example

var VideoOutputClass = require("@brightsign/videooutput");
var videoOutputHDMI = new VideoOutputClass("hdmi");

videoOutputHDMI.getOutputStatus().then(
        function(data) {
            console.log("\nPrint the HDMI output status");
            console.log(JSON.stringify(data));
        })
    .catch(
        function(data) {
            console.log(JSON.stringify(data));
        })