[vlc-commits] [Git][videolan/vlc][3.0.x] picture: align picture width to 64

Rémi Denis-Courmont (@Courmisch) gitlab at videolan.org
Wed Oct 12 15:22:55 UTC 2022



Rémi Denis-Courmont pushed to branch 3.0.x at VideoLAN / VLC


Commits:
ad26d63a by Steve Lhomme at 2022-10-12T15:08:12+00:00
picture: align picture width to 64

It seems the latest FFmpeg requires 64 bits alignment for some I420 output.

Fixes #27285

(cherry picked from commit fa75a43b0bb9b2997fda7006b6a83d697ecd6c89)

Signed-off-by: Steve Lhomme <robux4 at ycbcr.xyz>

- - - - -


1 changed file:

- src/misc/picture.c


Changes:

=====================================
src/misc/picture.c
=====================================
@@ -178,7 +178,7 @@ int picture_Setup( picture_t *p_picture, const video_format_t *restrict fmt )
     unsigned int i_ratio_h  = 1;
     for( unsigned i = 0; i < p_dsc->plane_count; i++ )
     {
-        i_modulo_w = LCM( i_modulo_w, 16 * p_dsc->p[i].w.den );
+        i_modulo_w = LCM( i_modulo_w, 64 * p_dsc->p[i].w.den );
         i_modulo_h = LCM( i_modulo_h, 16 * p_dsc->p[i].h.den );
         if( i_ratio_h < p_dsc->p[i].h.den )
             i_ratio_h = p_dsc->p[i].h.den;
@@ -198,7 +198,7 @@ int picture_Setup( picture_t *p_picture, const video_format_t *restrict fmt )
         p->i_visible_pitch = (fmt->i_visible_width + (p_dsc->p[i].w.den - 1)) / p_dsc->p[i].w.den * p_dsc->p[i].w.num * p_dsc->pixel_size;
         p->i_pixel_pitch   = p_dsc->pixel_size;
 
-        assert( (p->i_pitch % 16) == 0 );
+        assert( (p->i_pitch % 64) == 0 );
     }
     p_picture->i_planes  = p_dsc->plane_count;
 



View it on GitLab: https://code.videolan.org/videolan/vlc/-/commit/ad26d63aa48f0da1b67a8caf565a5e808b06f0d1

-- 
View it on GitLab: https://code.videolan.org/videolan/vlc/-/commit/ad26d63aa48f0da1b67a8caf565a5e808b06f0d1
You're receiving this email because of your account on code.videolan.org.


VideoLAN code repository instance


More information about the vlc-commits mailing list