summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--configure.ac21
-rw-r--r--ext/kate/gstkatespu.c19
-rw-r--r--ext/kate/gstkateutil.c46
-rw-r--r--ext/ofa/gstofa.c39
-rw-r--r--ext/resindvd/rsnwrappedbuffer.c1
-rw-r--r--ext/rsvg/gstrsvgdec.c41
-rw-r--r--ext/rsvg/gstrsvgdec.h2
-rw-r--r--ext/vp8/gstvp8enc.c27
-rw-r--r--ext/vp8/gstvp8enc.h2
-rw-r--r--gst-libs/gst/Makefile.am5
-rw-r--r--gst-libs/gst/video/gstbasevideocodec.c11
-rw-r--r--gst-libs/gst/video/gstbasevideocodec.h8
-rw-r--r--gst-libs/gst/video/gstbasevideodecoder.c95
-rw-r--r--gst-libs/gst/video/gstbasevideoencoder.c41
-rw-r--r--gst/camerabin2/gstcamerabin2.c135
-rw-r--r--gst/camerabin2/gstcamerabin2.h6
-rw-r--r--gst/camerabin2/gstviewfinderbin.c133
-rw-r--r--gst/camerabin2/gstviewfinderbin.h2
-rw-r--r--gst/dvdspu/gstspu-vobsub.c8
-rw-r--r--gst/hls/gsthlsdemux.c167
-rw-r--r--gst/hls/gsthlsdemux.h1
-rw-r--r--gst/hls/m3u8.c29
-rw-r--r--gst/hls/m3u8.h5
-rw-r--r--gst/mpegtsdemux/mpegtsbase.c26
-rw-r--r--gst/mpegtsdemux/mpegtsbase.h4
-rw-r--r--gst/mpegtsdemux/tsdemux.c116
-rw-r--r--gst/mpegtsmux/mpegtsmux.c16
-rw-r--r--gst/removesilence/Makefile.am12
-rw-r--r--gst/removesilence/gstremovesilence.c262
-rw-r--r--gst/removesilence/gstremovesilence.h56
-rw-r--r--gst/removesilence/vad_private.c152
-rw-r--r--gst/removesilence/vad_private.h44
-rw-r--r--sys/decklink/Makefile.am11
-rw-r--r--sys/decklink/capture.cpp27
-rw-r--r--sys/decklink/capture.h6
-rw-r--r--sys/decklink/gstdecklink.h19
-rw-r--r--sys/decklink/gstdecklinksink.cpp92
-rw-r--r--sys/decklink/gstdecklinksink.h9
-rw-r--r--sys/decklink/gstdecklinksrc.cpp164
-rw-r--r--sys/decklink/gstdecklinksrc.h16
-rw-r--r--sys/decklink/linux/DeckLinkAPI.h (renamed from sys/decklink/DeckLinkAPI.h)0
-rw-r--r--sys/decklink/linux/DeckLinkAPIDispatch.cpp (renamed from sys/decklink/DeckLinkAPIDispatch.cpp)0
-rw-r--r--sys/decklink/linux/LinuxCOM.h (renamed from sys/decklink/LinuxCOM.h)0
-rw-r--r--sys/decklink/win/DeckLinkAPI.h9217
-rw-r--r--sys/decklink/win/DeckLinkAPIDispatch.cpp40
-rw-r--r--sys/decklink/win/DeckLinkAPI_i.c319
-rw-r--r--tests/check/Makefile.am7
-rw-r--r--tests/check/elements/camerabin2.c146
-rw-r--r--tests/examples/Makefile.am6
49 files changed, 11301 insertions, 310 deletions
diff --git a/configure.ac b/configure.ac
index 8213cfd6f..44dc48a80 100644
--- a/configure.ac
+++ b/configure.ac
@@ -362,6 +362,7 @@ AG_GST_CHECK_PLUGIN(pcapparse)
AG_GST_CHECK_PLUGIN(pnm)
AG_GST_CHECK_PLUGIN(rawparse)
AG_GST_CHECK_PLUGIN(real)
+AG_GST_CHECK_PLUGIN(removesilence)
AG_GST_CHECK_PLUGIN(rtpmux)
AG_GST_CHECK_PLUGIN(rtpvp8)
AG_GST_CHECK_PLUGIN(scaletempo)
@@ -389,11 +390,6 @@ if test "x$HAVE_CPU_I386" != "xyes" && test "x$HAVE_CPU_X86_64" != "xyes"; then
AG_GST_DISABLE_PLUGIN(real)
fi
-dnl disable experimental plug-ins
-if test "x$BUILD_EXPERIMENTAL" != "xyes"; then
- AG_GST_DISABLE_PLUGIN(camerabin2)
-fi
-
# This will always succeed because we depend on GLib >= 2.16
PKG_CHECK_MODULES(GIO, gio-2.0 >= 2.16, HAVE_GIO=yes, HAVE_GIO=no)
AC_SUBST(GIO_CFLAGS)
@@ -1708,6 +1704,20 @@ AG_GST_CHECK_FEATURE(VP8, [VP8 decoder], vp8, [
HAVE_VP8=yes
AC_DEFINE(HAVE_VP8_ENCODER, 1, [Defined if the VP8 encoder is available])
VPX_LIBS="-lvpx"
+
+ AC_MSG_CHECKING([for VP8E_SET_TUNING presence])
+ AC_TRY_COMPILE([
+#include <vpx/vpx_encoder.h>
+#include <vpx/vp8cx.h>
+int foo=VP8E_SET_TUNING;
+ ], [
+return 0;
+ ], [
+ AC_DEFINE(HAVE_VP8ENC_TUNING, 1, [Defined if the VP8 encoder has tuning API])
+ AC_MSG_RESULT(yes)
+ ], [
+ AC_MSG_RESULT(no)
+ ])
])
AC_CHECK_LIB(vpx, vpx_codec_vp8_dx_algo, [
HAVE_VP8=yes
@@ -1929,6 +1939,7 @@ gst/pcapparse/Makefile
gst/pnm/Makefile
gst/rawparse/Makefile
gst/real/Makefile
+gst/removesilence/Makefile
gst/rtpmux/Makefile
gst/rtpvp8/Makefile
gst/scaletempo/Makefile
diff --git a/ext/kate/gstkatespu.c b/ext/kate/gstkatespu.c
index 13f561941..439291634 100644
--- a/ext/kate/gstkatespu.c
+++ b/ext/kate/gstkatespu.c
@@ -62,10 +62,10 @@ gst_kate_spu_decode_alpha (GstKateEnc * ke, const guint8 * ptr)
static void
gst_kate_spu_decode_area (GstKateEnc * ke, const guint8 * ptr)
{
- ke->spu_left = ((((guint16) ptr[0]) & 0x3f) << 4) | (ptr[1] >> 4);
- ke->spu_top = ((((guint16) ptr[3]) & 0x3f) << 4) | (ptr[4] >> 4);
- ke->spu_right = ((((guint16) ptr[1]) & 0x03) << 8) | ptr[2];
- ke->spu_bottom = ((((guint16) ptr[4]) & 0x03) << 8) | ptr[5];
+ ke->spu_left = ((((guint16) ptr[0]) & 0xff) << 4) | (ptr[1] >> 4);
+ ke->spu_top = ((((guint16) ptr[3]) & 0xff) << 4) | (ptr[4] >> 4);
+ ke->spu_right = ((((guint16) ptr[1]) & 0x0f) << 8) | ptr[2];
+ ke->spu_bottom = ((((guint16) ptr[4]) & 0x0f) << 8) | ptr[5];
GST_DEBUG_OBJECT (ke, "SPU area %u %u -> %u %d", ke->spu_left, ke->spu_top,
ke->spu_right, ke->spu_bottom);
}
@@ -494,9 +494,14 @@ gst_kate_spu_decode_spu (GstKateEnc * ke, GstBuffer * buf, kate_region * kr,
if (G_UNLIKELY (ke->spu_right - ke->spu_left < 0
|| ke->spu_bottom - ke->spu_top < 0 || ke->spu_pix_data[0] == 0
|| ke->spu_pix_data[1] == 0)) {
- GST_ELEMENT_ERROR (ke, STREAM, ENCODE, (NULL),
- ("SPU area is empty, nothing to encode"));
- return GST_FLOW_ERROR;
+ GST_DEBUG_OBJECT (ke,
+ "left %d, right %d, top %d, bottom %d, pix data %d %d", ke->spu_left,
+ ke->spu_right, ke->spu_top, ke->spu_bottom, ke->spu_pix_data[0],
+ ke->spu_pix_data[1]);
+ GST_WARNING_OBJECT (ke, "SPU area is empty, nothing to encode");
+ kate_bitmap_init (kb);
+ kb->width = kb->height = 0;
+ return GST_FLOW_OK;
}
/* create the palette */
diff --git a/ext/kate/gstkateutil.c b/ext/kate/gstkateutil.c
index 46ae19b9d..3062d5cd8 100644
--- a/ext/kate/gstkateutil.c
+++ b/ext/kate/gstkateutil.c
@@ -226,6 +226,18 @@ gst_kate_util_decoder_base_get_property (GstKateDecoderBase * decoder,
return res;
}
+static inline gboolean
+gst_kate_util_is_utf8_string (const char *value, size_t len)
+{
+ if (len == 0)
+ return FALSE;
+ if (memchr (value, 0, len - 1))
+ return FALSE;
+ if (value[len - 1])
+ return FALSE;
+ return (kate_text_validate (kate_utf8, value, len) >= 0);
+}
+
GstFlowReturn
gst_kate_util_decoder_base_chain_kate_packet (GstKateDecoderBase * decoder,
GstElement * element, GstPad * pad, GstBuffer * buf, GstPad * srcpad,
@@ -371,6 +383,40 @@ gst_kate_util_decoder_base_chain_kate_packet (GstKateDecoderBase * decoder,
break;
}
}
+#if ((KATE_VERSION_MAJOR<<16)|(KATE_VERSION_MINOR<<8)|KATE_VERSION_PATCH) >= 0x000400
+ else if (*ev && (*ev)->meta) {
+ int count = kate_meta_query_count ((*ev)->meta);
+ if (count > 0) {
+ GstTagList *evtags = gst_tag_list_new ();
+ int idx;
+ GST_DEBUG_OBJECT (decoder, "Kate event has %d attached metadata", count);
+ for (idx = 0; idx < count; ++idx) {
+ const char *tag, *value;
+ size_t len;
+ if (kate_meta_query ((*ev)->meta, idx, &tag, &value, &len) < 0) {
+ GST_WARNING_OBJECT (decoder, "Failed to retrieve metadata %d", idx);
+ } else {
+ if (gst_kate_util_is_utf8_string (value, len)) {
+ gchar *compound = g_strdup_printf ("%s=%s", tag, value);
+ GST_DEBUG_OBJECT (decoder, "Metadata %d: %s=%s (%zu bytes)", idx,
+ tag, value, len);
+ gst_tag_list_add (evtags, GST_TAG_MERGE_APPEND,
+ GST_TAG_EXTENDED_COMMENT, compound, NULL);
+ g_free (compound);
+ } else {
+ GST_INFO_OBJECT (decoder,
+ "Metadata %d, (%s, %zu bytes) is binary, ignored", idx, tag,
+ len);
+ }
+ }
+ }
+ if (gst_tag_list_is_empty (evtags))
+ gst_tag_list_free (evtags);
+ else
+ gst_element_found_tags_for_pad (element, tagpad, evtags);
+ }
+ }
+#endif
return rflow;
}
diff --git a/ext/ofa/gstofa.c b/ext/ofa/gstofa.c
index a18d7e352..6081fdb28 100644
--- a/ext/ofa/gstofa.c
+++ b/ext/ofa/gstofa.c
@@ -115,9 +115,11 @@ static void
create_fingerprint (GstOFA * ofa)
{
GstBuffer *buf;
- gint rate = GST_AUDIO_FILTER (ofa)->format.rate;
- gint channels = GST_AUDIO_FILTER (ofa)->format.channels;
- gint endianness;
+ GstAudioFilter *ofa_filter = GST_AUDIO_FILTER (ofa);
+ gint rate = ofa_filter->format.rate;
+ gint channels = ofa_filter->format.channels;
+ gint endianness =
+ ofa_filter->format.bigend ? OFA_BIG_ENDIAN : OFA_LITTLE_ENDIAN;
GstTagList *tags;
guint available;
@@ -135,7 +137,8 @@ create_fingerprint (GstOFA * ofa)
endianness = OFA_LITTLE_ENDIAN;
- GST_DEBUG ("Generating fingerprint");
+ GST_DEBUG_OBJECT (ofa, "Generating fingerprint for %u samples",
+ available / 2);
buf = gst_adapter_take_buffer (ofa->adapter, available);
@@ -143,16 +146,22 @@ create_fingerprint (GstOFA * ofa)
endianness, GST_BUFFER_SIZE (buf) / 2, rate,
(channels == 2) ? 1 : 0));
- GST_DEBUG ("Generated fingerprint");
+ if (ofa->fingerprint) {
+ GST_INFO_OBJECT (ofa, "Generated fingerprint: %s", ofa->fingerprint);
+ } else {
+ GST_WARNING_OBJECT (ofa, "Failed to generate fingerprint");
+ }
gst_buffer_unref (buf);
- tags = gst_tag_list_new ();
- gst_tag_list_add (tags, GST_TAG_MERGE_REPLACE,
- GST_TAG_OFA_FINGERPRINT, ofa->fingerprint, NULL);
- gst_element_found_tags (GST_ELEMENT (ofa), tags);
+ if (ofa->fingerprint) {
+ tags = gst_tag_list_new ();
+ gst_tag_list_add (tags, GST_TAG_MERGE_REPLACE,
+ GST_TAG_OFA_FINGERPRINT, ofa->fingerprint, NULL);
+ gst_element_found_tags (GST_ELEMENT (ofa), tags);
- g_object_notify (G_OBJECT (ofa), "fingerprint");
+ g_object_notify (G_OBJECT (ofa), "fingerprint");
+ }
ofa->record = FALSE;
}
@@ -165,7 +174,8 @@ gst_ofa_event (GstBaseTransform * trans, GstEvent * event)
switch (GST_EVENT_TYPE (event)) {
case GST_EVENT_FLUSH_STOP:
case GST_EVENT_NEWSEGMENT:
- GST_DEBUG ("Got %s event, clearing buffer", GST_EVENT_TYPE_NAME (event));
+ GST_DEBUG_OBJECT (ofa, "Got %s event, clearing buffer",
+ GST_EVENT_TYPE_NAME (event));
gst_adapter_clear (ofa->adapter);
ofa->record = TRUE;
g_free (ofa->fingerprint);
@@ -175,7 +185,7 @@ gst_ofa_event (GstBaseTransform * trans, GstEvent * event)
/* we got to the end of the stream but never generated a fingerprint
* (probably under 135 seconds)
*/
- if (!ofa->fingerprint)
+ if (!ofa->fingerprint && ofa->record)
create_fingerprint (ofa);
break;
default:
@@ -200,10 +210,11 @@ static GstFlowReturn
gst_ofa_transform_ip (GstBaseTransform * trans, GstBuffer * buf)
{
GstOFA *ofa = GST_OFA (trans);
+ GstAudioFilter *ofa_filter = GST_AUDIO_FILTER (ofa);
guint64 nframes;
GstClockTime duration;
- gint rate = GST_AUDIO_FILTER (ofa)->format.rate;
- gint channels = GST_AUDIO_FILTER (ofa)->format.channels;
+ gint rate = ofa_filter->format.rate;
+ gint channels = ofa_filter->format.channels;
g_return_val_if_fail (rate > 0 && channels > 0, GST_FLOW_NOT_NEGOTIATED);
diff --git a/ext/resindvd/rsnwrappedbuffer.c b/ext/resindvd/rsnwrappedbuffer.c
index 2663550be..a5f4c0fd3 100644
--- a/ext/resindvd/rsnwrappedbuffer.c
+++ b/ext/resindvd/rsnwrappedbuffer.c
@@ -75,6 +75,7 @@ rsn_meta_wrapped_unwrap_and_unref (GstBuffer * wrap_buf, RsnMetaWrapped * meta)
g_return_val_if_fail (meta->wrapped_buffer != NULL, NULL);
buf = gst_buffer_ref (meta->wrapped_buffer);
+ buf = gst_buffer_make_metadata_writable (buf);
/* Copy changed metadata back to the wrapped buffer from the wrapper,
* except the the read-only flag and the caps. */
diff --git a/ext/rsvg/gstrsvgdec.c b/ext/rsvg/gstrsvgdec.c
index c0a636216..f7cb701aa 100644
--- a/ext/rsvg/gstrsvgdec.c
+++ b/ext/rsvg/gstrsvgdec.c
@@ -141,7 +141,7 @@ gst_rsvg_dec_reset (GstRsvgDec * dec)
dec->width = dec->height = 0;
dec->fps_n = 0;
dec->fps_d = 1;
- dec->timestamp_offset = GST_CLOCK_TIME_NONE;
+ dec->first_timestamp = GST_CLOCK_TIME_NONE;
dec->frame_count = 0;
gst_segment_init (&dec->segment, GST_FORMAT_UNDEFINED);
@@ -341,11 +341,18 @@ gst_rsvg_dec_chain (GstPad * pad, GstBuffer * buffer)
guint size;
gboolean ret = GST_FLOW_OK;
- if (rsvg->timestamp_offset == GST_CLOCK_TIME_NONE) {
+ /* first_timestamp is used slightly differently where a framerate
+ is given or not.
+ If there is a frame rate, it will be used as a base.
+ If there is not, it will be used to keep track of the timestamp
+ of the first buffer, to be used as the timestamp of the output
+ buffer. When a buffer is output, first timestamp will resync to
+ the next buffer's timestamp. */
+ if (rsvg->first_timestamp == GST_CLOCK_TIME_NONE) {
if (GST_BUFFER_TIMESTAMP_IS_VALID (buffer))
- rsvg->timestamp_offset = GST_BUFFER_TIMESTAMP (buffer);
- else
- rsvg->timestamp_offset = 0;
+ rsvg->first_timestamp = GST_BUFFER_TIMESTAMP (buffer);
+ else if (rsvg->fps_n != 0)
+ rsvg->first_timestamp = 0;
}
gst_adapter_push (rsvg->adapter, buffer);
@@ -377,15 +384,33 @@ gst_rsvg_dec_chain (GstPad * pad, GstBuffer * buffer)
break;
- if (rsvg->fps_n != 0) {
+ if (rsvg->first_timestamp != GST_CLOCK_TIME_NONE) {
+ GST_BUFFER_TIMESTAMP (outbuf) = rsvg->first_timestamp;
+ GST_BUFFER_DURATION (outbuf) = GST_CLOCK_TIME_NONE;
+ if (GST_BUFFER_DURATION_IS_VALID (buffer)) {
+ GstClockTime end =
+ GST_BUFFER_TIMESTAMP_IS_VALID (buffer) ?
+ GST_BUFFER_TIMESTAMP (buffer) : rsvg->first_timestamp;
+ end += GST_BUFFER_DURATION (buffer);
+ GST_BUFFER_DURATION (outbuf) = end - GST_BUFFER_TIMESTAMP (outbuf);
+ }
+ if (rsvg->fps_n == 0) {
+ rsvg->first_timestamp = GST_CLOCK_TIME_NONE;
+ } else {
+ GST_BUFFER_DURATION (outbuf) =
+ gst_util_uint64_scale (rsvg->frame_count, rsvg->fps_d,
+ rsvg->fps_n * GST_SECOND);
+ }
+ } else if (rsvg->fps_n != 0) {
GST_BUFFER_TIMESTAMP (outbuf) =
- rsvg->timestamp_offset + gst_util_uint64_scale (rsvg->frame_count,
+ rsvg->first_timestamp + gst_util_uint64_scale (rsvg->frame_count,
rsvg->fps_d, rsvg->fps_n * GST_SECOND);
GST_BUFFER_DURATION (outbuf) =
gst_util_uint64_scale (rsvg->frame_count, rsvg->fps_d,
rsvg->fps_n * GST_SECOND);
} else {
- GST_BUFFER_TIMESTAMP (outbuf) = 0;
+ GST_BUFFER_TIMESTAMP (outbuf) = rsvg->first_timestamp;
+ GST_BUFFER_DURATION (outbuf) = GST_CLOCK_TIME_NONE;
}
rsvg->frame_count++;
diff --git a/ext/rsvg/gstrsvgdec.h b/ext/rsvg/gstrsvgdec.h
index 00279922f..0d048eece 100644
--- a/ext/rsvg/gstrsvgdec.h
+++ b/ext/rsvg/gstrsvgdec.h
@@ -58,7 +58,7 @@ struct _GstRsvgDec
GstTagList *pending_tags;
gint fps_n, fps_d;
- GstClockTime timestamp_offset;
+ GstClockTime first_timestamp;
guint64 frame_count;
GstSegment segment;
diff --git a/ext/vp8/gstvp8enc.c b/ext/vp8/gstvp8enc.c
index 78325265a..f0d282f22 100644
--- a/ext/vp8/gstvp8enc.c
+++ b/ext/vp8/gstvp8enc.c
@@ -101,7 +101,13 @@ gst_vp8_enc_coder_hook_free (GstVP8EncCoderHook * hook)
#define DEFAULT_LAG_IN_FRAMES 0
#define DEFAULT_SHARPNESS 0
#define DEFAULT_NOISE_SENSITIVITY 0
+#ifdef HAVE_VP8ENC_TUNING
#define DEFAULT_TUNE VP8_TUNE_PSNR
+#else
+typedef enum
+{ VP8_TUNE_NONE } vp8e_tuning;
+#define DEFAULT_TUNE VP8_TUNE_NONE
+#endif
#define DEFAULT_STATIC_THRESHOLD 0
#define DEFAULT_DROP_FRAME 0
#define DEFAULT_RESIZE_ALLOWED TRUE
@@ -186,8 +192,12 @@ static GType
gst_vp8_enc_tune_get_type (void)
{
static const GEnumValue values[] = {
+#ifdef HAVE_VP8ENC_TUNING
{VP8_TUNE_PSNR, "Tune for PSNR", "psnr"},
{VP8_TUNE_SSIM, "Tune for SSIM", "ssim"},
+#else
+ {VP8_TUNE_NONE, "none", "none"},
+#endif
{0, NULL, NULL}
};
static volatile GType id = 0;
@@ -542,7 +552,12 @@ gst_vp8_enc_set_property (GObject * object, guint prop_id,
gst_vp8_enc->noise_sensitivity = g_value_get_int (value);
break;
case PROP_TUNE:
+#ifdef HAVE_VP8ENC_TUNING
gst_vp8_enc->tuning = g_value_get_enum (value);
+#else
+ GST_WARNING_OBJECT (gst_vp8_enc,
+ "The tuning property is unsupported by this libvpx");
+#endif
break;
case PROP_STATIC_THRESHOLD:
gst_vp8_enc->static_threshold = g_value_get_int (value);
@@ -626,7 +641,12 @@ gst_vp8_enc_get_property (GObject * object, guint prop_id, GValue * value,
g_value_set_int (value, gst_vp8_enc->noise_sensitivity);
break;
case PROP_TUNE:
+#ifdef HAVE_VP8ENC_TUNING
g_value_set_enum (value, gst_vp8_enc->tuning);
+#else
+ GST_WARNING_OBJECT (gst_vp8_enc,
+ "The tuning property is unsupported by this libvpx");
+#endif
break;
case PROP_STATIC_THRESHOLD:
g_value_set_int (value, gst_vp8_enc->static_threshold);
@@ -800,8 +820,10 @@ gst_vp8_enc_set_format (GstBaseVideoEncoder * base_video_encoder,
status = vpx_codec_control (&encoder->encoder, VP8E_SET_ARNR_TYPE,
encoder->arnr_type);
#endif
+#ifdef HAVE_VP8ENC_TUNING
status = vpx_codec_control (&encoder->encoder, VP8E_SET_TUNING,
encoder->tuning);
+#endif
status =
vpx_codec_control (&encoder->encoder, VP8E_SET_ENABLEAUTOALTREF,
@@ -857,7 +879,6 @@ gst_vp8_enc_set_format (GstBaseVideoEncoder * base_video_encoder,
GstStructure *s;
GstBuffer *stream_hdr, *vorbiscomment;
const GstTagList *iface_tags;
- GstTagList *tags;
GValue array = { 0, };
GValue value = { 0, };
s = gst_caps_get_structure (caps, 0);
@@ -892,8 +913,8 @@ gst_vp8_enc_set_format (GstBaseVideoEncoder * base_video_encoder,
gst_tag_setter_get_tag_list (GST_TAG_SETTER (base_video_encoder));
if (iface_tags) {
vorbiscomment =
- gst_tag_list_to_vorbiscomment_buffer ((iface_tags) ? iface_tags :
- tags, (const guint8 *) "OVP80\2 ", 7,
+ gst_tag_list_to_vorbiscomment_buffer (iface_tags,
+ (const guint8 *) "OVP80\2 ", 7,
"Encoded with GStreamer vp8enc " PACKAGE_VERSION);
GST_BUFFER_FLAG_SET (vorbiscomment, GST_BUFFER_FLAG_IN_CAPS);
diff --git a/ext/vp8/gstvp8enc.h b/ext/vp8/gstvp8enc.h
index 420963529..3b0151297 100644
--- a/ext/vp8/gstvp8enc.h
+++ b/ext/vp8/gstvp8enc.h
@@ -78,7 +78,9 @@ struct _GstVP8Enc
unsigned int lag_in_frames;
int sharpness;
int noise_sensitivity;
+#ifdef HAVE_VP8ENC_TUNING
vp8e_tuning tuning;
+#endif
int static_threshold;
gboolean drop_frame;
gboolean resize_allowed;
diff --git a/gst-libs/gst/Makefile.am b/gst-libs/gst/Makefile.am
index f58086ca5..ac83c681f 100644
--- a/gst-libs/gst/Makefile.am
+++ b/gst-libs/gst/Makefile.am
@@ -1,8 +1,5 @@
-if BUILD_EXPERIMENTAL
-EXPERIMENTAL_LIBS=basecamerabinsrc
-endif
-SUBDIRS = interfaces signalprocessor video $(EXPERIMENTAL_LIBS)
+SUBDIRS = interfaces signalprocessor video basecamerabinsrc
noinst_HEADERS = gst-i18n-plugin.h gettext.h
DIST_SUBDIRS = interfaces signalprocessor video basecamerabinsrc
diff --git a/gst-libs/gst/video/gstbasevideocodec.c b/gst-libs/gst/video/gstbasevideocodec.c
index 31fa5e5df..68e203d55 100644
--- a/gst-libs/gst/video/gstbasevideocodec.c
+++ b/gst-libs/gst/video/gstbasevideocodec.c
@@ -97,6 +97,7 @@ gst_base_video_codec_init (GstBaseVideoCodec * base_video_codec,
gst_segment_init (&base_video_codec->segment, GST_FORMAT_TIME);
+ g_static_rec_mutex_init (&base_video_codec->stream_lock);
}
static void
@@ -106,24 +107,28 @@ gst_base_video_codec_reset (GstBaseVideoCodec * base_video_codec)
GST_DEBUG_OBJECT (base_video_codec, "reset");
- GST_OBJECT_LOCK (base_video_codec);
+ GST_BASE_VIDEO_CODEC_STREAM_LOCK (base_video_codec);
for (g = base_video_codec->frames; g; g = g_list_next (g)) {
gst_base_video_codec_free_frame ((GstVideoFrame *) g->data);
}
g_list_free (base_video_codec->frames);
base_video_codec->frames = NULL;
- GST_OBJECT_UNLOCK (base_video_codec);
base_video_codec->bytes = 0;
base_video_codec->time = 0;
gst_buffer_replace (&base_video_codec->state.codec_data, NULL);
gst_caps_replace (&base_video_codec->state.caps, NULL);
+ GST_BASE_VIDEO_CODEC_STREAM_UNLOCK (base_video_codec);
}
static void
gst_base_video_codec_finalize (GObject * object)
{
+ GstBaseVideoCodec *base_video_codec = GST_BASE_VIDEO_CODEC (object);
+
+ g_static_rec_mutex_free (&base_video_codec->stream_lock);
+
G_OBJECT_CLASS (parent_class)->finalize (object);
}
@@ -170,8 +175,10 @@ gst_base_video_codec_new_frame (GstBaseVideoCodec * base_video_codec)
frame = g_slice_new0 (GstVideoFrame);
+ GST_BASE_VIDEO_CODEC_STREAM_LOCK (base_video_codec);
frame->system_frame_number = base_video_codec->system_frame_number;
base_video_codec->system_frame_number++;
+ GST_BASE_VIDEO_CODEC_STREAM_UNLOCK (base_video_codec);
return frame;
}
diff --git a/gst-libs/gst/video/gstbasevideocodec.h b/gst-libs/gst/video/gstbasevideocodec.h
index c1e37120d..6471c352f 100644
--- a/gst-libs/gst/video/gstbasevideocodec.h
+++ b/gst-libs/gst/video/gstbasevideocodec.h
@@ -79,6 +79,9 @@ G_BEGIN_DECLS
*/
#define GST_BASE_VIDEO_CODEC_FLOW_NEED_DATA GST_FLOW_CUSTOM_SUCCESS
+#define GST_BASE_VIDEO_CODEC_STREAM_LOCK(codec) g_static_rec_mutex_lock (&GST_BASE_VIDEO_CODEC (codec)->stream_lock)
+#define GST_BASE_VIDEO_CODEC_STREAM_UNLOCK(codec) g_static_rec_mutex_unlock (&GST_BASE_VIDEO_CODEC (codec)->stream_lock)
+
typedef struct _GstVideoState GstVideoState;
typedef struct _GstVideoFrame GstVideoFrame;
typedef struct _GstBaseVideoCodec GstBaseVideoCodec;
@@ -145,6 +148,11 @@ struct _GstBaseVideoCodec
GstPad *sinkpad;
GstPad *srcpad;
+ /* protects all data processing, i.e. is locked
+ * in the chain function, finish_frame and when
+ * processing serialized events */
+ GStaticRecMutex stream_lock;
+
guint64 system_frame_number;
GList *frames; /* Protected with OBJECT_LOCK */
diff --git a/gst-libs/gst/video/gstbasevideodecoder.c b/gst-libs/gst/video/gstbasevideodecoder.c
index 5392d4486..1b01ed701 100644
--- a/gst-libs/gst/video/gstbasevideodecoder.c
+++ b/gst-libs/gst/video/gstbasevideodecoder.c
@@ -196,8 +196,6 @@ gst_base_video_decoder_class_init (GstBaseVideoDecoderClass * klass)
gstelement_class->change_state =
GST_DEBUG_FUNCPTR (gst_base_video_decoder_change_state);
-
- parent_class = g_type_class_peek_parent (klass);
}
static void
@@ -257,8 +255,10 @@ gst_base_video_decoder_push_src_event (GstBaseVideoDecoder * decoder,
|| GST_EVENT_TYPE (event) == GST_EVENT_FLUSH_STOP)
return gst_pad_push_event (decoder->base_video_codec.srcpad, event);
+ GST_BASE_VIDEO_CODEC_STREAM_LOCK (decoder);
decoder->current_frame_events =
g_list_prepend (decoder->current_frame_events, event);
+ GST_BASE_VIDEO_CODEC_STREAM_UNLOCK (decoder);
return TRUE;
}
@@ -279,6 +279,8 @@ gst_base_video_decoder_sink_setcaps (GstPad * pad, GstCaps * caps)
GST_DEBUG_OBJECT (base_video_decoder, "setcaps %" GST_PTR_FORMAT, caps);
+ GST_BASE_VIDEO_CODEC_STREAM_LOCK (base_video_decoder);
+
memset (&state, 0, sizeof (state));
state.caps = gst_caps_ref (caps);
@@ -322,6 +324,7 @@ gst_base_video_decoder_sink_setcaps (GstPad * pad, GstCaps * caps)
gst_caps_replace (&state.caps, NULL);
}
+ GST_BASE_VIDEO_CODEC_STREAM_UNLOCK (base_video_decoder);
g_object_unref (base_video_decoder);
return ret;
@@ -404,7 +407,8 @@ gst_base_video_decoder_sink_event (GstPad * pad, GstEvent * event)
case GST_EVENT_EOS:
{
GstFlowReturn flow_ret;
- ;
+
+ GST_BASE_VIDEO_CODEC_STREAM_LOCK (base_video_decoder);
if (!base_video_decoder->packetized) {
do {
flow_ret =
@@ -420,8 +424,9 @@ gst_base_video_decoder_sink_event (GstPad * pad, GstEvent * event)
if (flow_ret == GST_FLOW_OK)
ret = gst_base_video_decoder_push_src_event (base_video_decoder, event);
- }
+ GST_BASE_VIDEO_CODEC_STREAM_UNLOCK (base_video_decoder);
break;
+ }
case GST_EVENT_NEWSEGMENT:
{
gboolean update;
@@ -432,6 +437,7 @@ gst_base_video_decoder_sink_event (GstPad * pad, GstEvent * event)
gint64 pos;
GstSegment *segment = &GST_BASE_VIDEO_CODEC (base_video_decoder)->segment;
+ GST_BASE_VIDEO_CODEC_STREAM_LOCK (base_video_decoder);
gst_event_parse_new_segment_full (event, &update, &rate,
&arate, &format, &start, &stop, &pos);
@@ -468,6 +474,7 @@ gst_base_video_decoder_sink_event (GstPad * pad, GstEvent * event)
event = gst_event_new_new_segment_full (update, rate, arate,
GST_FORMAT_TIME, start, stop, pos);
} else {
+ GST_BASE_VIDEO_CODEC_STREAM_UNLOCK (base_video_decoder);
goto newseg_wrong_format;
}
}
@@ -482,12 +489,15 @@ gst_base_video_decoder_sink_event (GstPad * pad, GstEvent * event)
update, rate, arate, format, start, stop, pos);
ret = gst_base_video_decoder_push_src_event (base_video_decoder, event);
+ GST_BASE_VIDEO_CODEC_STREAM_UNLOCK (base_video_decoder);
break;
}
case GST_EVENT_FLUSH_STOP:
{
+ GST_BASE_VIDEO_CODEC_STREAM_LOCK (base_video_decoder);
/* well, this is kind of worse than a DISCONT */
gst_base_video_decoder_flush (base_video_decoder, TRUE);
+ GST_BASE_VIDEO_CODEC_STREAM_UNLOCK (base_video_decoder);
}
default:
/* FIXME this changes the order of events */
@@ -930,6 +940,8 @@ gst_base_video_decoder_reset (GstBaseVideoDecoder * base_video_decoder,
{
GST_DEBUG_OBJECT (base_video_decoder, "reset full %d", full);
+ GST_BASE_VIDEO_CODEC_STREAM_LOCK (base_video_decoder);
+
if (full) {
gst_segment_init (&GST_BASE_VIDEO_CODEC (base_video_decoder)->segment,
GST_FORMAT_UNDEFINED);
@@ -965,6 +977,7 @@ gst_base_video_decoder_reset (GstBaseVideoDecoder * base_video_decoder,
GST_CLOCK_TIME_NONE;
GST_BASE_VIDEO_CODEC (base_video_decoder)->proportion = 0.5;
GST_OBJECT_UNLOCK (base_video_decoder);
+ GST_BASE_VIDEO_CODEC_STREAM_UNLOCK (base_video_decoder);
}
static GstFlowReturn
@@ -1211,6 +1224,7 @@ static GstFlowReturn
gst_base_video_decoder_chain (GstPad * pad, GstBuffer * buf)
{
GstBaseVideoDecoder *base_video_decoder;
+ GstFlowReturn ret = GST_FLOW_OK;
base_video_decoder = GST_BASE_VIDEO_DECODER (GST_PAD_PARENT (pad));
@@ -1219,6 +1233,8 @@ gst_base_video_decoder_chain (GstPad * pad, GstBuffer * buf)
GST_TIME_ARGS (GST_BUFFER_TIMESTAMP (buf)),
GST_TIME_ARGS (GST_BUFFER_DURATION (buf)), GST_BUFFER_SIZE (buf));
+ GST_BASE_VIDEO_CODEC_STREAM_LOCK (base_video_decoder);
+
/* NOTE:
* requiring the pad to be negotiated makes it impossible to use
* oggdemux or filesrc ! decoder */
@@ -1242,7 +1258,8 @@ gst_base_video_decoder_chain (GstPad * pad, GstBuffer * buf)
ret = gst_base_video_decoder_push_src_event (base_video_decoder, event);
if (!ret) {
GST_ERROR_OBJECT (base_video_decoder, "new segment event ret=%d", ret);
- return GST_FLOW_ERROR;
+ ret = GST_FLOW_ERROR;
+ goto done;
}
}
@@ -1270,9 +1287,13 @@ gst_base_video_decoder_chain (GstPad * pad, GstBuffer * buf)
}
if (GST_BASE_VIDEO_CODEC (base_video_decoder)->segment.rate > 0.0)
- return gst_base_video_decoder_chain_forward (base_video_decoder, buf);
+ ret = gst_base_video_decoder_chain_forward (base_video_decoder, buf);
else
- return gst_base_video_decoder_chain_reverse (base_video_decoder, buf);
+ ret = gst_base_video_decoder_chain_reverse (base_video_decoder, buf);
+
+done:
+ GST_BASE_VIDEO_CODEC_STREAM_UNLOCK (base_video_decoder);
+ return ret;
}
static GstStateChangeReturn
@@ -1302,11 +1323,14 @@ gst_base_video_decoder_change_state (GstElement * element,
if (base_video_decoder_class->stop) {
base_video_decoder_class->stop (base_video_decoder);
}
+
+ GST_BASE_VIDEO_CODEC_STREAM_LOCK (base_video_decoder);
gst_base_video_decoder_reset (base_video_decoder, TRUE);
g_list_foreach (base_video_decoder->current_frame_events,
(GFunc) gst_event_unref, NULL);
g_list_free (base_video_decoder->current_frame_events);
base_video_decoder->current_frame_events = NULL;
+ GST_BASE_VIDEO_CODEC_STREAM_UNLOCK (base_video_decoder);
break;
default:
break;
@@ -1320,6 +1344,7 @@ gst_base_video_decoder_new_frame (GstBaseVideoDecoder * base_video_decoder)
{
GstVideoFrame *frame;
+ GST_BASE_VIDEO_CODEC_STREAM_LOCK (base_video_decoder);
frame =
gst_base_video_codec_new_frame (GST_BASE_VIDEO_CODEC
(base_video_decoder));
@@ -1335,6 +1360,8 @@ gst_base_video_decoder_new_frame (GstBaseVideoDecoder * base_video_decoder)
frame->events = base_video_decoder->current_frame_events;
base_video_decoder->current_frame_events = NULL;
+ GST_BASE_VIDEO_CODEC_STREAM_UNLOCK (base_video_decoder);
+
return frame;
}
@@ -1360,13 +1387,13 @@ gst_base_video_decoder_finish_frame (GstBaseVideoDecoder * base_video_decoder,
GList *l, *events = NULL;
GST_LOG_OBJECT (base_video_decoder, "finish frame");
+ GST_BASE_VIDEO_CODEC_STREAM_LOCK (base_video_decoder);
+
#ifndef GST_DISABLE_GST_DEBUG
- GST_OBJECT_LOCK (base_video_decoder);
GST_LOG_OBJECT (base_video_decoder, "n %d in %d out %d",
g_list_length (GST_BASE_VIDEO_CODEC (base_video_decoder)->frames),
gst_adapter_available (base_video_decoder->input_adapter),
gst_adapter_available (base_video_decoder->output_adapter));
- GST_OBJECT_UNLOCK (base_video_decoder);
#endif
GST_LOG_OBJECT (base_video_decoder,
@@ -1374,7 +1401,6 @@ gst_base_video_decoder_finish_frame (GstBaseVideoDecoder * base_video_decoder,
GST_TIME_ARGS (frame->presentation_timestamp));
/* Push all pending events that arrived before this frame */
- GST_OBJECT_LOCK (base_video_decoder);
for (l = base_video_decoder->base_video_codec.frames; l; l = l->next) {
GstVideoFrame *tmp = l->data;
@@ -1390,7 +1416,6 @@ gst_base_video_decoder_finish_frame (GstBaseVideoDecoder * base_video_decoder,
if (tmp == frame)
break;
}
- GST_OBJECT_UNLOCK (base_video_decoder);
for (l = g_list_last (events); l; l = l->next)
gst_pad_push_event (GST_BASE_VIDEO_CODEC_SRC_PAD (base_video_decoder),
@@ -1544,7 +1569,8 @@ gst_base_video_decoder_finish_frame (GstBaseVideoDecoder * base_video_decoder,
GST_TIME_ARGS (segment->start),
GST_TIME_ARGS (segment->stop), GST_TIME_ARGS (segment->time));
gst_buffer_unref (src_buffer);
- return GST_FLOW_OK;
+ ret = GST_FLOW_OK;
+ goto done;
}
}
@@ -1562,12 +1588,12 @@ gst_base_video_decoder_finish_frame (GstBaseVideoDecoder * base_video_decoder,
}
done:
- GST_OBJECT_LOCK (base_video_decoder);
GST_BASE_VIDEO_CODEC (base_video_decoder)->frames =
g_list_remove (GST_BASE_VIDEO_CODEC (base_video_decoder)->frames, frame);
- GST_OBJECT_UNLOCK (base_video_decoder);
gst_base_video_codec_free_frame (frame);
+ GST_BASE_VIDEO_CODEC_STREAM_UNLOCK (base_video_decoder);
+
return ret;
}
@@ -1589,6 +1615,7 @@ gst_base_video_decoder_add_to_frame (GstBaseVideoDecoder * base_video_decoder,
if (n_bytes == 0)
return;
+ GST_BASE_VIDEO_CODEC_STREAM_LOCK (base_video_decoder);
if (gst_adapter_available (base_video_decoder->output_adapter) == 0) {
base_video_decoder->frame_offset = base_video_decoder->input_offset -
gst_adapter_available (base_video_decoder->input_adapter);
@@ -1596,6 +1623,7 @@ gst_base_video_decoder_add_to_frame (GstBaseVideoDecoder * base_video_decoder,
buf = gst_adapter_take_buffer (base_video_decoder->input_adapter, n_bytes);
gst_adapter_push (base_video_decoder->output_adapter, buf);
+ GST_BASE_VIDEO_CODEC_STREAM_UNLOCK (base_video_decoder);
}
static guint64
@@ -1670,9 +1698,12 @@ gst_base_video_decoder_have_frame (GstBaseVideoDecoder * base_video_decoder)
int n_available;
GstClockTime timestamp;
GstClockTime duration;
+ GstFlowReturn ret = GST_FLOW_OK;
GST_LOG_OBJECT (base_video_decoder, "have_frame");
+ GST_BASE_VIDEO_CODEC_STREAM_LOCK (base_video_decoder);
+
n_available = gst_adapter_available (base_video_decoder->output_adapter);
if (n_available) {
buffer = gst_adapter_take_buffer (base_video_decoder->output_adapter,
@@ -1693,7 +1724,11 @@ gst_base_video_decoder_have_frame (GstBaseVideoDecoder * base_video_decoder)
"ts %" GST_TIME_FORMAT ", dur %" GST_TIME_FORMAT,
n_available, GST_TIME_ARGS (timestamp), GST_TIME_ARGS (duration));
- return gst_base_video_decoder_have_frame_2 (base_video_decoder);
+ ret = gst_base_video_decoder_have_frame_2 (base_video_decoder);
+
+ GST_BASE_VIDEO_CODEC_STREAM_UNLOCK (base_video_decoder);
+
+ return ret;
}
static GstFlowReturn
@@ -1729,10 +1764,8 @@ gst_base_video_decoder_have_frame_2 (GstBaseVideoDecoder * base_video_decoder)
GST_TIME_ARGS (frame->decode_timestamp));
GST_LOG_OBJECT (base_video_decoder, "dist %d", frame->distance_from_sync);
- GST_OBJECT_LOCK (base_video_decoder);
GST_BASE_VIDEO_CODEC (base_video_decoder)->frames =
g_list_append (GST_BASE_VIDEO_CODEC (base_video_decoder)->frames, frame);
- GST_OBJECT_UNLOCK (base_video_decoder);
frame->deadline =
gst_segment_to_running_time (&GST_BASE_VIDEO_CODEC
@@ -1779,11 +1812,14 @@ gst_base_video_decoder_lost_sync (GstBaseVideoDecoder * base_video_decoder)
GST_DEBUG_OBJECT (base_video_decoder, "lost_sync");
+ GST_BASE_VIDEO_CODEC_STREAM_LOCK (base_video_decoder);
+
if (gst_adapter_available (base_video_decoder->input_adapter) >= 1) {
gst_adapter_flush (base_video_decoder->input_adapter, 1);
}
base_video_decoder->have_sync = FALSE;
+ GST_BASE_VIDEO_CODEC_STREAM_UNLOCK (base_video_decoder);
}
/* FIXME not quite exciting; get rid of this ? */
@@ -1798,8 +1834,10 @@ gst_base_video_decoder_set_sync_point (GstBaseVideoDecoder * base_video_decoder)
{
GST_DEBUG_OBJECT (base_video_decoder, "set_sync_point");
+ GST_BASE_VIDEO_CODEC_STREAM_LOCK (base_video_decoder);
base_video_decoder->current_frame->is_sync_point = TRUE;
base_video_decoder->distance_from_sync = 0;
+ GST_BASE_VIDEO_CODEC_STREAM_UNLOCK (base_video_decoder);
}
/**
@@ -1814,9 +1852,9 @@ gst_base_video_decoder_get_oldest_frame (GstBaseVideoDecoder *
{
GList *g;
- GST_OBJECT_LOCK (base_video_decoder);
+ GST_BASE_VIDEO_CODEC_STREAM_LOCK (base_video_decoder);
g = g_list_first (GST_BASE_VIDEO_CODEC (base_video_decoder)->frames);
- GST_OBJECT_UNLOCK (base_video_decoder);
+ GST_BASE_VIDEO_CODEC_STREAM_UNLOCK (base_video_decoder);
if (g == NULL)
return NULL;
@@ -1837,7 +1875,7 @@ gst_base_video_decoder_get_frame (GstBaseVideoDecoder * base_video_decoder,
GList *g;
GstVideoFrame *frame = NULL;
- GST_OBJECT_LOCK (base_video_decoder);
+ GST_BASE_VIDEO_CODEC_STREAM_LOCK (base_video_decoder);
for (g = g_list_first (GST_BASE_VIDEO_CODEC (base_video_decoder)->frames);
g; g = g_list_next (g)) {
GstVideoFrame *tmp = g->data;
@@ -1847,7 +1885,7 @@ gst_base_video_decoder_get_frame (GstBaseVideoDecoder * base_video_decoder,
break;
}
}
- GST_OBJECT_UNLOCK (base_video_decoder);
+ GST_BASE_VIDEO_CODEC_STREAM_UNLOCK (base_video_decoder);
return frame;
}
@@ -1871,6 +1909,8 @@ gst_base_video_decoder_set_src_caps (GstBaseVideoDecoder * base_video_decoder)
g_return_val_if_fail (state->width != 0, FALSE);
g_return_val_if_fail (state->height != 0, FALSE);
+ GST_BASE_VIDEO_CODEC_STREAM_LOCK (base_video_decoder);
+
/* sanitize */
if (state->fps_n == 0 || state->fps_d == 0) {
state->fps_n = 0;
@@ -1898,6 +1938,8 @@ gst_base_video_decoder_set_src_caps (GstBaseVideoDecoder * base_video_decoder)
state->bytes_per_picture =
gst_video_format_get_size (state->format, state->width, state->height);
+ GST_BASE_VIDEO_CODEC_STREAM_UNLOCK (base_video_decoder);
+
return ret;
}
@@ -1922,6 +1964,9 @@ gst_base_video_decoder_alloc_src_buffer (GstBaseVideoDecoder *
GST_DEBUG ("alloc src buffer caps=%" GST_PTR_FORMAT,
GST_PAD_CAPS (GST_BASE_VIDEO_CODEC_SRC_PAD (base_video_decoder)));
+
+ GST_BASE_VIDEO_CODEC_STREAM_LOCK (base_video_decoder);
+
flow_ret =
gst_pad_alloc_buffer_and_set_caps (GST_BASE_VIDEO_CODEC_SRC_PAD
(base_video_decoder), GST_BUFFER_OFFSET_NONE, num_bytes,
@@ -1934,6 +1979,7 @@ gst_base_video_decoder_alloc_src_buffer (GstBaseVideoDecoder *
GST_PAD_CAPS (GST_BASE_VIDEO_CODEC_SRC_PAD (base_video_decoder)));
}
+ GST_BASE_VIDEO_CODEC_STREAM_UNLOCK (base_video_decoder);
return buffer;
}
@@ -1962,6 +2008,8 @@ gst_base_video_decoder_alloc_src_frame (GstBaseVideoDecoder *
(base_video_decoder)) != NULL, GST_FLOW_ERROR);
GST_LOG_OBJECT (base_video_decoder, "alloc buffer size %d", num_bytes);
+ GST_BASE_VIDEO_CODEC_STREAM_LOCK (base_video_decoder);
+
flow_ret =
gst_pad_alloc_buffer_and_set_caps (GST_BASE_VIDEO_CODEC_SRC_PAD
(base_video_decoder), GST_BUFFER_OFFSET_NONE, num_bytes,
@@ -1973,6 +2021,8 @@ gst_base_video_decoder_alloc_src_frame (GstBaseVideoDecoder *
gst_flow_get_name (flow_ret));
}
+ GST_BASE_VIDEO_CODEC_STREAM_UNLOCK (base_video_decoder);
+
return flow_ret;
}
@@ -1995,6 +2045,7 @@ gst_base_video_decoder_get_max_decode_time (GstBaseVideoDecoder *
GstClockTimeDiff deadline;
GstClockTime earliest_time;
+ GST_OBJECT_LOCK (base_video_decoder);
earliest_time = GST_BASE_VIDEO_CODEC (base_video_decoder)->earliest_time;
if (GST_CLOCK_TIME_IS_VALID (earliest_time))
deadline = GST_CLOCK_DIFF (earliest_time, frame->deadline);
@@ -2006,6 +2057,8 @@ gst_base_video_decoder_get_max_decode_time (GstBaseVideoDecoder *
GST_TIME_ARGS (earliest_time), GST_TIME_ARGS (frame->deadline),
GST_TIME_ARGS (deadline));
+ GST_OBJECT_UNLOCK (base_video_decoder);
+
return deadline;
}
diff --git a/gst-libs/gst/video/gstbasevideoencoder.c b/gst-libs/gst/video/gstbasevideoencoder.c
index 88d8c72dc..e1c2c77a6 100644
--- a/gst-libs/gst/video/gstbasevideoencoder.c
+++ b/gst-libs/gst/video/gstbasevideoencoder.c
@@ -169,13 +169,13 @@ gst_base_video_encoder_class_init (GstBaseVideoEncoderClass * klass)
gstelement_class->change_state =
GST_DEBUG_FUNCPTR (gst_base_video_encoder_change_state);
-
- parent_class = g_type_class_peek_parent (klass);
}
static void
gst_base_video_encoder_reset (GstBaseVideoEncoder * base_video_encoder)
{
+ GST_BASE_VIDEO_CODEC_STREAM_LOCK (base_video_encoder);
+
base_video_encoder->presentation_frame_number = 0;
base_video_encoder->distance_from_sync = 0;
base_video_encoder->force_keyframe = FALSE;
@@ -193,6 +193,8 @@ gst_base_video_encoder_reset (GstBaseVideoEncoder * base_video_encoder)
(GFunc) gst_event_unref, NULL);
g_list_free (base_video_encoder->current_frame_events);
base_video_encoder->current_frame_events = NULL;
+
+ GST_BASE_VIDEO_CODEC_STREAM_UNLOCK (base_video_encoder);
}
static void
@@ -285,6 +287,8 @@ gst_base_video_encoder_sink_setcaps (GstPad * pad, GstCaps * caps)
GST_DEBUG_OBJECT (base_video_encoder, "setcaps %" GST_PTR_FORMAT, caps);
+ GST_BASE_VIDEO_CODEC_STREAM_LOCK (base_video_encoder);
+
state = &GST_BASE_VIDEO_CODEC (base_video_encoder)->state;
memset (&tmp_state, 0, sizeof (tmp_state));
@@ -351,13 +355,15 @@ gst_base_video_encoder_sink_setcaps (GstPad * pad, GstCaps * caps)
}
exit:
- g_object_unref (base_video_encoder);
+ GST_BASE_VIDEO_CODEC_STREAM_UNLOCK (base_video_encoder);
if (!ret) {
GST_WARNING_OBJECT (base_video_encoder, "rejected caps %" GST_PTR_FORMAT,
caps);
}
+ g_object_unref (base_video_encoder);
+
return ret;
}
@@ -452,6 +458,7 @@ gst_base_video_encoder_sink_eventfunc (GstBaseVideoEncoder * base_video_encoder,
{
GstFlowReturn flow_ret;
+ GST_BASE_VIDEO_CODEC_STREAM_LOCK (base_video_encoder);
base_video_encoder->a.at_eos = TRUE;
if (base_video_encoder_class->finish) {
@@ -461,6 +468,7 @@ gst_base_video_encoder_sink_eventfunc (GstBaseVideoEncoder * base_video_encoder,
}
ret = (flow_ret == GST_BASE_VIDEO_ENCODER_FLOW_DROPPED);
+ GST_BASE_VIDEO_CODEC_STREAM_UNLOCK (base_video_encoder);
break;
}
case GST_EVENT_NEWSEGMENT:
@@ -473,6 +481,7 @@ gst_base_video_encoder_sink_eventfunc (GstBaseVideoEncoder * base_video_encoder,
gint64 stop;
gint64 position;
+ GST_BASE_VIDEO_CODEC_STREAM_LOCK (base_video_encoder);
gst_event_parse_new_segment_full (event, &update, &rate, &applied_rate,
&format, &start, &stop, &position);
@@ -484,6 +493,7 @@ gst_base_video_encoder_sink_eventfunc (GstBaseVideoEncoder * base_video_encoder,
if (format != GST_FORMAT_TIME) {
GST_DEBUG_OBJECT (base_video_encoder, "received non TIME newsegment");
+ GST_BASE_VIDEO_CODEC_STREAM_UNLOCK (base_video_encoder);
break;
}
@@ -492,6 +502,7 @@ gst_base_video_encoder_sink_eventfunc (GstBaseVideoEncoder * base_video_encoder,
gst_segment_set_newsegment_full (&GST_BASE_VIDEO_CODEC
(base_video_encoder)->segment, update, rate, applied_rate, format,
start, stop, position);
+ GST_BASE_VIDEO_CODEC_STREAM_UNLOCK (base_video_encoder);
break;
}
case GST_EVENT_CUSTOM_DOWNSTREAM:
@@ -556,8 +567,10 @@ gst_base_video_encoder_sink_event (GstPad * pad, GstEvent * event)
|| GST_EVENT_TYPE (event) == GST_EVENT_FLUSH_STOP) {
ret = gst_pad_push_event (enc->base_video_codec.srcpad, event);
} else {
+ GST_BASE_VIDEO_CODEC_STREAM_LOCK (enc);
enc->current_frame_events =
g_list_prepend (enc->current_frame_events, event);
+ GST_BASE_VIDEO_CODEC_STREAM_UNLOCK (enc);
}
}
@@ -699,8 +712,11 @@ gst_base_video_encoder_chain (GstPad * pad, GstBuffer * buf)
g_return_val_if_fail (klass->handle_frame != NULL, GST_FLOW_ERROR);
+ GST_BASE_VIDEO_CODEC_STREAM_LOCK (base_video_encoder);
+
if (!GST_PAD_CAPS (pad)) {
- return GST_FLOW_NOT_NEGOTIATED;
+ ret = GST_FLOW_NOT_NEGOTIATED;
+ goto done;
}
GST_LOG_OBJECT (base_video_encoder,
@@ -710,7 +726,8 @@ gst_base_video_encoder_chain (GstPad * pad, GstBuffer * buf)
GST_TIME_ARGS (GST_BUFFER_DURATION (buf)));
if (base_video_encoder->a.at_eos) {
- return GST_FLOW_UNEXPECTED;
+ ret = GST_FLOW_UNEXPECTED;
+ goto done;
}
if (base_video_encoder->sink_clipping) {
@@ -746,10 +763,8 @@ gst_base_video_encoder_chain (GstPad * pad, GstBuffer * buf)
frame->force_keyframe = base_video_encoder->force_keyframe;
base_video_encoder->force_keyframe = FALSE;
- GST_OBJECT_LOCK (base_video_encoder);
GST_BASE_VIDEO_CODEC (base_video_encoder)->frames =
g_list_append (GST_BASE_VIDEO_CODEC (base_video_encoder)->frames, frame);
- GST_OBJECT_UNLOCK (base_video_encoder);
/* new data, more finish needed */
base_video_encoder->drained = FALSE;
@@ -760,6 +775,8 @@ gst_base_video_encoder_chain (GstPad * pad, GstBuffer * buf)
ret = klass->handle_frame (base_video_encoder, frame);
done:
+ GST_BASE_VIDEO_CODEC_STREAM_UNLOCK (base_video_encoder);
+
g_object_unref (base_video_encoder);
return ret;
@@ -831,6 +848,8 @@ gst_base_video_encoder_finish_frame (GstBaseVideoEncoder * base_video_encoder,
GST_LOG_OBJECT (base_video_encoder,
"finish frame fpn %d", frame->presentation_frame_number);
+ GST_BASE_VIDEO_CODEC_STREAM_LOCK (base_video_encoder);
+
/* Push all pending events that arrived before this frame */
for (l = base_video_encoder->base_video_codec.frames; l; l = l->next) {
GstVideoFrame *tmp = l->data;
@@ -945,13 +964,13 @@ gst_base_video_encoder_finish_frame (GstBaseVideoEncoder * base_video_encoder,
done:
/* handed out */
- GST_OBJECT_LOCK (base_video_encoder);
GST_BASE_VIDEO_CODEC (base_video_encoder)->frames =
g_list_remove (GST_BASE_VIDEO_CODEC (base_video_encoder)->frames, frame);
- GST_OBJECT_UNLOCK (base_video_encoder);
gst_base_video_codec_free_frame (frame);
+ GST_BASE_VIDEO_CODEC_STREAM_UNLOCK (base_video_encoder);
+
return ret;
}
@@ -1025,9 +1044,9 @@ gst_base_video_encoder_get_oldest_frame (GstBaseVideoEncoder *
{
GList *g;
- GST_OBJECT_LOCK (base_video_encoder);
+ GST_BASE_VIDEO_CODEC_STREAM_LOCK (base_video_encoder);
g = g_list_first (GST_BASE_VIDEO_CODEC (base_video_encoder)->frames);
- GST_OBJECT_UNLOCK (base_video_encoder);
+ GST_BASE_VIDEO_CODEC_STREAM_UNLOCK (base_video_encoder);
if (g == NULL)
return NULL;
diff --git a/gst/camerabin2/gstcamerabin2.c b/gst/camerabin2/gstcamerabin2.c
index fc517e121..f40ef051b 100644
--- a/gst/camerabin2/gstcamerabin2.c
+++ b/gst/camerabin2/gstcamerabin2.c
@@ -23,7 +23,7 @@
* elements, providing an API for controlling a digital camera.
*
* <note>
- * Note that camerabin2 is still UNSTABLE, EXPERIMENTAL and under
+ * Note that camerabin2 is still UNSTABLE and under
* development.
* </note>
*
@@ -270,6 +270,9 @@ gst_cam_flags_get_type (void)
"elements", "no-audio-conversion"},
{C_FLAGS (GST_CAM_FLAG_NO_VIDEO_CONVERSION), "Do not use video conversion "
"elements", "no-video-conversion"},
+ {C_FLAGS (GST_CAM_FLAG_NO_VIEWFINDER_CONVERSION),
+ "Do not use viewfinder conversion " "elements",
+ "no-viewfinder-conversion"},
{0, NULL, NULL}
};
static volatile GType id = 0;
@@ -439,6 +442,7 @@ gst_camera_bin_stop_capture (GstCameraBin2 * camerabin)
g_signal_emit_by_name (camerabin->src, "stop-capture", NULL);
if (camerabin->mode == MODE_VIDEO && camerabin->audio_src) {
+ camerabin->audio_drop_eos = FALSE;
gst_element_send_event (camerabin->audio_src, gst_event_new_eos ());
}
}
@@ -1213,6 +1217,25 @@ gst_camera_bin_image_sink_event_probe (GstPad * pad, GstEvent * event,
return TRUE;
}
+static gboolean
+gst_camera_bin_audio_src_event_probe (GstPad * pad, GstEvent * event,
+ gpointer data)
+{
+ GstCameraBin2 *camera = data;
+ gboolean ret = TRUE;
+
+ if (GST_EVENT_TYPE (event) == GST_EVENT_EOS) {
+ /* we only let an EOS pass when the user is stopping a capture */
+ if (camera->audio_drop_eos) {
+ ret = FALSE;
+ } else {
+ camera->audio_drop_eos = TRUE;
+ }
+ }
+
+ return ret;
+}
+
/**
* gst_camera_bin_create_elements:
* @param camera: the #GstCameraBin2
@@ -1253,14 +1276,6 @@ gst_camera_bin_create_elements (GstCameraBin2 * camera)
g_signal_connect (camera->video_encodebin, "element-added",
(GCallback) encodebin_element_added, camera);
- /* propagate the flags property by translating appropriate values
- * to GstEncFlags values */
- if (camera->flags & GST_CAM_FLAG_NO_AUDIO_CONVERSION)
- encbin_flags |= (1 << 0);
- if (camera->flags & GST_CAM_FLAG_NO_VIDEO_CONVERSION)
- encbin_flags |= (1 << 1);
- g_object_set (camera->video_encodebin, "flags", encbin_flags, NULL);
-
camera->videosink =
gst_element_factory_make ("filesink", "videobin-filesink");
if (!camera->videosink) {
@@ -1362,11 +1377,14 @@ gst_camera_bin_create_elements (GstCameraBin2 * camera)
gst_object_ref (camera->imagesink),
gst_object_ref (camera->viewfinderbin_queue), NULL);
- /* Linking can be optimized TODO */
- gst_element_link (camera->video_encodebin, camera->videosink);
- gst_element_link (camera->image_encodebin, camera->imagesink);
- gst_element_link_many (camera->viewfinderbin_queue,
- camera->viewfinderbin_capsfilter, camera->viewfinderbin, NULL);
+ gst_element_link_pads_full (camera->video_encodebin, "src",
+ camera->videosink, "sink", GST_PAD_LINK_CHECK_NOTHING);
+ gst_element_link_pads_full (camera->image_encodebin, "src",
+ camera->imagesink, "sink", GST_PAD_LINK_CHECK_NOTHING);
+ gst_element_link_pads_full (camera->viewfinderbin_queue, "src",
+ camera->viewfinderbin_capsfilter, "sink", GST_PAD_LINK_CHECK_CAPS);
+ gst_element_link_pads_full (camera->viewfinderbin_capsfilter, "src",
+ camera->viewfinderbin, "sink", GST_PAD_LINK_CHECK_CAPS);
{
/* set an event probe to watch for custom location changes */
@@ -1396,6 +1414,17 @@ gst_camera_bin_create_elements (GstCameraBin2 * camera)
g_object_set (camera->imagesink, "location", camera->location, NULL);
}
+ /* propagate the flags property by translating appropriate values
+ * to GstEncFlags values */
+ if (camera->flags & GST_CAM_FLAG_NO_AUDIO_CONVERSION)
+ encbin_flags |= (1 << 0);
+ if (camera->flags & GST_CAM_FLAG_NO_VIDEO_CONVERSION)
+ encbin_flags |= (1 << 1);
+ g_object_set (camera->video_encodebin, "flags", encbin_flags, NULL);
+
+ g_object_set (camera->viewfinderbin, "disable-converters",
+ camera->flags & GST_CAM_FLAG_NO_VIEWFINDER_CONVERSION, NULL);
+
if (camera->video_profile_switch) {
GST_DEBUG_OBJECT (camera, "Switching encodebin's profile");
g_object_set (camera->video_encodebin, "profile", camera->video_profile,
@@ -1529,6 +1558,8 @@ gst_camera_bin_create_elements (GstCameraBin2 * camera)
}
if (new_audio_src) {
+ GstPad *srcpad;
+
if (g_object_class_find_property (G_OBJECT_GET_CLASS (camera->audio_src),
"provide-clock")) {
g_object_set (camera->audio_src, "provide-clock", FALSE, NULL);
@@ -1540,6 +1571,15 @@ gst_camera_bin_create_elements (GstCameraBin2 * camera)
gst_element_link_many (camera->audio_src, camera->audio_volume,
camera->audio_capsfilter, NULL);
+
+ srcpad = gst_element_get_static_pad (camera->audio_src, "src");
+
+ /* drop EOS for audiosrc elements that push them on state_changes
+ * (basesrc does this) */
+ gst_pad_add_event_probe (srcpad,
+ (GCallback) gst_camera_bin_audio_src_event_probe, camera);
+
+ gst_object_unref (srcpad);
}
if (has_audio) {
gst_camera_bin_check_and_replace_filter (camera, &camera->audio_filter,
@@ -1578,6 +1618,7 @@ gst_camera_bin_change_state (GstElement * element, GstStateChange trans)
GstStateChangeReturn ret = GST_STATE_CHANGE_SUCCESS;
GstCameraBin2 *camera = GST_CAMERA_BIN2_CAST (element);
+
switch (trans) {
case GST_STATE_CHANGE_NULL_TO_READY:
if (!gst_camera_bin_create_elements (camera)) {
@@ -1586,6 +1627,7 @@ gst_camera_bin_change_state (GstElement * element, GstStateChange trans)
break;
case GST_STATE_CHANGE_READY_TO_PAUSED:
GST_CAMERA_BIN2_RESET_PROCESSING_COUNTER (camera);
+ camera->audio_drop_eos = TRUE;
break;
case GST_STATE_CHANGE_PAUSED_TO_READY:
if (GST_STATE (camera->videosink) >= GST_STATE_PAUSED)
@@ -1734,8 +1776,12 @@ gst_camera_bin_set_property (GObject * object, guint prop_id,
"Setting audio capture caps to %" GST_PTR_FORMAT,
gst_value_get_caps (value));
- g_object_set (camera->audio_capsfilter, "caps",
- gst_value_get_caps (value), NULL);
+ if (G_LIKELY (camera->audio_capsfilter)) {
+ g_object_set (camera->audio_capsfilter, "caps",
+ gst_value_get_caps (value), NULL);
+ } else {
+ GST_WARNING_OBJECT (camera, "Audio capsfilter missing");
+ }
}
break;
case PROP_IMAGE_CAPTURE_CAPS:{
@@ -1750,13 +1796,18 @@ gst_camera_bin_set_property (GObject * object, guint prop_id,
"Setting image capture caps to %" GST_PTR_FORMAT,
gst_value_get_caps (value));
+ if (G_LIKELY (camera->imagebin_capsfilter)) {
+ g_object_set (camera->imagebin_capsfilter, "caps",
+ gst_value_get_caps (value), NULL);
+ } else {
+ GST_WARNING_OBJECT (camera, "Image capsfilter missing");
+ }
+
/* set the capsfilter caps and notify the src to renegotiate */
- g_object_set (camera->imagebin_capsfilter, "caps",
- gst_value_get_caps (value), NULL);
if (pad) {
GST_DEBUG_OBJECT (camera, "Pushing renegotiate on %s",
GST_PAD_NAME (pad));
- GST_PAD_EVENTFUNC (pad) (pad, gst_camera_bin_new_event_renegotiate ());
+ gst_pad_send_event (pad, gst_camera_bin_new_event_renegotiate ());
gst_object_unref (pad);
}
}
@@ -1774,12 +1825,17 @@ gst_camera_bin_set_property (GObject * object, guint prop_id,
gst_value_get_caps (value));
/* set the capsfilter caps and notify the src to renegotiate */
- g_object_set (camera->videobin_capsfilter, "caps",
- gst_value_get_caps (value), NULL);
+ if (G_LIKELY (camera->videobin_capsfilter)) {
+ g_object_set (camera->videobin_capsfilter, "caps",
+ gst_value_get_caps (value), NULL);
+ } else {
+ GST_WARNING_OBJECT (camera, "Video capsfilter missing");
+ }
+
if (pad) {
GST_DEBUG_OBJECT (camera, "Pushing renegotiate on %s",
GST_PAD_NAME (pad));
- GST_PAD_EVENTFUNC (pad) (pad, gst_camera_bin_new_event_renegotiate ());
+ gst_pad_send_event (pad, gst_camera_bin_new_event_renegotiate ());
gst_object_unref (pad);
}
}
@@ -1797,12 +1853,17 @@ gst_camera_bin_set_property (GObject * object, guint prop_id,
gst_value_get_caps (value));
/* set the capsfilter caps and notify the src to renegotiate */
- g_object_set (camera->viewfinderbin_capsfilter, "caps",
- gst_value_get_caps (value), NULL);
+ if (G_LIKELY (camera->viewfinderbin_capsfilter)) {
+ g_object_set (camera->viewfinderbin_capsfilter, "caps",
+ gst_value_get_caps (value), NULL);
+ } else {
+ GST_WARNING_OBJECT (camera, "Viewfinder capsfilter missing");
+ }
+
if (pad) {
GST_DEBUG_OBJECT (camera, "Pushing renegotiate on %s",
GST_PAD_NAME (pad));
- GST_PAD_EVENTFUNC (pad) (pad, gst_camera_bin_new_event_renegotiate ());
+ gst_pad_send_event (pad, gst_camera_bin_new_event_renegotiate ());
gst_object_unref (pad);
}
}
@@ -1970,28 +2031,44 @@ gst_camera_bin_get_property (GObject * object, guint prop_id,
break;
case PROP_AUDIO_CAPTURE_CAPS:{
GstCaps *caps = NULL;
- g_object_get (camera->audio_capsfilter, "caps", &caps, NULL);
+ if (G_LIKELY (camera->audio_capsfilter)) {
+ g_object_get (camera->audio_capsfilter, "caps", &caps, NULL);
+ } else {
+ GST_WARNING ("Missing audio capsfilter");
+ }
gst_value_set_caps (value, caps);
gst_caps_unref (caps);
}
break;
case PROP_IMAGE_CAPTURE_CAPS:{
GstCaps *caps = NULL;
- g_object_get (camera->imagebin_capsfilter, "caps", &caps, NULL);
+ if (G_LIKELY (camera->imagebin_capsfilter)) {
+ g_object_get (camera->imagebin_capsfilter, "caps", &caps, NULL);
+ } else {
+ GST_WARNING ("Missing imagebin capsfilter");
+ }
gst_value_set_caps (value, caps);
gst_caps_unref (caps);
}
break;
case PROP_VIDEO_CAPTURE_CAPS:{
GstCaps *caps = NULL;
- g_object_get (camera->videobin_capsfilter, "caps", &caps, NULL);
+ if (G_LIKELY (camera->videobin_capsfilter)) {
+ g_object_get (camera->videobin_capsfilter, "caps", &caps, NULL);
+ } else {
+ GST_WARNING ("Missing imagebin capsfilter");
+ }
gst_value_set_caps (value, caps);
gst_caps_unref (caps);
}
break;
case PROP_VIEWFINDER_CAPS:{
GstCaps *caps = NULL;
- g_object_get (camera->viewfinderbin_capsfilter, "caps", &caps, NULL);
+ if (G_LIKELY (camera->viewfinderbin_capsfilter)) {
+ g_object_get (camera->viewfinderbin_capsfilter, "caps", &caps, NULL);
+ } else {
+ GST_WARNING ("Missing imagebin capsfilter");
+ }
gst_value_set_caps (value, caps);
gst_caps_unref (caps);
}
diff --git a/gst/camerabin2/gstcamerabin2.h b/gst/camerabin2/gstcamerabin2.h
index e8611a877..b2cf61f6c 100644
--- a/gst/camerabin2/gstcamerabin2.h
+++ b/gst/camerabin2/gstcamerabin2.h
@@ -36,7 +36,9 @@ typedef enum
/* matches GstEncFlags GST_ENC_FLAG_NO_AUDIO_CONVERSION in encodebin */
GST_CAM_FLAG_NO_AUDIO_CONVERSION = (1 << 0),
/* matches GstEncFlags GST_ENC_FLAG_NO_VIDEO_CONVERSION in encodebin */
- GST_CAM_FLAG_NO_VIDEO_CONVERSION = (1 << 1)
+ GST_CAM_FLAG_NO_VIDEO_CONVERSION = (1 << 1),
+ /* maps to 'disable-converters' property in viewfinderbin */
+ GST_CAM_FLAG_NO_VIEWFINDER_CONVERSION = (1 << 2)
} GstCamFlags;
@@ -92,6 +94,8 @@ struct _GstCameraBin2
gboolean video_profile_switch;
gboolean image_profile_switch;
+ gboolean audio_drop_eos;
+
/* properties */
gint mode;
gchar *location;
diff --git a/gst/camerabin2/gstviewfinderbin.c b/gst/camerabin2/gstviewfinderbin.c
index 672e1fe14..746a6d904 100644
--- a/gst/camerabin2/gstviewfinderbin.c
+++ b/gst/camerabin2/gstviewfinderbin.c
@@ -43,15 +43,15 @@
GST_DEBUG_CATEGORY_STATIC (gst_viewfinder_bin_debug);
#define GST_CAT_DEFAULT gst_viewfinder_bin_debug
-/* prototypes */
-
-
enum
{
PROP_0,
PROP_VIDEO_SINK,
+ PROP_DISABLE_CONVERTERS
};
+#define DEFAULT_DISABLE_CONVERTERS FALSE
+
/* pad templates */
static GstStaticPadTemplate sink_template = GST_STATIC_PAD_TEMPLATE ("sink",
@@ -128,6 +128,12 @@ gst_viewfinder_bin_class_init (GstViewfinderBinClass * klass)
g_param_spec_object ("video-sink", "Video Sink",
"the video output element to use (NULL = default)",
GST_TYPE_ELEMENT, G_PARAM_READWRITE | G_PARAM_STATIC_STRINGS));
+
+ g_object_class_install_property (gobject_klass, PROP_DISABLE_CONVERTERS,
+ g_param_spec_boolean ("disable-converters", "Disable conversion elements",
+ "If video converters should be disabled (must be set on NULL)",
+ DEFAULT_DISABLE_CONVERTERS,
+ G_PARAM_READWRITE | G_PARAM_STATIC_STRINGS));
}
static void
@@ -140,6 +146,8 @@ gst_viewfinder_bin_init (GstViewfinderBin * viewfinderbin,
gst_object_unref (templ);
gst_element_add_pad (GST_ELEMENT_CAST (viewfinderbin),
viewfinderbin->ghostpad);
+
+ viewfinderbin->disable_converters = DEFAULT_DISABLE_CONVERTERS;
}
static gboolean
@@ -147,42 +155,15 @@ gst_viewfinder_bin_create_elements (GstViewfinderBin * vfbin)
{
GstElement *csp = NULL;
GstElement *videoscale = NULL;
- GstPad *pad = NULL;
+ GstPad *firstpad = NULL;
const gchar *missing_element_name;
+ gboolean newsink = FALSE;
+ gboolean updated_converters = FALSE;
GST_DEBUG_OBJECT (vfbin, "Creating internal elements");
- if (!vfbin->elements_created) {
- /* create elements */
- csp =
- gst_camerabin_create_and_add_element (GST_BIN (vfbin),
- "ffmpegcolorspace", "vfbin-csp");
- if (!csp) {
- missing_element_name = "ffmpegcolorspace";
- goto missing_element;
- }
-
- videoscale =
- gst_camerabin_create_and_add_element (GST_BIN (vfbin), "videoscale",
- "vfbin-videoscale");
- if (!videoscale) {
- missing_element_name = "videoscale";
- goto missing_element;
- }
-
- /* add ghostpad */
- pad = gst_element_get_static_pad (csp, "sink");
- if (!gst_ghost_pad_set_target (GST_GHOST_PAD (vfbin->ghostpad), pad))
- goto error;
- gst_object_unref (pad);
- pad = NULL;
-
- vfbin->elements_created = TRUE;
- GST_DEBUG_OBJECT (vfbin, "Elements succesfully created and linked");
- }
-
+ /* First check if we need to add/replace the internal sink */
if (vfbin->video_sink) {
- /* check if we need to replace the current one */
if (vfbin->user_video_sink && vfbin->video_sink != vfbin->user_video_sink) {
gst_bin_remove (GST_BIN_CAST (vfbin), vfbin->video_sink);
gst_object_unref (vfbin->video_sink);
@@ -203,20 +184,88 @@ gst_viewfinder_bin_create_elements (GstViewfinderBin * vfbin)
}
gst_bin_add (GST_BIN_CAST (vfbin), gst_object_ref (vfbin->video_sink));
+ newsink = TRUE;
+ }
+
+ /* check if we want add/remove the conversion elements */
+ if (vfbin->elements_created && vfbin->disable_converters) {
+ /* remove the elements, user doesn't want them */
+
+ gst_ghost_pad_set_target (GST_GHOST_PAD (vfbin->ghostpad), NULL);
+ csp = gst_bin_get_by_name (GST_BIN (vfbin), "vfbin-csp");
+ videoscale = gst_bin_get_by_name (GST_BIN (vfbin), "vfbin-videoscale");
+
+ gst_bin_remove (GST_BIN (vfbin), csp);
+ gst_bin_remove (GST_BIN (vfbin), videoscale);
+
+ gst_object_unref (csp);
+ gst_object_unref (videoscale);
- if (!videoscale)
+ updated_converters = TRUE;
+ } else if (!vfbin->elements_created && !vfbin->disable_converters) {
+ gst_ghost_pad_set_target (GST_GHOST_PAD (vfbin->ghostpad), NULL);
+
+ /* add the elements, user wants them */
+ csp =
+ gst_camerabin_create_and_add_element (GST_BIN (vfbin),
+ "ffmpegcolorspace", "vfbin-csp");
+ if (!csp) {
+ missing_element_name = "ffmpegcolorspace";
+ goto missing_element;
+ }
+
+ videoscale =
+ gst_camerabin_create_and_add_element (GST_BIN (vfbin), "videoscale",
+ "vfbin-videoscale");
+ if (!videoscale) {
+ missing_element_name = "videoscale";
+ goto missing_element;
+ }
+
+ vfbin->elements_created = TRUE;
+ GST_DEBUG_OBJECT (vfbin, "Elements succesfully created and linked");
+
+ updated_converters = TRUE;
+ }
+ /* otherwise, just leave it as is */
+
+ /* if sink was replaced -> link it to the internal converters */
+ if (newsink && !vfbin->disable_converters) {
+ gboolean unref = FALSE;
+ if (!videoscale) {
videoscale = gst_bin_get_by_name (GST_BIN_CAST (vfbin),
- "vfbin-videoscale");
+ "vfbin-videscale");
+ unref = TRUE;
+ }
if (!gst_element_link_pads (videoscale, "src", vfbin->video_sink, "sink")) {
GST_ELEMENT_ERROR (vfbin, CORE, NEGOTIATION, (NULL),
("linking videoscale and viewfindersink failed"));
}
- /* prevent it from being removed from the bin at this point */
+ if (unref)
+ gst_object_unref (videoscale);
videoscale = NULL;
}
+ /* Check if we need a new ghostpad target */
+ if (updated_converters || (newsink && vfbin->disable_converters)) {
+ if (vfbin->disable_converters) {
+ firstpad = gst_element_get_static_pad (vfbin->video_sink, "sink");
+ } else {
+ /* csp should always exist at this point */
+ firstpad = gst_element_get_static_pad (csp, "sink");
+ }
+ }
+
+ /* need to change the ghostpad target if firstpad is set */
+ if (firstpad) {
+ if (!gst_ghost_pad_set_target (GST_GHOST_PAD (vfbin->ghostpad), firstpad))
+ goto error;
+ gst_object_unref (firstpad);
+ firstpad = NULL;
+ }
+
return TRUE;
missing_element:
@@ -230,8 +279,8 @@ missing_element:
error:
GST_WARNING_OBJECT (vfbin, "Creating internal elements failed");
- if (pad)
- gst_object_unref (pad);
+ if (firstpad)
+ gst_object_unref (firstpad);
return FALSE;
}
@@ -288,6 +337,9 @@ gst_viewfinder_bin_set_property (GObject * object, guint prop_id,
case PROP_VIDEO_SINK:
gst_viewfinder_bin_set_video_sink (vfbin, g_value_get_object (value));
break;
+ case PROP_DISABLE_CONVERTERS:
+ vfbin->disable_converters = g_value_get_boolean (value);
+ break;
default:
G_OBJECT_WARN_INVALID_PROPERTY_ID (object, prop_id, pspec);
break;
@@ -304,6 +356,9 @@ gst_viewfinder_bin_get_property (GObject * object, guint prop_id,
case PROP_VIDEO_SINK:
g_value_set_object (value, vfbin->video_sink);
break;
+ case PROP_DISABLE_CONVERTERS:
+ g_value_set_boolean (value, vfbin->disable_converters);
+ break;
default:
G_OBJECT_WARN_INVALID_PROPERTY_ID (object, prop_id, pspec);
break;
diff --git a/gst/camerabin2/gstviewfinderbin.h b/gst/camerabin2/gstviewfinderbin.h
index 636921957..33b294444 100644
--- a/gst/camerabin2/gstviewfinderbin.h
+++ b/gst/camerabin2/gstviewfinderbin.h
@@ -43,6 +43,8 @@ struct _GstViewfinderBin
GstElement *user_video_sink;
gboolean elements_created;
+
+ gboolean disable_converters;
};
struct _GstViewfinderBinClass
diff --git a/gst/dvdspu/gstspu-vobsub.c b/gst/dvdspu/gstspu-vobsub.c
index 1757feb70..0a2380c9e 100644
--- a/gst/dvdspu/gstspu-vobsub.c
+++ b/gst/dvdspu/gstspu-vobsub.c
@@ -187,10 +187,10 @@ gst_dvd_spu_exec_cmd_blk (GstDVDSpu * dvdspu, guint8 * data, guint8 * end)
if (G_UNLIKELY (data + 7 >= end))
return; /* Invalid SET_DAREA cmd at the end of the blk */
- r->top = ((data[4] & 0x3f) << 4) | ((data[5] & 0xe0) >> 4);
- r->left = ((data[1] & 0x3f) << 4) | ((data[2] & 0xf0) >> 4);
- r->right = ((data[2] & 0x03) << 8) | data[3];
- r->bottom = ((data[5] & 0x03) << 8) | data[6];
+ r->top = ((data[4] & 0xff) << 4) | ((data[5] & 0xf0) >> 4);
+ r->left = ((data[1] & 0xff) << 4) | ((data[2] & 0xf0) >> 4);
+ r->right = ((data[2] & 0x0f) << 8) | data[3];
+ r->bottom = ((data[5] & 0x0f) << 8) | data[6];
GST_DEBUG_OBJECT (dvdspu,
" Set Display Area top %u left %u bottom %u right %u", r->top,
diff --git a/gst/hls/gsthlsdemux.c b/gst/hls/gsthlsdemux.c
index 773d24986..1e984b9dc 100644
--- a/gst/hls/gsthlsdemux.c
+++ b/gst/hls/gsthlsdemux.c
@@ -240,10 +240,9 @@ gst_hls_demux_init (GstHLSDemux * demux, GstHLSDemuxClass * klass)
demux->fetcher_lock = g_mutex_new ();
demux->queue = g_queue_new ();
g_static_rec_mutex_init (&demux->task_lock);
+ /* FIXME: This really should be a pad task instead */
demux->task = gst_task_create ((GstTaskFunction) gst_hls_demux_loop, demux);
gst_task_set_lock (demux->task, &demux->task_lock);
-
- demux->position = 0;
}
static void
@@ -314,11 +313,95 @@ gst_hls_demux_change_state (GstElement * element, GstStateChange transition)
static gboolean
gst_hls_demux_src_event (GstPad * pad, GstEvent * event)
{
+ GstHLSDemux *demux;
+
+ demux = GST_HLS_DEMUX (gst_pad_get_element_private (pad));
+
switch (event->type) {
- /* FIXME: ignore seek event for the moment */
case GST_EVENT_SEEK:
- gst_event_unref (event);
- return FALSE;
+ {
+ gdouble rate;
+ GstFormat format;
+ GstSeekFlags flags;
+ GstSeekType start_type, stop_type;
+ gint64 start, stop;
+ GList *walk;
+ gint current_pos;
+ gint current_sequence;
+ gint target_second;
+ GstM3U8MediaFile *file;
+
+ GST_INFO_OBJECT (demux, "Received GST_EVENT_SEEK");
+
+ if (gst_m3u8_client_is_live (demux->client)) {
+ GST_WARNING_OBJECT (demux, "Received seek event for live stream");
+ return FALSE;
+ }
+
+ gst_event_parse_seek (event, &rate, &format, &flags, &start_type, &start,
+ &stop_type, &stop);
+
+ if (format != GST_FORMAT_TIME)
+ return FALSE;
+
+ GST_DEBUG_OBJECT (demux, "seek event, rate: %f start: %" GST_TIME_FORMAT
+ " stop: %" GST_TIME_FORMAT, rate, GST_TIME_ARGS (start),
+ GST_TIME_ARGS (stop));
+
+ file = GST_M3U8_MEDIA_FILE (demux->client->current->files->data);
+ current_sequence = file->sequence;
+ current_pos = 0;
+ target_second = start / GST_SECOND;
+ GST_DEBUG_OBJECT (demux, "Target seek to %d", target_second);
+ for (walk = demux->client->current->files; walk; walk = walk->next) {
+ file = walk->data;
+
+ current_sequence = file->sequence;
+ if (current_pos <= target_second
+ && target_second < current_pos + file->duration) {
+ break;
+ }
+ current_pos += file->duration;
+ }
+
+ if (walk == NULL) {
+ GST_WARNING_OBJECT (demux, "Could not find seeked fragment");
+ return FALSE;
+ }
+
+ if (flags & GST_SEEK_FLAG_FLUSH) {
+ GST_DEBUG_OBJECT (demux, "sending flush start");
+ gst_pad_push_event (demux->srcpad, gst_event_new_flush_start ());
+ }
+
+ gst_hls_demux_stop_fetcher (demux, TRUE);
+ gst_task_pause (demux->task);
+ g_cond_signal (demux->thread_cond);
+
+ /* wait for streaming to finish */
+ g_static_rec_mutex_lock (&demux->task_lock);
+
+ demux->need_cache = TRUE;
+ while (!g_queue_is_empty (demux->queue)) {
+ GstBuffer *buf = g_queue_pop_head (demux->queue);
+ gst_buffer_unref (buf);
+ }
+
+ GST_DEBUG_OBJECT (demux, "seeking to sequence %d", current_sequence);
+ demux->client->sequence = current_sequence;
+ demux->position = start;
+ demux->need_segment = TRUE;
+
+ if (flags & GST_SEEK_FLAG_FLUSH) {
+ GST_DEBUG_OBJECT (demux, "sending flush stop");
+ gst_pad_push_event (demux->srcpad, gst_event_new_flush_stop ());
+ }
+
+ gst_task_start (demux->task);
+ g_static_rec_mutex_unlock (&demux->task_lock);
+
+ return TRUE;
+ }
default:
break;
}
@@ -405,7 +488,7 @@ gst_hls_demux_src_query (GstPad * pad, GstQuery * query)
switch (query->type) {
case GST_QUERY_DURATION:{
- GstClockTime duration;
+ GstClockTime duration = -1;
GstFormat fmt;
gst_query_parse_duration (query, &fmt, NULL);
@@ -416,6 +499,8 @@ gst_hls_demux_src_query (GstPad * pad, GstQuery * query)
ret = TRUE;
}
}
+ GST_INFO_OBJECT (hlsdemux, "GST_QUERY_DURATION returns %s with duration %"
+ GST_TIME_FORMAT, ret ? "TRUE" : "FALSE", GST_TIME_ARGS (duration));
break;
}
case GST_QUERY_URI:
@@ -428,18 +513,24 @@ gst_hls_demux_src_query (GstPad * pad, GstQuery * query)
break;
case GST_QUERY_SEEKING:{
GstFormat fmt;
- gint stop = -1;
+ gint64 stop = -1;
gst_query_parse_seeking (query, &fmt, NULL, NULL, NULL);
+ GST_INFO_OBJECT (hlsdemux, "Received GST_QUERY_SEEKING with format %d",
+ fmt);
if (fmt == GST_FORMAT_TIME) {
GstClockTime duration;
duration = gst_m3u8_client_get_duration (hlsdemux->client);
if (GST_CLOCK_TIME_IS_VALID (duration) && duration > 0)
stop = duration;
+
+ gst_query_set_seeking (query, fmt,
+ !gst_m3u8_client_is_live (hlsdemux->client), 0, stop);
+ ret = TRUE;
+ GST_INFO_OBJECT (hlsdemux, "GST_QUERY_SEEKING returning with stop : %"
+ GST_TIME_FORMAT, GST_TIME_ARGS (stop));
}
- gst_query_set_seeking (query, fmt, FALSE, 0, stop);
- ret = TRUE;
break;
}
default:
@@ -570,8 +661,8 @@ switch_pads (GstHLSDemux * demux, GstCaps * newcaps)
GST_DEBUG_FUNCPTR (gst_hls_demux_src_query));
gst_pad_set_element_private (demux->srcpad, demux);
gst_pad_set_active (demux->srcpad, TRUE);
- gst_element_add_pad (GST_ELEMENT (demux), demux->srcpad);
gst_pad_set_caps (demux->srcpad, newcaps);
+ gst_element_add_pad (GST_ELEMENT (demux), demux->srcpad);
gst_element_no_more_pads (GST_ELEMENT (demux));
@@ -608,23 +699,26 @@ gst_hls_demux_loop (GstHLSDemux * demux)
if (demux->end_of_playlist)
goto end_of_playlist;
- GST_TASK_WAIT (demux->task);
- /* If the queue is still empty check again if it's the end of the
- * playlist in case we reached it after beeing woken up */
- if (g_queue_is_empty (demux->queue) && demux->end_of_playlist)
- goto end_of_playlist;
+ goto empty_queue;
}
buf = g_queue_pop_head (demux->queue);
/* Figure out if we need to create/switch pads */
if (G_UNLIKELY (!demux->srcpad
- || GST_BUFFER_CAPS (buf) != GST_PAD_CAPS (demux->srcpad))) {
+ || GST_BUFFER_CAPS (buf) != GST_PAD_CAPS (demux->srcpad)
+ || demux->need_segment)) {
switch_pads (demux, GST_BUFFER_CAPS (buf));
+ demux->need_segment = TRUE;
+ }
+ if (demux->need_segment) {
/* And send a newsegment */
+ GST_DEBUG_OBJECT (demux, "Sending new-segment. Segment start:%"
+ GST_TIME_FORMAT, GST_TIME_ARGS (demux->position));
gst_pad_push_event (demux->srcpad,
- gst_event_new_new_segment (0, 1.0, GST_FORMAT_TIME, demux->position,
+ gst_event_new_new_segment (FALSE, 1.0, GST_FORMAT_TIME, demux->position,
GST_CLOCK_TIME_NONE, demux->position));
+ demux->need_segment = FALSE;
}
if (GST_CLOCK_TIME_IS_VALID (GST_BUFFER_DURATION (buf)))
@@ -655,9 +749,16 @@ cache_error:
error:
{
/* FIXME: handle error */
+ GST_DEBUG_OBJECT (demux, "error, stopping task");
gst_hls_demux_stop (demux);
return;
}
+
+empty_queue:
+ {
+ gst_task_pause (demux->task);
+ return;
+ }
}
static GstBusSyncReply
@@ -735,6 +836,9 @@ gst_hls_demux_reset (GstHLSDemux * demux, gboolean dispose)
gst_buffer_unref (buf);
}
g_queue_clear (demux->queue);
+
+ demux->position = 0;
+ demux->need_segment = TRUE;
}
static gboolean
@@ -834,7 +938,7 @@ gst_hls_demux_cache_fragments (GstHLSDemux * demux)
/* If this playlist is a variant playlist, select the first one
* and update it */
if (gst_m3u8_client_has_variant_playlist (demux->client)) {
- GstM3U8 *child = demux->client->main->lists->data;
+ GstM3U8 *child = demux->client->main->current_variant->data;
gst_m3u8_client_set_current (demux->client, child);
if (!gst_hls_demux_update_playlist (demux, FALSE)) {
GST_ERROR_OBJECT (demux, "Could not fetch the child playlist %s",
@@ -854,7 +958,13 @@ gst_hls_demux_cache_fragments (GstHLSDemux * demux)
}
/* Cache the first fragments */
- for (i = 0; i < demux->fragments_cache - 1; i++) {
+ for (i = 0; i < demux->fragments_cache; i++) {
+ gst_element_post_message (GST_ELEMENT (demux),
+ gst_message_new_buffering (GST_OBJECT (demux),
+ 100 * i / demux->fragments_cache));
+ g_get_current_time (&demux->next_update);
+ g_time_val_add (&demux->next_update,
+ demux->client->current->targetduration * 1000000);
if (!gst_hls_demux_get_next_fragment (demux, FALSE)) {
if (!demux->cancelled)
GST_ERROR_OBJECT (demux, "Error caching the first fragments");
@@ -863,7 +973,10 @@ gst_hls_demux_cache_fragments (GstHLSDemux * demux)
/* make sure we stop caching fragments if something cancelled it */
if (demux->cancelled)
return FALSE;
+ gst_hls_demux_switch_playlist (demux);
}
+ gst_element_post_message (GST_ELEMENT (demux),
+ gst_message_new_buffering (GST_OBJECT (demux), 100));
g_get_current_time (&demux->next_update);
@@ -968,17 +1081,17 @@ gst_hls_demux_change_playlist (GstHLSDemux * demux, gboolean is_fast)
GstStructure *s;
if (is_fast)
- list = g_list_next (demux->client->main->lists);
+ list = g_list_next (demux->client->main->current_variant);
else
- list = g_list_previous (demux->client->main->lists);
+ list = g_list_previous (demux->client->main->current_variant);
/* Don't do anything else if the playlist is the same */
if (!list || list->data == demux->client->current)
return TRUE;
- demux->client->main->lists = list;
+ demux->client->main->current_variant = list;
- gst_m3u8_client_set_current (demux->client, demux->client->main->lists->data);
+ gst_m3u8_client_set_current (demux->client, list->data);
gst_hls_demux_update_playlist (demux, TRUE);
GST_INFO_OBJECT (demux, "Client is %s, switching to bitrate %d",
is_fast ? "fast" : "slow", demux->client->current->bandwidth);
@@ -1065,13 +1178,14 @@ gst_hls_demux_get_next_fragment (GstHLSDemux * demux, gboolean retry)
guint avail;
const gchar *next_fragment_uri;
GstClockTime duration;
+ GstClockTime timestamp;
gboolean discont;
if (!gst_m3u8_client_get_next_fragment (demux->client, &discont,
- &next_fragment_uri, &duration)) {
+ &next_fragment_uri, &duration, &timestamp)) {
GST_INFO_OBJECT (demux, "This playlist doesn't contain more fragments");
demux->end_of_playlist = TRUE;
- GST_TASK_SIGNAL (demux->task);
+ gst_task_start (demux->task);
return FALSE;
}
@@ -1083,6 +1197,7 @@ gst_hls_demux_get_next_fragment (GstHLSDemux * demux, gboolean retry)
avail = gst_adapter_available (demux->download);
buf = gst_adapter_take_buffer (demux->download, avail);
GST_BUFFER_DURATION (buf) = duration;
+ GST_BUFFER_TIMESTAMP (buf) = timestamp;
/* We actually need to do this every time we switch bitrate */
if (G_UNLIKELY (demux->do_typefind)) {
@@ -1105,7 +1220,7 @@ gst_hls_demux_get_next_fragment (GstHLSDemux * demux, gboolean retry)
}
g_queue_push_tail (demux->queue, buf);
- GST_TASK_SIGNAL (demux->task);
+ gst_task_start (demux->task);
gst_adapter_clear (demux->download);
return TRUE;
}
diff --git a/gst/hls/gsthlsdemux.h b/gst/hls/gsthlsdemux.h
index 67574675d..bac8ef317 100644
--- a/gst/hls/gsthlsdemux.h
+++ b/gst/hls/gsthlsdemux.h
@@ -89,6 +89,7 @@ struct _GstHLSDemux
/* Position in the stream */
GstClockTime position;
+ gboolean need_segment;
};
struct _GstHLSDemuxClass
diff --git a/gst/hls/m3u8.c b/gst/hls/m3u8.c
index 20252f01d..26548101f 100644
--- a/gst/hls/m3u8.c
+++ b/gst/hls/m3u8.c
@@ -206,6 +206,7 @@ gst_m3u8_update (GstM3U8 * self, gchar * data, gboolean * updated)
if (!g_str_has_prefix (data, "#EXTM3U")) {
GST_WARNING ("Data doesn't start with #EXTM3U");
+ *updated = FALSE;
g_free (data);
return FALSE;
}
@@ -350,11 +351,22 @@ gst_m3u8_update (GstM3U8 * self, gchar * data, gboolean * updated)
}
/* redorder playlists by bitrate */
- if (self->lists)
+ if (self->lists) {
+ gchar *top_variant_uri = NULL;
+
+ if (!self->current_variant)
+ top_variant_uri = GST_M3U8 (self->lists->data)->uri;
+ else
+ top_variant_uri = GST_M3U8 (self->current_variant->data)->uri;
+
self->lists =
g_list_sort (self->lists,
(GCompareFunc) gst_m3u8_compare_playlist_by_bitrate);
+ self->current_variant = g_list_find_custom (self->lists, top_variant_uri,
+ (GCompareFunc) _m3u8_compare_uri);
+ }
+
return TRUE;
}
@@ -416,7 +428,7 @@ gst_m3u8_client_update (GstM3U8Client * self, gchar * data)
/* select the first playlist, for now */
if (!self->current) {
if (self->main->lists) {
- self->current = g_list_first (self->main->lists)->data;
+ self->current = self->main->current_variant->data;
} else {
self->current = self->main;
}
@@ -442,9 +454,11 @@ _find_next (GstM3U8MediaFile * file, GstM3U8Client * client)
gboolean
gst_m3u8_client_get_next_fragment (GstM3U8Client * client,
- gboolean * discontinuity, const gchar ** uri, GstClockTime * duration)
+ gboolean * discontinuity, const gchar ** uri, GstClockTime * duration,
+ GstClockTime * timestamp)
{
GList *l;
+ GList *walk;
GstM3U8MediaFile *file;
g_return_val_if_fail (client != NULL, FALSE);
@@ -464,6 +478,15 @@ gst_m3u8_client_get_next_fragment (GstM3U8Client * client,
*uri = file->uri;
*duration = file->duration * GST_SECOND;
+
+ *timestamp = 0;
+ for (walk = client->current->files; walk; walk = walk->next) {
+ if (walk == l)
+ break;
+ *timestamp += GST_M3U8_MEDIA_FILE (walk->data)->duration;
+ }
+ *timestamp *= GST_SECOND;
+
return TRUE;
}
diff --git a/gst/hls/m3u8.h b/gst/hls/m3u8.h
index 7f37cdd73..aefe8667d 100644
--- a/gst/hls/m3u8.h
+++ b/gst/hls/m3u8.h
@@ -29,6 +29,7 @@ G_BEGIN_DECLS typedef struct _GstM3U8 GstM3U8;
typedef struct _GstM3U8MediaFile GstM3U8MediaFile;
typedef struct _GstM3U8Client GstM3U8Client;
+#define GST_M3U8(m) ((GstM3U8*)m)
#define GST_M3U8_MEDIA_FILE(f) ((GstM3U8MediaFile*)f)
struct _GstM3U8
@@ -50,6 +51,7 @@ struct _GstM3U8
/*< private > */
gchar *last_data;
GList *lists; /* list of GstM3U8 from the main playlist */
+ GList *current_variant; /* Current variant playlist used */
GstM3U8 *parent; /* main playlist (if any) */
guint mediasequence; /* EXT-X-MEDIA-SEQUENCE & increased with new media file */
};
@@ -76,7 +78,8 @@ void gst_m3u8_client_free (GstM3U8Client * client);
gboolean gst_m3u8_client_update (GstM3U8Client * client, gchar * data);
void gst_m3u8_client_set_current (GstM3U8Client * client, GstM3U8 * m3u8);
gboolean gst_m3u8_client_get_next_fragment (GstM3U8Client * client,
- gboolean * discontinuity, const gchar ** uri, GstClockTime * duration);
+ gboolean * discontinuity, const gchar ** uri, GstClockTime * duration,
+ GstClockTime * timestamp);
GstClockTime gst_m3u8_client_get_duration (GstM3U8Client * client);
const gchar *gst_m3u8_client_get_uri(GstM3U8Client * client);
gboolean gst_m3u8_client_has_variant_playlist(GstM3U8Client * client);
diff --git a/gst/mpegtsdemux/mpegtsbase.c b/gst/mpegtsdemux/mpegtsbase.c
index 2a81f7593..1749ba2cc 100644
--- a/gst/mpegtsdemux/mpegtsbase.c
+++ b/gst/mpegtsdemux/mpegtsbase.c
@@ -215,6 +215,8 @@ mpegts_base_reset (MpegTSBase * base)
base->mode = BASE_MODE_STREAMING;
base->seen_pat = FALSE;
base->first_pat_offset = -1;
+ base->in_gap = 0;
+ base->first_buf_ts = GST_CLOCK_TIME_NONE;
if (klass->reset)
klass->reset (base);
@@ -1180,14 +1182,22 @@ mpegts_base_sink_event (GstPad * pad, GstEvent * event)
gst_segment_set_newsegment_full (&base->segment, update, rate,
applied_rate, format, start, stop, position);
gst_event_unref (event);
+ base->in_gap = GST_CLOCK_TIME_NONE;
+ base->first_buf_ts = GST_CLOCK_TIME_NONE;
}
break;
case GST_EVENT_EOS:
res = gst_mpegts_base_handle_eos (base);
break;
case GST_EVENT_FLUSH_START:
- gst_segment_init (&base->segment, GST_FORMAT_UNDEFINED);
mpegts_packetizer_flush (base->packetizer);
+ res = GST_MPEGTS_BASE_GET_CLASS (base)->push_event (base, event);
+ gst_event_unref (event);
+ break;
+ case GST_EVENT_FLUSH_STOP:
+ gst_segment_init (&base->segment, GST_FORMAT_UNDEFINED);
+ base->seen_pat = FALSE;
+ base->first_pat_offset = -1;
/* Passthrough */
default:
res = GST_MPEGTS_BASE_GET_CLASS (base)->push_event (base, event);
@@ -1226,6 +1236,13 @@ mpegts_base_chain (GstPad * pad, GstBuffer * buf)
base = GST_MPEGTS_BASE (gst_object_get_parent (GST_OBJECT (pad)));
packetizer = base->packetizer;
+ if (G_UNLIKELY (!GST_CLOCK_TIME_IS_VALID (base->first_buf_ts)) &&
+ GST_BUFFER_TIMESTAMP_IS_VALID (buf)) {
+ base->first_buf_ts = GST_BUFFER_TIMESTAMP (buf);
+ GST_DEBUG_OBJECT (base, "first buffer timestamp %" GST_TIME_FORMAT,
+ GST_TIME_ARGS (base->first_buf_ts));
+ }
+
mpegts_packetizer_push (base->packetizer, buf);
while (((pret =
mpegts_packetizer_next_packet (base->packetizer,
@@ -1399,6 +1416,13 @@ mpegts_base_handle_seek_event (MpegTSBase * base, GstPad * pad,
if (format != GST_FORMAT_TIME)
return FALSE;
+ /* First try if upstream supports seeking in TIME format */
+ if (gst_pad_push_event (base->sinkpad, gst_event_ref (event))) {
+ GST_DEBUG ("upstream handled SEEK event");
+ gst_event_unref (event);
+ return TRUE;
+ }
+
GST_DEBUG ("seek event, rate: %f start: %" GST_TIME_FORMAT
" stop: %" GST_TIME_FORMAT, rate, GST_TIME_ARGS (start),
GST_TIME_ARGS (stop));
diff --git a/gst/mpegtsdemux/mpegtsbase.h b/gst/mpegtsdemux/mpegtsbase.h
index 369078d47..1513898ec 100644
--- a/gst/mpegtsdemux/mpegtsbase.h
+++ b/gst/mpegtsdemux/mpegtsbase.h
@@ -130,6 +130,10 @@ struct _MpegTSBase {
/* Offset from the origin to the first PAT (pullmode) */
guint64 first_pat_offset;
+ /* interpolation gap between the upstream timestamp and the pts */
+ GstClockTime in_gap;
+ GstClockTime first_buf_ts;
+
/* Upstream segment */
GstSegment segment;
};
diff --git a/gst/mpegtsdemux/tsdemux.c b/gst/mpegtsdemux/tsdemux.c
index e859ea9c6..f7dc5cc6b 100644
--- a/gst/mpegtsdemux/tsdemux.c
+++ b/gst/mpegtsdemux/tsdemux.c
@@ -387,16 +387,19 @@ gst_ts_demux_srcpad_query (GstPad * pad, GstQuery * query)
gboolean res = TRUE;
GstFormat format;
GstTSDemux *demux;
+ MpegTSBase *base;
demux = GST_TS_DEMUX (gst_pad_get_parent (pad));
+ base = GST_MPEGTS_BASE (demux);
switch (GST_QUERY_TYPE (query)) {
case GST_QUERY_DURATION:
GST_DEBUG ("query duration");
gst_query_parse_duration (query, &format, NULL);
if (format == GST_FORMAT_TIME) {
- gst_query_set_duration (query, GST_FORMAT_TIME,
- demux->segment.duration);
+ if (!gst_pad_peer_query (base->sinkpad, query))
+ gst_query_set_duration (query, GST_FORMAT_TIME,
+ demux->segment.duration);
} else {
GST_DEBUG_OBJECT (demux, "only query duration on TIME is supported");
res = FALSE;
@@ -406,9 +409,17 @@ gst_ts_demux_srcpad_query (GstPad * pad, GstQuery * query)
GST_DEBUG ("query seeking");
gst_query_parse_seeking (query, &format, NULL, NULL, NULL);
if (format == GST_FORMAT_TIME) {
- gst_query_set_seeking (query, GST_FORMAT_TIME,
- demux->parent.mode != BASE_MODE_PUSHING, 0,
- demux->segment.duration);
+ gboolean seekable = FALSE;
+
+ if (gst_pad_peer_query (base->sinkpad, query))
+ gst_query_parse_seeking (query, NULL, &seekable, NULL, NULL);
+
+ /* If upstream is not seekable in TIME format we use
+ * our own values here */
+ if (!seekable)
+ gst_query_set_seeking (query, GST_FORMAT_TIME,
+ demux->parent.mode != BASE_MODE_PUSHING, 0,
+ demux->segment.duration);
} else {
GST_DEBUG_OBJECT (demux, "only TIME is supported for query seeking");
res = FALSE;
@@ -871,9 +882,10 @@ gst_ts_demux_srcpad_event (GstPad * pad, GstEvent * event)
switch (GST_EVENT_TYPE (event)) {
case GST_EVENT_SEEK:
res = mpegts_base_handle_seek_event ((MpegTSBase *) demux, pad, event);
- if (!res) {
+ if (res)
+ demux->need_newsegment = TRUE;
+ else
GST_WARNING ("seeking failed");
- }
gst_event_unref (event);
break;
default:
@@ -1217,13 +1229,24 @@ gst_ts_demux_stream_added (MpegTSBase * base, MpegTSBaseStream * bstream,
static void
gst_ts_demux_stream_removed (MpegTSBase * base, MpegTSBaseStream * bstream)
{
+ GstTSDemux *demux = GST_TS_DEMUX (base);
TSDemuxStream *stream = (TSDemuxStream *) bstream;
if (stream->pad) {
if (gst_pad_is_active (stream->pad)) {
- GST_DEBUG_OBJECT (stream->pad, "Flushing out pending data");
+ gboolean need_newsegment = demux->need_newsegment;
+
+ /* We must not send the newsegment when flushing the pending data
+ on the removed stream. We should only push it when the newly added
+ stream finishes parsing its PTS */
+ demux->need_newsegment = FALSE;
+
/* Flush out all data */
+ GST_DEBUG_OBJECT (stream->pad, "Flushing out pending data");
gst_ts_demux_push_pending_data ((GstTSDemux *) base, stream);
+
+ demux->need_newsegment = need_newsegment;
+
GST_DEBUG_OBJECT (stream->pad, "Pushing out EOS");
gst_pad_push_event (stream->pad, gst_event_new_eos ());
GST_DEBUG_OBJECT (stream->pad, "Deactivating and removing pad");
@@ -1570,6 +1593,7 @@ find_timestamps (MpegTSBase * base, guint64 initoff, guint64 * offset)
gst_structure_free (base->pat);
base->pat = NULL;
mpegts_base_remove_program (base, demux->current_program_number);
+ demux->program = NULL;
/* Find end position */
if (G_UNLIKELY (!gst_pad_query_peer_duration (base->sinkpad, &format,
@@ -1628,6 +1652,7 @@ beach:
base->pat = NULL;
}
mpegts_base_remove_program (base, demux->current_program_number);
+ demux->program = NULL;
return ret;
}
@@ -1750,14 +1775,16 @@ beach:
pcroffset->pcr = pcrs[nbpcr - 1];
pcroffset->offset = pcroffs[nbpcr - 1];
}
- GST_DEBUG ("pcrdiff:%" GST_TIME_FORMAT " offsetdiff %" G_GUINT64_FORMAT,
- GST_TIME_ARGS (PCRTIME_TO_GSTTIME (pcrs[nbpcr - 1] - pcrs[0])),
- pcroffs[nbpcr - 1] - pcroffs[0]);
- GST_DEBUG ("Estimated bitrate %" G_GUINT64_FORMAT,
- gst_util_uint64_scale (GST_SECOND, pcroffs[nbpcr - 1] - pcroffs[0],
- PCRTIME_TO_GSTTIME (pcrs[nbpcr - 1] - pcrs[0])));
- GST_DEBUG ("Average PCR interval %" G_GUINT64_FORMAT,
- (pcroffs[nbpcr - 1] - pcroffs[0]) / nbpcr);
+ if (nbpcr > 1) {
+ GST_DEBUG ("pcrdiff:%" GST_TIME_FORMAT " offsetdiff %" G_GUINT64_FORMAT,
+ GST_TIME_ARGS (PCRTIME_TO_GSTTIME (pcrs[nbpcr - 1] - pcrs[0])),
+ pcroffs[nbpcr - 1] - pcroffs[0]);
+ GST_DEBUG ("Estimated bitrate %" G_GUINT64_FORMAT,
+ gst_util_uint64_scale (GST_SECOND, pcroffs[nbpcr - 1] - pcroffs[0],
+ PCRTIME_TO_GSTTIME (pcrs[nbpcr - 1] - pcrs[0])));
+ GST_DEBUG ("Average PCR interval %" G_GUINT64_FORMAT,
+ (pcroffs[nbpcr - 1] - pcroffs[0]) / nbpcr);
+ }
}
/* Swallow any errors if it happened during the end scanning */
if (!isinitial)
@@ -1897,6 +1924,7 @@ TSPcrOffset_find_offset (gconstpointer a, gconstpointer b, gpointer user_data)
static GstFlowReturn
gst_ts_demux_parse_pes_header (GstTSDemux * demux, TSDemuxStream * stream)
{
+ MpegTSBase *base = (MpegTSBase *) demux;
PESHeader header;
GstFlowReturn res = GST_FLOW_OK;
gint offset = 0;
@@ -1945,7 +1973,38 @@ gst_ts_demux_parse_pes_header (GstTSDemux * demux, TSDemuxStream * stream)
#endif
stream->pts = time = MPEGTIME_TO_GSTTIME (header.PTS);
- GST_BUFFER_TIMESTAMP (stream->pendingbuffers[0]) = time;
+ GST_DEBUG_OBJECT (base, "stream PTS %" GST_TIME_FORMAT,
+ GST_TIME_ARGS (stream->pts));
+
+ /* safe default if insufficient upstream info */
+ if (G_UNLIKELY (!GST_CLOCK_TIME_IS_VALID (base->in_gap) &&
+ GST_CLOCK_TIME_IS_VALID (base->first_buf_ts) &&
+ base->mode == BASE_MODE_PUSHING &&
+ base->segment.format == GST_FORMAT_TIME)) {
+ /* Find the earliest current PTS we're going to push */
+ GstClockTime firstpts = GST_CLOCK_TIME_NONE;
+ GList *tmp;
+
+ for (tmp = demux->program->stream_list; tmp; tmp = tmp->next) {
+ TSDemuxStream *pstream = (TSDemuxStream *) tmp->data;
+ if (!GST_CLOCK_TIME_IS_VALID (firstpts) || pstream->pts < firstpts)
+ firstpts = pstream->pts;
+ }
+
+ base->in_gap = base->first_buf_ts - firstpts;
+ GST_DEBUG_OBJECT (base, "upstream segment start %" GST_TIME_FORMAT
+ ", first buffer timestamp: %" GST_TIME_FORMAT
+ ", first PTS: %" GST_TIME_FORMAT
+ ", interpolation gap: %" GST_TIME_FORMAT,
+ GST_TIME_ARGS (base->segment.start),
+ GST_TIME_ARGS (base->first_buf_ts), GST_TIME_ARGS (firstpts),
+ GST_TIME_ARGS (base->in_gap));
+ }
+
+ if (!GST_CLOCK_TIME_IS_VALID (base->in_gap))
+ base->in_gap = 0;
+
+ GST_BUFFER_TIMESTAMP (stream->pendingbuffers[0]) = time + base->in_gap;
}
if (header.DTS != -1)
@@ -2038,12 +2097,12 @@ static void
calculate_and_push_newsegment (GstTSDemux * demux, TSDemuxStream * stream)
{
MpegTSBase *base = (MpegTSBase *) demux;
- GstClockTime firstpts = GST_CLOCK_TIME_NONE;
GstEvent *newsegmentevent;
- GList *tmp;
gint64 start, stop, position;
+ GstClockTime firstpts = GST_CLOCK_TIME_NONE;
+ GList *tmp;
- GST_DEBUG ("Creating new newsegment");
+ GST_DEBUG ("Creating new newsegment for stream %p", stream);
/* Outgoing newsegment values
* start : The first/start PTS
@@ -2055,9 +2114,9 @@ calculate_and_push_newsegment (GstTSDemux * demux, TSDemuxStream * stream)
* PTS to that remote clock).
*/
- /* Find the earliest current PTS we're going to push */
for (tmp = demux->program->stream_list; tmp; tmp = tmp->next) {
TSDemuxStream *pstream = (TSDemuxStream *) tmp->data;
+
if (!GST_CLOCK_TIME_IS_VALID (firstpts) || pstream->pts < firstpts)
firstpts = pstream->pts;
}
@@ -2077,13 +2136,14 @@ calculate_and_push_newsegment (GstTSDemux * demux, TSDemuxStream * stream)
GST_TIME_ARGS (demux->segment.duration),
GST_TIME_ARGS (demux->segment.time));
- if (demux->segment.time == 0 && base->segment.format == GST_FORMAT_TIME)
- demux->segment.time = base->segment.time;
+ GST_DEBUG ("stream pts: %" GST_TIME_FORMAT " first pts: %" GST_TIME_FORMAT,
+ GST_TIME_ARGS (stream->pts), GST_TIME_ARGS (firstpts));
- start = firstpts;
- stop = GST_CLOCK_TIME_NONE;
- position = demux->segment.time ? firstpts - demux->segment.time : 0;
- demux->segment.time = start;
+ start = base->segment.start;
+ stop = base->segment.stop;
+ /* Shift the start depending on our position in the stream */
+ start += firstpts + base->in_gap - base->first_buf_ts;
+ position = start;
} else {
/* pull mode */
GST_DEBUG ("pull-based. Segment start:%" GST_TIME_FORMAT " duration:%"
@@ -2107,7 +2167,7 @@ calculate_and_push_newsegment (GstTSDemux * demux, TSDemuxStream * stream)
GST_TIME_FORMAT " time: %" GST_TIME_FORMAT, GST_TIME_ARGS (start),
GST_TIME_ARGS (stop), GST_TIME_ARGS (position));
newsegmentevent =
- gst_event_new_new_segment (0, 1.0, GST_FORMAT_TIME, start, stop,
+ gst_event_new_new_segment (FALSE, 1.0, GST_FORMAT_TIME, start, stop,
position);
push_event ((MpegTSBase *) demux, newsegmentevent);
diff --git a/gst/mpegtsmux/mpegtsmux.c b/gst/mpegtsmux/mpegtsmux.c
index 606e1d7f3..f59a5f7e3 100644
--- a/gst/mpegtsmux/mpegtsmux.c
+++ b/gst/mpegtsmux/mpegtsmux.c
@@ -687,15 +687,13 @@ mpegtsmux_collected (GstCollectPads * pads, MpegTsMux * mux)
}
if (G_UNLIKELY (prog->pcr_stream == NULL)) {
- if (best) {
- /* Take the first data stream for the PCR */
- GST_DEBUG_OBJECT (COLLECT_DATA_PAD (best),
- "Use stream (pid=%d) from pad as PCR for program (prog_id = %d)",
- MPEG_TS_PAD_DATA (best)->pid, MPEG_TS_PAD_DATA (best)->prog_id);
-
- /* Set the chosen PCR stream */
- tsmux_program_set_pcr_stream (prog, best->stream);
- }
+ /* Take the first data stream for the PCR */
+ GST_DEBUG_OBJECT (COLLECT_DATA_PAD (best),
+ "Use stream (pid=%d) from pad as PCR for program (prog_id = %d)",
+ MPEG_TS_PAD_DATA (best)->pid, MPEG_TS_PAD_DATA (best)->prog_id);
+
+ /* Set the chosen PCR stream */
+ tsmux_program_set_pcr_stream (prog, best->stream);
}
g_return_val_if_fail (buf != NULL, GST_FLOW_ERROR);
diff --git a/gst/removesilence/Makefile.am b/gst/removesilence/Makefile.am
new file mode 100644
index 000000000..c022ac133
--- /dev/null
+++ b/gst/removesilence/Makefile.am
@@ -0,0 +1,12 @@
+
+plugin_LTLIBRARIES = libgstremovesilence.la
+
+libgstremovesilence_la_SOURCES = gstremovesilence.c vad_private.c
+libgstremovesilence_la_CFLAGS = $(GST_PLUGINS_BASE_CFLAGS) $(GST_CFLAGS)
+libgstremovesilence_la_LIBADD = $(GST_PLUGINS_BASE_LIBS) $(GST_BASE_LIBS) $(GST_LIBS)
+libgstremovesilence_la_LDFLAGS = $(GST_PLUGIN_LDFLAGS)
+libgstremovesilence_la_LIBTOOLFLAGS = --tag=disable-static
+
+noinst_HEADERS = \
+ gstremovesilence.h \
+ vad_private.h
diff --git a/gst/removesilence/gstremovesilence.c b/gst/removesilence/gstremovesilence.c
new file mode 100644
index 000000000..edb9af3ab
--- /dev/null
+++ b/gst/removesilence/gstremovesilence.c
@@ -0,0 +1,262 @@
+/* GStreamer
+ * Copyright (C) 2011 Tiago Katcipis <tiagokatcipis@gmail.com>
+ * Copyright (C) 2011 Paulo Pizarro <paulo.pizarro@gmail.com>
+ *
+ * This library is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU Library General Public
+ * License as published by the Free Software Foundation; either
+ * version 2 of the License, or (at your option) any later version.
+ *
+ * This library is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Library General Public License for more details.
+ *
+ * You should have received a copy of the GNU Library General Public
+ * License along with this library; if not, write to the
+ * Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+ * Boston, MA 02111-1307, USA.
+ */
+
+/**
+ * SECTION:element-removesilence
+ *
+ * Removes all silence periods from an audio stream, dropping silence buffers.
+ *
+ * <refsect2>
+ * <title>Example launch line</title>
+ * |[
+ * gst-launch -v -m filesrc location="audiofile" ! decodebin2 ! removesilence remove=true ! wavenc ! filesink location=without_audio.wav
+ * ]|
+ * </refsect2>
+ */
+
+#ifdef HAVE_CONFIG_H
+#include "config.h"
+#endif
+
+#include <gst/gst.h>
+#include <gst/base/gstbasetransform.h>
+#include <gst/controller/gstcontroller.h>
+
+#include "gstremovesilence.h"
+
+
+GST_DEBUG_CATEGORY_STATIC (gst_remove_silence_debug);
+#define GST_CAT_DEFAULT gst_remove_silence_debug
+#define DEFAULT_VAD_HYSTERESIS 480 /* 60 mseg */
+
+/* Filter signals and args */
+enum
+{
+ /* FILL ME */
+ LAST_SIGNAL
+};
+
+enum
+{
+ PROP_0,
+ PROP_REMOVE,
+ PROP_HYSTERESIS
+};
+
+
+static GstStaticPadTemplate sink_template = GST_STATIC_PAD_TEMPLATE ("sink",
+ GST_PAD_SINK,
+ GST_PAD_ALWAYS,
+ GST_STATIC_CAPS
+ ("audio/x-raw-int, "
+ "rate=[1, MAX], channels=1, endianness=BYTE_ORDER, "
+ "width=16, depth=16, signed=true"));
+
+static GstStaticPadTemplate src_template = GST_STATIC_PAD_TEMPLATE ("src",
+ GST_PAD_SRC,
+ GST_PAD_ALWAYS,
+ GST_STATIC_CAPS
+ ("audio/x-raw-int, "
+ "rate=[1, MAX], channels=1, endianness=BYTE_ORDER, "
+ "width=16, depth=16, signed=true"));
+
+
+#define DEBUG_INIT(bla) \
+ GST_DEBUG_CATEGORY_INIT (gst_remove_silence_debug, "removesilence", 0, "removesilence element")
+
+GST_BOILERPLATE_FULL (GstRemoveSilence, gst_remove_silence, GstBaseTransform,
+ GST_TYPE_BASE_TRANSFORM, DEBUG_INIT);
+
+
+static void gst_remove_silence_set_property (GObject * object, guint prop_id,
+ const GValue * value, GParamSpec * pspec);
+static void gst_remove_silence_get_property (GObject * object, guint prop_id,
+ GValue * value, GParamSpec * pspec);
+
+static GstFlowReturn gst_remove_silence_transform_ip (GstBaseTransform * base,
+ GstBuffer * buf);
+static void gst_remove_silence_finalize (GObject * obj);
+static void gst_remove_silence_reset (GstRemoveSilence * filter);
+
+/* GObject vmethod implementations */
+
+static void
+gst_remove_silence_base_init (gpointer gclass)
+{
+ GstElementClass *element_class = GST_ELEMENT_CLASS (gclass);
+
+ gst_element_class_set_details_simple (element_class,
+ "RemoveSilence",
+ "Filter/Effect/Audio",
+ "Removes all the silence periods from the audio stream.",
+ "Tiago Katcipis <tiagokatcipis@gmail.com>\n \
+ Paulo Pizarro <paulo.pizarro@gmail.com>");
+
+ gst_element_class_add_pad_template (element_class,
+ gst_static_pad_template_get (&src_template));
+ gst_element_class_add_pad_template (element_class,
+ gst_static_pad_template_get (&sink_template));
+}
+
+/* initialize the removesilence's class */
+static void
+gst_remove_silence_class_init (GstRemoveSilenceClass * klass)
+{
+ GObjectClass *gobject_class;
+
+ gobject_class = (GObjectClass *) klass;
+ gobject_class->finalize = gst_remove_silence_finalize;
+ gobject_class->set_property = gst_remove_silence_set_property;
+ gobject_class->get_property = gst_remove_silence_get_property;
+
+ g_object_class_install_property (gobject_class, PROP_REMOVE,
+ g_param_spec_boolean ("remove", "Remove",
+ "Set to true to remove silence from the stream, false otherwhise",
+ FALSE, G_PARAM_READWRITE));
+
+ g_object_class_install_property (gobject_class, PROP_HYSTERESIS,
+ g_param_spec_uint64 ("hysteresis",
+ "Hysteresis",
+ "Set the hysteresis (on samples) used on the internal VAD",
+ 1, G_MAXUINT64, DEFAULT_VAD_HYSTERESIS, G_PARAM_READWRITE));
+
+
+ GST_BASE_TRANSFORM_CLASS (klass)->transform_ip =
+ GST_DEBUG_FUNCPTR (gst_remove_silence_transform_ip);
+}
+
+/* initialize the new element
+ * instantiate pads and add them to element
+ * set pad calback functions
+ * initialize instance structure
+ */
+static void
+gst_remove_silence_init (GstRemoveSilence * filter,
+ GstRemoveSilenceClass * gclass)
+{
+ filter->vad = vad_new (DEFAULT_VAD_HYSTERESIS);
+ filter->remove = FALSE;
+
+ if (!filter->vad) {
+ GST_DEBUG ("Error initializing VAD !!");
+ return;
+ }
+
+ gst_remove_silence_reset (filter);
+}
+
+static void
+gst_remove_silence_reset (GstRemoveSilence * filter)
+{
+ GST_DEBUG ("Reseting VAD");
+ if (filter->vad) {
+ vad_reset (filter->vad);
+ }
+ GST_DEBUG ("VAD Reseted");
+}
+
+static void
+gst_remove_silence_finalize (GObject * obj)
+{
+ GstRemoveSilence *filter = GST_REMOVE_SILENCE (obj);
+ GST_DEBUG ("Destroying VAD");
+ vad_destroy (filter->vad);
+ filter->vad = NULL;
+ GST_DEBUG ("VAD Destroyed");
+ G_OBJECT_CLASS (parent_class)->finalize (obj);
+}
+
+static void
+gst_remove_silence_set_property (GObject * object, guint prop_id,
+ const GValue * value, GParamSpec * pspec)
+{
+ GstRemoveSilence *filter = GST_REMOVE_SILENCE (object);
+
+ switch (prop_id) {
+ case PROP_REMOVE:
+ filter->remove = g_value_get_boolean (value);
+ break;
+ case PROP_HYSTERESIS:
+ vad_set_hysteresis (filter->vad, g_value_get_uint64 (value));
+ break;
+ default:
+ G_OBJECT_WARN_INVALID_PROPERTY_ID (object, prop_id, pspec);
+ break;
+ }
+}
+
+static void
+gst_remove_silence_get_property (GObject * object, guint prop_id,
+ GValue * value, GParamSpec * pspec)
+{
+ GstRemoveSilence *filter = GST_REMOVE_SILENCE (object);
+
+ switch (prop_id) {
+ case PROP_REMOVE:
+ g_value_set_boolean (value, filter->remove);
+ break;
+ case PROP_HYSTERESIS:
+ g_value_set_uint64 (value, vad_get_hysteresis (filter->vad));
+ break;
+ default:
+ G_OBJECT_WARN_INVALID_PROPERTY_ID (object, prop_id, pspec);
+ break;
+ }
+}
+
+static GstFlowReturn
+gst_remove_silence_transform_ip (GstBaseTransform * trans, GstBuffer * inbuf)
+{
+ GstRemoveSilence *filter = NULL;
+ int frame_type;
+
+ filter = GST_REMOVE_SILENCE (trans);
+
+ frame_type =
+ vad_update (filter->vad, (gint16 *) GST_BUFFER_DATA (inbuf),
+ GST_BUFFER_SIZE (inbuf) / sizeof (gint16));
+
+ if (frame_type == VAD_SILENCE) {
+
+ GST_DEBUG ("Silence detected");
+
+ if (filter->remove) {
+ GST_DEBUG ("Removing silence");
+ return GST_BASE_TRANSFORM_FLOW_DROPPED;
+ }
+
+ }
+
+ return GST_FLOW_OK;
+}
+
+/*Plugin init functions*/
+static gboolean
+plugin_init (GstPlugin * plugin)
+{
+ return gst_element_register (plugin, "removesilence", GST_RANK_NONE,
+ gst_remove_silence_get_type ());
+}
+
+GST_PLUGIN_DEFINE (GST_VERSION_MAJOR,
+ GST_VERSION_MINOR,
+ "removesilence",
+ "Removes silence from an audio stream",
+ plugin_init, VERSION, "LGPL", GST_PACKAGE_NAME, GST_PACKAGE_ORIGIN);
diff --git a/gst/removesilence/gstremovesilence.h b/gst/removesilence/gstremovesilence.h
new file mode 100644
index 000000000..0592a37ff
--- /dev/null
+++ b/gst/removesilence/gstremovesilence.h
@@ -0,0 +1,56 @@
+/* GStreamer
+ * Copyright (C) 2011 Tiago Katcipis <tiagokatcipis@gmail.com>
+ * Copyright (C) 2011 Paulo Pizarro <paulo.pizarro@gmail.com>
+ *
+ *
+ * This library is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU Library General Public
+ * License as published by the Free Software Foundation; either
+ * version 2 of the License, or (at your option) any later version.
+ *
+ * This library is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Library General Public License for more details.
+ *
+ * You should have received a copy of the GNU Library General Public
+ * License along with this library; if not, write to the
+ * Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+ * Boston, MA 02111-1307, USA.
+ */
+
+#ifndef __GST_REMOVE_SILENCE_H__
+#define __GST_REMOVE_SILENCE_H__
+
+#include <gst/gst.h>
+#include <gst/base/gstbasetransform.h>
+#include "vad_private.h"
+
+G_BEGIN_DECLS
+
+#define GST_TYPE_REMOVE_SILENCE \
+ (gst_remove_silence_get_type())
+#define GST_REMOVE_SILENCE(obj) \
+ (G_TYPE_CHECK_INSTANCE_CAST((obj),GST_TYPE_REMOVE_SILENCE,GstRemoveSilence))
+#define GST_REMOVE_SILENCE_CLASS(klass) \
+ (G_TYPE_CHECK_CLASS_CAST((klass),GST_TYPE_REMOVE_SILENCE,GstRemoveSilenceClass))
+#define GST_IS_REMOVESILENCE(obj) \
+ (G_TYPE_CHECK_INSTANCE_TYPE((obj),GST_TYPE_REMOVE_SILENCE))
+#define GST_IS_REMOVESILENCE_CLASS(klass) \
+ (G_TYPE_CHECK_CLASS_TYPE((klass),GST_TYPE_REMOVE_SILENCE))
+
+typedef struct _GstRemoveSilence {
+ GstBaseTransform parent;
+ VADFilter* vad;
+ gboolean remove;
+} GstRemoveSilence;
+
+typedef struct _GstRemoveSilenceClass {
+ GstBaseTransformClass parent_class;
+} GstRemoveSilenceClass;
+
+GType gst_remove_silence_get_type (void);
+
+G_END_DECLS
+
+#endif /* __GST_REMOVE_SILENCE_H__ */
diff --git a/gst/removesilence/vad_private.c b/gst/removesilence/vad_private.c
new file mode 100644
index 000000000..f187a0614
--- /dev/null
+++ b/gst/removesilence/vad_private.c
@@ -0,0 +1,152 @@
+/* GStreamer
+ * Copyright (C) 2009 Tiago Katcipis <tiagokatcipis@gmail.com>
+ * Copyright (C) 2009 Paulo Pizarro <paulo.pizarro@gmail.com>
+ * Copyright (C) 2009 Rogério Santos <rogerio.santos@digitro.com.br>
+ *
+ * This library is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU Library General Public
+ * License as published by the Free Software Foundation; either
+ * version 2 of the License, or (at your option) any later version.
+ *
+ * This library is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Library General Public License for more details.
+ *
+ * You should have received a copy of the GNU Library General Public
+ * License along with this library; if not, write to the
+ * Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+ * Boston, MA 02111-1307, USA.
+ */
+
+#include <string.h>
+#include <stdio.h>
+#include <stdlib.h>
+#include <glib.h>
+#include "vad_private.h"
+
+#define VAD_POWER_ALPHA 0x0800 /* Q16 */
+#define VAD_POWER_THRESHOLD 0x000010C7 /* -60 dB (square wave) */
+#define VAD_ZCR_THRESHOLD 0
+#define VAD_BUFFER_SIZE 256
+
+
+union pgen
+{
+ guint64 a;
+ gpointer v;
+ guint64 *l;
+ guchar *b;
+ guint16 *w;
+ gint16 *s;
+};
+
+struct _cqueue_s
+{
+ union pgen base;
+ union pgen tail;
+ union pgen head;
+ gint size;
+};
+
+typedef struct _cqueue_s cqueue_t;
+
+struct _vad_s
+{
+ gint16 vad_buffer[VAD_BUFFER_SIZE];
+ cqueue_t cqueue;
+ gint vad_state;
+ guint64 hysteresis;
+ guint64 vad_samples;
+ guint64 vad_power;
+ long vad_zcr;
+};
+
+VADFilter *
+vad_new (guint64 hysteresis)
+{
+ VADFilter *vad = malloc (sizeof (VADFilter));
+ vad_reset (vad);
+ vad->hysteresis = hysteresis;
+ return vad;
+}
+
+void
+vad_reset (VADFilter * vad)
+{
+ memset (vad, 0, sizeof (vad));
+ vad->cqueue.base.s = vad->vad_buffer;
+ vad->cqueue.tail.a = vad->cqueue.head.a = 0;
+ vad->cqueue.size = VAD_BUFFER_SIZE;
+ vad->vad_state = VAD_SILENCE;
+}
+
+void
+vad_destroy (VADFilter * p)
+{
+ free (p);
+}
+
+void
+vad_set_hysteresis (struct _vad_s *p, guint64 hysteresis)
+{
+ p->hysteresis = hysteresis;
+}
+
+guint64
+vad_get_hysteresis (struct _vad_s *p)
+{
+ return p->hysteresis;
+}
+
+gint
+vad_update (struct _vad_s * p, gint16 * data, gint len)
+{
+ guint64 tail;
+ gint frame_type;
+ gint16 sample;
+ gint i;
+
+ for (i = 0; i < len; i++) {
+ p->vad_power = VAD_POWER_ALPHA * ((data[i] * data[i] >> 14) & 0xFFFF) +
+ (0xFFFF - VAD_POWER_ALPHA) * (p->vad_power >> 16) +
+ ((0xFFFF - VAD_POWER_ALPHA) * (p->vad_power & 0xFFFF) >> 16);
+ /* Update VAD buffer */
+ p->cqueue.base.s[p->cqueue.head.a] = data[i];
+ p->cqueue.head.a = (p->cqueue.head.a + 1) & (p->cqueue.size - 1);
+ if (p->cqueue.head.a == p->cqueue.tail.a)
+ p->cqueue.tail.a = (p->cqueue.tail.a + 1) & (p->cqueue.size - 1);
+ }
+
+ tail = p->cqueue.tail.a;
+ p->vad_zcr = 0;
+ for (;;) {
+ sample = p->cqueue.base.s[tail];
+ tail = (tail + 1) & (p->cqueue.size - 1);
+ if (tail == p->cqueue.head.a)
+ break;
+ p->vad_zcr +=
+ ((sample & 0x8000) != (p->cqueue.base.s[tail] & 0x8000)) ? 1 : -1;
+ }
+
+ frame_type = (p->vad_power > VAD_POWER_THRESHOLD
+ && p->vad_zcr < VAD_ZCR_THRESHOLD) ? VAD_VOICE : VAD_SILENCE;
+
+ if (p->vad_state != frame_type) {
+ /* Voice to silence transition */
+ if (p->vad_state == VAD_VOICE) {
+ p->vad_samples += len;
+ if (p->vad_samples >= p->hysteresis) {
+ p->vad_state = frame_type;
+ p->vad_samples = 0;
+ }
+ } else {
+ p->vad_state = frame_type;
+ p->vad_samples = 0;
+ }
+ } else {
+ p->vad_samples = 0;
+ }
+
+ return p->vad_state;
+}
diff --git a/gst/removesilence/vad_private.h b/gst/removesilence/vad_private.h
new file mode 100644
index 000000000..5401f4184
--- /dev/null
+++ b/gst/removesilence/vad_private.h
@@ -0,0 +1,44 @@
+/* GStreamer
+ * Copyright (C) 2009 Tiago Katcipis <tiagokatcipis@gmail.com>
+ * Copyright (C) 2009 Paulo Pizarro <paulo.pizarro@gmail.com>
+ * Copyright (C) 2009 Rogério Santos <rogerio.santos@digitro.com.br>
+ *
+ * This library is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU Library General Public
+ * License as published by the Free Software Foundation; either
+ * version 2 of the License, or (at your option) any later version.
+ *
+ * This library is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Library General Public License for more details.
+ *
+ * You should have received a copy of the GNU Library General Public
+ * License along with this library; if not, write to the
+ * Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+ * Boston, MA 02111-1307, USA.
+ */
+
+
+#ifndef __VAD_FILTER_H__
+#define __VAD_FILTER_H__
+
+#define VAD_SILENCE 0
+#define VAD_VOICE 1
+
+
+typedef struct _vad_s VADFilter;
+
+gint vad_update(VADFilter *p, gint16 *data, gint len);
+
+void vad_set_hysteresis(VADFilter *p, guint64 hysteresis);
+
+guint64 vad_get_hysteresis(VADFilter *p);
+
+VADFilter* vad_new(guint64 hysteresis);
+
+void vad_reset(VADFilter *p);
+
+void vad_destroy(VADFilter *p);
+
+#endif /* __VAD_FILTER__ */
diff --git a/sys/decklink/Makefile.am b/sys/decklink/Makefile.am
index c84d87126..cb13a8ace 100644
--- a/sys/decklink/Makefile.am
+++ b/sys/decklink/Makefile.am
@@ -17,13 +17,18 @@ libgstdecklink_la_SOURCES = \
gstdecklinksink.cpp \
gstdecklink.cpp \
capture.cpp \
- DeckLinkAPIDispatch.cpp
+ linux/DeckLinkAPIDispatch.cpp
noinst_HEADERS = \
gstdecklink.h \
gstdecklinksrc.h \
gstdecklinksink.h \
capture.h \
- DeckLinkAPI.h \
- LinuxCOM.h
+ linux/DeckLinkAPI.h \
+ linux/LinuxCOM.h
+
+EXTRA_DIST = \
+ win/DeckLinkAPI.h \
+ win/DeckLinkAPIDispatch.cpp \
+ win/DeckLinkAPI_i.c
diff --git a/sys/decklink/capture.cpp b/sys/decklink/capture.cpp
index 9a4b8bcf8..bc3d9e087 100644
--- a/sys/decklink/capture.cpp
+++ b/sys/decklink/capture.cpp
@@ -28,41 +28,37 @@
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
-#include <pthread.h>
#include <unistd.h>
#include <fcntl.h>
#include "gstdecklinksrc.h"
-#include "DeckLinkAPI.h"
#include "capture.h"
-
-int videoOutputFile = -1;
-int audioOutputFile = -1;
+#define GST_CAT_DEFAULT gst_decklink_src_debug_category
IDeckLink *deckLink;
IDeckLinkInput *deckLinkInput;
IDeckLinkDisplayModeIterator *displayModeIterator;
-static BMDTimecodeFormat g_timecodeFormat = 0;
+static BMDTimecodeFormat g_timecodeFormat = (BMDTimecodeFormat)0;
DeckLinkCaptureDelegate::DeckLinkCaptureDelegate ():m_refCount (0)
{
- pthread_mutex_init (&m_mutex, NULL);
+ m_mutex = g_mutex_new();
}
DeckLinkCaptureDelegate::~DeckLinkCaptureDelegate ()
{
- pthread_mutex_destroy (&m_mutex);
+ g_mutex_free (m_mutex);
}
ULONG
DeckLinkCaptureDelegate::AddRef (void)
{
- pthread_mutex_lock (&m_mutex);
+ g_mutex_lock (m_mutex);
m_refCount++;
- pthread_mutex_unlock (&m_mutex);
+ g_mutex_unlock (m_mutex);
return (ULONG) m_refCount;
}
@@ -70,9 +66,9 @@ DeckLinkCaptureDelegate::AddRef (void)
ULONG
DeckLinkCaptureDelegate::Release (void)
{
- pthread_mutex_lock (&m_mutex);
+ g_mutex_lock (m_mutex);
m_refCount--;
- pthread_mutex_unlock (&m_mutex);
+ g_mutex_unlock (m_mutex);
if (m_refCount == 0) {
delete this;
@@ -103,6 +99,7 @@ HRESULT
IDeckLinkTimecode *timecode;
if (videoFrame->GetTimecode (g_timecodeFormat, &timecode) == S_OK) {
timecode->GetString (&timecodeString);
+ CONVERT_COM_STRING (timecodeString);
}
}
@@ -111,7 +108,7 @@ HRESULT
"Valid Frame", videoFrame->GetRowBytes () * videoFrame->GetHeight ());
if (timecodeString)
- free ((void *) timecodeString);
+ FREE_COM_STRING (timecodeString);
g_mutex_lock (decklinksrc->mutex);
if (decklinksrc->video_frame != NULL) {
@@ -124,6 +121,10 @@ HRESULT
decklinksrc->audio_frame = audioFrame;
}
}
+
+ /* increment regardless whether frame was dropped or not */
+ decklinksrc->frame_num++;
+
g_cond_signal (decklinksrc->cond);
g_mutex_unlock (decklinksrc->mutex);
}
diff --git a/sys/decklink/capture.h b/sys/decklink/capture.h
index 3c1ab4695..c501616d7 100644
--- a/sys/decklink/capture.h
+++ b/sys/decklink/capture.h
@@ -1,7 +1,7 @@
#ifndef __CAPTURE_H__
#define __CAPTURE_H__
-#include "DeckLinkAPI.h"
+#include "gstdecklink.h"
class DeckLinkCaptureDelegate : public IDeckLinkInputCallback
{
@@ -18,8 +18,8 @@ class DeckLinkCaptureDelegate : public IDeckLinkInputCallback
void *priv;
private:
- ULONG m_refCount;
- pthread_mutex_t m_mutex;
+ ULONG m_refCount;
+ GMutex *m_mutex;
};
#endif
diff --git a/sys/decklink/gstdecklink.h b/sys/decklink/gstdecklink.h
index 9dd637501..e69d14bb8 100644
--- a/sys/decklink/gstdecklink.h
+++ b/sys/decklink/gstdecklink.h
@@ -21,8 +21,25 @@
#define _GST_DECKLINK_H_
#include <gst/gst.h>
-#include "DeckLinkAPI.h"
+#ifdef G_OS_UNIX
+#include "linux/DeckLinkAPI.h"
+#endif
+
+#ifdef G_OS_WIN32
+#include "win/DeckLinkAPI.h"
+
+#include <comutil.h>
+
+#define bool BOOL
+#define COMSTR_T BSTR*
+#define FREE_COM_STRING(s) delete[] s;
+#define CONVERT_COM_STRING(s) BSTR _s = (BSTR)s; s = _com_util::ConvertBSTRToString(_s); ::SysFreeString(_s);
+#else
+#define COMSTR_T char*
+#define FREE_COM_STRING(s) free ((void *) s)
+#define CONVERT_COM_STRING(s)
+#endif /* _MSC_VER */
typedef enum {
GST_DECKLINK_MODE_NTSC,
diff --git a/sys/decklink/gstdecklinksink.cpp b/sys/decklink/gstdecklinksink.cpp
index 720c90d74..9948048bd 100644
--- a/sys/decklink/gstdecklinksink.cpp
+++ b/sys/decklink/gstdecklinksink.cpp
@@ -40,6 +40,7 @@
#include "gstdecklinksink.h"
#include <string.h>
+
GST_DEBUG_CATEGORY_STATIC (gst_decklink_sink_debug_category);
#define GST_CAT_DEFAULT gst_decklink_sink_debug_category
@@ -116,6 +117,10 @@ static GstFlowReturn gst_decklink_sink_audiosink_bufferalloc (GstPad * pad,
guint64 offset, guint size, GstCaps * caps, GstBuffer ** buf);
static GstIterator *gst_decklink_sink_audiosink_iterintlink (GstPad * pad);
+#ifdef _MSC_VER
+/* COM initialization/uninitialization thread */
+static void gst_decklink_sink_com_thread (GstDecklinkSink * src);
+#endif /* _MSC_VER */
enum
{
@@ -268,6 +273,24 @@ gst_decklink_sink_init (GstDecklinkSink * decklinksink,
decklinksink->callback = new Output;
decklinksink->callback->decklinksink = decklinksink;
+
+#ifdef _MSC_VER
+ decklinksink->com_init_lock = g_mutex_new();
+ decklinksink->com_deinit_lock = g_mutex_new();
+ decklinksink->com_initialized = g_cond_new();
+ decklinksink->com_uninitialize = g_cond_new();
+ decklinksink->com_uninitialized = g_cond_new();
+
+ g_mutex_lock (decklinksink->com_init_lock);
+
+ /* create the COM initialization thread */
+ g_thread_create ((GThreadFunc)gst_decklink_sink_com_thread,
+ decklinksink, FALSE, NULL);
+
+ /* wait until the COM thread signals that COM has been initialized */
+ g_cond_wait (decklinksink->com_initialized, decklinksink->com_init_lock);
+ g_mutex_unlock (decklinksink->com_init_lock);
+#endif /* _MSC_VER */
}
void
@@ -308,6 +331,45 @@ gst_decklink_sink_get_property (GObject * object, guint property_id,
}
}
+#ifdef _MSC_VER
+static void
+gst_decklink_sink_com_thread (GstDecklinkSink * src)
+{
+ HRESULT res;
+
+ g_mutex_lock (src->com_init_lock);
+
+ /* Initialize COM with a MTA for this process. This thread will
+ * be the first one to enter the apartement and the last one to leave
+ * it, unitializing COM properly */
+
+ res = CoInitializeEx (0, COINIT_MULTITHREADED);
+ if (res == S_FALSE)
+ GST_WARNING_OBJECT (src, "COM has been already initialized in the same process");
+ else if (res == RPC_E_CHANGED_MODE)
+ GST_WARNING_OBJECT (src, "The concurrency model of COM has changed.");
+ else
+ GST_INFO_OBJECT (src, "COM intialized succesfully");
+
+ src->comInitialized = TRUE;
+
+ /* Signal other threads waiting on this condition that COM was initialized */
+ g_cond_signal (src->com_initialized);
+
+ g_mutex_unlock (src->com_init_lock);
+
+ /* Wait until the unitialize condition is met to leave the COM apartement */
+ g_mutex_lock (src->com_deinit_lock);
+ g_cond_wait (src->com_uninitialize, src->com_deinit_lock);
+
+ CoUninitialize ();
+ GST_INFO_OBJECT (src, "COM unintialized succesfully");
+ src->comInitialized = FALSE;
+ g_cond_signal (src->com_uninitialized);
+ g_mutex_unlock (src->com_deinit_lock);
+}
+#endif /* _MSC_VER */
+
void
gst_decklink_sink_dispose (GObject * object)
{
@@ -333,6 +395,22 @@ gst_decklink_sink_finalize (GObject * object)
delete decklinksink->callback;
+#ifdef _MSC_VER
+ /* signal the COM thread that it should uninitialize COM */
+ if (decklinksink->comInitialized) {
+ g_mutex_lock (decklinksink->com_deinit_lock);
+ g_cond_signal (decklinksink->com_uninitialize);
+ g_cond_wait (decklinksink->com_uninitialized, decklinksink->com_deinit_lock);
+ g_mutex_unlock (decklinksink->com_deinit_lock);
+ }
+
+ g_mutex_free (decklinksink->com_init_lock);
+ g_mutex_free (decklinksink->com_deinit_lock);
+ g_cond_free (decklinksink->com_initialized);
+ g_cond_free (decklinksink->com_uninitialize);
+ g_cond_free (decklinksink->com_uninitialized);
+#endif /* _MSC_VER */
+
G_OBJECT_CLASS (parent_class)->finalize (object);
}
@@ -342,6 +420,7 @@ gst_decklink_sink_start (GstDecklinkSink * decklinksink)
IDeckLinkIterator *iterator;
HRESULT ret;
const GstDecklinkMode *mode;
+ BMDAudioSampleType sample_depth;
iterator = CreateDeckLinkIteratorInstance ();
if (iterator == NULL) {
@@ -377,8 +456,9 @@ gst_decklink_sink_start (GstDecklinkSink * decklinksink)
decklinksink->output->
SetScheduledFrameCompletionCallback (decklinksink->callback);
+ sample_depth = bmdAudioSampleType16bitInteger;
ret = decklinksink->output->EnableAudioOutput (bmdAudioSampleRate48kHz,
- 16, 2, bmdAudioOutputStreamContinuous);
+ sample_depth, 2, bmdAudioOutputStreamContinuous);
if (ret != S_OK) {
GST_ERROR ("failed to enable audio output");
return FALSE;
@@ -1003,10 +1083,8 @@ HRESULT Output::ScheduledPlaybackHasStopped ()
HRESULT Output::RenderAudioSamples (bool preroll)
{
- guint
- samplesWritten;
- GstBuffer *
- buffer;
+ uint32_t samplesWritten;
+ GstBuffer * buffer;
// guint64 samplesToWrite;
@@ -1016,7 +1094,9 @@ HRESULT Output::RenderAudioSamples (bool preroll)
// running = true;
} else {
g_mutex_lock (decklinksink->audio_mutex);
- decklinksink->output->ScheduleAudioSamples (GST_BUFFER_DATA (decklinksink->audio_buffer), GST_BUFFER_SIZE (decklinksink->audio_buffer) / 4, // 2 bytes per sample, stereo
+ decklinksink->output->ScheduleAudioSamples (
+ GST_BUFFER_DATA (decklinksink->audio_buffer),
+ GST_BUFFER_SIZE (decklinksink->audio_buffer) / 4, // 2 bytes per sample, stereo
0, 0, &samplesWritten);
buffer =
diff --git a/sys/decklink/gstdecklinksink.h b/sys/decklink/gstdecklinksink.h
index d1b3b48fb..b5f07005a 100644
--- a/sys/decklink/gstdecklinksink.h
+++ b/sys/decklink/gstdecklinksink.h
@@ -22,7 +22,6 @@
#include <gst/gst.h>
#include "gstdecklink.h"
-#include "DeckLinkAPI.h"
G_BEGIN_DECLS
@@ -76,6 +75,14 @@ struct _GstDecklinkSink
/* properties */
GstDecklinkModeEnum mode;
+#ifdef _MSC_VER
+ gboolean comInitialized;
+ GMutex *com_init_lock;
+ GMutex *com_deinit_lock;
+ GCond *com_initialized;
+ GCond *com_uninitialize;
+ GCond *com_uninitialized;
+#endif /* _MSC_VER */
};
struct _GstDecklinkSinkClass
diff --git a/sys/decklink/gstdecklinksrc.cpp b/sys/decklink/gstdecklinksrc.cpp
index c866204f6..1e44a3c38 100644
--- a/sys/decklink/gstdecklinksrc.cpp
+++ b/sys/decklink/gstdecklinksrc.cpp
@@ -41,7 +41,7 @@
#include "capture.h"
#include <string.h>
-GST_DEBUG_CATEGORY_STATIC (gst_decklink_src_debug_category);
+GST_DEBUG_CATEGORY (gst_decklink_src_debug_category);
#define GST_CAT_DEFAULT gst_decklink_src_debug_category
/* prototypes */
@@ -115,12 +115,18 @@ static GstIterator *gst_decklink_src_video_src_iterintlink (GstPad * pad);
static void gst_decklink_src_task (void *priv);
+#ifdef _MSC_VER
+/* COM initialization/uninitialization thread */
+static void gst_decklink_src_com_thread (GstDecklinkSrc * src);
+#endif /* _MSC_VER */
+
enum
{
PROP_0,
PROP_MODE,
PROP_CONNECTION,
- PROP_AUDIO_INPUT
+ PROP_AUDIO_INPUT,
+ PROP_SUBDEVICE
};
/* pad templates */
@@ -152,7 +158,7 @@ gst_decklink_src_base_init (gpointer g_class)
gst_static_pad_template_get (&gst_decklink_src_audio_src_template));
gst_element_class_add_pad_template (element_class,
gst_pad_template_new ("videosrc", GST_PAD_SRC, GST_PAD_ALWAYS,
- gst_decklink_mode_get_template_caps ()));
+ gst_decklink_mode_get_template_caps ()));
gst_element_class_set_details_simple (element_class, "Decklink source",
"Source/Video", "DeckLink Source", "David Schleef <ds@entropywave.com>");
@@ -195,7 +201,14 @@ gst_decklink_src_class_init (GstDecklinkSrcClass * klass)
g_object_class_install_property (gobject_class, PROP_AUDIO_INPUT,
g_param_spec_enum ("audio-input", "Audio Input", "Audio Input Connection",
- GST_TYPE_DECKLINK_AUDIO_CONNECTION, GST_DECKLINK_AUDIO_CONNECTION_AUTO,
+ GST_TYPE_DECKLINK_AUDIO_CONNECTION,
+ GST_DECKLINK_AUDIO_CONNECTION_AUTO,
+ (GParamFlags) (G_PARAM_READWRITE | G_PARAM_STATIC_STRINGS |
+ G_PARAM_CONSTRUCT)));
+
+ g_object_class_install_property (gobject_class, PROP_SUBDEVICE,
+ g_param_spec_int ("subdevice", "Subdevice", "Subdevice",
+ 0, 3, 0,
(GParamFlags) (G_PARAM_READWRITE | G_PARAM_STATIC_STRINGS |
G_PARAM_CONSTRUCT)));
}
@@ -239,9 +252,9 @@ gst_decklink_src_init (GstDecklinkSrc * decklinksrc,
- decklinksrc->videosrcpad = gst_pad_new_from_template (
- gst_element_class_get_pad_template(GST_ELEMENT_CLASS(decklinksrc_class),
- "videosrc"), "videosrc");
+ decklinksrc->videosrcpad =
+ gst_pad_new_from_template (gst_element_class_get_pad_template
+ (GST_ELEMENT_CLASS (decklinksrc_class), "videosrc"), "videosrc");
gst_pad_set_getcaps_function (decklinksrc->videosrcpad,
GST_DEBUG_FUNCPTR (gst_decklink_src_video_src_getcaps));
gst_pad_set_setcaps_function (decklinksrc->videosrcpad,
@@ -276,7 +289,30 @@ gst_decklink_src_init (GstDecklinkSrc * decklinksrc,
decklinksrc->mode = GST_DECKLINK_MODE_NTSC;
decklinksrc->connection = GST_DECKLINK_CONNECTION_SDI;
decklinksrc->audio_connection = GST_DECKLINK_AUDIO_CONNECTION_AUTO;
-
+ decklinksrc->subdevice = 0;
+
+ decklinksrc->stop = FALSE;
+ decklinksrc->dropped_frames = 0;
+ decklinksrc->dropped_frames_old = 0;
+ decklinksrc->frame_num = -1; /* -1 so will be 0 after incrementing */
+
+#ifdef _MSC_VER
+ decklinksrc->com_init_lock = g_mutex_new();
+ decklinksrc->com_deinit_lock = g_mutex_new();
+ decklinksrc->com_initialized = g_cond_new();
+ decklinksrc->com_uninitialize = g_cond_new();
+ decklinksrc->com_uninitialized = g_cond_new();
+
+ g_mutex_lock (decklinksrc->com_init_lock);
+
+ /* create the COM initialization thread */
+ g_thread_create ((GThreadFunc)gst_decklink_src_com_thread,
+ decklinksrc, FALSE, NULL);
+
+ /* wait until the COM thread signals that COM has been initialized */
+ g_cond_wait (decklinksrc->com_initialized, decklinksrc->com_init_lock);
+ g_mutex_unlock (decklinksrc->com_init_lock);
+#endif /* _MSC_VER */
}
void
@@ -300,6 +336,9 @@ gst_decklink_src_set_property (GObject * object, guint property_id,
decklinksrc->audio_connection =
(GstDecklinkAudioConnectionEnum) g_value_get_enum (value);
break;
+ case PROP_SUBDEVICE:
+ decklinksrc->subdevice = g_value_get_int (value);
+ break;
default:
G_OBJECT_WARN_INVALID_PROPERTY_ID (object, property_id, pspec);
break;
@@ -325,12 +364,54 @@ gst_decklink_src_get_property (GObject * object, guint property_id,
case PROP_AUDIO_INPUT:
g_value_set_enum (value, decklinksrc->audio_connection);
break;
+ case PROP_SUBDEVICE:
+ g_value_set_int (value, decklinksrc->subdevice);
+ break;
default:
G_OBJECT_WARN_INVALID_PROPERTY_ID (object, property_id, pspec);
break;
}
}
+#ifdef _MSC_VER
+static void
+gst_decklink_src_com_thread (GstDecklinkSrc * src)
+{
+ HRESULT res;
+
+ g_mutex_lock (src->com_init_lock);
+
+ /* Initialize COM with a MTA for this process. This thread will
+ * be the first one to enter the apartement and the last one to leave
+ * it, unitializing COM properly */
+
+ res = CoInitializeEx (0, COINIT_MULTITHREADED);
+ if (res == S_FALSE)
+ GST_WARNING_OBJECT (src, "COM has been already initialized in the same process");
+ else if (res == RPC_E_CHANGED_MODE)
+ GST_WARNING_OBJECT (src, "The concurrency model of COM has changed.");
+ else
+ GST_INFO_OBJECT (src, "COM intialized succesfully");
+
+ src->comInitialized = TRUE;
+
+ /* Signal other threads waiting on this condition that COM was initialized */
+ g_cond_signal (src->com_initialized);
+
+ g_mutex_unlock (src->com_init_lock);
+
+ /* Wait until the unitialize condition is met to leave the COM apartement */
+ g_mutex_lock (src->com_deinit_lock);
+ g_cond_wait (src->com_uninitialize, src->com_deinit_lock);
+
+ CoUninitialize ();
+ GST_INFO_OBJECT (src, "COM unintialized succesfully");
+ src->comInitialized = FALSE;
+ g_cond_signal (src->com_uninitialized);
+ g_mutex_unlock (src->com_deinit_lock);
+}
+#endif /* _MSC_VER */
+
void
gst_decklink_src_dispose (GObject * object)
{
@@ -362,6 +443,22 @@ gst_decklink_src_finalize (GObject * object)
gst_caps_unref (decklinksrc->video_caps);
}
+#ifdef _MSC_VER
+ /* signal the COM thread that it should uninitialize COM */
+ if (decklinksrc->comInitialized) {
+ g_mutex_lock (decklinksrc->com_deinit_lock);
+ g_cond_signal (decklinksrc->com_uninitialize);
+ g_cond_wait (decklinksrc->com_uninitialized, decklinksrc->com_deinit_lock);
+ g_mutex_unlock (decklinksrc->com_deinit_lock);
+ }
+
+ g_mutex_free (decklinksrc->com_init_lock);
+ g_mutex_free (decklinksrc->com_deinit_lock);
+ g_cond_free (decklinksrc->com_initialized);
+ g_cond_free (decklinksrc->com_uninitialize);
+ g_cond_free (decklinksrc->com_uninitialized);
+#endif /* _MSC_VER */
+
G_OBJECT_CLASS (parent_class)->finalize (object);
}
@@ -389,13 +486,14 @@ gst_decklink_src_start (GstElement * element)
DeckLinkCaptureDelegate *delegate;
//IDeckLinkDisplayModeIterator *mode_iterator;
//IDeckLinkDisplayMode *mode;
- int sample_depth;
+ BMDAudioSampleType sample_depth;
int channels;
HRESULT ret;
const GstDecklinkMode *mode;
IDeckLinkConfiguration *config;
BMDVideoConnection conn;
BMDAudioConnection aconn;
+ int i;
GST_DEBUG_OBJECT (decklinksrc, "start");
@@ -410,6 +508,13 @@ gst_decklink_src_start (GstElement * element)
GST_ERROR ("no card");
return FALSE;
}
+ for (i = 0; i < decklinksrc->subdevice; i++) {
+ ret = iterator->Next (&decklinksrc->decklink);
+ if (ret != S_OK) {
+ GST_ERROR ("no card");
+ return FALSE;
+ }
+ }
ret = decklinksrc->decklink->QueryInterface (IID_IDeckLinkInput,
(void **) &decklinksrc->input);
@@ -491,7 +596,6 @@ gst_decklink_src_start (GstElement * element)
GST_ERROR ("set configuration (audio input connection)");
return FALSE;
}
-
#if 0
ret = decklinksrc->input->GetDisplayModeIterator (&mode_iterator);
if (ret != S_OK) {
@@ -520,7 +624,7 @@ gst_decklink_src_start (GstElement * element)
return FALSE;
}
- sample_depth = 16;
+ sample_depth = bmdAudioSampleType16bitInteger;
channels = 2;
ret = decklinksrc->input->EnableAudioInput (bmdAudioSampleRate48kHz,
sample_depth, channels);
@@ -1056,7 +1160,6 @@ gst_decklink_src_task (void *priv)
GstBuffer *audio_buffer;
IDeckLinkVideoInputFrame *video_frame;
IDeckLinkAudioInputPacket *audio_frame;
- int dropped_frames;
void *data;
int n_samples;
GstFlowReturn ret;
@@ -1070,7 +1173,6 @@ gst_decklink_src_task (void *priv)
}
video_frame = decklinksrc->video_frame;
audio_frame = decklinksrc->audio_frame;
- dropped_frames = decklinksrc->dropped_frames;
decklinksrc->video_frame = NULL;
decklinksrc->audio_frame = NULL;
g_mutex_unlock (decklinksrc->mutex);
@@ -1080,10 +1182,14 @@ gst_decklink_src_task (void *priv)
return;
}
- if (dropped_frames > 0) {
- GST_ELEMENT_ERROR (decklinksrc, RESOURCE, READ, (NULL), (NULL));
- /* ERROR */
- return;
+ /* warning on dropped frames */
+ if (decklinksrc->dropped_frames - decklinksrc->dropped_frames_old > 0) {
+ GST_ELEMENT_WARNING (decklinksrc, RESOURCE, READ,
+ ("Dropped %d frame(s), for a total of %d frame(s)",
+ decklinksrc->dropped_frames - decklinksrc->dropped_frames_old,
+ decklinksrc->dropped_frames),
+ (NULL));
+ decklinksrc->dropped_frames_old = decklinksrc->dropped_frames;
}
mode = gst_decklink_get_mode (decklinksrc->mode);
@@ -1106,16 +1212,28 @@ gst_decklink_src_task (void *priv)
}
GST_BUFFER_TIMESTAMP (buffer) =
- gst_util_uint64_scale_int (decklinksrc->num_frames * GST_SECOND,
+ gst_util_uint64_scale_int (decklinksrc->frame_num * GST_SECOND,
mode->fps_d, mode->fps_n);
GST_BUFFER_DURATION (buffer) =
- gst_util_uint64_scale_int ((decklinksrc->num_frames + 1) * GST_SECOND,
+ gst_util_uint64_scale_int ((decklinksrc->frame_num + 1) * GST_SECOND,
mode->fps_d, mode->fps_n) - GST_BUFFER_TIMESTAMP (buffer);
- GST_BUFFER_OFFSET (buffer) = decklinksrc->num_frames;
- if (decklinksrc->num_frames == 0) {
+ GST_BUFFER_OFFSET (buffer) = decklinksrc->frame_num;
+ GST_BUFFER_OFFSET_END (buffer) = decklinksrc->frame_num;
+ if (decklinksrc->frame_num == 0) {
+ GstEvent *event;
+ gboolean ret;
+
GST_BUFFER_FLAG_SET (buffer, GST_BUFFER_FLAG_DISCONT);
+
+ event = gst_event_new_new_segment (FALSE, 1.0, GST_FORMAT_TIME, 0,
+ GST_CLOCK_TIME_NONE, 0);
+
+ ret = gst_pad_push_event (decklinksrc->videosrcpad, event);
+ if (!ret) {
+ GST_ERROR_OBJECT (decklinksrc, "new segment event ret=%d", ret);
+ return;
+ }
}
- decklinksrc->num_frames++;
if (decklinksrc->video_caps == NULL) {
decklinksrc->video_caps = gst_decklink_mode_get_caps (decklinksrc->mode);
@@ -1144,7 +1262,7 @@ gst_decklink_src_task (void *priv)
if (decklinksrc->audio_caps == NULL) {
decklinksrc->audio_caps = gst_caps_new_simple ("audio/x-raw-int",
- "endianness", G_TYPE_INT, LITTLE_ENDIAN,
+ "endianness", G_TYPE_INT, G_LITTLE_ENDIAN,
"signed", G_TYPE_BOOLEAN, TRUE,
"depth", G_TYPE_INT, 16,
"width", G_TYPE_INT, 16,
diff --git a/sys/decklink/gstdecklinksrc.h b/sys/decklink/gstdecklinksrc.h
index 3afdb5e63..69dea49f1 100644
--- a/sys/decklink/gstdecklinksrc.h
+++ b/sys/decklink/gstdecklinksrc.h
@@ -22,10 +22,9 @@
#include <gst/gst.h>
#include "gstdecklink.h"
-#include "DeckLinkAPI.h"
G_BEGIN_DECLS
-
+GST_DEBUG_CATEGORY_EXTERN (gst_decklink_src_debug_category);
#define GST_TYPE_DECKLINK_SRC (gst_decklink_src_get_type())
#define GST_DECKLINK_SRC(obj) (G_TYPE_CHECK_INSTANCE_CAST((obj),GST_TYPE_DECKLINK_SRC,GstDecklinkSrc))
#define GST_DECKLINK_SRC_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST((klass),GST_TYPE_DECKLINK_SRC,GstDecklinkSrcClass))
@@ -50,6 +49,7 @@ struct _GstDecklinkSrc
GMutex *mutex;
GCond *cond;
int dropped_frames;
+ int dropped_frames_old;
gboolean stop;
IDeckLinkVideoInputFrame *video_frame;
IDeckLinkAudioInputPacket * audio_frame;
@@ -60,7 +60,7 @@ struct _GstDecklinkSrc
guint64 num_audio_samples;
GstCaps *video_caps;
- guint64 num_frames;
+ guint64 frame_num;
int fps_n;
int fps_d;
int width;
@@ -73,6 +73,16 @@ struct _GstDecklinkSrc
GstDecklinkModeEnum mode;
GstDecklinkConnectionEnum connection;
GstDecklinkAudioConnectionEnum audio_connection;
+ int subdevice;
+
+#ifdef _MSC_VER
+ gboolean comInitialized;
+ GMutex *com_init_lock;
+ GMutex *com_deinit_lock;
+ GCond *com_initialized;
+ GCond *com_uninitialize;
+ GCond *com_uninitialized;
+#endif /* _MSC_VER */
};
struct _GstDecklinkSrcClass
diff --git a/sys/decklink/DeckLinkAPI.h b/sys/decklink/linux/DeckLinkAPI.h
index e9c1066e3..e9c1066e3 100644
--- a/sys/decklink/DeckLinkAPI.h
+++ b/sys/decklink/linux/DeckLinkAPI.h
diff --git a/sys/decklink/DeckLinkAPIDispatch.cpp b/sys/decklink/linux/DeckLinkAPIDispatch.cpp
index 957f9a4cb..957f9a4cb 100644
--- a/sys/decklink/DeckLinkAPIDispatch.cpp
+++ b/sys/decklink/linux/DeckLinkAPIDispatch.cpp
diff --git a/sys/decklink/LinuxCOM.h b/sys/decklink/linux/LinuxCOM.h
index 2b13697d2..2b13697d2 100644
--- a/sys/decklink/LinuxCOM.h
+++ b/sys/decklink/linux/LinuxCOM.h
diff --git a/sys/decklink/win/DeckLinkAPI.h b/sys/decklink/win/DeckLinkAPI.h
new file mode 100644
index 000000000..0341ce812
--- /dev/null
+++ b/sys/decklink/win/DeckLinkAPI.h
@@ -0,0 +1,9217 @@
+
+
+/* this ALWAYS GENERATED file contains the definitions for the interfaces */
+
+
+ /* File created by MIDL compiler version 7.00.0500 */
+/* at Fri Jun 17 10:43:51 2011
+ */
+/* Compiler settings for .\win\DeckLinkAPI.idl:
+ Oicf, W1, Zp8, env=Win32 (32b run)
+ protocol : dce , ms_ext, c_ext, robust
+ error checks: allocation ref bounds_check enum stub_data
+ VC __declspec() decoration level:
+ __declspec(uuid()), __declspec(selectany), __declspec(novtable)
+ DECLSPEC_UUID(), MIDL_INTERFACE()
+*/
+//@@MIDL_FILE_HEADING( )
+
+#pragma warning( disable: 4049 ) /* more than 64k source lines */
+
+
+/* verify that the <rpcndr.h> version is high enough to compile this file*/
+#ifndef __REQUIRED_RPCNDR_H_VERSION__
+#define __REQUIRED_RPCNDR_H_VERSION__ 475
+#endif
+
+#include "rpc.h"
+#include "rpcndr.h"
+
+#ifndef __RPCNDR_H_VERSION__
+#error this stub requires an updated version of <rpcndr.h>
+#endif // __RPCNDR_H_VERSION__
+
+
+#ifndef __DeckLinkAPI_h__
+#define __DeckLinkAPI_h__
+
+#if defined(_MSC_VER) && (_MSC_VER >= 1020)
+#pragma once
+#endif
+
+/* Forward Declarations */
+
+#ifndef __IDeckLinkVideoOutputCallback_FWD_DEFINED__
+#define __IDeckLinkVideoOutputCallback_FWD_DEFINED__
+typedef interface IDeckLinkVideoOutputCallback IDeckLinkVideoOutputCallback;
+#endif /* __IDeckLinkVideoOutputCallback_FWD_DEFINED__ */
+
+
+#ifndef __IDeckLinkInputCallback_FWD_DEFINED__
+#define __IDeckLinkInputCallback_FWD_DEFINED__
+typedef interface IDeckLinkInputCallback IDeckLinkInputCallback;
+#endif /* __IDeckLinkInputCallback_FWD_DEFINED__ */
+
+
+#ifndef __IDeckLinkMemoryAllocator_FWD_DEFINED__
+#define __IDeckLinkMemoryAllocator_FWD_DEFINED__
+typedef interface IDeckLinkMemoryAllocator IDeckLinkMemoryAllocator;
+#endif /* __IDeckLinkMemoryAllocator_FWD_DEFINED__ */
+
+
+#ifndef __IDeckLinkAudioOutputCallback_FWD_DEFINED__
+#define __IDeckLinkAudioOutputCallback_FWD_DEFINED__
+typedef interface IDeckLinkAudioOutputCallback IDeckLinkAudioOutputCallback;
+#endif /* __IDeckLinkAudioOutputCallback_FWD_DEFINED__ */
+
+
+#ifndef __IDeckLinkIterator_FWD_DEFINED__
+#define __IDeckLinkIterator_FWD_DEFINED__
+typedef interface IDeckLinkIterator IDeckLinkIterator;
+#endif /* __IDeckLinkIterator_FWD_DEFINED__ */
+
+
+#ifndef __IDeckLinkAPIInformation_FWD_DEFINED__
+#define __IDeckLinkAPIInformation_FWD_DEFINED__
+typedef interface IDeckLinkAPIInformation IDeckLinkAPIInformation;
+#endif /* __IDeckLinkAPIInformation_FWD_DEFINED__ */
+
+
+#ifndef __IDeckLinkDisplayModeIterator_FWD_DEFINED__
+#define __IDeckLinkDisplayModeIterator_FWD_DEFINED__
+typedef interface IDeckLinkDisplayModeIterator IDeckLinkDisplayModeIterator;
+#endif /* __IDeckLinkDisplayModeIterator_FWD_DEFINED__ */
+
+
+#ifndef __IDeckLinkDisplayMode_FWD_DEFINED__
+#define __IDeckLinkDisplayMode_FWD_DEFINED__
+typedef interface IDeckLinkDisplayMode IDeckLinkDisplayMode;
+#endif /* __IDeckLinkDisplayMode_FWD_DEFINED__ */
+
+
+#ifndef __IDeckLink_FWD_DEFINED__
+#define __IDeckLink_FWD_DEFINED__
+typedef interface IDeckLink IDeckLink;
+#endif /* __IDeckLink_FWD_DEFINED__ */
+
+
+#ifndef __IDeckLinkOutput_FWD_DEFINED__
+#define __IDeckLinkOutput_FWD_DEFINED__
+typedef interface IDeckLinkOutput IDeckLinkOutput;
+#endif /* __IDeckLinkOutput_FWD_DEFINED__ */
+
+
+#ifndef __IDeckLinkInput_FWD_DEFINED__
+#define __IDeckLinkInput_FWD_DEFINED__
+typedef interface IDeckLinkInput IDeckLinkInput;
+#endif /* __IDeckLinkInput_FWD_DEFINED__ */
+
+
+#ifndef __IDeckLinkTimecode_FWD_DEFINED__
+#define __IDeckLinkTimecode_FWD_DEFINED__
+typedef interface IDeckLinkTimecode IDeckLinkTimecode;
+#endif /* __IDeckLinkTimecode_FWD_DEFINED__ */
+
+
+#ifndef __IDeckLinkVideoFrame_FWD_DEFINED__
+#define __IDeckLinkVideoFrame_FWD_DEFINED__
+typedef interface IDeckLinkVideoFrame IDeckLinkVideoFrame;
+#endif /* __IDeckLinkVideoFrame_FWD_DEFINED__ */
+
+
+#ifndef __IDeckLinkMutableVideoFrame_FWD_DEFINED__
+#define __IDeckLinkMutableVideoFrame_FWD_DEFINED__
+typedef interface IDeckLinkMutableVideoFrame IDeckLinkMutableVideoFrame;
+#endif /* __IDeckLinkMutableVideoFrame_FWD_DEFINED__ */
+
+
+#ifndef __IDeckLinkVideoFrame3DExtensions_FWD_DEFINED__
+#define __IDeckLinkVideoFrame3DExtensions_FWD_DEFINED__
+typedef interface IDeckLinkVideoFrame3DExtensions IDeckLinkVideoFrame3DExtensions;
+#endif /* __IDeckLinkVideoFrame3DExtensions_FWD_DEFINED__ */
+
+
+#ifndef __IDeckLinkVideoInputFrame_FWD_DEFINED__
+#define __IDeckLinkVideoInputFrame_FWD_DEFINED__
+typedef interface IDeckLinkVideoInputFrame IDeckLinkVideoInputFrame;
+#endif /* __IDeckLinkVideoInputFrame_FWD_DEFINED__ */
+
+
+#ifndef __IDeckLinkVideoFrameAncillary_FWD_DEFINED__
+#define __IDeckLinkVideoFrameAncillary_FWD_DEFINED__
+typedef interface IDeckLinkVideoFrameAncillary IDeckLinkVideoFrameAncillary;
+#endif /* __IDeckLinkVideoFrameAncillary_FWD_DEFINED__ */
+
+
+#ifndef __IDeckLinkAudioInputPacket_FWD_DEFINED__
+#define __IDeckLinkAudioInputPacket_FWD_DEFINED__
+typedef interface IDeckLinkAudioInputPacket IDeckLinkAudioInputPacket;
+#endif /* __IDeckLinkAudioInputPacket_FWD_DEFINED__ */
+
+
+#ifndef __IDeckLinkScreenPreviewCallback_FWD_DEFINED__
+#define __IDeckLinkScreenPreviewCallback_FWD_DEFINED__
+typedef interface IDeckLinkScreenPreviewCallback IDeckLinkScreenPreviewCallback;
+#endif /* __IDeckLinkScreenPreviewCallback_FWD_DEFINED__ */
+
+
+#ifndef __IDeckLinkGLScreenPreviewHelper_FWD_DEFINED__
+#define __IDeckLinkGLScreenPreviewHelper_FWD_DEFINED__
+typedef interface IDeckLinkGLScreenPreviewHelper IDeckLinkGLScreenPreviewHelper;
+#endif /* __IDeckLinkGLScreenPreviewHelper_FWD_DEFINED__ */
+
+
+#ifndef __IDeckLinkConfiguration_FWD_DEFINED__
+#define __IDeckLinkConfiguration_FWD_DEFINED__
+typedef interface IDeckLinkConfiguration IDeckLinkConfiguration;
+#endif /* __IDeckLinkConfiguration_FWD_DEFINED__ */
+
+
+#ifndef __IDeckLinkAttributes_FWD_DEFINED__
+#define __IDeckLinkAttributes_FWD_DEFINED__
+typedef interface IDeckLinkAttributes IDeckLinkAttributes;
+#endif /* __IDeckLinkAttributes_FWD_DEFINED__ */
+
+
+#ifndef __IDeckLinkKeyer_FWD_DEFINED__
+#define __IDeckLinkKeyer_FWD_DEFINED__
+typedef interface IDeckLinkKeyer IDeckLinkKeyer;
+#endif /* __IDeckLinkKeyer_FWD_DEFINED__ */
+
+
+#ifndef __IDeckLinkVideoConversion_FWD_DEFINED__
+#define __IDeckLinkVideoConversion_FWD_DEFINED__
+typedef interface IDeckLinkVideoConversion IDeckLinkVideoConversion;
+#endif /* __IDeckLinkVideoConversion_FWD_DEFINED__ */
+
+
+#ifndef __IDeckLinkDeckControlStatusCallback_FWD_DEFINED__
+#define __IDeckLinkDeckControlStatusCallback_FWD_DEFINED__
+typedef interface IDeckLinkDeckControlStatusCallback IDeckLinkDeckControlStatusCallback;
+#endif /* __IDeckLinkDeckControlStatusCallback_FWD_DEFINED__ */
+
+
+#ifndef __IDeckLinkDeckControl_FWD_DEFINED__
+#define __IDeckLinkDeckControl_FWD_DEFINED__
+typedef interface IDeckLinkDeckControl IDeckLinkDeckControl;
+#endif /* __IDeckLinkDeckControl_FWD_DEFINED__ */
+
+
+#ifndef __CDeckLinkIterator_FWD_DEFINED__
+#define __CDeckLinkIterator_FWD_DEFINED__
+
+#ifdef __cplusplus
+typedef class CDeckLinkIterator CDeckLinkIterator;
+#else
+typedef struct CDeckLinkIterator CDeckLinkIterator;
+#endif /* __cplusplus */
+
+#endif /* __CDeckLinkIterator_FWD_DEFINED__ */
+
+
+#ifndef __CDeckLinkAPIInformation_FWD_DEFINED__
+#define __CDeckLinkAPIInformation_FWD_DEFINED__
+
+#ifdef __cplusplus
+typedef class CDeckLinkAPIInformation CDeckLinkAPIInformation;
+#else
+typedef struct CDeckLinkAPIInformation CDeckLinkAPIInformation;
+#endif /* __cplusplus */
+
+#endif /* __CDeckLinkAPIInformation_FWD_DEFINED__ */
+
+
+#ifndef __CDeckLinkGLScreenPreviewHelper_FWD_DEFINED__
+#define __CDeckLinkGLScreenPreviewHelper_FWD_DEFINED__
+
+#ifdef __cplusplus
+typedef class CDeckLinkGLScreenPreviewHelper CDeckLinkGLScreenPreviewHelper;
+#else
+typedef struct CDeckLinkGLScreenPreviewHelper CDeckLinkGLScreenPreviewHelper;
+#endif /* __cplusplus */
+
+#endif /* __CDeckLinkGLScreenPreviewHelper_FWD_DEFINED__ */
+
+
+#ifndef __CDeckLinkVideoConversion_FWD_DEFINED__
+#define __CDeckLinkVideoConversion_FWD_DEFINED__
+
+#ifdef __cplusplus
+typedef class CDeckLinkVideoConversion CDeckLinkVideoConversion;
+#else
+typedef struct CDeckLinkVideoConversion CDeckLinkVideoConversion;
+#endif /* __cplusplus */
+
+#endif /* __CDeckLinkVideoConversion_FWD_DEFINED__ */
+
+
+#ifndef __IDeckLinkDeckControl_v7_9_FWD_DEFINED__
+#define __IDeckLinkDeckControl_v7_9_FWD_DEFINED__
+typedef interface IDeckLinkDeckControl_v7_9 IDeckLinkDeckControl_v7_9;
+#endif /* __IDeckLinkDeckControl_v7_9_FWD_DEFINED__ */
+
+
+#ifndef __IDeckLinkDisplayModeIterator_v7_6_FWD_DEFINED__
+#define __IDeckLinkDisplayModeIterator_v7_6_FWD_DEFINED__
+typedef interface IDeckLinkDisplayModeIterator_v7_6 IDeckLinkDisplayModeIterator_v7_6;
+#endif /* __IDeckLinkDisplayModeIterator_v7_6_FWD_DEFINED__ */
+
+
+#ifndef __IDeckLinkDisplayMode_v7_6_FWD_DEFINED__
+#define __IDeckLinkDisplayMode_v7_6_FWD_DEFINED__
+typedef interface IDeckLinkDisplayMode_v7_6 IDeckLinkDisplayMode_v7_6;
+#endif /* __IDeckLinkDisplayMode_v7_6_FWD_DEFINED__ */
+
+
+#ifndef __IDeckLinkOutput_v7_6_FWD_DEFINED__
+#define __IDeckLinkOutput_v7_6_FWD_DEFINED__
+typedef interface IDeckLinkOutput_v7_6 IDeckLinkOutput_v7_6;
+#endif /* __IDeckLinkOutput_v7_6_FWD_DEFINED__ */
+
+
+#ifndef __IDeckLinkInput_v7_6_FWD_DEFINED__
+#define __IDeckLinkInput_v7_6_FWD_DEFINED__
+typedef interface IDeckLinkInput_v7_6 IDeckLinkInput_v7_6;
+#endif /* __IDeckLinkInput_v7_6_FWD_DEFINED__ */
+
+
+#ifndef __IDeckLinkTimecode_v7_6_FWD_DEFINED__
+#define __IDeckLinkTimecode_v7_6_FWD_DEFINED__
+typedef interface IDeckLinkTimecode_v7_6 IDeckLinkTimecode_v7_6;
+#endif /* __IDeckLinkTimecode_v7_6_FWD_DEFINED__ */
+
+
+#ifndef __IDeckLinkVideoFrame_v7_6_FWD_DEFINED__
+#define __IDeckLinkVideoFrame_v7_6_FWD_DEFINED__
+typedef interface IDeckLinkVideoFrame_v7_6 IDeckLinkVideoFrame_v7_6;
+#endif /* __IDeckLinkVideoFrame_v7_6_FWD_DEFINED__ */
+
+
+#ifndef __IDeckLinkMutableVideoFrame_v7_6_FWD_DEFINED__
+#define __IDeckLinkMutableVideoFrame_v7_6_FWD_DEFINED__
+typedef interface IDeckLinkMutableVideoFrame_v7_6 IDeckLinkMutableVideoFrame_v7_6;
+#endif /* __IDeckLinkMutableVideoFrame_v7_6_FWD_DEFINED__ */
+
+
+#ifndef __IDeckLinkVideoInputFrame_v7_6_FWD_DEFINED__
+#define __IDeckLinkVideoInputFrame_v7_6_FWD_DEFINED__
+typedef interface IDeckLinkVideoInputFrame_v7_6 IDeckLinkVideoInputFrame_v7_6;
+#endif /* __IDeckLinkVideoInputFrame_v7_6_FWD_DEFINED__ */
+
+
+#ifndef __IDeckLinkScreenPreviewCallback_v7_6_FWD_DEFINED__
+#define __IDeckLinkScreenPreviewCallback_v7_6_FWD_DEFINED__
+typedef interface IDeckLinkScreenPreviewCallback_v7_6 IDeckLinkScreenPreviewCallback_v7_6;
+#endif /* __IDeckLinkScreenPreviewCallback_v7_6_FWD_DEFINED__ */
+
+
+#ifndef __IDeckLinkGLScreenPreviewHelper_v7_6_FWD_DEFINED__
+#define __IDeckLinkGLScreenPreviewHelper_v7_6_FWD_DEFINED__
+typedef interface IDeckLinkGLScreenPreviewHelper_v7_6 IDeckLinkGLScreenPreviewHelper_v7_6;
+#endif /* __IDeckLinkGLScreenPreviewHelper_v7_6_FWD_DEFINED__ */
+
+
+#ifndef __IDeckLinkVideoConversion_v7_6_FWD_DEFINED__
+#define __IDeckLinkVideoConversion_v7_6_FWD_DEFINED__
+typedef interface IDeckLinkVideoConversion_v7_6 IDeckLinkVideoConversion_v7_6;
+#endif /* __IDeckLinkVideoConversion_v7_6_FWD_DEFINED__ */
+
+
+#ifndef __IDeckLinkConfiguration_v7_6_FWD_DEFINED__
+#define __IDeckLinkConfiguration_v7_6_FWD_DEFINED__
+typedef interface IDeckLinkConfiguration_v7_6 IDeckLinkConfiguration_v7_6;
+#endif /* __IDeckLinkConfiguration_v7_6_FWD_DEFINED__ */
+
+
+#ifndef __IDeckLinkVideoOutputCallback_v7_6_FWD_DEFINED__
+#define __IDeckLinkVideoOutputCallback_v7_6_FWD_DEFINED__
+typedef interface IDeckLinkVideoOutputCallback_v7_6 IDeckLinkVideoOutputCallback_v7_6;
+#endif /* __IDeckLinkVideoOutputCallback_v7_6_FWD_DEFINED__ */
+
+
+#ifndef __IDeckLinkInputCallback_v7_6_FWD_DEFINED__
+#define __IDeckLinkInputCallback_v7_6_FWD_DEFINED__
+typedef interface IDeckLinkInputCallback_v7_6 IDeckLinkInputCallback_v7_6;
+#endif /* __IDeckLinkInputCallback_v7_6_FWD_DEFINED__ */
+
+
+#ifndef __CDeckLinkGLScreenPreviewHelper_v7_6_FWD_DEFINED__
+#define __CDeckLinkGLScreenPreviewHelper_v7_6_FWD_DEFINED__
+
+#ifdef __cplusplus
+typedef class CDeckLinkGLScreenPreviewHelper_v7_6 CDeckLinkGLScreenPreviewHelper_v7_6;
+#else
+typedef struct CDeckLinkGLScreenPreviewHelper_v7_6 CDeckLinkGLScreenPreviewHelper_v7_6;
+#endif /* __cplusplus */
+
+#endif /* __CDeckLinkGLScreenPreviewHelper_v7_6_FWD_DEFINED__ */
+
+
+#ifndef __CDeckLinkVideoConversion_v7_6_FWD_DEFINED__
+#define __CDeckLinkVideoConversion_v7_6_FWD_DEFINED__
+
+#ifdef __cplusplus
+typedef class CDeckLinkVideoConversion_v7_6 CDeckLinkVideoConversion_v7_6;
+#else
+typedef struct CDeckLinkVideoConversion_v7_6 CDeckLinkVideoConversion_v7_6;
+#endif /* __cplusplus */
+
+#endif /* __CDeckLinkVideoConversion_v7_6_FWD_DEFINED__ */
+
+
+#ifndef __IDeckLinkInputCallback_v7_3_FWD_DEFINED__
+#define __IDeckLinkInputCallback_v7_3_FWD_DEFINED__
+typedef interface IDeckLinkInputCallback_v7_3 IDeckLinkInputCallback_v7_3;
+#endif /* __IDeckLinkInputCallback_v7_3_FWD_DEFINED__ */
+
+
+#ifndef __IDeckLinkOutput_v7_3_FWD_DEFINED__
+#define __IDeckLinkOutput_v7_3_FWD_DEFINED__
+typedef interface IDeckLinkOutput_v7_3 IDeckLinkOutput_v7_3;
+#endif /* __IDeckLinkOutput_v7_3_FWD_DEFINED__ */
+
+
+#ifndef __IDeckLinkInput_v7_3_FWD_DEFINED__
+#define __IDeckLinkInput_v7_3_FWD_DEFINED__
+typedef interface IDeckLinkInput_v7_3 IDeckLinkInput_v7_3;
+#endif /* __IDeckLinkInput_v7_3_FWD_DEFINED__ */
+
+
+#ifndef __IDeckLinkVideoInputFrame_v7_3_FWD_DEFINED__
+#define __IDeckLinkVideoInputFrame_v7_3_FWD_DEFINED__
+typedef interface IDeckLinkVideoInputFrame_v7_3 IDeckLinkVideoInputFrame_v7_3;
+#endif /* __IDeckLinkVideoInputFrame_v7_3_FWD_DEFINED__ */
+
+
+#ifndef __IDeckLinkDisplayModeIterator_v7_1_FWD_DEFINED__
+#define __IDeckLinkDisplayModeIterator_v7_1_FWD_DEFINED__
+typedef interface IDeckLinkDisplayModeIterator_v7_1 IDeckLinkDisplayModeIterator_v7_1;
+#endif /* __IDeckLinkDisplayModeIterator_v7_1_FWD_DEFINED__ */
+
+
+#ifndef __IDeckLinkDisplayMode_v7_1_FWD_DEFINED__
+#define __IDeckLinkDisplayMode_v7_1_FWD_DEFINED__
+typedef interface IDeckLinkDisplayMode_v7_1 IDeckLinkDisplayMode_v7_1;
+#endif /* __IDeckLinkDisplayMode_v7_1_FWD_DEFINED__ */
+
+
+#ifndef __IDeckLinkVideoFrame_v7_1_FWD_DEFINED__
+#define __IDeckLinkVideoFrame_v7_1_FWD_DEFINED__
+typedef interface IDeckLinkVideoFrame_v7_1 IDeckLinkVideoFrame_v7_1;
+#endif /* __IDeckLinkVideoFrame_v7_1_FWD_DEFINED__ */
+
+
+#ifndef __IDeckLinkVideoInputFrame_v7_1_FWD_DEFINED__
+#define __IDeckLinkVideoInputFrame_v7_1_FWD_DEFINED__
+typedef interface IDeckLinkVideoInputFrame_v7_1 IDeckLinkVideoInputFrame_v7_1;
+#endif /* __IDeckLinkVideoInputFrame_v7_1_FWD_DEFINED__ */
+
+
+#ifndef __IDeckLinkAudioInputPacket_v7_1_FWD_DEFINED__
+#define __IDeckLinkAudioInputPacket_v7_1_FWD_DEFINED__
+typedef interface IDeckLinkAudioInputPacket_v7_1 IDeckLinkAudioInputPacket_v7_1;
+#endif /* __IDeckLinkAudioInputPacket_v7_1_FWD_DEFINED__ */
+
+
+#ifndef __IDeckLinkVideoOutputCallback_v7_1_FWD_DEFINED__
+#define __IDeckLinkVideoOutputCallback_v7_1_FWD_DEFINED__
+typedef interface IDeckLinkVideoOutputCallback_v7_1 IDeckLinkVideoOutputCallback_v7_1;
+#endif /* __IDeckLinkVideoOutputCallback_v7_1_FWD_DEFINED__ */
+
+
+#ifndef __IDeckLinkInputCallback_v7_1_FWD_DEFINED__
+#define __IDeckLinkInputCallback_v7_1_FWD_DEFINED__
+typedef interface IDeckLinkInputCallback_v7_1 IDeckLinkInputCallback_v7_1;
+#endif /* __IDeckLinkInputCallback_v7_1_FWD_DEFINED__ */
+
+
+#ifndef __IDeckLinkOutput_v7_1_FWD_DEFINED__
+#define __IDeckLinkOutput_v7_1_FWD_DEFINED__
+typedef interface IDeckLinkOutput_v7_1 IDeckLinkOutput_v7_1;
+#endif /* __IDeckLinkOutput_v7_1_FWD_DEFINED__ */
+
+
+#ifndef __IDeckLinkInput_v7_1_FWD_DEFINED__
+#define __IDeckLinkInput_v7_1_FWD_DEFINED__
+typedef interface IDeckLinkInput_v7_1 IDeckLinkInput_v7_1;
+#endif /* __IDeckLinkInput_v7_1_FWD_DEFINED__ */
+
+
+/* header files for imported files */
+#include "unknwn.h"
+
+#ifdef __cplusplus
+extern "C"{
+#endif
+
+
+
+#ifndef __DeckLinkAPI_LIBRARY_DEFINED__
+#define __DeckLinkAPI_LIBRARY_DEFINED__
+
+/* library DeckLinkAPI */
+/* [helpstring][version][uuid] */
+
+typedef LONGLONG BMDTimeValue;
+
+typedef LONGLONG BMDTimeScale;
+
+typedef unsigned long BMDTimecodeBCD;
+
+typedef unsigned long BMDTimecodeUserBits;
+
+typedef unsigned long BMDDisplayModeFlags;
+typedef unsigned long BMDFrameFlags;
+typedef unsigned long BMDVideoInputFlags;
+typedef unsigned long BMDVideoInputFormatChangedEvents;
+typedef unsigned long BMDDetectedVideoInputFormatFlags;
+typedef unsigned long BMDTimecodeFlags;
+typedef unsigned long BMDAnalogVideoFlags;
+typedef unsigned long BMDDeckControlStatusFlags;
+typedef unsigned long BMDDeckControlExportModeOpsFlags;
+#if 0
+typedef enum _BMDDisplayModeFlags BMDDisplayModeFlags;
+
+typedef enum _BMDFrameFlags BMDFrameFlags;
+
+typedef enum _BMDVideoInputFlags BMDVideoInputFlags;
+
+typedef enum _BMDVideoInputFormatChangedEvents BMDVideoInputFormatChangedEvents;
+
+typedef enum _BMDDetectedVideoInputFormatFlags BMDDetectedVideoInputFormatFlags;
+
+typedef enum _BMDTimecodeFlags BMDTimecodeFlags;
+
+typedef enum _BMDAnalogVideoFlags BMDAnalogVideoFlags;
+
+typedef enum _BMDDeckControlStatusFlags BMDDeckControlStatusFlags;
+
+typedef enum _BMDDeckControlExportModeOpsFlags BMDDeckControlExportModeOpsFlags;
+
+#endif
+typedef /* [v1_enum] */
+enum _BMDDisplayMode
+ { bmdModeNTSC = 0x6e747363,
+ bmdModeNTSC2398 = 0x6e743233,
+ bmdModePAL = 0x70616c20,
+ bmdModeNTSCp = 0x6e747370,
+ bmdModePALp = 0x70616c70,
+ bmdModeHD1080p2398 = 0x32337073,
+ bmdModeHD1080p24 = 0x32347073,
+ bmdModeHD1080p25 = 0x48703235,
+ bmdModeHD1080p2997 = 0x48703239,
+ bmdModeHD1080p30 = 0x48703330,
+ bmdModeHD1080i50 = 0x48693530,
+ bmdModeHD1080i5994 = 0x48693539,
+ bmdModeHD1080i6000 = 0x48693630,
+ bmdModeHD1080p50 = 0x48703530,
+ bmdModeHD1080p5994 = 0x48703539,
+ bmdModeHD1080p6000 = 0x48703630,
+ bmdModeHD720p50 = 0x68703530,
+ bmdModeHD720p5994 = 0x68703539,
+ bmdModeHD720p60 = 0x68703630,
+ bmdMode2k2398 = 0x326b3233,
+ bmdMode2k24 = 0x326b3234,
+ bmdMode2k25 = 0x326b3235
+ } BMDDisplayMode;
+
+typedef /* [v1_enum] */
+enum _BMDFieldDominance
+ { bmdUnknownFieldDominance = 0,
+ bmdLowerFieldFirst = 0x6c6f7772,
+ bmdUpperFieldFirst = 0x75707072,
+ bmdProgressiveFrame = 0x70726f67,
+ bmdProgressiveSegmentedFrame = 0x70736620
+ } BMDFieldDominance;
+
+typedef /* [v1_enum] */
+enum _BMDPixelFormat
+ { bmdFormat8BitYUV = 0x32767579,
+ bmdFormat10BitYUV = 0x76323130,
+ bmdFormat8BitARGB = 32,
+ bmdFormat8BitBGRA = 0x42475241,
+ bmdFormat10BitRGB = 0x72323130
+ } BMDPixelFormat;
+
+/* [v1_enum] */
+enum _BMDDisplayModeFlags
+ { bmdDisplayModeSupports3D = ( 1 << 0 ) ,
+ bmdDisplayModeColorspaceRec601 = ( 1 << 1 ) ,
+ bmdDisplayModeColorspaceRec709 = ( 1 << 2 )
+ } ;
+typedef /* [v1_enum] */
+enum _BMDVideoOutputFlags
+ { bmdVideoOutputFlagDefault = 0,
+ bmdVideoOutputVANC = ( 1 << 0 ) ,
+ bmdVideoOutputVITC = ( 1 << 1 ) ,
+ bmdVideoOutputRP188 = ( 1 << 2 ) ,
+ bmdVideoOutputDualStream3D = ( 1 << 4 )
+ } BMDVideoOutputFlags;
+
+/* [v1_enum] */
+enum _BMDFrameFlags
+ { bmdFrameFlagDefault = 0,
+ bmdFrameFlagFlipVertical = ( 1 << 0 ) ,
+ bmdFrameHasNoInputSource = ( 1 << 31 )
+ } ;
+/* [v1_enum] */
+enum _BMDVideoInputFlags
+ { bmdVideoInputFlagDefault = 0,
+ bmdVideoInputEnableFormatDetection = ( 1 << 0 ) ,
+ bmdVideoInputDualStream3D = ( 1 << 1 )
+ } ;
+/* [v1_enum] */
+enum _BMDVideoInputFormatChangedEvents
+ { bmdVideoInputDisplayModeChanged = ( 1 << 0 ) ,
+ bmdVideoInputFieldDominanceChanged = ( 1 << 1 ) ,
+ bmdVideoInputColorspaceChanged = ( 1 << 2 )
+ } ;
+/* [v1_enum] */
+enum _BMDDetectedVideoInputFormatFlags
+ { bmdDetectedVideoInputYCbCr422 = ( 1 << 0 ) ,
+ bmdDetectedVideoInputRGB444 = ( 1 << 1 )
+ } ;
+typedef /* [v1_enum] */
+enum _BMDOutputFrameCompletionResult
+ { bmdOutputFrameCompleted = 0,
+ bmdOutputFrameDisplayedLate = ( bmdOutputFrameCompleted + 1 ) ,
+ bmdOutputFrameDropped = ( bmdOutputFrameDisplayedLate + 1 ) ,
+ bmdOutputFrameFlushed = ( bmdOutputFrameDropped + 1 )
+ } BMDOutputFrameCompletionResult;
+
+typedef /* [v1_enum] */
+enum _BMDReferenceStatus
+ { bmdReferenceNotSupportedByHardware = ( 1 << 0 ) ,
+ bmdReferenceLocked = ( 1 << 1 )
+ } BMDReferenceStatus;
+
+typedef /* [v1_enum] */
+enum _BMDAudioSampleRate
+ { bmdAudioSampleRate48kHz = 48000
+ } BMDAudioSampleRate;
+
+typedef /* [v1_enum] */
+enum _BMDAudioSampleType
+ { bmdAudioSampleType16bitInteger = 16,
+ bmdAudioSampleType32bitInteger = 32
+ } BMDAudioSampleType;
+
+typedef /* [v1_enum] */
+enum _BMDAudioOutputStreamType
+ { bmdAudioOutputStreamContinuous = 0,
+ bmdAudioOutputStreamContinuousDontResample = ( bmdAudioOutputStreamContinuous + 1 ) ,
+ bmdAudioOutputStreamTimestamped = ( bmdAudioOutputStreamContinuousDontResample + 1 )
+ } BMDAudioOutputStreamType;
+
+typedef /* [v1_enum] */
+enum _BMDDisplayModeSupport
+ { bmdDisplayModeNotSupported = 0,
+ bmdDisplayModeSupported = ( bmdDisplayModeNotSupported + 1 ) ,
+ bmdDisplayModeSupportedWithConversion = ( bmdDisplayModeSupported + 1 )
+ } BMDDisplayModeSupport;
+
+typedef /* [v1_enum] */
+enum _BMDTimecodeFormat
+ { bmdTimecodeRP188 = 0x72703138,
+ bmdTimecodeRP188Field2 = 0x72703132,
+ bmdTimecodeVITC = 0x76697463,
+ bmdTimecodeVITCField2 = 0x76697432,
+ bmdTimecodeSerial = 0x73657269
+ } BMDTimecodeFormat;
+
+/* [v1_enum] */
+enum _BMDTimecodeFlags
+ { bmdTimecodeFlagDefault = 0,
+ bmdTimecodeIsDropFrame = ( 1 << 0 )
+ } ;
+typedef /* [v1_enum] */
+enum _BMDVideoConnection
+ { bmdVideoConnectionSDI = ( 1 << 0 ) ,
+ bmdVideoConnectionHDMI = ( 1 << 1 ) ,
+ bmdVideoConnectionOpticalSDI = ( 1 << 2 ) ,
+ bmdVideoConnectionComponent = ( 1 << 3 ) ,
+ bmdVideoConnectionComposite = ( 1 << 4 ) ,
+ bmdVideoConnectionSVideo = ( 1 << 5 )
+ } BMDVideoConnection;
+
+/* [v1_enum] */
+enum _BMDAnalogVideoFlags
+ { bmdAnalogVideoFlagCompositeSetup75 = ( 1 << 0 ) ,
+ bmdAnalogVideoFlagComponentBetacamLevels = ( 1 << 1 )
+ } ;
+typedef /* [v1_enum] */
+enum _BMDAudioConnection
+ { bmdAudioConnectionEmbedded = 0x656d6264,
+ bmdAudioConnectionAESEBU = 0x61657320,
+ bmdAudioConnectionAnalog = 0x616e6c67
+ } BMDAudioConnection;
+
+typedef /* [v1_enum] */
+enum _BMDAudioOutputAnalogAESSwitch
+ { bmdAudioOutputSwitchAESEBU = 0x61657320,
+ bmdAudioOutputSwitchAnalog = 0x616e6c67
+ } BMDAudioOutputAnalogAESSwitch;
+
+typedef /* [v1_enum] */
+enum _BMDVideoOutputConversionMode
+ { bmdNoVideoOutputConversion = 0x6e6f6e65,
+ bmdVideoOutputLetterboxDownconversion = 0x6c746278,
+ bmdVideoOutputAnamorphicDownconversion = 0x616d7068,
+ bmdVideoOutputHD720toHD1080Conversion = 0x37323063,
+ bmdVideoOutputHardwareLetterboxDownconversion = 0x48576c62,
+ bmdVideoOutputHardwareAnamorphicDownconversion = 0x4857616d,
+ bmdVideoOutputHardwareCenterCutDownconversion = 0x48576363,
+ bmdVideoOutputHardware720p1080pCrossconversion = 0x78636170,
+ bmdVideoOutputHardwareAnamorphic720pUpconversion = 0x75613770,
+ bmdVideoOutputHardwareAnamorphic1080iUpconversion = 0x75613169,
+ bmdVideoOutputHardwareAnamorphic149To720pUpconversion = 0x75343770,
+ bmdVideoOutputHardwareAnamorphic149To1080iUpconversion = 0x75343169,
+ bmdVideoOutputHardwarePillarbox720pUpconversion = 0x75703770,
+ bmdVideoOutputHardwarePillarbox1080iUpconversion = 0x75703169
+ } BMDVideoOutputConversionMode;
+
+typedef /* [v1_enum] */
+enum _BMDVideoInputConversionMode
+ { bmdNoVideoInputConversion = 0x6e6f6e65,
+ bmdVideoInputLetterboxDownconversionFromHD1080 = 0x31306c62,
+ bmdVideoInputAnamorphicDownconversionFromHD1080 = 0x3130616d,
+ bmdVideoInputLetterboxDownconversionFromHD720 = 0x37326c62,
+ bmdVideoInputAnamorphicDownconversionFromHD720 = 0x3732616d,
+ bmdVideoInputLetterboxUpconversion = 0x6c627570,
+ bmdVideoInputAnamorphicUpconversion = 0x616d7570
+ } BMDVideoInputConversionMode;
+
+typedef /* [v1_enum] */
+enum _BMDVideo3DPackingFormat
+ { bmdVideo3DPackingSidebySideHalf = 0x73627368,
+ bmdVideo3DPackingLinebyLine = 0x6c62796c,
+ bmdVideo3DPackingTopAndBottom = 0x7461626f,
+ bmdVideo3DPackingFramePacking = 0x6672706b,
+ bmdVideo3DPackingLeftOnly = 0x6c656674,
+ bmdVideo3DPackingRightOnly = 0x72696768
+ } BMDVideo3DPackingFormat;
+
+typedef /* [v1_enum] */
+enum _BMDIdleVideoOutputOperation
+ { bmdIdleVideoOutputBlack = 0x626c6163,
+ bmdIdleVideoOutputLastFrame = 0x6c616661
+ } BMDIdleVideoOutputOperation;
+
+typedef /* [v1_enum] */
+enum _BMDDeckLinkConfigurationID
+ { bmdDeckLinkConfigSwapSerialRxTx = 0x73737274,
+ bmdDeckLinkConfigUse1080pNotPsF = 0x6670726f,
+ bmdDeckLinkConfigHDMI3DPackingFormat = 0x33647066,
+ bmdDeckLinkConfigBypass = 0x62797073,
+ bmdDeckLinkConfigAnalogAudioConsumerLevels = 0x6161636c,
+ bmdDeckLinkConfigFieldFlickerRemoval = 0x66646672,
+ bmdDeckLinkConfigHD1080p24ToHD1080i5994Conversion = 0x746f3539,
+ bmdDeckLinkConfig444SDIVideoOutput = 0x3434346f,
+ bmdDeckLinkConfig3GBpsVideoOutput = 0x33676273,
+ bmdDeckLinkConfigBlackVideoOutputDuringCapture = 0x62766f63,
+ bmdDeckLinkConfigLowLatencyVideoOutput = 0x6c6c766f,
+ bmdDeckLinkConfigVideoOutputConnection = 0x766f636e,
+ bmdDeckLinkConfigVideoOutputConversionMode = 0x766f636d,
+ bmdDeckLinkConfigAnalogVideoOutputFlags = 0x61766f66,
+ bmdDeckLinkConfigReferenceInputTimingOffset = 0x676c6f74,
+ bmdDeckLinkConfigVideoOutputIdleOperation = 0x766f696f,
+ bmdDeckLinkConfigVideoOutputComponentLumaGain = 0x6f636c67,
+ bmdDeckLinkConfigVideoOutputComponentChromaBlueGain = 0x6f636362,
+ bmdDeckLinkConfigVideoOutputComponentChromaRedGain = 0x6f636372,
+ bmdDeckLinkConfigVideoOutputCompositeLumaGain = 0x6f696c67,
+ bmdDeckLinkConfigVideoOutputCompositeChromaGain = 0x6f696367,
+ bmdDeckLinkConfigVideoOutputSVideoLumaGain = 0x6f736c67,
+ bmdDeckLinkConfigVideoOutputSVideoChromaGain = 0x6f736367,
+ bmdDeckLinkConfigVideoInputConnection = 0x7669636e,
+ bmdDeckLinkConfigAnalogVideoInputFlags = 0x61766966,
+ bmdDeckLinkConfigVideoInputConversionMode = 0x7669636d,
+ bmdDeckLinkConfig32PulldownSequenceInitialTimecodeFrame = 0x70646966,
+ bmdDeckLinkConfigVANCSourceLine1Mapping = 0x76736c31,
+ bmdDeckLinkConfigVANCSourceLine2Mapping = 0x76736c32,
+ bmdDeckLinkConfigVANCSourceLine3Mapping = 0x76736c33,
+ bmdDeckLinkConfigVideoInputComponentLumaGain = 0x69636c67,
+ bmdDeckLinkConfigVideoInputComponentChromaBlueGain = 0x69636362,
+ bmdDeckLinkConfigVideoInputComponentChromaRedGain = 0x69636372,
+ bmdDeckLinkConfigVideoInputCompositeLumaGain = 0x69696c67,
+ bmdDeckLinkConfigVideoInputCompositeChromaGain = 0x69696367,
+ bmdDeckLinkConfigVideoInputSVideoLumaGain = 0x69736c67,
+ bmdDeckLinkConfigVideoInputSVideoChromaGain = 0x69736367,
+ bmdDeckLinkConfigAudioInputConnection = 0x6169636e,
+ bmdDeckLinkConfigAnalogAudioInputScaleChannel1 = 0x61697331,
+ bmdDeckLinkConfigAnalogAudioInputScaleChannel2 = 0x61697332,
+ bmdDeckLinkConfigAnalogAudioInputScaleChannel3 = 0x61697333,
+ bmdDeckLinkConfigAnalogAudioInputScaleChannel4 = 0x61697334,
+ bmdDeckLinkConfigDigitalAudioInputScale = 0x64616973,
+ bmdDeckLinkConfigAudioOutputAESAnalogSwitch = 0x616f6161,
+ bmdDeckLinkConfigAnalogAudioOutputScaleChannel1 = 0x616f7331,
+ bmdDeckLinkConfigAnalogAudioOutputScaleChannel2 = 0x616f7332,
+ bmdDeckLinkConfigAnalogAudioOutputScaleChannel3 = 0x616f7333,
+ bmdDeckLinkConfigAnalogAudioOutputScaleChannel4 = 0x616f7334,
+ bmdDeckLinkConfigDigitalAudioOutputScale = 0x64616f73
+ } BMDDeckLinkConfigurationID;
+
+typedef /* [v1_enum] */
+enum _BMDDeckLinkAttributeID
+ { BMDDeckLinkSupportsInternalKeying = 0x6b657969,
+ BMDDeckLinkSupportsExternalKeying = 0x6b657965,
+ BMDDeckLinkSupportsHDKeying = 0x6b657968,
+ BMDDeckLinkSupportsInputFormatDetection = 0x696e6664,
+ BMDDeckLinkHasReferenceInput = 0x6872696e,
+ BMDDeckLinkHasSerialPort = 0x68737074,
+ BMDDeckLinkHasAnalogVideoOutputGain = 0x61766f67,
+ BMDDeckLinkCanOnlyAdjustOverallVideoOutputGain = 0x6f766f67,
+ BMDDeckLinkHasVideoInputAntiAliasingFilter = 0x6161666c,
+ BMDDeckLinkHasBypass = 0x62797073,
+ BMDDeckLinkMaximumAudioChannels = 0x6d616368,
+ BMDDeckLinkNumberOfSubDevices = 0x6e736264,
+ BMDDeckLinkSubDeviceIndex = 0x73756269,
+ BMDDeckLinkVideoOutputConnections = 0x766f636e,
+ BMDDeckLinkVideoInputConnections = 0x7669636e,
+ BMDDeckLinkVideoInputGainMinimum = 0x7669676d,
+ BMDDeckLinkVideoInputGainMaximum = 0x76696778,
+ BMDDeckLinkVideoOutputGainMinimum = 0x766f676d,
+ BMDDeckLinkVideoOutputGainMaximum = 0x766f6778,
+ BMDDeckLinkSerialPortDeviceName = 0x736c706e
+ } BMDDeckLinkAttributeID;
+
+typedef /* [v1_enum] */
+enum _BMDDeckLinkAPIInformationID
+ { BMDDeckLinkAPIVersion = 0x76657273
+ } BMDDeckLinkAPIInformationID;
+
+typedef /* [v1_enum] */
+enum _BMDDeckControlMode
+ { bmdDeckControlNotOpened = 0x6e746f70,
+ bmdDeckControlVTRControlMode = 0x76747263,
+ bmdDeckControlExportMode = 0x6578706d,
+ bmdDeckControlCaptureMode = 0x6361706d
+ } BMDDeckControlMode;
+
+typedef /* [v1_enum] */
+enum _BMDDeckControlEvent
+ { bmdDeckControlAbortedEvent = 0x61627465,
+ bmdDeckControlPrepareForExportEvent = 0x70666565,
+ bmdDeckControlExportCompleteEvent = 0x65786365,
+ bmdDeckControlPrepareForCaptureEvent = 0x70666365,
+ bmdDeckControlCaptureCompleteEvent = 0x63636576
+ } BMDDeckControlEvent;
+
+typedef /* [v1_enum] */
+enum _BMDDeckControlVTRControlState
+ { bmdDeckControlNotInVTRControlMode = 0x6e76636d,
+ bmdDeckControlVTRControlPlaying = 0x76747270,
+ bmdDeckControlVTRControlRecording = 0x76747272,
+ bmdDeckControlVTRControlStill = 0x76747261,
+ bmdDeckControlVTRControlSeeking = 0x76747273,
+ bmdDeckControlVTRControlStopped = 0x7674726f
+ } BMDDeckControlVTRControlState;
+
+/* [v1_enum] */
+enum _BMDDeckControlStatusFlags
+ { bmdDeckControlStatusDeckConnected = ( 1 << 0 ) ,
+ bmdDeckControlStatusRemoteMode = ( 1 << 1 ) ,
+ bmdDeckControlStatusRecordInhibited = ( 1 << 2 ) ,
+ bmdDeckControlStatusCassetteOut = ( 1 << 3 )
+ } ;
+/* [v1_enum] */
+enum _BMDDeckControlExportModeOpsFlags
+ { bmdDeckControlExportModeInsertVideo = ( 1 << 0 ) ,
+ bmdDeckControlExportModeInsertAudio1 = ( 1 << 1 ) ,
+ bmdDeckControlExportModeInsertAudio2 = ( 1 << 2 ) ,
+ bmdDeckControlExportModeInsertAudio3 = ( 1 << 3 ) ,
+ bmdDeckControlExportModeInsertAudio4 = ( 1 << 4 ) ,
+ bmdDeckControlExportModeInsertAudio5 = ( 1 << 5 ) ,
+ bmdDeckControlExportModeInsertAudio6 = ( 1 << 6 ) ,
+ bmdDeckControlExportModeInsertAudio7 = ( 1 << 7 ) ,
+ bmdDeckControlExportModeInsertAudio8 = ( 1 << 8 ) ,
+ bmdDeckControlExportModeInsertAudio9 = ( 1 << 9 ) ,
+ bmdDeckControlExportModeInsertAudio10 = ( 1 << 10 ) ,
+ bmdDeckControlExportModeInsertAudio11 = ( 1 << 11 ) ,
+ bmdDeckControlExportModeInsertAudio12 = ( 1 << 12 ) ,
+ bmdDeckControlExportModeInsertTimeCode = ( 1 << 13 ) ,
+ bmdDeckControlExportModeInsertAssemble = ( 1 << 14 ) ,
+ bmdDeckControlExportModeInsertPreview = ( 1 << 15 ) ,
+ bmdDeckControlUseManualExport = ( 1 << 16 )
+ } ;
+typedef /* [v1_enum] */
+enum _BMDDeckControlError
+ { bmdDeckControlNoError = 0x6e6f6572,
+ bmdDeckControlModeError = 0x6d6f6572,
+ bmdDeckControlMissedInPointError = 0x6d696572,
+ bmdDeckControlDeckTimeoutError = 0x64746572,
+ bmdDeckControlCommandFailedError = 0x63666572,
+ bmdDeckControlDeviceAlreadyOpenedError = 0x64616c6f,
+ bmdDeckControlFailedToOpenDeviceError = 0x66646572,
+ bmdDeckControlInLocalModeError = 0x6c6d6572,
+ bmdDeckControlEndOfTapeError = 0x65746572,
+ bmdDeckControlUserAbortError = 0x75616572,
+ bmdDeckControlNoTapeInDeckError = 0x6e746572,
+ bmdDeckControlNoVideoFromCardError = 0x6e766663,
+ bmdDeckControlNoCommunicationError = 0x6e636f6d,
+ bmdDeckControlBufferTooSmallError = 0x6274736d,
+ bmdDeckControlBadChecksumError = 0x63686b73,
+ bmdDeckControlUnknownError = 0x756e6572
+ } BMDDeckControlError;
+
+typedef /* [v1_enum] */
+enum _BMD3DPreviewFormat
+ { bmd3DPreviewFormatDefault = 0x64656661,
+ bmd3DPreviewFormatLeftOnly = 0x6c656674,
+ bmd3DPreviewFormatRightOnly = 0x72696768,
+ bmd3DPreviewFormatSideBySide = 0x73696465,
+ bmd3DPreviewFormatTopBottom = 0x746f7062
+ } BMD3DPreviewFormat;
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+typedef /* [v1_enum] */
+enum _BMDVideoConnection_v7_6
+ { bmdVideoConnectionSDI_v7_6 = 0x73646920,
+ bmdVideoConnectionHDMI_v7_6 = 0x68646d69,
+ bmdVideoConnectionOpticalSDI_v7_6 = 0x6f707469,
+ bmdVideoConnectionComponent_v7_6 = 0x63706e74,
+ bmdVideoConnectionComposite_v7_6 = 0x636d7374,
+ bmdVideoConnectionSVideo_v7_6 = 0x73766964
+ } BMDVideoConnection_v7_6;
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+EXTERN_C const IID LIBID_DeckLinkAPI;
+
+#ifndef __IDeckLinkVideoOutputCallback_INTERFACE_DEFINED__
+#define __IDeckLinkVideoOutputCallback_INTERFACE_DEFINED__
+
+/* interface IDeckLinkVideoOutputCallback */
+/* [helpstring][uuid][object] */
+
+
+EXTERN_C const IID IID_IDeckLinkVideoOutputCallback;
+
+#if defined(__cplusplus) && !defined(CINTERFACE)
+
+ MIDL_INTERFACE("20AA5225-1958-47CB-820B-80A8D521A6EE")
+ IDeckLinkVideoOutputCallback : public IUnknown
+ {
+ public:
+ virtual HRESULT STDMETHODCALLTYPE ScheduledFrameCompleted(
+ /* [in] */ IDeckLinkVideoFrame *completedFrame,
+ /* [in] */ BMDOutputFrameCompletionResult result) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE ScheduledPlaybackHasStopped( void) = 0;
+
+ };
+
+#else /* C style interface */
+
+ typedef struct IDeckLinkVideoOutputCallbackVtbl
+ {
+ BEGIN_INTERFACE
+
+ HRESULT ( STDMETHODCALLTYPE *QueryInterface )(
+ IDeckLinkVideoOutputCallback * This,
+ /* [in] */ REFIID riid,
+ /* [iid_is][out] */
+ __RPC__deref_out void **ppvObject);
+
+ ULONG ( STDMETHODCALLTYPE *AddRef )(
+ IDeckLinkVideoOutputCallback * This);
+
+ ULONG ( STDMETHODCALLTYPE *Release )(
+ IDeckLinkVideoOutputCallback * This);
+
+ HRESULT ( STDMETHODCALLTYPE *ScheduledFrameCompleted )(
+ IDeckLinkVideoOutputCallback * This,
+ /* [in] */ IDeckLinkVideoFrame *completedFrame,
+ /* [in] */ BMDOutputFrameCompletionResult result);
+
+ HRESULT ( STDMETHODCALLTYPE *ScheduledPlaybackHasStopped )(
+ IDeckLinkVideoOutputCallback * This);
+
+ END_INTERFACE
+ } IDeckLinkVideoOutputCallbackVtbl;
+
+ interface IDeckLinkVideoOutputCallback
+ {
+ CONST_VTBL struct IDeckLinkVideoOutputCallbackVtbl *lpVtbl;
+ };
+
+
+
+#ifdef COBJMACROS
+
+
+#define IDeckLinkVideoOutputCallback_QueryInterface(This,riid,ppvObject) \
+ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) )
+
+#define IDeckLinkVideoOutputCallback_AddRef(This) \
+ ( (This)->lpVtbl -> AddRef(This) )
+
+#define IDeckLinkVideoOutputCallback_Release(This) \
+ ( (This)->lpVtbl -> Release(This) )
+
+
+#define IDeckLinkVideoOutputCallback_ScheduledFrameCompleted(This,completedFrame,result) \
+ ( (This)->lpVtbl -> ScheduledFrameCompleted(This,completedFrame,result) )
+
+#define IDeckLinkVideoOutputCallback_ScheduledPlaybackHasStopped(This) \
+ ( (This)->lpVtbl -> ScheduledPlaybackHasStopped(This) )
+
+#endif /* COBJMACROS */
+
+
+#endif /* C style interface */
+
+
+
+
+#endif /* __IDeckLinkVideoOutputCallback_INTERFACE_DEFINED__ */
+
+
+#ifndef __IDeckLinkInputCallback_INTERFACE_DEFINED__
+#define __IDeckLinkInputCallback_INTERFACE_DEFINED__
+
+/* interface IDeckLinkInputCallback */
+/* [helpstring][uuid][object] */
+
+
+EXTERN_C const IID IID_IDeckLinkInputCallback;
+
+#if defined(__cplusplus) && !defined(CINTERFACE)
+
+ MIDL_INTERFACE("DD04E5EC-7415-42AB-AE4A-E80C4DFC044A")
+ IDeckLinkInputCallback : public IUnknown
+ {
+ public:
+ virtual HRESULT STDMETHODCALLTYPE VideoInputFormatChanged(
+ /* [in] */ BMDVideoInputFormatChangedEvents notificationEvents,
+ /* [in] */ IDeckLinkDisplayMode *newDisplayMode,
+ /* [in] */ BMDDetectedVideoInputFormatFlags detectedSignalFlags) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE VideoInputFrameArrived(
+ /* [in] */ IDeckLinkVideoInputFrame *videoFrame,
+ /* [in] */ IDeckLinkAudioInputPacket *audioPacket) = 0;
+
+ };
+
+#else /* C style interface */
+
+ typedef struct IDeckLinkInputCallbackVtbl
+ {
+ BEGIN_INTERFACE
+
+ HRESULT ( STDMETHODCALLTYPE *QueryInterface )(
+ IDeckLinkInputCallback * This,
+ /* [in] */ REFIID riid,
+ /* [iid_is][out] */
+ __RPC__deref_out void **ppvObject);
+
+ ULONG ( STDMETHODCALLTYPE *AddRef )(
+ IDeckLinkInputCallback * This);
+
+ ULONG ( STDMETHODCALLTYPE *Release )(
+ IDeckLinkInputCallback * This);
+
+ HRESULT ( STDMETHODCALLTYPE *VideoInputFormatChanged )(
+ IDeckLinkInputCallback * This,
+ /* [in] */ BMDVideoInputFormatChangedEvents notificationEvents,
+ /* [in] */ IDeckLinkDisplayMode *newDisplayMode,
+ /* [in] */ BMDDetectedVideoInputFormatFlags detectedSignalFlags);
+
+ HRESULT ( STDMETHODCALLTYPE *VideoInputFrameArrived )(
+ IDeckLinkInputCallback * This,
+ /* [in] */ IDeckLinkVideoInputFrame *videoFrame,
+ /* [in] */ IDeckLinkAudioInputPacket *audioPacket);
+
+ END_INTERFACE
+ } IDeckLinkInputCallbackVtbl;
+
+ interface IDeckLinkInputCallback
+ {
+ CONST_VTBL struct IDeckLinkInputCallbackVtbl *lpVtbl;
+ };
+
+
+
+#ifdef COBJMACROS
+
+
+#define IDeckLinkInputCallback_QueryInterface(This,riid,ppvObject) \
+ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) )
+
+#define IDeckLinkInputCallback_AddRef(This) \
+ ( (This)->lpVtbl -> AddRef(This) )
+
+#define IDeckLinkInputCallback_Release(This) \
+ ( (This)->lpVtbl -> Release(This) )
+
+
+#define IDeckLinkInputCallback_VideoInputFormatChanged(This,notificationEvents,newDisplayMode,detectedSignalFlags) \
+ ( (This)->lpVtbl -> VideoInputFormatChanged(This,notificationEvents,newDisplayMode,detectedSignalFlags) )
+
+#define IDeckLinkInputCallback_VideoInputFrameArrived(This,videoFrame,audioPacket) \
+ ( (This)->lpVtbl -> VideoInputFrameArrived(This,videoFrame,audioPacket) )
+
+#endif /* COBJMACROS */
+
+
+#endif /* C style interface */
+
+
+
+
+#endif /* __IDeckLinkInputCallback_INTERFACE_DEFINED__ */
+
+
+#ifndef __IDeckLinkMemoryAllocator_INTERFACE_DEFINED__
+#define __IDeckLinkMemoryAllocator_INTERFACE_DEFINED__
+
+/* interface IDeckLinkMemoryAllocator */
+/* [helpstring][local][uuid][object] */
+
+
+EXTERN_C const IID IID_IDeckLinkMemoryAllocator;
+
+#if defined(__cplusplus) && !defined(CINTERFACE)
+
+ MIDL_INTERFACE("B36EB6E7-9D29-4AA8-92EF-843B87A289E8")
+ IDeckLinkMemoryAllocator : public IUnknown
+ {
+ public:
+ virtual HRESULT STDMETHODCALLTYPE AllocateBuffer(
+ /* [in] */ unsigned long bufferSize,
+ /* [out] */ void **allocatedBuffer) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE ReleaseBuffer(
+ /* [in] */ void *buffer) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE Commit( void) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE Decommit( void) = 0;
+
+ };
+
+#else /* C style interface */
+
+ typedef struct IDeckLinkMemoryAllocatorVtbl
+ {
+ BEGIN_INTERFACE
+
+ HRESULT ( STDMETHODCALLTYPE *QueryInterface )(
+ IDeckLinkMemoryAllocator * This,
+ /* [in] */ REFIID riid,
+ /* [iid_is][out] */
+ __RPC__deref_out void **ppvObject);
+
+ ULONG ( STDMETHODCALLTYPE *AddRef )(
+ IDeckLinkMemoryAllocator * This);
+
+ ULONG ( STDMETHODCALLTYPE *Release )(
+ IDeckLinkMemoryAllocator * This);
+
+ HRESULT ( STDMETHODCALLTYPE *AllocateBuffer )(
+ IDeckLinkMemoryAllocator * This,
+ /* [in] */ unsigned long bufferSize,
+ /* [out] */ void **allocatedBuffer);
+
+ HRESULT ( STDMETHODCALLTYPE *ReleaseBuffer )(
+ IDeckLinkMemoryAllocator * This,
+ /* [in] */ void *buffer);
+
+ HRESULT ( STDMETHODCALLTYPE *Commit )(
+ IDeckLinkMemoryAllocator * This);
+
+ HRESULT ( STDMETHODCALLTYPE *Decommit )(
+ IDeckLinkMemoryAllocator * This);
+
+ END_INTERFACE
+ } IDeckLinkMemoryAllocatorVtbl;
+
+ interface IDeckLinkMemoryAllocator
+ {
+ CONST_VTBL struct IDeckLinkMemoryAllocatorVtbl *lpVtbl;
+ };
+
+
+
+#ifdef COBJMACROS
+
+
+#define IDeckLinkMemoryAllocator_QueryInterface(This,riid,ppvObject) \
+ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) )
+
+#define IDeckLinkMemoryAllocator_AddRef(This) \
+ ( (This)->lpVtbl -> AddRef(This) )
+
+#define IDeckLinkMemoryAllocator_Release(This) \
+ ( (This)->lpVtbl -> Release(This) )
+
+
+#define IDeckLinkMemoryAllocator_AllocateBuffer(This,bufferSize,allocatedBuffer) \
+ ( (This)->lpVtbl -> AllocateBuffer(This,bufferSize,allocatedBuffer) )
+
+#define IDeckLinkMemoryAllocator_ReleaseBuffer(This,buffer) \
+ ( (This)->lpVtbl -> ReleaseBuffer(This,buffer) )
+
+#define IDeckLinkMemoryAllocator_Commit(This) \
+ ( (This)->lpVtbl -> Commit(This) )
+
+#define IDeckLinkMemoryAllocator_Decommit(This) \
+ ( (This)->lpVtbl -> Decommit(This) )
+
+#endif /* COBJMACROS */
+
+
+#endif /* C style interface */
+
+
+
+
+#endif /* __IDeckLinkMemoryAllocator_INTERFACE_DEFINED__ */
+
+
+#ifndef __IDeckLinkAudioOutputCallback_INTERFACE_DEFINED__
+#define __IDeckLinkAudioOutputCallback_INTERFACE_DEFINED__
+
+/* interface IDeckLinkAudioOutputCallback */
+/* [helpstring][local][uuid][object] */
+
+
+EXTERN_C const IID IID_IDeckLinkAudioOutputCallback;
+
+#if defined(__cplusplus) && !defined(CINTERFACE)
+
+ MIDL_INTERFACE("403C681B-7F46-4A12-B993-2BB127084EE6")
+ IDeckLinkAudioOutputCallback : public IUnknown
+ {
+ public:
+ virtual HRESULT STDMETHODCALLTYPE RenderAudioSamples(
+ /* [in] */ BOOL preroll) = 0;
+
+ };
+
+#else /* C style interface */
+
+ typedef struct IDeckLinkAudioOutputCallbackVtbl
+ {
+ BEGIN_INTERFACE
+
+ HRESULT ( STDMETHODCALLTYPE *QueryInterface )(
+ IDeckLinkAudioOutputCallback * This,
+ /* [in] */ REFIID riid,
+ /* [iid_is][out] */
+ __RPC__deref_out void **ppvObject);
+
+ ULONG ( STDMETHODCALLTYPE *AddRef )(
+ IDeckLinkAudioOutputCallback * This);
+
+ ULONG ( STDMETHODCALLTYPE *Release )(
+ IDeckLinkAudioOutputCallback * This);
+
+ HRESULT ( STDMETHODCALLTYPE *RenderAudioSamples )(
+ IDeckLinkAudioOutputCallback * This,
+ /* [in] */ BOOL preroll);
+
+ END_INTERFACE
+ } IDeckLinkAudioOutputCallbackVtbl;
+
+ interface IDeckLinkAudioOutputCallback
+ {
+ CONST_VTBL struct IDeckLinkAudioOutputCallbackVtbl *lpVtbl;
+ };
+
+
+
+#ifdef COBJMACROS
+
+
+#define IDeckLinkAudioOutputCallback_QueryInterface(This,riid,ppvObject) \
+ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) )
+
+#define IDeckLinkAudioOutputCallback_AddRef(This) \
+ ( (This)->lpVtbl -> AddRef(This) )
+
+#define IDeckLinkAudioOutputCallback_Release(This) \
+ ( (This)->lpVtbl -> Release(This) )
+
+
+#define IDeckLinkAudioOutputCallback_RenderAudioSamples(This,preroll) \
+ ( (This)->lpVtbl -> RenderAudioSamples(This,preroll) )
+
+#endif /* COBJMACROS */
+
+
+#endif /* C style interface */
+
+
+
+
+#endif /* __IDeckLinkAudioOutputCallback_INTERFACE_DEFINED__ */
+
+
+#ifndef __IDeckLinkIterator_INTERFACE_DEFINED__
+#define __IDeckLinkIterator_INTERFACE_DEFINED__
+
+/* interface IDeckLinkIterator */
+/* [helpstring][uuid][object] */
+
+
+EXTERN_C const IID IID_IDeckLinkIterator;
+
+#if defined(__cplusplus) && !defined(CINTERFACE)
+
+ MIDL_INTERFACE("74E936FC-CC28-4A67-81A0-1E94E52D4E69")
+ IDeckLinkIterator : public IUnknown
+ {
+ public:
+ virtual HRESULT STDMETHODCALLTYPE Next(
+ /* [out] */ IDeckLink **deckLinkInstance) = 0;
+
+ };
+
+#else /* C style interface */
+
+ typedef struct IDeckLinkIteratorVtbl
+ {
+ BEGIN_INTERFACE
+
+ HRESULT ( STDMETHODCALLTYPE *QueryInterface )(
+ IDeckLinkIterator * This,
+ /* [in] */ REFIID riid,
+ /* [iid_is][out] */
+ __RPC__deref_out void **ppvObject);
+
+ ULONG ( STDMETHODCALLTYPE *AddRef )(
+ IDeckLinkIterator * This);
+
+ ULONG ( STDMETHODCALLTYPE *Release )(
+ IDeckLinkIterator * This);
+
+ HRESULT ( STDMETHODCALLTYPE *Next )(
+ IDeckLinkIterator * This,
+ /* [out] */ IDeckLink **deckLinkInstance);
+
+ END_INTERFACE
+ } IDeckLinkIteratorVtbl;
+
+ interface IDeckLinkIterator
+ {
+ CONST_VTBL struct IDeckLinkIteratorVtbl *lpVtbl;
+ };
+
+
+
+#ifdef COBJMACROS
+
+
+#define IDeckLinkIterator_QueryInterface(This,riid,ppvObject) \
+ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) )
+
+#define IDeckLinkIterator_AddRef(This) \
+ ( (This)->lpVtbl -> AddRef(This) )
+
+#define IDeckLinkIterator_Release(This) \
+ ( (This)->lpVtbl -> Release(This) )
+
+
+#define IDeckLinkIterator_Next(This,deckLinkInstance) \
+ ( (This)->lpVtbl -> Next(This,deckLinkInstance) )
+
+#endif /* COBJMACROS */
+
+
+#endif /* C style interface */
+
+
+
+
+#endif /* __IDeckLinkIterator_INTERFACE_DEFINED__ */
+
+
+#ifndef __IDeckLinkAPIInformation_INTERFACE_DEFINED__
+#define __IDeckLinkAPIInformation_INTERFACE_DEFINED__
+
+/* interface IDeckLinkAPIInformation */
+/* [helpstring][uuid][object] */
+
+
+EXTERN_C const IID IID_IDeckLinkAPIInformation;
+
+#if defined(__cplusplus) && !defined(CINTERFACE)
+
+ MIDL_INTERFACE("7BEA3C68-730D-4322-AF34-8A7152B532A4")
+ IDeckLinkAPIInformation : public IUnknown
+ {
+ public:
+ virtual HRESULT STDMETHODCALLTYPE GetFlag(
+ /* [in] */ BMDDeckLinkAPIInformationID cfgID,
+ /* [out] */ BOOL *value) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE GetInt(
+ /* [in] */ BMDDeckLinkAPIInformationID cfgID,
+ /* [out] */ LONGLONG *value) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE GetFloat(
+ /* [in] */ BMDDeckLinkAPIInformationID cfgID,
+ /* [out] */ double *value) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE GetString(
+ /* [in] */ BMDDeckLinkAPIInformationID cfgID,
+ /* [out] */ BSTR *value) = 0;
+
+ };
+
+#else /* C style interface */
+
+ typedef struct IDeckLinkAPIInformationVtbl
+ {
+ BEGIN_INTERFACE
+
+ HRESULT ( STDMETHODCALLTYPE *QueryInterface )(
+ IDeckLinkAPIInformation * This,
+ /* [in] */ REFIID riid,
+ /* [iid_is][out] */
+ __RPC__deref_out void **ppvObject);
+
+ ULONG ( STDMETHODCALLTYPE *AddRef )(
+ IDeckLinkAPIInformation * This);
+
+ ULONG ( STDMETHODCALLTYPE *Release )(
+ IDeckLinkAPIInformation * This);
+
+ HRESULT ( STDMETHODCALLTYPE *GetFlag )(
+ IDeckLinkAPIInformation * This,
+ /* [in] */ BMDDeckLinkAPIInformationID cfgID,
+ /* [out] */ BOOL *value);
+
+ HRESULT ( STDMETHODCALLTYPE *GetInt )(
+ IDeckLinkAPIInformation * This,
+ /* [in] */ BMDDeckLinkAPIInformationID cfgID,
+ /* [out] */ LONGLONG *value);
+
+ HRESULT ( STDMETHODCALLTYPE *GetFloat )(
+ IDeckLinkAPIInformation * This,
+ /* [in] */ BMDDeckLinkAPIInformationID cfgID,
+ /* [out] */ double *value);
+
+ HRESULT ( STDMETHODCALLTYPE *GetString )(
+ IDeckLinkAPIInformation * This,
+ /* [in] */ BMDDeckLinkAPIInformationID cfgID,
+ /* [out] */ BSTR *value);
+
+ END_INTERFACE
+ } IDeckLinkAPIInformationVtbl;
+
+ interface IDeckLinkAPIInformation
+ {
+ CONST_VTBL struct IDeckLinkAPIInformationVtbl *lpVtbl;
+ };
+
+
+
+#ifdef COBJMACROS
+
+
+#define IDeckLinkAPIInformation_QueryInterface(This,riid,ppvObject) \
+ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) )
+
+#define IDeckLinkAPIInformation_AddRef(This) \
+ ( (This)->lpVtbl -> AddRef(This) )
+
+#define IDeckLinkAPIInformation_Release(This) \
+ ( (This)->lpVtbl -> Release(This) )
+
+
+#define IDeckLinkAPIInformation_GetFlag(This,cfgID,value) \
+ ( (This)->lpVtbl -> GetFlag(This,cfgID,value) )
+
+#define IDeckLinkAPIInformation_GetInt(This,cfgID,value) \
+ ( (This)->lpVtbl -> GetInt(This,cfgID,value) )
+
+#define IDeckLinkAPIInformation_GetFloat(This,cfgID,value) \
+ ( (This)->lpVtbl -> GetFloat(This,cfgID,value) )
+
+#define IDeckLinkAPIInformation_GetString(This,cfgID,value) \
+ ( (This)->lpVtbl -> GetString(This,cfgID,value) )
+
+#endif /* COBJMACROS */
+
+
+#endif /* C style interface */
+
+
+
+
+#endif /* __IDeckLinkAPIInformation_INTERFACE_DEFINED__ */
+
+
+#ifndef __IDeckLinkDisplayModeIterator_INTERFACE_DEFINED__
+#define __IDeckLinkDisplayModeIterator_INTERFACE_DEFINED__
+
+/* interface IDeckLinkDisplayModeIterator */
+/* [helpstring][uuid][object] */
+
+
+EXTERN_C const IID IID_IDeckLinkDisplayModeIterator;
+
+#if defined(__cplusplus) && !defined(CINTERFACE)
+
+ MIDL_INTERFACE("9C88499F-F601-4021-B80B-032E4EB41C35")
+ IDeckLinkDisplayModeIterator : public IUnknown
+ {
+ public:
+ virtual HRESULT STDMETHODCALLTYPE Next(
+ /* [out] */ IDeckLinkDisplayMode **deckLinkDisplayMode) = 0;
+
+ };
+
+#else /* C style interface */
+
+ typedef struct IDeckLinkDisplayModeIteratorVtbl
+ {
+ BEGIN_INTERFACE
+
+ HRESULT ( STDMETHODCALLTYPE *QueryInterface )(
+ IDeckLinkDisplayModeIterator * This,
+ /* [in] */ REFIID riid,
+ /* [iid_is][out] */
+ __RPC__deref_out void **ppvObject);
+
+ ULONG ( STDMETHODCALLTYPE *AddRef )(
+ IDeckLinkDisplayModeIterator * This);
+
+ ULONG ( STDMETHODCALLTYPE *Release )(
+ IDeckLinkDisplayModeIterator * This);
+
+ HRESULT ( STDMETHODCALLTYPE *Next )(
+ IDeckLinkDisplayModeIterator * This,
+ /* [out] */ IDeckLinkDisplayMode **deckLinkDisplayMode);
+
+ END_INTERFACE
+ } IDeckLinkDisplayModeIteratorVtbl;
+
+ interface IDeckLinkDisplayModeIterator
+ {
+ CONST_VTBL struct IDeckLinkDisplayModeIteratorVtbl *lpVtbl;
+ };
+
+
+
+#ifdef COBJMACROS
+
+
+#define IDeckLinkDisplayModeIterator_QueryInterface(This,riid,ppvObject) \
+ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) )
+
+#define IDeckLinkDisplayModeIterator_AddRef(This) \
+ ( (This)->lpVtbl -> AddRef(This) )
+
+#define IDeckLinkDisplayModeIterator_Release(This) \
+ ( (This)->lpVtbl -> Release(This) )
+
+
+#define IDeckLinkDisplayModeIterator_Next(This,deckLinkDisplayMode) \
+ ( (This)->lpVtbl -> Next(This,deckLinkDisplayMode) )
+
+#endif /* COBJMACROS */
+
+
+#endif /* C style interface */
+
+
+
+
+#endif /* __IDeckLinkDisplayModeIterator_INTERFACE_DEFINED__ */
+
+
+#ifndef __IDeckLinkDisplayMode_INTERFACE_DEFINED__
+#define __IDeckLinkDisplayMode_INTERFACE_DEFINED__
+
+/* interface IDeckLinkDisplayMode */
+/* [helpstring][uuid][object] */
+
+
+EXTERN_C const IID IID_IDeckLinkDisplayMode;
+
+#if defined(__cplusplus) && !defined(CINTERFACE)
+
+ MIDL_INTERFACE("3EB2C1AB-0A3D-4523-A3AD-F40D7FB14E78")
+ IDeckLinkDisplayMode : public IUnknown
+ {
+ public:
+ virtual HRESULT STDMETHODCALLTYPE GetName(
+ /* [out] */ BSTR *name) = 0;
+
+ virtual BMDDisplayMode STDMETHODCALLTYPE GetDisplayMode( void) = 0;
+
+ virtual long STDMETHODCALLTYPE GetWidth( void) = 0;
+
+ virtual long STDMETHODCALLTYPE GetHeight( void) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE GetFrameRate(
+ /* [out] */ BMDTimeValue *frameDuration,
+ /* [out] */ BMDTimeScale *timeScale) = 0;
+
+ virtual BMDFieldDominance STDMETHODCALLTYPE GetFieldDominance( void) = 0;
+
+ virtual BMDDisplayModeFlags STDMETHODCALLTYPE GetFlags( void) = 0;
+
+ };
+
+#else /* C style interface */
+
+ typedef struct IDeckLinkDisplayModeVtbl
+ {
+ BEGIN_INTERFACE
+
+ HRESULT ( STDMETHODCALLTYPE *QueryInterface )(
+ IDeckLinkDisplayMode * This,
+ /* [in] */ REFIID riid,
+ /* [iid_is][out] */
+ __RPC__deref_out void **ppvObject);
+
+ ULONG ( STDMETHODCALLTYPE *AddRef )(
+ IDeckLinkDisplayMode * This);
+
+ ULONG ( STDMETHODCALLTYPE *Release )(
+ IDeckLinkDisplayMode * This);
+
+ HRESULT ( STDMETHODCALLTYPE *GetName )(
+ IDeckLinkDisplayMode * This,
+ /* [out] */ BSTR *name);
+
+ BMDDisplayMode ( STDMETHODCALLTYPE *GetDisplayMode )(
+ IDeckLinkDisplayMode * This);
+
+ long ( STDMETHODCALLTYPE *GetWidth )(
+ IDeckLinkDisplayMode * This);
+
+ long ( STDMETHODCALLTYPE *GetHeight )(
+ IDeckLinkDisplayMode * This);
+
+ HRESULT ( STDMETHODCALLTYPE *GetFrameRate )(
+ IDeckLinkDisplayMode * This,
+ /* [out] */ BMDTimeValue *frameDuration,
+ /* [out] */ BMDTimeScale *timeScale);
+
+ BMDFieldDominance ( STDMETHODCALLTYPE *GetFieldDominance )(
+ IDeckLinkDisplayMode * This);
+
+ BMDDisplayModeFlags ( STDMETHODCALLTYPE *GetFlags )(
+ IDeckLinkDisplayMode * This);
+
+ END_INTERFACE
+ } IDeckLinkDisplayModeVtbl;
+
+ interface IDeckLinkDisplayMode
+ {
+ CONST_VTBL struct IDeckLinkDisplayModeVtbl *lpVtbl;
+ };
+
+
+
+#ifdef COBJMACROS
+
+
+#define IDeckLinkDisplayMode_QueryInterface(This,riid,ppvObject) \
+ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) )
+
+#define IDeckLinkDisplayMode_AddRef(This) \
+ ( (This)->lpVtbl -> AddRef(This) )
+
+#define IDeckLinkDisplayMode_Release(This) \
+ ( (This)->lpVtbl -> Release(This) )
+
+
+#define IDeckLinkDisplayMode_GetName(This,name) \
+ ( (This)->lpVtbl -> GetName(This,name) )
+
+#define IDeckLinkDisplayMode_GetDisplayMode(This) \
+ ( (This)->lpVtbl -> GetDisplayMode(This) )
+
+#define IDeckLinkDisplayMode_GetWidth(This) \
+ ( (This)->lpVtbl -> GetWidth(This) )
+
+#define IDeckLinkDisplayMode_GetHeight(This) \
+ ( (This)->lpVtbl -> GetHeight(This) )
+
+#define IDeckLinkDisplayMode_GetFrameRate(This,frameDuration,timeScale) \
+ ( (This)->lpVtbl -> GetFrameRate(This,frameDuration,timeScale) )
+
+#define IDeckLinkDisplayMode_GetFieldDominance(This) \
+ ( (This)->lpVtbl -> GetFieldDominance(This) )
+
+#define IDeckLinkDisplayMode_GetFlags(This) \
+ ( (This)->lpVtbl -> GetFlags(This) )
+
+#endif /* COBJMACROS */
+
+
+#endif /* C style interface */
+
+
+
+
+#endif /* __IDeckLinkDisplayMode_INTERFACE_DEFINED__ */
+
+
+#ifndef __IDeckLink_INTERFACE_DEFINED__
+#define __IDeckLink_INTERFACE_DEFINED__
+
+/* interface IDeckLink */
+/* [helpstring][uuid][object] */
+
+
+EXTERN_C const IID IID_IDeckLink;
+
+#if defined(__cplusplus) && !defined(CINTERFACE)
+
+ MIDL_INTERFACE("62BFF75D-6569-4E55-8D4D-66AA03829ABC")
+ IDeckLink : public IUnknown
+ {
+ public:
+ virtual HRESULT STDMETHODCALLTYPE GetModelName(
+ /* [out] */ BSTR *modelName) = 0;
+
+ };
+
+#else /* C style interface */
+
+ typedef struct IDeckLinkVtbl
+ {
+ BEGIN_INTERFACE
+
+ HRESULT ( STDMETHODCALLTYPE *QueryInterface )(
+ IDeckLink * This,
+ /* [in] */ REFIID riid,
+ /* [iid_is][out] */
+ __RPC__deref_out void **ppvObject);
+
+ ULONG ( STDMETHODCALLTYPE *AddRef )(
+ IDeckLink * This);
+
+ ULONG ( STDMETHODCALLTYPE *Release )(
+ IDeckLink * This);
+
+ HRESULT ( STDMETHODCALLTYPE *GetModelName )(
+ IDeckLink * This,
+ /* [out] */ BSTR *modelName);
+
+ END_INTERFACE
+ } IDeckLinkVtbl;
+
+ interface IDeckLink
+ {
+ CONST_VTBL struct IDeckLinkVtbl *lpVtbl;
+ };
+
+
+
+#ifdef COBJMACROS
+
+
+#define IDeckLink_QueryInterface(This,riid,ppvObject) \
+ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) )
+
+#define IDeckLink_AddRef(This) \
+ ( (This)->lpVtbl -> AddRef(This) )
+
+#define IDeckLink_Release(This) \
+ ( (This)->lpVtbl -> Release(This) )
+
+
+#define IDeckLink_GetModelName(This,modelName) \
+ ( (This)->lpVtbl -> GetModelName(This,modelName) )
+
+#endif /* COBJMACROS */
+
+
+#endif /* C style interface */
+
+
+
+
+#endif /* __IDeckLink_INTERFACE_DEFINED__ */
+
+
+#ifndef __IDeckLinkOutput_INTERFACE_DEFINED__
+#define __IDeckLinkOutput_INTERFACE_DEFINED__
+
+/* interface IDeckLinkOutput */
+/* [helpstring][local][uuid][object] */
+
+
+EXTERN_C const IID IID_IDeckLinkOutput;
+
+#if defined(__cplusplus) && !defined(CINTERFACE)
+
+ MIDL_INTERFACE("A3EF0963-0862-44ED-92A9-EE89ABF431C7")
+ IDeckLinkOutput : public IUnknown
+ {
+ public:
+ virtual HRESULT STDMETHODCALLTYPE DoesSupportVideoMode(
+ /* [in] */ BMDDisplayMode displayMode,
+ /* [in] */ BMDPixelFormat pixelFormat,
+ /* [in] */ BMDVideoOutputFlags flags,
+ /* [out] */ BMDDisplayModeSupport *result,
+ /* [out] */ IDeckLinkDisplayMode **resultDisplayMode) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE GetDisplayModeIterator(
+ /* [out] */ IDeckLinkDisplayModeIterator **iterator) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE SetScreenPreviewCallback(
+ /* [in] */ IDeckLinkScreenPreviewCallback *previewCallback) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE EnableVideoOutput(
+ /* [in] */ BMDDisplayMode displayMode,
+ /* [in] */ BMDVideoOutputFlags flags) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE DisableVideoOutput( void) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE SetVideoOutputFrameMemoryAllocator(
+ /* [in] */ IDeckLinkMemoryAllocator *theAllocator) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE CreateVideoFrame(
+ /* [in] */ long width,
+ /* [in] */ long height,
+ /* [in] */ long rowBytes,
+ /* [in] */ BMDPixelFormat pixelFormat,
+ /* [in] */ BMDFrameFlags flags,
+ /* [out] */ IDeckLinkMutableVideoFrame **outFrame) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE CreateAncillaryData(
+ /* [in] */ BMDPixelFormat pixelFormat,
+ /* [out] */ IDeckLinkVideoFrameAncillary **outBuffer) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE DisplayVideoFrameSync(
+ /* [in] */ IDeckLinkVideoFrame *theFrame) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE ScheduleVideoFrame(
+ /* [in] */ IDeckLinkVideoFrame *theFrame,
+ /* [in] */ BMDTimeValue displayTime,
+ /* [in] */ BMDTimeValue displayDuration,
+ /* [in] */ BMDTimeScale timeScale) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE SetScheduledFrameCompletionCallback(
+ /* [in] */ IDeckLinkVideoOutputCallback *theCallback) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE GetBufferedVideoFrameCount(
+ /* [out] */ unsigned long *bufferedFrameCount) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE EnableAudioOutput(
+ /* [in] */ BMDAudioSampleRate sampleRate,
+ /* [in] */ BMDAudioSampleType sampleType,
+ /* [in] */ unsigned long channelCount,
+ /* [in] */ BMDAudioOutputStreamType streamType) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE DisableAudioOutput( void) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE WriteAudioSamplesSync(
+ /* [in] */ void *buffer,
+ /* [in] */ unsigned long sampleFrameCount,
+ /* [out] */ unsigned long *sampleFramesWritten) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE BeginAudioPreroll( void) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE EndAudioPreroll( void) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE ScheduleAudioSamples(
+ /* [in] */ void *buffer,
+ /* [in] */ unsigned long sampleFrameCount,
+ /* [in] */ BMDTimeValue streamTime,
+ /* [in] */ BMDTimeScale timeScale,
+ /* [out] */ unsigned long *sampleFramesWritten) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE GetBufferedAudioSampleFrameCount(
+ /* [out] */ unsigned long *bufferedSampleFrameCount) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE FlushBufferedAudioSamples( void) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE SetAudioCallback(
+ /* [in] */ IDeckLinkAudioOutputCallback *theCallback) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE StartScheduledPlayback(
+ /* [in] */ BMDTimeValue playbackStartTime,
+ /* [in] */ BMDTimeScale timeScale,
+ /* [in] */ double playbackSpeed) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE StopScheduledPlayback(
+ /* [in] */ BMDTimeValue stopPlaybackAtTime,
+ /* [out] */ BMDTimeValue *actualStopTime,
+ /* [in] */ BMDTimeScale timeScale) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE IsScheduledPlaybackRunning(
+ /* [out] */ BOOL *active) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE GetScheduledStreamTime(
+ /* [in] */ BMDTimeScale desiredTimeScale,
+ /* [out] */ BMDTimeValue *streamTime,
+ /* [out] */ double *playbackSpeed) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE GetReferenceStatus(
+ /* [out] */ BMDReferenceStatus *referenceStatus) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE GetHardwareReferenceClock(
+ /* [in] */ BMDTimeScale desiredTimeScale,
+ /* [out] */ BMDTimeValue *hardwareTime,
+ /* [out] */ BMDTimeValue *timeInFrame,
+ /* [out] */ BMDTimeValue *ticksPerFrame) = 0;
+
+ };
+
+#else /* C style interface */
+
+ typedef struct IDeckLinkOutputVtbl
+ {
+ BEGIN_INTERFACE
+
+ HRESULT ( STDMETHODCALLTYPE *QueryInterface )(
+ IDeckLinkOutput * This,
+ /* [in] */ REFIID riid,
+ /* [iid_is][out] */
+ __RPC__deref_out void **ppvObject);
+
+ ULONG ( STDMETHODCALLTYPE *AddRef )(
+ IDeckLinkOutput * This);
+
+ ULONG ( STDMETHODCALLTYPE *Release )(
+ IDeckLinkOutput * This);
+
+ HRESULT ( STDMETHODCALLTYPE *DoesSupportVideoMode )(
+ IDeckLinkOutput * This,
+ /* [in] */ BMDDisplayMode displayMode,
+ /* [in] */ BMDPixelFormat pixelFormat,
+ /* [in] */ BMDVideoOutputFlags flags,
+ /* [out] */ BMDDisplayModeSupport *result,
+ /* [out] */ IDeckLinkDisplayMode **resultDisplayMode);
+
+ HRESULT ( STDMETHODCALLTYPE *GetDisplayModeIterator )(
+ IDeckLinkOutput * This,
+ /* [out] */ IDeckLinkDisplayModeIterator **iterator);
+
+ HRESULT ( STDMETHODCALLTYPE *SetScreenPreviewCallback )(
+ IDeckLinkOutput * This,
+ /* [in] */ IDeckLinkScreenPreviewCallback *previewCallback);
+
+ HRESULT ( STDMETHODCALLTYPE *EnableVideoOutput )(
+ IDeckLinkOutput * This,
+ /* [in] */ BMDDisplayMode displayMode,
+ /* [in] */ BMDVideoOutputFlags flags);
+
+ HRESULT ( STDMETHODCALLTYPE *DisableVideoOutput )(
+ IDeckLinkOutput * This);
+
+ HRESULT ( STDMETHODCALLTYPE *SetVideoOutputFrameMemoryAllocator )(
+ IDeckLinkOutput * This,
+ /* [in] */ IDeckLinkMemoryAllocator *theAllocator);
+
+ HRESULT ( STDMETHODCALLTYPE *CreateVideoFrame )(
+ IDeckLinkOutput * This,
+ /* [in] */ long width,
+ /* [in] */ long height,
+ /* [in] */ long rowBytes,
+ /* [in] */ BMDPixelFormat pixelFormat,
+ /* [in] */ BMDFrameFlags flags,
+ /* [out] */ IDeckLinkMutableVideoFrame **outFrame);
+
+ HRESULT ( STDMETHODCALLTYPE *CreateAncillaryData )(
+ IDeckLinkOutput * This,
+ /* [in] */ BMDPixelFormat pixelFormat,
+ /* [out] */ IDeckLinkVideoFrameAncillary **outBuffer);
+
+ HRESULT ( STDMETHODCALLTYPE *DisplayVideoFrameSync )(
+ IDeckLinkOutput * This,
+ /* [in] */ IDeckLinkVideoFrame *theFrame);
+
+ HRESULT ( STDMETHODCALLTYPE *ScheduleVideoFrame )(
+ IDeckLinkOutput * This,
+ /* [in] */ IDeckLinkVideoFrame *theFrame,
+ /* [in] */ BMDTimeValue displayTime,
+ /* [in] */ BMDTimeValue displayDuration,
+ /* [in] */ BMDTimeScale timeScale);
+
+ HRESULT ( STDMETHODCALLTYPE *SetScheduledFrameCompletionCallback )(
+ IDeckLinkOutput * This,
+ /* [in] */ IDeckLinkVideoOutputCallback *theCallback);
+
+ HRESULT ( STDMETHODCALLTYPE *GetBufferedVideoFrameCount )(
+ IDeckLinkOutput * This,
+ /* [out] */ unsigned long *bufferedFrameCount);
+
+ HRESULT ( STDMETHODCALLTYPE *EnableAudioOutput )(
+ IDeckLinkOutput * This,
+ /* [in] */ BMDAudioSampleRate sampleRate,
+ /* [in] */ BMDAudioSampleType sampleType,
+ /* [in] */ unsigned long channelCount,
+ /* [in] */ BMDAudioOutputStreamType streamType);
+
+ HRESULT ( STDMETHODCALLTYPE *DisableAudioOutput )(
+ IDeckLinkOutput * This);
+
+ HRESULT ( STDMETHODCALLTYPE *WriteAudioSamplesSync )(
+ IDeckLinkOutput * This,
+ /* [in] */ void *buffer,
+ /* [in] */ unsigned long sampleFrameCount,
+ /* [out] */ unsigned long *sampleFramesWritten);
+
+ HRESULT ( STDMETHODCALLTYPE *BeginAudioPreroll )(
+ IDeckLinkOutput * This);
+
+ HRESULT ( STDMETHODCALLTYPE *EndAudioPreroll )(
+ IDeckLinkOutput * This);
+
+ HRESULT ( STDMETHODCALLTYPE *ScheduleAudioSamples )(
+ IDeckLinkOutput * This,
+ /* [in] */ void *buffer,
+ /* [in] */ unsigned long sampleFrameCount,
+ /* [in] */ BMDTimeValue streamTime,
+ /* [in] */ BMDTimeScale timeScale,
+ /* [out] */ unsigned long *sampleFramesWritten);
+
+ HRESULT ( STDMETHODCALLTYPE *GetBufferedAudioSampleFrameCount )(
+ IDeckLinkOutput * This,
+ /* [out] */ unsigned long *bufferedSampleFrameCount);
+
+ HRESULT ( STDMETHODCALLTYPE *FlushBufferedAudioSamples )(
+ IDeckLinkOutput * This);
+
+ HRESULT ( STDMETHODCALLTYPE *SetAudioCallback )(
+ IDeckLinkOutput * This,
+ /* [in] */ IDeckLinkAudioOutputCallback *theCallback);
+
+ HRESULT ( STDMETHODCALLTYPE *StartScheduledPlayback )(
+ IDeckLinkOutput * This,
+ /* [in] */ BMDTimeValue playbackStartTime,
+ /* [in] */ BMDTimeScale timeScale,
+ /* [in] */ double playbackSpeed);
+
+ HRESULT ( STDMETHODCALLTYPE *StopScheduledPlayback )(
+ IDeckLinkOutput * This,
+ /* [in] */ BMDTimeValue stopPlaybackAtTime,
+ /* [out] */ BMDTimeValue *actualStopTime,
+ /* [in] */ BMDTimeScale timeScale);
+
+ HRESULT ( STDMETHODCALLTYPE *IsScheduledPlaybackRunning )(
+ IDeckLinkOutput * This,
+ /* [out] */ BOOL *active);
+
+ HRESULT ( STDMETHODCALLTYPE *GetScheduledStreamTime )(
+ IDeckLinkOutput * This,
+ /* [in] */ BMDTimeScale desiredTimeScale,
+ /* [out] */ BMDTimeValue *streamTime,
+ /* [out] */ double *playbackSpeed);
+
+ HRESULT ( STDMETHODCALLTYPE *GetReferenceStatus )(
+ IDeckLinkOutput * This,
+ /* [out] */ BMDReferenceStatus *referenceStatus);
+
+ HRESULT ( STDMETHODCALLTYPE *GetHardwareReferenceClock )(
+ IDeckLinkOutput * This,
+ /* [in] */ BMDTimeScale desiredTimeScale,
+ /* [out] */ BMDTimeValue *hardwareTime,
+ /* [out] */ BMDTimeValue *timeInFrame,
+ /* [out] */ BMDTimeValue *ticksPerFrame);
+
+ END_INTERFACE
+ } IDeckLinkOutputVtbl;
+
+ interface IDeckLinkOutput
+ {
+ CONST_VTBL struct IDeckLinkOutputVtbl *lpVtbl;
+ };
+
+
+
+#ifdef COBJMACROS
+
+
+#define IDeckLinkOutput_QueryInterface(This,riid,ppvObject) \
+ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) )
+
+#define IDeckLinkOutput_AddRef(This) \
+ ( (This)->lpVtbl -> AddRef(This) )
+
+#define IDeckLinkOutput_Release(This) \
+ ( (This)->lpVtbl -> Release(This) )
+
+
+#define IDeckLinkOutput_DoesSupportVideoMode(This,displayMode,pixelFormat,flags,result,resultDisplayMode) \
+ ( (This)->lpVtbl -> DoesSupportVideoMode(This,displayMode,pixelFormat,flags,result,resultDisplayMode) )
+
+#define IDeckLinkOutput_GetDisplayModeIterator(This,iterator) \
+ ( (This)->lpVtbl -> GetDisplayModeIterator(This,iterator) )
+
+#define IDeckLinkOutput_SetScreenPreviewCallback(This,previewCallback) \
+ ( (This)->lpVtbl -> SetScreenPreviewCallback(This,previewCallback) )
+
+#define IDeckLinkOutput_EnableVideoOutput(This,displayMode,flags) \
+ ( (This)->lpVtbl -> EnableVideoOutput(This,displayMode,flags) )
+
+#define IDeckLinkOutput_DisableVideoOutput(This) \
+ ( (This)->lpVtbl -> DisableVideoOutput(This) )
+
+#define IDeckLinkOutput_SetVideoOutputFrameMemoryAllocator(This,theAllocator) \
+ ( (This)->lpVtbl -> SetVideoOutputFrameMemoryAllocator(This,theAllocator) )
+
+#define IDeckLinkOutput_CreateVideoFrame(This,width,height,rowBytes,pixelFormat,flags,outFrame) \
+ ( (This)->lpVtbl -> CreateVideoFrame(This,width,height,rowBytes,pixelFormat,flags,outFrame) )
+
+#define IDeckLinkOutput_CreateAncillaryData(This,pixelFormat,outBuffer) \
+ ( (This)->lpVtbl -> CreateAncillaryData(This,pixelFormat,outBuffer) )
+
+#define IDeckLinkOutput_DisplayVideoFrameSync(This,theFrame) \
+ ( (This)->lpVtbl -> DisplayVideoFrameSync(This,theFrame) )
+
+#define IDeckLinkOutput_ScheduleVideoFrame(This,theFrame,displayTime,displayDuration,timeScale) \
+ ( (This)->lpVtbl -> ScheduleVideoFrame(This,theFrame,displayTime,displayDuration,timeScale) )
+
+#define IDeckLinkOutput_SetScheduledFrameCompletionCallback(This,theCallback) \
+ ( (This)->lpVtbl -> SetScheduledFrameCompletionCallback(This,theCallback) )
+
+#define IDeckLinkOutput_GetBufferedVideoFrameCount(This,bufferedFrameCount) \
+ ( (This)->lpVtbl -> GetBufferedVideoFrameCount(This,bufferedFrameCount) )
+
+#define IDeckLinkOutput_EnableAudioOutput(This,sampleRate,sampleType,channelCount,streamType) \
+ ( (This)->lpVtbl -> EnableAudioOutput(This,sampleRate,sampleType,channelCount,streamType) )
+
+#define IDeckLinkOutput_DisableAudioOutput(This) \
+ ( (This)->lpVtbl -> DisableAudioOutput(This) )
+
+#define IDeckLinkOutput_WriteAudioSamplesSync(This,buffer,sampleFrameCount,sampleFramesWritten) \
+ ( (This)->lpVtbl -> WriteAudioSamplesSync(This,buffer,sampleFrameCount,sampleFramesWritten) )
+
+#define IDeckLinkOutput_BeginAudioPreroll(This) \
+ ( (This)->lpVtbl -> BeginAudioPreroll(This) )
+
+#define IDeckLinkOutput_EndAudioPreroll(This) \
+ ( (This)->lpVtbl -> EndAudioPreroll(This) )
+
+#define IDeckLinkOutput_ScheduleAudioSamples(This,buffer,sampleFrameCount,streamTime,timeScale,sampleFramesWritten) \
+ ( (This)->lpVtbl -> ScheduleAudioSamples(This,buffer,sampleFrameCount,streamTime,timeScale,sampleFramesWritten) )
+
+#define IDeckLinkOutput_GetBufferedAudioSampleFrameCount(This,bufferedSampleFrameCount) \
+ ( (This)->lpVtbl -> GetBufferedAudioSampleFrameCount(This,bufferedSampleFrameCount) )
+
+#define IDeckLinkOutput_FlushBufferedAudioSamples(This) \
+ ( (This)->lpVtbl -> FlushBufferedAudioSamples(This) )
+
+#define IDeckLinkOutput_SetAudioCallback(This,theCallback) \
+ ( (This)->lpVtbl -> SetAudioCallback(This,theCallback) )
+
+#define IDeckLinkOutput_StartScheduledPlayback(This,playbackStartTime,timeScale,playbackSpeed) \
+ ( (This)->lpVtbl -> StartScheduledPlayback(This,playbackStartTime,timeScale,playbackSpeed) )
+
+#define IDeckLinkOutput_StopScheduledPlayback(This,stopPlaybackAtTime,actualStopTime,timeScale) \
+ ( (This)->lpVtbl -> StopScheduledPlayback(This,stopPlaybackAtTime,actualStopTime,timeScale) )
+
+#define IDeckLinkOutput_IsScheduledPlaybackRunning(This,active) \
+ ( (This)->lpVtbl -> IsScheduledPlaybackRunning(This,active) )
+
+#define IDeckLinkOutput_GetScheduledStreamTime(This,desiredTimeScale,streamTime,playbackSpeed) \
+ ( (This)->lpVtbl -> GetScheduledStreamTime(This,desiredTimeScale,streamTime,playbackSpeed) )
+
+#define IDeckLinkOutput_GetReferenceStatus(This,referenceStatus) \
+ ( (This)->lpVtbl -> GetReferenceStatus(This,referenceStatus) )
+
+#define IDeckLinkOutput_GetHardwareReferenceClock(This,desiredTimeScale,hardwareTime,timeInFrame,ticksPerFrame) \
+ ( (This)->lpVtbl -> GetHardwareReferenceClock(This,desiredTimeScale,hardwareTime,timeInFrame,ticksPerFrame) )
+
+#endif /* COBJMACROS */
+
+
+#endif /* C style interface */
+
+
+
+
+#endif /* __IDeckLinkOutput_INTERFACE_DEFINED__ */
+
+
+#ifndef __IDeckLinkInput_INTERFACE_DEFINED__
+#define __IDeckLinkInput_INTERFACE_DEFINED__
+
+/* interface IDeckLinkInput */
+/* [helpstring][uuid][object] */
+
+
+EXTERN_C const IID IID_IDeckLinkInput;
+
+#if defined(__cplusplus) && !defined(CINTERFACE)
+
+ MIDL_INTERFACE("6D40EF78-28B9-4E21-990D-95BB7750A04F")
+ IDeckLinkInput : public IUnknown
+ {
+ public:
+ virtual HRESULT STDMETHODCALLTYPE DoesSupportVideoMode(
+ /* [in] */ BMDDisplayMode displayMode,
+ /* [in] */ BMDPixelFormat pixelFormat,
+ /* [in] */ BMDVideoInputFlags flags,
+ /* [out] */ BMDDisplayModeSupport *result,
+ /* [out] */ IDeckLinkDisplayMode **resultDisplayMode) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE GetDisplayModeIterator(
+ /* [out] */ IDeckLinkDisplayModeIterator **iterator) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE SetScreenPreviewCallback(
+ /* [in] */ IDeckLinkScreenPreviewCallback *previewCallback) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE EnableVideoInput(
+ /* [in] */ BMDDisplayMode displayMode,
+ /* [in] */ BMDPixelFormat pixelFormat,
+ /* [in] */ BMDVideoInputFlags flags) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE DisableVideoInput( void) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE GetAvailableVideoFrameCount(
+ /* [out] */ unsigned long *availableFrameCount) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE EnableAudioInput(
+ /* [in] */ BMDAudioSampleRate sampleRate,
+ /* [in] */ BMDAudioSampleType sampleType,
+ /* [in] */ unsigned long channelCount) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE DisableAudioInput( void) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE GetAvailableAudioSampleFrameCount(
+ /* [out] */ unsigned long *availableSampleFrameCount) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE StartStreams( void) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE StopStreams( void) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE PauseStreams( void) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE FlushStreams( void) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE SetCallback(
+ /* [in] */ IDeckLinkInputCallback *theCallback) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE GetHardwareReferenceClock(
+ /* [in] */ BMDTimeScale desiredTimeScale,
+ /* [out] */ BMDTimeValue *hardwareTime,
+ /* [out] */ BMDTimeValue *timeInFrame,
+ /* [out] */ BMDTimeValue *ticksPerFrame) = 0;
+
+ };
+
+#else /* C style interface */
+
+ typedef struct IDeckLinkInputVtbl
+ {
+ BEGIN_INTERFACE
+
+ HRESULT ( STDMETHODCALLTYPE *QueryInterface )(
+ IDeckLinkInput * This,
+ /* [in] */ REFIID riid,
+ /* [iid_is][out] */
+ __RPC__deref_out void **ppvObject);
+
+ ULONG ( STDMETHODCALLTYPE *AddRef )(
+ IDeckLinkInput * This);
+
+ ULONG ( STDMETHODCALLTYPE *Release )(
+ IDeckLinkInput * This);
+
+ HRESULT ( STDMETHODCALLTYPE *DoesSupportVideoMode )(
+ IDeckLinkInput * This,
+ /* [in] */ BMDDisplayMode displayMode,
+ /* [in] */ BMDPixelFormat pixelFormat,
+ /* [in] */ BMDVideoInputFlags flags,
+ /* [out] */ BMDDisplayModeSupport *result,
+ /* [out] */ IDeckLinkDisplayMode **resultDisplayMode);
+
+ HRESULT ( STDMETHODCALLTYPE *GetDisplayModeIterator )(
+ IDeckLinkInput * This,
+ /* [out] */ IDeckLinkDisplayModeIterator **iterator);
+
+ HRESULT ( STDMETHODCALLTYPE *SetScreenPreviewCallback )(
+ IDeckLinkInput * This,
+ /* [in] */ IDeckLinkScreenPreviewCallback *previewCallback);
+
+ HRESULT ( STDMETHODCALLTYPE *EnableVideoInput )(
+ IDeckLinkInput * This,
+ /* [in] */ BMDDisplayMode displayMode,
+ /* [in] */ BMDPixelFormat pixelFormat,
+ /* [in] */ BMDVideoInputFlags flags);
+
+ HRESULT ( STDMETHODCALLTYPE *DisableVideoInput )(
+ IDeckLinkInput * This);
+
+ HRESULT ( STDMETHODCALLTYPE *GetAvailableVideoFrameCount )(
+ IDeckLinkInput * This,
+ /* [out] */ unsigned long *availableFrameCount);
+
+ HRESULT ( STDMETHODCALLTYPE *EnableAudioInput )(
+ IDeckLinkInput * This,
+ /* [in] */ BMDAudioSampleRate sampleRate,
+ /* [in] */ BMDAudioSampleType sampleType,
+ /* [in] */ unsigned long channelCount);
+
+ HRESULT ( STDMETHODCALLTYPE *DisableAudioInput )(
+ IDeckLinkInput * This);
+
+ HRESULT ( STDMETHODCALLTYPE *GetAvailableAudioSampleFrameCount )(
+ IDeckLinkInput * This,
+ /* [out] */ unsigned long *availableSampleFrameCount);
+
+ HRESULT ( STDMETHODCALLTYPE *StartStreams )(
+ IDeckLinkInput * This);
+
+ HRESULT ( STDMETHODCALLTYPE *StopStreams )(
+ IDeckLinkInput * This);
+
+ HRESULT ( STDMETHODCALLTYPE *PauseStreams )(
+ IDeckLinkInput * This);
+
+ HRESULT ( STDMETHODCALLTYPE *FlushStreams )(
+ IDeckLinkInput * This);
+
+ HRESULT ( STDMETHODCALLTYPE *SetCallback )(
+ IDeckLinkInput * This,
+ /* [in] */ IDeckLinkInputCallback *theCallback);
+
+ HRESULT ( STDMETHODCALLTYPE *GetHardwareReferenceClock )(
+ IDeckLinkInput * This,
+ /* [in] */ BMDTimeScale desiredTimeScale,
+ /* [out] */ BMDTimeValue *hardwareTime,
+ /* [out] */ BMDTimeValue *timeInFrame,
+ /* [out] */ BMDTimeValue *ticksPerFrame);
+
+ END_INTERFACE
+ } IDeckLinkInputVtbl;
+
+ interface IDeckLinkInput
+ {
+ CONST_VTBL struct IDeckLinkInputVtbl *lpVtbl;
+ };
+
+
+
+#ifdef COBJMACROS
+
+
+#define IDeckLinkInput_QueryInterface(This,riid,ppvObject) \
+ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) )
+
+#define IDeckLinkInput_AddRef(This) \
+ ( (This)->lpVtbl -> AddRef(This) )
+
+#define IDeckLinkInput_Release(This) \
+ ( (This)->lpVtbl -> Release(This) )
+
+
+#define IDeckLinkInput_DoesSupportVideoMode(This,displayMode,pixelFormat,flags,result,resultDisplayMode) \
+ ( (This)->lpVtbl -> DoesSupportVideoMode(This,displayMode,pixelFormat,flags,result,resultDisplayMode) )
+
+#define IDeckLinkInput_GetDisplayModeIterator(This,iterator) \
+ ( (This)->lpVtbl -> GetDisplayModeIterator(This,iterator) )
+
+#define IDeckLinkInput_SetScreenPreviewCallback(This,previewCallback) \
+ ( (This)->lpVtbl -> SetScreenPreviewCallback(This,previewCallback) )
+
+#define IDeckLinkInput_EnableVideoInput(This,displayMode,pixelFormat,flags) \
+ ( (This)->lpVtbl -> EnableVideoInput(This,displayMode,pixelFormat,flags) )
+
+#define IDeckLinkInput_DisableVideoInput(This) \
+ ( (This)->lpVtbl -> DisableVideoInput(This) )
+
+#define IDeckLinkInput_GetAvailableVideoFrameCount(This,availableFrameCount) \
+ ( (This)->lpVtbl -> GetAvailableVideoFrameCount(This,availableFrameCount) )
+
+#define IDeckLinkInput_EnableAudioInput(This,sampleRate,sampleType,channelCount) \
+ ( (This)->lpVtbl -> EnableAudioInput(This,sampleRate,sampleType,channelCount) )
+
+#define IDeckLinkInput_DisableAudioInput(This) \
+ ( (This)->lpVtbl -> DisableAudioInput(This) )
+
+#define IDeckLinkInput_GetAvailableAudioSampleFrameCount(This,availableSampleFrameCount) \
+ ( (This)->lpVtbl -> GetAvailableAudioSampleFrameCount(This,availableSampleFrameCount) )
+
+#define IDeckLinkInput_StartStreams(This) \
+ ( (This)->lpVtbl -> StartStreams(This) )
+
+#define IDeckLinkInput_StopStreams(This) \
+ ( (This)->lpVtbl -> StopStreams(This) )
+
+#define IDeckLinkInput_PauseStreams(This) \
+ ( (This)->lpVtbl -> PauseStreams(This) )
+
+#define IDeckLinkInput_FlushStreams(This) \
+ ( (This)->lpVtbl -> FlushStreams(This) )
+
+#define IDeckLinkInput_SetCallback(This,theCallback) \
+ ( (This)->lpVtbl -> SetCallback(This,theCallback) )
+
+#define IDeckLinkInput_GetHardwareReferenceClock(This,desiredTimeScale,hardwareTime,timeInFrame,ticksPerFrame) \
+ ( (This)->lpVtbl -> GetHardwareReferenceClock(This,desiredTimeScale,hardwareTime,timeInFrame,ticksPerFrame) )
+
+#endif /* COBJMACROS */
+
+
+#endif /* C style interface */
+
+
+
+
+#endif /* __IDeckLinkInput_INTERFACE_DEFINED__ */
+
+
+#ifndef __IDeckLinkTimecode_INTERFACE_DEFINED__
+#define __IDeckLinkTimecode_INTERFACE_DEFINED__
+
+/* interface IDeckLinkTimecode */
+/* [helpstring][uuid][object] */
+
+
+EXTERN_C const IID IID_IDeckLinkTimecode;
+
+#if defined(__cplusplus) && !defined(CINTERFACE)
+
+ MIDL_INTERFACE("BC6CFBD3-8317-4325-AC1C-1216391E9340")
+ IDeckLinkTimecode : public IUnknown
+ {
+ public:
+ virtual BMDTimecodeBCD STDMETHODCALLTYPE GetBCD( void) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE GetComponents(
+ /* [out] */ unsigned char *hours,
+ /* [out] */ unsigned char *minutes,
+ /* [out] */ unsigned char *seconds,
+ /* [out] */ unsigned char *frames) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE GetString(
+ /* [out] */ BSTR *timecode) = 0;
+
+ virtual BMDTimecodeFlags STDMETHODCALLTYPE GetFlags( void) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE GetTimecodeUserBits(
+ /* [out] */ BMDTimecodeUserBits *userBits) = 0;
+
+ };
+
+#else /* C style interface */
+
+ typedef struct IDeckLinkTimecodeVtbl
+ {
+ BEGIN_INTERFACE
+
+ HRESULT ( STDMETHODCALLTYPE *QueryInterface )(
+ IDeckLinkTimecode * This,
+ /* [in] */ REFIID riid,
+ /* [iid_is][out] */
+ __RPC__deref_out void **ppvObject);
+
+ ULONG ( STDMETHODCALLTYPE *AddRef )(
+ IDeckLinkTimecode * This);
+
+ ULONG ( STDMETHODCALLTYPE *Release )(
+ IDeckLinkTimecode * This);
+
+ BMDTimecodeBCD ( STDMETHODCALLTYPE *GetBCD )(
+ IDeckLinkTimecode * This);
+
+ HRESULT ( STDMETHODCALLTYPE *GetComponents )(
+ IDeckLinkTimecode * This,
+ /* [out] */ unsigned char *hours,
+ /* [out] */ unsigned char *minutes,
+ /* [out] */ unsigned char *seconds,
+ /* [out] */ unsigned char *frames);
+
+ HRESULT ( STDMETHODCALLTYPE *GetString )(
+ IDeckLinkTimecode * This,
+ /* [out] */ BSTR *timecode);
+
+ BMDTimecodeFlags ( STDMETHODCALLTYPE *GetFlags )(
+ IDeckLinkTimecode * This);
+
+ HRESULT ( STDMETHODCALLTYPE *GetTimecodeUserBits )(
+ IDeckLinkTimecode * This,
+ /* [out] */ BMDTimecodeUserBits *userBits);
+
+ END_INTERFACE
+ } IDeckLinkTimecodeVtbl;
+
+ interface IDeckLinkTimecode
+ {
+ CONST_VTBL struct IDeckLinkTimecodeVtbl *lpVtbl;
+ };
+
+
+
+#ifdef COBJMACROS
+
+
+#define IDeckLinkTimecode_QueryInterface(This,riid,ppvObject) \
+ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) )
+
+#define IDeckLinkTimecode_AddRef(This) \
+ ( (This)->lpVtbl -> AddRef(This) )
+
+#define IDeckLinkTimecode_Release(This) \
+ ( (This)->lpVtbl -> Release(This) )
+
+
+#define IDeckLinkTimecode_GetBCD(This) \
+ ( (This)->lpVtbl -> GetBCD(This) )
+
+#define IDeckLinkTimecode_GetComponents(This,hours,minutes,seconds,frames) \
+ ( (This)->lpVtbl -> GetComponents(This,hours,minutes,seconds,frames) )
+
+#define IDeckLinkTimecode_GetString(This,timecode) \
+ ( (This)->lpVtbl -> GetString(This,timecode) )
+
+#define IDeckLinkTimecode_GetFlags(This) \
+ ( (This)->lpVtbl -> GetFlags(This) )
+
+#define IDeckLinkTimecode_GetTimecodeUserBits(This,userBits) \
+ ( (This)->lpVtbl -> GetTimecodeUserBits(This,userBits) )
+
+#endif /* COBJMACROS */
+
+
+#endif /* C style interface */
+
+
+
+
+#endif /* __IDeckLinkTimecode_INTERFACE_DEFINED__ */
+
+
+#ifndef __IDeckLinkVideoFrame_INTERFACE_DEFINED__
+#define __IDeckLinkVideoFrame_INTERFACE_DEFINED__
+
+/* interface IDeckLinkVideoFrame */
+/* [helpstring][local][uuid][object] */
+
+
+EXTERN_C const IID IID_IDeckLinkVideoFrame;
+
+#if defined(__cplusplus) && !defined(CINTERFACE)
+
+ MIDL_INTERFACE("3F716FE0-F023-4111-BE5D-EF4414C05B17")
+ IDeckLinkVideoFrame : public IUnknown
+ {
+ public:
+ virtual long STDMETHODCALLTYPE GetWidth( void) = 0;
+
+ virtual long STDMETHODCALLTYPE GetHeight( void) = 0;
+
+ virtual long STDMETHODCALLTYPE GetRowBytes( void) = 0;
+
+ virtual BMDPixelFormat STDMETHODCALLTYPE GetPixelFormat( void) = 0;
+
+ virtual BMDFrameFlags STDMETHODCALLTYPE GetFlags( void) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE GetBytes(
+ /* [out] */ void **buffer) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE GetTimecode(
+ /* [in] */ BMDTimecodeFormat format,
+ /* [out] */ IDeckLinkTimecode **timecode) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE GetAncillaryData(
+ /* [out] */ IDeckLinkVideoFrameAncillary **ancillary) = 0;
+
+ };
+
+#else /* C style interface */
+
+ typedef struct IDeckLinkVideoFrameVtbl
+ {
+ BEGIN_INTERFACE
+
+ HRESULT ( STDMETHODCALLTYPE *QueryInterface )(
+ IDeckLinkVideoFrame * This,
+ /* [in] */ REFIID riid,
+ /* [iid_is][out] */
+ __RPC__deref_out void **ppvObject);
+
+ ULONG ( STDMETHODCALLTYPE *AddRef )(
+ IDeckLinkVideoFrame * This);
+
+ ULONG ( STDMETHODCALLTYPE *Release )(
+ IDeckLinkVideoFrame * This);
+
+ long ( STDMETHODCALLTYPE *GetWidth )(
+ IDeckLinkVideoFrame * This);
+
+ long ( STDMETHODCALLTYPE *GetHeight )(
+ IDeckLinkVideoFrame * This);
+
+ long ( STDMETHODCALLTYPE *GetRowBytes )(
+ IDeckLinkVideoFrame * This);
+
+ BMDPixelFormat ( STDMETHODCALLTYPE *GetPixelFormat )(
+ IDeckLinkVideoFrame * This);
+
+ BMDFrameFlags ( STDMETHODCALLTYPE *GetFlags )(
+ IDeckLinkVideoFrame * This);
+
+ HRESULT ( STDMETHODCALLTYPE *GetBytes )(
+ IDeckLinkVideoFrame * This,
+ /* [out] */ void **buffer);
+
+ HRESULT ( STDMETHODCALLTYPE *GetTimecode )(
+ IDeckLinkVideoFrame * This,
+ /* [in] */ BMDTimecodeFormat format,
+ /* [out] */ IDeckLinkTimecode **timecode);
+
+ HRESULT ( STDMETHODCALLTYPE *GetAncillaryData )(
+ IDeckLinkVideoFrame * This,
+ /* [out] */ IDeckLinkVideoFrameAncillary **ancillary);
+
+ END_INTERFACE
+ } IDeckLinkVideoFrameVtbl;
+
+ interface IDeckLinkVideoFrame
+ {
+ CONST_VTBL struct IDeckLinkVideoFrameVtbl *lpVtbl;
+ };
+
+
+
+#ifdef COBJMACROS
+
+
+#define IDeckLinkVideoFrame_QueryInterface(This,riid,ppvObject) \
+ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) )
+
+#define IDeckLinkVideoFrame_AddRef(This) \
+ ( (This)->lpVtbl -> AddRef(This) )
+
+#define IDeckLinkVideoFrame_Release(This) \
+ ( (This)->lpVtbl -> Release(This) )
+
+
+#define IDeckLinkVideoFrame_GetWidth(This) \
+ ( (This)->lpVtbl -> GetWidth(This) )
+
+#define IDeckLinkVideoFrame_GetHeight(This) \
+ ( (This)->lpVtbl -> GetHeight(This) )
+
+#define IDeckLinkVideoFrame_GetRowBytes(This) \
+ ( (This)->lpVtbl -> GetRowBytes(This) )
+
+#define IDeckLinkVideoFrame_GetPixelFormat(This) \
+ ( (This)->lpVtbl -> GetPixelFormat(This) )
+
+#define IDeckLinkVideoFrame_GetFlags(This) \
+ ( (This)->lpVtbl -> GetFlags(This) )
+
+#define IDeckLinkVideoFrame_GetBytes(This,buffer) \
+ ( (This)->lpVtbl -> GetBytes(This,buffer) )
+
+#define IDeckLinkVideoFrame_GetTimecode(This,format,timecode) \
+ ( (This)->lpVtbl -> GetTimecode(This,format,timecode) )
+
+#define IDeckLinkVideoFrame_GetAncillaryData(This,ancillary) \
+ ( (This)->lpVtbl -> GetAncillaryData(This,ancillary) )
+
+#endif /* COBJMACROS */
+
+
+#endif /* C style interface */
+
+
+
+
+#endif /* __IDeckLinkVideoFrame_INTERFACE_DEFINED__ */
+
+
+#ifndef __IDeckLinkMutableVideoFrame_INTERFACE_DEFINED__
+#define __IDeckLinkMutableVideoFrame_INTERFACE_DEFINED__
+
+/* interface IDeckLinkMutableVideoFrame */
+/* [helpstring][local][uuid][object] */
+
+
+EXTERN_C const IID IID_IDeckLinkMutableVideoFrame;
+
+#if defined(__cplusplus) && !defined(CINTERFACE)
+
+ MIDL_INTERFACE("69E2639F-40DA-4E19-B6F2-20ACE815C390")
+ IDeckLinkMutableVideoFrame : public IDeckLinkVideoFrame
+ {
+ public:
+ virtual HRESULT STDMETHODCALLTYPE SetFlags(
+ /* [in] */ BMDFrameFlags newFlags) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE SetTimecode(
+ /* [in] */ BMDTimecodeFormat format,
+ /* [in] */ IDeckLinkTimecode *timecode) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE SetTimecodeFromComponents(
+ /* [in] */ BMDTimecodeFormat format,
+ /* [in] */ unsigned char hours,
+ /* [in] */ unsigned char minutes,
+ /* [in] */ unsigned char seconds,
+ /* [in] */ unsigned char frames,
+ /* [in] */ BMDTimecodeFlags flags) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE SetAncillaryData(
+ /* [in] */ IDeckLinkVideoFrameAncillary *ancillary) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE SetTimecodeUserBits(
+ /* [in] */ BMDTimecodeFormat format,
+ /* [in] */ BMDTimecodeUserBits userBits) = 0;
+
+ };
+
+#else /* C style interface */
+
+ typedef struct IDeckLinkMutableVideoFrameVtbl
+ {
+ BEGIN_INTERFACE
+
+ HRESULT ( STDMETHODCALLTYPE *QueryInterface )(
+ IDeckLinkMutableVideoFrame * This,
+ /* [in] */ REFIID riid,
+ /* [iid_is][out] */
+ __RPC__deref_out void **ppvObject);
+
+ ULONG ( STDMETHODCALLTYPE *AddRef )(
+ IDeckLinkMutableVideoFrame * This);
+
+ ULONG ( STDMETHODCALLTYPE *Release )(
+ IDeckLinkMutableVideoFrame * This);
+
+ long ( STDMETHODCALLTYPE *GetWidth )(
+ IDeckLinkMutableVideoFrame * This);
+
+ long ( STDMETHODCALLTYPE *GetHeight )(
+ IDeckLinkMutableVideoFrame * This);
+
+ long ( STDMETHODCALLTYPE *GetRowBytes )(
+ IDeckLinkMutableVideoFrame * This);
+
+ BMDPixelFormat ( STDMETHODCALLTYPE *GetPixelFormat )(
+ IDeckLinkMutableVideoFrame * This);
+
+ BMDFrameFlags ( STDMETHODCALLTYPE *GetFlags )(
+ IDeckLinkMutableVideoFrame * This);
+
+ HRESULT ( STDMETHODCALLTYPE *GetBytes )(
+ IDeckLinkMutableVideoFrame * This,
+ /* [out] */ void **buffer);
+
+ HRESULT ( STDMETHODCALLTYPE *GetTimecode )(
+ IDeckLinkMutableVideoFrame * This,
+ /* [in] */ BMDTimecodeFormat format,
+ /* [out] */ IDeckLinkTimecode **timecode);
+
+ HRESULT ( STDMETHODCALLTYPE *GetAncillaryData )(
+ IDeckLinkMutableVideoFrame * This,
+ /* [out] */ IDeckLinkVideoFrameAncillary **ancillary);
+
+ HRESULT ( STDMETHODCALLTYPE *SetFlags )(
+ IDeckLinkMutableVideoFrame * This,
+ /* [in] */ BMDFrameFlags newFlags);
+
+ HRESULT ( STDMETHODCALLTYPE *SetTimecode )(
+ IDeckLinkMutableVideoFrame * This,
+ /* [in] */ BMDTimecodeFormat format,
+ /* [in] */ IDeckLinkTimecode *timecode);
+
+ HRESULT ( STDMETHODCALLTYPE *SetTimecodeFromComponents )(
+ IDeckLinkMutableVideoFrame * This,
+ /* [in] */ BMDTimecodeFormat format,
+ /* [in] */ unsigned char hours,
+ /* [in] */ unsigned char minutes,
+ /* [in] */ unsigned char seconds,
+ /* [in] */ unsigned char frames,
+ /* [in] */ BMDTimecodeFlags flags);
+
+ HRESULT ( STDMETHODCALLTYPE *SetAncillaryData )(
+ IDeckLinkMutableVideoFrame * This,
+ /* [in] */ IDeckLinkVideoFrameAncillary *ancillary);
+
+ HRESULT ( STDMETHODCALLTYPE *SetTimecodeUserBits )(
+ IDeckLinkMutableVideoFrame * This,
+ /* [in] */ BMDTimecodeFormat format,
+ /* [in] */ BMDTimecodeUserBits userBits);
+
+ END_INTERFACE
+ } IDeckLinkMutableVideoFrameVtbl;
+
+ interface IDeckLinkMutableVideoFrame
+ {
+ CONST_VTBL struct IDeckLinkMutableVideoFrameVtbl *lpVtbl;
+ };
+
+
+
+#ifdef COBJMACROS
+
+
+#define IDeckLinkMutableVideoFrame_QueryInterface(This,riid,ppvObject) \
+ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) )
+
+#define IDeckLinkMutableVideoFrame_AddRef(This) \
+ ( (This)->lpVtbl -> AddRef(This) )
+
+#define IDeckLinkMutableVideoFrame_Release(This) \
+ ( (This)->lpVtbl -> Release(This) )
+
+
+#define IDeckLinkMutableVideoFrame_GetWidth(This) \
+ ( (This)->lpVtbl -> GetWidth(This) )
+
+#define IDeckLinkMutableVideoFrame_GetHeight(This) \
+ ( (This)->lpVtbl -> GetHeight(This) )
+
+#define IDeckLinkMutableVideoFrame_GetRowBytes(This) \
+ ( (This)->lpVtbl -> GetRowBytes(This) )
+
+#define IDeckLinkMutableVideoFrame_GetPixelFormat(This) \
+ ( (This)->lpVtbl -> GetPixelFormat(This) )
+
+#define IDeckLinkMutableVideoFrame_GetFlags(This) \
+ ( (This)->lpVtbl -> GetFlags(This) )
+
+#define IDeckLinkMutableVideoFrame_GetBytes(This,buffer) \
+ ( (This)->lpVtbl -> GetBytes(This,buffer) )
+
+#define IDeckLinkMutableVideoFrame_GetTimecode(This,format,timecode) \
+ ( (This)->lpVtbl -> GetTimecode(This,format,timecode) )
+
+#define IDeckLinkMutableVideoFrame_GetAncillaryData(This,ancillary) \
+ ( (This)->lpVtbl -> GetAncillaryData(This,ancillary) )
+
+
+#define IDeckLinkMutableVideoFrame_SetFlags(This,newFlags) \
+ ( (This)->lpVtbl -> SetFlags(This,newFlags) )
+
+#define IDeckLinkMutableVideoFrame_SetTimecode(This,format,timecode) \
+ ( (This)->lpVtbl -> SetTimecode(This,format,timecode) )
+
+#define IDeckLinkMutableVideoFrame_SetTimecodeFromComponents(This,format,hours,minutes,seconds,frames,flags) \
+ ( (This)->lpVtbl -> SetTimecodeFromComponents(This,format,hours,minutes,seconds,frames,flags) )
+
+#define IDeckLinkMutableVideoFrame_SetAncillaryData(This,ancillary) \
+ ( (This)->lpVtbl -> SetAncillaryData(This,ancillary) )
+
+#define IDeckLinkMutableVideoFrame_SetTimecodeUserBits(This,format,userBits) \
+ ( (This)->lpVtbl -> SetTimecodeUserBits(This,format,userBits) )
+
+#endif /* COBJMACROS */
+
+
+#endif /* C style interface */
+
+
+
+
+#endif /* __IDeckLinkMutableVideoFrame_INTERFACE_DEFINED__ */
+
+
+#ifndef __IDeckLinkVideoFrame3DExtensions_INTERFACE_DEFINED__
+#define __IDeckLinkVideoFrame3DExtensions_INTERFACE_DEFINED__
+
+/* interface IDeckLinkVideoFrame3DExtensions */
+/* [helpstring][local][uuid][object] */
+
+
+EXTERN_C const IID IID_IDeckLinkVideoFrame3DExtensions;
+
+#if defined(__cplusplus) && !defined(CINTERFACE)
+
+ MIDL_INTERFACE("DA0F7E4A-EDC7-48A8-9CDD-2DB51C729CD7")
+ IDeckLinkVideoFrame3DExtensions : public IUnknown
+ {
+ public:
+ virtual BMDVideo3DPackingFormat STDMETHODCALLTYPE Get3DPackingFormat( void) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE GetFrameForRightEye(
+ /* [out] */ IDeckLinkVideoFrame **rightEyeFrame) = 0;
+
+ };
+
+#else /* C style interface */
+
+ typedef struct IDeckLinkVideoFrame3DExtensionsVtbl
+ {
+ BEGIN_INTERFACE
+
+ HRESULT ( STDMETHODCALLTYPE *QueryInterface )(
+ IDeckLinkVideoFrame3DExtensions * This,
+ /* [in] */ REFIID riid,
+ /* [iid_is][out] */
+ __RPC__deref_out void **ppvObject);
+
+ ULONG ( STDMETHODCALLTYPE *AddRef )(
+ IDeckLinkVideoFrame3DExtensions * This);
+
+ ULONG ( STDMETHODCALLTYPE *Release )(
+ IDeckLinkVideoFrame3DExtensions * This);
+
+ BMDVideo3DPackingFormat ( STDMETHODCALLTYPE *Get3DPackingFormat )(
+ IDeckLinkVideoFrame3DExtensions * This);
+
+ HRESULT ( STDMETHODCALLTYPE *GetFrameForRightEye )(
+ IDeckLinkVideoFrame3DExtensions * This,
+ /* [out] */ IDeckLinkVideoFrame **rightEyeFrame);
+
+ END_INTERFACE
+ } IDeckLinkVideoFrame3DExtensionsVtbl;
+
+ interface IDeckLinkVideoFrame3DExtensions
+ {
+ CONST_VTBL struct IDeckLinkVideoFrame3DExtensionsVtbl *lpVtbl;
+ };
+
+
+
+#ifdef COBJMACROS
+
+
+#define IDeckLinkVideoFrame3DExtensions_QueryInterface(This,riid,ppvObject) \
+ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) )
+
+#define IDeckLinkVideoFrame3DExtensions_AddRef(This) \
+ ( (This)->lpVtbl -> AddRef(This) )
+
+#define IDeckLinkVideoFrame3DExtensions_Release(This) \
+ ( (This)->lpVtbl -> Release(This) )
+
+
+#define IDeckLinkVideoFrame3DExtensions_Get3DPackingFormat(This) \
+ ( (This)->lpVtbl -> Get3DPackingFormat(This) )
+
+#define IDeckLinkVideoFrame3DExtensions_GetFrameForRightEye(This,rightEyeFrame) \
+ ( (This)->lpVtbl -> GetFrameForRightEye(This,rightEyeFrame) )
+
+#endif /* COBJMACROS */
+
+
+#endif /* C style interface */
+
+
+
+
+#endif /* __IDeckLinkVideoFrame3DExtensions_INTERFACE_DEFINED__ */
+
+
+#ifndef __IDeckLinkVideoInputFrame_INTERFACE_DEFINED__
+#define __IDeckLinkVideoInputFrame_INTERFACE_DEFINED__
+
+/* interface IDeckLinkVideoInputFrame */
+/* [helpstring][local][uuid][object] */
+
+
+EXTERN_C const IID IID_IDeckLinkVideoInputFrame;
+
+#if defined(__cplusplus) && !defined(CINTERFACE)
+
+ MIDL_INTERFACE("05CFE374-537C-4094-9A57-680525118F44")
+ IDeckLinkVideoInputFrame : public IDeckLinkVideoFrame
+ {
+ public:
+ virtual HRESULT STDMETHODCALLTYPE GetStreamTime(
+ /* [out] */ BMDTimeValue *frameTime,
+ /* [out] */ BMDTimeValue *frameDuration,
+ /* [in] */ BMDTimeScale timeScale) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE GetHardwareReferenceTimestamp(
+ /* [in] */ BMDTimeScale timeScale,
+ /* [out] */ BMDTimeValue *frameTime,
+ /* [out] */ BMDTimeValue *frameDuration) = 0;
+
+ };
+
+#else /* C style interface */
+
+ typedef struct IDeckLinkVideoInputFrameVtbl
+ {
+ BEGIN_INTERFACE
+
+ HRESULT ( STDMETHODCALLTYPE *QueryInterface )(
+ IDeckLinkVideoInputFrame * This,
+ /* [in] */ REFIID riid,
+ /* [iid_is][out] */
+ __RPC__deref_out void **ppvObject);
+
+ ULONG ( STDMETHODCALLTYPE *AddRef )(
+ IDeckLinkVideoInputFrame * This);
+
+ ULONG ( STDMETHODCALLTYPE *Release )(
+ IDeckLinkVideoInputFrame * This);
+
+ long ( STDMETHODCALLTYPE *GetWidth )(
+ IDeckLinkVideoInputFrame * This);
+
+ long ( STDMETHODCALLTYPE *GetHeight )(
+ IDeckLinkVideoInputFrame * This);
+
+ long ( STDMETHODCALLTYPE *GetRowBytes )(
+ IDeckLinkVideoInputFrame * This);
+
+ BMDPixelFormat ( STDMETHODCALLTYPE *GetPixelFormat )(
+ IDeckLinkVideoInputFrame * This);
+
+ BMDFrameFlags ( STDMETHODCALLTYPE *GetFlags )(
+ IDeckLinkVideoInputFrame * This);
+
+ HRESULT ( STDMETHODCALLTYPE *GetBytes )(
+ IDeckLinkVideoInputFrame * This,
+ /* [out] */ void **buffer);
+
+ HRESULT ( STDMETHODCALLTYPE *GetTimecode )(
+ IDeckLinkVideoInputFrame * This,
+ /* [in] */ BMDTimecodeFormat format,
+ /* [out] */ IDeckLinkTimecode **timecode);
+
+ HRESULT ( STDMETHODCALLTYPE *GetAncillaryData )(
+ IDeckLinkVideoInputFrame * This,
+ /* [out] */ IDeckLinkVideoFrameAncillary **ancillary);
+
+ HRESULT ( STDMETHODCALLTYPE *GetStreamTime )(
+ IDeckLinkVideoInputFrame * This,
+ /* [out] */ BMDTimeValue *frameTime,
+ /* [out] */ BMDTimeValue *frameDuration,
+ /* [in] */ BMDTimeScale timeScale);
+
+ HRESULT ( STDMETHODCALLTYPE *GetHardwareReferenceTimestamp )(
+ IDeckLinkVideoInputFrame * This,
+ /* [in] */ BMDTimeScale timeScale,
+ /* [out] */ BMDTimeValue *frameTime,
+ /* [out] */ BMDTimeValue *frameDuration);
+
+ END_INTERFACE
+ } IDeckLinkVideoInputFrameVtbl;
+
+ interface IDeckLinkVideoInputFrame
+ {
+ CONST_VTBL struct IDeckLinkVideoInputFrameVtbl *lpVtbl;
+ };
+
+
+
+#ifdef COBJMACROS
+
+
+#define IDeckLinkVideoInputFrame_QueryInterface(This,riid,ppvObject) \
+ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) )
+
+#define IDeckLinkVideoInputFrame_AddRef(This) \
+ ( (This)->lpVtbl -> AddRef(This) )
+
+#define IDeckLinkVideoInputFrame_Release(This) \
+ ( (This)->lpVtbl -> Release(This) )
+
+
+#define IDeckLinkVideoInputFrame_GetWidth(This) \
+ ( (This)->lpVtbl -> GetWidth(This) )
+
+#define IDeckLinkVideoInputFrame_GetHeight(This) \
+ ( (This)->lpVtbl -> GetHeight(This) )
+
+#define IDeckLinkVideoInputFrame_GetRowBytes(This) \
+ ( (This)->lpVtbl -> GetRowBytes(This) )
+
+#define IDeckLinkVideoInputFrame_GetPixelFormat(This) \
+ ( (This)->lpVtbl -> GetPixelFormat(This) )
+
+#define IDeckLinkVideoInputFrame_GetFlags(This) \
+ ( (This)->lpVtbl -> GetFlags(This) )
+
+#define IDeckLinkVideoInputFrame_GetBytes(This,buffer) \
+ ( (This)->lpVtbl -> GetBytes(This,buffer) )
+
+#define IDeckLinkVideoInputFrame_GetTimecode(This,format,timecode) \
+ ( (This)->lpVtbl -> GetTimecode(This,format,timecode) )
+
+#define IDeckLinkVideoInputFrame_GetAncillaryData(This,ancillary) \
+ ( (This)->lpVtbl -> GetAncillaryData(This,ancillary) )
+
+
+#define IDeckLinkVideoInputFrame_GetStreamTime(This,frameTime,frameDuration,timeScale) \
+ ( (This)->lpVtbl -> GetStreamTime(This,frameTime,frameDuration,timeScale) )
+
+#define IDeckLinkVideoInputFrame_GetHardwareReferenceTimestamp(This,timeScale,frameTime,frameDuration) \
+ ( (This)->lpVtbl -> GetHardwareReferenceTimestamp(This,timeScale,frameTime,frameDuration) )
+
+#endif /* COBJMACROS */
+
+
+#endif /* C style interface */
+
+
+
+
+#endif /* __IDeckLinkVideoInputFrame_INTERFACE_DEFINED__ */
+
+
+#ifndef __IDeckLinkVideoFrameAncillary_INTERFACE_DEFINED__
+#define __IDeckLinkVideoFrameAncillary_INTERFACE_DEFINED__
+
+/* interface IDeckLinkVideoFrameAncillary */
+/* [helpstring][local][uuid][object] */
+
+
+EXTERN_C const IID IID_IDeckLinkVideoFrameAncillary;
+
+#if defined(__cplusplus) && !defined(CINTERFACE)
+
+ MIDL_INTERFACE("732E723C-D1A4-4E29-9E8E-4A88797A0004")
+ IDeckLinkVideoFrameAncillary : public IUnknown
+ {
+ public:
+ virtual HRESULT STDMETHODCALLTYPE GetBufferForVerticalBlankingLine(
+ /* [in] */ unsigned long lineNumber,
+ /* [out] */ void **buffer) = 0;
+
+ virtual BMDPixelFormat STDMETHODCALLTYPE GetPixelFormat( void) = 0;
+
+ virtual BMDDisplayMode STDMETHODCALLTYPE GetDisplayMode( void) = 0;
+
+ };
+
+#else /* C style interface */
+
+ typedef struct IDeckLinkVideoFrameAncillaryVtbl
+ {
+ BEGIN_INTERFACE
+
+ HRESULT ( STDMETHODCALLTYPE *QueryInterface )(
+ IDeckLinkVideoFrameAncillary * This,
+ /* [in] */ REFIID riid,
+ /* [iid_is][out] */
+ __RPC__deref_out void **ppvObject);
+
+ ULONG ( STDMETHODCALLTYPE *AddRef )(
+ IDeckLinkVideoFrameAncillary * This);
+
+ ULONG ( STDMETHODCALLTYPE *Release )(
+ IDeckLinkVideoFrameAncillary * This);
+
+ HRESULT ( STDMETHODCALLTYPE *GetBufferForVerticalBlankingLine )(
+ IDeckLinkVideoFrameAncillary * This,
+ /* [in] */ unsigned long lineNumber,
+ /* [out] */ void **buffer);
+
+ BMDPixelFormat ( STDMETHODCALLTYPE *GetPixelFormat )(
+ IDeckLinkVideoFrameAncillary * This);
+
+ BMDDisplayMode ( STDMETHODCALLTYPE *GetDisplayMode )(
+ IDeckLinkVideoFrameAncillary * This);
+
+ END_INTERFACE
+ } IDeckLinkVideoFrameAncillaryVtbl;
+
+ interface IDeckLinkVideoFrameAncillary
+ {
+ CONST_VTBL struct IDeckLinkVideoFrameAncillaryVtbl *lpVtbl;
+ };
+
+
+
+#ifdef COBJMACROS
+
+
+#define IDeckLinkVideoFrameAncillary_QueryInterface(This,riid,ppvObject) \
+ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) )
+
+#define IDeckLinkVideoFrameAncillary_AddRef(This) \
+ ( (This)->lpVtbl -> AddRef(This) )
+
+#define IDeckLinkVideoFrameAncillary_Release(This) \
+ ( (This)->lpVtbl -> Release(This) )
+
+
+#define IDeckLinkVideoFrameAncillary_GetBufferForVerticalBlankingLine(This,lineNumber,buffer) \
+ ( (This)->lpVtbl -> GetBufferForVerticalBlankingLine(This,lineNumber,buffer) )
+
+#define IDeckLinkVideoFrameAncillary_GetPixelFormat(This) \
+ ( (This)->lpVtbl -> GetPixelFormat(This) )
+
+#define IDeckLinkVideoFrameAncillary_GetDisplayMode(This) \
+ ( (This)->lpVtbl -> GetDisplayMode(This) )
+
+#endif /* COBJMACROS */
+
+
+#endif /* C style interface */
+
+
+
+
+#endif /* __IDeckLinkVideoFrameAncillary_INTERFACE_DEFINED__ */
+
+
+#ifndef __IDeckLinkAudioInputPacket_INTERFACE_DEFINED__
+#define __IDeckLinkAudioInputPacket_INTERFACE_DEFINED__
+
+/* interface IDeckLinkAudioInputPacket */
+/* [helpstring][local][uuid][object] */
+
+
+EXTERN_C const IID IID_IDeckLinkAudioInputPacket;
+
+#if defined(__cplusplus) && !defined(CINTERFACE)
+
+ MIDL_INTERFACE("E43D5870-2894-11DE-8C30-0800200C9A66")
+ IDeckLinkAudioInputPacket : public IUnknown
+ {
+ public:
+ virtual long STDMETHODCALLTYPE GetSampleFrameCount( void) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE GetBytes(
+ /* [out] */ void **buffer) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE GetPacketTime(
+ /* [out] */ BMDTimeValue *packetTime,
+ /* [in] */ BMDTimeScale timeScale) = 0;
+
+ };
+
+#else /* C style interface */
+
+ typedef struct IDeckLinkAudioInputPacketVtbl
+ {
+ BEGIN_INTERFACE
+
+ HRESULT ( STDMETHODCALLTYPE *QueryInterface )(
+ IDeckLinkAudioInputPacket * This,
+ /* [in] */ REFIID riid,
+ /* [iid_is][out] */
+ __RPC__deref_out void **ppvObject);
+
+ ULONG ( STDMETHODCALLTYPE *AddRef )(
+ IDeckLinkAudioInputPacket * This);
+
+ ULONG ( STDMETHODCALLTYPE *Release )(
+ IDeckLinkAudioInputPacket * This);
+
+ long ( STDMETHODCALLTYPE *GetSampleFrameCount )(
+ IDeckLinkAudioInputPacket * This);
+
+ HRESULT ( STDMETHODCALLTYPE *GetBytes )(
+ IDeckLinkAudioInputPacket * This,
+ /* [out] */ void **buffer);
+
+ HRESULT ( STDMETHODCALLTYPE *GetPacketTime )(
+ IDeckLinkAudioInputPacket * This,
+ /* [out] */ BMDTimeValue *packetTime,
+ /* [in] */ BMDTimeScale timeScale);
+
+ END_INTERFACE
+ } IDeckLinkAudioInputPacketVtbl;
+
+ interface IDeckLinkAudioInputPacket
+ {
+ CONST_VTBL struct IDeckLinkAudioInputPacketVtbl *lpVtbl;
+ };
+
+
+
+#ifdef COBJMACROS
+
+
+#define IDeckLinkAudioInputPacket_QueryInterface(This,riid,ppvObject) \
+ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) )
+
+#define IDeckLinkAudioInputPacket_AddRef(This) \
+ ( (This)->lpVtbl -> AddRef(This) )
+
+#define IDeckLinkAudioInputPacket_Release(This) \
+ ( (This)->lpVtbl -> Release(This) )
+
+
+#define IDeckLinkAudioInputPacket_GetSampleFrameCount(This) \
+ ( (This)->lpVtbl -> GetSampleFrameCount(This) )
+
+#define IDeckLinkAudioInputPacket_GetBytes(This,buffer) \
+ ( (This)->lpVtbl -> GetBytes(This,buffer) )
+
+#define IDeckLinkAudioInputPacket_GetPacketTime(This,packetTime,timeScale) \
+ ( (This)->lpVtbl -> GetPacketTime(This,packetTime,timeScale) )
+
+#endif /* COBJMACROS */
+
+
+#endif /* C style interface */
+
+
+
+
+#endif /* __IDeckLinkAudioInputPacket_INTERFACE_DEFINED__ */
+
+
+#ifndef __IDeckLinkScreenPreviewCallback_INTERFACE_DEFINED__
+#define __IDeckLinkScreenPreviewCallback_INTERFACE_DEFINED__
+
+/* interface IDeckLinkScreenPreviewCallback */
+/* [helpstring][local][uuid][object] */
+
+
+EXTERN_C const IID IID_IDeckLinkScreenPreviewCallback;
+
+#if defined(__cplusplus) && !defined(CINTERFACE)
+
+ MIDL_INTERFACE("B1D3F49A-85FE-4C5D-95C8-0B5D5DCCD438")
+ IDeckLinkScreenPreviewCallback : public IUnknown
+ {
+ public:
+ virtual HRESULT STDMETHODCALLTYPE DrawFrame(
+ /* [in] */ IDeckLinkVideoFrame *theFrame) = 0;
+
+ };
+
+#else /* C style interface */
+
+ typedef struct IDeckLinkScreenPreviewCallbackVtbl
+ {
+ BEGIN_INTERFACE
+
+ HRESULT ( STDMETHODCALLTYPE *QueryInterface )(
+ IDeckLinkScreenPreviewCallback * This,
+ /* [in] */ REFIID riid,
+ /* [iid_is][out] */
+ __RPC__deref_out void **ppvObject);
+
+ ULONG ( STDMETHODCALLTYPE *AddRef )(
+ IDeckLinkScreenPreviewCallback * This);
+
+ ULONG ( STDMETHODCALLTYPE *Release )(
+ IDeckLinkScreenPreviewCallback * This);
+
+ HRESULT ( STDMETHODCALLTYPE *DrawFrame )(
+ IDeckLinkScreenPreviewCallback * This,
+ /* [in] */ IDeckLinkVideoFrame *theFrame);
+
+ END_INTERFACE
+ } IDeckLinkScreenPreviewCallbackVtbl;
+
+ interface IDeckLinkScreenPreviewCallback
+ {
+ CONST_VTBL struct IDeckLinkScreenPreviewCallbackVtbl *lpVtbl;
+ };
+
+
+
+#ifdef COBJMACROS
+
+
+#define IDeckLinkScreenPreviewCallback_QueryInterface(This,riid,ppvObject) \
+ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) )
+
+#define IDeckLinkScreenPreviewCallback_AddRef(This) \
+ ( (This)->lpVtbl -> AddRef(This) )
+
+#define IDeckLinkScreenPreviewCallback_Release(This) \
+ ( (This)->lpVtbl -> Release(This) )
+
+
+#define IDeckLinkScreenPreviewCallback_DrawFrame(This,theFrame) \
+ ( (This)->lpVtbl -> DrawFrame(This,theFrame) )
+
+#endif /* COBJMACROS */
+
+
+#endif /* C style interface */
+
+
+
+
+#endif /* __IDeckLinkScreenPreviewCallback_INTERFACE_DEFINED__ */
+
+
+#ifndef __IDeckLinkGLScreenPreviewHelper_INTERFACE_DEFINED__
+#define __IDeckLinkGLScreenPreviewHelper_INTERFACE_DEFINED__
+
+/* interface IDeckLinkGLScreenPreviewHelper */
+/* [helpstring][local][uuid][object] */
+
+
+EXTERN_C const IID IID_IDeckLinkGLScreenPreviewHelper;
+
+#if defined(__cplusplus) && !defined(CINTERFACE)
+
+ MIDL_INTERFACE("504E2209-CAC7-4C1A-9FB4-C5BB6274D22F")
+ IDeckLinkGLScreenPreviewHelper : public IUnknown
+ {
+ public:
+ virtual HRESULT STDMETHODCALLTYPE InitializeGL( void) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE PaintGL( void) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE SetFrame(
+ /* [in] */ IDeckLinkVideoFrame *theFrame) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE Set3DPreviewFormat(
+ /* [in] */ BMD3DPreviewFormat previewFormat) = 0;
+
+ };
+
+#else /* C style interface */
+
+ typedef struct IDeckLinkGLScreenPreviewHelperVtbl
+ {
+ BEGIN_INTERFACE
+
+ HRESULT ( STDMETHODCALLTYPE *QueryInterface )(
+ IDeckLinkGLScreenPreviewHelper * This,
+ /* [in] */ REFIID riid,
+ /* [iid_is][out] */
+ __RPC__deref_out void **ppvObject);
+
+ ULONG ( STDMETHODCALLTYPE *AddRef )(
+ IDeckLinkGLScreenPreviewHelper * This);
+
+ ULONG ( STDMETHODCALLTYPE *Release )(
+ IDeckLinkGLScreenPreviewHelper * This);
+
+ HRESULT ( STDMETHODCALLTYPE *InitializeGL )(
+ IDeckLinkGLScreenPreviewHelper * This);
+
+ HRESULT ( STDMETHODCALLTYPE *PaintGL )(
+ IDeckLinkGLScreenPreviewHelper * This);
+
+ HRESULT ( STDMETHODCALLTYPE *SetFrame )(
+ IDeckLinkGLScreenPreviewHelper * This,
+ /* [in] */ IDeckLinkVideoFrame *theFrame);
+
+ HRESULT ( STDMETHODCALLTYPE *Set3DPreviewFormat )(
+ IDeckLinkGLScreenPreviewHelper * This,
+ /* [in] */ BMD3DPreviewFormat previewFormat);
+
+ END_INTERFACE
+ } IDeckLinkGLScreenPreviewHelperVtbl;
+
+ interface IDeckLinkGLScreenPreviewHelper
+ {
+ CONST_VTBL struct IDeckLinkGLScreenPreviewHelperVtbl *lpVtbl;
+ };
+
+
+
+#ifdef COBJMACROS
+
+
+#define IDeckLinkGLScreenPreviewHelper_QueryInterface(This,riid,ppvObject) \
+ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) )
+
+#define IDeckLinkGLScreenPreviewHelper_AddRef(This) \
+ ( (This)->lpVtbl -> AddRef(This) )
+
+#define IDeckLinkGLScreenPreviewHelper_Release(This) \
+ ( (This)->lpVtbl -> Release(This) )
+
+
+#define IDeckLinkGLScreenPreviewHelper_InitializeGL(This) \
+ ( (This)->lpVtbl -> InitializeGL(This) )
+
+#define IDeckLinkGLScreenPreviewHelper_PaintGL(This) \
+ ( (This)->lpVtbl -> PaintGL(This) )
+
+#define IDeckLinkGLScreenPreviewHelper_SetFrame(This,theFrame) \
+ ( (This)->lpVtbl -> SetFrame(This,theFrame) )
+
+#define IDeckLinkGLScreenPreviewHelper_Set3DPreviewFormat(This,previewFormat) \
+ ( (This)->lpVtbl -> Set3DPreviewFormat(This,previewFormat) )
+
+#endif /* COBJMACROS */
+
+
+#endif /* C style interface */
+
+
+
+
+#endif /* __IDeckLinkGLScreenPreviewHelper_INTERFACE_DEFINED__ */
+
+
+#ifndef __IDeckLinkConfiguration_INTERFACE_DEFINED__
+#define __IDeckLinkConfiguration_INTERFACE_DEFINED__
+
+/* interface IDeckLinkConfiguration */
+/* [helpstring][local][uuid][object] */
+
+
+EXTERN_C const IID IID_IDeckLinkConfiguration;
+
+#if defined(__cplusplus) && !defined(CINTERFACE)
+
+ MIDL_INTERFACE("C679A35B-610C-4D09-B748-1D0478100FC0")
+ IDeckLinkConfiguration : public IUnknown
+ {
+ public:
+ virtual HRESULT STDMETHODCALLTYPE SetFlag(
+ /* [in] */ BMDDeckLinkConfigurationID cfgID,
+ /* [in] */ BOOL value) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE GetFlag(
+ /* [in] */ BMDDeckLinkConfigurationID cfgID,
+ /* [out] */ BOOL *value) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE SetInt(
+ /* [in] */ BMDDeckLinkConfigurationID cfgID,
+ /* [in] */ LONGLONG value) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE GetInt(
+ /* [in] */ BMDDeckLinkConfigurationID cfgID,
+ /* [out] */ LONGLONG *value) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE SetFloat(
+ /* [in] */ BMDDeckLinkConfigurationID cfgID,
+ /* [in] */ double value) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE GetFloat(
+ /* [in] */ BMDDeckLinkConfigurationID cfgID,
+ /* [out] */ double *value) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE SetString(
+ /* [in] */ BMDDeckLinkConfigurationID cfgID,
+ /* [in] */ BSTR value) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE GetString(
+ /* [in] */ BMDDeckLinkConfigurationID cfgID,
+ /* [out] */ BSTR *value) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE WriteConfigurationToPreferences( void) = 0;
+
+ };
+
+#else /* C style interface */
+
+ typedef struct IDeckLinkConfigurationVtbl
+ {
+ BEGIN_INTERFACE
+
+ HRESULT ( STDMETHODCALLTYPE *QueryInterface )(
+ IDeckLinkConfiguration * This,
+ /* [in] */ REFIID riid,
+ /* [iid_is][out] */
+ __RPC__deref_out void **ppvObject);
+
+ ULONG ( STDMETHODCALLTYPE *AddRef )(
+ IDeckLinkConfiguration * This);
+
+ ULONG ( STDMETHODCALLTYPE *Release )(
+ IDeckLinkConfiguration * This);
+
+ HRESULT ( STDMETHODCALLTYPE *SetFlag )(
+ IDeckLinkConfiguration * This,
+ /* [in] */ BMDDeckLinkConfigurationID cfgID,
+ /* [in] */ BOOL value);
+
+ HRESULT ( STDMETHODCALLTYPE *GetFlag )(
+ IDeckLinkConfiguration * This,
+ /* [in] */ BMDDeckLinkConfigurationID cfgID,
+ /* [out] */ BOOL *value);
+
+ HRESULT ( STDMETHODCALLTYPE *SetInt )(
+ IDeckLinkConfiguration * This,
+ /* [in] */ BMDDeckLinkConfigurationID cfgID,
+ /* [in] */ LONGLONG value);
+
+ HRESULT ( STDMETHODCALLTYPE *GetInt )(
+ IDeckLinkConfiguration * This,
+ /* [in] */ BMDDeckLinkConfigurationID cfgID,
+ /* [out] */ LONGLONG *value);
+
+ HRESULT ( STDMETHODCALLTYPE *SetFloat )(
+ IDeckLinkConfiguration * This,
+ /* [in] */ BMDDeckLinkConfigurationID cfgID,
+ /* [in] */ double value);
+
+ HRESULT ( STDMETHODCALLTYPE *GetFloat )(
+ IDeckLinkConfiguration * This,
+ /* [in] */ BMDDeckLinkConfigurationID cfgID,
+ /* [out] */ double *value);
+
+ HRESULT ( STDMETHODCALLTYPE *SetString )(
+ IDeckLinkConfiguration * This,
+ /* [in] */ BMDDeckLinkConfigurationID cfgID,
+ /* [in] */ BSTR value);
+
+ HRESULT ( STDMETHODCALLTYPE *GetString )(
+ IDeckLinkConfiguration * This,
+ /* [in] */ BMDDeckLinkConfigurationID cfgID,
+ /* [out] */ BSTR *value);
+
+ HRESULT ( STDMETHODCALLTYPE *WriteConfigurationToPreferences )(
+ IDeckLinkConfiguration * This);
+
+ END_INTERFACE
+ } IDeckLinkConfigurationVtbl;
+
+ interface IDeckLinkConfiguration
+ {
+ CONST_VTBL struct IDeckLinkConfigurationVtbl *lpVtbl;
+ };
+
+
+
+#ifdef COBJMACROS
+
+
+#define IDeckLinkConfiguration_QueryInterface(This,riid,ppvObject) \
+ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) )
+
+#define IDeckLinkConfiguration_AddRef(This) \
+ ( (This)->lpVtbl -> AddRef(This) )
+
+#define IDeckLinkConfiguration_Release(This) \
+ ( (This)->lpVtbl -> Release(This) )
+
+
+#define IDeckLinkConfiguration_SetFlag(This,cfgID,value) \
+ ( (This)->lpVtbl -> SetFlag(This,cfgID,value) )
+
+#define IDeckLinkConfiguration_GetFlag(This,cfgID,value) \
+ ( (This)->lpVtbl -> GetFlag(This,cfgID,value) )
+
+#define IDeckLinkConfiguration_SetInt(This,cfgID,value) \
+ ( (This)->lpVtbl -> SetInt(This,cfgID,value) )
+
+#define IDeckLinkConfiguration_GetInt(This,cfgID,value) \
+ ( (This)->lpVtbl -> GetInt(This,cfgID,value) )
+
+#define IDeckLinkConfiguration_SetFloat(This,cfgID,value) \
+ ( (This)->lpVtbl -> SetFloat(This,cfgID,value) )
+
+#define IDeckLinkConfiguration_GetFloat(This,cfgID,value) \
+ ( (This)->lpVtbl -> GetFloat(This,cfgID,value) )
+
+#define IDeckLinkConfiguration_SetString(This,cfgID,value) \
+ ( (This)->lpVtbl -> SetString(This,cfgID,value) )
+
+#define IDeckLinkConfiguration_GetString(This,cfgID,value) \
+ ( (This)->lpVtbl -> GetString(This,cfgID,value) )
+
+#define IDeckLinkConfiguration_WriteConfigurationToPreferences(This) \
+ ( (This)->lpVtbl -> WriteConfigurationToPreferences(This) )
+
+#endif /* COBJMACROS */
+
+
+#endif /* C style interface */
+
+
+
+
+#endif /* __IDeckLinkConfiguration_INTERFACE_DEFINED__ */
+
+
+#ifndef __IDeckLinkAttributes_INTERFACE_DEFINED__
+#define __IDeckLinkAttributes_INTERFACE_DEFINED__
+
+/* interface IDeckLinkAttributes */
+/* [helpstring][local][uuid][object] */
+
+
+EXTERN_C const IID IID_IDeckLinkAttributes;
+
+#if defined(__cplusplus) && !defined(CINTERFACE)
+
+ MIDL_INTERFACE("ABC11843-D966-44CB-96E2-A1CB5D3135C4")
+ IDeckLinkAttributes : public IUnknown
+ {
+ public:
+ virtual HRESULT STDMETHODCALLTYPE GetFlag(
+ /* [in] */ BMDDeckLinkAttributeID cfgID,
+ /* [out] */ BOOL *value) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE GetInt(
+ /* [in] */ BMDDeckLinkAttributeID cfgID,
+ /* [out] */ LONGLONG *value) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE GetFloat(
+ /* [in] */ BMDDeckLinkAttributeID cfgID,
+ /* [out] */ double *value) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE GetString(
+ /* [in] */ BMDDeckLinkAttributeID cfgID,
+ /* [out] */ BSTR *value) = 0;
+
+ };
+
+#else /* C style interface */
+
+ typedef struct IDeckLinkAttributesVtbl
+ {
+ BEGIN_INTERFACE
+
+ HRESULT ( STDMETHODCALLTYPE *QueryInterface )(
+ IDeckLinkAttributes * This,
+ /* [in] */ REFIID riid,
+ /* [iid_is][out] */
+ __RPC__deref_out void **ppvObject);
+
+ ULONG ( STDMETHODCALLTYPE *AddRef )(
+ IDeckLinkAttributes * This);
+
+ ULONG ( STDMETHODCALLTYPE *Release )(
+ IDeckLinkAttributes * This);
+
+ HRESULT ( STDMETHODCALLTYPE *GetFlag )(
+ IDeckLinkAttributes * This,
+ /* [in] */ BMDDeckLinkAttributeID cfgID,
+ /* [out] */ BOOL *value);
+
+ HRESULT ( STDMETHODCALLTYPE *GetInt )(
+ IDeckLinkAttributes * This,
+ /* [in] */ BMDDeckLinkAttributeID cfgID,
+ /* [out] */ LONGLONG *value);
+
+ HRESULT ( STDMETHODCALLTYPE *GetFloat )(
+ IDeckLinkAttributes * This,
+ /* [in] */ BMDDeckLinkAttributeID cfgID,
+ /* [out] */ double *value);
+
+ HRESULT ( STDMETHODCALLTYPE *GetString )(
+ IDeckLinkAttributes * This,
+ /* [in] */ BMDDeckLinkAttributeID cfgID,
+ /* [out] */ BSTR *value);
+
+ END_INTERFACE
+ } IDeckLinkAttributesVtbl;
+
+ interface IDeckLinkAttributes
+ {
+ CONST_VTBL struct IDeckLinkAttributesVtbl *lpVtbl;
+ };
+
+
+
+#ifdef COBJMACROS
+
+
+#define IDeckLinkAttributes_QueryInterface(This,riid,ppvObject) \
+ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) )
+
+#define IDeckLinkAttributes_AddRef(This) \
+ ( (This)->lpVtbl -> AddRef(This) )
+
+#define IDeckLinkAttributes_Release(This) \
+ ( (This)->lpVtbl -> Release(This) )
+
+
+#define IDeckLinkAttributes_GetFlag(This,cfgID,value) \
+ ( (This)->lpVtbl -> GetFlag(This,cfgID,value) )
+
+#define IDeckLinkAttributes_GetInt(This,cfgID,value) \
+ ( (This)->lpVtbl -> GetInt(This,cfgID,value) )
+
+#define IDeckLinkAttributes_GetFloat(This,cfgID,value) \
+ ( (This)->lpVtbl -> GetFloat(This,cfgID,value) )
+
+#define IDeckLinkAttributes_GetString(This,cfgID,value) \
+ ( (This)->lpVtbl -> GetString(This,cfgID,value) )
+
+#endif /* COBJMACROS */
+
+
+#endif /* C style interface */
+
+
+
+
+#endif /* __IDeckLinkAttributes_INTERFACE_DEFINED__ */
+
+
+#ifndef __IDeckLinkKeyer_INTERFACE_DEFINED__
+#define __IDeckLinkKeyer_INTERFACE_DEFINED__
+
+/* interface IDeckLinkKeyer */
+/* [helpstring][local][uuid][object] */
+
+
+EXTERN_C const IID IID_IDeckLinkKeyer;
+
+#if defined(__cplusplus) && !defined(CINTERFACE)
+
+ MIDL_INTERFACE("89AFCAF5-65F8-421E-98F7-96FE5F5BFBA3")
+ IDeckLinkKeyer : public IUnknown
+ {
+ public:
+ virtual HRESULT STDMETHODCALLTYPE Enable(
+ /* [in] */ BOOL isExternal) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE SetLevel(
+ /* [in] */ unsigned char level) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE RampUp(
+ /* [in] */ unsigned long numberOfFrames) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE RampDown(
+ /* [in] */ unsigned long numberOfFrames) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE Disable( void) = 0;
+
+ };
+
+#else /* C style interface */
+
+ typedef struct IDeckLinkKeyerVtbl
+ {
+ BEGIN_INTERFACE
+
+ HRESULT ( STDMETHODCALLTYPE *QueryInterface )(
+ IDeckLinkKeyer * This,
+ /* [in] */ REFIID riid,
+ /* [iid_is][out] */
+ __RPC__deref_out void **ppvObject);
+
+ ULONG ( STDMETHODCALLTYPE *AddRef )(
+ IDeckLinkKeyer * This);
+
+ ULONG ( STDMETHODCALLTYPE *Release )(
+ IDeckLinkKeyer * This);
+
+ HRESULT ( STDMETHODCALLTYPE *Enable )(
+ IDeckLinkKeyer * This,
+ /* [in] */ BOOL isExternal);
+
+ HRESULT ( STDMETHODCALLTYPE *SetLevel )(
+ IDeckLinkKeyer * This,
+ /* [in] */ unsigned char level);
+
+ HRESULT ( STDMETHODCALLTYPE *RampUp )(
+ IDeckLinkKeyer * This,
+ /* [in] */ unsigned long numberOfFrames);
+
+ HRESULT ( STDMETHODCALLTYPE *RampDown )(
+ IDeckLinkKeyer * This,
+ /* [in] */ unsigned long numberOfFrames);
+
+ HRESULT ( STDMETHODCALLTYPE *Disable )(
+ IDeckLinkKeyer * This);
+
+ END_INTERFACE
+ } IDeckLinkKeyerVtbl;
+
+ interface IDeckLinkKeyer
+ {
+ CONST_VTBL struct IDeckLinkKeyerVtbl *lpVtbl;
+ };
+
+
+
+#ifdef COBJMACROS
+
+
+#define IDeckLinkKeyer_QueryInterface(This,riid,ppvObject) \
+ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) )
+
+#define IDeckLinkKeyer_AddRef(This) \
+ ( (This)->lpVtbl -> AddRef(This) )
+
+#define IDeckLinkKeyer_Release(This) \
+ ( (This)->lpVtbl -> Release(This) )
+
+
+#define IDeckLinkKeyer_Enable(This,isExternal) \
+ ( (This)->lpVtbl -> Enable(This,isExternal) )
+
+#define IDeckLinkKeyer_SetLevel(This,level) \
+ ( (This)->lpVtbl -> SetLevel(This,level) )
+
+#define IDeckLinkKeyer_RampUp(This,numberOfFrames) \
+ ( (This)->lpVtbl -> RampUp(This,numberOfFrames) )
+
+#define IDeckLinkKeyer_RampDown(This,numberOfFrames) \
+ ( (This)->lpVtbl -> RampDown(This,numberOfFrames) )
+
+#define IDeckLinkKeyer_Disable(This) \
+ ( (This)->lpVtbl -> Disable(This) )
+
+#endif /* COBJMACROS */
+
+
+#endif /* C style interface */
+
+
+
+
+#endif /* __IDeckLinkKeyer_INTERFACE_DEFINED__ */
+
+
+#ifndef __IDeckLinkVideoConversion_INTERFACE_DEFINED__
+#define __IDeckLinkVideoConversion_INTERFACE_DEFINED__
+
+/* interface IDeckLinkVideoConversion */
+/* [helpstring][local][uuid][object] */
+
+
+EXTERN_C const IID IID_IDeckLinkVideoConversion;
+
+#if defined(__cplusplus) && !defined(CINTERFACE)
+
+ MIDL_INTERFACE("3BBCB8A2-DA2C-42D9-B5D8-88083644E99A")
+ IDeckLinkVideoConversion : public IUnknown
+ {
+ public:
+ virtual HRESULT STDMETHODCALLTYPE ConvertFrame(
+ /* [in] */ IDeckLinkVideoFrame *srcFrame,
+ /* [in] */ IDeckLinkVideoFrame *dstFrame) = 0;
+
+ };
+
+#else /* C style interface */
+
+ typedef struct IDeckLinkVideoConversionVtbl
+ {
+ BEGIN_INTERFACE
+
+ HRESULT ( STDMETHODCALLTYPE *QueryInterface )(
+ IDeckLinkVideoConversion * This,
+ /* [in] */ REFIID riid,
+ /* [iid_is][out] */
+ __RPC__deref_out void **ppvObject);
+
+ ULONG ( STDMETHODCALLTYPE *AddRef )(
+ IDeckLinkVideoConversion * This);
+
+ ULONG ( STDMETHODCALLTYPE *Release )(
+ IDeckLinkVideoConversion * This);
+
+ HRESULT ( STDMETHODCALLTYPE *ConvertFrame )(
+ IDeckLinkVideoConversion * This,
+ /* [in] */ IDeckLinkVideoFrame *srcFrame,
+ /* [in] */ IDeckLinkVideoFrame *dstFrame);
+
+ END_INTERFACE
+ } IDeckLinkVideoConversionVtbl;
+
+ interface IDeckLinkVideoConversion
+ {
+ CONST_VTBL struct IDeckLinkVideoConversionVtbl *lpVtbl;
+ };
+
+
+
+#ifdef COBJMACROS
+
+
+#define IDeckLinkVideoConversion_QueryInterface(This,riid,ppvObject) \
+ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) )
+
+#define IDeckLinkVideoConversion_AddRef(This) \
+ ( (This)->lpVtbl -> AddRef(This) )
+
+#define IDeckLinkVideoConversion_Release(This) \
+ ( (This)->lpVtbl -> Release(This) )
+
+
+#define IDeckLinkVideoConversion_ConvertFrame(This,srcFrame,dstFrame) \
+ ( (This)->lpVtbl -> ConvertFrame(This,srcFrame,dstFrame) )
+
+#endif /* COBJMACROS */
+
+
+#endif /* C style interface */
+
+
+
+
+#endif /* __IDeckLinkVideoConversion_INTERFACE_DEFINED__ */
+
+
+#ifndef __IDeckLinkDeckControlStatusCallback_INTERFACE_DEFINED__
+#define __IDeckLinkDeckControlStatusCallback_INTERFACE_DEFINED__
+
+/* interface IDeckLinkDeckControlStatusCallback */
+/* [helpstring][uuid][object] */
+
+
+EXTERN_C const IID IID_IDeckLinkDeckControlStatusCallback;
+
+#if defined(__cplusplus) && !defined(CINTERFACE)
+
+ MIDL_INTERFACE("E5F693C1-4283-4716-B18F-C1431521955B")
+ IDeckLinkDeckControlStatusCallback : public IUnknown
+ {
+ public:
+ virtual HRESULT STDMETHODCALLTYPE TimecodeUpdate(
+ /* [in] */ BMDTimecodeBCD currentTimecode) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE VTRControlStateChanged(
+ /* [in] */ BMDDeckControlVTRControlState newState,
+ /* [in] */ BMDDeckControlError error) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE DeckControlEventReceived(
+ /* [in] */ BMDDeckControlEvent event,
+ /* [in] */ BMDDeckControlError error) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE DeckControlStatusChanged(
+ /* [in] */ BMDDeckControlStatusFlags flags,
+ /* [in] */ unsigned long mask) = 0;
+
+ };
+
+#else /* C style interface */
+
+ typedef struct IDeckLinkDeckControlStatusCallbackVtbl
+ {
+ BEGIN_INTERFACE
+
+ HRESULT ( STDMETHODCALLTYPE *QueryInterface )(
+ IDeckLinkDeckControlStatusCallback * This,
+ /* [in] */ REFIID riid,
+ /* [iid_is][out] */
+ __RPC__deref_out void **ppvObject);
+
+ ULONG ( STDMETHODCALLTYPE *AddRef )(
+ IDeckLinkDeckControlStatusCallback * This);
+
+ ULONG ( STDMETHODCALLTYPE *Release )(
+ IDeckLinkDeckControlStatusCallback * This);
+
+ HRESULT ( STDMETHODCALLTYPE *TimecodeUpdate )(
+ IDeckLinkDeckControlStatusCallback * This,
+ /* [in] */ BMDTimecodeBCD currentTimecode);
+
+ HRESULT ( STDMETHODCALLTYPE *VTRControlStateChanged )(
+ IDeckLinkDeckControlStatusCallback * This,
+ /* [in] */ BMDDeckControlVTRControlState newState,
+ /* [in] */ BMDDeckControlError error);
+
+ HRESULT ( STDMETHODCALLTYPE *DeckControlEventReceived )(
+ IDeckLinkDeckControlStatusCallback * This,
+ /* [in] */ BMDDeckControlEvent event,
+ /* [in] */ BMDDeckControlError error);
+
+ HRESULT ( STDMETHODCALLTYPE *DeckControlStatusChanged )(
+ IDeckLinkDeckControlStatusCallback * This,
+ /* [in] */ BMDDeckControlStatusFlags flags,
+ /* [in] */ unsigned long mask);
+
+ END_INTERFACE
+ } IDeckLinkDeckControlStatusCallbackVtbl;
+
+ interface IDeckLinkDeckControlStatusCallback
+ {
+ CONST_VTBL struct IDeckLinkDeckControlStatusCallbackVtbl *lpVtbl;
+ };
+
+
+
+#ifdef COBJMACROS
+
+
+#define IDeckLinkDeckControlStatusCallback_QueryInterface(This,riid,ppvObject) \
+ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) )
+
+#define IDeckLinkDeckControlStatusCallback_AddRef(This) \
+ ( (This)->lpVtbl -> AddRef(This) )
+
+#define IDeckLinkDeckControlStatusCallback_Release(This) \
+ ( (This)->lpVtbl -> Release(This) )
+
+
+#define IDeckLinkDeckControlStatusCallback_TimecodeUpdate(This,currentTimecode) \
+ ( (This)->lpVtbl -> TimecodeUpdate(This,currentTimecode) )
+
+#define IDeckLinkDeckControlStatusCallback_VTRControlStateChanged(This,newState,error) \
+ ( (This)->lpVtbl -> VTRControlStateChanged(This,newState,error) )
+
+#define IDeckLinkDeckControlStatusCallback_DeckControlEventReceived(This,event,error) \
+ ( (This)->lpVtbl -> DeckControlEventReceived(This,event,error) )
+
+#define IDeckLinkDeckControlStatusCallback_DeckControlStatusChanged(This,flags,mask) \
+ ( (This)->lpVtbl -> DeckControlStatusChanged(This,flags,mask) )
+
+#endif /* COBJMACROS */
+
+
+#endif /* C style interface */
+
+
+
+
+#endif /* __IDeckLinkDeckControlStatusCallback_INTERFACE_DEFINED__ */
+
+
+#ifndef __IDeckLinkDeckControl_INTERFACE_DEFINED__
+#define __IDeckLinkDeckControl_INTERFACE_DEFINED__
+
+/* interface IDeckLinkDeckControl */
+/* [helpstring][uuid][object] */
+
+
+EXTERN_C const IID IID_IDeckLinkDeckControl;
+
+#if defined(__cplusplus) && !defined(CINTERFACE)
+
+ MIDL_INTERFACE("522A9E39-0F3C-4742-94EE-D80DE335DA1D")
+ IDeckLinkDeckControl : public IUnknown
+ {
+ public:
+ virtual HRESULT STDMETHODCALLTYPE Open(
+ /* [in] */ BMDTimeScale timeScale,
+ /* [in] */ BMDTimeValue timeValue,
+ /* [in] */ BOOL timecodeIsDropFrame,
+ /* [out] */ BMDDeckControlError *error) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE Close(
+ /* [in] */ BOOL standbyOn) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE GetCurrentState(
+ /* [out] */ BMDDeckControlMode *mode,
+ /* [out] */ BMDDeckControlVTRControlState *vtrControlState,
+ /* [out] */ BMDDeckControlStatusFlags *flags) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE SetStandby(
+ /* [in] */ BOOL standbyOn) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE SendCommand(
+ /* [in] */ unsigned char *inBuffer,
+ /* [in] */ unsigned long inBufferSize,
+ /* [out] */ unsigned char *outBuffer,
+ /* [out] */ unsigned long *outDataSize,
+ /* [in] */ unsigned long outBufferSize,
+ /* [out] */ BMDDeckControlError *error) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE Play(
+ /* [out] */ BMDDeckControlError *error) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE Stop(
+ /* [out] */ BMDDeckControlError *error) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE TogglePlayStop(
+ /* [out] */ BMDDeckControlError *error) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE Eject(
+ /* [out] */ BMDDeckControlError *error) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE GoToTimecode(
+ /* [in] */ BMDTimecodeBCD timecode,
+ /* [out] */ BMDDeckControlError *error) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE FastForward(
+ /* [in] */ BOOL viewTape,
+ /* [out] */ BMDDeckControlError *error) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE Rewind(
+ /* [in] */ BOOL viewTape,
+ /* [out] */ BMDDeckControlError *error) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE StepForward(
+ /* [out] */ BMDDeckControlError *error) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE StepBack(
+ /* [out] */ BMDDeckControlError *error) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE Jog(
+ /* [in] */ double rate,
+ /* [out] */ BMDDeckControlError *error) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE Shuttle(
+ /* [in] */ double rate,
+ /* [out] */ BMDDeckControlError *error) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE GetTimecodeString(
+ /* [out] */ BSTR *currentTimeCode,
+ /* [out] */ BMDDeckControlError *error) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE GetTimecode(
+ /* [out] */ IDeckLinkTimecode **currentTimecode,
+ /* [out] */ BMDDeckControlError *error) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE GetTimecodeBCD(
+ /* [out] */ BMDTimecodeBCD *currentTimecode,
+ /* [out] */ BMDDeckControlError *error) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE SetPreroll(
+ /* [in] */ unsigned long prerollSeconds) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE GetPreroll(
+ /* [out] */ unsigned long *prerollSeconds) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE SetExportOffset(
+ /* [in] */ long exportOffsetFields) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE GetExportOffset(
+ /* [out] */ long *exportOffsetFields) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE GetManualExportOffset(
+ /* [out] */ long *deckManualExportOffsetFields) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE SetCaptureOffset(
+ /* [in] */ long captureOffsetFields) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE GetCaptureOffset(
+ /* [out] */ long *captureOffsetFields) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE StartExport(
+ /* [in] */ BMDTimecodeBCD inTimecode,
+ /* [in] */ BMDTimecodeBCD outTimecode,
+ /* [in] */ BMDDeckControlExportModeOpsFlags exportModeOps,
+ /* [out] */ BMDDeckControlError *error) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE StartCapture(
+ /* [in] */ BOOL useVITC,
+ /* [in] */ BMDTimecodeBCD inTimecode,
+ /* [in] */ BMDTimecodeBCD outTimecode,
+ /* [out] */ BMDDeckControlError *error) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE GetDeviceID(
+ /* [out] */ unsigned short *deviceId,
+ /* [out] */ BMDDeckControlError *error) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE Abort( void) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE CrashRecordStart(
+ /* [out] */ BMDDeckControlError *error) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE CrashRecordStop(
+ /* [out] */ BMDDeckControlError *error) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE SetCallback(
+ /* [in] */ IDeckLinkDeckControlStatusCallback *callback) = 0;
+
+ };
+
+#else /* C style interface */
+
+ typedef struct IDeckLinkDeckControlVtbl
+ {
+ BEGIN_INTERFACE
+
+ HRESULT ( STDMETHODCALLTYPE *QueryInterface )(
+ IDeckLinkDeckControl * This,
+ /* [in] */ REFIID riid,
+ /* [iid_is][out] */
+ __RPC__deref_out void **ppvObject);
+
+ ULONG ( STDMETHODCALLTYPE *AddRef )(
+ IDeckLinkDeckControl * This);
+
+ ULONG ( STDMETHODCALLTYPE *Release )(
+ IDeckLinkDeckControl * This);
+
+ HRESULT ( STDMETHODCALLTYPE *Open )(
+ IDeckLinkDeckControl * This,
+ /* [in] */ BMDTimeScale timeScale,
+ /* [in] */ BMDTimeValue timeValue,
+ /* [in] */ BOOL timecodeIsDropFrame,
+ /* [out] */ BMDDeckControlError *error);
+
+ HRESULT ( STDMETHODCALLTYPE *Close )(
+ IDeckLinkDeckControl * This,
+ /* [in] */ BOOL standbyOn);
+
+ HRESULT ( STDMETHODCALLTYPE *GetCurrentState )(
+ IDeckLinkDeckControl * This,
+ /* [out] */ BMDDeckControlMode *mode,
+ /* [out] */ BMDDeckControlVTRControlState *vtrControlState,
+ /* [out] */ BMDDeckControlStatusFlags *flags);
+
+ HRESULT ( STDMETHODCALLTYPE *SetStandby )(
+ IDeckLinkDeckControl * This,
+ /* [in] */ BOOL standbyOn);
+
+ HRESULT ( STDMETHODCALLTYPE *SendCommand )(
+ IDeckLinkDeckControl * This,
+ /* [in] */ unsigned char *inBuffer,
+ /* [in] */ unsigned long inBufferSize,
+ /* [out] */ unsigned char *outBuffer,
+ /* [out] */ unsigned long *outDataSize,
+ /* [in] */ unsigned long outBufferSize,
+ /* [out] */ BMDDeckControlError *error);
+
+ HRESULT ( STDMETHODCALLTYPE *Play )(
+ IDeckLinkDeckControl * This,
+ /* [out] */ BMDDeckControlError *error);
+
+ HRESULT ( STDMETHODCALLTYPE *Stop )(
+ IDeckLinkDeckControl * This,
+ /* [out] */ BMDDeckControlError *error);
+
+ HRESULT ( STDMETHODCALLTYPE *TogglePlayStop )(
+ IDeckLinkDeckControl * This,
+ /* [out] */ BMDDeckControlError *error);
+
+ HRESULT ( STDMETHODCALLTYPE *Eject )(
+ IDeckLinkDeckControl * This,
+ /* [out] */ BMDDeckControlError *error);
+
+ HRESULT ( STDMETHODCALLTYPE *GoToTimecode )(
+ IDeckLinkDeckControl * This,
+ /* [in] */ BMDTimecodeBCD timecode,
+ /* [out] */ BMDDeckControlError *error);
+
+ HRESULT ( STDMETHODCALLTYPE *FastForward )(
+ IDeckLinkDeckControl * This,
+ /* [in] */ BOOL viewTape,
+ /* [out] */ BMDDeckControlError *error);
+
+ HRESULT ( STDMETHODCALLTYPE *Rewind )(
+ IDeckLinkDeckControl * This,
+ /* [in] */ BOOL viewTape,
+ /* [out] */ BMDDeckControlError *error);
+
+ HRESULT ( STDMETHODCALLTYPE *StepForward )(
+ IDeckLinkDeckControl * This,
+ /* [out] */ BMDDeckControlError *error);
+
+ HRESULT ( STDMETHODCALLTYPE *StepBack )(
+ IDeckLinkDeckControl * This,
+ /* [out] */ BMDDeckControlError *error);
+
+ HRESULT ( STDMETHODCALLTYPE *Jog )(
+ IDeckLinkDeckControl * This,
+ /* [in] */ double rate,
+ /* [out] */ BMDDeckControlError *error);
+
+ HRESULT ( STDMETHODCALLTYPE *Shuttle )(
+ IDeckLinkDeckControl * This,
+ /* [in] */ double rate,
+ /* [out] */ BMDDeckControlError *error);
+
+ HRESULT ( STDMETHODCALLTYPE *GetTimecodeString )(
+ IDeckLinkDeckControl * This,
+ /* [out] */ BSTR *currentTimeCode,
+ /* [out] */ BMDDeckControlError *error);
+
+ HRESULT ( STDMETHODCALLTYPE *GetTimecode )(
+ IDeckLinkDeckControl * This,
+ /* [out] */ IDeckLinkTimecode **currentTimecode,
+ /* [out] */ BMDDeckControlError *error);
+
+ HRESULT ( STDMETHODCALLTYPE *GetTimecodeBCD )(
+ IDeckLinkDeckControl * This,
+ /* [out] */ BMDTimecodeBCD *currentTimecode,
+ /* [out] */ BMDDeckControlError *error);
+
+ HRESULT ( STDMETHODCALLTYPE *SetPreroll )(
+ IDeckLinkDeckControl * This,
+ /* [in] */ unsigned long prerollSeconds);
+
+ HRESULT ( STDMETHODCALLTYPE *GetPreroll )(
+ IDeckLinkDeckControl * This,
+ /* [out] */ unsigned long *prerollSeconds);
+
+ HRESULT ( STDMETHODCALLTYPE *SetExportOffset )(
+ IDeckLinkDeckControl * This,
+ /* [in] */ long exportOffsetFields);
+
+ HRESULT ( STDMETHODCALLTYPE *GetExportOffset )(
+ IDeckLinkDeckControl * This,
+ /* [out] */ long *exportOffsetFields);
+
+ HRESULT ( STDMETHODCALLTYPE *GetManualExportOffset )(
+ IDeckLinkDeckControl * This,
+ /* [out] */ long *deckManualExportOffsetFields);
+
+ HRESULT ( STDMETHODCALLTYPE *SetCaptureOffset )(
+ IDeckLinkDeckControl * This,
+ /* [in] */ long captureOffsetFields);
+
+ HRESULT ( STDMETHODCALLTYPE *GetCaptureOffset )(
+ IDeckLinkDeckControl * This,
+ /* [out] */ long *captureOffsetFields);
+
+ HRESULT ( STDMETHODCALLTYPE *StartExport )(
+ IDeckLinkDeckControl * This,
+ /* [in] */ BMDTimecodeBCD inTimecode,
+ /* [in] */ BMDTimecodeBCD outTimecode,
+ /* [in] */ BMDDeckControlExportModeOpsFlags exportModeOps,
+ /* [out] */ BMDDeckControlError *error);
+
+ HRESULT ( STDMETHODCALLTYPE *StartCapture )(
+ IDeckLinkDeckControl * This,
+ /* [in] */ BOOL useVITC,
+ /* [in] */ BMDTimecodeBCD inTimecode,
+ /* [in] */ BMDTimecodeBCD outTimecode,
+ /* [out] */ BMDDeckControlError *error);
+
+ HRESULT ( STDMETHODCALLTYPE *GetDeviceID )(
+ IDeckLinkDeckControl * This,
+ /* [out] */ unsigned short *deviceId,
+ /* [out] */ BMDDeckControlError *error);
+
+ HRESULT ( STDMETHODCALLTYPE *Abort )(
+ IDeckLinkDeckControl * This);
+
+ HRESULT ( STDMETHODCALLTYPE *CrashRecordStart )(
+ IDeckLinkDeckControl * This,
+ /* [out] */ BMDDeckControlError *error);
+
+ HRESULT ( STDMETHODCALLTYPE *CrashRecordStop )(
+ IDeckLinkDeckControl * This,
+ /* [out] */ BMDDeckControlError *error);
+
+ HRESULT ( STDMETHODCALLTYPE *SetCallback )(
+ IDeckLinkDeckControl * This,
+ /* [in] */ IDeckLinkDeckControlStatusCallback *callback);
+
+ END_INTERFACE
+ } IDeckLinkDeckControlVtbl;
+
+ interface IDeckLinkDeckControl
+ {
+ CONST_VTBL struct IDeckLinkDeckControlVtbl *lpVtbl;
+ };
+
+
+
+#ifdef COBJMACROS
+
+
+#define IDeckLinkDeckControl_QueryInterface(This,riid,ppvObject) \
+ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) )
+
+#define IDeckLinkDeckControl_AddRef(This) \
+ ( (This)->lpVtbl -> AddRef(This) )
+
+#define IDeckLinkDeckControl_Release(This) \
+ ( (This)->lpVtbl -> Release(This) )
+
+
+#define IDeckLinkDeckControl_Open(This,timeScale,timeValue,timecodeIsDropFrame,error) \
+ ( (This)->lpVtbl -> Open(This,timeScale,timeValue,timecodeIsDropFrame,error) )
+
+#define IDeckLinkDeckControl_Close(This,standbyOn) \
+ ( (This)->lpVtbl -> Close(This,standbyOn) )
+
+#define IDeckLinkDeckControl_GetCurrentState(This,mode,vtrControlState,flags) \
+ ( (This)->lpVtbl -> GetCurrentState(This,mode,vtrControlState,flags) )
+
+#define IDeckLinkDeckControl_SetStandby(This,standbyOn) \
+ ( (This)->lpVtbl -> SetStandby(This,standbyOn) )
+
+#define IDeckLinkDeckControl_SendCommand(This,inBuffer,inBufferSize,outBuffer,outDataSize,outBufferSize,error) \
+ ( (This)->lpVtbl -> SendCommand(This,inBuffer,inBufferSize,outBuffer,outDataSize,outBufferSize,error) )
+
+#define IDeckLinkDeckControl_Play(This,error) \
+ ( (This)->lpVtbl -> Play(This,error) )
+
+#define IDeckLinkDeckControl_Stop(This,error) \
+ ( (This)->lpVtbl -> Stop(This,error) )
+
+#define IDeckLinkDeckControl_TogglePlayStop(This,error) \
+ ( (This)->lpVtbl -> TogglePlayStop(This,error) )
+
+#define IDeckLinkDeckControl_Eject(This,error) \
+ ( (This)->lpVtbl -> Eject(This,error) )
+
+#define IDeckLinkDeckControl_GoToTimecode(This,timecode,error) \
+ ( (This)->lpVtbl -> GoToTimecode(This,timecode,error) )
+
+#define IDeckLinkDeckControl_FastForward(This,viewTape,error) \
+ ( (This)->lpVtbl -> FastForward(This,viewTape,error) )
+
+#define IDeckLinkDeckControl_Rewind(This,viewTape,error) \
+ ( (This)->lpVtbl -> Rewind(This,viewTape,error) )
+
+#define IDeckLinkDeckControl_StepForward(This,error) \
+ ( (This)->lpVtbl -> StepForward(This,error) )
+
+#define IDeckLinkDeckControl_StepBack(This,error) \
+ ( (This)->lpVtbl -> StepBack(This,error) )
+
+#define IDeckLinkDeckControl_Jog(This,rate,error) \
+ ( (This)->lpVtbl -> Jog(This,rate,error) )
+
+#define IDeckLinkDeckControl_Shuttle(This,rate,error) \
+ ( (This)->lpVtbl -> Shuttle(This,rate,error) )
+
+#define IDeckLinkDeckControl_GetTimecodeString(This,currentTimeCode,error) \
+ ( (This)->lpVtbl -> GetTimecodeString(This,currentTimeCode,error) )
+
+#define IDeckLinkDeckControl_GetTimecode(This,currentTimecode,error) \
+ ( (This)->lpVtbl -> GetTimecode(This,currentTimecode,error) )
+
+#define IDeckLinkDeckControl_GetTimecodeBCD(This,currentTimecode,error) \
+ ( (This)->lpVtbl -> GetTimecodeBCD(This,currentTimecode,error) )
+
+#define IDeckLinkDeckControl_SetPreroll(This,prerollSeconds) \
+ ( (This)->lpVtbl -> SetPreroll(This,prerollSeconds) )
+
+#define IDeckLinkDeckControl_GetPreroll(This,prerollSeconds) \
+ ( (This)->lpVtbl -> GetPreroll(This,prerollSeconds) )
+
+#define IDeckLinkDeckControl_SetExportOffset(This,exportOffsetFields) \
+ ( (This)->lpVtbl -> SetExportOffset(This,exportOffsetFields) )
+
+#define IDeckLinkDeckControl_GetExportOffset(This,exportOffsetFields) \
+ ( (This)->lpVtbl -> GetExportOffset(This,exportOffsetFields) )
+
+#define IDeckLinkDeckControl_GetManualExportOffset(This,deckManualExportOffsetFields) \
+ ( (This)->lpVtbl -> GetManualExportOffset(This,deckManualExportOffsetFields) )
+
+#define IDeckLinkDeckControl_SetCaptureOffset(This,captureOffsetFields) \
+ ( (This)->lpVtbl -> SetCaptureOffset(This,captureOffsetFields) )
+
+#define IDeckLinkDeckControl_GetCaptureOffset(This,captureOffsetFields) \
+ ( (This)->lpVtbl -> GetCaptureOffset(This,captureOffsetFields) )
+
+#define IDeckLinkDeckControl_StartExport(This,inTimecode,outTimecode,exportModeOps,error) \
+ ( (This)->lpVtbl -> StartExport(This,inTimecode,outTimecode,exportModeOps,error) )
+
+#define IDeckLinkDeckControl_StartCapture(This,useVITC,inTimecode,outTimecode,error) \
+ ( (This)->lpVtbl -> StartCapture(This,useVITC,inTimecode,outTimecode,error) )
+
+#define IDeckLinkDeckControl_GetDeviceID(This,deviceId,error) \
+ ( (This)->lpVtbl -> GetDeviceID(This,deviceId,error) )
+
+#define IDeckLinkDeckControl_Abort(This) \
+ ( (This)->lpVtbl -> Abort(This) )
+
+#define IDeckLinkDeckControl_CrashRecordStart(This,error) \
+ ( (This)->lpVtbl -> CrashRecordStart(This,error) )
+
+#define IDeckLinkDeckControl_CrashRecordStop(This,error) \
+ ( (This)->lpVtbl -> CrashRecordStop(This,error) )
+
+#define IDeckLinkDeckControl_SetCallback(This,callback) \
+ ( (This)->lpVtbl -> SetCallback(This,callback) )
+
+#endif /* COBJMACROS */
+
+
+#endif /* C style interface */
+
+
+
+
+#endif /* __IDeckLinkDeckControl_INTERFACE_DEFINED__ */
+
+
+EXTERN_C const CLSID CLSID_CDeckLinkIterator;
+
+#ifdef __cplusplus
+
+class DECLSPEC_UUID("D9EDA3B3-2887-41FA-B724-017CF1EB1D37")
+CDeckLinkIterator;
+#endif
+
+EXTERN_C const CLSID CLSID_CDeckLinkAPIInformation;
+
+#ifdef __cplusplus
+
+class DECLSPEC_UUID("263CA19F-ED09-482E-9F9D-84005783A237")
+CDeckLinkAPIInformation;
+#endif
+
+EXTERN_C const CLSID CLSID_CDeckLinkGLScreenPreviewHelper;
+
+#ifdef __cplusplus
+
+class DECLSPEC_UUID("F63E77C7-B655-4A4A-9AD0-3CA85D394343")
+CDeckLinkGLScreenPreviewHelper;
+#endif
+
+EXTERN_C const CLSID CLSID_CDeckLinkVideoConversion;
+
+#ifdef __cplusplus
+
+class DECLSPEC_UUID("7DBBBB11-5B7B-467D-AEA4-CEA468FD368C")
+CDeckLinkVideoConversion;
+#endif
+
+#ifndef __IDeckLinkDeckControl_v7_9_INTERFACE_DEFINED__
+#define __IDeckLinkDeckControl_v7_9_INTERFACE_DEFINED__
+
+/* interface IDeckLinkDeckControl_v7_9 */
+/* [helpstring][uuid][object] */
+
+
+EXTERN_C const IID IID_IDeckLinkDeckControl_v7_9;
+
+#if defined(__cplusplus) && !defined(CINTERFACE)
+
+ MIDL_INTERFACE("A4D81043-0619-42B7-8ED6-602D29041DF7")
+ IDeckLinkDeckControl_v7_9 : public IUnknown
+ {
+ public:
+ virtual HRESULT STDMETHODCALLTYPE Open(
+ /* [in] */ BMDTimeScale timeScale,
+ /* [in] */ BMDTimeValue timeValue,
+ /* [in] */ BOOL timecodeIsDropFrame,
+ /* [out] */ BMDDeckControlError *error) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE Close(
+ /* [in] */ BOOL standbyOn) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE GetCurrentState(
+ /* [out] */ BMDDeckControlMode *mode,
+ /* [out] */ BMDDeckControlVTRControlState *vtrControlState,
+ /* [out] */ BMDDeckControlStatusFlags *flags) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE SetStandby(
+ /* [in] */ BOOL standbyOn) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE Play(
+ /* [out] */ BMDDeckControlError *error) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE Stop(
+ /* [out] */ BMDDeckControlError *error) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE TogglePlayStop(
+ /* [out] */ BMDDeckControlError *error) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE Eject(
+ /* [out] */ BMDDeckControlError *error) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE GoToTimecode(
+ /* [in] */ BMDTimecodeBCD timecode,
+ /* [out] */ BMDDeckControlError *error) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE FastForward(
+ /* [in] */ BOOL viewTape,
+ /* [out] */ BMDDeckControlError *error) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE Rewind(
+ /* [in] */ BOOL viewTape,
+ /* [out] */ BMDDeckControlError *error) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE StepForward(
+ /* [out] */ BMDDeckControlError *error) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE StepBack(
+ /* [out] */ BMDDeckControlError *error) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE Jog(
+ /* [in] */ double rate,
+ /* [out] */ BMDDeckControlError *error) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE Shuttle(
+ /* [in] */ double rate,
+ /* [out] */ BMDDeckControlError *error) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE GetTimecodeString(
+ /* [out] */ BSTR *currentTimeCode,
+ /* [out] */ BMDDeckControlError *error) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE GetTimecode(
+ /* [out] */ IDeckLinkTimecode **currentTimecode,
+ /* [out] */ BMDDeckControlError *error) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE GetTimecodeBCD(
+ /* [out] */ BMDTimecodeBCD *currentTimecode,
+ /* [out] */ BMDDeckControlError *error) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE SetPreroll(
+ /* [in] */ unsigned long prerollSeconds) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE GetPreroll(
+ /* [out] */ unsigned long *prerollSeconds) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE SetExportOffset(
+ /* [in] */ long exportOffsetFields) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE GetExportOffset(
+ /* [out] */ long *exportOffsetFields) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE GetManualExportOffset(
+ /* [out] */ long *deckManualExportOffsetFields) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE SetCaptureOffset(
+ /* [in] */ long captureOffsetFields) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE GetCaptureOffset(
+ /* [out] */ long *captureOffsetFields) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE StartExport(
+ /* [in] */ BMDTimecodeBCD inTimecode,
+ /* [in] */ BMDTimecodeBCD outTimecode,
+ /* [in] */ BMDDeckControlExportModeOpsFlags exportModeOps,
+ /* [out] */ BMDDeckControlError *error) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE StartCapture(
+ /* [in] */ BOOL useVITC,
+ /* [in] */ BMDTimecodeBCD inTimecode,
+ /* [in] */ BMDTimecodeBCD outTimecode,
+ /* [out] */ BMDDeckControlError *error) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE GetDeviceID(
+ /* [out] */ unsigned short *deviceId,
+ /* [out] */ BMDDeckControlError *error) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE Abort( void) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE CrashRecordStart(
+ /* [out] */ BMDDeckControlError *error) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE CrashRecordStop(
+ /* [out] */ BMDDeckControlError *error) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE SetCallback(
+ /* [in] */ IDeckLinkDeckControlStatusCallback *callback) = 0;
+
+ };
+
+#else /* C style interface */
+
+ typedef struct IDeckLinkDeckControl_v7_9Vtbl
+ {
+ BEGIN_INTERFACE
+
+ HRESULT ( STDMETHODCALLTYPE *QueryInterface )(
+ IDeckLinkDeckControl_v7_9 * This,
+ /* [in] */ REFIID riid,
+ /* [iid_is][out] */
+ __RPC__deref_out void **ppvObject);
+
+ ULONG ( STDMETHODCALLTYPE *AddRef )(
+ IDeckLinkDeckControl_v7_9 * This);
+
+ ULONG ( STDMETHODCALLTYPE *Release )(
+ IDeckLinkDeckControl_v7_9 * This);
+
+ HRESULT ( STDMETHODCALLTYPE *Open )(
+ IDeckLinkDeckControl_v7_9 * This,
+ /* [in] */ BMDTimeScale timeScale,
+ /* [in] */ BMDTimeValue timeValue,
+ /* [in] */ BOOL timecodeIsDropFrame,
+ /* [out] */ BMDDeckControlError *error);
+
+ HRESULT ( STDMETHODCALLTYPE *Close )(
+ IDeckLinkDeckControl_v7_9 * This,
+ /* [in] */ BOOL standbyOn);
+
+ HRESULT ( STDMETHODCALLTYPE *GetCurrentState )(
+ IDeckLinkDeckControl_v7_9 * This,
+ /* [out] */ BMDDeckControlMode *mode,
+ /* [out] */ BMDDeckControlVTRControlState *vtrControlState,
+ /* [out] */ BMDDeckControlStatusFlags *flags);
+
+ HRESULT ( STDMETHODCALLTYPE *SetStandby )(
+ IDeckLinkDeckControl_v7_9 * This,
+ /* [in] */ BOOL standbyOn);
+
+ HRESULT ( STDMETHODCALLTYPE *Play )(
+ IDeckLinkDeckControl_v7_9 * This,
+ /* [out] */ BMDDeckControlError *error);
+
+ HRESULT ( STDMETHODCALLTYPE *Stop )(
+ IDeckLinkDeckControl_v7_9 * This,
+ /* [out] */ BMDDeckControlError *error);
+
+ HRESULT ( STDMETHODCALLTYPE *TogglePlayStop )(
+ IDeckLinkDeckControl_v7_9 * This,
+ /* [out] */ BMDDeckControlError *error);
+
+ HRESULT ( STDMETHODCALLTYPE *Eject )(
+ IDeckLinkDeckControl_v7_9 * This,
+ /* [out] */ BMDDeckControlError *error);
+
+ HRESULT ( STDMETHODCALLTYPE *GoToTimecode )(
+ IDeckLinkDeckControl_v7_9 * This,
+ /* [in] */ BMDTimecodeBCD timecode,
+ /* [out] */ BMDDeckControlError *error);
+
+ HRESULT ( STDMETHODCALLTYPE *FastForward )(
+ IDeckLinkDeckControl_v7_9 * This,
+ /* [in] */ BOOL viewTape,
+ /* [out] */ BMDDeckControlError *error);
+
+ HRESULT ( STDMETHODCALLTYPE *Rewind )(
+ IDeckLinkDeckControl_v7_9 * This,
+ /* [in] */ BOOL viewTape,
+ /* [out] */ BMDDeckControlError *error);
+
+ HRESULT ( STDMETHODCALLTYPE *StepForward )(
+ IDeckLinkDeckControl_v7_9 * This,
+ /* [out] */ BMDDeckControlError *error);
+
+ HRESULT ( STDMETHODCALLTYPE *StepBack )(
+ IDeckLinkDeckControl_v7_9 * This,
+ /* [out] */ BMDDeckControlError *error);
+
+ HRESULT ( STDMETHODCALLTYPE *Jog )(
+ IDeckLinkDeckControl_v7_9 * This,
+ /* [in] */ double rate,
+ /* [out] */ BMDDeckControlError *error);
+
+ HRESULT ( STDMETHODCALLTYPE *Shuttle )(
+ IDeckLinkDeckControl_v7_9 * This,
+ /* [in] */ double rate,
+ /* [out] */ BMDDeckControlError *error);
+
+ HRESULT ( STDMETHODCALLTYPE *GetTimecodeString )(
+ IDeckLinkDeckControl_v7_9 * This,
+ /* [out] */ BSTR *currentTimeCode,
+ /* [out] */ BMDDeckControlError *error);
+
+ HRESULT ( STDMETHODCALLTYPE *GetTimecode )(
+ IDeckLinkDeckControl_v7_9 * This,
+ /* [out] */ IDeckLinkTimecode **currentTimecode,
+ /* [out] */ BMDDeckControlError *error);
+
+ HRESULT ( STDMETHODCALLTYPE *GetTimecodeBCD )(
+ IDeckLinkDeckControl_v7_9 * This,
+ /* [out] */ BMDTimecodeBCD *currentTimecode,
+ /* [out] */ BMDDeckControlError *error);
+
+ HRESULT ( STDMETHODCALLTYPE *SetPreroll )(
+ IDeckLinkDeckControl_v7_9 * This,
+ /* [in] */ unsigned long prerollSeconds);
+
+ HRESULT ( STDMETHODCALLTYPE *GetPreroll )(
+ IDeckLinkDeckControl_v7_9 * This,
+ /* [out] */ unsigned long *prerollSeconds);
+
+ HRESULT ( STDMETHODCALLTYPE *SetExportOffset )(
+ IDeckLinkDeckControl_v7_9 * This,
+ /* [in] */ long exportOffsetFields);
+
+ HRESULT ( STDMETHODCALLTYPE *GetExportOffset )(
+ IDeckLinkDeckControl_v7_9 * This,
+ /* [out] */ long *exportOffsetFields);
+
+ HRESULT ( STDMETHODCALLTYPE *GetManualExportOffset )(
+ IDeckLinkDeckControl_v7_9 * This,
+ /* [out] */ long *deckManualExportOffsetFields);
+
+ HRESULT ( STDMETHODCALLTYPE *SetCaptureOffset )(
+ IDeckLinkDeckControl_v7_9 * This,
+ /* [in] */ long captureOffsetFields);
+
+ HRESULT ( STDMETHODCALLTYPE *GetCaptureOffset )(
+ IDeckLinkDeckControl_v7_9 * This,
+ /* [out] */ long *captureOffsetFields);
+
+ HRESULT ( STDMETHODCALLTYPE *StartExport )(
+ IDeckLinkDeckControl_v7_9 * This,
+ /* [in] */ BMDTimecodeBCD inTimecode,
+ /* [in] */ BMDTimecodeBCD outTimecode,
+ /* [in] */ BMDDeckControlExportModeOpsFlags exportModeOps,
+ /* [out] */ BMDDeckControlError *error);
+
+ HRESULT ( STDMETHODCALLTYPE *StartCapture )(
+ IDeckLinkDeckControl_v7_9 * This,
+ /* [in] */ BOOL useVITC,
+ /* [in] */ BMDTimecodeBCD inTimecode,
+ /* [in] */ BMDTimecodeBCD outTimecode,
+ /* [out] */ BMDDeckControlError *error);
+
+ HRESULT ( STDMETHODCALLTYPE *GetDeviceID )(
+ IDeckLinkDeckControl_v7_9 * This,
+ /* [out] */ unsigned short *deviceId,
+ /* [out] */ BMDDeckControlError *error);
+
+ HRESULT ( STDMETHODCALLTYPE *Abort )(
+ IDeckLinkDeckControl_v7_9 * This);
+
+ HRESULT ( STDMETHODCALLTYPE *CrashRecordStart )(
+ IDeckLinkDeckControl_v7_9 * This,
+ /* [out] */ BMDDeckControlError *error);
+
+ HRESULT ( STDMETHODCALLTYPE *CrashRecordStop )(
+ IDeckLinkDeckControl_v7_9 * This,
+ /* [out] */ BMDDeckControlError *error);
+
+ HRESULT ( STDMETHODCALLTYPE *SetCallback )(
+ IDeckLinkDeckControl_v7_9 * This,
+ /* [in] */ IDeckLinkDeckControlStatusCallback *callback);
+
+ END_INTERFACE
+ } IDeckLinkDeckControl_v7_9Vtbl;
+
+ interface IDeckLinkDeckControl_v7_9
+ {
+ CONST_VTBL struct IDeckLinkDeckControl_v7_9Vtbl *lpVtbl;
+ };
+
+
+
+#ifdef COBJMACROS
+
+
+#define IDeckLinkDeckControl_v7_9_QueryInterface(This,riid,ppvObject) \
+ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) )
+
+#define IDeckLinkDeckControl_v7_9_AddRef(This) \
+ ( (This)->lpVtbl -> AddRef(This) )
+
+#define IDeckLinkDeckControl_v7_9_Release(This) \
+ ( (This)->lpVtbl -> Release(This) )
+
+
+#define IDeckLinkDeckControl_v7_9_Open(This,timeScale,timeValue,timecodeIsDropFrame,error) \
+ ( (This)->lpVtbl -> Open(This,timeScale,timeValue,timecodeIsDropFrame,error) )
+
+#define IDeckLinkDeckControl_v7_9_Close(This,standbyOn) \
+ ( (This)->lpVtbl -> Close(This,standbyOn) )
+
+#define IDeckLinkDeckControl_v7_9_GetCurrentState(This,mode,vtrControlState,flags) \
+ ( (This)->lpVtbl -> GetCurrentState(This,mode,vtrControlState,flags) )
+
+#define IDeckLinkDeckControl_v7_9_SetStandby(This,standbyOn) \
+ ( (This)->lpVtbl -> SetStandby(This,standbyOn) )
+
+#define IDeckLinkDeckControl_v7_9_Play(This,error) \
+ ( (This)->lpVtbl -> Play(This,error) )
+
+#define IDeckLinkDeckControl_v7_9_Stop(This,error) \
+ ( (This)->lpVtbl -> Stop(This,error) )
+
+#define IDeckLinkDeckControl_v7_9_TogglePlayStop(This,error) \
+ ( (This)->lpVtbl -> TogglePlayStop(This,error) )
+
+#define IDeckLinkDeckControl_v7_9_Eject(This,error) \
+ ( (This)->lpVtbl -> Eject(This,error) )
+
+#define IDeckLinkDeckControl_v7_9_GoToTimecode(This,timecode,error) \
+ ( (This)->lpVtbl -> GoToTimecode(This,timecode,error) )
+
+#define IDeckLinkDeckControl_v7_9_FastForward(This,viewTape,error) \
+ ( (This)->lpVtbl -> FastForward(This,viewTape,error) )
+
+#define IDeckLinkDeckControl_v7_9_Rewind(This,viewTape,error) \
+ ( (This)->lpVtbl -> Rewind(This,viewTape,error) )
+
+#define IDeckLinkDeckControl_v7_9_StepForward(This,error) \
+ ( (This)->lpVtbl -> StepForward(This,error) )
+
+#define IDeckLinkDeckControl_v7_9_StepBack(This,error) \
+ ( (This)->lpVtbl -> StepBack(This,error) )
+
+#define IDeckLinkDeckControl_v7_9_Jog(This,rate,error) \
+ ( (This)->lpVtbl -> Jog(This,rate,error) )
+
+#define IDeckLinkDeckControl_v7_9_Shuttle(This,rate,error) \
+ ( (This)->lpVtbl -> Shuttle(This,rate,error) )
+
+#define IDeckLinkDeckControl_v7_9_GetTimecodeString(This,currentTimeCode,error) \
+ ( (This)->lpVtbl -> GetTimecodeString(This,currentTimeCode,error) )
+
+#define IDeckLinkDeckControl_v7_9_GetTimecode(This,currentTimecode,error) \
+ ( (This)->lpVtbl -> GetTimecode(This,currentTimecode,error) )
+
+#define IDeckLinkDeckControl_v7_9_GetTimecodeBCD(This,currentTimecode,error) \
+ ( (This)->lpVtbl -> GetTimecodeBCD(This,currentTimecode,error) )
+
+#define IDeckLinkDeckControl_v7_9_SetPreroll(This,prerollSeconds) \
+ ( (This)->lpVtbl -> SetPreroll(This,prerollSeconds) )
+
+#define IDeckLinkDeckControl_v7_9_GetPreroll(This,prerollSeconds) \
+ ( (This)->lpVtbl -> GetPreroll(This,prerollSeconds) )
+
+#define IDeckLinkDeckControl_v7_9_SetExportOffset(This,exportOffsetFields) \
+ ( (This)->lpVtbl -> SetExportOffset(This,exportOffsetFields) )
+
+#define IDeckLinkDeckControl_v7_9_GetExportOffset(This,exportOffsetFields) \
+ ( (This)->lpVtbl -> GetExportOffset(This,exportOffsetFields) )
+
+#define IDeckLinkDeckControl_v7_9_GetManualExportOffset(This,deckManualExportOffsetFields) \
+ ( (This)->lpVtbl -> GetManualExportOffset(This,deckManualExportOffsetFields) )
+
+#define IDeckLinkDeckControl_v7_9_SetCaptureOffset(This,captureOffsetFields) \
+ ( (This)->lpVtbl -> SetCaptureOffset(This,captureOffsetFields) )
+
+#define IDeckLinkDeckControl_v7_9_GetCaptureOffset(This,captureOffsetFields) \
+ ( (This)->lpVtbl -> GetCaptureOffset(This,captureOffsetFields) )
+
+#define IDeckLinkDeckControl_v7_9_StartExport(This,inTimecode,outTimecode,exportModeOps,error) \
+ ( (This)->lpVtbl -> StartExport(This,inTimecode,outTimecode,exportModeOps,error) )
+
+#define IDeckLinkDeckControl_v7_9_StartCapture(This,useVITC,inTimecode,outTimecode,error) \
+ ( (This)->lpVtbl -> StartCapture(This,useVITC,inTimecode,outTimecode,error) )
+
+#define IDeckLinkDeckControl_v7_9_GetDeviceID(This,deviceId,error) \
+ ( (This)->lpVtbl -> GetDeviceID(This,deviceId,error) )
+
+#define IDeckLinkDeckControl_v7_9_Abort(This) \
+ ( (This)->lpVtbl -> Abort(This) )
+
+#define IDeckLinkDeckControl_v7_9_CrashRecordStart(This,error) \
+ ( (This)->lpVtbl -> CrashRecordStart(This,error) )
+
+#define IDeckLinkDeckControl_v7_9_CrashRecordStop(This,error) \
+ ( (This)->lpVtbl -> CrashRecordStop(This,error) )
+
+#define IDeckLinkDeckControl_v7_9_SetCallback(This,callback) \
+ ( (This)->lpVtbl -> SetCallback(This,callback) )
+
+#endif /* COBJMACROS */
+
+
+#endif /* C style interface */
+
+
+
+
+#endif /* __IDeckLinkDeckControl_v7_9_INTERFACE_DEFINED__ */
+
+
+#ifndef __IDeckLinkDisplayModeIterator_v7_6_INTERFACE_DEFINED__
+#define __IDeckLinkDisplayModeIterator_v7_6_INTERFACE_DEFINED__
+
+/* interface IDeckLinkDisplayModeIterator_v7_6 */
+/* [helpstring][uuid][object] */
+
+
+EXTERN_C const IID IID_IDeckLinkDisplayModeIterator_v7_6;
+
+#if defined(__cplusplus) && !defined(CINTERFACE)
+
+ MIDL_INTERFACE("455D741F-1779-4800-86F5-0B5D13D79751")
+ IDeckLinkDisplayModeIterator_v7_6 : public IUnknown
+ {
+ public:
+ virtual HRESULT STDMETHODCALLTYPE Next(
+ /* [out] */ IDeckLinkDisplayMode_v7_6 **deckLinkDisplayMode) = 0;
+
+ };
+
+#else /* C style interface */
+
+ typedef struct IDeckLinkDisplayModeIterator_v7_6Vtbl
+ {
+ BEGIN_INTERFACE
+
+ HRESULT ( STDMETHODCALLTYPE *QueryInterface )(
+ IDeckLinkDisplayModeIterator_v7_6 * This,
+ /* [in] */ REFIID riid,
+ /* [iid_is][out] */
+ __RPC__deref_out void **ppvObject);
+
+ ULONG ( STDMETHODCALLTYPE *AddRef )(
+ IDeckLinkDisplayModeIterator_v7_6 * This);
+
+ ULONG ( STDMETHODCALLTYPE *Release )(
+ IDeckLinkDisplayModeIterator_v7_6 * This);
+
+ HRESULT ( STDMETHODCALLTYPE *Next )(
+ IDeckLinkDisplayModeIterator_v7_6 * This,
+ /* [out] */ IDeckLinkDisplayMode_v7_6 **deckLinkDisplayMode);
+
+ END_INTERFACE
+ } IDeckLinkDisplayModeIterator_v7_6Vtbl;
+
+ interface IDeckLinkDisplayModeIterator_v7_6
+ {
+ CONST_VTBL struct IDeckLinkDisplayModeIterator_v7_6Vtbl *lpVtbl;
+ };
+
+
+
+#ifdef COBJMACROS
+
+
+#define IDeckLinkDisplayModeIterator_v7_6_QueryInterface(This,riid,ppvObject) \
+ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) )
+
+#define IDeckLinkDisplayModeIterator_v7_6_AddRef(This) \
+ ( (This)->lpVtbl -> AddRef(This) )
+
+#define IDeckLinkDisplayModeIterator_v7_6_Release(This) \
+ ( (This)->lpVtbl -> Release(This) )
+
+
+#define IDeckLinkDisplayModeIterator_v7_6_Next(This,deckLinkDisplayMode) \
+ ( (This)->lpVtbl -> Next(This,deckLinkDisplayMode) )
+
+#endif /* COBJMACROS */
+
+
+#endif /* C style interface */
+
+
+
+
+#endif /* __IDeckLinkDisplayModeIterator_v7_6_INTERFACE_DEFINED__ */
+
+
+#ifndef __IDeckLinkDisplayMode_v7_6_INTERFACE_DEFINED__
+#define __IDeckLinkDisplayMode_v7_6_INTERFACE_DEFINED__
+
+/* interface IDeckLinkDisplayMode_v7_6 */
+/* [helpstring][uuid][object] */
+
+
+EXTERN_C const IID IID_IDeckLinkDisplayMode_v7_6;
+
+#if defined(__cplusplus) && !defined(CINTERFACE)
+
+ MIDL_INTERFACE("87451E84-2B7E-439E-A629-4393EA4A8550")
+ IDeckLinkDisplayMode_v7_6 : public IUnknown
+ {
+ public:
+ virtual HRESULT STDMETHODCALLTYPE GetName(
+ /* [out] */ BSTR *name) = 0;
+
+ virtual BMDDisplayMode STDMETHODCALLTYPE GetDisplayMode( void) = 0;
+
+ virtual long STDMETHODCALLTYPE GetWidth( void) = 0;
+
+ virtual long STDMETHODCALLTYPE GetHeight( void) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE GetFrameRate(
+ /* [out] */ BMDTimeValue *frameDuration,
+ /* [out] */ BMDTimeScale *timeScale) = 0;
+
+ virtual BMDFieldDominance STDMETHODCALLTYPE GetFieldDominance( void) = 0;
+
+ };
+
+#else /* C style interface */
+
+ typedef struct IDeckLinkDisplayMode_v7_6Vtbl
+ {
+ BEGIN_INTERFACE
+
+ HRESULT ( STDMETHODCALLTYPE *QueryInterface )(
+ IDeckLinkDisplayMode_v7_6 * This,
+ /* [in] */ REFIID riid,
+ /* [iid_is][out] */
+ __RPC__deref_out void **ppvObject);
+
+ ULONG ( STDMETHODCALLTYPE *AddRef )(
+ IDeckLinkDisplayMode_v7_6 * This);
+
+ ULONG ( STDMETHODCALLTYPE *Release )(
+ IDeckLinkDisplayMode_v7_6 * This);
+
+ HRESULT ( STDMETHODCALLTYPE *GetName )(
+ IDeckLinkDisplayMode_v7_6 * This,
+ /* [out] */ BSTR *name);
+
+ BMDDisplayMode ( STDMETHODCALLTYPE *GetDisplayMode )(
+ IDeckLinkDisplayMode_v7_6 * This);
+
+ long ( STDMETHODCALLTYPE *GetWidth )(
+ IDeckLinkDisplayMode_v7_6 * This);
+
+ long ( STDMETHODCALLTYPE *GetHeight )(
+ IDeckLinkDisplayMode_v7_6 * This);
+
+ HRESULT ( STDMETHODCALLTYPE *GetFrameRate )(
+ IDeckLinkDisplayMode_v7_6 * This,
+ /* [out] */ BMDTimeValue *frameDuration,
+ /* [out] */ BMDTimeScale *timeScale);
+
+ BMDFieldDominance ( STDMETHODCALLTYPE *GetFieldDominance )(
+ IDeckLinkDisplayMode_v7_6 * This);
+
+ END_INTERFACE
+ } IDeckLinkDisplayMode_v7_6Vtbl;
+
+ interface IDeckLinkDisplayMode_v7_6
+ {
+ CONST_VTBL struct IDeckLinkDisplayMode_v7_6Vtbl *lpVtbl;
+ };
+
+
+
+#ifdef COBJMACROS
+
+
+#define IDeckLinkDisplayMode_v7_6_QueryInterface(This,riid,ppvObject) \
+ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) )
+
+#define IDeckLinkDisplayMode_v7_6_AddRef(This) \
+ ( (This)->lpVtbl -> AddRef(This) )
+
+#define IDeckLinkDisplayMode_v7_6_Release(This) \
+ ( (This)->lpVtbl -> Release(This) )
+
+
+#define IDeckLinkDisplayMode_v7_6_GetName(This,name) \
+ ( (This)->lpVtbl -> GetName(This,name) )
+
+#define IDeckLinkDisplayMode_v7_6_GetDisplayMode(This) \
+ ( (This)->lpVtbl -> GetDisplayMode(This) )
+
+#define IDeckLinkDisplayMode_v7_6_GetWidth(This) \
+ ( (This)->lpVtbl -> GetWidth(This) )
+
+#define IDeckLinkDisplayMode_v7_6_GetHeight(This) \
+ ( (This)->lpVtbl -> GetHeight(This) )
+
+#define IDeckLinkDisplayMode_v7_6_GetFrameRate(This,frameDuration,timeScale) \
+ ( (This)->lpVtbl -> GetFrameRate(This,frameDuration,timeScale) )
+
+#define IDeckLinkDisplayMode_v7_6_GetFieldDominance(This) \
+ ( (This)->lpVtbl -> GetFieldDominance(This) )
+
+#endif /* COBJMACROS */
+
+
+#endif /* C style interface */
+
+
+
+
+#endif /* __IDeckLinkDisplayMode_v7_6_INTERFACE_DEFINED__ */
+
+
+#ifndef __IDeckLinkOutput_v7_6_INTERFACE_DEFINED__
+#define __IDeckLinkOutput_v7_6_INTERFACE_DEFINED__
+
+/* interface IDeckLinkOutput_v7_6 */
+/* [helpstring][local][uuid][object] */
+
+
+EXTERN_C const IID IID_IDeckLinkOutput_v7_6;
+
+#if defined(__cplusplus) && !defined(CINTERFACE)
+
+ MIDL_INTERFACE("29228142-EB8C-4141-A621-F74026450955")
+ IDeckLinkOutput_v7_6 : public IUnknown
+ {
+ public:
+ virtual HRESULT STDMETHODCALLTYPE DoesSupportVideoMode(
+ BMDDisplayMode displayMode,
+ BMDPixelFormat pixelFormat,
+ /* [out] */ BMDDisplayModeSupport *result) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE GetDisplayModeIterator(
+ /* [out] */ IDeckLinkDisplayModeIterator_v7_6 **iterator) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE SetScreenPreviewCallback(
+ /* [in] */ IDeckLinkScreenPreviewCallback_v7_6 *previewCallback) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE EnableVideoOutput(
+ BMDDisplayMode displayMode,
+ BMDVideoOutputFlags flags) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE DisableVideoOutput( void) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE SetVideoOutputFrameMemoryAllocator(
+ /* [in] */ IDeckLinkMemoryAllocator *theAllocator) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE CreateVideoFrame(
+ long width,
+ long height,
+ long rowBytes,
+ BMDPixelFormat pixelFormat,
+ BMDFrameFlags flags,
+ /* [out] */ IDeckLinkMutableVideoFrame_v7_6 **outFrame) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE CreateAncillaryData(
+ BMDPixelFormat pixelFormat,
+ /* [out] */ IDeckLinkVideoFrameAncillary **outBuffer) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE DisplayVideoFrameSync(
+ /* [in] */ IDeckLinkVideoFrame_v7_6 *theFrame) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE ScheduleVideoFrame(
+ /* [in] */ IDeckLinkVideoFrame_v7_6 *theFrame,
+ BMDTimeValue displayTime,
+ BMDTimeValue displayDuration,
+ BMDTimeScale timeScale) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE SetScheduledFrameCompletionCallback(
+ /* [in] */ IDeckLinkVideoOutputCallback_v7_6 *theCallback) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE GetBufferedVideoFrameCount(
+ /* [out] */ unsigned long *bufferedFrameCount) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE EnableAudioOutput(
+ BMDAudioSampleRate sampleRate,
+ BMDAudioSampleType sampleType,
+ unsigned long channelCount,
+ BMDAudioOutputStreamType streamType) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE DisableAudioOutput( void) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE WriteAudioSamplesSync(
+ /* [in] */ void *buffer,
+ unsigned long sampleFrameCount,
+ /* [out] */ unsigned long *sampleFramesWritten) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE BeginAudioPreroll( void) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE EndAudioPreroll( void) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE ScheduleAudioSamples(
+ /* [in] */ void *buffer,
+ unsigned long sampleFrameCount,
+ BMDTimeValue streamTime,
+ BMDTimeScale timeScale,
+ /* [out] */ unsigned long *sampleFramesWritten) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE GetBufferedAudioSampleFrameCount(
+ /* [out] */ unsigned long *bufferedSampleFrameCount) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE FlushBufferedAudioSamples( void) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE SetAudioCallback(
+ /* [in] */ IDeckLinkAudioOutputCallback *theCallback) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE StartScheduledPlayback(
+ BMDTimeValue playbackStartTime,
+ BMDTimeScale timeScale,
+ double playbackSpeed) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE StopScheduledPlayback(
+ BMDTimeValue stopPlaybackAtTime,
+ /* [out] */ BMDTimeValue *actualStopTime,
+ BMDTimeScale timeScale) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE IsScheduledPlaybackRunning(
+ /* [out] */ BOOL *active) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE GetScheduledStreamTime(
+ BMDTimeScale desiredTimeScale,
+ /* [out] */ BMDTimeValue *streamTime,
+ /* [out] */ double *playbackSpeed) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE GetHardwareReferenceClock(
+ BMDTimeScale desiredTimeScale,
+ /* [out] */ BMDTimeValue *hardwareTime,
+ /* [out] */ BMDTimeValue *timeInFrame,
+ /* [out] */ BMDTimeValue *ticksPerFrame) = 0;
+
+ };
+
+#else /* C style interface */
+
+ typedef struct IDeckLinkOutput_v7_6Vtbl
+ {
+ BEGIN_INTERFACE
+
+ HRESULT ( STDMETHODCALLTYPE *QueryInterface )(
+ IDeckLinkOutput_v7_6 * This,
+ /* [in] */ REFIID riid,
+ /* [iid_is][out] */
+ __RPC__deref_out void **ppvObject);
+
+ ULONG ( STDMETHODCALLTYPE *AddRef )(
+ IDeckLinkOutput_v7_6 * This);
+
+ ULONG ( STDMETHODCALLTYPE *Release )(
+ IDeckLinkOutput_v7_6 * This);
+
+ HRESULT ( STDMETHODCALLTYPE *DoesSupportVideoMode )(
+ IDeckLinkOutput_v7_6 * This,
+ BMDDisplayMode displayMode,
+ BMDPixelFormat pixelFormat,
+ /* [out] */ BMDDisplayModeSupport *result);
+
+ HRESULT ( STDMETHODCALLTYPE *GetDisplayModeIterator )(
+ IDeckLinkOutput_v7_6 * This,
+ /* [out] */ IDeckLinkDisplayModeIterator_v7_6 **iterator);
+
+ HRESULT ( STDMETHODCALLTYPE *SetScreenPreviewCallback )(
+ IDeckLinkOutput_v7_6 * This,
+ /* [in] */ IDeckLinkScreenPreviewCallback_v7_6 *previewCallback);
+
+ HRESULT ( STDMETHODCALLTYPE *EnableVideoOutput )(
+ IDeckLinkOutput_v7_6 * This,
+ BMDDisplayMode displayMode,
+ BMDVideoOutputFlags flags);
+
+ HRESULT ( STDMETHODCALLTYPE *DisableVideoOutput )(
+ IDeckLinkOutput_v7_6 * This);
+
+ HRESULT ( STDMETHODCALLTYPE *SetVideoOutputFrameMemoryAllocator )(
+ IDeckLinkOutput_v7_6 * This,
+ /* [in] */ IDeckLinkMemoryAllocator *theAllocator);
+
+ HRESULT ( STDMETHODCALLTYPE *CreateVideoFrame )(
+ IDeckLinkOutput_v7_6 * This,
+ long width,
+ long height,
+ long rowBytes,
+ BMDPixelFormat pixelFormat,
+ BMDFrameFlags flags,
+ /* [out] */ IDeckLinkMutableVideoFrame_v7_6 **outFrame);
+
+ HRESULT ( STDMETHODCALLTYPE *CreateAncillaryData )(
+ IDeckLinkOutput_v7_6 * This,
+ BMDPixelFormat pixelFormat,
+ /* [out] */ IDeckLinkVideoFrameAncillary **outBuffer);
+
+ HRESULT ( STDMETHODCALLTYPE *DisplayVideoFrameSync )(
+ IDeckLinkOutput_v7_6 * This,
+ /* [in] */ IDeckLinkVideoFrame_v7_6 *theFrame);
+
+ HRESULT ( STDMETHODCALLTYPE *ScheduleVideoFrame )(
+ IDeckLinkOutput_v7_6 * This,
+ /* [in] */ IDeckLinkVideoFrame_v7_6 *theFrame,
+ BMDTimeValue displayTime,
+ BMDTimeValue displayDuration,
+ BMDTimeScale timeScale);
+
+ HRESULT ( STDMETHODCALLTYPE *SetScheduledFrameCompletionCallback )(
+ IDeckLinkOutput_v7_6 * This,
+ /* [in] */ IDeckLinkVideoOutputCallback_v7_6 *theCallback);
+
+ HRESULT ( STDMETHODCALLTYPE *GetBufferedVideoFrameCount )(
+ IDeckLinkOutput_v7_6 * This,
+ /* [out] */ unsigned long *bufferedFrameCount);
+
+ HRESULT ( STDMETHODCALLTYPE *EnableAudioOutput )(
+ IDeckLinkOutput_v7_6 * This,
+ BMDAudioSampleRate sampleRate,
+ BMDAudioSampleType sampleType,
+ unsigned long channelCount,
+ BMDAudioOutputStreamType streamType);
+
+ HRESULT ( STDMETHODCALLTYPE *DisableAudioOutput )(
+ IDeckLinkOutput_v7_6 * This);
+
+ HRESULT ( STDMETHODCALLTYPE *WriteAudioSamplesSync )(
+ IDeckLinkOutput_v7_6 * This,
+ /* [in] */ void *buffer,
+ unsigned long sampleFrameCount,
+ /* [out] */ unsigned long *sampleFramesWritten);
+
+ HRESULT ( STDMETHODCALLTYPE *BeginAudioPreroll )(
+ IDeckLinkOutput_v7_6 * This);
+
+ HRESULT ( STDMETHODCALLTYPE *EndAudioPreroll )(
+ IDeckLinkOutput_v7_6 * This);
+
+ HRESULT ( STDMETHODCALLTYPE *ScheduleAudioSamples )(
+ IDeckLinkOutput_v7_6 * This,
+ /* [in] */ void *buffer,
+ unsigned long sampleFrameCount,
+ BMDTimeValue streamTime,
+ BMDTimeScale timeScale,
+ /* [out] */ unsigned long *sampleFramesWritten);
+
+ HRESULT ( STDMETHODCALLTYPE *GetBufferedAudioSampleFrameCount )(
+ IDeckLinkOutput_v7_6 * This,
+ /* [out] */ unsigned long *bufferedSampleFrameCount);
+
+ HRESULT ( STDMETHODCALLTYPE *FlushBufferedAudioSamples )(
+ IDeckLinkOutput_v7_6 * This);
+
+ HRESULT ( STDMETHODCALLTYPE *SetAudioCallback )(
+ IDeckLinkOutput_v7_6 * This,
+ /* [in] */ IDeckLinkAudioOutputCallback *theCallback);
+
+ HRESULT ( STDMETHODCALLTYPE *StartScheduledPlayback )(
+ IDeckLinkOutput_v7_6 * This,
+ BMDTimeValue playbackStartTime,
+ BMDTimeScale timeScale,
+ double playbackSpeed);
+
+ HRESULT ( STDMETHODCALLTYPE *StopScheduledPlayback )(
+ IDeckLinkOutput_v7_6 * This,
+ BMDTimeValue stopPlaybackAtTime,
+ /* [out] */ BMDTimeValue *actualStopTime,
+ BMDTimeScale timeScale);
+
+ HRESULT ( STDMETHODCALLTYPE *IsScheduledPlaybackRunning )(
+ IDeckLinkOutput_v7_6 * This,
+ /* [out] */ BOOL *active);
+
+ HRESULT ( STDMETHODCALLTYPE *GetScheduledStreamTime )(
+ IDeckLinkOutput_v7_6 * This,
+ BMDTimeScale desiredTimeScale,
+ /* [out] */ BMDTimeValue *streamTime,
+ /* [out] */ double *playbackSpeed);
+
+ HRESULT ( STDMETHODCALLTYPE *GetHardwareReferenceClock )(
+ IDeckLinkOutput_v7_6 * This,
+ BMDTimeScale desiredTimeScale,
+ /* [out] */ BMDTimeValue *hardwareTime,
+ /* [out] */ BMDTimeValue *timeInFrame,
+ /* [out] */ BMDTimeValue *ticksPerFrame);
+
+ END_INTERFACE
+ } IDeckLinkOutput_v7_6Vtbl;
+
+ interface IDeckLinkOutput_v7_6
+ {
+ CONST_VTBL struct IDeckLinkOutput_v7_6Vtbl *lpVtbl;
+ };
+
+
+
+#ifdef COBJMACROS
+
+
+#define IDeckLinkOutput_v7_6_QueryInterface(This,riid,ppvObject) \
+ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) )
+
+#define IDeckLinkOutput_v7_6_AddRef(This) \
+ ( (This)->lpVtbl -> AddRef(This) )
+
+#define IDeckLinkOutput_v7_6_Release(This) \
+ ( (This)->lpVtbl -> Release(This) )
+
+
+#define IDeckLinkOutput_v7_6_DoesSupportVideoMode(This,displayMode,pixelFormat,result) \
+ ( (This)->lpVtbl -> DoesSupportVideoMode(This,displayMode,pixelFormat,result) )
+
+#define IDeckLinkOutput_v7_6_GetDisplayModeIterator(This,iterator) \
+ ( (This)->lpVtbl -> GetDisplayModeIterator(This,iterator) )
+
+#define IDeckLinkOutput_v7_6_SetScreenPreviewCallback(This,previewCallback) \
+ ( (This)->lpVtbl -> SetScreenPreviewCallback(This,previewCallback) )
+
+#define IDeckLinkOutput_v7_6_EnableVideoOutput(This,displayMode,flags) \
+ ( (This)->lpVtbl -> EnableVideoOutput(This,displayMode,flags) )
+
+#define IDeckLinkOutput_v7_6_DisableVideoOutput(This) \
+ ( (This)->lpVtbl -> DisableVideoOutput(This) )
+
+#define IDeckLinkOutput_v7_6_SetVideoOutputFrameMemoryAllocator(This,theAllocator) \
+ ( (This)->lpVtbl -> SetVideoOutputFrameMemoryAllocator(This,theAllocator) )
+
+#define IDeckLinkOutput_v7_6_CreateVideoFrame(This,width,height,rowBytes,pixelFormat,flags,outFrame) \
+ ( (This)->lpVtbl -> CreateVideoFrame(This,width,height,rowBytes,pixelFormat,flags,outFrame) )
+
+#define IDeckLinkOutput_v7_6_CreateAncillaryData(This,pixelFormat,outBuffer) \
+ ( (This)->lpVtbl -> CreateAncillaryData(This,pixelFormat,outBuffer) )
+
+#define IDeckLinkOutput_v7_6_DisplayVideoFrameSync(This,theFrame) \
+ ( (This)->lpVtbl -> DisplayVideoFrameSync(This,theFrame) )
+
+#define IDeckLinkOutput_v7_6_ScheduleVideoFrame(This,theFrame,displayTime,displayDuration,timeScale) \
+ ( (This)->lpVtbl -> ScheduleVideoFrame(This,theFrame,displayTime,displayDuration,timeScale) )
+
+#define IDeckLinkOutput_v7_6_SetScheduledFrameCompletionCallback(This,theCallback) \
+ ( (This)->lpVtbl -> SetScheduledFrameCompletionCallback(This,theCallback) )
+
+#define IDeckLinkOutput_v7_6_GetBufferedVideoFrameCount(This,bufferedFrameCount) \
+ ( (This)->lpVtbl -> GetBufferedVideoFrameCount(This,bufferedFrameCount) )
+
+#define IDeckLinkOutput_v7_6_EnableAudioOutput(This,sampleRate,sampleType,channelCount,streamType) \
+ ( (This)->lpVtbl -> EnableAudioOutput(This,sampleRate,sampleType,channelCount,streamType) )
+
+#define IDeckLinkOutput_v7_6_DisableAudioOutput(This) \
+ ( (This)->lpVtbl -> DisableAudioOutput(This) )
+
+#define IDeckLinkOutput_v7_6_WriteAudioSamplesSync(This,buffer,sampleFrameCount,sampleFramesWritten) \
+ ( (This)->lpVtbl -> WriteAudioSamplesSync(This,buffer,sampleFrameCount,sampleFramesWritten) )
+
+#define IDeckLinkOutput_v7_6_BeginAudioPreroll(This) \
+ ( (This)->lpVtbl -> BeginAudioPreroll(This) )
+
+#define IDeckLinkOutput_v7_6_EndAudioPreroll(This) \
+ ( (This)->lpVtbl -> EndAudioPreroll(This) )
+
+#define IDeckLinkOutput_v7_6_ScheduleAudioSamples(This,buffer,sampleFrameCount,streamTime,timeScale,sampleFramesWritten) \
+ ( (This)->lpVtbl -> ScheduleAudioSamples(This,buffer,sampleFrameCount,streamTime,timeScale,sampleFramesWritten) )
+
+#define IDeckLinkOutput_v7_6_GetBufferedAudioSampleFrameCount(This,bufferedSampleFrameCount) \
+ ( (This)->lpVtbl -> GetBufferedAudioSampleFrameCount(This,bufferedSampleFrameCount) )
+
+#define IDeckLinkOutput_v7_6_FlushBufferedAudioSamples(This) \
+ ( (This)->lpVtbl -> FlushBufferedAudioSamples(This) )
+
+#define IDeckLinkOutput_v7_6_SetAudioCallback(This,theCallback) \
+ ( (This)->lpVtbl -> SetAudioCallback(This,theCallback) )
+
+#define IDeckLinkOutput_v7_6_StartScheduledPlayback(This,playbackStartTime,timeScale,playbackSpeed) \
+ ( (This)->lpVtbl -> StartScheduledPlayback(This,playbackStartTime,timeScale,playbackSpeed) )
+
+#define IDeckLinkOutput_v7_6_StopScheduledPlayback(This,stopPlaybackAtTime,actualStopTime,timeScale) \
+ ( (This)->lpVtbl -> StopScheduledPlayback(This,stopPlaybackAtTime,actualStopTime,timeScale) )
+
+#define IDeckLinkOutput_v7_6_IsScheduledPlaybackRunning(This,active) \
+ ( (This)->lpVtbl -> IsScheduledPlaybackRunning(This,active) )
+
+#define IDeckLinkOutput_v7_6_GetScheduledStreamTime(This,desiredTimeScale,streamTime,playbackSpeed) \
+ ( (This)->lpVtbl -> GetScheduledStreamTime(This,desiredTimeScale,streamTime,playbackSpeed) )
+
+#define IDeckLinkOutput_v7_6_GetHardwareReferenceClock(This,desiredTimeScale,hardwareTime,timeInFrame,ticksPerFrame) \
+ ( (This)->lpVtbl -> GetHardwareReferenceClock(This,desiredTimeScale,hardwareTime,timeInFrame,ticksPerFrame) )
+
+#endif /* COBJMACROS */
+
+
+#endif /* C style interface */
+
+
+
+
+#endif /* __IDeckLinkOutput_v7_6_INTERFACE_DEFINED__ */
+
+
+#ifndef __IDeckLinkInput_v7_6_INTERFACE_DEFINED__
+#define __IDeckLinkInput_v7_6_INTERFACE_DEFINED__
+
+/* interface IDeckLinkInput_v7_6 */
+/* [helpstring][uuid][object] */
+
+
+EXTERN_C const IID IID_IDeckLinkInput_v7_6;
+
+#if defined(__cplusplus) && !defined(CINTERFACE)
+
+ MIDL_INTERFACE("300C135A-9F43-48E2-9906-6D7911D93CF1")
+ IDeckLinkInput_v7_6 : public IUnknown
+ {
+ public:
+ virtual HRESULT STDMETHODCALLTYPE DoesSupportVideoMode(
+ BMDDisplayMode displayMode,
+ BMDPixelFormat pixelFormat,
+ /* [out] */ BMDDisplayModeSupport *result) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE GetDisplayModeIterator(
+ /* [out] */ IDeckLinkDisplayModeIterator_v7_6 **iterator) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE SetScreenPreviewCallback(
+ /* [in] */ IDeckLinkScreenPreviewCallback_v7_6 *previewCallback) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE EnableVideoInput(
+ BMDDisplayMode displayMode,
+ BMDPixelFormat pixelFormat,
+ BMDVideoInputFlags flags) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE DisableVideoInput( void) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE GetAvailableVideoFrameCount(
+ /* [out] */ unsigned long *availableFrameCount) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE EnableAudioInput(
+ BMDAudioSampleRate sampleRate,
+ BMDAudioSampleType sampleType,
+ unsigned long channelCount) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE DisableAudioInput( void) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE GetAvailableAudioSampleFrameCount(
+ /* [out] */ unsigned long *availableSampleFrameCount) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE StartStreams( void) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE StopStreams( void) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE PauseStreams( void) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE FlushStreams( void) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE SetCallback(
+ /* [in] */ IDeckLinkInputCallback_v7_6 *theCallback) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE GetHardwareReferenceClock(
+ BMDTimeScale desiredTimeScale,
+ /* [out] */ BMDTimeValue *hardwareTime,
+ /* [out] */ BMDTimeValue *timeInFrame,
+ /* [out] */ BMDTimeValue *ticksPerFrame) = 0;
+
+ };
+
+#else /* C style interface */
+
+ typedef struct IDeckLinkInput_v7_6Vtbl
+ {
+ BEGIN_INTERFACE
+
+ HRESULT ( STDMETHODCALLTYPE *QueryInterface )(
+ IDeckLinkInput_v7_6 * This,
+ /* [in] */ REFIID riid,
+ /* [iid_is][out] */
+ __RPC__deref_out void **ppvObject);
+
+ ULONG ( STDMETHODCALLTYPE *AddRef )(
+ IDeckLinkInput_v7_6 * This);
+
+ ULONG ( STDMETHODCALLTYPE *Release )(
+ IDeckLinkInput_v7_6 * This);
+
+ HRESULT ( STDMETHODCALLTYPE *DoesSupportVideoMode )(
+ IDeckLinkInput_v7_6 * This,
+ BMDDisplayMode displayMode,
+ BMDPixelFormat pixelFormat,
+ /* [out] */ BMDDisplayModeSupport *result);
+
+ HRESULT ( STDMETHODCALLTYPE *GetDisplayModeIterator )(
+ IDeckLinkInput_v7_6 * This,
+ /* [out] */ IDeckLinkDisplayModeIterator_v7_6 **iterator);
+
+ HRESULT ( STDMETHODCALLTYPE *SetScreenPreviewCallback )(
+ IDeckLinkInput_v7_6 * This,
+ /* [in] */ IDeckLinkScreenPreviewCallback_v7_6 *previewCallback);
+
+ HRESULT ( STDMETHODCALLTYPE *EnableVideoInput )(
+ IDeckLinkInput_v7_6 * This,
+ BMDDisplayMode displayMode,
+ BMDPixelFormat pixelFormat,
+ BMDVideoInputFlags flags);
+
+ HRESULT ( STDMETHODCALLTYPE *DisableVideoInput )(
+ IDeckLinkInput_v7_6 * This);
+
+ HRESULT ( STDMETHODCALLTYPE *GetAvailableVideoFrameCount )(
+ IDeckLinkInput_v7_6 * This,
+ /* [out] */ unsigned long *availableFrameCount);
+
+ HRESULT ( STDMETHODCALLTYPE *EnableAudioInput )(
+ IDeckLinkInput_v7_6 * This,
+ BMDAudioSampleRate sampleRate,
+ BMDAudioSampleType sampleType,
+ unsigned long channelCount);
+
+ HRESULT ( STDMETHODCALLTYPE *DisableAudioInput )(
+ IDeckLinkInput_v7_6 * This);
+
+ HRESULT ( STDMETHODCALLTYPE *GetAvailableAudioSampleFrameCount )(
+ IDeckLinkInput_v7_6 * This,
+ /* [out] */ unsigned long *availableSampleFrameCount);
+
+ HRESULT ( STDMETHODCALLTYPE *StartStreams )(
+ IDeckLinkInput_v7_6 * This);
+
+ HRESULT ( STDMETHODCALLTYPE *StopStreams )(
+ IDeckLinkInput_v7_6 * This);
+
+ HRESULT ( STDMETHODCALLTYPE *PauseStreams )(
+ IDeckLinkInput_v7_6 * This);
+
+ HRESULT ( STDMETHODCALLTYPE *FlushStreams )(
+ IDeckLinkInput_v7_6 * This);
+
+ HRESULT ( STDMETHODCALLTYPE *SetCallback )(
+ IDeckLinkInput_v7_6 * This,
+ /* [in] */ IDeckLinkInputCallback_v7_6 *theCallback);
+
+ HRESULT ( STDMETHODCALLTYPE *GetHardwareReferenceClock )(
+ IDeckLinkInput_v7_6 * This,
+ BMDTimeScale desiredTimeScale,
+ /* [out] */ BMDTimeValue *hardwareTime,
+ /* [out] */ BMDTimeValue *timeInFrame,
+ /* [out] */ BMDTimeValue *ticksPerFrame);
+
+ END_INTERFACE
+ } IDeckLinkInput_v7_6Vtbl;
+
+ interface IDeckLinkInput_v7_6
+ {
+ CONST_VTBL struct IDeckLinkInput_v7_6Vtbl *lpVtbl;
+ };
+
+
+
+#ifdef COBJMACROS
+
+
+#define IDeckLinkInput_v7_6_QueryInterface(This,riid,ppvObject) \
+ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) )
+
+#define IDeckLinkInput_v7_6_AddRef(This) \
+ ( (This)->lpVtbl -> AddRef(This) )
+
+#define IDeckLinkInput_v7_6_Release(This) \
+ ( (This)->lpVtbl -> Release(This) )
+
+
+#define IDeckLinkInput_v7_6_DoesSupportVideoMode(This,displayMode,pixelFormat,result) \
+ ( (This)->lpVtbl -> DoesSupportVideoMode(This,displayMode,pixelFormat,result) )
+
+#define IDeckLinkInput_v7_6_GetDisplayModeIterator(This,iterator) \
+ ( (This)->lpVtbl -> GetDisplayModeIterator(This,iterator) )
+
+#define IDeckLinkInput_v7_6_SetScreenPreviewCallback(This,previewCallback) \
+ ( (This)->lpVtbl -> SetScreenPreviewCallback(This,previewCallback) )
+
+#define IDeckLinkInput_v7_6_EnableVideoInput(This,displayMode,pixelFormat,flags) \
+ ( (This)->lpVtbl -> EnableVideoInput(This,displayMode,pixelFormat,flags) )
+
+#define IDeckLinkInput_v7_6_DisableVideoInput(This) \
+ ( (This)->lpVtbl -> DisableVideoInput(This) )
+
+#define IDeckLinkInput_v7_6_GetAvailableVideoFrameCount(This,availableFrameCount) \
+ ( (This)->lpVtbl -> GetAvailableVideoFrameCount(This,availableFrameCount) )
+
+#define IDeckLinkInput_v7_6_EnableAudioInput(This,sampleRate,sampleType,channelCount) \
+ ( (This)->lpVtbl -> EnableAudioInput(This,sampleRate,sampleType,channelCount) )
+
+#define IDeckLinkInput_v7_6_DisableAudioInput(This) \
+ ( (This)->lpVtbl -> DisableAudioInput(This) )
+
+#define IDeckLinkInput_v7_6_GetAvailableAudioSampleFrameCount(This,availableSampleFrameCount) \
+ ( (This)->lpVtbl -> GetAvailableAudioSampleFrameCount(This,availableSampleFrameCount) )
+
+#define IDeckLinkInput_v7_6_StartStreams(This) \
+ ( (This)->lpVtbl -> StartStreams(This) )
+
+#define IDeckLinkInput_v7_6_StopStreams(This) \
+ ( (This)->lpVtbl -> StopStreams(This) )
+
+#define IDeckLinkInput_v7_6_PauseStreams(This) \
+ ( (This)->lpVtbl -> PauseStreams(This) )
+
+#define IDeckLinkInput_v7_6_FlushStreams(This) \
+ ( (This)->lpVtbl -> FlushStreams(This) )
+
+#define IDeckLinkInput_v7_6_SetCallback(This,theCallback) \
+ ( (This)->lpVtbl -> SetCallback(This,theCallback) )
+
+#define IDeckLinkInput_v7_6_GetHardwareReferenceClock(This,desiredTimeScale,hardwareTime,timeInFrame,ticksPerFrame) \
+ ( (This)->lpVtbl -> GetHardwareReferenceClock(This,desiredTimeScale,hardwareTime,timeInFrame,ticksPerFrame) )
+
+#endif /* COBJMACROS */
+
+
+#endif /* C style interface */
+
+
+
+
+#endif /* __IDeckLinkInput_v7_6_INTERFACE_DEFINED__ */
+
+
+#ifndef __IDeckLinkTimecode_v7_6_INTERFACE_DEFINED__
+#define __IDeckLinkTimecode_v7_6_INTERFACE_DEFINED__
+
+/* interface IDeckLinkTimecode_v7_6 */
+/* [helpstring][uuid][object] */
+
+
+EXTERN_C const IID IID_IDeckLinkTimecode_v7_6;
+
+#if defined(__cplusplus) && !defined(CINTERFACE)
+
+ MIDL_INTERFACE("EFB9BCA6-A521-44F7-BD69-2332F24D9EE6")
+ IDeckLinkTimecode_v7_6 : public IUnknown
+ {
+ public:
+ virtual BMDTimecodeBCD STDMETHODCALLTYPE GetBCD( void) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE GetComponents(
+ /* [out] */ unsigned char *hours,
+ /* [out] */ unsigned char *minutes,
+ /* [out] */ unsigned char *seconds,
+ /* [out] */ unsigned char *frames) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE GetString(
+ /* [out] */ BSTR *timecode) = 0;
+
+ virtual BMDTimecodeFlags STDMETHODCALLTYPE GetFlags( void) = 0;
+
+ };
+
+#else /* C style interface */
+
+ typedef struct IDeckLinkTimecode_v7_6Vtbl
+ {
+ BEGIN_INTERFACE
+
+ HRESULT ( STDMETHODCALLTYPE *QueryInterface )(
+ IDeckLinkTimecode_v7_6 * This,
+ /* [in] */ REFIID riid,
+ /* [iid_is][out] */
+ __RPC__deref_out void **ppvObject);
+
+ ULONG ( STDMETHODCALLTYPE *AddRef )(
+ IDeckLinkTimecode_v7_6 * This);
+
+ ULONG ( STDMETHODCALLTYPE *Release )(
+ IDeckLinkTimecode_v7_6 * This);
+
+ BMDTimecodeBCD ( STDMETHODCALLTYPE *GetBCD )(
+ IDeckLinkTimecode_v7_6 * This);
+
+ HRESULT ( STDMETHODCALLTYPE *GetComponents )(
+ IDeckLinkTimecode_v7_6 * This,
+ /* [out] */ unsigned char *hours,
+ /* [out] */ unsigned char *minutes,
+ /* [out] */ unsigned char *seconds,
+ /* [out] */ unsigned char *frames);
+
+ HRESULT ( STDMETHODCALLTYPE *GetString )(
+ IDeckLinkTimecode_v7_6 * This,
+ /* [out] */ BSTR *timecode);
+
+ BMDTimecodeFlags ( STDMETHODCALLTYPE *GetFlags )(
+ IDeckLinkTimecode_v7_6 * This);
+
+ END_INTERFACE
+ } IDeckLinkTimecode_v7_6Vtbl;
+
+ interface IDeckLinkTimecode_v7_6
+ {
+ CONST_VTBL struct IDeckLinkTimecode_v7_6Vtbl *lpVtbl;
+ };
+
+
+
+#ifdef COBJMACROS
+
+
+#define IDeckLinkTimecode_v7_6_QueryInterface(This,riid,ppvObject) \
+ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) )
+
+#define IDeckLinkTimecode_v7_6_AddRef(This) \
+ ( (This)->lpVtbl -> AddRef(This) )
+
+#define IDeckLinkTimecode_v7_6_Release(This) \
+ ( (This)->lpVtbl -> Release(This) )
+
+
+#define IDeckLinkTimecode_v7_6_GetBCD(This) \
+ ( (This)->lpVtbl -> GetBCD(This) )
+
+#define IDeckLinkTimecode_v7_6_GetComponents(This,hours,minutes,seconds,frames) \
+ ( (This)->lpVtbl -> GetComponents(This,hours,minutes,seconds,frames) )
+
+#define IDeckLinkTimecode_v7_6_GetString(This,timecode) \
+ ( (This)->lpVtbl -> GetString(This,timecode) )
+
+#define IDeckLinkTimecode_v7_6_GetFlags(This) \
+ ( (This)->lpVtbl -> GetFlags(This) )
+
+#endif /* COBJMACROS */
+
+
+#endif /* C style interface */
+
+
+
+
+#endif /* __IDeckLinkTimecode_v7_6_INTERFACE_DEFINED__ */
+
+
+#ifndef __IDeckLinkVideoFrame_v7_6_INTERFACE_DEFINED__
+#define __IDeckLinkVideoFrame_v7_6_INTERFACE_DEFINED__
+
+/* interface IDeckLinkVideoFrame_v7_6 */
+/* [helpstring][local][uuid][object] */
+
+
+EXTERN_C const IID IID_IDeckLinkVideoFrame_v7_6;
+
+#if defined(__cplusplus) && !defined(CINTERFACE)
+
+ MIDL_INTERFACE("A8D8238E-6B18-4196-99E1-5AF717B83D32")
+ IDeckLinkVideoFrame_v7_6 : public IUnknown
+ {
+ public:
+ virtual long STDMETHODCALLTYPE GetWidth( void) = 0;
+
+ virtual long STDMETHODCALLTYPE GetHeight( void) = 0;
+
+ virtual long STDMETHODCALLTYPE GetRowBytes( void) = 0;
+
+ virtual BMDPixelFormat STDMETHODCALLTYPE GetPixelFormat( void) = 0;
+
+ virtual BMDFrameFlags STDMETHODCALLTYPE GetFlags( void) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE GetBytes(
+ /* [out] */ void **buffer) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE GetTimecode(
+ BMDTimecodeFormat format,
+ /* [out] */ IDeckLinkTimecode_v7_6 **timecode) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE GetAncillaryData(
+ /* [out] */ IDeckLinkVideoFrameAncillary **ancillary) = 0;
+
+ };
+
+#else /* C style interface */
+
+ typedef struct IDeckLinkVideoFrame_v7_6Vtbl
+ {
+ BEGIN_INTERFACE
+
+ HRESULT ( STDMETHODCALLTYPE *QueryInterface )(
+ IDeckLinkVideoFrame_v7_6 * This,
+ /* [in] */ REFIID riid,
+ /* [iid_is][out] */
+ __RPC__deref_out void **ppvObject);
+
+ ULONG ( STDMETHODCALLTYPE *AddRef )(
+ IDeckLinkVideoFrame_v7_6 * This);
+
+ ULONG ( STDMETHODCALLTYPE *Release )(
+ IDeckLinkVideoFrame_v7_6 * This);
+
+ long ( STDMETHODCALLTYPE *GetWidth )(
+ IDeckLinkVideoFrame_v7_6 * This);
+
+ long ( STDMETHODCALLTYPE *GetHeight )(
+ IDeckLinkVideoFrame_v7_6 * This);
+
+ long ( STDMETHODCALLTYPE *GetRowBytes )(
+ IDeckLinkVideoFrame_v7_6 * This);
+
+ BMDPixelFormat ( STDMETHODCALLTYPE *GetPixelFormat )(
+ IDeckLinkVideoFrame_v7_6 * This);
+
+ BMDFrameFlags ( STDMETHODCALLTYPE *GetFlags )(
+ IDeckLinkVideoFrame_v7_6 * This);
+
+ HRESULT ( STDMETHODCALLTYPE *GetBytes )(
+ IDeckLinkVideoFrame_v7_6 * This,
+ /* [out] */ void **buffer);
+
+ HRESULT ( STDMETHODCALLTYPE *GetTimecode )(
+ IDeckLinkVideoFrame_v7_6 * This,
+ BMDTimecodeFormat format,
+ /* [out] */ IDeckLinkTimecode_v7_6 **timecode);
+
+ HRESULT ( STDMETHODCALLTYPE *GetAncillaryData )(
+ IDeckLinkVideoFrame_v7_6 * This,
+ /* [out] */ IDeckLinkVideoFrameAncillary **ancillary);
+
+ END_INTERFACE
+ } IDeckLinkVideoFrame_v7_6Vtbl;
+
+ interface IDeckLinkVideoFrame_v7_6
+ {
+ CONST_VTBL struct IDeckLinkVideoFrame_v7_6Vtbl *lpVtbl;
+ };
+
+
+
+#ifdef COBJMACROS
+
+
+#define IDeckLinkVideoFrame_v7_6_QueryInterface(This,riid,ppvObject) \
+ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) )
+
+#define IDeckLinkVideoFrame_v7_6_AddRef(This) \
+ ( (This)->lpVtbl -> AddRef(This) )
+
+#define IDeckLinkVideoFrame_v7_6_Release(This) \
+ ( (This)->lpVtbl -> Release(This) )
+
+
+#define IDeckLinkVideoFrame_v7_6_GetWidth(This) \
+ ( (This)->lpVtbl -> GetWidth(This) )
+
+#define IDeckLinkVideoFrame_v7_6_GetHeight(This) \
+ ( (This)->lpVtbl -> GetHeight(This) )
+
+#define IDeckLinkVideoFrame_v7_6_GetRowBytes(This) \
+ ( (This)->lpVtbl -> GetRowBytes(This) )
+
+#define IDeckLinkVideoFrame_v7_6_GetPixelFormat(This) \
+ ( (This)->lpVtbl -> GetPixelFormat(This) )
+
+#define IDeckLinkVideoFrame_v7_6_GetFlags(This) \
+ ( (This)->lpVtbl -> GetFlags(This) )
+
+#define IDeckLinkVideoFrame_v7_6_GetBytes(This,buffer) \
+ ( (This)->lpVtbl -> GetBytes(This,buffer) )
+
+#define IDeckLinkVideoFrame_v7_6_GetTimecode(This,format,timecode) \
+ ( (This)->lpVtbl -> GetTimecode(This,format,timecode) )
+
+#define IDeckLinkVideoFrame_v7_6_GetAncillaryData(This,ancillary) \
+ ( (This)->lpVtbl -> GetAncillaryData(This,ancillary) )
+
+#endif /* COBJMACROS */
+
+
+#endif /* C style interface */
+
+
+
+
+#endif /* __IDeckLinkVideoFrame_v7_6_INTERFACE_DEFINED__ */
+
+
+#ifndef __IDeckLinkMutableVideoFrame_v7_6_INTERFACE_DEFINED__
+#define __IDeckLinkMutableVideoFrame_v7_6_INTERFACE_DEFINED__
+
+/* interface IDeckLinkMutableVideoFrame_v7_6 */
+/* [helpstring][local][uuid][object] */
+
+
+EXTERN_C const IID IID_IDeckLinkMutableVideoFrame_v7_6;
+
+#if defined(__cplusplus) && !defined(CINTERFACE)
+
+ MIDL_INTERFACE("46FCEE00-B4E6-43D0-91C0-023A7FCEB34F")
+ IDeckLinkMutableVideoFrame_v7_6 : public IDeckLinkVideoFrame_v7_6
+ {
+ public:
+ virtual HRESULT STDMETHODCALLTYPE SetFlags(
+ BMDFrameFlags newFlags) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE SetTimecode(
+ BMDTimecodeFormat format,
+ /* [in] */ IDeckLinkTimecode_v7_6 *timecode) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE SetTimecodeFromComponents(
+ BMDTimecodeFormat format,
+ unsigned char hours,
+ unsigned char minutes,
+ unsigned char seconds,
+ unsigned char frames,
+ BMDTimecodeFlags flags) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE SetAncillaryData(
+ /* [in] */ IDeckLinkVideoFrameAncillary *ancillary) = 0;
+
+ };
+
+#else /* C style interface */
+
+ typedef struct IDeckLinkMutableVideoFrame_v7_6Vtbl
+ {
+ BEGIN_INTERFACE
+
+ HRESULT ( STDMETHODCALLTYPE *QueryInterface )(
+ IDeckLinkMutableVideoFrame_v7_6 * This,
+ /* [in] */ REFIID riid,
+ /* [iid_is][out] */
+ __RPC__deref_out void **ppvObject);
+
+ ULONG ( STDMETHODCALLTYPE *AddRef )(
+ IDeckLinkMutableVideoFrame_v7_6 * This);
+
+ ULONG ( STDMETHODCALLTYPE *Release )(
+ IDeckLinkMutableVideoFrame_v7_6 * This);
+
+ long ( STDMETHODCALLTYPE *GetWidth )(
+ IDeckLinkMutableVideoFrame_v7_6 * This);
+
+ long ( STDMETHODCALLTYPE *GetHeight )(
+ IDeckLinkMutableVideoFrame_v7_6 * This);
+
+ long ( STDMETHODCALLTYPE *GetRowBytes )(
+ IDeckLinkMutableVideoFrame_v7_6 * This);
+
+ BMDPixelFormat ( STDMETHODCALLTYPE *GetPixelFormat )(
+ IDeckLinkMutableVideoFrame_v7_6 * This);
+
+ BMDFrameFlags ( STDMETHODCALLTYPE *GetFlags )(
+ IDeckLinkMutableVideoFrame_v7_6 * This);
+
+ HRESULT ( STDMETHODCALLTYPE *GetBytes )(
+ IDeckLinkMutableVideoFrame_v7_6 * This,
+ /* [out] */ void **buffer);
+
+ HRESULT ( STDMETHODCALLTYPE *GetTimecode )(
+ IDeckLinkMutableVideoFrame_v7_6 * This,
+ BMDTimecodeFormat format,
+ /* [out] */ IDeckLinkTimecode_v7_6 **timecode);
+
+ HRESULT ( STDMETHODCALLTYPE *GetAncillaryData )(
+ IDeckLinkMutableVideoFrame_v7_6 * This,
+ /* [out] */ IDeckLinkVideoFrameAncillary **ancillary);
+
+ HRESULT ( STDMETHODCALLTYPE *SetFlags )(
+ IDeckLinkMutableVideoFrame_v7_6 * This,
+ BMDFrameFlags newFlags);
+
+ HRESULT ( STDMETHODCALLTYPE *SetTimecode )(
+ IDeckLinkMutableVideoFrame_v7_6 * This,
+ BMDTimecodeFormat format,
+ /* [in] */ IDeckLinkTimecode_v7_6 *timecode);
+
+ HRESULT ( STDMETHODCALLTYPE *SetTimecodeFromComponents )(
+ IDeckLinkMutableVideoFrame_v7_6 * This,
+ BMDTimecodeFormat format,
+ unsigned char hours,
+ unsigned char minutes,
+ unsigned char seconds,
+ unsigned char frames,
+ BMDTimecodeFlags flags);
+
+ HRESULT ( STDMETHODCALLTYPE *SetAncillaryData )(
+ IDeckLinkMutableVideoFrame_v7_6 * This,
+ /* [in] */ IDeckLinkVideoFrameAncillary *ancillary);
+
+ END_INTERFACE
+ } IDeckLinkMutableVideoFrame_v7_6Vtbl;
+
+ interface IDeckLinkMutableVideoFrame_v7_6
+ {
+ CONST_VTBL struct IDeckLinkMutableVideoFrame_v7_6Vtbl *lpVtbl;
+ };
+
+
+
+#ifdef COBJMACROS
+
+
+#define IDeckLinkMutableVideoFrame_v7_6_QueryInterface(This,riid,ppvObject) \
+ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) )
+
+#define IDeckLinkMutableVideoFrame_v7_6_AddRef(This) \
+ ( (This)->lpVtbl -> AddRef(This) )
+
+#define IDeckLinkMutableVideoFrame_v7_6_Release(This) \
+ ( (This)->lpVtbl -> Release(This) )
+
+
+#define IDeckLinkMutableVideoFrame_v7_6_GetWidth(This) \
+ ( (This)->lpVtbl -> GetWidth(This) )
+
+#define IDeckLinkMutableVideoFrame_v7_6_GetHeight(This) \
+ ( (This)->lpVtbl -> GetHeight(This) )
+
+#define IDeckLinkMutableVideoFrame_v7_6_GetRowBytes(This) \
+ ( (This)->lpVtbl -> GetRowBytes(This) )
+
+#define IDeckLinkMutableVideoFrame_v7_6_GetPixelFormat(This) \
+ ( (This)->lpVtbl -> GetPixelFormat(This) )
+
+#define IDeckLinkMutableVideoFrame_v7_6_GetFlags(This) \
+ ( (This)->lpVtbl -> GetFlags(This) )
+
+#define IDeckLinkMutableVideoFrame_v7_6_GetBytes(This,buffer) \
+ ( (This)->lpVtbl -> GetBytes(This,buffer) )
+
+#define IDeckLinkMutableVideoFrame_v7_6_GetTimecode(This,format,timecode) \
+ ( (This)->lpVtbl -> GetTimecode(This,format,timecode) )
+
+#define IDeckLinkMutableVideoFrame_v7_6_GetAncillaryData(This,ancillary) \
+ ( (This)->lpVtbl -> GetAncillaryData(This,ancillary) )
+
+
+#define IDeckLinkMutableVideoFrame_v7_6_SetFlags(This,newFlags) \
+ ( (This)->lpVtbl -> SetFlags(This,newFlags) )
+
+#define IDeckLinkMutableVideoFrame_v7_6_SetTimecode(This,format,timecode) \
+ ( (This)->lpVtbl -> SetTimecode(This,format,timecode) )
+
+#define IDeckLinkMutableVideoFrame_v7_6_SetTimecodeFromComponents(This,format,hours,minutes,seconds,frames,flags) \
+ ( (This)->lpVtbl -> SetTimecodeFromComponents(This,format,hours,minutes,seconds,frames,flags) )
+
+#define IDeckLinkMutableVideoFrame_v7_6_SetAncillaryData(This,ancillary) \
+ ( (This)->lpVtbl -> SetAncillaryData(This,ancillary) )
+
+#endif /* COBJMACROS */
+
+
+#endif /* C style interface */
+
+
+
+
+#endif /* __IDeckLinkMutableVideoFrame_v7_6_INTERFACE_DEFINED__ */
+
+
+#ifndef __IDeckLinkVideoInputFrame_v7_6_INTERFACE_DEFINED__
+#define __IDeckLinkVideoInputFrame_v7_6_INTERFACE_DEFINED__
+
+/* interface IDeckLinkVideoInputFrame_v7_6 */
+/* [helpstring][local][uuid][object] */
+
+
+EXTERN_C const IID IID_IDeckLinkVideoInputFrame_v7_6;
+
+#if defined(__cplusplus) && !defined(CINTERFACE)
+
+ MIDL_INTERFACE("9A74FA41-AE9F-47AC-8CF4-01F42DD59965")
+ IDeckLinkVideoInputFrame_v7_6 : public IDeckLinkVideoFrame_v7_6
+ {
+ public:
+ virtual HRESULT STDMETHODCALLTYPE GetStreamTime(
+ /* [out] */ BMDTimeValue *frameTime,
+ /* [out] */ BMDTimeValue *frameDuration,
+ BMDTimeScale timeScale) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE GetHardwareReferenceTimestamp(
+ BMDTimeScale timeScale,
+ /* [out] */ BMDTimeValue *frameTime,
+ /* [out] */ BMDTimeValue *frameDuration) = 0;
+
+ };
+
+#else /* C style interface */
+
+ typedef struct IDeckLinkVideoInputFrame_v7_6Vtbl
+ {
+ BEGIN_INTERFACE
+
+ HRESULT ( STDMETHODCALLTYPE *QueryInterface )(
+ IDeckLinkVideoInputFrame_v7_6 * This,
+ /* [in] */ REFIID riid,
+ /* [iid_is][out] */
+ __RPC__deref_out void **ppvObject);
+
+ ULONG ( STDMETHODCALLTYPE *AddRef )(
+ IDeckLinkVideoInputFrame_v7_6 * This);
+
+ ULONG ( STDMETHODCALLTYPE *Release )(
+ IDeckLinkVideoInputFrame_v7_6 * This);
+
+ long ( STDMETHODCALLTYPE *GetWidth )(
+ IDeckLinkVideoInputFrame_v7_6 * This);
+
+ long ( STDMETHODCALLTYPE *GetHeight )(
+ IDeckLinkVideoInputFrame_v7_6 * This);
+
+ long ( STDMETHODCALLTYPE *GetRowBytes )(
+ IDeckLinkVideoInputFrame_v7_6 * This);
+
+ BMDPixelFormat ( STDMETHODCALLTYPE *GetPixelFormat )(
+ IDeckLinkVideoInputFrame_v7_6 * This);
+
+ BMDFrameFlags ( STDMETHODCALLTYPE *GetFlags )(
+ IDeckLinkVideoInputFrame_v7_6 * This);
+
+ HRESULT ( STDMETHODCALLTYPE *GetBytes )(
+ IDeckLinkVideoInputFrame_v7_6 * This,
+ /* [out] */ void **buffer);
+
+ HRESULT ( STDMETHODCALLTYPE *GetTimecode )(
+ IDeckLinkVideoInputFrame_v7_6 * This,
+ BMDTimecodeFormat format,
+ /* [out] */ IDeckLinkTimecode_v7_6 **timecode);
+
+ HRESULT ( STDMETHODCALLTYPE *GetAncillaryData )(
+ IDeckLinkVideoInputFrame_v7_6 * This,
+ /* [out] */ IDeckLinkVideoFrameAncillary **ancillary);
+
+ HRESULT ( STDMETHODCALLTYPE *GetStreamTime )(
+ IDeckLinkVideoInputFrame_v7_6 * This,
+ /* [out] */ BMDTimeValue *frameTime,
+ /* [out] */ BMDTimeValue *frameDuration,
+ BMDTimeScale timeScale);
+
+ HRESULT ( STDMETHODCALLTYPE *GetHardwareReferenceTimestamp )(
+ IDeckLinkVideoInputFrame_v7_6 * This,
+ BMDTimeScale timeScale,
+ /* [out] */ BMDTimeValue *frameTime,
+ /* [out] */ BMDTimeValue *frameDuration);
+
+ END_INTERFACE
+ } IDeckLinkVideoInputFrame_v7_6Vtbl;
+
+ interface IDeckLinkVideoInputFrame_v7_6
+ {
+ CONST_VTBL struct IDeckLinkVideoInputFrame_v7_6Vtbl *lpVtbl;
+ };
+
+
+
+#ifdef COBJMACROS
+
+
+#define IDeckLinkVideoInputFrame_v7_6_QueryInterface(This,riid,ppvObject) \
+ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) )
+
+#define IDeckLinkVideoInputFrame_v7_6_AddRef(This) \
+ ( (This)->lpVtbl -> AddRef(This) )
+
+#define IDeckLinkVideoInputFrame_v7_6_Release(This) \
+ ( (This)->lpVtbl -> Release(This) )
+
+
+#define IDeckLinkVideoInputFrame_v7_6_GetWidth(This) \
+ ( (This)->lpVtbl -> GetWidth(This) )
+
+#define IDeckLinkVideoInputFrame_v7_6_GetHeight(This) \
+ ( (This)->lpVtbl -> GetHeight(This) )
+
+#define IDeckLinkVideoInputFrame_v7_6_GetRowBytes(This) \
+ ( (This)->lpVtbl -> GetRowBytes(This) )
+
+#define IDeckLinkVideoInputFrame_v7_6_GetPixelFormat(This) \
+ ( (This)->lpVtbl -> GetPixelFormat(This) )
+
+#define IDeckLinkVideoInputFrame_v7_6_GetFlags(This) \
+ ( (This)->lpVtbl -> GetFlags(This) )
+
+#define IDeckLinkVideoInputFrame_v7_6_GetBytes(This,buffer) \
+ ( (This)->lpVtbl -> GetBytes(This,buffer) )
+
+#define IDeckLinkVideoInputFrame_v7_6_GetTimecode(This,format,timecode) \
+ ( (This)->lpVtbl -> GetTimecode(This,format,timecode) )
+
+#define IDeckLinkVideoInputFrame_v7_6_GetAncillaryData(This,ancillary) \
+ ( (This)->lpVtbl -> GetAncillaryData(This,ancillary) )
+
+
+#define IDeckLinkVideoInputFrame_v7_6_GetStreamTime(This,frameTime,frameDuration,timeScale) \
+ ( (This)->lpVtbl -> GetStreamTime(This,frameTime,frameDuration,timeScale) )
+
+#define IDeckLinkVideoInputFrame_v7_6_GetHardwareReferenceTimestamp(This,timeScale,frameTime,frameDuration) \
+ ( (This)->lpVtbl -> GetHardwareReferenceTimestamp(This,timeScale,frameTime,frameDuration) )
+
+#endif /* COBJMACROS */
+
+
+#endif /* C style interface */
+
+
+
+
+#endif /* __IDeckLinkVideoInputFrame_v7_6_INTERFACE_DEFINED__ */
+
+
+#ifndef __IDeckLinkScreenPreviewCallback_v7_6_INTERFACE_DEFINED__
+#define __IDeckLinkScreenPreviewCallback_v7_6_INTERFACE_DEFINED__
+
+/* interface IDeckLinkScreenPreviewCallback_v7_6 */
+/* [helpstring][local][uuid][object] */
+
+
+EXTERN_C const IID IID_IDeckLinkScreenPreviewCallback_v7_6;
+
+#if defined(__cplusplus) && !defined(CINTERFACE)
+
+ MIDL_INTERFACE("373F499D-4B4D-4518-AD22-6354E5A5825E")
+ IDeckLinkScreenPreviewCallback_v7_6 : public IUnknown
+ {
+ public:
+ virtual HRESULT STDMETHODCALLTYPE DrawFrame(
+ /* [in] */ IDeckLinkVideoFrame_v7_6 *theFrame) = 0;
+
+ };
+
+#else /* C style interface */
+
+ typedef struct IDeckLinkScreenPreviewCallback_v7_6Vtbl
+ {
+ BEGIN_INTERFACE
+
+ HRESULT ( STDMETHODCALLTYPE *QueryInterface )(
+ IDeckLinkScreenPreviewCallback_v7_6 * This,
+ /* [in] */ REFIID riid,
+ /* [iid_is][out] */
+ __RPC__deref_out void **ppvObject);
+
+ ULONG ( STDMETHODCALLTYPE *AddRef )(
+ IDeckLinkScreenPreviewCallback_v7_6 * This);
+
+ ULONG ( STDMETHODCALLTYPE *Release )(
+ IDeckLinkScreenPreviewCallback_v7_6 * This);
+
+ HRESULT ( STDMETHODCALLTYPE *DrawFrame )(
+ IDeckLinkScreenPreviewCallback_v7_6 * This,
+ /* [in] */ IDeckLinkVideoFrame_v7_6 *theFrame);
+
+ END_INTERFACE
+ } IDeckLinkScreenPreviewCallback_v7_6Vtbl;
+
+ interface IDeckLinkScreenPreviewCallback_v7_6
+ {
+ CONST_VTBL struct IDeckLinkScreenPreviewCallback_v7_6Vtbl *lpVtbl;
+ };
+
+
+
+#ifdef COBJMACROS
+
+
+#define IDeckLinkScreenPreviewCallback_v7_6_QueryInterface(This,riid,ppvObject) \
+ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) )
+
+#define IDeckLinkScreenPreviewCallback_v7_6_AddRef(This) \
+ ( (This)->lpVtbl -> AddRef(This) )
+
+#define IDeckLinkScreenPreviewCallback_v7_6_Release(This) \
+ ( (This)->lpVtbl -> Release(This) )
+
+
+#define IDeckLinkScreenPreviewCallback_v7_6_DrawFrame(This,theFrame) \
+ ( (This)->lpVtbl -> DrawFrame(This,theFrame) )
+
+#endif /* COBJMACROS */
+
+
+#endif /* C style interface */
+
+
+
+
+#endif /* __IDeckLinkScreenPreviewCallback_v7_6_INTERFACE_DEFINED__ */
+
+
+#ifndef __IDeckLinkGLScreenPreviewHelper_v7_6_INTERFACE_DEFINED__
+#define __IDeckLinkGLScreenPreviewHelper_v7_6_INTERFACE_DEFINED__
+
+/* interface IDeckLinkGLScreenPreviewHelper_v7_6 */
+/* [helpstring][local][uuid][object] */
+
+
+EXTERN_C const IID IID_IDeckLinkGLScreenPreviewHelper_v7_6;
+
+#if defined(__cplusplus) && !defined(CINTERFACE)
+
+ MIDL_INTERFACE("BA575CD9-A15E-497B-B2C2-F9AFE7BE4EBA")
+ IDeckLinkGLScreenPreviewHelper_v7_6 : public IUnknown
+ {
+ public:
+ virtual HRESULT STDMETHODCALLTYPE InitializeGL( void) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE PaintGL( void) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE SetFrame(
+ /* [in] */ IDeckLinkVideoFrame_v7_6 *theFrame) = 0;
+
+ };
+
+#else /* C style interface */
+
+ typedef struct IDeckLinkGLScreenPreviewHelper_v7_6Vtbl
+ {
+ BEGIN_INTERFACE
+
+ HRESULT ( STDMETHODCALLTYPE *QueryInterface )(
+ IDeckLinkGLScreenPreviewHelper_v7_6 * This,
+ /* [in] */ REFIID riid,
+ /* [iid_is][out] */
+ __RPC__deref_out void **ppvObject);
+
+ ULONG ( STDMETHODCALLTYPE *AddRef )(
+ IDeckLinkGLScreenPreviewHelper_v7_6 * This);
+
+ ULONG ( STDMETHODCALLTYPE *Release )(
+ IDeckLinkGLScreenPreviewHelper_v7_6 * This);
+
+ HRESULT ( STDMETHODCALLTYPE *InitializeGL )(
+ IDeckLinkGLScreenPreviewHelper_v7_6 * This);
+
+ HRESULT ( STDMETHODCALLTYPE *PaintGL )(
+ IDeckLinkGLScreenPreviewHelper_v7_6 * This);
+
+ HRESULT ( STDMETHODCALLTYPE *SetFrame )(
+ IDeckLinkGLScreenPreviewHelper_v7_6 * This,
+ /* [in] */ IDeckLinkVideoFrame_v7_6 *theFrame);
+
+ END_INTERFACE
+ } IDeckLinkGLScreenPreviewHelper_v7_6Vtbl;
+
+ interface IDeckLinkGLScreenPreviewHelper_v7_6
+ {
+ CONST_VTBL struct IDeckLinkGLScreenPreviewHelper_v7_6Vtbl *lpVtbl;
+ };
+
+
+
+#ifdef COBJMACROS
+
+
+#define IDeckLinkGLScreenPreviewHelper_v7_6_QueryInterface(This,riid,ppvObject) \
+ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) )
+
+#define IDeckLinkGLScreenPreviewHelper_v7_6_AddRef(This) \
+ ( (This)->lpVtbl -> AddRef(This) )
+
+#define IDeckLinkGLScreenPreviewHelper_v7_6_Release(This) \
+ ( (This)->lpVtbl -> Release(This) )
+
+
+#define IDeckLinkGLScreenPreviewHelper_v7_6_InitializeGL(This) \
+ ( (This)->lpVtbl -> InitializeGL(This) )
+
+#define IDeckLinkGLScreenPreviewHelper_v7_6_PaintGL(This) \
+ ( (This)->lpVtbl -> PaintGL(This) )
+
+#define IDeckLinkGLScreenPreviewHelper_v7_6_SetFrame(This,theFrame) \
+ ( (This)->lpVtbl -> SetFrame(This,theFrame) )
+
+#endif /* COBJMACROS */
+
+
+#endif /* C style interface */
+
+
+
+
+#endif /* __IDeckLinkGLScreenPreviewHelper_v7_6_INTERFACE_DEFINED__ */
+
+
+#ifndef __IDeckLinkVideoConversion_v7_6_INTERFACE_DEFINED__
+#define __IDeckLinkVideoConversion_v7_6_INTERFACE_DEFINED__
+
+/* interface IDeckLinkVideoConversion_v7_6 */
+/* [helpstring][local][uuid][object] */
+
+
+EXTERN_C const IID IID_IDeckLinkVideoConversion_v7_6;
+
+#if defined(__cplusplus) && !defined(CINTERFACE)
+
+ MIDL_INTERFACE("3EB504C9-F97D-40FE-A158-D407D48CB53B")
+ IDeckLinkVideoConversion_v7_6 : public IUnknown
+ {
+ public:
+ virtual HRESULT STDMETHODCALLTYPE ConvertFrame(
+ /* [in] */ IDeckLinkVideoFrame_v7_6 *srcFrame,
+ /* [in] */ IDeckLinkVideoFrame_v7_6 *dstFrame) = 0;
+
+ };
+
+#else /* C style interface */
+
+ typedef struct IDeckLinkVideoConversion_v7_6Vtbl
+ {
+ BEGIN_INTERFACE
+
+ HRESULT ( STDMETHODCALLTYPE *QueryInterface )(
+ IDeckLinkVideoConversion_v7_6 * This,
+ /* [in] */ REFIID riid,
+ /* [iid_is][out] */
+ __RPC__deref_out void **ppvObject);
+
+ ULONG ( STDMETHODCALLTYPE *AddRef )(
+ IDeckLinkVideoConversion_v7_6 * This);
+
+ ULONG ( STDMETHODCALLTYPE *Release )(
+ IDeckLinkVideoConversion_v7_6 * This);
+
+ HRESULT ( STDMETHODCALLTYPE *ConvertFrame )(
+ IDeckLinkVideoConversion_v7_6 * This,
+ /* [in] */ IDeckLinkVideoFrame_v7_6 *srcFrame,
+ /* [in] */ IDeckLinkVideoFrame_v7_6 *dstFrame);
+
+ END_INTERFACE
+ } IDeckLinkVideoConversion_v7_6Vtbl;
+
+ interface IDeckLinkVideoConversion_v7_6
+ {
+ CONST_VTBL struct IDeckLinkVideoConversion_v7_6Vtbl *lpVtbl;
+ };
+
+
+
+#ifdef COBJMACROS
+
+
+#define IDeckLinkVideoConversion_v7_6_QueryInterface(This,riid,ppvObject) \
+ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) )
+
+#define IDeckLinkVideoConversion_v7_6_AddRef(This) \
+ ( (This)->lpVtbl -> AddRef(This) )
+
+#define IDeckLinkVideoConversion_v7_6_Release(This) \
+ ( (This)->lpVtbl -> Release(This) )
+
+
+#define IDeckLinkVideoConversion_v7_6_ConvertFrame(This,srcFrame,dstFrame) \
+ ( (This)->lpVtbl -> ConvertFrame(This,srcFrame,dstFrame) )
+
+#endif /* COBJMACROS */
+
+
+#endif /* C style interface */
+
+
+
+
+#endif /* __IDeckLinkVideoConversion_v7_6_INTERFACE_DEFINED__ */
+
+
+#ifndef __IDeckLinkConfiguration_v7_6_INTERFACE_DEFINED__
+#define __IDeckLinkConfiguration_v7_6_INTERFACE_DEFINED__
+
+/* interface IDeckLinkConfiguration_v7_6 */
+/* [helpstring][uuid][object] */
+
+
+EXTERN_C const IID IID_IDeckLinkConfiguration_v7_6;
+
+#if defined(__cplusplus) && !defined(CINTERFACE)
+
+ MIDL_INTERFACE("B8EAD569-B764-47F0-A73F-AE40DF6CBF10")
+ IDeckLinkConfiguration_v7_6 : public IUnknown
+ {
+ public:
+ virtual HRESULT STDMETHODCALLTYPE GetConfigurationValidator(
+ /* [out] */ IDeckLinkConfiguration_v7_6 **configObject) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE WriteConfigurationToPreferences( void) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE SetVideoOutputFormat(
+ /* [in] */ BMDVideoConnection_v7_6 videoOutputConnection) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE IsVideoOutputActive(
+ /* [in] */ BMDVideoConnection_v7_6 videoOutputConnection,
+ /* [out] */ BOOL *active) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE SetAnalogVideoOutputFlags(
+ /* [in] */ BMDAnalogVideoFlags analogVideoFlags) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE GetAnalogVideoOutputFlags(
+ /* [out] */ BMDAnalogVideoFlags *analogVideoFlags) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE EnableFieldFlickerRemovalWhenPaused(
+ /* [in] */ BOOL enable) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE IsEnabledFieldFlickerRemovalWhenPaused(
+ /* [out] */ BOOL *enabled) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE Set444And3GBpsVideoOutput(
+ /* [in] */ BOOL enable444VideoOutput,
+ /* [in] */ BOOL enable3GbsOutput) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE Get444And3GBpsVideoOutput(
+ /* [out] */ BOOL *is444VideoOutputEnabled,
+ /* [out] */ BOOL *threeGbsOutputEnabled) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE SetVideoOutputConversionMode(
+ /* [in] */ BMDVideoOutputConversionMode conversionMode) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE GetVideoOutputConversionMode(
+ /* [out] */ BMDVideoOutputConversionMode *conversionMode) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE Set_HD1080p24_to_HD1080i5994_Conversion(
+ /* [in] */ BOOL enable) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE Get_HD1080p24_to_HD1080i5994_Conversion(
+ /* [out] */ BOOL *enabled) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE SetVideoInputFormat(
+ /* [in] */ BMDVideoConnection_v7_6 videoInputFormat) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE GetVideoInputFormat(
+ /* [out] */ BMDVideoConnection_v7_6 *videoInputFormat) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE SetAnalogVideoInputFlags(
+ /* [in] */ BMDAnalogVideoFlags analogVideoFlags) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE GetAnalogVideoInputFlags(
+ /* [out] */ BMDAnalogVideoFlags *analogVideoFlags) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE SetVideoInputConversionMode(
+ /* [in] */ BMDVideoInputConversionMode conversionMode) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE GetVideoInputConversionMode(
+ /* [out] */ BMDVideoInputConversionMode *conversionMode) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE SetBlackVideoOutputDuringCapture(
+ /* [in] */ BOOL blackOutInCapture) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE GetBlackVideoOutputDuringCapture(
+ /* [out] */ BOOL *blackOutInCapture) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE Set32PulldownSequenceInitialTimecodeFrame(
+ /* [in] */ unsigned long aFrameTimecode) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE Get32PulldownSequenceInitialTimecodeFrame(
+ /* [out] */ unsigned long *aFrameTimecode) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE SetVancSourceLineMapping(
+ /* [in] */ unsigned long activeLine1VANCsource,
+ /* [in] */ unsigned long activeLine2VANCsource,
+ /* [in] */ unsigned long activeLine3VANCsource) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE GetVancSourceLineMapping(
+ /* [out] */ unsigned long *activeLine1VANCsource,
+ /* [out] */ unsigned long *activeLine2VANCsource,
+ /* [out] */ unsigned long *activeLine3VANCsource) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE SetAudioInputFormat(
+ /* [in] */ BMDAudioConnection audioInputFormat) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE GetAudioInputFormat(
+ /* [out] */ BMDAudioConnection *audioInputFormat) = 0;
+
+ };
+
+#else /* C style interface */
+
+ typedef struct IDeckLinkConfiguration_v7_6Vtbl
+ {
+ BEGIN_INTERFACE
+
+ HRESULT ( STDMETHODCALLTYPE *QueryInterface )(
+ IDeckLinkConfiguration_v7_6 * This,
+ /* [in] */ REFIID riid,
+ /* [iid_is][out] */
+ __RPC__deref_out void **ppvObject);
+
+ ULONG ( STDMETHODCALLTYPE *AddRef )(
+ IDeckLinkConfiguration_v7_6 * This);
+
+ ULONG ( STDMETHODCALLTYPE *Release )(
+ IDeckLinkConfiguration_v7_6 * This);
+
+ HRESULT ( STDMETHODCALLTYPE *GetConfigurationValidator )(
+ IDeckLinkConfiguration_v7_6 * This,
+ /* [out] */ IDeckLinkConfiguration_v7_6 **configObject);
+
+ HRESULT ( STDMETHODCALLTYPE *WriteConfigurationToPreferences )(
+ IDeckLinkConfiguration_v7_6 * This);
+
+ HRESULT ( STDMETHODCALLTYPE *SetVideoOutputFormat )(
+ IDeckLinkConfiguration_v7_6 * This,
+ /* [in] */ BMDVideoConnection_v7_6 videoOutputConnection);
+
+ HRESULT ( STDMETHODCALLTYPE *IsVideoOutputActive )(
+ IDeckLinkConfiguration_v7_6 * This,
+ /* [in] */ BMDVideoConnection_v7_6 videoOutputConnection,
+ /* [out] */ BOOL *active);
+
+ HRESULT ( STDMETHODCALLTYPE *SetAnalogVideoOutputFlags )(
+ IDeckLinkConfiguration_v7_6 * This,
+ /* [in] */ BMDAnalogVideoFlags analogVideoFlags);
+
+ HRESULT ( STDMETHODCALLTYPE *GetAnalogVideoOutputFlags )(
+ IDeckLinkConfiguration_v7_6 * This,
+ /* [out] */ BMDAnalogVideoFlags *analogVideoFlags);
+
+ HRESULT ( STDMETHODCALLTYPE *EnableFieldFlickerRemovalWhenPaused )(
+ IDeckLinkConfiguration_v7_6 * This,
+ /* [in] */ BOOL enable);
+
+ HRESULT ( STDMETHODCALLTYPE *IsEnabledFieldFlickerRemovalWhenPaused )(
+ IDeckLinkConfiguration_v7_6 * This,
+ /* [out] */ BOOL *enabled);
+
+ HRESULT ( STDMETHODCALLTYPE *Set444And3GBpsVideoOutput )(
+ IDeckLinkConfiguration_v7_6 * This,
+ /* [in] */ BOOL enable444VideoOutput,
+ /* [in] */ BOOL enable3GbsOutput);
+
+ HRESULT ( STDMETHODCALLTYPE *Get444And3GBpsVideoOutput )(
+ IDeckLinkConfiguration_v7_6 * This,
+ /* [out] */ BOOL *is444VideoOutputEnabled,
+ /* [out] */ BOOL *threeGbsOutputEnabled);
+
+ HRESULT ( STDMETHODCALLTYPE *SetVideoOutputConversionMode )(
+ IDeckLinkConfiguration_v7_6 * This,
+ /* [in] */ BMDVideoOutputConversionMode conversionMode);
+
+ HRESULT ( STDMETHODCALLTYPE *GetVideoOutputConversionMode )(
+ IDeckLinkConfiguration_v7_6 * This,
+ /* [out] */ BMDVideoOutputConversionMode *conversionMode);
+
+ HRESULT ( STDMETHODCALLTYPE *Set_HD1080p24_to_HD1080i5994_Conversion )(
+ IDeckLinkConfiguration_v7_6 * This,
+ /* [in] */ BOOL enable);
+
+ HRESULT ( STDMETHODCALLTYPE *Get_HD1080p24_to_HD1080i5994_Conversion )(
+ IDeckLinkConfiguration_v7_6 * This,
+ /* [out] */ BOOL *enabled);
+
+ HRESULT ( STDMETHODCALLTYPE *SetVideoInputFormat )(
+ IDeckLinkConfiguration_v7_6 * This,
+ /* [in] */ BMDVideoConnection_v7_6 videoInputFormat);
+
+ HRESULT ( STDMETHODCALLTYPE *GetVideoInputFormat )(
+ IDeckLinkConfiguration_v7_6 * This,
+ /* [out] */ BMDVideoConnection_v7_6 *videoInputFormat);
+
+ HRESULT ( STDMETHODCALLTYPE *SetAnalogVideoInputFlags )(
+ IDeckLinkConfiguration_v7_6 * This,
+ /* [in] */ BMDAnalogVideoFlags analogVideoFlags);
+
+ HRESULT ( STDMETHODCALLTYPE *GetAnalogVideoInputFlags )(
+ IDeckLinkConfiguration_v7_6 * This,
+ /* [out] */ BMDAnalogVideoFlags *analogVideoFlags);
+
+ HRESULT ( STDMETHODCALLTYPE *SetVideoInputConversionMode )(
+ IDeckLinkConfiguration_v7_6 * This,
+ /* [in] */ BMDVideoInputConversionMode conversionMode);
+
+ HRESULT ( STDMETHODCALLTYPE *GetVideoInputConversionMode )(
+ IDeckLinkConfiguration_v7_6 * This,
+ /* [out] */ BMDVideoInputConversionMode *conversionMode);
+
+ HRESULT ( STDMETHODCALLTYPE *SetBlackVideoOutputDuringCapture )(
+ IDeckLinkConfiguration_v7_6 * This,
+ /* [in] */ BOOL blackOutInCapture);
+
+ HRESULT ( STDMETHODCALLTYPE *GetBlackVideoOutputDuringCapture )(
+ IDeckLinkConfiguration_v7_6 * This,
+ /* [out] */ BOOL *blackOutInCapture);
+
+ HRESULT ( STDMETHODCALLTYPE *Set32PulldownSequenceInitialTimecodeFrame )(
+ IDeckLinkConfiguration_v7_6 * This,
+ /* [in] */ unsigned long aFrameTimecode);
+
+ HRESULT ( STDMETHODCALLTYPE *Get32PulldownSequenceInitialTimecodeFrame )(
+ IDeckLinkConfiguration_v7_6 * This,
+ /* [out] */ unsigned long *aFrameTimecode);
+
+ HRESULT ( STDMETHODCALLTYPE *SetVancSourceLineMapping )(
+ IDeckLinkConfiguration_v7_6 * This,
+ /* [in] */ unsigned long activeLine1VANCsource,
+ /* [in] */ unsigned long activeLine2VANCsource,
+ /* [in] */ unsigned long activeLine3VANCsource);
+
+ HRESULT ( STDMETHODCALLTYPE *GetVancSourceLineMapping )(
+ IDeckLinkConfiguration_v7_6 * This,
+ /* [out] */ unsigned long *activeLine1VANCsource,
+ /* [out] */ unsigned long *activeLine2VANCsource,
+ /* [out] */ unsigned long *activeLine3VANCsource);
+
+ HRESULT ( STDMETHODCALLTYPE *SetAudioInputFormat )(
+ IDeckLinkConfiguration_v7_6 * This,
+ /* [in] */ BMDAudioConnection audioInputFormat);
+
+ HRESULT ( STDMETHODCALLTYPE *GetAudioInputFormat )(
+ IDeckLinkConfiguration_v7_6 * This,
+ /* [out] */ BMDAudioConnection *audioInputFormat);
+
+ END_INTERFACE
+ } IDeckLinkConfiguration_v7_6Vtbl;
+
+ interface IDeckLinkConfiguration_v7_6
+ {
+ CONST_VTBL struct IDeckLinkConfiguration_v7_6Vtbl *lpVtbl;
+ };
+
+
+
+#ifdef COBJMACROS
+
+
+#define IDeckLinkConfiguration_v7_6_QueryInterface(This,riid,ppvObject) \
+ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) )
+
+#define IDeckLinkConfiguration_v7_6_AddRef(This) \
+ ( (This)->lpVtbl -> AddRef(This) )
+
+#define IDeckLinkConfiguration_v7_6_Release(This) \
+ ( (This)->lpVtbl -> Release(This) )
+
+
+#define IDeckLinkConfiguration_v7_6_GetConfigurationValidator(This,configObject) \
+ ( (This)->lpVtbl -> GetConfigurationValidator(This,configObject) )
+
+#define IDeckLinkConfiguration_v7_6_WriteConfigurationToPreferences(This) \
+ ( (This)->lpVtbl -> WriteConfigurationToPreferences(This) )
+
+#define IDeckLinkConfiguration_v7_6_SetVideoOutputFormat(This,videoOutputConnection) \
+ ( (This)->lpVtbl -> SetVideoOutputFormat(This,videoOutputConnection) )
+
+#define IDeckLinkConfiguration_v7_6_IsVideoOutputActive(This,videoOutputConnection,active) \
+ ( (This)->lpVtbl -> IsVideoOutputActive(This,videoOutputConnection,active) )
+
+#define IDeckLinkConfiguration_v7_6_SetAnalogVideoOutputFlags(This,analogVideoFlags) \
+ ( (This)->lpVtbl -> SetAnalogVideoOutputFlags(This,analogVideoFlags) )
+
+#define IDeckLinkConfiguration_v7_6_GetAnalogVideoOutputFlags(This,analogVideoFlags) \
+ ( (This)->lpVtbl -> GetAnalogVideoOutputFlags(This,analogVideoFlags) )
+
+#define IDeckLinkConfiguration_v7_6_EnableFieldFlickerRemovalWhenPaused(This,enable) \
+ ( (This)->lpVtbl -> EnableFieldFlickerRemovalWhenPaused(This,enable) )
+
+#define IDeckLinkConfiguration_v7_6_IsEnabledFieldFlickerRemovalWhenPaused(This,enabled) \
+ ( (This)->lpVtbl -> IsEnabledFieldFlickerRemovalWhenPaused(This,enabled) )
+
+#define IDeckLinkConfiguration_v7_6_Set444And3GBpsVideoOutput(This,enable444VideoOutput,enable3GbsOutput) \
+ ( (This)->lpVtbl -> Set444And3GBpsVideoOutput(This,enable444VideoOutput,enable3GbsOutput) )
+
+#define IDeckLinkConfiguration_v7_6_Get444And3GBpsVideoOutput(This,is444VideoOutputEnabled,threeGbsOutputEnabled) \
+ ( (This)->lpVtbl -> Get444And3GBpsVideoOutput(This,is444VideoOutputEnabled,threeGbsOutputEnabled) )
+
+#define IDeckLinkConfiguration_v7_6_SetVideoOutputConversionMode(This,conversionMode) \
+ ( (This)->lpVtbl -> SetVideoOutputConversionMode(This,conversionMode) )
+
+#define IDeckLinkConfiguration_v7_6_GetVideoOutputConversionMode(This,conversionMode) \
+ ( (This)->lpVtbl -> GetVideoOutputConversionMode(This,conversionMode) )
+
+#define IDeckLinkConfiguration_v7_6_Set_HD1080p24_to_HD1080i5994_Conversion(This,enable) \
+ ( (This)->lpVtbl -> Set_HD1080p24_to_HD1080i5994_Conversion(This,enable) )
+
+#define IDeckLinkConfiguration_v7_6_Get_HD1080p24_to_HD1080i5994_Conversion(This,enabled) \
+ ( (This)->lpVtbl -> Get_HD1080p24_to_HD1080i5994_Conversion(This,enabled) )
+
+#define IDeckLinkConfiguration_v7_6_SetVideoInputFormat(This,videoInputFormat) \
+ ( (This)->lpVtbl -> SetVideoInputFormat(This,videoInputFormat) )
+
+#define IDeckLinkConfiguration_v7_6_GetVideoInputFormat(This,videoInputFormat) \
+ ( (This)->lpVtbl -> GetVideoInputFormat(This,videoInputFormat) )
+
+#define IDeckLinkConfiguration_v7_6_SetAnalogVideoInputFlags(This,analogVideoFlags) \
+ ( (This)->lpVtbl -> SetAnalogVideoInputFlags(This,analogVideoFlags) )
+
+#define IDeckLinkConfiguration_v7_6_GetAnalogVideoInputFlags(This,analogVideoFlags) \
+ ( (This)->lpVtbl -> GetAnalogVideoInputFlags(This,analogVideoFlags) )
+
+#define IDeckLinkConfiguration_v7_6_SetVideoInputConversionMode(This,conversionMode) \
+ ( (This)->lpVtbl -> SetVideoInputConversionMode(This,conversionMode) )
+
+#define IDeckLinkConfiguration_v7_6_GetVideoInputConversionMode(This,conversionMode) \
+ ( (This)->lpVtbl -> GetVideoInputConversionMode(This,conversionMode) )
+
+#define IDeckLinkConfiguration_v7_6_SetBlackVideoOutputDuringCapture(This,blackOutInCapture) \
+ ( (This)->lpVtbl -> SetBlackVideoOutputDuringCapture(This,blackOutInCapture) )
+
+#define IDeckLinkConfiguration_v7_6_GetBlackVideoOutputDuringCapture(This,blackOutInCapture) \
+ ( (This)->lpVtbl -> GetBlackVideoOutputDuringCapture(This,blackOutInCapture) )
+
+#define IDeckLinkConfiguration_v7_6_Set32PulldownSequenceInitialTimecodeFrame(This,aFrameTimecode) \
+ ( (This)->lpVtbl -> Set32PulldownSequenceInitialTimecodeFrame(This,aFrameTimecode) )
+
+#define IDeckLinkConfiguration_v7_6_Get32PulldownSequenceInitialTimecodeFrame(This,aFrameTimecode) \
+ ( (This)->lpVtbl -> Get32PulldownSequenceInitialTimecodeFrame(This,aFrameTimecode) )
+
+#define IDeckLinkConfiguration_v7_6_SetVancSourceLineMapping(This,activeLine1VANCsource,activeLine2VANCsource,activeLine3VANCsource) \
+ ( (This)->lpVtbl -> SetVancSourceLineMapping(This,activeLine1VANCsource,activeLine2VANCsource,activeLine3VANCsource) )
+
+#define IDeckLinkConfiguration_v7_6_GetVancSourceLineMapping(This,activeLine1VANCsource,activeLine2VANCsource,activeLine3VANCsource) \
+ ( (This)->lpVtbl -> GetVancSourceLineMapping(This,activeLine1VANCsource,activeLine2VANCsource,activeLine3VANCsource) )
+
+#define IDeckLinkConfiguration_v7_6_SetAudioInputFormat(This,audioInputFormat) \
+ ( (This)->lpVtbl -> SetAudioInputFormat(This,audioInputFormat) )
+
+#define IDeckLinkConfiguration_v7_6_GetAudioInputFormat(This,audioInputFormat) \
+ ( (This)->lpVtbl -> GetAudioInputFormat(This,audioInputFormat) )
+
+#endif /* COBJMACROS */
+
+
+#endif /* C style interface */
+
+
+
+
+#endif /* __IDeckLinkConfiguration_v7_6_INTERFACE_DEFINED__ */
+
+
+#ifndef __IDeckLinkVideoOutputCallback_v7_6_INTERFACE_DEFINED__
+#define __IDeckLinkVideoOutputCallback_v7_6_INTERFACE_DEFINED__
+
+/* interface IDeckLinkVideoOutputCallback_v7_6 */
+/* [helpstring][uuid][object] */
+
+
+EXTERN_C const IID IID_IDeckLinkVideoOutputCallback_v7_6;
+
+#if defined(__cplusplus) && !defined(CINTERFACE)
+
+ MIDL_INTERFACE("E763A626-4A3C-49D1-BF13-E7AD3692AE52")
+ IDeckLinkVideoOutputCallback_v7_6 : public IUnknown
+ {
+ public:
+ virtual HRESULT STDMETHODCALLTYPE ScheduledFrameCompleted(
+ /* [in] */ IDeckLinkVideoFrame_v7_6 *completedFrame,
+ /* [in] */ BMDOutputFrameCompletionResult result) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE ScheduledPlaybackHasStopped( void) = 0;
+
+ };
+
+#else /* C style interface */
+
+ typedef struct IDeckLinkVideoOutputCallback_v7_6Vtbl
+ {
+ BEGIN_INTERFACE
+
+ HRESULT ( STDMETHODCALLTYPE *QueryInterface )(
+ IDeckLinkVideoOutputCallback_v7_6 * This,
+ /* [in] */ REFIID riid,
+ /* [iid_is][out] */
+ __RPC__deref_out void **ppvObject);
+
+ ULONG ( STDMETHODCALLTYPE *AddRef )(
+ IDeckLinkVideoOutputCallback_v7_6 * This);
+
+ ULONG ( STDMETHODCALLTYPE *Release )(
+ IDeckLinkVideoOutputCallback_v7_6 * This);
+
+ HRESULT ( STDMETHODCALLTYPE *ScheduledFrameCompleted )(
+ IDeckLinkVideoOutputCallback_v7_6 * This,
+ /* [in] */ IDeckLinkVideoFrame_v7_6 *completedFrame,
+ /* [in] */ BMDOutputFrameCompletionResult result);
+
+ HRESULT ( STDMETHODCALLTYPE *ScheduledPlaybackHasStopped )(
+ IDeckLinkVideoOutputCallback_v7_6 * This);
+
+ END_INTERFACE
+ } IDeckLinkVideoOutputCallback_v7_6Vtbl;
+
+ interface IDeckLinkVideoOutputCallback_v7_6
+ {
+ CONST_VTBL struct IDeckLinkVideoOutputCallback_v7_6Vtbl *lpVtbl;
+ };
+
+
+
+#ifdef COBJMACROS
+
+
+#define IDeckLinkVideoOutputCallback_v7_6_QueryInterface(This,riid,ppvObject) \
+ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) )
+
+#define IDeckLinkVideoOutputCallback_v7_6_AddRef(This) \
+ ( (This)->lpVtbl -> AddRef(This) )
+
+#define IDeckLinkVideoOutputCallback_v7_6_Release(This) \
+ ( (This)->lpVtbl -> Release(This) )
+
+
+#define IDeckLinkVideoOutputCallback_v7_6_ScheduledFrameCompleted(This,completedFrame,result) \
+ ( (This)->lpVtbl -> ScheduledFrameCompleted(This,completedFrame,result) )
+
+#define IDeckLinkVideoOutputCallback_v7_6_ScheduledPlaybackHasStopped(This) \
+ ( (This)->lpVtbl -> ScheduledPlaybackHasStopped(This) )
+
+#endif /* COBJMACROS */
+
+
+#endif /* C style interface */
+
+
+
+
+#endif /* __IDeckLinkVideoOutputCallback_v7_6_INTERFACE_DEFINED__ */
+
+
+#ifndef __IDeckLinkInputCallback_v7_6_INTERFACE_DEFINED__
+#define __IDeckLinkInputCallback_v7_6_INTERFACE_DEFINED__
+
+/* interface IDeckLinkInputCallback_v7_6 */
+/* [helpstring][uuid][object] */
+
+
+EXTERN_C const IID IID_IDeckLinkInputCallback_v7_6;
+
+#if defined(__cplusplus) && !defined(CINTERFACE)
+
+ MIDL_INTERFACE("31D28EE7-88B6-4CB1-897A-CDBF79A26414")
+ IDeckLinkInputCallback_v7_6 : public IUnknown
+ {
+ public:
+ virtual HRESULT STDMETHODCALLTYPE VideoInputFormatChanged(
+ /* [in] */ BMDVideoInputFormatChangedEvents notificationEvents,
+ /* [in] */ IDeckLinkDisplayMode_v7_6 *newDisplayMode,
+ /* [in] */ BMDDetectedVideoInputFormatFlags detectedSignalFlags) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE VideoInputFrameArrived(
+ /* [in] */ IDeckLinkVideoInputFrame_v7_6 *videoFrame,
+ /* [in] */ IDeckLinkAudioInputPacket *audioPacket) = 0;
+
+ };
+
+#else /* C style interface */
+
+ typedef struct IDeckLinkInputCallback_v7_6Vtbl
+ {
+ BEGIN_INTERFACE
+
+ HRESULT ( STDMETHODCALLTYPE *QueryInterface )(
+ IDeckLinkInputCallback_v7_6 * This,
+ /* [in] */ REFIID riid,
+ /* [iid_is][out] */
+ __RPC__deref_out void **ppvObject);
+
+ ULONG ( STDMETHODCALLTYPE *AddRef )(
+ IDeckLinkInputCallback_v7_6 * This);
+
+ ULONG ( STDMETHODCALLTYPE *Release )(
+ IDeckLinkInputCallback_v7_6 * This);
+
+ HRESULT ( STDMETHODCALLTYPE *VideoInputFormatChanged )(
+ IDeckLinkInputCallback_v7_6 * This,
+ /* [in] */ BMDVideoInputFormatChangedEvents notificationEvents,
+ /* [in] */ IDeckLinkDisplayMode_v7_6 *newDisplayMode,
+ /* [in] */ BMDDetectedVideoInputFormatFlags detectedSignalFlags);
+
+ HRESULT ( STDMETHODCALLTYPE *VideoInputFrameArrived )(
+ IDeckLinkInputCallback_v7_6 * This,
+ /* [in] */ IDeckLinkVideoInputFrame_v7_6 *videoFrame,
+ /* [in] */ IDeckLinkAudioInputPacket *audioPacket);
+
+ END_INTERFACE
+ } IDeckLinkInputCallback_v7_6Vtbl;
+
+ interface IDeckLinkInputCallback_v7_6
+ {
+ CONST_VTBL struct IDeckLinkInputCallback_v7_6Vtbl *lpVtbl;
+ };
+
+
+
+#ifdef COBJMACROS
+
+
+#define IDeckLinkInputCallback_v7_6_QueryInterface(This,riid,ppvObject) \
+ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) )
+
+#define IDeckLinkInputCallback_v7_6_AddRef(This) \
+ ( (This)->lpVtbl -> AddRef(This) )
+
+#define IDeckLinkInputCallback_v7_6_Release(This) \
+ ( (This)->lpVtbl -> Release(This) )
+
+
+#define IDeckLinkInputCallback_v7_6_VideoInputFormatChanged(This,notificationEvents,newDisplayMode,detectedSignalFlags) \
+ ( (This)->lpVtbl -> VideoInputFormatChanged(This,notificationEvents,newDisplayMode,detectedSignalFlags) )
+
+#define IDeckLinkInputCallback_v7_6_VideoInputFrameArrived(This,videoFrame,audioPacket) \
+ ( (This)->lpVtbl -> VideoInputFrameArrived(This,videoFrame,audioPacket) )
+
+#endif /* COBJMACROS */
+
+
+#endif /* C style interface */
+
+
+
+
+#endif /* __IDeckLinkInputCallback_v7_6_INTERFACE_DEFINED__ */
+
+
+EXTERN_C const CLSID CLSID_CDeckLinkGLScreenPreviewHelper_v7_6;
+
+#ifdef __cplusplus
+
+class DECLSPEC_UUID("D398CEE7-4434-4CA3-9BA6-5AE34556B905")
+CDeckLinkGLScreenPreviewHelper_v7_6;
+#endif
+
+EXTERN_C const CLSID CLSID_CDeckLinkVideoConversion_v7_6;
+
+#ifdef __cplusplus
+
+class DECLSPEC_UUID("FFA84F77-73BE-4FB7-B03E-B5E44B9F759B")
+CDeckLinkVideoConversion_v7_6;
+#endif
+
+#ifndef __IDeckLinkInputCallback_v7_3_INTERFACE_DEFINED__
+#define __IDeckLinkInputCallback_v7_3_INTERFACE_DEFINED__
+
+/* interface IDeckLinkInputCallback_v7_3 */
+/* [helpstring][uuid][object] */
+
+
+EXTERN_C const IID IID_IDeckLinkInputCallback_v7_3;
+
+#if defined(__cplusplus) && !defined(CINTERFACE)
+
+ MIDL_INTERFACE("FD6F311D-4D00-444B-9ED4-1F25B5730AD0")
+ IDeckLinkInputCallback_v7_3 : public IUnknown
+ {
+ public:
+ virtual HRESULT STDMETHODCALLTYPE VideoInputFormatChanged(
+ /* [in] */ BMDVideoInputFormatChangedEvents notificationEvents,
+ /* [in] */ IDeckLinkDisplayMode_v7_6 *newDisplayMode,
+ /* [in] */ BMDDetectedVideoInputFormatFlags detectedSignalFlags) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE VideoInputFrameArrived(
+ /* [in] */ IDeckLinkVideoInputFrame_v7_3 *videoFrame,
+ /* [in] */ IDeckLinkAudioInputPacket *audioPacket) = 0;
+
+ };
+
+#else /* C style interface */
+
+ typedef struct IDeckLinkInputCallback_v7_3Vtbl
+ {
+ BEGIN_INTERFACE
+
+ HRESULT ( STDMETHODCALLTYPE *QueryInterface )(
+ IDeckLinkInputCallback_v7_3 * This,
+ /* [in] */ REFIID riid,
+ /* [iid_is][out] */
+ __RPC__deref_out void **ppvObject);
+
+ ULONG ( STDMETHODCALLTYPE *AddRef )(
+ IDeckLinkInputCallback_v7_3 * This);
+
+ ULONG ( STDMETHODCALLTYPE *Release )(
+ IDeckLinkInputCallback_v7_3 * This);
+
+ HRESULT ( STDMETHODCALLTYPE *VideoInputFormatChanged )(
+ IDeckLinkInputCallback_v7_3 * This,
+ /* [in] */ BMDVideoInputFormatChangedEvents notificationEvents,
+ /* [in] */ IDeckLinkDisplayMode_v7_6 *newDisplayMode,
+ /* [in] */ BMDDetectedVideoInputFormatFlags detectedSignalFlags);
+
+ HRESULT ( STDMETHODCALLTYPE *VideoInputFrameArrived )(
+ IDeckLinkInputCallback_v7_3 * This,
+ /* [in] */ IDeckLinkVideoInputFrame_v7_3 *videoFrame,
+ /* [in] */ IDeckLinkAudioInputPacket *audioPacket);
+
+ END_INTERFACE
+ } IDeckLinkInputCallback_v7_3Vtbl;
+
+ interface IDeckLinkInputCallback_v7_3
+ {
+ CONST_VTBL struct IDeckLinkInputCallback_v7_3Vtbl *lpVtbl;
+ };
+
+
+
+#ifdef COBJMACROS
+
+
+#define IDeckLinkInputCallback_v7_3_QueryInterface(This,riid,ppvObject) \
+ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) )
+
+#define IDeckLinkInputCallback_v7_3_AddRef(This) \
+ ( (This)->lpVtbl -> AddRef(This) )
+
+#define IDeckLinkInputCallback_v7_3_Release(This) \
+ ( (This)->lpVtbl -> Release(This) )
+
+
+#define IDeckLinkInputCallback_v7_3_VideoInputFormatChanged(This,notificationEvents,newDisplayMode,detectedSignalFlags) \
+ ( (This)->lpVtbl -> VideoInputFormatChanged(This,notificationEvents,newDisplayMode,detectedSignalFlags) )
+
+#define IDeckLinkInputCallback_v7_3_VideoInputFrameArrived(This,videoFrame,audioPacket) \
+ ( (This)->lpVtbl -> VideoInputFrameArrived(This,videoFrame,audioPacket) )
+
+#endif /* COBJMACROS */
+
+
+#endif /* C style interface */
+
+
+
+
+#endif /* __IDeckLinkInputCallback_v7_3_INTERFACE_DEFINED__ */
+
+
+#ifndef __IDeckLinkOutput_v7_3_INTERFACE_DEFINED__
+#define __IDeckLinkOutput_v7_3_INTERFACE_DEFINED__
+
+/* interface IDeckLinkOutput_v7_3 */
+/* [helpstring][local][uuid][object] */
+
+
+EXTERN_C const IID IID_IDeckLinkOutput_v7_3;
+
+#if defined(__cplusplus) && !defined(CINTERFACE)
+
+ MIDL_INTERFACE("271C65E3-C323-4344-A30F-D908BCB20AA3")
+ IDeckLinkOutput_v7_3 : public IUnknown
+ {
+ public:
+ virtual HRESULT STDMETHODCALLTYPE DoesSupportVideoMode(
+ BMDDisplayMode displayMode,
+ BMDPixelFormat pixelFormat,
+ /* [out] */ BMDDisplayModeSupport *result) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE GetDisplayModeIterator(
+ /* [out] */ IDeckLinkDisplayModeIterator_v7_6 **iterator) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE SetScreenPreviewCallback(
+ /* [in] */ IDeckLinkScreenPreviewCallback *previewCallback) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE EnableVideoOutput(
+ BMDDisplayMode displayMode,
+ BMDVideoOutputFlags flags) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE DisableVideoOutput( void) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE SetVideoOutputFrameMemoryAllocator(
+ /* [in] */ IDeckLinkMemoryAllocator *theAllocator) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE CreateVideoFrame(
+ long width,
+ long height,
+ long rowBytes,
+ BMDPixelFormat pixelFormat,
+ BMDFrameFlags flags,
+ /* [out] */ IDeckLinkMutableVideoFrame_v7_6 **outFrame) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE CreateAncillaryData(
+ BMDPixelFormat pixelFormat,
+ /* [out] */ IDeckLinkVideoFrameAncillary **outBuffer) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE DisplayVideoFrameSync(
+ /* [in] */ IDeckLinkVideoFrame_v7_6 *theFrame) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE ScheduleVideoFrame(
+ /* [in] */ IDeckLinkVideoFrame_v7_6 *theFrame,
+ BMDTimeValue displayTime,
+ BMDTimeValue displayDuration,
+ BMDTimeScale timeScale) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE SetScheduledFrameCompletionCallback(
+ /* [in] */ IDeckLinkVideoOutputCallback *theCallback) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE GetBufferedVideoFrameCount(
+ /* [out] */ unsigned long *bufferedFrameCount) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE EnableAudioOutput(
+ BMDAudioSampleRate sampleRate,
+ BMDAudioSampleType sampleType,
+ unsigned long channelCount,
+ BMDAudioOutputStreamType streamType) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE DisableAudioOutput( void) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE WriteAudioSamplesSync(
+ /* [in] */ void *buffer,
+ unsigned long sampleFrameCount,
+ /* [out] */ unsigned long *sampleFramesWritten) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE BeginAudioPreroll( void) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE EndAudioPreroll( void) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE ScheduleAudioSamples(
+ /* [in] */ void *buffer,
+ unsigned long sampleFrameCount,
+ BMDTimeValue streamTime,
+ BMDTimeScale timeScale,
+ /* [out] */ unsigned long *sampleFramesWritten) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE GetBufferedAudioSampleFrameCount(
+ /* [out] */ unsigned long *bufferedSampleFrameCount) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE FlushBufferedAudioSamples( void) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE SetAudioCallback(
+ /* [in] */ IDeckLinkAudioOutputCallback *theCallback) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE StartScheduledPlayback(
+ BMDTimeValue playbackStartTime,
+ BMDTimeScale timeScale,
+ double playbackSpeed) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE StopScheduledPlayback(
+ BMDTimeValue stopPlaybackAtTime,
+ /* [out] */ BMDTimeValue *actualStopTime,
+ BMDTimeScale timeScale) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE IsScheduledPlaybackRunning(
+ /* [out] */ BOOL *active) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE GetHardwareReferenceClock(
+ BMDTimeScale desiredTimeScale,
+ /* [out] */ BMDTimeValue *elapsedTimeSinceSchedulerBegan) = 0;
+
+ };
+
+#else /* C style interface */
+
+ typedef struct IDeckLinkOutput_v7_3Vtbl
+ {
+ BEGIN_INTERFACE
+
+ HRESULT ( STDMETHODCALLTYPE *QueryInterface )(
+ IDeckLinkOutput_v7_3 * This,
+ /* [in] */ REFIID riid,
+ /* [iid_is][out] */
+ __RPC__deref_out void **ppvObject);
+
+ ULONG ( STDMETHODCALLTYPE *AddRef )(
+ IDeckLinkOutput_v7_3 * This);
+
+ ULONG ( STDMETHODCALLTYPE *Release )(
+ IDeckLinkOutput_v7_3 * This);
+
+ HRESULT ( STDMETHODCALLTYPE *DoesSupportVideoMode )(
+ IDeckLinkOutput_v7_3 * This,
+ BMDDisplayMode displayMode,
+ BMDPixelFormat pixelFormat,
+ /* [out] */ BMDDisplayModeSupport *result);
+
+ HRESULT ( STDMETHODCALLTYPE *GetDisplayModeIterator )(
+ IDeckLinkOutput_v7_3 * This,
+ /* [out] */ IDeckLinkDisplayModeIterator_v7_6 **iterator);
+
+ HRESULT ( STDMETHODCALLTYPE *SetScreenPreviewCallback )(
+ IDeckLinkOutput_v7_3 * This,
+ /* [in] */ IDeckLinkScreenPreviewCallback *previewCallback);
+
+ HRESULT ( STDMETHODCALLTYPE *EnableVideoOutput )(
+ IDeckLinkOutput_v7_3 * This,
+ BMDDisplayMode displayMode,
+ BMDVideoOutputFlags flags);
+
+ HRESULT ( STDMETHODCALLTYPE *DisableVideoOutput )(
+ IDeckLinkOutput_v7_3 * This);
+
+ HRESULT ( STDMETHODCALLTYPE *SetVideoOutputFrameMemoryAllocator )(
+ IDeckLinkOutput_v7_3 * This,
+ /* [in] */ IDeckLinkMemoryAllocator *theAllocator);
+
+ HRESULT ( STDMETHODCALLTYPE *CreateVideoFrame )(
+ IDeckLinkOutput_v7_3 * This,
+ long width,
+ long height,
+ long rowBytes,
+ BMDPixelFormat pixelFormat,
+ BMDFrameFlags flags,
+ /* [out] */ IDeckLinkMutableVideoFrame_v7_6 **outFrame);
+
+ HRESULT ( STDMETHODCALLTYPE *CreateAncillaryData )(
+ IDeckLinkOutput_v7_3 * This,
+ BMDPixelFormat pixelFormat,
+ /* [out] */ IDeckLinkVideoFrameAncillary **outBuffer);
+
+ HRESULT ( STDMETHODCALLTYPE *DisplayVideoFrameSync )(
+ IDeckLinkOutput_v7_3 * This,
+ /* [in] */ IDeckLinkVideoFrame_v7_6 *theFrame);
+
+ HRESULT ( STDMETHODCALLTYPE *ScheduleVideoFrame )(
+ IDeckLinkOutput_v7_3 * This,
+ /* [in] */ IDeckLinkVideoFrame_v7_6 *theFrame,
+ BMDTimeValue displayTime,
+ BMDTimeValue displayDuration,
+ BMDTimeScale timeScale);
+
+ HRESULT ( STDMETHODCALLTYPE *SetScheduledFrameCompletionCallback )(
+ IDeckLinkOutput_v7_3 * This,
+ /* [in] */ IDeckLinkVideoOutputCallback *theCallback);
+
+ HRESULT ( STDMETHODCALLTYPE *GetBufferedVideoFrameCount )(
+ IDeckLinkOutput_v7_3 * This,
+ /* [out] */ unsigned long *bufferedFrameCount);
+
+ HRESULT ( STDMETHODCALLTYPE *EnableAudioOutput )(
+ IDeckLinkOutput_v7_3 * This,
+ BMDAudioSampleRate sampleRate,
+ BMDAudioSampleType sampleType,
+ unsigned long channelCount,
+ BMDAudioOutputStreamType streamType);
+
+ HRESULT ( STDMETHODCALLTYPE *DisableAudioOutput )(
+ IDeckLinkOutput_v7_3 * This);
+
+ HRESULT ( STDMETHODCALLTYPE *WriteAudioSamplesSync )(
+ IDeckLinkOutput_v7_3 * This,
+ /* [in] */ void *buffer,
+ unsigned long sampleFrameCount,
+ /* [out] */ unsigned long *sampleFramesWritten);
+
+ HRESULT ( STDMETHODCALLTYPE *BeginAudioPreroll )(
+ IDeckLinkOutput_v7_3 * This);
+
+ HRESULT ( STDMETHODCALLTYPE *EndAudioPreroll )(
+ IDeckLinkOutput_v7_3 * This);
+
+ HRESULT ( STDMETHODCALLTYPE *ScheduleAudioSamples )(
+ IDeckLinkOutput_v7_3 * This,
+ /* [in] */ void *buffer,
+ unsigned long sampleFrameCount,
+ BMDTimeValue streamTime,
+ BMDTimeScale timeScale,
+ /* [out] */ unsigned long *sampleFramesWritten);
+
+ HRESULT ( STDMETHODCALLTYPE *GetBufferedAudioSampleFrameCount )(
+ IDeckLinkOutput_v7_3 * This,
+ /* [out] */ unsigned long *bufferedSampleFrameCount);
+
+ HRESULT ( STDMETHODCALLTYPE *FlushBufferedAudioSamples )(
+ IDeckLinkOutput_v7_3 * This);
+
+ HRESULT ( STDMETHODCALLTYPE *SetAudioCallback )(
+ IDeckLinkOutput_v7_3 * This,
+ /* [in] */ IDeckLinkAudioOutputCallback *theCallback);
+
+ HRESULT ( STDMETHODCALLTYPE *StartScheduledPlayback )(
+ IDeckLinkOutput_v7_3 * This,
+ BMDTimeValue playbackStartTime,
+ BMDTimeScale timeScale,
+ double playbackSpeed);
+
+ HRESULT ( STDMETHODCALLTYPE *StopScheduledPlayback )(
+ IDeckLinkOutput_v7_3 * This,
+ BMDTimeValue stopPlaybackAtTime,
+ /* [out] */ BMDTimeValue *actualStopTime,
+ BMDTimeScale timeScale);
+
+ HRESULT ( STDMETHODCALLTYPE *IsScheduledPlaybackRunning )(
+ IDeckLinkOutput_v7_3 * This,
+ /* [out] */ BOOL *active);
+
+ HRESULT ( STDMETHODCALLTYPE *GetHardwareReferenceClock )(
+ IDeckLinkOutput_v7_3 * This,
+ BMDTimeScale desiredTimeScale,
+ /* [out] */ BMDTimeValue *elapsedTimeSinceSchedulerBegan);
+
+ END_INTERFACE
+ } IDeckLinkOutput_v7_3Vtbl;
+
+ interface IDeckLinkOutput_v7_3
+ {
+ CONST_VTBL struct IDeckLinkOutput_v7_3Vtbl *lpVtbl;
+ };
+
+
+
+#ifdef COBJMACROS
+
+
+#define IDeckLinkOutput_v7_3_QueryInterface(This,riid,ppvObject) \
+ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) )
+
+#define IDeckLinkOutput_v7_3_AddRef(This) \
+ ( (This)->lpVtbl -> AddRef(This) )
+
+#define IDeckLinkOutput_v7_3_Release(This) \
+ ( (This)->lpVtbl -> Release(This) )
+
+
+#define IDeckLinkOutput_v7_3_DoesSupportVideoMode(This,displayMode,pixelFormat,result) \
+ ( (This)->lpVtbl -> DoesSupportVideoMode(This,displayMode,pixelFormat,result) )
+
+#define IDeckLinkOutput_v7_3_GetDisplayModeIterator(This,iterator) \
+ ( (This)->lpVtbl -> GetDisplayModeIterator(This,iterator) )
+
+#define IDeckLinkOutput_v7_3_SetScreenPreviewCallback(This,previewCallback) \
+ ( (This)->lpVtbl -> SetScreenPreviewCallback(This,previewCallback) )
+
+#define IDeckLinkOutput_v7_3_EnableVideoOutput(This,displayMode,flags) \
+ ( (This)->lpVtbl -> EnableVideoOutput(This,displayMode,flags) )
+
+#define IDeckLinkOutput_v7_3_DisableVideoOutput(This) \
+ ( (This)->lpVtbl -> DisableVideoOutput(This) )
+
+#define IDeckLinkOutput_v7_3_SetVideoOutputFrameMemoryAllocator(This,theAllocator) \
+ ( (This)->lpVtbl -> SetVideoOutputFrameMemoryAllocator(This,theAllocator) )
+
+#define IDeckLinkOutput_v7_3_CreateVideoFrame(This,width,height,rowBytes,pixelFormat,flags,outFrame) \
+ ( (This)->lpVtbl -> CreateVideoFrame(This,width,height,rowBytes,pixelFormat,flags,outFrame) )
+
+#define IDeckLinkOutput_v7_3_CreateAncillaryData(This,pixelFormat,outBuffer) \
+ ( (This)->lpVtbl -> CreateAncillaryData(This,pixelFormat,outBuffer) )
+
+#define IDeckLinkOutput_v7_3_DisplayVideoFrameSync(This,theFrame) \
+ ( (This)->lpVtbl -> DisplayVideoFrameSync(This,theFrame) )
+
+#define IDeckLinkOutput_v7_3_ScheduleVideoFrame(This,theFrame,displayTime,displayDuration,timeScale) \
+ ( (This)->lpVtbl -> ScheduleVideoFrame(This,theFrame,displayTime,displayDuration,timeScale) )
+
+#define IDeckLinkOutput_v7_3_SetScheduledFrameCompletionCallback(This,theCallback) \
+ ( (This)->lpVtbl -> SetScheduledFrameCompletionCallback(This,theCallback) )
+
+#define IDeckLinkOutput_v7_3_GetBufferedVideoFrameCount(This,bufferedFrameCount) \
+ ( (This)->lpVtbl -> GetBufferedVideoFrameCount(This,bufferedFrameCount) )
+
+#define IDeckLinkOutput_v7_3_EnableAudioOutput(This,sampleRate,sampleType,channelCount,streamType) \
+ ( (This)->lpVtbl -> EnableAudioOutput(This,sampleRate,sampleType,channelCount,streamType) )
+
+#define IDeckLinkOutput_v7_3_DisableAudioOutput(This) \
+ ( (This)->lpVtbl -> DisableAudioOutput(This) )
+
+#define IDeckLinkOutput_v7_3_WriteAudioSamplesSync(This,buffer,sampleFrameCount,sampleFramesWritten) \
+ ( (This)->lpVtbl -> WriteAudioSamplesSync(This,buffer,sampleFrameCount,sampleFramesWritten) )
+
+#define IDeckLinkOutput_v7_3_BeginAudioPreroll(This) \
+ ( (This)->lpVtbl -> BeginAudioPreroll(This) )
+
+#define IDeckLinkOutput_v7_3_EndAudioPreroll(This) \
+ ( (This)->lpVtbl -> EndAudioPreroll(This) )
+
+#define IDeckLinkOutput_v7_3_ScheduleAudioSamples(This,buffer,sampleFrameCount,streamTime,timeScale,sampleFramesWritten) \
+ ( (This)->lpVtbl -> ScheduleAudioSamples(This,buffer,sampleFrameCount,streamTime,timeScale,sampleFramesWritten) )
+
+#define IDeckLinkOutput_v7_3_GetBufferedAudioSampleFrameCount(This,bufferedSampleFrameCount) \
+ ( (This)->lpVtbl -> GetBufferedAudioSampleFrameCount(This,bufferedSampleFrameCount) )
+
+#define IDeckLinkOutput_v7_3_FlushBufferedAudioSamples(This) \
+ ( (This)->lpVtbl -> FlushBufferedAudioSamples(This) )
+
+#define IDeckLinkOutput_v7_3_SetAudioCallback(This,theCallback) \
+ ( (This)->lpVtbl -> SetAudioCallback(This,theCallback) )
+
+#define IDeckLinkOutput_v7_3_StartScheduledPlayback(This,playbackStartTime,timeScale,playbackSpeed) \
+ ( (This)->lpVtbl -> StartScheduledPlayback(This,playbackStartTime,timeScale,playbackSpeed) )
+
+#define IDeckLinkOutput_v7_3_StopScheduledPlayback(This,stopPlaybackAtTime,actualStopTime,timeScale) \
+ ( (This)->lpVtbl -> StopScheduledPlayback(This,stopPlaybackAtTime,actualStopTime,timeScale) )
+
+#define IDeckLinkOutput_v7_3_IsScheduledPlaybackRunning(This,active) \
+ ( (This)->lpVtbl -> IsScheduledPlaybackRunning(This,active) )
+
+#define IDeckLinkOutput_v7_3_GetHardwareReferenceClock(This,desiredTimeScale,elapsedTimeSinceSchedulerBegan) \
+ ( (This)->lpVtbl -> GetHardwareReferenceClock(This,desiredTimeScale,elapsedTimeSinceSchedulerBegan) )
+
+#endif /* COBJMACROS */
+
+
+#endif /* C style interface */
+
+
+
+
+#endif /* __IDeckLinkOutput_v7_3_INTERFACE_DEFINED__ */
+
+
+#ifndef __IDeckLinkInput_v7_3_INTERFACE_DEFINED__
+#define __IDeckLinkInput_v7_3_INTERFACE_DEFINED__
+
+/* interface IDeckLinkInput_v7_3 */
+/* [helpstring][uuid][object] */
+
+
+EXTERN_C const IID IID_IDeckLinkInput_v7_3;
+
+#if defined(__cplusplus) && !defined(CINTERFACE)
+
+ MIDL_INTERFACE("4973F012-9925-458C-871C-18774CDBBECB")
+ IDeckLinkInput_v7_3 : public IUnknown
+ {
+ public:
+ virtual HRESULT STDMETHODCALLTYPE DoesSupportVideoMode(
+ BMDDisplayMode displayMode,
+ BMDPixelFormat pixelFormat,
+ /* [out] */ BMDDisplayModeSupport *result) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE GetDisplayModeIterator(
+ /* [out] */ IDeckLinkDisplayModeIterator_v7_6 **iterator) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE SetScreenPreviewCallback(
+ /* [in] */ IDeckLinkScreenPreviewCallback *previewCallback) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE EnableVideoInput(
+ BMDDisplayMode displayMode,
+ BMDPixelFormat pixelFormat,
+ BMDVideoInputFlags flags) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE DisableVideoInput( void) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE GetAvailableVideoFrameCount(
+ /* [out] */ unsigned long *availableFrameCount) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE EnableAudioInput(
+ BMDAudioSampleRate sampleRate,
+ BMDAudioSampleType sampleType,
+ unsigned long channelCount) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE DisableAudioInput( void) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE GetAvailableAudioSampleFrameCount(
+ /* [out] */ unsigned long *availableSampleFrameCount) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE StartStreams( void) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE StopStreams( void) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE PauseStreams( void) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE FlushStreams( void) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE SetCallback(
+ /* [in] */ IDeckLinkInputCallback_v7_3 *theCallback) = 0;
+
+ };
+
+#else /* C style interface */
+
+ typedef struct IDeckLinkInput_v7_3Vtbl
+ {
+ BEGIN_INTERFACE
+
+ HRESULT ( STDMETHODCALLTYPE *QueryInterface )(
+ IDeckLinkInput_v7_3 * This,
+ /* [in] */ REFIID riid,
+ /* [iid_is][out] */
+ __RPC__deref_out void **ppvObject);
+
+ ULONG ( STDMETHODCALLTYPE *AddRef )(
+ IDeckLinkInput_v7_3 * This);
+
+ ULONG ( STDMETHODCALLTYPE *Release )(
+ IDeckLinkInput_v7_3 * This);
+
+ HRESULT ( STDMETHODCALLTYPE *DoesSupportVideoMode )(
+ IDeckLinkInput_v7_3 * This,
+ BMDDisplayMode displayMode,
+ BMDPixelFormat pixelFormat,
+ /* [out] */ BMDDisplayModeSupport *result);
+
+ HRESULT ( STDMETHODCALLTYPE *GetDisplayModeIterator )(
+ IDeckLinkInput_v7_3 * This,
+ /* [out] */ IDeckLinkDisplayModeIterator_v7_6 **iterator);
+
+ HRESULT ( STDMETHODCALLTYPE *SetScreenPreviewCallback )(
+ IDeckLinkInput_v7_3 * This,
+ /* [in] */ IDeckLinkScreenPreviewCallback *previewCallback);
+
+ HRESULT ( STDMETHODCALLTYPE *EnableVideoInput )(
+ IDeckLinkInput_v7_3 * This,
+ BMDDisplayMode displayMode,
+ BMDPixelFormat pixelFormat,
+ BMDVideoInputFlags flags);
+
+ HRESULT ( STDMETHODCALLTYPE *DisableVideoInput )(
+ IDeckLinkInput_v7_3 * This);
+
+ HRESULT ( STDMETHODCALLTYPE *GetAvailableVideoFrameCount )(
+ IDeckLinkInput_v7_3 * This,
+ /* [out] */ unsigned long *availableFrameCount);
+
+ HRESULT ( STDMETHODCALLTYPE *EnableAudioInput )(
+ IDeckLinkInput_v7_3 * This,
+ BMDAudioSampleRate sampleRate,
+ BMDAudioSampleType sampleType,
+ unsigned long channelCount);
+
+ HRESULT ( STDMETHODCALLTYPE *DisableAudioInput )(
+ IDeckLinkInput_v7_3 * This);
+
+ HRESULT ( STDMETHODCALLTYPE *GetAvailableAudioSampleFrameCount )(
+ IDeckLinkInput_v7_3 * This,
+ /* [out] */ unsigned long *availableSampleFrameCount);
+
+ HRESULT ( STDMETHODCALLTYPE *StartStreams )(
+ IDeckLinkInput_v7_3 * This);
+
+ HRESULT ( STDMETHODCALLTYPE *StopStreams )(
+ IDeckLinkInput_v7_3 * This);
+
+ HRESULT ( STDMETHODCALLTYPE *PauseStreams )(
+ IDeckLinkInput_v7_3 * This);
+
+ HRESULT ( STDMETHODCALLTYPE *FlushStreams )(
+ IDeckLinkInput_v7_3 * This);
+
+ HRESULT ( STDMETHODCALLTYPE *SetCallback )(
+ IDeckLinkInput_v7_3 * This,
+ /* [in] */ IDeckLinkInputCallback_v7_3 *theCallback);
+
+ END_INTERFACE
+ } IDeckLinkInput_v7_3Vtbl;
+
+ interface IDeckLinkInput_v7_3
+ {
+ CONST_VTBL struct IDeckLinkInput_v7_3Vtbl *lpVtbl;
+ };
+
+
+
+#ifdef COBJMACROS
+
+
+#define IDeckLinkInput_v7_3_QueryInterface(This,riid,ppvObject) \
+ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) )
+
+#define IDeckLinkInput_v7_3_AddRef(This) \
+ ( (This)->lpVtbl -> AddRef(This) )
+
+#define IDeckLinkInput_v7_3_Release(This) \
+ ( (This)->lpVtbl -> Release(This) )
+
+
+#define IDeckLinkInput_v7_3_DoesSupportVideoMode(This,displayMode,pixelFormat,result) \
+ ( (This)->lpVtbl -> DoesSupportVideoMode(This,displayMode,pixelFormat,result) )
+
+#define IDeckLinkInput_v7_3_GetDisplayModeIterator(This,iterator) \
+ ( (This)->lpVtbl -> GetDisplayModeIterator(This,iterator) )
+
+#define IDeckLinkInput_v7_3_SetScreenPreviewCallback(This,previewCallback) \
+ ( (This)->lpVtbl -> SetScreenPreviewCallback(This,previewCallback) )
+
+#define IDeckLinkInput_v7_3_EnableVideoInput(This,displayMode,pixelFormat,flags) \
+ ( (This)->lpVtbl -> EnableVideoInput(This,displayMode,pixelFormat,flags) )
+
+#define IDeckLinkInput_v7_3_DisableVideoInput(This) \
+ ( (This)->lpVtbl -> DisableVideoInput(This) )
+
+#define IDeckLinkInput_v7_3_GetAvailableVideoFrameCount(This,availableFrameCount) \
+ ( (This)->lpVtbl -> GetAvailableVideoFrameCount(This,availableFrameCount) )
+
+#define IDeckLinkInput_v7_3_EnableAudioInput(This,sampleRate,sampleType,channelCount) \
+ ( (This)->lpVtbl -> EnableAudioInput(This,sampleRate,sampleType,channelCount) )
+
+#define IDeckLinkInput_v7_3_DisableAudioInput(This) \
+ ( (This)->lpVtbl -> DisableAudioInput(This) )
+
+#define IDeckLinkInput_v7_3_GetAvailableAudioSampleFrameCount(This,availableSampleFrameCount) \
+ ( (This)->lpVtbl -> GetAvailableAudioSampleFrameCount(This,availableSampleFrameCount) )
+
+#define IDeckLinkInput_v7_3_StartStreams(This) \
+ ( (This)->lpVtbl -> StartStreams(This) )
+
+#define IDeckLinkInput_v7_3_StopStreams(This) \
+ ( (This)->lpVtbl -> StopStreams(This) )
+
+#define IDeckLinkInput_v7_3_PauseStreams(This) \
+ ( (This)->lpVtbl -> PauseStreams(This) )
+
+#define IDeckLinkInput_v7_3_FlushStreams(This) \
+ ( (This)->lpVtbl -> FlushStreams(This) )
+
+#define IDeckLinkInput_v7_3_SetCallback(This,theCallback) \
+ ( (This)->lpVtbl -> SetCallback(This,theCallback) )
+
+#endif /* COBJMACROS */
+
+
+#endif /* C style interface */
+
+
+
+
+#endif /* __IDeckLinkInput_v7_3_INTERFACE_DEFINED__ */
+
+
+#ifndef __IDeckLinkVideoInputFrame_v7_3_INTERFACE_DEFINED__
+#define __IDeckLinkVideoInputFrame_v7_3_INTERFACE_DEFINED__
+
+/* interface IDeckLinkVideoInputFrame_v7_3 */
+/* [helpstring][local][uuid][object] */
+
+
+EXTERN_C const IID IID_IDeckLinkVideoInputFrame_v7_3;
+
+#if defined(__cplusplus) && !defined(CINTERFACE)
+
+ MIDL_INTERFACE("CF317790-2894-11DE-8C30-0800200C9A66")
+ IDeckLinkVideoInputFrame_v7_3 : public IDeckLinkVideoFrame_v7_6
+ {
+ public:
+ virtual HRESULT STDMETHODCALLTYPE GetStreamTime(
+ /* [out] */ BMDTimeValue *frameTime,
+ /* [out] */ BMDTimeValue *frameDuration,
+ BMDTimeScale timeScale) = 0;
+
+ };
+
+#else /* C style interface */
+
+ typedef struct IDeckLinkVideoInputFrame_v7_3Vtbl
+ {
+ BEGIN_INTERFACE
+
+ HRESULT ( STDMETHODCALLTYPE *QueryInterface )(
+ IDeckLinkVideoInputFrame_v7_3 * This,
+ /* [in] */ REFIID riid,
+ /* [iid_is][out] */
+ __RPC__deref_out void **ppvObject);
+
+ ULONG ( STDMETHODCALLTYPE *AddRef )(
+ IDeckLinkVideoInputFrame_v7_3 * This);
+
+ ULONG ( STDMETHODCALLTYPE *Release )(
+ IDeckLinkVideoInputFrame_v7_3 * This);
+
+ long ( STDMETHODCALLTYPE *GetWidth )(
+ IDeckLinkVideoInputFrame_v7_3 * This);
+
+ long ( STDMETHODCALLTYPE *GetHeight )(
+ IDeckLinkVideoInputFrame_v7_3 * This);
+
+ long ( STDMETHODCALLTYPE *GetRowBytes )(
+ IDeckLinkVideoInputFrame_v7_3 * This);
+
+ BMDPixelFormat ( STDMETHODCALLTYPE *GetPixelFormat )(
+ IDeckLinkVideoInputFrame_v7_3 * This);
+
+ BMDFrameFlags ( STDMETHODCALLTYPE *GetFlags )(
+ IDeckLinkVideoInputFrame_v7_3 * This);
+
+ HRESULT ( STDMETHODCALLTYPE *GetBytes )(
+ IDeckLinkVideoInputFrame_v7_3 * This,
+ /* [out] */ void **buffer);
+
+ HRESULT ( STDMETHODCALLTYPE *GetTimecode )(
+ IDeckLinkVideoInputFrame_v7_3 * This,
+ BMDTimecodeFormat format,
+ /* [out] */ IDeckLinkTimecode_v7_6 **timecode);
+
+ HRESULT ( STDMETHODCALLTYPE *GetAncillaryData )(
+ IDeckLinkVideoInputFrame_v7_3 * This,
+ /* [out] */ IDeckLinkVideoFrameAncillary **ancillary);
+
+ HRESULT ( STDMETHODCALLTYPE *GetStreamTime )(
+ IDeckLinkVideoInputFrame_v7_3 * This,
+ /* [out] */ BMDTimeValue *frameTime,
+ /* [out] */ BMDTimeValue *frameDuration,
+ BMDTimeScale timeScale);
+
+ END_INTERFACE
+ } IDeckLinkVideoInputFrame_v7_3Vtbl;
+
+ interface IDeckLinkVideoInputFrame_v7_3
+ {
+ CONST_VTBL struct IDeckLinkVideoInputFrame_v7_3Vtbl *lpVtbl;
+ };
+
+
+
+#ifdef COBJMACROS
+
+
+#define IDeckLinkVideoInputFrame_v7_3_QueryInterface(This,riid,ppvObject) \
+ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) )
+
+#define IDeckLinkVideoInputFrame_v7_3_AddRef(This) \
+ ( (This)->lpVtbl -> AddRef(This) )
+
+#define IDeckLinkVideoInputFrame_v7_3_Release(This) \
+ ( (This)->lpVtbl -> Release(This) )
+
+
+#define IDeckLinkVideoInputFrame_v7_3_GetWidth(This) \
+ ( (This)->lpVtbl -> GetWidth(This) )
+
+#define IDeckLinkVideoInputFrame_v7_3_GetHeight(This) \
+ ( (This)->lpVtbl -> GetHeight(This) )
+
+#define IDeckLinkVideoInputFrame_v7_3_GetRowBytes(This) \
+ ( (This)->lpVtbl -> GetRowBytes(This) )
+
+#define IDeckLinkVideoInputFrame_v7_3_GetPixelFormat(This) \
+ ( (This)->lpVtbl -> GetPixelFormat(This) )
+
+#define IDeckLinkVideoInputFrame_v7_3_GetFlags(This) \
+ ( (This)->lpVtbl -> GetFlags(This) )
+
+#define IDeckLinkVideoInputFrame_v7_3_GetBytes(This,buffer) \
+ ( (This)->lpVtbl -> GetBytes(This,buffer) )
+
+#define IDeckLinkVideoInputFrame_v7_3_GetTimecode(This,format,timecode) \
+ ( (This)->lpVtbl -> GetTimecode(This,format,timecode) )
+
+#define IDeckLinkVideoInputFrame_v7_3_GetAncillaryData(This,ancillary) \
+ ( (This)->lpVtbl -> GetAncillaryData(This,ancillary) )
+
+
+#define IDeckLinkVideoInputFrame_v7_3_GetStreamTime(This,frameTime,frameDuration,timeScale) \
+ ( (This)->lpVtbl -> GetStreamTime(This,frameTime,frameDuration,timeScale) )
+
+#endif /* COBJMACROS */
+
+
+#endif /* C style interface */
+
+
+
+
+#endif /* __IDeckLinkVideoInputFrame_v7_3_INTERFACE_DEFINED__ */
+
+
+#ifndef __IDeckLinkDisplayModeIterator_v7_1_INTERFACE_DEFINED__
+#define __IDeckLinkDisplayModeIterator_v7_1_INTERFACE_DEFINED__
+
+/* interface IDeckLinkDisplayModeIterator_v7_1 */
+/* [helpstring][uuid][object] */
+
+
+EXTERN_C const IID IID_IDeckLinkDisplayModeIterator_v7_1;
+
+#if defined(__cplusplus) && !defined(CINTERFACE)
+
+ MIDL_INTERFACE("B28131B6-59AC-4857-B5AC-CD75D5883E2F")
+ IDeckLinkDisplayModeIterator_v7_1 : public IUnknown
+ {
+ public:
+ virtual HRESULT STDMETHODCALLTYPE Next(
+ /* [out] */ IDeckLinkDisplayMode_v7_1 **deckLinkDisplayMode) = 0;
+
+ };
+
+#else /* C style interface */
+
+ typedef struct IDeckLinkDisplayModeIterator_v7_1Vtbl
+ {
+ BEGIN_INTERFACE
+
+ HRESULT ( STDMETHODCALLTYPE *QueryInterface )(
+ IDeckLinkDisplayModeIterator_v7_1 * This,
+ /* [in] */ REFIID riid,
+ /* [iid_is][out] */
+ __RPC__deref_out void **ppvObject);
+
+ ULONG ( STDMETHODCALLTYPE *AddRef )(
+ IDeckLinkDisplayModeIterator_v7_1 * This);
+
+ ULONG ( STDMETHODCALLTYPE *Release )(
+ IDeckLinkDisplayModeIterator_v7_1 * This);
+
+ HRESULT ( STDMETHODCALLTYPE *Next )(
+ IDeckLinkDisplayModeIterator_v7_1 * This,
+ /* [out] */ IDeckLinkDisplayMode_v7_1 **deckLinkDisplayMode);
+
+ END_INTERFACE
+ } IDeckLinkDisplayModeIterator_v7_1Vtbl;
+
+ interface IDeckLinkDisplayModeIterator_v7_1
+ {
+ CONST_VTBL struct IDeckLinkDisplayModeIterator_v7_1Vtbl *lpVtbl;
+ };
+
+
+
+#ifdef COBJMACROS
+
+
+#define IDeckLinkDisplayModeIterator_v7_1_QueryInterface(This,riid,ppvObject) \
+ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) )
+
+#define IDeckLinkDisplayModeIterator_v7_1_AddRef(This) \
+ ( (This)->lpVtbl -> AddRef(This) )
+
+#define IDeckLinkDisplayModeIterator_v7_1_Release(This) \
+ ( (This)->lpVtbl -> Release(This) )
+
+
+#define IDeckLinkDisplayModeIterator_v7_1_Next(This,deckLinkDisplayMode) \
+ ( (This)->lpVtbl -> Next(This,deckLinkDisplayMode) )
+
+#endif /* COBJMACROS */
+
+
+#endif /* C style interface */
+
+
+
+
+#endif /* __IDeckLinkDisplayModeIterator_v7_1_INTERFACE_DEFINED__ */
+
+
+#ifndef __IDeckLinkDisplayMode_v7_1_INTERFACE_DEFINED__
+#define __IDeckLinkDisplayMode_v7_1_INTERFACE_DEFINED__
+
+/* interface IDeckLinkDisplayMode_v7_1 */
+/* [helpstring][uuid][object] */
+
+
+EXTERN_C const IID IID_IDeckLinkDisplayMode_v7_1;
+
+#if defined(__cplusplus) && !defined(CINTERFACE)
+
+ MIDL_INTERFACE("AF0CD6D5-8376-435E-8433-54F9DD530AC3")
+ IDeckLinkDisplayMode_v7_1 : public IUnknown
+ {
+ public:
+ virtual HRESULT STDMETHODCALLTYPE GetName(
+ /* [out] */ BSTR *name) = 0;
+
+ virtual BMDDisplayMode STDMETHODCALLTYPE GetDisplayMode( void) = 0;
+
+ virtual long STDMETHODCALLTYPE GetWidth( void) = 0;
+
+ virtual long STDMETHODCALLTYPE GetHeight( void) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE GetFrameRate(
+ /* [out] */ BMDTimeValue *frameDuration,
+ /* [out] */ BMDTimeScale *timeScale) = 0;
+
+ };
+
+#else /* C style interface */
+
+ typedef struct IDeckLinkDisplayMode_v7_1Vtbl
+ {
+ BEGIN_INTERFACE
+
+ HRESULT ( STDMETHODCALLTYPE *QueryInterface )(
+ IDeckLinkDisplayMode_v7_1 * This,
+ /* [in] */ REFIID riid,
+ /* [iid_is][out] */
+ __RPC__deref_out void **ppvObject);
+
+ ULONG ( STDMETHODCALLTYPE *AddRef )(
+ IDeckLinkDisplayMode_v7_1 * This);
+
+ ULONG ( STDMETHODCALLTYPE *Release )(
+ IDeckLinkDisplayMode_v7_1 * This);
+
+ HRESULT ( STDMETHODCALLTYPE *GetName )(
+ IDeckLinkDisplayMode_v7_1 * This,
+ /* [out] */ BSTR *name);
+
+ BMDDisplayMode ( STDMETHODCALLTYPE *GetDisplayMode )(
+ IDeckLinkDisplayMode_v7_1 * This);
+
+ long ( STDMETHODCALLTYPE *GetWidth )(
+ IDeckLinkDisplayMode_v7_1 * This);
+
+ long ( STDMETHODCALLTYPE *GetHeight )(
+ IDeckLinkDisplayMode_v7_1 * This);
+
+ HRESULT ( STDMETHODCALLTYPE *GetFrameRate )(
+ IDeckLinkDisplayMode_v7_1 * This,
+ /* [out] */ BMDTimeValue *frameDuration,
+ /* [out] */ BMDTimeScale *timeScale);
+
+ END_INTERFACE
+ } IDeckLinkDisplayMode_v7_1Vtbl;
+
+ interface IDeckLinkDisplayMode_v7_1
+ {
+ CONST_VTBL struct IDeckLinkDisplayMode_v7_1Vtbl *lpVtbl;
+ };
+
+
+
+#ifdef COBJMACROS
+
+
+#define IDeckLinkDisplayMode_v7_1_QueryInterface(This,riid,ppvObject) \
+ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) )
+
+#define IDeckLinkDisplayMode_v7_1_AddRef(This) \
+ ( (This)->lpVtbl -> AddRef(This) )
+
+#define IDeckLinkDisplayMode_v7_1_Release(This) \
+ ( (This)->lpVtbl -> Release(This) )
+
+
+#define IDeckLinkDisplayMode_v7_1_GetName(This,name) \
+ ( (This)->lpVtbl -> GetName(This,name) )
+
+#define IDeckLinkDisplayMode_v7_1_GetDisplayMode(This) \
+ ( (This)->lpVtbl -> GetDisplayMode(This) )
+
+#define IDeckLinkDisplayMode_v7_1_GetWidth(This) \
+ ( (This)->lpVtbl -> GetWidth(This) )
+
+#define IDeckLinkDisplayMode_v7_1_GetHeight(This) \
+ ( (This)->lpVtbl -> GetHeight(This) )
+
+#define IDeckLinkDisplayMode_v7_1_GetFrameRate(This,frameDuration,timeScale) \
+ ( (This)->lpVtbl -> GetFrameRate(This,frameDuration,timeScale) )
+
+#endif /* COBJMACROS */
+
+
+#endif /* C style interface */
+
+
+
+
+#endif /* __IDeckLinkDisplayMode_v7_1_INTERFACE_DEFINED__ */
+
+
+#ifndef __IDeckLinkVideoFrame_v7_1_INTERFACE_DEFINED__
+#define __IDeckLinkVideoFrame_v7_1_INTERFACE_DEFINED__
+
+/* interface IDeckLinkVideoFrame_v7_1 */
+/* [helpstring][local][uuid][object] */
+
+
+EXTERN_C const IID IID_IDeckLinkVideoFrame_v7_1;
+
+#if defined(__cplusplus) && !defined(CINTERFACE)
+
+ MIDL_INTERFACE("333F3A10-8C2D-43CF-B79D-46560FEEA1CE")
+ IDeckLinkVideoFrame_v7_1 : public IUnknown
+ {
+ public:
+ virtual long STDMETHODCALLTYPE GetWidth( void) = 0;
+
+ virtual long STDMETHODCALLTYPE GetHeight( void) = 0;
+
+ virtual long STDMETHODCALLTYPE GetRowBytes( void) = 0;
+
+ virtual BMDPixelFormat STDMETHODCALLTYPE GetPixelFormat( void) = 0;
+
+ virtual BMDFrameFlags STDMETHODCALLTYPE GetFlags( void) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE GetBytes(
+ void **buffer) = 0;
+
+ };
+
+#else /* C style interface */
+
+ typedef struct IDeckLinkVideoFrame_v7_1Vtbl
+ {
+ BEGIN_INTERFACE
+
+ HRESULT ( STDMETHODCALLTYPE *QueryInterface )(
+ IDeckLinkVideoFrame_v7_1 * This,
+ /* [in] */ REFIID riid,
+ /* [iid_is][out] */
+ __RPC__deref_out void **ppvObject);
+
+ ULONG ( STDMETHODCALLTYPE *AddRef )(
+ IDeckLinkVideoFrame_v7_1 * This);
+
+ ULONG ( STDMETHODCALLTYPE *Release )(
+ IDeckLinkVideoFrame_v7_1 * This);
+
+ long ( STDMETHODCALLTYPE *GetWidth )(
+ IDeckLinkVideoFrame_v7_1 * This);
+
+ long ( STDMETHODCALLTYPE *GetHeight )(
+ IDeckLinkVideoFrame_v7_1 * This);
+
+ long ( STDMETHODCALLTYPE *GetRowBytes )(
+ IDeckLinkVideoFrame_v7_1 * This);
+
+ BMDPixelFormat ( STDMETHODCALLTYPE *GetPixelFormat )(
+ IDeckLinkVideoFrame_v7_1 * This);
+
+ BMDFrameFlags ( STDMETHODCALLTYPE *GetFlags )(
+ IDeckLinkVideoFrame_v7_1 * This);
+
+ HRESULT ( STDMETHODCALLTYPE *GetBytes )(
+ IDeckLinkVideoFrame_v7_1 * This,
+ void **buffer);
+
+ END_INTERFACE
+ } IDeckLinkVideoFrame_v7_1Vtbl;
+
+ interface IDeckLinkVideoFrame_v7_1
+ {
+ CONST_VTBL struct IDeckLinkVideoFrame_v7_1Vtbl *lpVtbl;
+ };
+
+
+
+#ifdef COBJMACROS
+
+
+#define IDeckLinkVideoFrame_v7_1_QueryInterface(This,riid,ppvObject) \
+ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) )
+
+#define IDeckLinkVideoFrame_v7_1_AddRef(This) \
+ ( (This)->lpVtbl -> AddRef(This) )
+
+#define IDeckLinkVideoFrame_v7_1_Release(This) \
+ ( (This)->lpVtbl -> Release(This) )
+
+
+#define IDeckLinkVideoFrame_v7_1_GetWidth(This) \
+ ( (This)->lpVtbl -> GetWidth(This) )
+
+#define IDeckLinkVideoFrame_v7_1_GetHeight(This) \
+ ( (This)->lpVtbl -> GetHeight(This) )
+
+#define IDeckLinkVideoFrame_v7_1_GetRowBytes(This) \
+ ( (This)->lpVtbl -> GetRowBytes(This) )
+
+#define IDeckLinkVideoFrame_v7_1_GetPixelFormat(This) \
+ ( (This)->lpVtbl -> GetPixelFormat(This) )
+
+#define IDeckLinkVideoFrame_v7_1_GetFlags(This) \
+ ( (This)->lpVtbl -> GetFlags(This) )
+
+#define IDeckLinkVideoFrame_v7_1_GetBytes(This,buffer) \
+ ( (This)->lpVtbl -> GetBytes(This,buffer) )
+
+#endif /* COBJMACROS */
+
+
+#endif /* C style interface */
+
+
+
+
+#endif /* __IDeckLinkVideoFrame_v7_1_INTERFACE_DEFINED__ */
+
+
+#ifndef __IDeckLinkVideoInputFrame_v7_1_INTERFACE_DEFINED__
+#define __IDeckLinkVideoInputFrame_v7_1_INTERFACE_DEFINED__
+
+/* interface IDeckLinkVideoInputFrame_v7_1 */
+/* [helpstring][local][uuid][object] */
+
+
+EXTERN_C const IID IID_IDeckLinkVideoInputFrame_v7_1;
+
+#if defined(__cplusplus) && !defined(CINTERFACE)
+
+ MIDL_INTERFACE("C8B41D95-8848-40EE-9B37-6E3417FB114B")
+ IDeckLinkVideoInputFrame_v7_1 : public IDeckLinkVideoFrame_v7_1
+ {
+ public:
+ virtual HRESULT STDMETHODCALLTYPE GetFrameTime(
+ BMDTimeValue *frameTime,
+ BMDTimeValue *frameDuration,
+ BMDTimeScale timeScale) = 0;
+
+ };
+
+#else /* C style interface */
+
+ typedef struct IDeckLinkVideoInputFrame_v7_1Vtbl
+ {
+ BEGIN_INTERFACE
+
+ HRESULT ( STDMETHODCALLTYPE *QueryInterface )(
+ IDeckLinkVideoInputFrame_v7_1 * This,
+ /* [in] */ REFIID riid,
+ /* [iid_is][out] */
+ __RPC__deref_out void **ppvObject);
+
+ ULONG ( STDMETHODCALLTYPE *AddRef )(
+ IDeckLinkVideoInputFrame_v7_1 * This);
+
+ ULONG ( STDMETHODCALLTYPE *Release )(
+ IDeckLinkVideoInputFrame_v7_1 * This);
+
+ long ( STDMETHODCALLTYPE *GetWidth )(
+ IDeckLinkVideoInputFrame_v7_1 * This);
+
+ long ( STDMETHODCALLTYPE *GetHeight )(
+ IDeckLinkVideoInputFrame_v7_1 * This);
+
+ long ( STDMETHODCALLTYPE *GetRowBytes )(
+ IDeckLinkVideoInputFrame_v7_1 * This);
+
+ BMDPixelFormat ( STDMETHODCALLTYPE *GetPixelFormat )(
+ IDeckLinkVideoInputFrame_v7_1 * This);
+
+ BMDFrameFlags ( STDMETHODCALLTYPE *GetFlags )(
+ IDeckLinkVideoInputFrame_v7_1 * This);
+
+ HRESULT ( STDMETHODCALLTYPE *GetBytes )(
+ IDeckLinkVideoInputFrame_v7_1 * This,
+ void **buffer);
+
+ HRESULT ( STDMETHODCALLTYPE *GetFrameTime )(
+ IDeckLinkVideoInputFrame_v7_1 * This,
+ BMDTimeValue *frameTime,
+ BMDTimeValue *frameDuration,
+ BMDTimeScale timeScale);
+
+ END_INTERFACE
+ } IDeckLinkVideoInputFrame_v7_1Vtbl;
+
+ interface IDeckLinkVideoInputFrame_v7_1
+ {
+ CONST_VTBL struct IDeckLinkVideoInputFrame_v7_1Vtbl *lpVtbl;
+ };
+
+
+
+#ifdef COBJMACROS
+
+
+#define IDeckLinkVideoInputFrame_v7_1_QueryInterface(This,riid,ppvObject) \
+ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) )
+
+#define IDeckLinkVideoInputFrame_v7_1_AddRef(This) \
+ ( (This)->lpVtbl -> AddRef(This) )
+
+#define IDeckLinkVideoInputFrame_v7_1_Release(This) \
+ ( (This)->lpVtbl -> Release(This) )
+
+
+#define IDeckLinkVideoInputFrame_v7_1_GetWidth(This) \
+ ( (This)->lpVtbl -> GetWidth(This) )
+
+#define IDeckLinkVideoInputFrame_v7_1_GetHeight(This) \
+ ( (This)->lpVtbl -> GetHeight(This) )
+
+#define IDeckLinkVideoInputFrame_v7_1_GetRowBytes(This) \
+ ( (This)->lpVtbl -> GetRowBytes(This) )
+
+#define IDeckLinkVideoInputFrame_v7_1_GetPixelFormat(This) \
+ ( (This)->lpVtbl -> GetPixelFormat(This) )
+
+#define IDeckLinkVideoInputFrame_v7_1_GetFlags(This) \
+ ( (This)->lpVtbl -> GetFlags(This) )
+
+#define IDeckLinkVideoInputFrame_v7_1_GetBytes(This,buffer) \
+ ( (This)->lpVtbl -> GetBytes(This,buffer) )
+
+
+#define IDeckLinkVideoInputFrame_v7_1_GetFrameTime(This,frameTime,frameDuration,timeScale) \
+ ( (This)->lpVtbl -> GetFrameTime(This,frameTime,frameDuration,timeScale) )
+
+#endif /* COBJMACROS */
+
+
+#endif /* C style interface */
+
+
+
+
+#endif /* __IDeckLinkVideoInputFrame_v7_1_INTERFACE_DEFINED__ */
+
+
+#ifndef __IDeckLinkAudioInputPacket_v7_1_INTERFACE_DEFINED__
+#define __IDeckLinkAudioInputPacket_v7_1_INTERFACE_DEFINED__
+
+/* interface IDeckLinkAudioInputPacket_v7_1 */
+/* [helpstring][local][uuid][object] */
+
+
+EXTERN_C const IID IID_IDeckLinkAudioInputPacket_v7_1;
+
+#if defined(__cplusplus) && !defined(CINTERFACE)
+
+ MIDL_INTERFACE("C86DE4F6-A29F-42E3-AB3A-1363E29F0788")
+ IDeckLinkAudioInputPacket_v7_1 : public IUnknown
+ {
+ public:
+ virtual long STDMETHODCALLTYPE GetSampleCount( void) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE GetBytes(
+ void **buffer) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE GetAudioPacketTime(
+ BMDTimeValue *packetTime,
+ BMDTimeScale timeScale) = 0;
+
+ };
+
+#else /* C style interface */
+
+ typedef struct IDeckLinkAudioInputPacket_v7_1Vtbl
+ {
+ BEGIN_INTERFACE
+
+ HRESULT ( STDMETHODCALLTYPE *QueryInterface )(
+ IDeckLinkAudioInputPacket_v7_1 * This,
+ /* [in] */ REFIID riid,
+ /* [iid_is][out] */
+ __RPC__deref_out void **ppvObject);
+
+ ULONG ( STDMETHODCALLTYPE *AddRef )(
+ IDeckLinkAudioInputPacket_v7_1 * This);
+
+ ULONG ( STDMETHODCALLTYPE *Release )(
+ IDeckLinkAudioInputPacket_v7_1 * This);
+
+ long ( STDMETHODCALLTYPE *GetSampleCount )(
+ IDeckLinkAudioInputPacket_v7_1 * This);
+
+ HRESULT ( STDMETHODCALLTYPE *GetBytes )(
+ IDeckLinkAudioInputPacket_v7_1 * This,
+ void **buffer);
+
+ HRESULT ( STDMETHODCALLTYPE *GetAudioPacketTime )(
+ IDeckLinkAudioInputPacket_v7_1 * This,
+ BMDTimeValue *packetTime,
+ BMDTimeScale timeScale);
+
+ END_INTERFACE
+ } IDeckLinkAudioInputPacket_v7_1Vtbl;
+
+ interface IDeckLinkAudioInputPacket_v7_1
+ {
+ CONST_VTBL struct IDeckLinkAudioInputPacket_v7_1Vtbl *lpVtbl;
+ };
+
+
+
+#ifdef COBJMACROS
+
+
+#define IDeckLinkAudioInputPacket_v7_1_QueryInterface(This,riid,ppvObject) \
+ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) )
+
+#define IDeckLinkAudioInputPacket_v7_1_AddRef(This) \
+ ( (This)->lpVtbl -> AddRef(This) )
+
+#define IDeckLinkAudioInputPacket_v7_1_Release(This) \
+ ( (This)->lpVtbl -> Release(This) )
+
+
+#define IDeckLinkAudioInputPacket_v7_1_GetSampleCount(This) \
+ ( (This)->lpVtbl -> GetSampleCount(This) )
+
+#define IDeckLinkAudioInputPacket_v7_1_GetBytes(This,buffer) \
+ ( (This)->lpVtbl -> GetBytes(This,buffer) )
+
+#define IDeckLinkAudioInputPacket_v7_1_GetAudioPacketTime(This,packetTime,timeScale) \
+ ( (This)->lpVtbl -> GetAudioPacketTime(This,packetTime,timeScale) )
+
+#endif /* COBJMACROS */
+
+
+#endif /* C style interface */
+
+
+
+
+#endif /* __IDeckLinkAudioInputPacket_v7_1_INTERFACE_DEFINED__ */
+
+
+#ifndef __IDeckLinkVideoOutputCallback_v7_1_INTERFACE_DEFINED__
+#define __IDeckLinkVideoOutputCallback_v7_1_INTERFACE_DEFINED__
+
+/* interface IDeckLinkVideoOutputCallback_v7_1 */
+/* [helpstring][uuid][object] */
+
+
+EXTERN_C const IID IID_IDeckLinkVideoOutputCallback_v7_1;
+
+#if defined(__cplusplus) && !defined(CINTERFACE)
+
+ MIDL_INTERFACE("EBD01AFA-E4B0-49C6-A01D-EDB9D1B55FD9")
+ IDeckLinkVideoOutputCallback_v7_1 : public IUnknown
+ {
+ public:
+ virtual HRESULT STDMETHODCALLTYPE ScheduledFrameCompleted(
+ /* [in] */ IDeckLinkVideoFrame_v7_1 *completedFrame,
+ /* [in] */ BMDOutputFrameCompletionResult result) = 0;
+
+ };
+
+#else /* C style interface */
+
+ typedef struct IDeckLinkVideoOutputCallback_v7_1Vtbl
+ {
+ BEGIN_INTERFACE
+
+ HRESULT ( STDMETHODCALLTYPE *QueryInterface )(
+ IDeckLinkVideoOutputCallback_v7_1 * This,
+ /* [in] */ REFIID riid,
+ /* [iid_is][out] */
+ __RPC__deref_out void **ppvObject);
+
+ ULONG ( STDMETHODCALLTYPE *AddRef )(
+ IDeckLinkVideoOutputCallback_v7_1 * This);
+
+ ULONG ( STDMETHODCALLTYPE *Release )(
+ IDeckLinkVideoOutputCallback_v7_1 * This);
+
+ HRESULT ( STDMETHODCALLTYPE *ScheduledFrameCompleted )(
+ IDeckLinkVideoOutputCallback_v7_1 * This,
+ /* [in] */ IDeckLinkVideoFrame_v7_1 *completedFrame,
+ /* [in] */ BMDOutputFrameCompletionResult result);
+
+ END_INTERFACE
+ } IDeckLinkVideoOutputCallback_v7_1Vtbl;
+
+ interface IDeckLinkVideoOutputCallback_v7_1
+ {
+ CONST_VTBL struct IDeckLinkVideoOutputCallback_v7_1Vtbl *lpVtbl;
+ };
+
+
+
+#ifdef COBJMACROS
+
+
+#define IDeckLinkVideoOutputCallback_v7_1_QueryInterface(This,riid,ppvObject) \
+ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) )
+
+#define IDeckLinkVideoOutputCallback_v7_1_AddRef(This) \
+ ( (This)->lpVtbl -> AddRef(This) )
+
+#define IDeckLinkVideoOutputCallback_v7_1_Release(This) \
+ ( (This)->lpVtbl -> Release(This) )
+
+
+#define IDeckLinkVideoOutputCallback_v7_1_ScheduledFrameCompleted(This,completedFrame,result) \
+ ( (This)->lpVtbl -> ScheduledFrameCompleted(This,completedFrame,result) )
+
+#endif /* COBJMACROS */
+
+
+#endif /* C style interface */
+
+
+
+
+#endif /* __IDeckLinkVideoOutputCallback_v7_1_INTERFACE_DEFINED__ */
+
+
+#ifndef __IDeckLinkInputCallback_v7_1_INTERFACE_DEFINED__
+#define __IDeckLinkInputCallback_v7_1_INTERFACE_DEFINED__
+
+/* interface IDeckLinkInputCallback_v7_1 */
+/* [helpstring][uuid][object] */
+
+
+EXTERN_C const IID IID_IDeckLinkInputCallback_v7_1;
+
+#if defined(__cplusplus) && !defined(CINTERFACE)
+
+ MIDL_INTERFACE("7F94F328-5ED4-4E9F-9729-76A86BDC99CC")
+ IDeckLinkInputCallback_v7_1 : public IUnknown
+ {
+ public:
+ virtual HRESULT STDMETHODCALLTYPE VideoInputFrameArrived(
+ /* [in] */ IDeckLinkVideoInputFrame_v7_1 *videoFrame,
+ /* [in] */ IDeckLinkAudioInputPacket_v7_1 *audioPacket) = 0;
+
+ };
+
+#else /* C style interface */
+
+ typedef struct IDeckLinkInputCallback_v7_1Vtbl
+ {
+ BEGIN_INTERFACE
+
+ HRESULT ( STDMETHODCALLTYPE *QueryInterface )(
+ IDeckLinkInputCallback_v7_1 * This,
+ /* [in] */ REFIID riid,
+ /* [iid_is][out] */
+ __RPC__deref_out void **ppvObject);
+
+ ULONG ( STDMETHODCALLTYPE *AddRef )(
+ IDeckLinkInputCallback_v7_1 * This);
+
+ ULONG ( STDMETHODCALLTYPE *Release )(
+ IDeckLinkInputCallback_v7_1 * This);
+
+ HRESULT ( STDMETHODCALLTYPE *VideoInputFrameArrived )(
+ IDeckLinkInputCallback_v7_1 * This,
+ /* [in] */ IDeckLinkVideoInputFrame_v7_1 *videoFrame,
+ /* [in] */ IDeckLinkAudioInputPacket_v7_1 *audioPacket);
+
+ END_INTERFACE
+ } IDeckLinkInputCallback_v7_1Vtbl;
+
+ interface IDeckLinkInputCallback_v7_1
+ {
+ CONST_VTBL struct IDeckLinkInputCallback_v7_1Vtbl *lpVtbl;
+ };
+
+
+
+#ifdef COBJMACROS
+
+
+#define IDeckLinkInputCallback_v7_1_QueryInterface(This,riid,ppvObject) \
+ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) )
+
+#define IDeckLinkInputCallback_v7_1_AddRef(This) \
+ ( (This)->lpVtbl -> AddRef(This) )
+
+#define IDeckLinkInputCallback_v7_1_Release(This) \
+ ( (This)->lpVtbl -> Release(This) )
+
+
+#define IDeckLinkInputCallback_v7_1_VideoInputFrameArrived(This,videoFrame,audioPacket) \
+ ( (This)->lpVtbl -> VideoInputFrameArrived(This,videoFrame,audioPacket) )
+
+#endif /* COBJMACROS */
+
+
+#endif /* C style interface */
+
+
+
+
+#endif /* __IDeckLinkInputCallback_v7_1_INTERFACE_DEFINED__ */
+
+
+#ifndef __IDeckLinkOutput_v7_1_INTERFACE_DEFINED__
+#define __IDeckLinkOutput_v7_1_INTERFACE_DEFINED__
+
+/* interface IDeckLinkOutput_v7_1 */
+/* [helpstring][local][uuid][object] */
+
+
+EXTERN_C const IID IID_IDeckLinkOutput_v7_1;
+
+#if defined(__cplusplus) && !defined(CINTERFACE)
+
+ MIDL_INTERFACE("AE5B3E9B-4E1E-4535-B6E8-480FF52F6CE5")
+ IDeckLinkOutput_v7_1 : public IUnknown
+ {
+ public:
+ virtual HRESULT STDMETHODCALLTYPE DoesSupportVideoMode(
+ BMDDisplayMode displayMode,
+ BMDPixelFormat pixelFormat,
+ /* [out] */ BMDDisplayModeSupport *result) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE GetDisplayModeIterator(
+ /* [out] */ IDeckLinkDisplayModeIterator_v7_1 **iterator) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE EnableVideoOutput(
+ BMDDisplayMode displayMode) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE DisableVideoOutput( void) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE SetVideoOutputFrameMemoryAllocator(
+ /* [in] */ IDeckLinkMemoryAllocator *theAllocator) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE CreateVideoFrame(
+ long width,
+ long height,
+ long rowBytes,
+ BMDPixelFormat pixelFormat,
+ BMDFrameFlags flags,
+ IDeckLinkVideoFrame_v7_1 **outFrame) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE CreateVideoFrameFromBuffer(
+ void *buffer,
+ long width,
+ long height,
+ long rowBytes,
+ BMDPixelFormat pixelFormat,
+ BMDFrameFlags flags,
+ IDeckLinkVideoFrame_v7_1 **outFrame) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE DisplayVideoFrameSync(
+ IDeckLinkVideoFrame_v7_1 *theFrame) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE ScheduleVideoFrame(
+ IDeckLinkVideoFrame_v7_1 *theFrame,
+ BMDTimeValue displayTime,
+ BMDTimeValue displayDuration,
+ BMDTimeScale timeScale) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE SetScheduledFrameCompletionCallback(
+ /* [in] */ IDeckLinkVideoOutputCallback_v7_1 *theCallback) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE EnableAudioOutput(
+ BMDAudioSampleRate sampleRate,
+ BMDAudioSampleType sampleType,
+ unsigned long channelCount) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE DisableAudioOutput( void) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE WriteAudioSamplesSync(
+ void *buffer,
+ unsigned long sampleFrameCount,
+ /* [out] */ unsigned long *sampleFramesWritten) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE BeginAudioPreroll( void) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE EndAudioPreroll( void) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE ScheduleAudioSamples(
+ void *buffer,
+ unsigned long sampleFrameCount,
+ BMDTimeValue streamTime,
+ BMDTimeScale timeScale,
+ /* [out] */ unsigned long *sampleFramesWritten) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE GetBufferedAudioSampleFrameCount(
+ /* [out] */ unsigned long *bufferedSampleCount) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE FlushBufferedAudioSamples( void) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE SetAudioCallback(
+ /* [in] */ IDeckLinkAudioOutputCallback *theCallback) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE StartScheduledPlayback(
+ BMDTimeValue playbackStartTime,
+ BMDTimeScale timeScale,
+ double playbackSpeed) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE StopScheduledPlayback(
+ BMDTimeValue stopPlaybackAtTime,
+ BMDTimeValue *actualStopTime,
+ BMDTimeScale timeScale) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE GetHardwareReferenceClock(
+ BMDTimeScale desiredTimeScale,
+ BMDTimeValue *elapsedTimeSinceSchedulerBegan) = 0;
+
+ };
+
+#else /* C style interface */
+
+ typedef struct IDeckLinkOutput_v7_1Vtbl
+ {
+ BEGIN_INTERFACE
+
+ HRESULT ( STDMETHODCALLTYPE *QueryInterface )(
+ IDeckLinkOutput_v7_1 * This,
+ /* [in] */ REFIID riid,
+ /* [iid_is][out] */
+ __RPC__deref_out void **ppvObject);
+
+ ULONG ( STDMETHODCALLTYPE *AddRef )(
+ IDeckLinkOutput_v7_1 * This);
+
+ ULONG ( STDMETHODCALLTYPE *Release )(
+ IDeckLinkOutput_v7_1 * This);
+
+ HRESULT ( STDMETHODCALLTYPE *DoesSupportVideoMode )(
+ IDeckLinkOutput_v7_1 * This,
+ BMDDisplayMode displayMode,
+ BMDPixelFormat pixelFormat,
+ /* [out] */ BMDDisplayModeSupport *result);
+
+ HRESULT ( STDMETHODCALLTYPE *GetDisplayModeIterator )(
+ IDeckLinkOutput_v7_1 * This,
+ /* [out] */ IDeckLinkDisplayModeIterator_v7_1 **iterator);
+
+ HRESULT ( STDMETHODCALLTYPE *EnableVideoOutput )(
+ IDeckLinkOutput_v7_1 * This,
+ BMDDisplayMode displayMode);
+
+ HRESULT ( STDMETHODCALLTYPE *DisableVideoOutput )(
+ IDeckLinkOutput_v7_1 * This);
+
+ HRESULT ( STDMETHODCALLTYPE *SetVideoOutputFrameMemoryAllocator )(
+ IDeckLinkOutput_v7_1 * This,
+ /* [in] */ IDeckLinkMemoryAllocator *theAllocator);
+
+ HRESULT ( STDMETHODCALLTYPE *CreateVideoFrame )(
+ IDeckLinkOutput_v7_1 * This,
+ long width,
+ long height,
+ long rowBytes,
+ BMDPixelFormat pixelFormat,
+ BMDFrameFlags flags,
+ IDeckLinkVideoFrame_v7_1 **outFrame);
+
+ HRESULT ( STDMETHODCALLTYPE *CreateVideoFrameFromBuffer )(
+ IDeckLinkOutput_v7_1 * This,
+ void *buffer,
+ long width,
+ long height,
+ long rowBytes,
+ BMDPixelFormat pixelFormat,
+ BMDFrameFlags flags,
+ IDeckLinkVideoFrame_v7_1 **outFrame);
+
+ HRESULT ( STDMETHODCALLTYPE *DisplayVideoFrameSync )(
+ IDeckLinkOutput_v7_1 * This,
+ IDeckLinkVideoFrame_v7_1 *theFrame);
+
+ HRESULT ( STDMETHODCALLTYPE *ScheduleVideoFrame )(
+ IDeckLinkOutput_v7_1 * This,
+ IDeckLinkVideoFrame_v7_1 *theFrame,
+ BMDTimeValue displayTime,
+ BMDTimeValue displayDuration,
+ BMDTimeScale timeScale);
+
+ HRESULT ( STDMETHODCALLTYPE *SetScheduledFrameCompletionCallback )(
+ IDeckLinkOutput_v7_1 * This,
+ /* [in] */ IDeckLinkVideoOutputCallback_v7_1 *theCallback);
+
+ HRESULT ( STDMETHODCALLTYPE *EnableAudioOutput )(
+ IDeckLinkOutput_v7_1 * This,
+ BMDAudioSampleRate sampleRate,
+ BMDAudioSampleType sampleType,
+ unsigned long channelCount);
+
+ HRESULT ( STDMETHODCALLTYPE *DisableAudioOutput )(
+ IDeckLinkOutput_v7_1 * This);
+
+ HRESULT ( STDMETHODCALLTYPE *WriteAudioSamplesSync )(
+ IDeckLinkOutput_v7_1 * This,
+ void *buffer,
+ unsigned long sampleFrameCount,
+ /* [out] */ unsigned long *sampleFramesWritten);
+
+ HRESULT ( STDMETHODCALLTYPE *BeginAudioPreroll )(
+ IDeckLinkOutput_v7_1 * This);
+
+ HRESULT ( STDMETHODCALLTYPE *EndAudioPreroll )(
+ IDeckLinkOutput_v7_1 * This);
+
+ HRESULT ( STDMETHODCALLTYPE *ScheduleAudioSamples )(
+ IDeckLinkOutput_v7_1 * This,
+ void *buffer,
+ unsigned long sampleFrameCount,
+ BMDTimeValue streamTime,
+ BMDTimeScale timeScale,
+ /* [out] */ unsigned long *sampleFramesWritten);
+
+ HRESULT ( STDMETHODCALLTYPE *GetBufferedAudioSampleFrameCount )(
+ IDeckLinkOutput_v7_1 * This,
+ /* [out] */ unsigned long *bufferedSampleCount);
+
+ HRESULT ( STDMETHODCALLTYPE *FlushBufferedAudioSamples )(
+ IDeckLinkOutput_v7_1 * This);
+
+ HRESULT ( STDMETHODCALLTYPE *SetAudioCallback )(
+ IDeckLinkOutput_v7_1 * This,
+ /* [in] */ IDeckLinkAudioOutputCallback *theCallback);
+
+ HRESULT ( STDMETHODCALLTYPE *StartScheduledPlayback )(
+ IDeckLinkOutput_v7_1 * This,
+ BMDTimeValue playbackStartTime,
+ BMDTimeScale timeScale,
+ double playbackSpeed);
+
+ HRESULT ( STDMETHODCALLTYPE *StopScheduledPlayback )(
+ IDeckLinkOutput_v7_1 * This,
+ BMDTimeValue stopPlaybackAtTime,
+ BMDTimeValue *actualStopTime,
+ BMDTimeScale timeScale);
+
+ HRESULT ( STDMETHODCALLTYPE *GetHardwareReferenceClock )(
+ IDeckLinkOutput_v7_1 * This,
+ BMDTimeScale desiredTimeScale,
+ BMDTimeValue *elapsedTimeSinceSchedulerBegan);
+
+ END_INTERFACE
+ } IDeckLinkOutput_v7_1Vtbl;
+
+ interface IDeckLinkOutput_v7_1
+ {
+ CONST_VTBL struct IDeckLinkOutput_v7_1Vtbl *lpVtbl;
+ };
+
+
+
+#ifdef COBJMACROS
+
+
+#define IDeckLinkOutput_v7_1_QueryInterface(This,riid,ppvObject) \
+ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) )
+
+#define IDeckLinkOutput_v7_1_AddRef(This) \
+ ( (This)->lpVtbl -> AddRef(This) )
+
+#define IDeckLinkOutput_v7_1_Release(This) \
+ ( (This)->lpVtbl -> Release(This) )
+
+
+#define IDeckLinkOutput_v7_1_DoesSupportVideoMode(This,displayMode,pixelFormat,result) \
+ ( (This)->lpVtbl -> DoesSupportVideoMode(This,displayMode,pixelFormat,result) )
+
+#define IDeckLinkOutput_v7_1_GetDisplayModeIterator(This,iterator) \
+ ( (This)->lpVtbl -> GetDisplayModeIterator(This,iterator) )
+
+#define IDeckLinkOutput_v7_1_EnableVideoOutput(This,displayMode) \
+ ( (This)->lpVtbl -> EnableVideoOutput(This,displayMode) )
+
+#define IDeckLinkOutput_v7_1_DisableVideoOutput(This) \
+ ( (This)->lpVtbl -> DisableVideoOutput(This) )
+
+#define IDeckLinkOutput_v7_1_SetVideoOutputFrameMemoryAllocator(This,theAllocator) \
+ ( (This)->lpVtbl -> SetVideoOutputFrameMemoryAllocator(This,theAllocator) )
+
+#define IDeckLinkOutput_v7_1_CreateVideoFrame(This,width,height,rowBytes,pixelFormat,flags,outFrame) \
+ ( (This)->lpVtbl -> CreateVideoFrame(This,width,height,rowBytes,pixelFormat,flags,outFrame) )
+
+#define IDeckLinkOutput_v7_1_CreateVideoFrameFromBuffer(This,buffer,width,height,rowBytes,pixelFormat,flags,outFrame) \
+ ( (This)->lpVtbl -> CreateVideoFrameFromBuffer(This,buffer,width,height,rowBytes,pixelFormat,flags,outFrame) )
+
+#define IDeckLinkOutput_v7_1_DisplayVideoFrameSync(This,theFrame) \
+ ( (This)->lpVtbl -> DisplayVideoFrameSync(This,theFrame) )
+
+#define IDeckLinkOutput_v7_1_ScheduleVideoFrame(This,theFrame,displayTime,displayDuration,timeScale) \
+ ( (This)->lpVtbl -> ScheduleVideoFrame(This,theFrame,displayTime,displayDuration,timeScale) )
+
+#define IDeckLinkOutput_v7_1_SetScheduledFrameCompletionCallback(This,theCallback) \
+ ( (This)->lpVtbl -> SetScheduledFrameCompletionCallback(This,theCallback) )
+
+#define IDeckLinkOutput_v7_1_EnableAudioOutput(This,sampleRate,sampleType,channelCount) \
+ ( (This)->lpVtbl -> EnableAudioOutput(This,sampleRate,sampleType,channelCount) )
+
+#define IDeckLinkOutput_v7_1_DisableAudioOutput(This) \
+ ( (This)->lpVtbl -> DisableAudioOutput(This) )
+
+#define IDeckLinkOutput_v7_1_WriteAudioSamplesSync(This,buffer,sampleFrameCount,sampleFramesWritten) \
+ ( (This)->lpVtbl -> WriteAudioSamplesSync(This,buffer,sampleFrameCount,sampleFramesWritten) )
+
+#define IDeckLinkOutput_v7_1_BeginAudioPreroll(This) \
+ ( (This)->lpVtbl -> BeginAudioPreroll(This) )
+
+#define IDeckLinkOutput_v7_1_EndAudioPreroll(This) \
+ ( (This)->lpVtbl -> EndAudioPreroll(This) )
+
+#define IDeckLinkOutput_v7_1_ScheduleAudioSamples(This,buffer,sampleFrameCount,streamTime,timeScale,sampleFramesWritten) \
+ ( (This)->lpVtbl -> ScheduleAudioSamples(This,buffer,sampleFrameCount,streamTime,timeScale,sampleFramesWritten) )
+
+#define IDeckLinkOutput_v7_1_GetBufferedAudioSampleFrameCount(This,bufferedSampleCount) \
+ ( (This)->lpVtbl -> GetBufferedAudioSampleFrameCount(This,bufferedSampleCount) )
+
+#define IDeckLinkOutput_v7_1_FlushBufferedAudioSamples(This) \
+ ( (This)->lpVtbl -> FlushBufferedAudioSamples(This) )
+
+#define IDeckLinkOutput_v7_1_SetAudioCallback(This,theCallback) \
+ ( (This)->lpVtbl -> SetAudioCallback(This,theCallback) )
+
+#define IDeckLinkOutput_v7_1_StartScheduledPlayback(This,playbackStartTime,timeScale,playbackSpeed) \
+ ( (This)->lpVtbl -> StartScheduledPlayback(This,playbackStartTime,timeScale,playbackSpeed) )
+
+#define IDeckLinkOutput_v7_1_StopScheduledPlayback(This,stopPlaybackAtTime,actualStopTime,timeScale) \
+ ( (This)->lpVtbl -> StopScheduledPlayback(This,stopPlaybackAtTime,actualStopTime,timeScale) )
+
+#define IDeckLinkOutput_v7_1_GetHardwareReferenceClock(This,desiredTimeScale,elapsedTimeSinceSchedulerBegan) \
+ ( (This)->lpVtbl -> GetHardwareReferenceClock(This,desiredTimeScale,elapsedTimeSinceSchedulerBegan) )
+
+#endif /* COBJMACROS */
+
+
+#endif /* C style interface */
+
+
+
+
+#endif /* __IDeckLinkOutput_v7_1_INTERFACE_DEFINED__ */
+
+
+#ifndef __IDeckLinkInput_v7_1_INTERFACE_DEFINED__
+#define __IDeckLinkInput_v7_1_INTERFACE_DEFINED__
+
+/* interface IDeckLinkInput_v7_1 */
+/* [helpstring][uuid][object] */
+
+
+EXTERN_C const IID IID_IDeckLinkInput_v7_1;
+
+#if defined(__cplusplus) && !defined(CINTERFACE)
+
+ MIDL_INTERFACE("2B54EDEF-5B32-429F-BA11-BB990596EACD")
+ IDeckLinkInput_v7_1 : public IUnknown
+ {
+ public:
+ virtual HRESULT STDMETHODCALLTYPE DoesSupportVideoMode(
+ BMDDisplayMode displayMode,
+ BMDPixelFormat pixelFormat,
+ /* [out] */ BMDDisplayModeSupport *result) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE GetDisplayModeIterator(
+ /* [out] */ IDeckLinkDisplayModeIterator_v7_1 **iterator) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE EnableVideoInput(
+ BMDDisplayMode displayMode,
+ BMDPixelFormat pixelFormat,
+ BMDVideoInputFlags flags) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE DisableVideoInput( void) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE EnableAudioInput(
+ BMDAudioSampleRate sampleRate,
+ BMDAudioSampleType sampleType,
+ unsigned long channelCount) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE DisableAudioInput( void) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE ReadAudioSamples(
+ void *buffer,
+ unsigned long sampleFrameCount,
+ /* [out] */ unsigned long *sampleFramesRead,
+ /* [out] */ BMDTimeValue *audioPacketTime,
+ BMDTimeScale timeScale) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE GetBufferedAudioSampleFrameCount(
+ /* [out] */ unsigned long *bufferedSampleCount) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE StartStreams( void) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE StopStreams( void) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE PauseStreams( void) = 0;
+
+ virtual HRESULT STDMETHODCALLTYPE SetCallback(
+ /* [in] */ IDeckLinkInputCallback_v7_1 *theCallback) = 0;
+
+ };
+
+#else /* C style interface */
+
+ typedef struct IDeckLinkInput_v7_1Vtbl
+ {
+ BEGIN_INTERFACE
+
+ HRESULT ( STDMETHODCALLTYPE *QueryInterface )(
+ IDeckLinkInput_v7_1 * This,
+ /* [in] */ REFIID riid,
+ /* [iid_is][out] */
+ __RPC__deref_out void **ppvObject);
+
+ ULONG ( STDMETHODCALLTYPE *AddRef )(
+ IDeckLinkInput_v7_1 * This);
+
+ ULONG ( STDMETHODCALLTYPE *Release )(
+ IDeckLinkInput_v7_1 * This);
+
+ HRESULT ( STDMETHODCALLTYPE *DoesSupportVideoMode )(
+ IDeckLinkInput_v7_1 * This,
+ BMDDisplayMode displayMode,
+ BMDPixelFormat pixelFormat,
+ /* [out] */ BMDDisplayModeSupport *result);
+
+ HRESULT ( STDMETHODCALLTYPE *GetDisplayModeIterator )(
+ IDeckLinkInput_v7_1 * This,
+ /* [out] */ IDeckLinkDisplayModeIterator_v7_1 **iterator);
+
+ HRESULT ( STDMETHODCALLTYPE *EnableVideoInput )(
+ IDeckLinkInput_v7_1 * This,
+ BMDDisplayMode displayMode,
+ BMDPixelFormat pixelFormat,
+ BMDVideoInputFlags flags);
+
+ HRESULT ( STDMETHODCALLTYPE *DisableVideoInput )(
+ IDeckLinkInput_v7_1 * This);
+
+ HRESULT ( STDMETHODCALLTYPE *EnableAudioInput )(
+ IDeckLinkInput_v7_1 * This,
+ BMDAudioSampleRate sampleRate,
+ BMDAudioSampleType sampleType,
+ unsigned long channelCount);
+
+ HRESULT ( STDMETHODCALLTYPE *DisableAudioInput )(
+ IDeckLinkInput_v7_1 * This);
+
+ HRESULT ( STDMETHODCALLTYPE *ReadAudioSamples )(
+ IDeckLinkInput_v7_1 * This,
+ void *buffer,
+ unsigned long sampleFrameCount,
+ /* [out] */ unsigned long *sampleFramesRead,
+ /* [out] */ BMDTimeValue *audioPacketTime,
+ BMDTimeScale timeScale);
+
+ HRESULT ( STDMETHODCALLTYPE *GetBufferedAudioSampleFrameCount )(
+ IDeckLinkInput_v7_1 * This,
+ /* [out] */ unsigned long *bufferedSampleCount);
+
+ HRESULT ( STDMETHODCALLTYPE *StartStreams )(
+ IDeckLinkInput_v7_1 * This);
+
+ HRESULT ( STDMETHODCALLTYPE *StopStreams )(
+ IDeckLinkInput_v7_1 * This);
+
+ HRESULT ( STDMETHODCALLTYPE *PauseStreams )(
+ IDeckLinkInput_v7_1 * This);
+
+ HRESULT ( STDMETHODCALLTYPE *SetCallback )(
+ IDeckLinkInput_v7_1 * This,
+ /* [in] */ IDeckLinkInputCallback_v7_1 *theCallback);
+
+ END_INTERFACE
+ } IDeckLinkInput_v7_1Vtbl;
+
+ interface IDeckLinkInput_v7_1
+ {
+ CONST_VTBL struct IDeckLinkInput_v7_1Vtbl *lpVtbl;
+ };
+
+
+
+#ifdef COBJMACROS
+
+
+#define IDeckLinkInput_v7_1_QueryInterface(This,riid,ppvObject) \
+ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) )
+
+#define IDeckLinkInput_v7_1_AddRef(This) \
+ ( (This)->lpVtbl -> AddRef(This) )
+
+#define IDeckLinkInput_v7_1_Release(This) \
+ ( (This)->lpVtbl -> Release(This) )
+
+
+#define IDeckLinkInput_v7_1_DoesSupportVideoMode(This,displayMode,pixelFormat,result) \
+ ( (This)->lpVtbl -> DoesSupportVideoMode(This,displayMode,pixelFormat,result) )
+
+#define IDeckLinkInput_v7_1_GetDisplayModeIterator(This,iterator) \
+ ( (This)->lpVtbl -> GetDisplayModeIterator(This,iterator) )
+
+#define IDeckLinkInput_v7_1_EnableVideoInput(This,displayMode,pixelFormat,flags) \
+ ( (This)->lpVtbl -> EnableVideoInput(This,displayMode,pixelFormat,flags) )
+
+#define IDeckLinkInput_v7_1_DisableVideoInput(This) \
+ ( (This)->lpVtbl -> DisableVideoInput(This) )
+
+#define IDeckLinkInput_v7_1_EnableAudioInput(This,sampleRate,sampleType,channelCount) \
+ ( (This)->lpVtbl -> EnableAudioInput(This,sampleRate,sampleType,channelCount) )
+
+#define IDeckLinkInput_v7_1_DisableAudioInput(This) \
+ ( (This)->lpVtbl -> DisableAudioInput(This) )
+
+#define IDeckLinkInput_v7_1_ReadAudioSamples(This,buffer,sampleFrameCount,sampleFramesRead,audioPacketTime,timeScale) \
+ ( (This)->lpVtbl -> ReadAudioSamples(This,buffer,sampleFrameCount,sampleFramesRead,audioPacketTime,timeScale) )
+
+#define IDeckLinkInput_v7_1_GetBufferedAudioSampleFrameCount(This,bufferedSampleCount) \
+ ( (This)->lpVtbl -> GetBufferedAudioSampleFrameCount(This,bufferedSampleCount) )
+
+#define IDeckLinkInput_v7_1_StartStreams(This) \
+ ( (This)->lpVtbl -> StartStreams(This) )
+
+#define IDeckLinkInput_v7_1_StopStreams(This) \
+ ( (This)->lpVtbl -> StopStreams(This) )
+
+#define IDeckLinkInput_v7_1_PauseStreams(This) \
+ ( (This)->lpVtbl -> PauseStreams(This) )
+
+#define IDeckLinkInput_v7_1_SetCallback(This,theCallback) \
+ ( (This)->lpVtbl -> SetCallback(This,theCallback) )
+
+#endif /* COBJMACROS */
+
+
+#endif /* C style interface */
+
+
+
+
+#endif /* __IDeckLinkInput_v7_1_INTERFACE_DEFINED__ */
+
+#endif /* __DeckLinkAPI_LIBRARY_DEFINED__ */
+
+/* Additional Prototypes for ALL interfaces */
+
+/* end of Additional Prototypes */
+
+#ifdef __cplusplus
+}
+#endif
+
+#endif
+
+
diff --git a/sys/decklink/win/DeckLinkAPIDispatch.cpp b/sys/decklink/win/DeckLinkAPIDispatch.cpp
new file mode 100644
index 000000000..8a69a8ae8
--- /dev/null
+++ b/sys/decklink/win/DeckLinkAPIDispatch.cpp
@@ -0,0 +1,40 @@
+/* -LICENSE-START-
+** Copyright (c) 2011 Blackmagic Design
+**
+** Permission is hereby granted, free of charge, to any person or organization
+** obtaining a copy of the software and accompanying documentation covered by
+** this license (the "Software") to use, reproduce, display, distribute,
+** execute, and transmit the Software, and to prepare derivative works of the
+** Software, and to permit third-parties to whom the Software is furnished to
+** do so, all subject to the following:
+**
+** The copyright notices in the Software and this entire statement, including
+** the above license grant, this restriction and the following disclaimer,
+** must be included in all copies of the Software, in whole or in part, and
+** all derivative works of the Software, unless such copies or derivative
+** works are solely in the form of machine-executable object code generated by
+** a source language processor.
+**
+** THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
+** IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
+** FITNESS FOR A PARTICULAR PURPOSE, TITLE AND NON-INFRINGEMENT. IN NO EVENT
+** SHALL THE COPYRIGHT HOLDERS OR ANYONE DISTRIBUTING THE SOFTWARE BE LIABLE
+** FOR ANY DAMAGES OR OTHER LIABILITY, WHETHER IN CONTRACT, TORT OR OTHERWISE,
+** ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
+** DEALINGS IN THE SOFTWARE.
+** -LICENSE-END-
+**/
+
+#include "DeckLinkAPI.h"
+
+extern "C" {
+
+IDeckLinkIterator* CreateDeckLinkIteratorInstance (void)
+{
+ IDeckLinkIterator *deckLinkIterator = NULL;
+ HRESULT res = CoCreateInstance(CLSID_CDeckLinkIterator, NULL, CLSCTX_ALL,
+ IID_IDeckLinkIterator, (void**)&deckLinkIterator);
+ return deckLinkIterator;
+}
+
+}; \ No newline at end of file
diff --git a/sys/decklink/win/DeckLinkAPI_i.c b/sys/decklink/win/DeckLinkAPI_i.c
new file mode 100644
index 000000000..ca14206ac
--- /dev/null
+++ b/sys/decklink/win/DeckLinkAPI_i.c
@@ -0,0 +1,319 @@
+
+
+/* this ALWAYS GENERATED file contains the IIDs and CLSIDs */
+
+/* link this file in with the server and any clients */
+
+
+ /* File created by MIDL compiler version 7.00.0500 */
+/* at Fri Jun 17 10:43:51 2011
+ */
+/* Compiler settings for .\win\DeckLinkAPI.idl:
+ Oicf, W1, Zp8, env=Win32 (32b run)
+ protocol : dce , ms_ext, c_ext, robust
+ error checks: allocation ref bounds_check enum stub_data
+ VC __declspec() decoration level:
+ __declspec(uuid()), __declspec(selectany), __declspec(novtable)
+ DECLSPEC_UUID(), MIDL_INTERFACE()
+*/
+//@@MIDL_FILE_HEADING( )
+
+#pragma warning( disable: 4049 ) /* more than 64k source lines */
+
+
+#ifdef __cplusplus
+extern "C"
+{
+#endif
+
+
+#include <rpc.h>
+#include <rpcndr.h>
+
+#ifdef _MIDL_USE_GUIDDEF_
+
+#ifndef INITGUID
+#define INITGUID
+#include <guiddef.h>
+#undef INITGUID
+#else
+#include <guiddef.h>
+#endif
+
+#define MIDL_DEFINE_GUID(type,name,l,w1,w2,b1,b2,b3,b4,b5,b6,b7,b8) \
+ DEFINE_GUID(name,l,w1,w2,b1,b2,b3,b4,b5,b6,b7,b8)
+
+#else // !_MIDL_USE_GUIDDEF_
+
+#ifndef __IID_DEFINED__
+#define __IID_DEFINED__
+
+ typedef struct _IID
+ {
+ unsigned long x;
+ unsigned short s1;
+ unsigned short s2;
+ unsigned char c[8];
+ } IID;
+
+#endif // __IID_DEFINED__
+
+#ifndef CLSID_DEFINED
+#define CLSID_DEFINED
+ typedef IID CLSID;
+#endif // CLSID_DEFINED
+
+#define MIDL_DEFINE_GUID(type,name,l,w1,w2,b1,b2,b3,b4,b5,b6,b7,b8) \
+ const type name = {l,w1,w2,{b1,b2,b3,b4,b5,b6,b7,b8}}
+
+#endif /* !_MIDL_USE_GUIDDEF_ */
+
+ MIDL_DEFINE_GUID (IID, LIBID_DeckLinkAPI, 0xD864517A, 0xEDD5, 0x466D, 0x86,
+ 0x7D, 0xC8, 0x19, 0xF1, 0xC0, 0x52, 0xBB);
+
+
+ MIDL_DEFINE_GUID (IID, IID_IDeckLinkVideoOutputCallback, 0x20AA5225, 0x1958,
+ 0x47CB, 0x82, 0x0B, 0x80, 0xA8, 0xD5, 0x21, 0xA6, 0xEE);
+
+
+ MIDL_DEFINE_GUID (IID, IID_IDeckLinkInputCallback, 0xDD04E5EC, 0x7415,
+ 0x42AB, 0xAE, 0x4A, 0xE8, 0x0C, 0x4D, 0xFC, 0x04, 0x4A);
+
+
+ MIDL_DEFINE_GUID (IID, IID_IDeckLinkMemoryAllocator, 0xB36EB6E7, 0x9D29,
+ 0x4AA8, 0x92, 0xEF, 0x84, 0x3B, 0x87, 0xA2, 0x89, 0xE8);
+
+
+ MIDL_DEFINE_GUID (IID, IID_IDeckLinkAudioOutputCallback, 0x403C681B, 0x7F46,
+ 0x4A12, 0xB9, 0x93, 0x2B, 0xB1, 0x27, 0x08, 0x4E, 0xE6);
+
+
+ MIDL_DEFINE_GUID (IID, IID_IDeckLinkIterator, 0x74E936FC, 0xCC28, 0x4A67,
+ 0x81, 0xA0, 0x1E, 0x94, 0xE5, 0x2D, 0x4E, 0x69);
+
+
+ MIDL_DEFINE_GUID (IID, IID_IDeckLinkAPIInformation, 0x7BEA3C68, 0x730D,
+ 0x4322, 0xAF, 0x34, 0x8A, 0x71, 0x52, 0xB5, 0x32, 0xA4);
+
+
+ MIDL_DEFINE_GUID (IID, IID_IDeckLinkDisplayModeIterator, 0x9C88499F, 0xF601,
+ 0x4021, 0xB8, 0x0B, 0x03, 0x2E, 0x4E, 0xB4, 0x1C, 0x35);
+
+
+ MIDL_DEFINE_GUID (IID, IID_IDeckLinkDisplayMode, 0x3EB2C1AB, 0x0A3D, 0x4523,
+ 0xA3, 0xAD, 0xF4, 0x0D, 0x7F, 0xB1, 0x4E, 0x78);
+
+
+ MIDL_DEFINE_GUID (IID, IID_IDeckLink, 0x62BFF75D, 0x6569, 0x4E55, 0x8D,
+ 0x4D, 0x66, 0xAA, 0x03, 0x82, 0x9A, 0xBC);
+
+
+ MIDL_DEFINE_GUID (IID, IID_IDeckLinkOutput, 0xA3EF0963, 0x0862, 0x44ED,
+ 0x92, 0xA9, 0xEE, 0x89, 0xAB, 0xF4, 0x31, 0xC7);
+
+
+ MIDL_DEFINE_GUID (IID, IID_IDeckLinkInput, 0x6D40EF78, 0x28B9, 0x4E21, 0x99,
+ 0x0D, 0x95, 0xBB, 0x77, 0x50, 0xA0, 0x4F);
+
+
+ MIDL_DEFINE_GUID (IID, IID_IDeckLinkTimecode, 0xBC6CFBD3, 0x8317, 0x4325,
+ 0xAC, 0x1C, 0x12, 0x16, 0x39, 0x1E, 0x93, 0x40);
+
+
+ MIDL_DEFINE_GUID (IID, IID_IDeckLinkVideoFrame, 0x3F716FE0, 0xF023, 0x4111,
+ 0xBE, 0x5D, 0xEF, 0x44, 0x14, 0xC0, 0x5B, 0x17);
+
+
+ MIDL_DEFINE_GUID (IID, IID_IDeckLinkMutableVideoFrame, 0x69E2639F, 0x40DA,
+ 0x4E19, 0xB6, 0xF2, 0x20, 0xAC, 0xE8, 0x15, 0xC3, 0x90);
+
+
+ MIDL_DEFINE_GUID (IID, IID_IDeckLinkVideoFrame3DExtensions, 0xDA0F7E4A,
+ 0xEDC7, 0x48A8, 0x9C, 0xDD, 0x2D, 0xB5, 0x1C, 0x72, 0x9C, 0xD7);
+
+
+ MIDL_DEFINE_GUID (IID, IID_IDeckLinkVideoInputFrame, 0x05CFE374, 0x537C,
+ 0x4094, 0x9A, 0x57, 0x68, 0x05, 0x25, 0x11, 0x8F, 0x44);
+
+
+ MIDL_DEFINE_GUID (IID, IID_IDeckLinkVideoFrameAncillary, 0x732E723C, 0xD1A4,
+ 0x4E29, 0x9E, 0x8E, 0x4A, 0x88, 0x79, 0x7A, 0x00, 0x04);
+
+
+ MIDL_DEFINE_GUID (IID, IID_IDeckLinkAudioInputPacket, 0xE43D5870, 0x2894,
+ 0x11DE, 0x8C, 0x30, 0x08, 0x00, 0x20, 0x0C, 0x9A, 0x66);
+
+
+ MIDL_DEFINE_GUID (IID, IID_IDeckLinkScreenPreviewCallback, 0xB1D3F49A,
+ 0x85FE, 0x4C5D, 0x95, 0xC8, 0x0B, 0x5D, 0x5D, 0xCC, 0xD4, 0x38);
+
+
+ MIDL_DEFINE_GUID (IID, IID_IDeckLinkGLScreenPreviewHelper, 0x504E2209,
+ 0xCAC7, 0x4C1A, 0x9F, 0xB4, 0xC5, 0xBB, 0x62, 0x74, 0xD2, 0x2F);
+
+
+ MIDL_DEFINE_GUID (IID, IID_IDeckLinkConfiguration, 0xC679A35B, 0x610C,
+ 0x4D09, 0xB7, 0x48, 0x1D, 0x04, 0x78, 0x10, 0x0F, 0xC0);
+
+
+ MIDL_DEFINE_GUID (IID, IID_IDeckLinkAttributes, 0xABC11843, 0xD966, 0x44CB,
+ 0x96, 0xE2, 0xA1, 0xCB, 0x5D, 0x31, 0x35, 0xC4);
+
+
+ MIDL_DEFINE_GUID (IID, IID_IDeckLinkKeyer, 0x89AFCAF5, 0x65F8, 0x421E, 0x98,
+ 0xF7, 0x96, 0xFE, 0x5F, 0x5B, 0xFB, 0xA3);
+
+
+ MIDL_DEFINE_GUID (IID, IID_IDeckLinkVideoConversion, 0x3BBCB8A2, 0xDA2C,
+ 0x42D9, 0xB5, 0xD8, 0x88, 0x08, 0x36, 0x44, 0xE9, 0x9A);
+
+
+ MIDL_DEFINE_GUID (IID, IID_IDeckLinkDeckControlStatusCallback, 0xE5F693C1,
+ 0x4283, 0x4716, 0xB1, 0x8F, 0xC1, 0x43, 0x15, 0x21, 0x95, 0x5B);
+
+
+ MIDL_DEFINE_GUID (IID, IID_IDeckLinkDeckControl, 0x522A9E39, 0x0F3C, 0x4742,
+ 0x94, 0xEE, 0xD8, 0x0D, 0xE3, 0x35, 0xDA, 0x1D);
+
+
+ MIDL_DEFINE_GUID (CLSID, CLSID_CDeckLinkIterator, 0xD9EDA3B3, 0x2887,
+ 0x41FA, 0xB7, 0x24, 0x01, 0x7C, 0xF1, 0xEB, 0x1D, 0x37);
+
+
+ MIDL_DEFINE_GUID (CLSID, CLSID_CDeckLinkAPIInformation, 0x263CA19F, 0xED09,
+ 0x482E, 0x9F, 0x9D, 0x84, 0x00, 0x57, 0x83, 0xA2, 0x37);
+
+
+ MIDL_DEFINE_GUID (CLSID, CLSID_CDeckLinkGLScreenPreviewHelper, 0xF63E77C7,
+ 0xB655, 0x4A4A, 0x9A, 0xD0, 0x3C, 0xA8, 0x5D, 0x39, 0x43, 0x43);
+
+
+ MIDL_DEFINE_GUID (CLSID, CLSID_CDeckLinkVideoConversion, 0x7DBBBB11, 0x5B7B,
+ 0x467D, 0xAE, 0xA4, 0xCE, 0xA4, 0x68, 0xFD, 0x36, 0x8C);
+
+
+ MIDL_DEFINE_GUID (IID, IID_IDeckLinkDeckControl_v7_9, 0xA4D81043, 0x0619,
+ 0x42B7, 0x8E, 0xD6, 0x60, 0x2D, 0x29, 0x04, 0x1D, 0xF7);
+
+
+ MIDL_DEFINE_GUID (IID, IID_IDeckLinkDisplayModeIterator_v7_6, 0x455D741F,
+ 0x1779, 0x4800, 0x86, 0xF5, 0x0B, 0x5D, 0x13, 0xD7, 0x97, 0x51);
+
+
+ MIDL_DEFINE_GUID (IID, IID_IDeckLinkDisplayMode_v7_6, 0x87451E84, 0x2B7E,
+ 0x439E, 0xA6, 0x29, 0x43, 0x93, 0xEA, 0x4A, 0x85, 0x50);
+
+
+ MIDL_DEFINE_GUID (IID, IID_IDeckLinkOutput_v7_6, 0x29228142, 0xEB8C, 0x4141,
+ 0xA6, 0x21, 0xF7, 0x40, 0x26, 0x45, 0x09, 0x55);
+
+
+ MIDL_DEFINE_GUID (IID, IID_IDeckLinkInput_v7_6, 0x300C135A, 0x9F43, 0x48E2,
+ 0x99, 0x06, 0x6D, 0x79, 0x11, 0xD9, 0x3C, 0xF1);
+
+
+ MIDL_DEFINE_GUID (IID, IID_IDeckLinkTimecode_v7_6, 0xEFB9BCA6, 0xA521,
+ 0x44F7, 0xBD, 0x69, 0x23, 0x32, 0xF2, 0x4D, 0x9E, 0xE6);
+
+
+ MIDL_DEFINE_GUID (IID, IID_IDeckLinkVideoFrame_v7_6, 0xA8D8238E, 0x6B18,
+ 0x4196, 0x99, 0xE1, 0x5A, 0xF7, 0x17, 0xB8, 0x3D, 0x32);
+
+
+ MIDL_DEFINE_GUID (IID, IID_IDeckLinkMutableVideoFrame_v7_6, 0x46FCEE00,
+ 0xB4E6, 0x43D0, 0x91, 0xC0, 0x02, 0x3A, 0x7F, 0xCE, 0xB3, 0x4F);
+
+
+ MIDL_DEFINE_GUID (IID, IID_IDeckLinkVideoInputFrame_v7_6, 0x9A74FA41,
+ 0xAE9F, 0x47AC, 0x8C, 0xF4, 0x01, 0xF4, 0x2D, 0xD5, 0x99, 0x65);
+
+
+ MIDL_DEFINE_GUID (IID, IID_IDeckLinkScreenPreviewCallback_v7_6, 0x373F499D,
+ 0x4B4D, 0x4518, 0xAD, 0x22, 0x63, 0x54, 0xE5, 0xA5, 0x82, 0x5E);
+
+
+ MIDL_DEFINE_GUID (IID, IID_IDeckLinkGLScreenPreviewHelper_v7_6, 0xBA575CD9,
+ 0xA15E, 0x497B, 0xB2, 0xC2, 0xF9, 0xAF, 0xE7, 0xBE, 0x4E, 0xBA);
+
+
+ MIDL_DEFINE_GUID (IID, IID_IDeckLinkVideoConversion_v7_6, 0x3EB504C9,
+ 0xF97D, 0x40FE, 0xA1, 0x58, 0xD4, 0x07, 0xD4, 0x8C, 0xB5, 0x3B);
+
+
+ MIDL_DEFINE_GUID (IID, IID_IDeckLinkConfiguration_v7_6, 0xB8EAD569, 0xB764,
+ 0x47F0, 0xA7, 0x3F, 0xAE, 0x40, 0xDF, 0x6C, 0xBF, 0x10);
+
+
+ MIDL_DEFINE_GUID (IID, IID_IDeckLinkVideoOutputCallback_v7_6, 0xE763A626,
+ 0x4A3C, 0x49D1, 0xBF, 0x13, 0xE7, 0xAD, 0x36, 0x92, 0xAE, 0x52);
+
+
+ MIDL_DEFINE_GUID (IID, IID_IDeckLinkInputCallback_v7_6, 0x31D28EE7, 0x88B6,
+ 0x4CB1, 0x89, 0x7A, 0xCD, 0xBF, 0x79, 0xA2, 0x64, 0x14);
+
+
+ MIDL_DEFINE_GUID (CLSID, CLSID_CDeckLinkGLScreenPreviewHelper_v7_6,
+ 0xD398CEE7, 0x4434, 0x4CA3, 0x9B, 0xA6, 0x5A, 0xE3, 0x45, 0x56, 0xB9,
+ 0x05);
+
+
+ MIDL_DEFINE_GUID (CLSID, CLSID_CDeckLinkVideoConversion_v7_6, 0xFFA84F77,
+ 0x73BE, 0x4FB7, 0xB0, 0x3E, 0xB5, 0xE4, 0x4B, 0x9F, 0x75, 0x9B);
+
+
+ MIDL_DEFINE_GUID (IID, IID_IDeckLinkInputCallback_v7_3, 0xFD6F311D, 0x4D00,
+ 0x444B, 0x9E, 0xD4, 0x1F, 0x25, 0xB5, 0x73, 0x0A, 0xD0);
+
+
+ MIDL_DEFINE_GUID (IID, IID_IDeckLinkOutput_v7_3, 0x271C65E3, 0xC323, 0x4344,
+ 0xA3, 0x0F, 0xD9, 0x08, 0xBC, 0xB2, 0x0A, 0xA3);
+
+
+ MIDL_DEFINE_GUID (IID, IID_IDeckLinkInput_v7_3, 0x4973F012, 0x9925, 0x458C,
+ 0x87, 0x1C, 0x18, 0x77, 0x4C, 0xDB, 0xBE, 0xCB);
+
+
+ MIDL_DEFINE_GUID (IID, IID_IDeckLinkVideoInputFrame_v7_3, 0xCF317790,
+ 0x2894, 0x11DE, 0x8C, 0x30, 0x08, 0x00, 0x20, 0x0C, 0x9A, 0x66);
+
+
+ MIDL_DEFINE_GUID (IID, IID_IDeckLinkDisplayModeIterator_v7_1, 0xB28131B6,
+ 0x59AC, 0x4857, 0xB5, 0xAC, 0xCD, 0x75, 0xD5, 0x88, 0x3E, 0x2F);
+
+
+ MIDL_DEFINE_GUID (IID, IID_IDeckLinkDisplayMode_v7_1, 0xAF0CD6D5, 0x8376,
+ 0x435E, 0x84, 0x33, 0x54, 0xF9, 0xDD, 0x53, 0x0A, 0xC3);
+
+
+ MIDL_DEFINE_GUID (IID, IID_IDeckLinkVideoFrame_v7_1, 0x333F3A10, 0x8C2D,
+ 0x43CF, 0xB7, 0x9D, 0x46, 0x56, 0x0F, 0xEE, 0xA1, 0xCE);
+
+
+ MIDL_DEFINE_GUID (IID, IID_IDeckLinkVideoInputFrame_v7_1, 0xC8B41D95,
+ 0x8848, 0x40EE, 0x9B, 0x37, 0x6E, 0x34, 0x17, 0xFB, 0x11, 0x4B);
+
+
+ MIDL_DEFINE_GUID (IID, IID_IDeckLinkAudioInputPacket_v7_1, 0xC86DE4F6,
+ 0xA29F, 0x42E3, 0xAB, 0x3A, 0x13, 0x63, 0xE2, 0x9F, 0x07, 0x88);
+
+
+ MIDL_DEFINE_GUID (IID, IID_IDeckLinkVideoOutputCallback_v7_1, 0xEBD01AFA,
+ 0xE4B0, 0x49C6, 0xA0, 0x1D, 0xED, 0xB9, 0xD1, 0xB5, 0x5F, 0xD9);
+
+
+ MIDL_DEFINE_GUID (IID, IID_IDeckLinkInputCallback_v7_1, 0x7F94F328, 0x5ED4,
+ 0x4E9F, 0x97, 0x29, 0x76, 0xA8, 0x6B, 0xDC, 0x99, 0xCC);
+
+
+ MIDL_DEFINE_GUID (IID, IID_IDeckLinkOutput_v7_1, 0xAE5B3E9B, 0x4E1E, 0x4535,
+ 0xB6, 0xE8, 0x48, 0x0F, 0xF5, 0x2F, 0x6C, 0xE5);
+
+
+ MIDL_DEFINE_GUID (IID, IID_IDeckLinkInput_v7_1, 0x2B54EDEF, 0x5B32, 0x429F,
+ 0xBA, 0x11, 0xBB, 0x99, 0x05, 0x96, 0xEA, 0xCD);
+
+#undef MIDL_DEFINE_GUID
+
+#ifdef __cplusplus
+}
+#endif
diff --git a/tests/check/Makefile.am b/tests/check/Makefile.am
index 430d5ac6a..dca2775b1 100644
--- a/tests/check/Makefile.am
+++ b/tests/check/Makefile.am
@@ -145,11 +145,6 @@ VALGRIND_TO_FIX = \
VALGRIND_TESTS_DISABLE = \
$(VALGRIND_TO_FIX)
-if BUILD_EXPERIMENTAL
-EXPERIMENTAL_CHECKS=elements/camerabin2 \
- elements/viewfinderbin
-endif
-
# these tests don't even pass
# neon: too flaky (almost always fails 'the first time')
noinst_PROGRAMS = \
@@ -171,6 +166,7 @@ check_PROGRAMS = \
elements/asfmux \
elements/baseaudiovisualizer \
elements/camerabin \
+ elements/camerabin2 \
elements/dataurisrc \
elements/legacyresample \
$(check_jifmux) \
@@ -189,6 +185,7 @@ check_PROGRAMS = \
elements/rtpmux \
$(check_schro) \
$(check_vp8) \
+ elements/viewfinderbin \
$(check_zbar) \
$(check_orc) \
$(EXPERIMENTAL_CHECKS)
diff --git a/tests/check/elements/camerabin2.c b/tests/check/elements/camerabin2.c
index 6638ccf76..e824f2956 100644
--- a/tests/check/elements/camerabin2.c
+++ b/tests/check/elements/camerabin2.c
@@ -174,6 +174,9 @@ static GstTagList *tags_found;
static gboolean
validity_bus_cb (GstBus * bus, GstMessage * message, gpointer data);
+static GstMessage *wait_for_element_message (GstElement * camera,
+ const gchar * name, GstClockTime timeout);
+
static void
validate_taglist_foreach (const GstTagList * list, const gchar * tag,
gpointer user_data)
@@ -279,8 +282,14 @@ capture_bus_cb (GstBus * bus, GstMessage * message, gpointer data)
}
static void
-check_preview_image (void)
+check_preview_image (GstElement * camera)
{
+ if (!preview_buffer && camera) {
+ GstMessage *msg = wait_for_element_message (camera,
+ GST_BASE_CAMERA_SRC_PREVIEW_MESSAGE_NAME, GST_CLOCK_TIME_NONE);
+ fail_unless (msg != NULL);
+ gst_message_unref (msg);
+ }
fail_unless (preview_buffer != NULL);
if (preview_caps) {
fail_unless (GST_BUFFER_CAPS (preview_buffer) != NULL);
@@ -324,6 +333,7 @@ setup_wrappercamerabinsrc_videotestsrc (void)
GstElement *fakevideosink;
GstElement *src;
GstElement *testsrc;
+ GstElement *audiosrc;
GST_INFO ("init");
@@ -336,16 +346,19 @@ setup_wrappercamerabinsrc_videotestsrc (void)
fakevideosink = gst_element_factory_make ("fakesink", NULL);
src = gst_element_factory_make ("wrappercamerabinsrc", NULL);
testsrc = gst_element_factory_make ("videotestsrc", NULL);
+ audiosrc = gst_element_factory_make ("audiotestsrc", NULL);
preview_caps = gst_caps_new_simple ("video/x-raw-rgb", "width", G_TYPE_INT,
320, "height", G_TYPE_INT, 240, NULL);
g_object_set (G_OBJECT (testsrc), "is-live", TRUE, "peer-alloc", FALSE, NULL);
+ g_object_set (G_OBJECT (audiosrc), "is-live", TRUE, NULL);
g_object_set (G_OBJECT (src), "video-source", testsrc, NULL);
g_object_set (G_OBJECT (camera), "camera-source", src, "preview-caps",
- preview_caps, NULL);
+ preview_caps, "audio-source", audiosrc, NULL);
gst_object_unref (src);
gst_object_unref (testsrc);
+ gst_object_unref (audiosrc);
vfbin = gst_bin_get_by_name (GST_BIN (camera), "vf-bin");
g_object_set (G_OBJECT (vfbin), "video-sink", fakevideosink, NULL);
@@ -530,9 +543,52 @@ filter_buffer_count (GstPad * pad, GstMiniObject * obj, gpointer data)
return TRUE;
}
+static GstMessage *
+wait_for_element_message (GstElement * camera, const gchar * name,
+ GstClockTime timeout)
+{
+ GstBus *bus = gst_pipeline_get_bus (GST_PIPELINE (camera));
+ GstMessage *msg;
+
+ while (1) {
+ msg = gst_bus_timed_pop_filtered (bus, timeout, GST_MESSAGE_ERROR |
+ GST_MESSAGE_EOS | GST_MESSAGE_ELEMENT);
+
+ if (msg) {
+ if (GST_MESSAGE_TYPE (msg) == GST_MESSAGE_ELEMENT) {
+ const GstStructure *st = gst_message_get_structure (msg);
+ if (gst_structure_has_name (st,
+ GST_BASE_CAMERA_SRC_PREVIEW_MESSAGE_NAME)) {
+ GstBuffer *buf;
+ const GValue *value;
+
+ value = gst_structure_get_value (st, "buffer");
+ fail_unless (value != NULL);
+ buf = gst_value_get_buffer (value);
+
+ if (preview_buffer)
+ gst_buffer_unref (preview_buffer);
+ preview_buffer = gst_buffer_ref (buf);
+ }
+
+ if (gst_structure_has_name (st, name))
+ break;
+ } else {
+ gst_message_unref (msg);
+ msg = NULL;
+ break;
+ }
+ }
+ }
+
+ gst_object_unref (bus);
+ return msg;
+}
+
GST_START_TEST (test_single_image_capture)
{
gboolean idle;
+ GstMessage *msg;
if (!camera)
return;
@@ -553,11 +609,12 @@ GST_START_TEST (test_single_image_capture)
fail_unless (idle);
g_signal_emit_by_name (camera, "start-capture", NULL);
- g_timeout_add_seconds (3, (GSourceFunc) g_main_loop_quit, main_loop);
- g_main_loop_run (main_loop);
+ msg = wait_for_element_message (camera, "image-done", GST_CLOCK_TIME_NONE);
+ fail_unless (msg != NULL);
+ gst_message_unref (msg);
/* check that we got a preview image */
- check_preview_image ();
+ check_preview_image (camera);
g_object_get (camera, "idle", &idle, NULL);
fail_unless (idle);
@@ -595,6 +652,7 @@ GST_START_TEST (test_multiple_image_captures)
GST_INFO ("starting capture");
for (i = 0; i < 3; i++) {
+ GstMessage *msg;
GstCaps *caps;
caps = gst_caps_new_simple ("video/x-raw-rgb", "width", G_TYPE_INT,
@@ -605,13 +663,13 @@ GST_START_TEST (test_multiple_image_captures)
g_signal_emit_by_name (camera, "start-capture", NULL);
- g_timeout_add_seconds (3, (GSourceFunc) g_main_loop_quit, main_loop);
- g_main_loop_run (main_loop);
+ msg = wait_for_element_message (camera, "image-done", GST_CLOCK_TIME_NONE);
+ fail_unless (msg != NULL);
+ gst_message_unref (msg);
- check_preview_image ();
+ check_preview_image (camera);
}
- g_usleep (G_USEC_PER_SEC * 3);
g_object_get (camera, "idle", &idle, NULL);
fail_unless (idle);
gst_element_set_state (GST_ELEMENT (camera), GST_STATE_NULL);
@@ -625,6 +683,7 @@ GST_END_TEST;
GST_START_TEST (test_single_video_recording)
{
+ GstMessage *msg;
gboolean idle;
if (!camera)
return;
@@ -657,9 +716,11 @@ GST_START_TEST (test_single_video_recording)
g_signal_emit_by_name (camera, "stop-capture", NULL);
- check_preview_image ();
+ check_preview_image (camera);
- g_usleep (G_USEC_PER_SEC * 3);
+ msg = wait_for_element_message (camera, "video-done", GST_CLOCK_TIME_NONE);
+ fail_unless (msg != NULL);
+ gst_message_unref (msg);
g_object_get (camera, "idle", &idle, NULL);
fail_unless (idle);
@@ -697,6 +758,7 @@ GST_START_TEST (test_multiple_video_recordings)
g_object_get (camera, "idle", &idle, NULL);
fail_unless (idle);
for (i = 0; i < 3; i++) {
+ GstMessage *msg;
GstCaps *caps;
caps = gst_caps_new_simple ("video/x-raw-rgb", "width", G_TYPE_INT,
@@ -718,10 +780,12 @@ GST_START_TEST (test_multiple_video_recordings)
g_main_loop_run (main_loop);
g_signal_emit_by_name (camera, "stop-capture", NULL);
- check_preview_image ();
+ msg = wait_for_element_message (camera, "video-done", GST_CLOCK_TIME_NONE);
+ fail_unless (msg != NULL);
+ gst_message_unref (msg);
+
+ check_preview_image (camera);
- g_timeout_add_seconds (3, (GSourceFunc) g_main_loop_quit, main_loop);
- g_main_loop_run (main_loop);
g_object_get (camera, "idle", &idle, NULL);
fail_unless (idle);
}
@@ -753,6 +817,7 @@ GST_START_TEST (test_image_video_cycle)
GST_INFO ("starting capture");
for (i = 0; i < 2; i++) {
+ GstMessage *msg;
g_object_get (camera, "idle", &idle, NULL);
fail_unless (idle);
@@ -761,10 +826,12 @@ GST_START_TEST (test_image_video_cycle)
g_object_set (camera, "location", make_test_file_name (IMAGE_FILENAME, i),
NULL);
g_signal_emit_by_name (camera, "start-capture", NULL);
- g_timeout_add_seconds (3, (GSourceFunc) g_main_loop_quit, main_loop);
- g_main_loop_run (main_loop);
- check_preview_image ();
+ msg = wait_for_element_message (camera, "image-done", GST_CLOCK_TIME_NONE);
+ fail_unless (msg != NULL);
+ gst_message_unref (msg);
+
+ check_preview_image (camera);
/* now go to video */
g_object_set (camera, "mode", 2, NULL);
@@ -776,7 +843,11 @@ GST_START_TEST (test_image_video_cycle)
g_main_loop_run (main_loop);
g_signal_emit_by_name (camera, "stop-capture", NULL);
- check_preview_image ();
+ msg = wait_for_element_message (camera, "video-done", GST_CLOCK_TIME_NONE);
+ fail_unless (msg != NULL);
+ gst_message_unref (msg);
+
+ check_preview_image (camera);
/* wait for capture to finish */
g_usleep (G_USEC_PER_SEC);
@@ -817,6 +888,7 @@ GST_START_TEST (test_image_capture_previews)
GST_INFO ("starting capture");
for (i = 0; i < 3; i++) {
+ GstMessage *msg;
GstCaps *caps;
caps = gst_caps_new_simple ("video/x-raw-rgb", "width", G_TYPE_INT,
@@ -828,10 +900,11 @@ GST_START_TEST (test_image_capture_previews)
g_signal_emit_by_name (camera, "start-capture", NULL);
- g_timeout_add_seconds (3, (GSourceFunc) g_main_loop_quit, main_loop);
- g_main_loop_run (main_loop);
+ msg = wait_for_element_message (camera, "image-done", GST_CLOCK_TIME_NONE);
+ fail_unless (msg != NULL);
+ gst_message_unref (msg);
- check_preview_image ();
+ check_preview_image (camera);
if (preview_buffer)
gst_buffer_unref (preview_buffer);
@@ -896,13 +969,15 @@ GST_START_TEST (test_image_capture_with_tags)
GST_INFO ("starting capture");
for (i = 0; i < 3; i++) {
+ GstMessage *msg;
gst_tag_setter_merge_tags (GST_TAG_SETTER (camera), taglists[i],
GST_TAG_MERGE_REPLACE);
g_signal_emit_by_name (camera, "start-capture", NULL);
- g_timeout_add_seconds (3, (GSourceFunc) g_main_loop_quit, main_loop);
- g_main_loop_run (main_loop);
+ msg = wait_for_element_message (camera, "image-done", GST_CLOCK_TIME_NONE);
+ fail_unless (msg != NULL);
+ gst_message_unref (msg);
}
gst_element_set_state (GST_ELEMENT (camera), GST_STATE_NULL);
@@ -966,6 +1041,8 @@ GST_START_TEST (test_video_capture_with_tags)
GST_INFO ("starting capture");
for (i = 0; i < 3; i++) {
+ GstMessage *msg;
+
gst_tag_setter_merge_tags (GST_TAG_SETTER (camera), taglists[i],
GST_TAG_MERGE_REPLACE);
@@ -975,7 +1052,10 @@ GST_START_TEST (test_video_capture_with_tags)
g_main_loop_run (main_loop);
g_signal_emit_by_name (camera, "stop-capture", NULL);
- g_usleep (G_USEC_PER_SEC * 3);
+
+ msg = wait_for_element_message (camera, "video-done", GST_CLOCK_TIME_NONE);
+ fail_unless (msg != NULL);
+ gst_message_unref (msg);
}
gst_element_set_state (GST_ELEMENT (camera), GST_STATE_NULL);
@@ -1037,6 +1117,7 @@ GST_END_TEST;
GST_START_TEST (test_idle_property)
{
+ GstMessage *msg;
gboolean idle;
if (!camera)
return;
@@ -1073,9 +1154,12 @@ GST_START_TEST (test_idle_property)
g_signal_emit_by_name (camera, "stop-capture", NULL);
- check_preview_image ();
+ msg = wait_for_element_message (camera, "video-done", GST_CLOCK_TIME_NONE);
+ fail_unless (msg != NULL);
+ gst_message_unref (msg);
+
+ check_preview_image (camera);
- g_usleep (3 * G_USEC_PER_SEC);
g_object_get (camera, "idle", &idle, NULL);
fail_unless (idle);
@@ -1144,7 +1228,7 @@ GST_START_TEST (test_image_custom_filter)
g_main_loop_run (main_loop);
/* check that we got a preview image */
- check_preview_image ();
+ check_preview_image (camera);
gst_element_set_state (GST_ELEMENT (camera), GST_STATE_NULL);
check_file_validity (IMAGE_FILENAME, 0, NULL, 0, 0, NO_AUDIO);
@@ -1225,7 +1309,7 @@ GST_START_TEST (test_video_custom_filter)
g_signal_emit_by_name (camera, "stop-capture", NULL);
/* check that we got a preview image */
- check_preview_image ();
+ check_preview_image (camera);
gst_element_set_state (GST_ELEMENT (camera), GST_STATE_NULL);
check_file_validity (VIDEO_FILENAME, 0, NULL, 0, 0, WITH_AUDIO);
@@ -1283,6 +1367,7 @@ GST_START_TEST (test_image_location_switching)
glong notify_id;
GstCaps *caps;
GstElement *src;
+ GstMessage *msg;
if (!camera)
return;
@@ -1319,7 +1404,10 @@ GST_START_TEST (test_image_location_switching)
g_idle_add (image_location_switch_do_capture, filenames);
g_main_loop_run (main_loop);
- g_usleep (G_USEC_PER_SEC * 3);
+ msg = wait_for_element_message (camera, "image-done", GST_CLOCK_TIME_NONE);
+ fail_unless (msg != NULL);
+ gst_message_unref (msg);
+
gst_element_set_state (GST_ELEMENT (camera), GST_STATE_NULL);
for (i = 0; i < LOCATION_SWITCHING_FILENAMES_COUNT; i++) {
diff --git a/tests/examples/Makefile.am b/tests/examples/Makefile.am
index 84c178797..5183dfebf 100644
--- a/tests/examples/Makefile.am
+++ b/tests/examples/Makefile.am
@@ -10,12 +10,6 @@ else
DIRECTFB_DIR=
endif
-if BUILD_EXPERIMENTAL
-CAMERABIN2=camerabin2
-else
-CAMERABIN2=
-endif
-
OPENCV_EXAMPLES=opencv
SUBDIRS= $(DIRECTFB_DIR) $(GTK_EXAMPLES) $(OPENCV_EXAMPLES)