Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Contribute to GitLab
Sign in / Register
Toggle navigation
F
ffmpeg.wasm-core
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Linshizhi
ffmpeg.wasm-core
Commits
c9d982aa
Commit
c9d982aa
authored
Jul 22, 2014
by
Marc-Antoine Arnaud
Committed by
Luca Barbato
Jul 28, 2014
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
mxf: Detect Vanc/Vbi SMPTE-436M mxf track
Signed-off-by:
Luca Barbato
<
lu_zero@gentoo.org
>
parent
dc71f195
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
18 additions
and
0 deletions
+18
-0
mxfdec.c
libavformat/mxfdec.c
+18
-0
No files found.
libavformat/mxfdec.c
View file @
c9d982aa
...
...
@@ -971,6 +971,15 @@ static const MXFCodecUL mxf_sound_essence_container_uls[] = {
{
{
0x00
,
0x00
,
0x00
,
0x00
,
0x00
,
0x00
,
0x00
,
0x00
,
0x00
,
0x00
,
0x00
,
0x00
,
0x00
,
0x00
,
0x00
,
0x00
},
0
,
AV_CODEC_ID_NONE
},
};
static
const
MXFCodecUL
mxf_data_essence_container_uls
[]
=
{
{
{
0x06
,
0x0e
,
0x2b
,
0x34
,
0x04
,
0x01
,
0x01
,
0x09
,
0x0d
,
0x01
,
0x03
,
0x01
,
0x02
,
0x0e
,
0x00
,
0x00
},
16
,
0
},
{
{
0x06
,
0x0e
,
0x2b
,
0x34
,
0x04
,
0x01
,
0x01
,
0x09
,
0x0d
,
0x01
,
0x03
,
0x01
,
0x02
,
0x0e
,
0x00
,
0x00
},
16
,
AV_CODEC_ID_NONE
},
};
static
const
char
*
mxf_data_essence_descriptor
[]
=
{
"vbi_vanc_smpte_436M"
,
};
static
int
mxf_get_sorted_table_segments
(
MXFContext
*
mxf
,
int
*
nb_sorted_segments
,
MXFIndexTableSegment
***
sorted_segments
)
{
int
i
,
j
,
nb_segments
=
0
;
...
...
@@ -1618,6 +1627,14 @@ static int mxf_parse_structural_metadata(MXFContext *mxf)
}
else
if
(
st
->
codec
->
codec_id
==
AV_CODEC_ID_MP2
)
{
st
->
need_parsing
=
AVSTREAM_PARSE_FULL
;
}
}
else
if
(
st
->
codec
->
codec_type
==
AVMEDIA_TYPE_DATA
)
{
int
codec_id
=
mxf_get_codec_ul
(
mxf_data_essence_container_uls
,
essence_container_ul
)
->
id
;
if
(
codec_id
>=
0
&&
codec_id
<
FF_ARRAY_ELEMS
(
mxf_data_essence_descriptor
))
{
av_dict_set
(
&
st
->
metadata
,
"data_type"
,
mxf_data_essence_descriptor
[
codec_id
],
0
);
}
}
if
(
descriptor
->
extradata
)
{
st
->
codec
->
extradata
=
av_mallocz
(
descriptor
->
extradata_size
+
FF_INPUT_BUFFER_PADDING_SIZE
);
...
...
@@ -1790,6 +1807,7 @@ static const MXFMetadataReadTableEntry mxf_metadata_read_table[] = {
{
{
0x06
,
0x0e
,
0x2b
,
0x34
,
0x02
,
0x53
,
0x01
,
0x01
,
0x0d
,
0x01
,
0x01
,
0x01
,
0x01
,
0x01
,
0x51
,
0x00
},
mxf_read_generic_descriptor
,
sizeof
(
MXFDescriptor
),
Descriptor
},
/* MPEG 2 Video */
{
{
0x06
,
0x0e
,
0x2b
,
0x34
,
0x02
,
0x53
,
0x01
,
0x01
,
0x0d
,
0x01
,
0x01
,
0x01
,
0x01
,
0x01
,
0x48
,
0x00
},
mxf_read_generic_descriptor
,
sizeof
(
MXFDescriptor
),
Descriptor
},
/* Wave */
{
{
0x06
,
0x0e
,
0x2b
,
0x34
,
0x02
,
0x53
,
0x01
,
0x01
,
0x0d
,
0x01
,
0x01
,
0x01
,
0x01
,
0x01
,
0x47
,
0x00
},
mxf_read_generic_descriptor
,
sizeof
(
MXFDescriptor
),
Descriptor
},
/* AES3 */
{
{
0x06
,
0x0e
,
0x2b
,
0x34
,
0x02
,
0x53
,
0x01
,
0x01
,
0x0d
,
0x01
,
0x01
,
0x01
,
0x01
,
0x01
,
0x5c
,
0x00
},
mxf_read_generic_descriptor
,
sizeof
(
MXFDescriptor
),
Descriptor
},
/* VANC/VBI - SMPTE 436M */
{
{
0x06
,
0x0e
,
0x2b
,
0x34
,
0x02
,
0x53
,
0x01
,
0x01
,
0x0d
,
0x01
,
0x01
,
0x01
,
0x01
,
0x01
,
0x3A
,
0x00
},
mxf_read_track
,
sizeof
(
MXFTrack
),
Track
},
/* Static Track */
{
{
0x06
,
0x0e
,
0x2b
,
0x34
,
0x02
,
0x53
,
0x01
,
0x01
,
0x0d
,
0x01
,
0x01
,
0x01
,
0x01
,
0x01
,
0x3B
,
0x00
},
mxf_read_track
,
sizeof
(
MXFTrack
),
Track
},
/* Generic Track */
{
{
0x06
,
0x0e
,
0x2b
,
0x34
,
0x02
,
0x53
,
0x01
,
0x01
,
0x0d
,
0x01
,
0x04
,
0x01
,
0x02
,
0x02
,
0x00
,
0x00
},
mxf_read_cryptographic_context
,
sizeof
(
MXFCryptoContext
),
CryptoContext
},
...
...
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