diff options
author | wm4 <nfxjfg@googlemail.com> | 2017-03-04 23:57:32 +0000 |
---|---|---|
committer | wm4 <nfxjfg@googlemail.com> | 2017-03-23 09:34:21 +0100 |
commit | 156bd8278f4098426cffaa68efb161907e5c1869 (patch) | |
tree | 5de1856a82ef4b69126dcc04c49e093078cdb2d9 /libavcodec/avcodec.h | |
parent | 30cadfe071ad353b60144d235a347a57ada7998c (diff) | |
download | ffmpeg-156bd8278f4098426cffaa68efb161907e5c1869.tar.gz |
lavc: Add hwaccel_flags field to AVCodecContext
This "reuses" the flags introduced for the av_vdpau_bind_context() API
function, and makes them available to all hwaccels. This does not affect
the current vdpau API, as av_vdpau_bind_context() should obviously
override the AVCodecContext.hwaccel_flags flags for the sake of
compatibility.
Cherry-picked from Libav commit 16a163b5.
Reviewed-by: Mark Thompson <sw@jkqxz.net>
Diffstat (limited to 'libavcodec/avcodec.h')
-rw-r--r-- | libavcodec/avcodec.h | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/libavcodec/avcodec.h b/libavcodec/avcodec.h index 3e3c37278a..b3479a7223 100644 --- a/libavcodec/avcodec.h +++ b/libavcodec/avcodec.h @@ -3620,6 +3620,15 @@ typedef struct AVCodecContext { * contexts used must be created on the same device. */ AVBufferRef *hw_device_ctx; + + /** + * Bit set of AV_HWACCEL_FLAG_* flags, which affect hardware accelerated + * decoding (if active). + * - encoding: unused + * - decoding: Set by user (either before avcodec_open2(), or in the + * AVCodecContext.get_format callback) + */ + int hwaccel_flags; } AVCodecContext; AVRational av_codec_get_pkt_timebase (const AVCodecContext *avctx); |