[FFmpeg-devel] [PATCH 08/42] avcodec/dovi_rpu: Use RefStruct API for Vdr data

Anton Khirnov anton at khirnov.net
Mon Oct 2 12:51:25 EEST 2023


Quoting Andreas Rheinhardt (2023-09-19 21:57:00)
> It avoids allocations and the corresponding error checks.
> Also avoids casts and indirections.
> 
> Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt at outlook.com>
> ---
>  libavcodec/dovi_rpu.c | 54 ++++++++++++++++++-------------------------
>  libavcodec/dovi_rpu.h |  4 ++--
>  libavcodec/hevcdec.c  |  4 +---
>  3 files changed, 26 insertions(+), 36 deletions(-)
> 
> diff --git a/libavcodec/dovi_rpu.c b/libavcodec/dovi_rpu.c
> index dd38936552..794fa878a7 100644
> --- a/libavcodec/dovi_rpu.c
> +++ b/libavcodec/dovi_rpu.c
> @@ -26,6 +26,7 @@
>  #include "dovi_rpu.h"
>  #include "golomb.h"
>  #include "get_bits.h"
> +#include "refstruct.h"
>  
>  enum {
>      RPU_COEFF_FIXED = 0,
> @@ -35,15 +36,15 @@ enum {
>  /**
>   * Private contents of vdr_ref.

Should update the comment as well.

Otherwise looks good.

-- 
Anton Khirnov


More information about the ffmpeg-devel mailing list