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
ee80cf74
Commit
ee80cf74
authored
Oct 23, 2013
by
Diego Biurrun
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
avfilter: x86: K&R formatting cosmetics
parent
c7f25d4c
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
42 additions
and
23 deletions
+42
-23
vf_gradfun_init.c
libavfilter/x86/vf_gradfun_init.c
+27
-16
vf_hqdn3d_init.c
libavfilter/x86/vf_hqdn3d_init.c
+15
-7
No files found.
libavfilter/x86/vf_gradfun_init.c
View file @
ee80cf74
...
...
@@ -26,10 +26,22 @@
#include "libavutil/x86/cpu.h"
#include "libavfilter/gradfun.h"
#if HAVE_YASM
void
ff_gradfun_filter_line_mmxext
(
intptr_t
x
,
uint8_t
*
dst
,
uint8_t
*
src
,
uint16_t
*
dc
,
int
thresh
,
const
uint16_t
*
dithers
);
void
ff_gradfun_filter_line_ssse3
(
intptr_t
x
,
uint8_t
*
dst
,
uint8_t
*
src
,
uint16_t
*
dc
,
int
thresh
,
const
uint16_t
*
dithers
);
void
ff_gradfun_blur_line_movdqa_sse2
(
intptr_t
x
,
uint16_t
*
buf
,
uint16_t
*
buf1
,
uint16_t
*
dc
,
uint8_t
*
src1
,
uint8_t
*
src2
);
void
ff_gradfun_blur_line_movdqu_sse2
(
intptr_t
x
,
uint16_t
*
buf
,
uint16_t
*
buf1
,
uint16_t
*
dc
,
uint8_t
*
src1
,
uint8_t
*
src2
);
#if HAVE_YASM
static
void
gradfun_filter_line_mmxext
(
uint8_t
*
dst
,
uint8_t
*
src
,
uint16_t
*
dc
,
int
width
,
int
thresh
,
const
uint16_t
*
dithers
)
...
...
@@ -37,45 +49,44 @@ static void gradfun_filter_line_mmxext(uint8_t *dst, uint8_t *src, uint16_t *dc,
intptr_t
x
;
if
(
width
&
3
)
{
x
=
width
&
~
3
;
ff_gradfun_filter_line_c
(
dst
+
x
,
src
+
x
,
dc
+
x
/
2
,
width
-
x
,
thresh
,
dithers
);
ff_gradfun_filter_line_c
(
dst
+
x
,
src
+
x
,
dc
+
x
/
2
,
width
-
x
,
thresh
,
dithers
);
width
=
x
;
}
x
=
-
width
;
ff_gradfun_filter_line_mmxext
(
x
,
dst
+
width
,
src
+
width
,
dc
+
width
/
2
,
ff_gradfun_filter_line_mmxext
(
x
,
dst
+
width
,
src
+
width
,
dc
+
width
/
2
,
thresh
,
dithers
);
}
void
ff_gradfun_filter_line_ssse3
(
intptr_t
x
,
uint8_t
*
dst
,
uint8_t
*
src
,
uint16_t
*
dc
,
int
thresh
,
const
uint16_t
*
dithers
);
static
void
gradfun_filter_line_ssse3
(
uint8_t
*
dst
,
uint8_t
*
src
,
uint16_t
*
dc
,
int
width
,
int
thresh
,
const
uint16_t
*
dithers
)
static
void
gradfun_filter_line_ssse3
(
uint8_t
*
dst
,
uint8_t
*
src
,
uint16_t
*
dc
,
int
width
,
int
thresh
,
const
uint16_t
*
dithers
)
{
intptr_t
x
;
if
(
width
&
7
)
{
// could be 10% faster if I somehow eliminated this
x
=
width
&
~
7
;
ff_gradfun_filter_line_c
(
dst
+
x
,
src
+
x
,
dc
+
x
/
2
,
width
-
x
,
thresh
,
dithers
);
ff_gradfun_filter_line_c
(
dst
+
x
,
src
+
x
,
dc
+
x
/
2
,
width
-
x
,
thresh
,
dithers
);
width
=
x
;
}
x
=
-
width
;
ff_gradfun_filter_line_ssse3
(
x
,
dst
+
width
,
src
+
width
,
dc
+
width
/
2
,
ff_gradfun_filter_line_ssse3
(
x
,
dst
+
width
,
src
+
width
,
dc
+
width
/
2
,
thresh
,
dithers
);
}
void
ff_gradfun_blur_line_movdqa_sse2
(
intptr_t
x
,
uint16_t
*
buf
,
uint16_t
*
buf1
,
uint16_t
*
dc
,
uint8_t
*
src1
,
uint8_t
*
src2
);
void
ff_gradfun_blur_line_movdqu_sse2
(
intptr_t
x
,
uint16_t
*
buf
,
uint16_t
*
buf1
,
uint16_t
*
dc
,
uint8_t
*
src1
,
uint8_t
*
src2
);
static
void
gradfun_blur_line_sse2
(
uint16_t
*
dc
,
uint16_t
*
buf
,
uint16_t
*
buf1
,
uint8_t
*
src
,
int
src_linesize
,
int
width
)
static
void
gradfun_blur_line_sse2
(
uint16_t
*
dc
,
uint16_t
*
buf
,
uint16_t
*
buf1
,
uint8_t
*
src
,
int
src_linesize
,
int
width
)
{
intptr_t
x
=
-
2
*
width
;
if
(((
intptr_t
)
src
|
src_linesize
)
&
15
)
{
intptr_t
x
=
-
2
*
width
;
if
(((
intptr_t
)
src
|
src_linesize
)
&
15
)
ff_gradfun_blur_line_movdqu_sse2
(
x
,
buf
+
width
,
buf1
+
width
,
dc
+
width
,
src
+
width
*
2
,
src
+
width
*
2
+
src_linesize
);
}
else
{
else
ff_gradfun_blur_line_movdqa_sse2
(
x
,
buf
+
width
,
buf1
+
width
,
dc
+
width
,
src
+
width
*
2
,
src
+
width
*
2
+
src_linesize
);
}
}
#endif
/* HAVE_YASM */
...
...
libavfilter/x86/vf_hqdn3d_init.c
View file @
ee80cf74
...
...
@@ -23,17 +23,25 @@
#include "libavfilter/vf_hqdn3d.h"
#include "config.h"
void
ff_hqdn3d_row_8_x86
(
uint8_t
*
src
,
uint8_t
*
dst
,
uint16_t
*
line_ant
,
uint16_t
*
frame_ant
,
ptrdiff_t
w
,
int16_t
*
spatial
,
int16_t
*
temporal
);
void
ff_hqdn3d_row_9_x86
(
uint8_t
*
src
,
uint8_t
*
dst
,
uint16_t
*
line_ant
,
uint16_t
*
frame_ant
,
ptrdiff_t
w
,
int16_t
*
spatial
,
int16_t
*
temporal
);
void
ff_hqdn3d_row_10_x86
(
uint8_t
*
src
,
uint8_t
*
dst
,
uint16_t
*
line_ant
,
uint16_t
*
frame_ant
,
ptrdiff_t
w
,
int16_t
*
spatial
,
int16_t
*
temporal
);
void
ff_hqdn3d_row_16_x86
(
uint8_t
*
src
,
uint8_t
*
dst
,
uint16_t
*
line_ant
,
uint16_t
*
frame_ant
,
ptrdiff_t
w
,
int16_t
*
spatial
,
int16_t
*
temporal
);
void
ff_hqdn3d_row_8_x86
(
uint8_t
*
src
,
uint8_t
*
dst
,
uint16_t
*
line_ant
,
uint16_t
*
frame_ant
,
ptrdiff_t
w
,
int16_t
*
spatial
,
int16_t
*
temporal
);
void
ff_hqdn3d_row_9_x86
(
uint8_t
*
src
,
uint8_t
*
dst
,
uint16_t
*
line_ant
,
uint16_t
*
frame_ant
,
ptrdiff_t
w
,
int16_t
*
spatial
,
int16_t
*
temporal
);
void
ff_hqdn3d_row_10_x86
(
uint8_t
*
src
,
uint8_t
*
dst
,
uint16_t
*
line_ant
,
uint16_t
*
frame_ant
,
ptrdiff_t
w
,
int16_t
*
spatial
,
int16_t
*
temporal
);
void
ff_hqdn3d_row_16_x86
(
uint8_t
*
src
,
uint8_t
*
dst
,
uint16_t
*
line_ant
,
uint16_t
*
frame_ant
,
ptrdiff_t
w
,
int16_t
*
spatial
,
int16_t
*
temporal
);
av_cold
void
ff_hqdn3d_init_x86
(
HQDN3DContext
*
hqdn3d
)
{
#if HAVE_YASM
hqdn3d
->
denoise_row
[
8
]
=
ff_hqdn3d_row_8_x86
;
hqdn3d
->
denoise_row
[
9
]
=
ff_hqdn3d_row_9_x86
;
hqdn3d
->
denoise_row
[
8
]
=
ff_hqdn3d_row_8_x86
;
hqdn3d
->
denoise_row
[
9
]
=
ff_hqdn3d_row_9_x86
;
hqdn3d
->
denoise_row
[
10
]
=
ff_hqdn3d_row_10_x86
;
hqdn3d
->
denoise_row
[
16
]
=
ff_hqdn3d_row_16_x86
;
#endif
#endif
/* HAVE_YASM */
}
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