diff options
author | Vittorio Giovara <vittorio.giovara@gmail.com> | 2015-03-11 20:43:58 +0000 |
---|---|---|
committer | Vittorio Giovara <vittorio.giovara@gmail.com> | 2015-03-13 19:47:47 +0000 |
commit | 117b432748ca87de4cd0f09d9b1495545e264733 (patch) | |
tree | 0542c2432120a0e973bcc1748a717f122787f97c /libavcodec/internal.h | |
parent | 9993a067f6c8c7e7838052ac3146aa6b80dd7e81 (diff) |
lavc: Introduce AVCodec internal capabilities
This field is designed for marking codec properties useful to lavc internals.
Two internal capabilities are added:
- FF_CODEC_CAP_INIT_THREADSAFE: codec can be opened without locks;
- FF_CODEC_CAP_INIT_CLEANUP: codec frees memory if initialization fails.
Diffstat (limited to 'libavcodec/internal.h')
-rw-r--r-- | libavcodec/internal.h | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/libavcodec/internal.h b/libavcodec/internal.h index a68d6134e3..a681329f20 100644 --- a/libavcodec/internal.h +++ b/libavcodec/internal.h @@ -33,6 +33,16 @@ #include "avcodec.h" #include "config.h" +/** + * Codec is thread safe. + */ +#define FF_CODEC_CAP_INIT_THREADSAFE (1 << 0) +/** + * Codec cleans up memory on init failure. + */ +#define FF_CODEC_CAP_INIT_CLEANUP (1 << 1) + + #define FF_SANE_NB_CHANNELS 63U #define FF_SIGNBIT(x) (x >> CHAR_BIT * sizeof(x) - 1) |