summaryrefslogtreecommitdiff
path: root/libavdevice/decklink_dec.cpp
diff options
context:
space:
mode:
authorKarthick J <kjeyapal@akamai.com>2017-11-07 09:32:23 +0530
committerMarton Balint <cus@passwd.hu>2017-11-21 22:55:49 +0100
commitaa7b0329ff282ea8afb3c26dcbbc64209a280219 (patch)
tree4146710600547c5c2c321fca8eff5c8cbce9d54a /libavdevice/decklink_dec.cpp
parent0e7865ce4152f8b04cda6a698bbee4fd4a94009d (diff)
downloadffmpeg-aa7b0329ff282ea8afb3c26dcbbc64209a280219.tar.gz
avdevice/decklink: refactor ff_decklink_set_format function
This is done to enable input format autodetection in decklink_dec. Signed-off-by: Marton Balint <cus@passwd.hu>
Diffstat (limited to 'libavdevice/decklink_dec.cpp')
-rw-r--r--libavdevice/decklink_dec.cpp6
1 files changed, 6 insertions, 0 deletions
diff --git a/libavdevice/decklink_dec.cpp b/libavdevice/decklink_dec.cpp
index e90b42811a..03a049a21e 100644
--- a/libavdevice/decklink_dec.cpp
+++ b/libavdevice/decklink_dec.cpp
@@ -916,6 +916,12 @@ av_cold int ff_decklink_read_header(AVFormatContext *avctx)
goto error;
}
+ if (ff_decklink_set_configs(avctx, DIRECTION_IN) < 0) {
+ av_log(avctx, AV_LOG_ERROR, "Could not set input configuration\n");
+ ret = AVERROR(EIO);
+ goto error;
+ }
+
if (mode_num > 0 || cctx->format_code) {
if (ff_decklink_set_format(avctx, DIRECTION_IN, mode_num) < 0) {
av_log(avctx, AV_LOG_ERROR, "Could not set mode number %d or format code %s for %s\n",