mirror of
https://git.ffmpeg.org/ffmpeg.git
synced 2025-12-08 06:09:50 +00:00
avdevice/decklink: factorize cleanup function to common code
Reviewed-by: Deti Fliegl <deti@fliegl.de> Signed-off-by: Marton Balint <cus@passwd.hu>
This commit is contained in:
parent
340cea9f22
commit
1fc85d8511
4 changed files with 18 additions and 17 deletions
|
|
@ -239,3 +239,16 @@ int ff_decklink_list_formats(AVFormatContext *avctx, decklink_direction_t direct
|
|||
|
||||
return 0;
|
||||
}
|
||||
|
||||
void ff_decklink_cleanup(AVFormatContext *avctx)
|
||||
{
|
||||
struct decklink_cctx *cctx = (struct decklink_cctx *) avctx->priv_data;
|
||||
struct decklink_ctx *ctx = (struct decklink_ctx *) cctx->ctx;
|
||||
|
||||
if (ctx->dli)
|
||||
ctx->dli->Release();
|
||||
if (ctx->dlo)
|
||||
ctx->dlo->Release();
|
||||
if (ctx->dl)
|
||||
ctx->dl->Release();
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue