From d7786b66bdd4b625765eb461ec286b846e94e9f2 Mon Sep 17 00:00:00 2001 From: Mark Thompson Date: Tue, 1 May 2018 00:18:16 +0100 Subject: cbs: Fragment/unit data is always reference counted Make this clear in the documentation and add some asserts to ensure that it is always true. --- libavcodec/cbs.h | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) (limited to 'libavcodec/cbs.h') diff --git a/libavcodec/cbs.h b/libavcodec/cbs.h index 402eb39e00..487358afaf 100644 --- a/libavcodec/cbs.h +++ b/libavcodec/cbs.h @@ -84,8 +84,9 @@ typedef struct CodedBitstreamUnit { */ size_t data_bit_padding; /** - * If data is reference counted, a reference to the buffer containing - * data. Null if data is not reference counted. + * A reference to the buffer containing data. + * + * Must be set if data is not NULL. */ AVBufferRef *data_ref; @@ -130,8 +131,9 @@ typedef struct CodedBitstreamFragment { */ size_t data_bit_padding; /** - * If data is reference counted, a reference to the buffer containing - * data. Null if data is not reference counted. + * A reference to the buffer containing data. + * + * Must be set if data is not NULL. */ AVBufferRef *data_ref; -- cgit v1.2.1