diff options
author | James Almer <jamrial@gmail.com> | 2020-06-01 11:22:01 -0300 |
---|---|---|
committer | James Almer <jamrial@gmail.com> | 2020-06-05 10:07:05 -0300 |
commit | b6c8444e2387d9a75b24d5ec1d8308fe6e37645b (patch) | |
tree | b53b4c3f9597e45319f23775f0f9958f2ccd2325 /libavutil/buffer_internal.h | |
parent | f2ad89beff2720b9659cee5d79667f6136f6b47a (diff) |
avutil/buffer: separate public and internal flags inside AVBuffers
It's better to not mix user provided flags and internal flags set by
AVBufferRef helper functions.
Signed-off-by: James Almer <jamrial@gmail.com>
Diffstat (limited to 'libavutil/buffer_internal.h')
-rw-r--r-- | libavutil/buffer_internal.h | 13 |
1 files changed, 7 insertions, 6 deletions
diff --git a/libavutil/buffer_internal.h b/libavutil/buffer_internal.h index 54b67047e5..70d2615a06 100644 --- a/libavutil/buffer_internal.h +++ b/libavutil/buffer_internal.h @@ -26,13 +26,9 @@ #include "thread.h" /** - * The buffer is always treated as read-only. - */ -#define BUFFER_FLAG_READONLY (1 << 0) -/** * The buffer was av_realloc()ed, so it is reallocatable. */ -#define BUFFER_FLAG_REALLOCATABLE (1 << 1) +#define BUFFER_FLAG_REALLOCATABLE (1 << 0) struct AVBuffer { uint8_t *data; /**< data described by this buffer */ @@ -54,9 +50,14 @@ struct AVBuffer { void *opaque; /** - * A combination of BUFFER_FLAG_* + * A combination of AV_BUFFER_FLAG_* */ int flags; + + /** + * A combination of BUFFER_FLAG_* + */ + int flags_internal; }; typedef struct BufferPoolEntry { |