[vlc-commits] codec: videotoolbox: with avcC playback with nal_length_size != 4

Thomas Guillem git at videolan.org
Mon Oct 2 13:25:31 CEST 2017


vlc | branch: master | Thomas Guillem <thomas at gllm.fr> | Mon Oct  2 13:20:24 2017 +0200| [c6ce03f5cb156743d3e62c0b8e7718a525a90378] | committer: Thomas Guillem

codec: videotoolbox: with avcC playback with nal_length_size != 4

Fixes #18876

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

 modules/codec/videotoolbox.m | 5 +++--
 1 file changed, 3 insertions(+), 2 deletions(-)

diff --git a/modules/codec/videotoolbox.m b/modules/codec/videotoolbox.m
index c0e9b4cc0a..2c48981389 100644
--- a/modules/codec/videotoolbox.m
+++ b/modules/codec/videotoolbox.m
@@ -399,8 +399,9 @@ static frame_info_t * CreateReorderInfo(decoder_t *p_dec, const block_t *p_block
 
     if (p_sys->b_poc_based_reorder)
     {
-        if(p_sys->codec != kCMVideoCodecType_H264 ||
-           !ParseH264NAL(p_dec, p_block->p_buffer, p_block->i_buffer, 4, p_info))
+        if (p_sys->codec != kCMVideoCodecType_H264 ||
+            !ParseH264NAL(p_dec, p_block->p_buffer, p_block->i_buffer,
+                          p_sys->hh.i_nal_length_size , p_info))
         {
             assert(p_sys->codec == kCMVideoCodecType_H264);
             free(p_info);



More information about the vlc-commits mailing list