Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
What's new
10
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Open sidebar
BC
public
external
libvpx
Commits
dd31f2e4
Commit
dd31f2e4
authored
Jan 13, 2014
by
Dmitry Kovalev
Committed by
Gerrit Code Review
Jan 13, 2014
Browse files
Options
Browse Files
Download
Plain Diff
Merge "Adding mv_has_subpel() function."
parents
9c9fdf30
b02c72b5
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
11 additions
and
12 deletions
+11
-12
vp9/encoder/vp9_rdopt.c
vp9/encoder/vp9_rdopt.c
+11
-12
No files found.
vp9/encoder/vp9_rdopt.c
View file @
dd31f2e4
...
@@ -1638,6 +1638,10 @@ static INLINE void mi_buf_restore(MACROBLOCK *x, struct buf_2d orig_src,
...
@@ -1638,6 +1638,10 @@ static INLINE void mi_buf_restore(MACROBLOCK *x, struct buf_2d orig_src,
x
->
e_mbd
.
plane
[
0
].
pre
[
1
]
=
orig_pre
[
1
];
x
->
e_mbd
.
plane
[
0
].
pre
[
1
]
=
orig_pre
[
1
];
}
}
static
INLINE
int
mv_has_subpel
(
const
MV
*
mv
)
{
return
(
mv
->
row
&
0x0F
)
||
(
mv
->
col
&
0x0F
);
}
static
void
rd_check_segment_txsize
(
VP9_COMP
*
cpi
,
MACROBLOCK
*
x
,
static
void
rd_check_segment_txsize
(
VP9_COMP
*
cpi
,
MACROBLOCK
*
x
,
const
TileInfo
*
const
tile
,
const
TileInfo
*
const
tile
,
BEST_SEG_INFO
*
bsi_buf
,
int
filter_idx
,
BEST_SEG_INFO
*
bsi_buf
,
int
filter_idx
,
...
@@ -1931,15 +1935,13 @@ static void rd_check_segment_txsize(VP9_COMP *cpi, MACROBLOCK *x,
...
@@ -1931,15 +1935,13 @@ static void rd_check_segment_txsize(VP9_COMP *cpi, MACROBLOCK *x,
if
(
filter_idx
>
0
)
{
if
(
filter_idx
>
0
)
{
BEST_SEG_INFO
*
ref_bsi
=
bsi_buf
;
BEST_SEG_INFO
*
ref_bsi
=
bsi_buf
;
subpelmv
=
(
mode_mv
[
this_mode
].
as_mv
.
row
&
0x0f
)
||
subpelmv
=
mv_has_subpel
(
&
mode_mv
[
this_mode
].
as_mv
);
(
mode_mv
[
this_mode
].
as_mv
.
col
&
0x0f
);
have_ref
=
mode_mv
[
this_mode
].
as_int
==
have_ref
=
mode_mv
[
this_mode
].
as_int
==
ref_bsi
->
rdstat
[
i
][
mode_idx
].
mvs
[
0
].
as_int
;
ref_bsi
->
rdstat
[
i
][
mode_idx
].
mvs
[
0
].
as_int
;
if
(
has_second_rf
)
{
if
(
has_second_rf
)
{
subpelmv
|=
(
second_mode_mv
[
this_mode
].
as_mv
.
row
&
0x0f
)
||
subpelmv
|=
mv_has_subpel
(
&
second_mode_mv
[
this_mode
].
as_mv
);
(
second_mode_mv
[
this_mode
].
as_mv
.
col
&
0x0f
);
have_ref
&=
second_mode_mv
[
this_mode
].
as_int
==
have_ref
&=
second_mode_mv
[
this_mode
].
as_int
==
ref_bsi
->
rdstat
[
i
][
mode_idx
].
mvs
[
1
].
as_int
;
ref_bsi
->
rdstat
[
i
][
mode_idx
].
mvs
[
1
].
as_int
;
}
}
if
(
filter_idx
>
1
&&
!
subpelmv
&&
!
have_ref
)
{
if
(
filter_idx
>
1
&&
!
subpelmv
&&
!
have_ref
)
{
...
@@ -2770,12 +2772,9 @@ static int64_t handle_inter_mode(VP9_COMP *cpi, MACROBLOCK *x,
...
@@ -2770,12 +2772,9 @@ static int64_t handle_inter_mode(VP9_COMP *cpi, MACROBLOCK *x,
pred_exists
=
0
;
pred_exists
=
0
;
// Are all MVs integer pel for Y and UV
// Are all MVs integer pel for Y and UV
intpel_mv
=
(
mbmi
->
mv
[
0
].
as_mv
.
row
&
15
)
==
0
&&
intpel_mv
=
!
mv_has_subpel
(
&
mbmi
->
mv
[
0
].
as_mv
);
(
mbmi
->
mv
[
0
].
as_mv
.
col
&
15
)
==
0
;
if
(
is_comp_pred
)
if
(
is_comp_pred
)
intpel_mv
&=
(
mbmi
->
mv
[
1
].
as_mv
.
row
&
15
)
==
0
&&
intpel_mv
&=
!
mv_has_subpel
(
&
mbmi
->
mv
[
1
].
as_mv
);
(
mbmi
->
mv
[
1
].
as_mv
.
col
&
15
)
==
0
;
// Search for best switchable filter by checking the variance of
// Search for best switchable filter by checking the variance of
// pred error irrespective of whether the filter will be used
// pred error irrespective of whether the filter will be used
...
...
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