# Decklink Video Sink block

Media Blocks SDK .Net

SDK contains a Decklink Video Sink block, which allows video output to Blackmagic Decklink devices.

You can use HDMI, SDI, and other outputs.

# Enumerating devices

To enumerate available video output devices, use the following code:

var devices = await DecklinkVideoSinkBlock.GetDevicesAsync();
foreach (var item in devices)
{
    Debug.WriteLine(item.Name);
}

# Creating a block

To create a block, use the following code:

DecklinkVideoSinkSettings videoSinkSettings = null;

// select the first device
var device = (await DecklinkVideoSinkBlock.GetDevicesAsync())[0];
if (device != null)
{
    // create settings object
    videoSinkSettings = new DecklinkVideoSinkSettings(device);

    // set video mode
    videoSinkSettings.Mode = DecklinkMode.HD1080i60;
}

// create the block
var decklinkVideoSink = new DecklinkVideoSinkBlock(videoSinkSettings);

The block is created with the specified settings. If you want to change the settings, use the Settings property.

The block must be added to the pipeline. You can connect the Decklink Video Sink block to other blocks, such as video processors or sources, using the Input pad.

# Sample applications