| 1 | | Did you try |
| 2 | | |
| 3 | | {{{ |
| 4 | | diff --git a/libavcodec/nvdec.c b/libavcodec/nvdec.c |
| 5 | | index b60da24301..9b97d02a67 100644 |
| 6 | | --- a/libavcodec/nvdec.c |
| 7 | | +++ b/libavcodec/nvdec.c |
| 8 | | @@ -300,7 +300,7 @@ int ff_nvdec_decode_init(AVCodecContext *avctx) |
| 9 | | } |
| 10 | | chroma_444 = ctx->supports_444 && cuvid_chroma_format == cudaVideoChromaFormat_444; |
| 11 | | |
| 12 | | - if (!avctx->hw_frames_ctx) { |
| 13 | | + if (avctx->hw_frames_ctx) { |
| 14 | | ret = ff_decode_get_hw_frames_ctx(avctx, AV_HWDEVICE_TYPE_CUDA); |
| 15 | | if (ret < 0) |
| 16 | | return ret; |
| 17 | | }}} |
| 18 | | |
| | 1 | Did you try to change AVCodecContext::hw_frames_ctx |