Frame generating

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

Alexey Zamaruev

  • Posts: 1
  • Joined: Wed Apr 29, 2015 3:57 pm

Frame generating

PostMon May 04, 2015 11:08 am

Hi there!
May be somebody was faced with converting API to C#, especially receiving frames with a certain frequency from the video stream

thanks
Offline

Nicholas Gill

Blackmagic Design

  • Posts: 169
  • Joined: Mon May 04, 2015 10:28 pm

Re: Frame generating

PostTue May 19, 2015 11:16 pm

Hi Alexey,

There is a C# example in the Desktop Video SDK, see Win/Samples/SignalGenCSharp for the project.

While this example demonstrates playback, the interfaces for capture are very similar and importantly, the SDK manual is also applicable to C#.

See section "2.4.1 Capture" (reproduced below) for a high-level overview of the steps necessary to capture video.

Cheers,

-nick

2.4.1 Capture
An application performing a standard streaming capture operation should perform the following steps:
• If desired, enumerate the supported capture video modes by calling IDeckLinkInput::GetDisplayModeIterator. For each reported capture mode, call IDeckLinkInput::DoesSupportVideoMode to check if the combination of the video mode and pixel format is supported.
IDeckLinkInput::EnableVideoInput
IDeckLinkInput::EnableAudioInput
IDeckLinkInput::SetCallback
IDeckLinkInput::StartStreams
• While streams are running:
- receive calls to IDeckLinkInputCallback::VideoInputFrameArrived with video frame and corresponding audio packet
IDeckLinkInput::StopStreams

Audio may be “pulled” from a separate thread if desired.

If audio is not required, the call to IDeckLinkInput::EnableAudioInput may be omitted and the IDeckLinkInputCallback::VideoInputFrameArrived callback will receive NULL audio packets.

Return to Software Developers

Who is online

Users browsing this forum: No registered users and 17 guests