Decklink internal keyer BT.2020 support

Ask software engineering and SDK questions for developers working on Mac OS X, Windows or Linux.
  • Author
  • Message
Offline

jurisver

  • Posts: 4
  • Joined: Thu Aug 01, 2024 3:54 pm
  • Real Name: Juri Sverlov

Decklink internal keyer BT.2020 support

PostFri Aug 02, 2024 5:18 pm

I want to use the internal keyer of the Decklink 8K Pro to place an overlay on a live video image. Different input video formats should be supported and the input video properties (resolution, refresh rate, color coding, ...) should not be changed.
I set the output video mode based on the detected input video mode. This ensures that the resolution and refresh rate are correct. However, if the input signal has a BT.2020 color space, the color space is converted to BT.709 after keying. (If I have BT.709 at the input, the output is BT.709 as expected)

How can I control the color space on the output pin of the Decklink 8K Pro?

Here a screenshot of the DeviceStatusCSharp.exe from the Decklink SDK examples showing the difference between input and output signal:
Image
Offline

Mitra Mahmoodzadeh

  • Posts: 64
  • Joined: Wed Sep 02, 2015 2:45 pm

Re: Decklink internal keyer BT.2020 support

PostSat Aug 03, 2024 6:44 pm

Hello Juri,

You can set bmdDeckLinkConfigRec2020Output flag.

If set to true, device will output Rec.709 frames in
Rec.2020 colorspace.
HiTech Playout is a full-featured, free 8-channel standard SD/HD/UHD playout and recorder.
Link: https://forum.blackmagicdesign.com/viewtopic.php?f=14&t=203230
Offline

jurisver

  • Posts: 4
  • Joined: Thu Aug 01, 2024 3:54 pm
  • Real Name: Juri Sverlov

Re: Decklink internal keyer BT.2020 support

PostThu Aug 08, 2024 11:02 am

Thanks for the reply. I hope that i can somehow avoid color conversions at it may lead to information lost or any type of modification of the incoming video signal.

By luck I saw the following changelog in the changelog of the new Desktop Video version 14.1.
New feature on DeckLink 8K Pro:
Add support for keying in Rec.2020, HLG and PQ.


This is exactly what i am search for, i think :)

In the decklink SDK documentation i did not find anything regarding this feature.
Is here a Blackmagic dev who could explain how this new feature works?
Offline

Cameron Nichols

Blackmagic Design

  • Posts: 451
  • Joined: Mon Sep 04, 2017 4:05 am

Re: Decklink internal keyer BT.2020 support

PostThu Aug 15, 2024 3:31 am

Hi Juri,

To output a frame with Rec.2020, please use the following steps:
  • If required, create IDeckLinkMutableVideoFrame object with IDeckLinkOutput::CreateVideoFrame[1].
  • Create new class that implements both IDeckLinkVideoFrame and IDeckLinkVideoFrameMetadataExtensions with the following guidance[2][3]:
    • Provide created IDeckLinkMutableVideoFrame object to constructor, storing reference.
    • Release reference to IDeckLinkMutableVideoFrame object in destructor
    • Implement all methods of IDeckLinkVideoFrame providing wrapped calls to the local IDeckLinkMutableVideoFrame member.
    • Implement IDeckLinkVideoFrameMetadataExtensions::GetInt to return colorspace value bmdColorspaceRec2020 when metadata ID is bmdDeckLinkFrameMetadataColorspace[4][5]. Return E_NOTIMPL for other metadata IDs
    • The remaining IDeckLinkVideoFrameMetadataExtensions method should just return E_NOTIMPL.
    • Implement IUnknown methods with examples from SDK samples. QueryInterface should handle cases for IID_IDeckLinkVideoFrame and IID_IDeckLinkVideoFrameMetadataExtensions.
  • Create an object with the custom interface and schedule output with the IDeckLinkVideoFrame as normal.

The SignalGenHDR sample should be used as reference, please have a look at the implementation of class HDRVideoFrame.

Regards
Cameron

References (DeckLink SDK manual)
[1] Section 2.5.3.9 IDeckLinkOutput::CreateVideoFrame method
[2] Section 2.5.5 IDeckLinkVideoFrame Interface
[3] Section 2.5.43 IDeckLinkVideoFrameMetadataExtensions Interface
[4] Section 3.65 Colorspace
[5] Section 3.61 Frame Metadata ID
Offline

jurisver

  • Posts: 4
  • Joined: Thu Aug 01, 2024 3:54 pm
  • Real Name: Juri Sverlov

Re: Decklink internal keyer BT.2020 support

PostThu Sep 12, 2024 4:38 pm

Hello Cameron,

Thank you for your detailed reply!
We will try it out in the next few days
Offline

y.lanovyi

  • Posts: 1
  • Joined: Mon Sep 16, 2024 9:35 am
  • Real Name: Yaroslav Lanovyi

Re: Decklink internal keyer BT.2020 support

PostMon Sep 16, 2024 10:37 pm

Hi Cameron,

Thank you for your detailed explanation. We have a few additional questions regarding this topic.

In the latest update to the DeckLink SDK (version 14.1), we noticed that the flags bmdDeckLinkConfigVideoOutputConversionColorspaceDestination and bmdDeckLinkConfigVideoOutputConversionColorspaceSource were added to the BMDDeckLinkConfigurationID enum.

Our question is: is it possible to use these flags to configure the input and output colorspace directly without having to override each frame of the output?

We’ve attempted to implement this in our C# application and have updated the SDK and DLL to version 14.2. However, we faced an E_NOTIMPL error returned from the dll when calling the IDeckLinkConfiguration.GetInt/SetInt(_BMDDeckLinkConfigurationID.bmdDeckLinkConfigVideoOutputConversionColorspaceDestination, out long destination) method.

We would greatly appreciate any assistance you can provide on this matter. :)
Offline

Cameron Nichols

Blackmagic Design

  • Posts: 451
  • Joined: Mon Sep 04, 2017 4:05 am

Re: Decklink internal keyer BT.2020 support

PostWed Sep 25, 2024 5:55 am

Hi Yaroslav,

Configuration items bmdDeckLinkConfigVideoOutputConversionColorspaceSource and bmdDeckLinkConfigVideoOutputConversionColorspaceDestination are used to configure the output conversion pipeline for Dolby Vision output. Please refer to high-level description in section 2.4.12.3 in the DeckLink SDK manual for further information.

Accessing these configuration items will return E_NOTIMPL for targets that do not support Dolby Vision.

Kind Regards
Cameron Nichols

Return to Software Developers

Who is online

Users browsing this forum: No registered users and 6 guests