[FFmpeg-devel] [PATCH] lavc/vvc: Add missing bounds for first subpic size

Nuo Mi nuomi2021 at gmail.com
Tue Nov 19 16:47:31 EET 2024


On Sun, Nov 17, 2024 at 8:28 PM Frank Plowman <post at frankplowman.com> wrote:

> Add missing upper bounds for the width and height of the first
> subpicture.  Corresponding bounds were added for all other subpictures
> in 01701bd, but were not included for the first subpicture (which has
> slightly different syntax).
>
Hi Frank,
Thank you for the patch.
I'll integrate it with some of my local changes and submit it for review
later this week.

>
> Signed-off-by: Frank Plowman <post at frankplowman.com>
> ---
>  libavcodec/cbs_h266_syntax_template.c | 4 ++--
>  1 file changed, 2 insertions(+), 2 deletions(-)
>
> diff --git a/libavcodec/cbs_h266_syntax_template.c
> b/libavcodec/cbs_h266_syntax_template.c
> index 6b2d6534ef..96704936ba 100644
> --- a/libavcodec/cbs_h266_syntax_template.c
> +++ b/libavcodec/cbs_h266_syntax_template.c
> @@ -1145,11 +1145,11 @@ static int FUNC(sps)(CodedBitstreamContext *ctx,
> RWContext *rw,
>              infer(sps_subpic_ctu_top_left_x[0], 0);
>              infer(sps_subpic_ctu_top_left_y[0], 0);
>              if (current->sps_pic_width_max_in_luma_samples > ctb_size_y)
> -                ubs(wlen, sps_subpic_width_minus1[0], 1, 0);
> +                us(wlen, sps_subpic_width_minus1[0], 0, tmp_width_val -
> 1, 1, 0);
>              else
>                  infer(sps_subpic_width_minus1[0], tmp_width_val - 1);
>              if (current->sps_pic_height_max_in_luma_samples > ctb_size_y)
> -                ubs(hlen, sps_subpic_height_minus1[0], 1, 0);
> +                us(hlen, sps_subpic_height_minus1[0], 0, tmp_height_val -
> 1, 1, 0);
>              else
>                  infer(sps_subpic_height_minus1[0], tmp_height_val - 1);
>              if (!current->sps_independent_subpics_flag) {
> --
> 2.47.0
>
> _______________________________________________
> ffmpeg-devel mailing list
> ffmpeg-devel at ffmpeg.org
> https://ffmpeg.org/mailman/listinfo/ffmpeg-devel
>
> To unsubscribe, visit link above, or email
> ffmpeg-devel-request at ffmpeg.org with subject "unsubscribe".
>


More information about the ffmpeg-devel mailing list