mirror of
https://github.com/FFmpeg/FFmpeg.git
synced 2024-12-23 12:43:46 +02:00
avdevice/decklink_dec: fix stopping streams in read_close
The capture_started variable was never set, it is simpler to call the stop functions unconditionally if the interface is available. Signed-off-by: Marton Balint <cus@passwd.hu>
This commit is contained in:
parent
3e9793cf38
commit
95324ecf23
@ -115,7 +115,6 @@ struct decklink_ctx {
|
||||
|
||||
/* Status */
|
||||
int playback_started;
|
||||
int capture_started;
|
||||
int64_t last_pts;
|
||||
unsigned long frameCount;
|
||||
unsigned int dropped;
|
||||
|
@ -983,7 +983,7 @@ av_cold int ff_decklink_read_close(AVFormatContext *avctx)
|
||||
struct decklink_cctx *cctx = (struct decklink_cctx *)avctx->priv_data;
|
||||
struct decklink_ctx *ctx = (struct decklink_ctx *)cctx->ctx;
|
||||
|
||||
if (ctx->capture_started) {
|
||||
if (ctx->dli) {
|
||||
ctx->dli->StopStreams();
|
||||
ctx->dli->DisableVideoInput();
|
||||
ctx->dli->DisableAudioInput();
|
||||
|
Loading…
Reference in New Issue
Block a user