Woohooo, another geek post. So, the last few days, I’ve been working on linking the DeckLink SDK for HDMI input stream with my OpenCV project. After struggling with some mutex and threads and stuff, at last I’m able to complete it.
Okay, let’s start from the top.
Intensity Pro is one of blackmagic products. It’s taking HDMI signal input and there are some output ports as well, but I’m not focusing on the output for now. My goal is to take HD video signal from GoPro Hero2 cameras through HDMI cable and process it “live” using OpenCV. So, what I have to do is to convert the stream to OpenCV data structure. I’ve built a class to make it easier for you. You will need the DeckLink SDK from BlackMagic to make it work. The project example (Qt) can be downloaded here. The important files are cameradecklink.cpp and .h. I’ve also included some sort of example using two camera streams at once and showing the last frame captured from the camera. The project might not work directly, since you need to change the project file accordingly to your OpenCV configuration and you will need to change the location of the DeckLink SDK. Other things you need to change as well: height and width (of the stream), and videomodeindex (can be looked up in the Capture sample in DeckLink SDK). EDIT: Another thing that needs to look at is the conversion between the HD stream to OpenCV format. In the code, I only implemented conversion from UYVY to RGB, since that’s what I need.
I hope this helps. 🙂