Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
V
vlc
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Redmine
Redmine
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Operations
Operations
Metrics
Environments
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
videolan
vlc
Commits
1855ec49
Commit
1855ec49
authored
Jan 14, 2015
by
Francois Cartegnie
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
demux: libmp4: parse fiel extension atom
parent
94b41252
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
32 additions
and
0 deletions
+32
-0
modules/demux/mp4/libmp4.c
modules/demux/mp4/libmp4.c
+25
-0
modules/demux/mp4/libmp4.h
modules/demux/mp4/libmp4.h
+7
-0
No files found.
modules/demux/mp4/libmp4.c
View file @
1855ec49
...
@@ -1871,6 +1871,30 @@ static int MP4_ReadBox_dvc1( stream_t *p_stream, MP4_Box_t *p_box )
...
@@ -1871,6 +1871,30 @@ static int MP4_ReadBox_dvc1( stream_t *p_stream, MP4_Box_t *p_box )
MP4_READBOX_EXIT
(
1
);
MP4_READBOX_EXIT
(
1
);
}
}
static
int
MP4_ReadBox_fiel
(
stream_t
*
p_stream
,
MP4_Box_t
*
p_box
)
{
MP4_Box_data_fiel_t
*
p_fiel
;
MP4_READBOX_ENTER
(
MP4_Box_data_fiel_t
);
p_fiel
=
p_box
->
data
.
p_fiel
;
if
(
i_read
<
2
)
MP4_READBOX_EXIT
(
0
);
if
(
p_peek
[
0
]
==
2
)
/* Interlaced */
{
/*
* 0 – There is only one field.
* 1 – T is displayed earliest, T is stored first in the file.
* 6 – B is displayed earliest, B is stored first in the file.
* 9 – B is displayed earliest, T is stored first in the file.
* 14 – T is displayed earliest, B is stored first in the file.
*/
if
(
p_peek
[
1
]
==
1
||
p_peek
[
1
]
==
9
)
p_fiel
->
i_flags
=
BLOCK_FLAG_TOP_FIELD_FIRST
;
else
if
(
p_peek
[
1
]
==
6
||
p_peek
[
1
]
==
14
)
p_fiel
->
i_flags
=
BLOCK_FLAG_BOTTOM_FIELD_FIRST
;
}
MP4_READBOX_EXIT
(
1
);
}
static
int
MP4_ReadBox_enda
(
stream_t
*
p_stream
,
MP4_Box_t
*
p_box
)
static
int
MP4_ReadBox_enda
(
stream_t
*
p_stream
,
MP4_Box_t
*
p_box
)
{
{
MP4_Box_data_enda_t
*
p_enda
;
MP4_Box_data_enda_t
*
p_enda
;
...
@@ -3673,6 +3697,7 @@ static const struct
...
@@ -3673,6 +3697,7 @@ static const struct
{
ATOM_dac3
,
MP4_ReadBox_dac3
,
MP4_FreeBox_Common
,
0
},
{
ATOM_dac3
,
MP4_ReadBox_dac3
,
MP4_FreeBox_Common
,
0
},
{
ATOM_dec3
,
MP4_ReadBox_dec3
,
MP4_FreeBox_Common
,
0
},
{
ATOM_dec3
,
MP4_ReadBox_dec3
,
MP4_FreeBox_Common
,
0
},
{
ATOM_dvc1
,
MP4_ReadBox_dvc1
,
MP4_FreeBox_Common
,
0
},
{
ATOM_dvc1
,
MP4_ReadBox_dvc1
,
MP4_FreeBox_Common
,
0
},
{
ATOM_fiel
,
MP4_ReadBox_fiel
,
MP4_FreeBox_Common
,
0
},
{
ATOM_glbl
,
MP4_ReadBox_Binary
,
MP4_FreeBox_Binary
,
ATOM_FFV1
},
{
ATOM_glbl
,
MP4_ReadBox_Binary
,
MP4_FreeBox_Binary
,
ATOM_FFV1
},
{
ATOM_enda
,
MP4_ReadBox_enda
,
MP4_FreeBox_Common
,
0
},
{
ATOM_enda
,
MP4_ReadBox_enda
,
MP4_FreeBox_Common
,
0
},
{
ATOM_iods
,
MP4_ReadBox_iods
,
MP4_FreeBox_Common
,
0
},
{
ATOM_iods
,
MP4_ReadBox_iods
,
MP4_FreeBox_Common
,
0
},
...
...
modules/demux/mp4/libmp4.h
View file @
1855ec49
...
@@ -199,6 +199,7 @@
...
@@ -199,6 +199,7 @@
#define ATOM_avcC VLC_FOURCC( 'a', 'v', 'c', 'C' )
#define ATOM_avcC VLC_FOURCC( 'a', 'v', 'c', 'C' )
#define ATOM_m4ds VLC_FOURCC( 'm', '4', 'd', 's' )
#define ATOM_m4ds VLC_FOURCC( 'm', '4', 'd', 's' )
#define ATOM_fiel VLC_FOURCC( 'f', 'i', 'e', 'l' )
#define ATOM_glbl VLC_FOURCC( 'g', 'l', 'b', 'l' )
#define ATOM_glbl VLC_FOURCC( 'g', 'l', 'b', 'l' )
#define ATOM_hvcC VLC_FOURCC( 'h', 'v', 'c', 'C' )
#define ATOM_hvcC VLC_FOURCC( 'h', 'v', 'c', 'C' )
...
@@ -1224,6 +1225,11 @@ typedef struct
...
@@ -1224,6 +1225,11 @@ typedef struct
}
MP4_Box_data_dvc1_t
;
}
MP4_Box_data_dvc1_t
;
typedef
struct
{
uint32_t
i_flags
;
}
MP4_Box_data_fiel_t
;
typedef
struct
typedef
struct
{
{
uint16_t
i_little_endian
;
uint16_t
i_little_endian
;
...
@@ -1414,6 +1420,7 @@ typedef union MP4_Box_data_s
...
@@ -1414,6 +1420,7 @@ typedef union MP4_Box_data_s
MP4_Box_data_dac3_t
*
p_dac3
;
MP4_Box_data_dac3_t
*
p_dac3
;
MP4_Box_data_dec3_t
*
p_dec3
;
MP4_Box_data_dec3_t
*
p_dec3
;
MP4_Box_data_dvc1_t
*
p_dvc1
;
MP4_Box_data_dvc1_t
*
p_dvc1
;
MP4_Box_data_fiel_t
*
p_fiel
;
MP4_Box_data_chan_t
*
p_chan
;
MP4_Box_data_chan_t
*
p_chan
;
MP4_Box_data_enda_t
*
p_enda
;
MP4_Box_data_enda_t
*
p_enda
;
MP4_Box_data_keys_t
*
p_keys
;
MP4_Box_data_keys_t
*
p_keys
;
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment