Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
Yushin Cho
aom-rav1e
Commits
c8406c65
Commit
c8406c65
authored
Apr 10, 2014
by
Dmitry Kovalev
Committed by
Gerrit Code Review
Apr 10, 2014
Browse files
Merge "Fixing invalid ref buffer in vp9_diamond_search_sad_c()."
parents
5053845a
c8167f5b
Changes
1
Hide whitespace changes
Inline
Side-by-side
vp9/encoder/vp9_mcomp.c
View file @
c8406c65
...
...
@@ -993,20 +993,21 @@ int vp9_diamond_search_sad_c(const MACROBLOCK *x,
const
MV
fcenter_mv
=
{
center_mv
->
row
>>
3
,
center_mv
->
col
>>
3
};
const
int
*
mvjsadcost
=
x
->
nmvjointsadcost
;
int
*
mvsadcost
[
2
]
=
{
x
->
nmvsadcost
[
0
],
x
->
nmvsadcost
[
1
]};
const
uint8_t
*
best_address
;
const
uint8_t
*
best_address
,
*
in_what_ref
;
int
best_sad
=
INT_MAX
;
int
best_site
=
0
;
int
last_site
=
0
;
int
i
,
j
,
step
;
clamp_mv
(
ref_mv
,
x
->
mv_col_min
,
x
->
mv_col_max
,
x
->
mv_row_min
,
x
->
mv_row_max
);
best_address
=
get_buf_from_mv
(
in_what
,
ref_mv
);
in_what_ref
=
get_buf_from_mv
(
in_what
,
ref_mv
);
best_address
=
in_what_ref
;
*
num00
=
0
;
*
best_mv
=
*
ref_mv
;
// Check the starting position
best_sad
=
fn_ptr
->
sdf
(
what
->
buf
,
what
->
stride
,
in_what
->
buf
,
in_what
->
stride
,
0x7fffffff
)
+
best_address
,
in_what
->
stride
,
0x7fffffff
)
+
mvsad_err_cost
(
best_mv
,
&
fcenter_mv
,
mvjsadcost
,
mvsadcost
,
sad_per_bit
);
i
=
1
;
...
...
@@ -1060,7 +1061,7 @@ int vp9_diamond_search_sad_c(const MACROBLOCK *x,
break
;
};
#endif
}
else
if
(
best_address
==
in_what
->
bu
f
)
{
}
else
if
(
best_address
==
in_what
_re
f
)
{
(
*
num00
)
++
;
}
}
...
...
Write
Preview
Supports
Markdown
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