[vlc-commits] packetizer: h264: fix next VCL NAL test

Francois Cartegnie git at videolan.org
Wed Jun 21 16:26:35 CEST 2017


vlc/vlc-2.2 | branch: master | Francois Cartegnie <fcvlcdev at free.fr> | Thu Apr 23 23:41:17 2015 +0200| [b05279a0d7d26ab809757e3f61ce384616936c0b] | committer: Hugo Beauzée-Luyssen

packetizer: h264: fix next VCL NAL test

According to ISO 14496-10 7.4.1.2.4,
next first NAL of next picture appears when
nal_ref_ids differs with one being equal to 0.

(cherry picked from commit 431812a1fdb400fe4d1051ca40575ce2b09ba535)
Signed-off-by: Hugo Beauzée-Luyssen <hugo at beauzee.fr>

> http://git.videolan.org/gitweb.cgi/vlc/vlc-2.2.git/?a=commit;h=b05279a0d7d26ab809757e3f61ce384616936c0b
---

 modules/packetizer/h264.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/modules/packetizer/h264.c b/modules/packetizer/h264.c
index ded600fb94..ed507ccd1d 100644
--- a/modules/packetizer/h264.c
+++ b/modules/packetizer/h264.c
@@ -1120,7 +1120,7 @@ static void ParseSlice( decoder_t *p_dec, bool *pb_new_picture, slice_t *p_slice
     if( slice.i_frame_num != p_sys->slice.i_frame_num ||
         slice.i_pic_parameter_set_id != p_sys->slice.i_pic_parameter_set_id ||
         slice.i_field_pic_flag != p_sys->slice.i_field_pic_flag ||
-        slice.i_nal_ref_idc != p_sys->slice.i_nal_ref_idc )
+        !slice.i_nal_ref_idc != !p_sys->slice.i_nal_ref_idc )
         b_pic = true;
     if( (slice.i_bottom_field_flag != -1) &&
         (p_sys->slice.i_bottom_field_flag != -1) &&



More information about the vlc-commits mailing list