# Blindly trying Blackmagic Intensity Pro 4K stuff



## Brian Stephan (Sep 12, 2015)

Hello,

On a lark I decided to just try some changes in order to get my card working in obs-studio. The problem is that though I have some (long, but rusty) C/C++ experience, I don't really know anything about video programming. The Pro 4K is working fine in MediaExpress, so I have something to compare against.

I made only this change (I saw the Mantis bug suggesting maybe bumping the SDK, I didn't find it made any difference before or after):


```
diff --git a/plugins/decklink/decklink-device-instance.cpp b/plugins/decklink/decklink-device-instance.cpp
index 71b554f..9d7ec9c 100644
--- a/plugins/decklink/decklink-device-instance.cpp
+++ b/plugins/decklink/decklink-device-instance.cpp
@@ -12,7 +12,7 @@ DeckLinkDeviceInstance::DeckLinkDeviceInstance(DeckLink *decklink_,
                DeckLinkDevice *device_) :
        currentFrame(), currentPacket(), decklink(decklink_), device(device_)
{
-       currentFrame.format = VIDEO_FORMAT_UYVY;
+       currentFrame.format = VIDEO_FORMAT_BGRA;

        currentPacket.samples_per_sec = 48000;
        currentPacket.speakers        = SPEAKERS_STEREO;
@@ -84,7 +84,7 @@ bool DeckLinkDeviceInstance::StartCapture(DeckLinkDeviceMode *mode_)

        const BMDDisplayMode displayMode = mode_->GetDisplayMode();
        const HRESULT videoResult = input->EnableVideoInput(displayMode,
-                       bmdFormat8BitYUV, bmdVideoInputFlagDefault);
+                       bmdFormat8BitARGB, bmdVideoInputFlagDefault);

        if (videoResult != S_OK) {
                LOG(LOG_ERROR, "Failed to enable video input");
```

(Obviously, just setting the new format for all of decklink is ham-handed. The Blackmagic Design Status Report claims it is in 1080p59.94, 8-bit ARGB, and I'm just trying to get something to work for this card.)

I get video in obs, but it is in the wrong color, of course --- I couldn't find a VIDEO_FORMAT_ARGB defined, and trying to roll my own got deep into glad.h stuff I don't understand.

Any suggestions on other things I could try to do? Again, I'm a software engineer, but I'm green as grass when it comes to video signals or the obs-studio codebase in general.

Thanks.


----------



## Jim (Sep 14, 2015)

Okay, first of all, if possible get in contact with me ASAP, #obs-dev on quakenet IRC network.  That way I can help you work through it real time.

Second, you're probably wanting VIDEO_FORMAT_RGBA.

If you do successfully implement it make sure to get in contact with me (my email is on the contact page of the site) if you don't want to on IRC.  Absolutely get in contact with me/us one way or another.


----------



## Brian Stephan (Sep 15, 2015)

Hi! Thanks for reaching out. Stepping away from it for a day, I realized what I was doing wrong and got the right combination of input/output formats. Video looks right in my hack job. I will see if I can figure out the device IDs so that it only does this for the card(s?) that need it.


----------

