[vlc-devel] [PATCH] picture: init the plane table using the same size
Rémi Denis-Courmont
remi at remlab.net
Tue Apr 30 16:20:19 CEST 2019
Hi,
Uh, isn't the macro called ARRAY_SIZE? I'm surprised this even compiles (well, I have not tried).
Le 30 avril 2019 11:03:14 GMT+02:00, Steve Lhomme <robux4 at ycbcr.xyz> a écrit :
>And the table is using PICTURE_PLANE_MAX not VOUT_MAX_PLANES.
>---
> src/misc/picture.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
>diff --git a/src/misc/picture.c b/src/misc/picture.c
>index 46a2a069de..7ca4c6ac56 100644
>--- a/src/misc/picture.c
>+++ b/src/misc/picture.c
>@@ -114,7 +114,7 @@ int picture_Setup( picture_t *p_picture, const
>video_format_t *restrict fmt )
>
> /* Store default values */
> p_picture->i_planes = 0;
>- for( unsigned i = 0; i < VOUT_MAX_PLANES; i++ )
>+ for( unsigned i = 0; i < ARRAYSIZE(p_picture->p); i++ )
> {
> plane_t *p = &p_picture->p[i];
> p->p_pixels = NULL;
>--
>2.17.1
>
>_______________________________________________
>vlc-devel mailing list
>To unsubscribe or modify your subscription options:
>https://mailman.videolan.org/listinfo/vlc-devel
--
Envoyé de mon appareil Android avec Courriel K-9 Mail. Veuillez excuser ma brièveté.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mailman.videolan.org/pipermail/vlc-devel/attachments/20190430/e861fcd0/attachment.html>
More information about the vlc-devel
mailing list