C# and GetBufferForVerticalBlankingLine

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

matt.hardiman

  • Posts: 1
  • Joined: Sun Aug 20, 2017 1:01 pm

C# and GetBufferForVerticalBlankingLine

PostSun Aug 20, 2017 1:09 pm

Hi

I'm trying to extract VANC data using a C# application. I have got as far as capturing the video fine but I'm unable to work out the correct way to extract the VANC

Following the examples, I can get the Frame in "VideoInputFrameArrived" callback and also get the ancilliary data using

Code: Select all
                IDeckLinkVideoFrameAncillary ancilliary;
                aFrame.GetAncillaryData(out ancilliary);


but, when I try to get the VBI information using

Code: Select all
 ancilliary.GetBufferForVerticalBlankingLine(i, out pVancData);


the application hangs and visual studio shows no exceptions. I am lost at how I declare and reserve memory for the pVancData variable and have tried several different approaches but am clearly out of my depth.

The import of the DeckLinkAPI.dll shows the following for the IDeckLinkVideoFrameAncillary structure...

Code: Select all
namespace DeckLinkAPI
{
    [Guid("732E723C-D1A4-4E29-9E8E-4A88797A0004")]
    [InterfaceType(1)]
    public interface IDeckLinkVideoFrameAncillary
    {
        void GetBufferForVerticalBlankingLine(uint lineNumber, out IntPtr buffer);
        _BMDDisplayMode GetDisplayMode();
        _BMDPixelFormat GetPixelFormat();
    }
}


I'm unsure how to use this method in C# and really would appreciate any pointers

thanks

Return to Software Developers

Who is online

Users browsing this forum: Google [Bot] and 9 guests