summaryrefslogtreecommitdiff
path: root/libavutil/buffer_internal.h
diff options
context:
space:
mode:
authorAnton Khirnov <anton@khirnov.net>2022-08-04 10:16:51 +0200
committerAnton Khirnov <anton@khirnov.net>2022-08-04 10:16:51 +0200
commitd17953b287e0fa9d61c9aada7e36c03403b2fd69 (patch)
treebbc363a8db9cb0314d46c3e2e7aa1804a2e5430e /libavutil/buffer_internal.h
parent4c9009dd1b6fa98200d859df3a0a0ea7aa7e3ffc (diff)
lavu/buffer: convert to AVRefcount WIPrefcount
Diffstat (limited to 'libavutil/buffer_internal.h')
-rw-r--r--libavutil/buffer_internal.h5
1 files changed, 4 insertions, 1 deletions
diff --git a/libavutil/buffer_internal.h b/libavutil/buffer_internal.h
index adb916aaa2..29119b47ab 100644
--- a/libavutil/buffer_internal.h
+++ b/libavutil/buffer_internal.h
@@ -23,6 +23,7 @@
#include <stdint.h>
#include "buffer.h"
+#include "refcount.h"
#include "thread.h"
/**
@@ -39,6 +40,8 @@ struct AVBuffer {
uint8_t *data; /**< data described by this buffer */
size_t size; /**< size of data in bytes */
+ AVRefcount rc;
+
/**
* number of existing AVBufferRef instances referring to this buffer
*/
@@ -98,7 +101,7 @@ struct AVBufferPool {
* buffers have been released, then it's safe to free the pool and all
* the buffers in it.
*/
- atomic_uint refcount;
+ AVRefcount rc;
size_t size;
void *opaque;