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
b0d23ae2
Commit
b0d23ae2
authored
Aug 04, 2012
by
Stefano Sabatini
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
lavf/img2doc: document options
parent
b5c7318b
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
30 additions
and
7 deletions
+30
-7
demuxers.texi
doc/demuxers.texi
+25
-2
img2dec.c
libavformat/img2dec.c
+5
-5
No files found.
doc/demuxers.texi
View file @
b0d23ae2
...
...
@@ -34,8 +34,9 @@ specified in the pattern with the string "%%".
If the pattern contains "%d" or "%0@var{N}d", the first filename of
the file list specified by the pattern must contain a number
inclusively contained between 0 and 4, all the following numbers must
be sequential. This limitation may be hopefully fixed.
inclusively contained between @var{start_number} and
@var{start_number}+4, all the following numbers must be
sequential.
The pattern may contain a suffix which is used to automatically
determine the format of the images contained in the files.
...
...
@@ -49,6 +50,23 @@ sequence of filenames of the form @file{i%m%g-1.jpg},
The size, the pixel format, and the format of each image must be the
same for all the files in the sequence.
This demuxer accepts the following options:
@table @option
@item framerate
Set the framerate for the video stream. It defaults to 25.
@item loop
If set to 1, loop over the input. Default value is 0.
@item pixel_format
Set the pixel format of the images to read. If not specified the pixel
format is guessed from the first image file in the sequence.
@item start_number
Set the index of the file matched by the image file pattern to start
to read from. Default value is 0.
@item video_size
Set the video size of the images to read. If not specified the video
size is guessed from the first image file in the sequence.
@end table
The following example shows how to use @command{ffmpeg} for creating a
video from the images in the file sequence @file{img-001.jpeg},
@file{img-002.jpeg}, ..., assuming an input frame rate of 10 frames per
...
...
@@ -57,6 +75,11 @@ second:
ffmpeg -i 'img-%03d.jpeg' -r 10 out.mkv
@end example
As above, but start by reading from a file with index 100 in the sequence:
@example
ffmpeg -start_number 100 -i 'img-%03d.jpeg' -r 10 out.mkv
@end example
Note that the pattern must not necessarily contain "%d" or
"%0@var{N}d", for example to convert a single image file
@file{img.jpeg} you can employ the command:
...
...
libavformat/img2dec.c
View file @
b0d23ae2
...
...
@@ -387,11 +387,11 @@ static int read_close(struct AVFormatContext* s1)
#define OFFSET(x) offsetof(VideoDemuxData, x)
#define DEC AV_OPT_FLAG_DECODING_PARAM
static
const
AVOption
options
[]
=
{
{
"framerate"
,
"
"
,
OFFSET
(
framerate
),
AV_OPT_TYPE_STRING
,
{.
str
=
"25"
},
0
,
0
,
DEC
},
{
"loop"
,
""
,
OFFSET
(
loop
),
AV_OPT_TYPE_INT
,
{.
dbl
=
0
},
0
,
1
,
DEC
},
{
"pixel_format"
,
"
"
,
OFFSET
(
pixel_format
),
AV_OPT_TYPE_STRING
,
{.
str
=
NULL
},
0
,
0
,
DEC
},
{
"start_number"
,
"
first number in the sequence"
,
OFFSET
(
start_number
),
AV_OPT_TYPE_INT
,
{.
dbl
=
0
},
0
,
INT_MAX
,
DEC
},
{
"video_size"
,
"
"
,
OFFSET
(
video_size
),
AV_OPT_TYPE_STRING
,
{.
str
=
NULL
},
0
,
0
,
DEC
},
{
"framerate"
,
"
set the video framerate"
,
OFFSET
(
framerate
),
AV_OPT_TYPE_STRING
,
{.
str
=
"25"
},
0
,
0
,
DEC
},
{
"loop"
,
"
force loop over input file sequence
"
,
OFFSET
(
loop
),
AV_OPT_TYPE_INT
,
{.
dbl
=
0
},
0
,
1
,
DEC
},
{
"pixel_format"
,
"
set video pixel format"
,
OFFSET
(
pixel_format
),
AV_OPT_TYPE_STRING
,
{.
str
=
NULL
},
0
,
0
,
DEC
},
{
"start_number"
,
"
set first number in the sequence"
,
OFFSET
(
start_number
),
AV_OPT_TYPE_INT
,
{.
dbl
=
0
},
0
,
INT_MAX
,
DEC
},
{
"video_size"
,
"
set video size"
,
OFFSET
(
video_size
),
AV_OPT_TYPE_STRING
,
{.
str
=
NULL
},
0
,
0
,
DEC
},
{
NULL
},
};
...
...
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