---
title: videooutput
slug: develop/videooutput
docTags: 
createdAt: 2025-03-27T16:58:54.124Z
---

The *videooutput&#xA0;*&#x6F;bject allows you to configure and retrieve non-persistent settings related to a video output (the video mode itself is configured with the [videomodeconfiguration](docId\:uupZxkYFlBSOLyh8oLcES)*&#xA0;&#x20;*&#x6F;bject).

**videooutput IDL**

```javascript
interface VideoOutputEvent {
    attribute String type;
};
 
callback VideoOutputEventCallback = void (VideoOutputEvent event);
 
[
    constructor(String interfaceName)
] interface VideoOutputConfiguration {
    attribute String type;
    Promise<Size> getVideoResolution();
    Promise<Size> getGraphicsResolution();
    Promise<Size> getOutputResolution();
    Promise<void> adjustGraphicsColor(ColorProperties);
    Promise<EdidIdentity> getEdidIdentity();
    Promise<String> getEdid();
    Promise<void> setMultiScreenBezel(int xPercentage, int yPercentage);
    Promise<void> setBackgroundColor(int color);
    Promise<void> setPowerSaveMode(bool enable);
    Promise<bool> getPowerSaveMode();
    Promise<void> set3dMode(int mode);
    Promise<bool> isAttached();
    [type == "hdmi"] Promise<OutputStatus> getOutputStatus();
    [type == "hdmi"] Promise<void> disableAudio(bool disable);
    [type == "hdmi"] Promise<TxHdcpStatus> getTxHdcpStatus();
    [type == "hdmi"] Promise<void> forceHdcpOn(bool);
    Promise<void> setSyncDomain(String domain)
    Promise<void> setMpcdi(String filename);
    void addEventListener(String type, VideoOutputEventCallback callback);
    void removeEventListener(String type, VideoOutputEventCallback callback);
};

interface EdidIdentity {
    attribute String manufacturer;
    attribute int product;
    attribute int serialNumber;
    attribute int weekOfManufacture;
    attribute int yearOfManufacture;
    attribute String monitorName;
    attribute String textString;
    attribute String serialNumberString;
    attribute bool bt2020RgbSupport;
    attribute bool bt2020YccSupport;
    attribute bool sdrEotfSupport;
    attribute bool hdrEotfSupport;
    attribute bool hdrSt2084Support;
};
 
interface OutputStatus {
    attribute bool outputPresent;
    attribute bool outputPowered;
    attribute bool unstable;
    attribute String audioFormat;
    attribute int audioSampleRate;
    attribute int audioBitsPerSample;
    attribute int audioChannelCount;
    attribute String eotf;
};
 
interface Size {
    attribute int width;
    attribute int height;
};
 
interface ColorProperties {
    attribute int constrast;
    attribute int saturation;
    attribute int hue;
    attribute int brightness;
};
```

## 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-1`", "`HDMI-2`", "`HDMI-3`", "`HDMI-4`" and "`vga`").

```javascript
var VideoOutputClass = require("@brightsign/videooutput");
var videoOutputHDMI = new VideoOutputClass("HDMI-1");
```

## VideoOutputConfiguration

Use this interface to perform operations on the video output.

### Events

A `VideoOutputEvent` is raised when the hotplug status of the HDM&#x49;*®* output changes. It has one type property:

- `type`: The event type is `hotplugevent`

### Methods

**getVideoResolution()**

```javascript
Promise<Size> getVideoResolution() 
```

Returns the current resolution of the video plane.

**getGraphicsResolution()**

```javascript
Promise<Size> getGraphicsResolution() 
```

Returns the current resolution of the graphics plane.

**getOutputResolution()**

```javascript
Promise<Size> getOutputResolution() 
```

Returns the current video-output resolution.

:::hint{type="info"}
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()**

```javascript
Promise<> adjustGraphicsColor(ColorProperties) 
```

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

**getEdidIdentity()**

```javascript
Promise<EdidIdentity> getEdidIdentity()
```

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

**getEdid()**

```javascript
Promise<String> getEdid()
```

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

**setMultiScreenBezel()**

```javascript
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()**

```javascript
Promise<> setBackgroundColor(int color)
```

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

**setPowerSaveMode()**

```javascript
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.

**getPowerSaveMode()**

```javascript
Promise<bool> getPowerSaveMode()
```

Returns `True` if power save mode is enabled on the video output.

**set3dMode()**

```javascript
Promise<> set3dMode(int mode)
```

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

- 0: Standard mono video (default)
- 1: Side-by-side stereo video
- 2: Top-and-bottom stereo video

**isAttached()**

