Is there a minimal working example of C++ DeckLink output?

472 views Asked by At

I would like to write a C++ program that outputs color patches to a monitor via a DeckLink card and samples the signal of a camera which is filming that monitor and also connected to the computer via a DeckLink card.

Is there something like a minimal working example for just sending a single solid color patch continuously to a DeckLink output? I've looked through the examples that come with the DeckLink SDK (specifically SignalGenerator and TestPattern), but they seem to contain a lot more code than I actually need.

I've also read the seemingly relevant parts of the SDK documentation, but I'm new to C++ so it's all a little overwhelming to me. I think it would be very helpful if I could just see the absolute minimum amount of code required to output one solid color for as long as the program is running.

1

There are 1 answers

1
mantis On

Is there a particular reason to do this in C++? If you're just outputting Colourbars or other trivial things you might be better off using gstreamer. Particulary its gst-launch utility. As far as i'm aware gstreamer has support for blackmagics DeckLink Cards for both input and output of video/audio via it's decklink-plugins.

a simple (and UNTESTED!) example might look like this:

gst-launch-1.0 videotestsrc ! videoconvert ! decklinkvideosink device-number=0 mode=1080p25 

I dont have one of these cards available to me so i can't verify the pipeline above.