[vlc-commits] packetizer: hevc: don't expect specific NAL for IFrames (fix #21289)
Francois Cartegnie
git at videolan.org
Tue Oct 9 12:00:44 CEST 2018
vlc | branch: master | Francois Cartegnie <fcvlcdev at free.fr> | Tue Oct 9 11:57:56 2018 +0200| [eb89ac907209be7c4bd57cb18b94e1059fd71e90] | committer: Francois Cartegnie
packetizer: hevc: don't expect specific NAL for IFrames (fix #21289)
> http://git.videolan.org/gitweb.cgi/vlc.git/?a=commit;h=eb89ac907209be7c4bd57cb18b94e1059fd71e90
---
modules/packetizer/hevc.c | 16 ++++++++++++----
1 file changed, 12 insertions(+), 4 deletions(-)
diff --git a/modules/packetizer/hevc.c b/modules/packetizer/hevc.c
index 320c57df8e..aff8de39f4 100644
--- a/modules/packetizer/hevc.c
+++ b/modules/packetizer/hevc.c
@@ -682,10 +682,18 @@ static block_t *ParseVCL(decoder_t *p_dec, uint8_t i_nal_type, block_t *p_frag)
enum hevc_slice_type_e type;
if(hevc_get_slice_type( p_sli, &type ))
{
- if( type == HEVC_SLICE_TYPE_P )
- p_frag->i_flags |= BLOCK_FLAG_TYPE_P;
- else
- p_frag->i_flags |= BLOCK_FLAG_TYPE_B;
+ switch(type)
+ {
+ case HEVC_SLICE_TYPE_B:
+ p_frag->i_flags |= BLOCK_FLAG_TYPE_B;
+ break;
+ case HEVC_SLICE_TYPE_P:
+ p_frag->i_flags |= BLOCK_FLAG_TYPE_P;
+ break;
+ case HEVC_SLICE_TYPE_I:
+ p_frag->i_flags |= BLOCK_FLAG_TYPE_I;
+ break;
+ }
}
}
else p_frag->i_flags |= BLOCK_FLAG_TYPE_B;
More information about the vlc-commits
mailing list