```javascript
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()**

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

Returns `OutputStatus` which describes the current state of the video output and is defined below.

**disableAudio()**

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

Disables audio output. If passed `True`, the video will continue to output.

**getTxHdcpStatus()**

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

Returns the current HDCP authentication state of the video output.

**forceHdcpOn()**

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

Can be used to force HDCP authentication on the video output. Even without HDCP forced on, there can still be HDCP on the output if an HDMI input has requested authentication.

**setSyncDomain()&#x20;**

```javascript
Promise<void> setSyncDomain(String domain)
```

Passing any string will enable Genlock synchronization. To disable Genlock on the domain, pass an empty string to this method. Genlock synchronization will lock the vertical sync of the video output to the system clock reference. PTP is then used to synchronize the system clock of multiple players (for example, in a video wall).

**setMpcdi()**

```javascript
Promise<void> setMpcdi(String filename)
```

Users that construct an MPCDI file as per the version1a 2D media profile should pass videoOutputHDMI.setMpcdi("SD:/filename.mpcdi") to the player to decode the file and apply the warp and blend to the output as per the requirements set in filename.mpcdi (replace "filename" with the name of your actual file). Passing an empty string will turn off the warp and blend, and the image will return to the normal format.

Series 4 players implement all levels of the MPCDI 2D media profile (version 1a).

**close()**

```javascript
Promise<void> close()
```

This method shuts down the instance, preventing it from further consuming resources. If it is not called, garbage collection determines when the instance will be destroyed.

## EdidIdentity

This interface contains EDID information about an attached display:

- `manufacturer` <font color="#6554c0">string</font>
- `product` <font color="#6554c0">int</font>
- `serialNumber` <font color="#6554c0">int</font>
- `weekOfManufacture` <font color="#6554c0">int</font>
- `yearOfManufacture` <font color="#6554c0">int</font>
- `monitorName` <font color="#6554c0">string</font>
- `textString` <font color="#6554c0">string</font>
- `serialNumberString` <font color="#6554c0">string</font>
- `bt2020RgbSupport` <font color="#6554c0">bool</font>
- `bt2020YccSupport` <font color="#6554c0">bool</font>
- `sdrEotfSupport` <font color="#6554c0">bool</font>
- `hdrEotfSupport` <font color="#6554c0">bool</font>
- `hdrSt2084Support` <font color="#6554c0">bool</font>

## OutputStatus

This interface contains information about an attached HDMI display device.

:::hint{type="info"}
The `outputPresent` and `outputPowered` entries will always be `false` if `setPowerSaveMode(true)` has been called on the output.
:::



- `outputPresent`<font color="#6554c0"> bool</font>: A flag indicating whether the HDMI output is connected to a display device or not. This is based on the HDMI HPD line state. This value should always be `true` when there is a device connected, however it is dependent on the connected display adhering to this spec.
- `outputPowered` <font color="#6554c0">bool</font>: A flag indicating whether the display device is on (i.e. RX powered). This is based on the TMDS differential termination status.&#x20;
- `unstable` <font color="#6554c0">bool</font>: A flag indicating whether the display signal is unstable or stable
- `audioFormat` <font color="#6554c0">string</font>: The format of the audio output. A "PCM" value indicates that the player is sending decoded output.
- `audioSampleRate` <font color="#6554c0">int</font>: The audio sample rate (in hertz)
- `audioBitsPerSample` <font color="#6554c0">int</font>:  The number of bits per audio sample
- `audioChannelCount` <font color="#6554c0">int</font>: The number of audio channels in the output
- `eotf` <font color="#6554c0">string</font>: The current electro-optical transfer function (EOTF) used by the display. The following are possible values:
  - "HDR (GAMMA)"
  - "SDR (GAMMA)"
  - "SMPTE 2084 (PQ)"
  - "Future (BBC/NHK)"
  - "unspecified"

## Size

This interface represents a video resolution.

- `width` <font color="#6554c0">int</font>:  The height of the screen/plane
- `height` <font color="#6554c0">int</font>:  The width of the screen/plane

## 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.

- `contrast` <font color="#6554c0">int</font>
- `saturation` <font color="#6554c0">int</font>
- `hue` <font color="#6554c0">int</font>
- `brightness` <font color="#6554c0">int</font>

## TxHdcpStatus

This interface is returned by the `getTxHdcpStatus()` method.

- `state` <font color="#6554c0">string</font>: The HDCP status of the HDMI output, which can be one of the following values:
  - "`not-required`": HDCP is not required by the player. HDCP is required by the player if the video has been decoded locally and needs protection or if the script has called the `forceHdcpOn()` method. Note that, even if this parameter indicates `not-required`, HDCP might still be active in passthrough mode if an upstream HDMI source (i.e. a device connected to the HDMI input port on the player) has requested it.
  - "`authenticated`": HDCP has been enabled and successfully negotiated.
  - "`authentication-in-progress`": HDCP has been enabled but authentication is incomplete.
  - "`authentication-failed`": HDCP has been requested but could not be negotiated.

## Example

```javascript
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));
        })
```

