Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
BC
public
external
libvpx
Commits
d82b9f62
Commit
d82b9f62
authored
Jan 24, 2017
by
Jerome Jiang
Committed by
Gerrit Code Review
Jan 24, 2017
Browse files
Merge "vp9: Adjust the threshold to set avg_source_sad_sb flag."
parents
270fadc1
40ffa283
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
4 additions
and
1 deletion
+4
-1
vp9/encoder/vp9_ratectrl.c
vp9/encoder/vp9_ratectrl.c
+4
-1
No files found.
vp9/encoder/vp9_ratectrl.c
View file @
d82b9f62
...
...
@@ -2246,6 +2246,8 @@ void vp9_avg_source_sad(VP9_COMP *cpi) {
int
num_samples
=
0
;
int
sb_cols
=
(
cm
->
mi_cols
+
MI_BLOCK_SIZE
-
1
)
/
MI_BLOCK_SIZE
;
int
sb_rows
=
(
cm
->
mi_rows
+
MI_BLOCK_SIZE
-
1
)
/
MI_BLOCK_SIZE
;
uint64_t
avg_source_sad_threshold
=
5000
;
if
(
cpi
->
oxcf
.
speed
>=
8
)
avg_source_sad_threshold
=
10000
;
if
(
cpi
->
oxcf
.
lag_in_frames
>
0
)
{
src_y
=
frames
[
frame
]
->
y_buffer
;
src_ystride
=
frames
[
frame
]
->
y_stride
;
...
...
@@ -2264,7 +2266,8 @@ void vp9_avg_source_sad(VP9_COMP *cpi) {
tmp_sad
=
cpi
->
fn_ptr
[
bsize
].
sdf
(
src_y
,
src_ystride
,
last_src_y
,
last_src_ystride
);
if
(
cpi
->
sf
.
use_source_sad
)
cpi
->
avg_source_sad_sb
[
num_samples
]
=
tmp_sad
<
5000
?
1
:
0
;
cpi
->
avg_source_sad_sb
[
num_samples
]
=
tmp_sad
<
avg_source_sad_threshold
?
1
:
0
;
avg_sad
+=
tmp_sad
;
num_samples
++
;
}
...
...
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