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
eef38316
Commit
eef38316
authored
Nov 23, 2015
by
Vittorio Giovara
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
texturedspenc: Avoid using separate variables
Use the result directly, removing an unneeded cast.
parent
7831fb90
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
3 additions
and
7 deletions
+3
-7
texturedspenc.c
libavcodec/texturedspenc.c
+3
-7
No files found.
libavcodec/texturedspenc.c
View file @
eef38316
...
...
@@ -583,14 +583,10 @@ static void rgba2ycocg(uint8_t *dst, const uint8_t *pixel)
int
b
=
pixel
[
2
];
int
t
=
(
2
+
r
+
b
)
>>
2
;
int
y
=
av_clip_uint8
(
g
+
t
);
int
co
=
av_clip_uint8
(
128
+
((
r
-
b
+
1
)
>>
1
));
int
cg
=
av_clip_uint8
(
128
+
g
-
t
);
dst
[
0
]
=
(
uint8_t
)
co
;
dst
[
1
]
=
(
uint8_t
)
cg
;
dst
[
0
]
=
av_clip_uint8
(
128
+
((
r
-
b
+
1
)
>>
1
));
/* Co */
dst
[
1
]
=
av_clip_uint8
(
128
+
g
-
t
);
/* Cg */
dst
[
2
]
=
0
;
dst
[
3
]
=
(
uint8_t
)
y
;
dst
[
3
]
=
av_clip_uint8
(
g
+
t
);
/* Y */
}
/**
...
...
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