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
7ca60994
Commit
7ca60994
authored
Nov 30, 2004
by
Michael Niedermayer
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
max frames command line options
Originally committed as revision 3722 to
svn://svn.ffmpeg.org/ffmpeg/trunk
parent
42dd22c4
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
9 additions
and
0 deletions
+9
-0
ffmpeg.c
ffmpeg.c
+9
-0
No files found.
ffmpeg.c
View file @
7ca60994
...
@@ -96,6 +96,7 @@ static int frame_topBand = 0;
...
@@ -96,6 +96,7 @@ static int frame_topBand = 0;
static
int
frame_bottomBand
=
0
;
static
int
frame_bottomBand
=
0
;
static
int
frame_leftBand
=
0
;
static
int
frame_leftBand
=
0
;
static
int
frame_rightBand
=
0
;
static
int
frame_rightBand
=
0
;
static
int
max_frames
[
3
]
=
{
INT_MAX
,
INT_MAX
,
INT_MAX
};
static
int
frame_rate
=
25
;
static
int
frame_rate
=
25
;
static
int
frame_rate_base
=
1
;
static
int
frame_rate_base
=
1
;
static
int
video_bit_rate
=
200
*
1000
;
static
int
video_bit_rate
=
200
*
1000
;
...
@@ -711,6 +712,7 @@ static void do_video_out(AVFormatContext *s,
...
@@ -711,6 +712,7 @@ static void do_video_out(AVFormatContext *s,
}
else
}
else
ost
->
sync_opts
=
lrintf
(
ost
->
sync_ipts
*
enc
->
frame_rate
/
enc
->
frame_rate_base
);
ost
->
sync_opts
=
lrintf
(
ost
->
sync_ipts
*
enc
->
frame_rate
/
enc
->
frame_rate_base
);
nb_frames
=
FFMIN
(
nb_frames
,
max_frames
[
CODEC_TYPE_VIDEO
]
-
ost
->
frame_number
);
if
(
nb_frames
<=
0
)
if
(
nb_frames
<=
0
)
return
;
return
;
...
@@ -1838,6 +1840,10 @@ static int av_encode(AVFormatContext **output_files,
...
@@ -1838,6 +1840,10 @@ static int av_encode(AVFormatContext **output_files,
if
(
!
input_sync
)
file_index
=
ist
->
file_index
;
if
(
!
input_sync
)
file_index
=
ist
->
file_index
;
}
}
}
}
if
(
ost
->
frame_number
>=
max_frames
[
ost
->
st
->
codec
.
codec_type
]){
file_index
=
-
1
;
break
;
}
}
}
/* if none, if is finished */
/* if none, if is finished */
if
(
file_index
<
0
)
{
if
(
file_index
<
0
)
{
...
@@ -3827,6 +3833,9 @@ const OptionDef options[] = {
...
@@ -3827,6 +3833,9 @@ const OptionDef options[] = {
/* video options */
/* video options */
{
"b"
,
HAS_ARG
|
OPT_VIDEO
,
{(
void
*
)
opt_video_bitrate
},
"set video bitrate (in kbit/s)"
,
"bitrate"
},
{
"b"
,
HAS_ARG
|
OPT_VIDEO
,
{(
void
*
)
opt_video_bitrate
},
"set video bitrate (in kbit/s)"
,
"bitrate"
},
{
"vframes"
,
OPT_INT
|
HAS_ARG
|
OPT_VIDEO
,
{(
void
*
)
&
max_frames
[
CODEC_TYPE_VIDEO
]},
"set the number of video frames to record"
,
"number"
},
{
"aframes"
,
OPT_INT
|
HAS_ARG
|
OPT_AUDIO
,
{(
void
*
)
&
max_frames
[
CODEC_TYPE_AUDIO
]},
"set the number of audio frames to record"
,
"number"
},
{
"dframes"
,
OPT_INT
|
HAS_ARG
,
{(
void
*
)
&
max_frames
[
CODEC_TYPE_DATA
]},
"set the number of data frames to record"
,
"number"
},
{
"r"
,
HAS_ARG
|
OPT_VIDEO
,
{(
void
*
)
opt_frame_rate
},
"set frame rate (Hz value, fraction or abbreviation)"
,
"rate"
},
{
"r"
,
HAS_ARG
|
OPT_VIDEO
,
{(
void
*
)
opt_frame_rate
},
"set frame rate (Hz value, fraction or abbreviation)"
,
"rate"
},
{
"s"
,
HAS_ARG
|
OPT_VIDEO
,
{(
void
*
)
opt_frame_size
},
"set frame size (WxH or abbreviation)"
,
"size"
},
{
"s"
,
HAS_ARG
|
OPT_VIDEO
,
{(
void
*
)
opt_frame_size
},
"set frame size (WxH or abbreviation)"
,
"size"
},
{
"aspect"
,
HAS_ARG
|
OPT_VIDEO
,
{(
void
*
)
opt_frame_aspect_ratio
},
"set aspect ratio (4:3, 16:9 or 1.3333, 1.7777)"
,
"aspect"
},
{
"aspect"
,
HAS_ARG
|
OPT_VIDEO
,
{(
void
*
)
opt_frame_aspect_ratio
},
"set aspect ratio (4:3, 16:9 or 1.3333, 1.7777)"
,
"aspect"
},
...
...
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