Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
F
ffmpeg
Project
Project
Details
Activity
Releases
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
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Stefan Westerfeld
ffmpeg
Commits
1340fe7c
Commit
1340fe7c
authored
Dec 27, 2022
by
Clément Bœsch
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
avfilter/paletteuse: move r,g,b computation in a more local scope
parent
1ae1b707
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
3 additions
and
3 deletions
+3
-3
vf_paletteuse.c
libavfilter/vf_paletteuse.c
+3
-3
No files found.
libavfilter/vf_paletteuse.c
View file @
1340fe7c
...
...
@@ -262,9 +262,6 @@ static av_always_inline int color_get(PaletteUseContext *s, uint32_t color)
static
av_always_inline
int
get_dst_color_err
(
PaletteUseContext
*
s
,
uint32_t
c
,
int
*
er
,
int
*
eg
,
int
*
eb
)
{
const
uint8_t
r
=
c
>>
16
&
0xff
;
const
uint8_t
g
=
c
>>
8
&
0xff
;
const
uint8_t
b
=
c
&
0xff
;
uint32_t
dstc
;
const
int
dstx
=
color_get
(
s
,
c
);
if
(
dstx
<
0
)
...
...
@@ -273,6 +270,9 @@ static av_always_inline int get_dst_color_err(PaletteUseContext *s,
if
(
dstx
==
s
->
transparency_index
)
{
*
er
=
*
eg
=
*
eb
=
0
;
}
else
{
const
uint8_t
r
=
c
>>
16
&
0xff
;
const
uint8_t
g
=
c
>>
8
&
0xff
;
const
uint8_t
b
=
c
&
0xff
;
*
er
=
(
int
)
r
-
(
int
)(
dstc
>>
16
&
0xff
);
*
eg
=
(
int
)
g
-
(
int
)(
dstc
>>
8
&
0xff
);
*
eb
=
(
int
)
b
-
(
int
)(
dstc
&
0xff
);
...
...
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