diff options
Diffstat (limited to 'libavcodec/decode.h')
-rw-r--r-- | libavcodec/decode.h | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/libavcodec/decode.h b/libavcodec/decode.h index 235f355..37b2e45 100644 --- a/libavcodec/decode.h +++ b/libavcodec/decode.h @@ -23,6 +23,7 @@ #include "libavutil/buffer.h" #include "libavutil/frame.h" +#include "libavutil/hwcontext.h" #include "avcodec.h" @@ -70,4 +71,12 @@ int ff_decode_get_packet(AVCodecContext *avctx, AVPacket *pkt); void ff_decode_bsfs_uninit(AVCodecContext *avctx); +/** + * Make sure avctx.hw_frames_ctx is set. If it's not set, the function will + * try to allocate it from hw_device_ctx. If that is not possible, an error + * message is printed, and an error code is returned. + */ +int ff_decode_get_hw_frames_ctx(AVCodecContext *avctx, + enum AVHWDeviceType dev_type); + #endif /* AVCODEC_DECODE_H */ |