Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
Xiph.Org
aom-rav1e
Commits
5433fa49
Commit
5433fa49
authored
Oct 10, 2017
by
Debargha Mukherjee
Browse files
Fix mv clamping when superres is used
BUG=aomedia:862 Change-Id: Ide71432cb85858362360e3c4ae8404f75ff9ba03
parent
97d6a37e
Changes
3
Hide whitespace changes
Inline
Side-by-side
aom_scale/yv12config.h
View file @
5433fa49
...
...
@@ -31,7 +31,11 @@ extern "C" {
// TODO(jingning): Use unified inter predictor for encoder and
// decoder during the development process. Revisit the frame border
// to improve the decoder performance.
#if CONFIG_EXT_PARTITION && CONFIG_FRAME_SUPERRES
#define AOM_BORDER_IN_PIXELS 288
#else
#define AOM_BORDER_IN_PIXELS 160
#endif // CONFIG_EXT_PARTITION
typedef
struct
yv12_buffer_config
{
union
{
...
...
av1/common/reconinter.c
View file @
5433fa49
...
...
@@ -1336,10 +1336,10 @@ static INLINE void build_inter_predictors(
pos_x
+=
SCALE_EXTRA_OFF
;
pos_y
+=
SCALE_EXTRA_OFF
;
const
int
top
=
-
((
AOM_INTERP_EXTEND
+
bh
)
<<
SCALE_SUBPEL_BITS
);
const
int
top
=
-
AOM_LEFT_TOP_MARGIN_SCALED
;
const
int
left
=
-
AOM_LEFT_TOP_MARGIN_SCALED
;
const
int
bottom
=
(
pre_buf
->
height
+
AOM_INTERP_EXTEND
)
<<
SCALE_SUBPEL_BITS
;
const
int
left
=
-
((
AOM_INTERP_EXTEND
+
bw
)
<<
SCALE_SUBPEL_BITS
);
const
int
right
=
(
pre_buf
->
width
+
AOM_INTERP_EXTEND
)
<<
SCALE_SUBPEL_BITS
;
pos_y
=
clamp
(
pos_y
,
top
,
bottom
);
...
...
@@ -1494,10 +1494,10 @@ static INLINE void build_inter_predictors(
// Clamp against the reference frame borders, with enough extension
// that we don't force the reference block to be partially onscreen.
const
int
top
=
-
((
AOM_INTERP_EXTEND
+
bh
)
<<
SCALE_SUBPEL_BITS
);
const
int
top
=
-
AOM_LEFT_TOP_MARGIN_SCALED
;
const
int
left
=
-
AOM_LEFT_TOP_MARGIN_SCALED
;
const
int
bottom
=
(
pre_buf
->
height
+
AOM_INTERP_EXTEND
)
<<
SCALE_SUBPEL_BITS
;
const
int
left
=
-
((
AOM_INTERP_EXTEND
+
bw
)
<<
SCALE_SUBPEL_BITS
);
const
int
right
=
(
pre_buf
->
width
+
AOM_INTERP_EXTEND
)
<<
SCALE_SUBPEL_BITS
;
pos_y
=
clamp
(
pos_y
,
top
,
bottom
);
...
...
@@ -3227,10 +3227,10 @@ static void build_inter_predictors_single_buf(MACROBLOCKD *xd, int plane,
pos_x
+=
SCALE_EXTRA_OFF
;
pos_y
+=
SCALE_EXTRA_OFF
;
const
int
top
=
-
((
AOM_INTERP_EXTEND
+
bh
)
<<
SCALE_SUBPEL_BITS
);
const
int
top
=
-
AOM_LEFT_TOP_MARGIN_SCALED
;
const
int
left
=
-
AOM_LEFT_TOP_MARGIN_SCALED
;
const
int
bottom
=
(
pre_buf
->
height
+
AOM_INTERP_EXTEND
)
<<
SCALE_SUBPEL_BITS
;
const
int
left
=
-
((
AOM_INTERP_EXTEND
+
bw
)
<<
SCALE_SUBPEL_BITS
);
const
int
right
=
(
pre_buf
->
width
+
AOM_INTERP_EXTEND
)
<<
SCALE_SUBPEL_BITS
;
pos_y
=
clamp
(
pos_y
,
top
,
bottom
);
pos_x
=
clamp
(
pos_x
,
left
,
right
);
...
...
av1/common/reconinter.h
View file @
5433fa49
...
...
@@ -28,6 +28,9 @@
#define WARP_GM_NEIGHBORS_WITH_OBMC 0
#endif // CONFIG_MOTION_VAR && CONFIG_WARPED_MOTION
#define AOM_LEFT_TOP_MARGIN_SCALED \
((AOM_BORDER_IN_PIXELS - AOM_INTERP_EXTEND) << SCALE_SUBPEL_BITS)
#ifdef __cplusplus
extern
"C"
{
#endif
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new 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