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
3a87dce6
Commit
3a87dce6
authored
Sep 21, 2011
by
Stefano Sabatini
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
vf_drawtext: remove useless and misnamed intermediary "baseline" variable in draw_text()
parent
500b3210
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
2 additions
and
3 deletions
+2
-3
vf_drawtext.c
libavfilter/vf_drawtext.c
+2
-3
No files found.
libavfilter/vf_drawtext.c
View file @
3a87dce6
...
...
@@ -560,7 +560,7 @@ static int draw_text(AVFilterContext *ctx, AVFilterBufferRef *picref,
DrawTextContext
*
dtext
=
ctx
->
priv
;
uint32_t
code
=
0
,
prev_code
=
0
;
int
x
=
0
,
y
=
0
,
i
=
0
,
ret
;
int
text_height
,
baseline
;
int
text_height
;
char
*
text
=
dtext
->
text
;
uint8_t
*
p
;
int
str_w
=
0
,
len
;
...
...
@@ -624,7 +624,6 @@ static int draw_text(AVFilterContext *ctx, AVFilterBufferRef *picref,
y_max
=
FFMAX
(
glyph
->
bbox
.
yMax
,
y_max
);
}
text_height
=
y_max
-
y_min
;
baseline
=
y_max
;
/* compute and save position for each glyph */
glyph
=
NULL
;
...
...
@@ -663,7 +662,7 @@ static int draw_text(AVFilterContext *ctx, AVFilterBufferRef *picref,
/* save position */
dtext
->
positions
[
i
].
x
=
x
+
glyph
->
bitmap_left
;
dtext
->
positions
[
i
].
y
=
y
-
glyph
->
bitmap_top
+
baseline
;
dtext
->
positions
[
i
].
y
=
y
-
glyph
->
bitmap_top
+
y_max
;
if
(
code
==
'\t'
)
x
=
(
x
/
dtext
->
tabsize
+
1
)
*
dtext
->
tabsize
;
else
x
+=
glyph
->
advance
;
}
...
...
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