| 221 | } |
| 222 | |
| 223 | static int amf_decode_close(AVCodecContext *avctx) |
| 224 | { |
| 225 | AMFDecoderContext *ctx = avctx->priv_data; |
| 226 | |
| 227 | if (ctx->decoder) { |
| 228 | ctx->decoder->pVtbl->Terminate(ctx->decoder); |
| 229 | ctx->decoder->pVtbl->Release(ctx->decoder); |
| 230 | ctx->decoder = NULL; |
| 231 | } |
| 232 | |
| 233 | av_buffer_unref(&ctx->device_ctx_ref); |
| 234 | av_packet_free(&ctx->in_pkt); |
| 235 | |
| 236 | return 0; |
| 237 | } |
| 238 | |
| 239 | static int amf_init_frames_context(AVCodecContext *avctx, int sw_format, int new_width, int new_height) |
| 240 | { |
no test coverage detected