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
ac18114b
Commit
ac18114b
authored
Aug 15, 2016
by
Paul B Mahol
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
avfilter/vf_zoompan: fix pzoom usage
parent
b93e2233
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
11 additions
and
4 deletions
+11
-4
vf_zoompan.c
libavfilter/vf_zoompan.c
+11
-4
No files found.
libavfilter/vf_zoompan.c
View file @
ac18114b
...
@@ -143,6 +143,10 @@ static int output_single_frame(AVFilterContext *ctx, AVFrame *in, double *var_va
...
@@ -143,6 +143,10 @@ static int output_single_frame(AVFilterContext *ctx, AVFrame *in, double *var_va
int
px
[
4
],
py
[
4
];
int
px
[
4
],
py
[
4
];
AVFrame
*
out
;
AVFrame
*
out
;
var_values
[
VAR_PX
]
=
s
->
x
;
var_values
[
VAR_PY
]
=
s
->
y
;
var_values
[
VAR_PZOOM
]
=
s
->
prev_zoom
;
var_values
[
VAR_PDURATION
]
=
s
->
prev_nb_frames
;
var_values
[
VAR_TIME
]
=
pts
*
av_q2d
(
outlink
->
time_base
);
var_values
[
VAR_TIME
]
=
pts
*
av_q2d
(
outlink
->
time_base
);
var_values
[
VAR_FRAME
]
=
i
;
var_values
[
VAR_FRAME
]
=
i
;
var_values
[
VAR_ON
]
=
outlink
->
frame_count
+
1
;
var_values
[
VAR_ON
]
=
outlink
->
frame_count
+
1
;
...
@@ -265,7 +269,7 @@ static int request_frame(AVFilterLink *outlink)
...
@@ -265,7 +269,7 @@ static int request_frame(AVFilterLink *outlink)
AVFilterContext
*
ctx
=
outlink
->
src
;
AVFilterContext
*
ctx
=
outlink
->
src
;
ZPContext
*
s
=
ctx
->
priv
;
ZPContext
*
s
=
ctx
->
priv
;
AVFrame
*
in
=
s
->
in
;
AVFrame
*
in
=
s
->
in
;
double
zoom
=
1
,
dx
=
0
,
dy
=
0
;
double
zoom
=
-
1
,
dx
=-
1
,
dy
=-
1
;
int
ret
=
-
1
;
int
ret
=
-
1
;
if
(
in
)
{
if
(
in
)
{
...
@@ -276,8 +280,11 @@ static int request_frame(AVFilterLink *outlink)
...
@@ -276,8 +280,11 @@ static int request_frame(AVFilterLink *outlink)
}
}
if
(
s
->
current_frame
>=
s
->
nb_frames
)
{
if
(
s
->
current_frame
>=
s
->
nb_frames
)
{
if
(
dx
!=
-
1
)
s
->
x
=
dx
;
s
->
x
=
dx
;
if
(
dy
!=
-
1
)
s
->
y
=
dy
;
s
->
y
=
dy
;
if
(
zoom
!=
-
1
)
s
->
prev_zoom
=
zoom
;
s
->
prev_zoom
=
zoom
;
s
->
prev_nb_frames
=
s
->
nb_frames
;
s
->
prev_nb_frames
=
s
->
nb_frames
;
s
->
nb_frames
=
0
;
s
->
nb_frames
=
0
;
...
...
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