[vlc-devel] [PATCH] picture: move the multiview left eye flag in the pictures

Rémi Denis-Courmont remi at remlab.net
Fri Oct 23 17:01:45 CEST 2020


Le perjantaina 23. lokakuuta 2020, 7.50.35 EEST Steve Lhomme a écrit :
> On 2020-10-22 17:25, Rémi Denis-Courmont wrote:
> > Le torstaina 22. lokakuuta 2020, 11.18.40 EEST Steve Lhomme a écrit :
> >> This flag flips on every picture. It should be set in the video_format_t
> >> should be stable when only this value changes.
> >> ---
> >> 
> >>   include/vlc_es.h              | 1 -
> >>   include/vlc_picture.h         | 1 +
> >>   modules/codec/avcodec/video.c | 2 +-
> >>   3 files changed, 2 insertions(+), 2 deletions(-)
> >> 
> >> diff --git a/include/vlc_es.h b/include/vlc_es.h
> >> index 841fa05bf60..404a937d833 100644
> >> --- a/include/vlc_es.h
> >> +++ b/include/vlc_es.h
> >> @@ -375,7 +375,6 @@ struct video_format_t
> >> 
> >>       video_multiview_mode_t multiview_mode;        /** Multiview mode,
> >>       2D,
> >> 
> >> 3D */ bool b_multiview_right_eye_first;   /** Multiview left or right eye
> >> first*/ -    bool b_multiview_left_eye;
> >> 
> >>       video_projection_mode_t projection_mode;            /**< projection
> >> 
> >> mode */ vlc_viewpoint_t pose;
> >> diff --git a/include/vlc_picture.h b/include/vlc_picture.h
> >> index 280471db953..9fa7b46911d 100644
> >> --- a/include/vlc_picture.h
> >> +++ b/include/vlc_picture.h
> >> @@ -146,6 +146,7 @@ struct picture_t
> >> 
> >>        * Those properties can be changed by the decoder
> >>        * @{
> >>        */
> >> 
> >> +    bool            b_multiview_left_eye; /**< left eye or right eye in
> >> multiview */ bool            b_progressive;          /**< is it a
> >> progressive frame? */ bool            b_top_field_first;             /**<
> >> which field is first */ unsigned int    i_nb_fields;                 
> >> /**<
> >> number of displayed fields */
> > 
> > I would add it after the existing booleans to avoid gratuitious ABI
> > breaks.
> 
> If bool was a bitfield that could make a difference but it is not. So
> unless it's put at the very end of the structure, the ABI breakage is
> unavoidable.

In this case, there are two other booleans above that were not visible in the 
diff. So yeah, the ABI is broken anyway, nevermind.

-- 
レミ・デニ-クールモン
http://www.remlab.net/





More information about the vlc-devel mailing list