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
91c56db6
Commit
91c56db6
authored
Jan 23, 2005
by
Michael Niedermayer
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
use clip_uint8()
Originally committed as revision 3867 to
svn://svn.ffmpeg.org/ffmpeg/trunk
parent
f2196640
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
2 additions
and
7 deletions
+2
-7
dsputil.c
libavcodec/dsputil.c
+2
-7
No files found.
libavcodec/dsputil.c
View file @
91c56db6
...
...
@@ -2374,13 +2374,8 @@ H264_MC(avg_, 16)
#undef op2_put
#endif
static
inline
uint8_t
clip1
(
int
x
){
if
(
x
>
255
)
return
255
;
if
(
x
<
0
)
return
0
;
return
x
;
}
#define op_scale1(x) block[x] = clip1( (block[x]*weight + offset) >> log2_denom )
#define op_scale2(x) dst[x] = clip( (src[x]*weights + dst[x]*weightd + offset) >> (log2_denom+1), 0, 255 )
#define op_scale1(x) block[x] = clip_uint8( (block[x]*weight + offset) >> log2_denom )
#define op_scale2(x) dst[x] = clip_uint8( (src[x]*weights + dst[x]*weightd + offset) >> (log2_denom+1))
#define H264_WEIGHT(W,H) \
static void weight_h264_pixels ## W ## x ## H ## _c(uint8_t *block, int stride, int log2_denom, int weight, int offset){ \
int x, 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