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
df2aa222
Commit
df2aa222
authored
Jul 04, 2014
by
Luca Barbato
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
mov: Clarify tkhd flag settings
parent
f9072969
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
6 additions
and
3 deletions
+6
-3
movenc.c
libavformat/movenc.c
+6
-3
No files found.
libavformat/movenc.c
View file @
df2aa222
...
...
@@ -1465,8 +1465,10 @@ static int mov_write_tkhd_tag(AVIOContext *pb, MOVMuxContext *mov,
int64_t
duration
=
av_rescale_rnd
(
track
->
track_duration
,
MOV_TIMESCALE
,
track
->
timescale
,
AV_ROUND_UP
);
int
version
=
duration
<
INT32_MAX
?
0
:
1
;
int
flags
=
MOV_TKHD_FLAG_IN_MOVIE
;
int
group
=
0
;
if
(
st
)
{
if
(
mov
->
per_stream_grouping
)
group
=
st
->
index
;
...
...
@@ -1474,15 +1476,16 @@ static int mov_write_tkhd_tag(AVIOContext *pb, MOVMuxContext *mov,
group
=
st
->
codec
->
codec_type
;
}
if
(
track
->
flags
&
MOV_TRACK_ENABLED
)
flags
|=
MOV_TKHD_FLAG_ENABLED
;
if
(
track
->
mode
==
MODE_ISM
)
version
=
1
;
(
version
==
1
)
?
avio_wb32
(
pb
,
104
)
:
avio_wb32
(
pb
,
92
);
/* size */
ffio_wfourcc
(
pb
,
"tkhd"
);
avio_w8
(
pb
,
version
);
avio_wb24
(
pb
,
(
track
->
flags
&
MOV_TRACK_ENABLED
)
?
MOV_TKHD_FLAG_ENABLED
|
MOV_TKHD_FLAG_IN_MOVIE
:
MOV_TKHD_FLAG_IN_MOVIE
);
avio_wb24
(
pb
,
flags
);
if
(
version
==
1
)
{
avio_wb64
(
pb
,
track
->
time
);
avio_wb64
(
pb
,
track
->
time
);
...
...
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