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
62457f90
Commit
62457f90
authored
Feb 06, 2011
by
Jason Garrett-Glaser
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
VP8: idct_mb optimizations
Currently uses AV_RL32 instead of AV_RL32A, as the latter doesn't exist yet.
parent
17cf7c68
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
16 additions
and
16 deletions
+16
-16
vp8.c
libavcodec/vp8.c
+16
-16
No files found.
libavcodec/vp8.c
View file @
62457f90
...
...
@@ -1421,17 +1421,17 @@ static av_always_inline void idct_mb(VP8Context *s, uint8_t *dst[3], VP8Macroblo
if
(
mb
->
mode
!=
MODE_I4x4
)
{
uint8_t
*
y_dst
=
dst
[
0
];
for
(
y
=
0
;
y
<
4
;
y
++
)
{
uint32_t
nnz4
=
AV_R
N32A
(
s
->
non_zero_count_cache
[
y
]);
uint32_t
nnz4
=
AV_R
L32
(
s
->
non_zero_count_cache
[
y
]);
if
(
nnz4
)
{
if
(
nnz4
&~
0x01010101
)
{
for
(
x
=
0
;
x
<
4
;
x
++
)
{
i
nt
nnz
=
s
->
non_zero_count_cache
[
y
][
x
];
if
(
nnz
)
{
if
(
nnz
==
1
)
s
->
vp8dsp
.
vp8_idct_dc
_add
(
y_dst
+
4
*
x
,
s
->
block
[
y
][
x
],
s
->
linesize
);
else
s
->
vp8dsp
.
vp8_idct_add
(
y_dst
+
4
*
x
,
s
->
block
[
y
][
x
],
s
->
linesize
);
}
i
f
((
uint8_t
)
nnz4
==
1
)
s
->
vp8dsp
.
vp8_idct_dc_add
(
y_dst
+
4
*
x
,
s
->
block
[
y
][
x
],
s
->
linesize
);
else
if
((
uint8_t
)
nnz4
>
1
)
s
->
vp8dsp
.
vp8_idct
_add
(
y_dst
+
4
*
x
,
s
->
block
[
y
][
x
],
s
->
linesize
);
nnz4
>>=
8
;
if
(
!
nnz4
)
break
;
}
}
else
{
s
->
vp8dsp
.
vp8_idct_dc_add4y
(
y_dst
,
s
->
block
[
y
],
s
->
linesize
);
...
...
@@ -1442,19 +1442,19 @@ static av_always_inline void idct_mb(VP8Context *s, uint8_t *dst[3], VP8Macroblo
}
for
(
ch
=
0
;
ch
<
2
;
ch
++
)
{
uint32_t
nnz4
=
AV_R
N32A
(
s
->
non_zero_count_cache
[
4
+
ch
]);
uint32_t
nnz4
=
AV_R
L32
(
s
->
non_zero_count_cache
[
4
+
ch
]);
if
(
nnz4
)
{
uint8_t
*
ch_dst
=
dst
[
1
+
ch
];
if
(
nnz4
&~
0x01010101
)
{
for
(
y
=
0
;
y
<
2
;
y
++
)
{
for
(
x
=
0
;
x
<
2
;
x
++
)
{
i
nt
nnz
=
s
->
non_zero_count_cache
[
4
+
ch
][(
y
<<
1
)
+
x
];
if
(
nnz
)
{
if
(
nnz
==
1
)
s
->
vp8dsp
.
vp8_idct_dc
_add
(
ch_dst
+
4
*
x
,
s
->
block
[
4
+
ch
][(
y
<<
1
)
+
x
],
s
->
uvlinesize
);
else
s
->
vp8dsp
.
vp8_idct_add
(
ch_dst
+
4
*
x
,
s
->
block
[
4
+
ch
][(
y
<<
1
)
+
x
],
s
->
uvlinesize
);
}
i
f
((
uint8_t
)
nnz4
==
1
)
s
->
vp8dsp
.
vp8_idct_dc_add
(
ch_dst
+
4
*
x
,
s
->
block
[
4
+
ch
][(
y
<<
1
)
+
x
],
s
->
uvlinesize
);
else
if
((
uint8_t
)
nnz4
>
1
)
s
->
vp8dsp
.
vp8_idct
_add
(
ch_dst
+
4
*
x
,
s
->
block
[
4
+
ch
][(
y
<<
1
)
+
x
],
s
->
uvlinesize
);
nnz4
>>=
8
;
if
(
!
nnz4
)
break
;
}
ch_dst
+=
4
*
s
->
uvlinesize
;
}
...
...
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