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
77f326dc
Commit
77f326dc
authored
Jan 17, 2015
by
Michael Niedermayer
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
ffmpeg: Make CFR frame drop threshold user adjustable
Signed-off-by:
Michael Niedermayer
<
michaelni@gmx.at
>
parent
52f2adc0
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
7 additions
and
1 deletion
+7
-1
ffmpeg.c
ffmpeg.c
+3
-1
ffmpeg.h
ffmpeg.h
+1
-0
ffmpeg_opt.c
ffmpeg_opt.c
+3
-0
No files found.
ffmpeg.c
View file @
77f326dc
...
...
@@ -962,7 +962,9 @@ static void do_video_out(AVFormatContext *s,
}
case
VSYNC_CFR
:
// FIXME set to 0.5 after we fix some dts/pts bugs like in avidec.c
if
(
delta
<
-
1
.
1
)
if
(
frame_drop_threshold
&&
delta
<
frame_drop_threshold
&&
ost
->
frame_number
)
{
nb_frames
=
0
;
}
else
if
(
delta
<
-
1
.
1
)
nb_frames
=
0
;
else
if
(
delta
>
1
.
1
)
{
nb_frames
=
lrintf
(
delta
);
...
...
ffmpeg.h
View file @
77f326dc
...
...
@@ -482,6 +482,7 @@ extern float dts_error_threshold;
extern
int
audio_volume
;
extern
int
audio_sync_method
;
extern
int
video_sync_method
;
extern
float
frame_drop_threshold
;
extern
int
do_benchmark
;
extern
int
do_benchmark_all
;
extern
int
do_deinterlace
;
...
...
ffmpeg_opt.c
View file @
77f326dc
...
...
@@ -86,6 +86,7 @@ float dts_error_threshold = 3600*30;
int
audio_volume
=
256
;
int
audio_sync_method
=
0
;
int
video_sync_method
=
VSYNC_AUTO
;
float
frame_drop_threshold
=
0
;
int
do_deinterlace
=
0
;
int
do_benchmark
=
0
;
int
do_benchmark_all
=
0
;
...
...
@@ -2873,6 +2874,8 @@ const OptionDef options[] = {
"
\"
dv
\"
,
\"
dv50
\"
,
\"
pal-vcd
\"
,
\"
ntsc-svcd
\"
, ...)"
,
"type"
},
{
"vsync"
,
HAS_ARG
|
OPT_EXPERT
,
{
opt_vsync
},
"video sync method"
,
""
},
{
"frame_drop_threshold"
,
HAS_ARG
|
OPT_FLOAT
|
OPT_EXPERT
,
{
&
frame_drop_threshold
},
"frame drop threshold"
,
""
},
{
"async"
,
HAS_ARG
|
OPT_INT
|
OPT_EXPERT
,
{
&
audio_sync_method
},
"audio sync method"
,
""
},
{
"adrift_threshold"
,
HAS_ARG
|
OPT_FLOAT
|
OPT_EXPERT
,
{
&
audio_drift_threshold
},
...
...
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