[vlc-commits] demux: mp4: fix naming of objectProfileIndication
Francois Cartegnie
git at videolan.org
Mon Sep 29 15:48:54 CEST 2014
vlc | branch: master | Francois Cartegnie <fcvlcdev at free.fr> | Mon Sep 29 15:35:55 2014 +0200| [01f05de90bd3e4dbb735c6408e39e2ffc2dc25f0] | committer: Francois Cartegnie
demux: mp4: fix naming of objectProfileIndication
> http://git.videolan.org/gitweb.cgi/vlc.git/?a=commit;h=01f05de90bd3e4dbb735c6408e39e2ffc2dc25f0
---
modules/demux/mp4/libmp4.c | 8 ++++----
modules/demux/mp4/libmp4.h | 2 +-
modules/demux/mp4/mp4.c | 8 +++++---
3 files changed, 10 insertions(+), 8 deletions(-)
diff --git a/modules/demux/mp4/libmp4.c b/modules/demux/mp4/libmp4.c
index 064f6f5..b6cf91c 100644
--- a/modules/demux/mp4/libmp4.c
+++ b/modules/demux/mp4/libmp4.c
@@ -1212,7 +1212,7 @@ static int MP4_ReadBox_esds( stream_t *p_stream, MP4_Box_t *p_box )
MP4_GET1BYTE( i_type );
- if( i_type == 0x03 ) /* MP4ESDescrTag */
+ if( i_type == 0x03 ) /* MP4ESDescrTag ISO/IEC 14496-1 8.3.3 */
{
i_len = MP4_ReadLengthDescriptor( &p_peek, &i_read );
@@ -1258,7 +1258,7 @@ static int MP4_ReadBox_esds( stream_t *p_stream, MP4_Box_t *p_box )
MP4_GET1BYTE( i_type ); /* get next type */
}
- if( i_type != 0x04)/* MP4DecConfigDescrTag */
+ if( i_type != 0x04)/* MP4DecConfigDescrTag ISO/IEC 14496-1 8.3.4 */
{
es_descriptor.p_decConfigDescr = NULL;
MP4_READBOX_EXIT( 1 ); /* rest isn't interesting up to now */
@@ -1276,7 +1276,7 @@ static int MP4_ReadBox_esds( stream_t *p_stream, MP4_Box_t *p_box )
if( unlikely( es_descriptor.p_decConfigDescr == NULL ) )
MP4_READBOX_EXIT( 0 );
- MP4_GET1BYTE( es_descriptor.p_decConfigDescr->i_objectTypeIndication );
+ MP4_GET1BYTE( es_descriptor.p_decConfigDescr->i_objectProfileIndication );
MP4_GET1BYTE( i_flags );
es_descriptor.p_decConfigDescr->i_streamType = i_flags >> 2;
es_descriptor.p_decConfigDescr->b_upStream = ( i_flags >> 1 )&0x01;
@@ -1284,7 +1284,7 @@ static int MP4_ReadBox_esds( stream_t *p_stream, MP4_Box_t *p_box )
MP4_GET4BYTES( es_descriptor.p_decConfigDescr->i_max_bitrate );
MP4_GET4BYTES( es_descriptor.p_decConfigDescr->i_avg_bitrate );
MP4_GET1BYTE( i_type );
- if( i_type != 0x05 )/* MP4DecSpecificDescrTag */
+ if( i_type != 0x05 )/* MP4DecSpecificDescrTag ISO/IEC 14496-1 8.3.5 */
{
es_descriptor.p_decConfigDescr->i_decoder_specific_info_len = 0;
es_descriptor.p_decConfigDescr->p_decoder_specific_info = NULL;
diff --git a/modules/demux/mp4/libmp4.h b/modules/demux/mp4/libmp4.h
index 683b677..643e922 100644
--- a/modules/demux/mp4/libmp4.h
+++ b/modules/demux/mp4/libmp4.h
@@ -766,7 +766,7 @@ typedef struct MP4_Box_data_cprt_s
/* DecoderConfigDescriptor */
typedef struct MP4_descriptor_decoder_config_s
{
- uint8_t i_objectTypeIndication;
+ uint8_t i_objectProfileIndication;
uint8_t i_streamType;
int b_upStream;
int i_buffer_sizeDB;
diff --git a/modules/demux/mp4/mp4.c b/modules/demux/mp4/mp4.c
index a146de7..42c718d 100644
--- a/modules/demux/mp4/mp4.c
+++ b/modules/demux/mp4/mp4.c
@@ -2709,6 +2709,8 @@ static int TrackCreateES( demux_t *p_demux, mp4_track_t *p_track,
/* now see if esds is present and if so create a data packet
with decoder_specific_info */
+
+ /* Only if MP4V */
#define p_decconfig p_esds->data.p_esds->es_descriptor.p_decConfigDescr
if( ( ( p_esds = MP4_BoxGet( p_sample, "esds" ) ) ||
( p_esds = MP4_BoxGet( p_sample, "wave/esds" ) ) )&&
@@ -2716,7 +2718,7 @@ static int TrackCreateES( demux_t *p_demux, mp4_track_t *p_track,
( p_decconfig ) )
{
/* First update information based on i_objectTypeIndication */
- switch( p_decconfig->i_objectTypeIndication )
+ switch( p_decconfig->i_objectProfileIndication )
{
case( 0x20 ): /* MPEG4 VIDEO */
p_track->fmt.i_codec = VLC_CODEC_MP4V;
@@ -2809,8 +2811,8 @@ static int TrackCreateES( demux_t *p_demux, mp4_track_t *p_track,
default:
/* Unknown entry, but don't touch i_fourcc */
msg_Warn( p_demux,
- "unknown objectTypeIndication(0x%x) (Track[ID 0x%x])",
- p_decconfig->i_objectTypeIndication,
+ "unknown objectProfileIndication(0x%x) (Track[ID 0x%x])",
+ p_decconfig->i_objectProfileIndication,
p_track->i_track_ID );
break;
}
More information about the vlc-commits
mailing list