[vlc-devel] [PATCH 2/9] core: add 3D stereo information to video_format_t
Rémi Denis-Courmont
remi at remlab.net
Fri Aug 8 20:25:47 CEST 2014
Le vendredi 8 août 2014, 20:13:27 Felix Abecassis a écrit :
> ---
> include/vlc_es.h | 3 +++
> src/input/decoder.c | 3 ++-
> src/misc/es_format.c | 3 +++
> 3 files changed, 8 insertions(+), 1 deletion(-)
>
> diff --git a/include/vlc_es.h b/include/vlc_es.h
> index 5790d23..2fbf254 100644
> --- a/include/vlc_es.h
> +++ b/include/vlc_es.h
> @@ -26,6 +26,7 @@
>
> #include <vlc_fourcc.h>
> #include <vlc_text_style.h>
> +#include <vlc_stereo3d.h>
>
> /**
> * \file
> @@ -219,6 +220,8 @@ struct video_format_t
> int i_rbshift, i_lbshift;
> video_palette_t *p_palette; /**< video palette from
> demuxer */ video_orientation_t orientation; /**< picture
> orientation */ +
> + stereo3d_format_t stereo_format;
_format seems a bit redundant in there.
> };
>
> /**
> diff --git a/src/input/decoder.c b/src/input/decoder.c
> index 87c65ef..db7d28d 100644
> --- a/src/input/decoder.c
> +++ b/src/input/decoder.c
> @@ -2052,7 +2052,8 @@ static picture_t *vout_new_buffer( decoder_t *p_dec )
> p_dec->fmt_out.i_codec != p_owner->video.i_chroma ||
> (int64_t)p_dec->fmt_out.video.i_sar_num * p_owner->video.i_sar_den
> != (int64_t)p_dec->fmt_out.video.i_sar_den * p_owner->video.i_sar_num || -
> p_dec->fmt_out.video.orientation != p_owner->video.orientation ) +
> p_dec->fmt_out.video.orientation != p_owner->video.orientation || +
> p_dec->fmt_out.video.stereo_format.mode !=
> p_owner->video.stereo_format.mode) {
> vout_thread_t *p_vout;
>
> diff --git a/src/misc/es_format.c b/src/misc/es_format.c
> index 27622bc..69bab7f 100644
> --- a/src/misc/es_format.c
> +++ b/src/misc/es_format.c
> @@ -392,6 +392,9 @@ bool video_format_IsSimilar( const video_format_t
> *p_fmt1, const video_format_t if( v1.orientation != v2.orientation)
> return false;
>
> + if( v1.stereo_format.mode != v2.stereo_format.mode )
> + return false;
> +
> if( v1.i_chroma == VLC_CODEC_RGB15 ||
> v1.i_chroma == VLC_CODEC_RGB16 ||
> v1.i_chroma == VLC_CODEC_RGB24 ||
--
Rémi Denis-Courmont
http://www.remlab.net/
More information about the vlc-devel
mailing list