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
0bf02fb1
Commit
0bf02fb1
authored
Jul 02, 2011
by
Stefano Sabatini
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
vf_pad: add support for a "sar" variable
Also add a "dar" alias for "a", for avoiding confusion with sar/dar.
parent
01151a26
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
12 additions
and
5 deletions
+12
-5
filters.texi
doc/filters.texi
+4
-1
avfilter.h
libavfilter/avfilter.h
+1
-1
vf_pad.c
libavfilter/vf_pad.c
+7
-3
No files found.
doc/filters.texi
View file @
0bf02fb1
...
...
@@ -1129,9 +1129,12 @@ same as @var{out_w} and @var{out_h}
x and y offsets as specified by the @var{x} and @var{y}
expressions, or NAN if not yet specified
@item a
@item
dar,
a
input display aspect ratio, same as @var{iw} / @var{ih}
@item sar
input sample aspect ratio
@item hsub, vsub
horizontal and vertical chroma subsample values. For example for the
pixel format "yuv422p" @var{hsub} is 2 and @var{vsub} is 1.
...
...
libavfilter/avfilter.h
View file @
0bf02fb1
...
...
@@ -30,7 +30,7 @@
#define LIBAVFILTER_VERSION_MAJOR 2
#define LIBAVFILTER_VERSION_MINOR 24
#define LIBAVFILTER_VERSION_MICRO
2
#define LIBAVFILTER_VERSION_MICRO
3
#define LIBAVFILTER_VERSION_INT AV_VERSION_INT(LIBAVFILTER_VERSION_MAJOR, \
LIBAVFILTER_VERSION_MINOR, \
...
...
libavfilter/vf_pad.c
View file @
0bf02fb1
...
...
@@ -45,7 +45,8 @@ static const char *var_names[] = {
"out_h"
,
"oh"
,
"x"
,
"y"
,
"a"
,
"a"
,
"dar"
,
"sar"
,
"hsub"
,
"vsub"
,
NULL
...
...
@@ -61,7 +62,8 @@ enum var_name {
VAR_OUT_H
,
VAR_OH
,
VAR_X
,
VAR_Y
,
VAR_A
,
VAR_A
,
VAR_DAR
,
VAR_SAR
,
VAR_HSUB
,
VAR_VSUB
,
VARS_NB
...
...
@@ -156,7 +158,9 @@ static int config_input(AVFilterLink *inlink)
var_values
[
VAR_IN_H
]
=
var_values
[
VAR_IH
]
=
inlink
->
h
;
var_values
[
VAR_OUT_W
]
=
var_values
[
VAR_OW
]
=
NAN
;
var_values
[
VAR_OUT_H
]
=
var_values
[
VAR_OH
]
=
NAN
;
var_values
[
VAR_A
]
=
(
float
)
inlink
->
w
/
inlink
->
h
;
var_values
[
VAR_DAR
]
=
var_values
[
VAR_A
]
=
(
float
)
inlink
->
w
/
inlink
->
h
;
var_values
[
VAR_SAR
]
=
inlink
->
sample_aspect_ratio
.
num
?
(
float
)
inlink
->
sample_aspect_ratio
.
num
/
inlink
->
sample_aspect_ratio
.
den
:
1
;
var_values
[
VAR_HSUB
]
=
1
<<
pad
->
hsub
;
var_values
[
VAR_VSUB
]
=
2
<<
pad
->
vsub
;
...
...
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