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
9ca7ad24
Commit
9ca7ad24
authored
Jul 07, 2018
by
James Almer
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
avformat/mov: add support for AV1 streams
Signed-off-by:
James Almer
<
jamrial@gmail.com
>
parent
a754af94
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
32 additions
and
0 deletions
+32
-0
isom.c
libavformat/isom.c
+1
-0
mov.c
libavformat/mov.c
+31
-0
No files found.
libavformat/isom.c
View file @
9ca7ad24
...
...
@@ -188,6 +188,7 @@ const AVCodecTag ff_codec_movvideo_tags[] = {
{
AV_CODEC_ID_VP8
,
MKTAG
(
'v'
,
'p'
,
'0'
,
'8'
)
},
/* VP8 */
{
AV_CODEC_ID_VP9
,
MKTAG
(
'v'
,
'p'
,
'0'
,
'9'
)
},
/* VP9 */
{
AV_CODEC_ID_AV1
,
MKTAG
(
'a'
,
'v'
,
'0'
,
'1'
)
},
/* AV1 */
{
AV_CODEC_ID_MPEG1VIDEO
,
MKTAG
(
'm'
,
'1'
,
'v'
,
' '
)
},
{
AV_CODEC_ID_MPEG1VIDEO
,
MKTAG
(
'm'
,
'1'
,
'v'
,
'1'
)
},
/* Apple MPEG-1 Camcorder */
...
...
libavformat/mov.c
View file @
9ca7ad24
...
...
@@ -5185,6 +5185,36 @@ static int mov_read_tmcd(MOVContext *c, AVIOContext *pb, MOVAtom atom)
return
0
;
}
static
int
mov_read_av1c
(
MOVContext
*
c
,
AVIOContext
*
pb
,
MOVAtom
atom
)
{
AVStream
*
st
;
int
ret
,
version
;
if
(
c
->
fc
->
nb_streams
<
1
)
return
0
;
st
=
c
->
fc
->
streams
[
c
->
fc
->
nb_streams
-
1
];
if
(
atom
.
size
<
5
)
{
av_log
(
c
->
fc
,
AV_LOG_ERROR
,
"Empty AV1 Codec Configuration Box
\n
"
);
return
AVERROR_INVALIDDATA
;
}
version
=
avio_r8
(
pb
);
if
(
version
!=
0
)
{
av_log
(
c
->
fc
,
AV_LOG_WARNING
,
"Unknown AV1 Codec Configuration Box version %d
\n
"
,
version
);
return
0
;
}
avio_skip
(
pb
,
3
);
/* flags */
avio_skip
(
pb
,
1
);
/* reserved, initial_presentation_delay_present, initial_presentation_delay_minus_one */
ret
=
ff_get_extradata
(
c
->
fc
,
st
->
codecpar
,
pb
,
atom
.
size
-
5
);
if
(
ret
<
0
)
return
ret
;
return
0
;
}
static
int
mov_read_vpcc
(
MOVContext
*
c
,
AVIOContext
*
pb
,
MOVAtom
atom
)
{
AVStream
*
st
;
...
...
@@ -6622,6 +6652,7 @@ static const MOVParseTableEntry mov_default_parse_table[] = {
{
MKTAG
(
'A'
,
'A'
,
'L'
,
'P'
),
mov_read_avid
},
{
MKTAG
(
'A'
,
'R'
,
'E'
,
'S'
),
mov_read_ares
},
{
MKTAG
(
'a'
,
'v'
,
's'
,
's'
),
mov_read_avss
},
{
MKTAG
(
'a'
,
'v'
,
'1'
,
'C'
),
mov_read_av1c
},
{
MKTAG
(
'c'
,
'h'
,
'p'
,
'l'
),
mov_read_chpl
},
{
MKTAG
(
'c'
,
'o'
,
'6'
,
'4'
),
mov_read_stco
},
{
MKTAG
(
'c'
,
'o'
,
'l'
,
'r'
),
mov_read_colr
},
...
...
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