Skip to content
GitLab
Explore
Projects
Groups
Topics
Snippets
Projects
Groups
Topics
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
BC
public
external
libvpx
Commits
1a66dab9
Commit
1a66dab9
authored
10 years ago
by
Tim Kopp
Browse files
Options
Download
Patches
Plain Diff
VP9 denoiser used s/int/enum where appropriate
Change-Id: Id52a7869fd1f31bb060de170e3295da7435adb9e
parent
2f71de77
v1.14.0-linphone
1.4.X
feature/update_to_v1.9.0-linphone
feature/uwp_nuget
frame_parallel
highbitdepth
indianrunnerduck
javanwhistlingduck
khakicampbell
linphone
linphone-android
linphone-old
longtailedduck
m49-2623
m52-2743
m54-2840
m56-2924
m66-3359
m68-3440
mandarinduck
nextgen
nextgenv2
sandbox/Jingning/experimental
sandbox/Jingning/vpx
sandbox/aconverse@google.com/ansbench
sandbox/hkuang/frame_parallel
sandbox/hkuang@google.com/decode
sandbox/jimbankoski@google.com/proposed-aom
sandbox/jingning@google.com/decoder_test_suite
sandbox/jingning@google.com/experimental
sandbox/jzern@google.com/test
sandbox/wangch@google.com/vp9
sandbox/yaowu@google.com/mergeaom
v1.12.0-linphone
v1.6.1_linphone
v1.7.0-linphone
v1.9.0-linphone
v1.9.0
v1.9.0-rc1
v1.8.2
v1.8.1
v1.8.0
v1.7.0
v1.6.1
v1.6.0
v1.5.0
v1.4.0
No related merge requests found
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
vp9/encoder/vp9_denoiser.c
+14
-12
vp9/encoder/vp9_denoiser.c
vp9/encoder/vp9_denoiser.h
+2
-2
vp9/encoder/vp9_denoiser.h
with
16 additions
and
14 deletions
vp9/encoder/vp9_denoiser.c
+
14
−
12
View file @
1a66dab9
...
...
@@ -22,14 +22,13 @@ static void make_grayscale(YV12_BUFFER_CONFIG *yuv);
static
const
int
widths
[]
=
{
4
,
4
,
8
,
8
,
8
,
16
,
16
,
16
,
32
,
32
,
32
,
64
,
64
};
static
const
int
heights
[]
=
{
4
,
8
,
4
,
8
,
16
,
8
,
16
,
32
,
16
,
32
,
64
,
32
,
64
};
int
vp9_denoiser_filter
()
{
return
0
;
}
static
int
update_running_avg
(
const
uint8_t
*
mc_avg
,
int
mc_avg_stride
,
uint8_t
*
avg
,
int
avg_stride
,
const
uint8_t
*
sig
,
int
sig_stride
,
int
increase_denoising
,
BLOCK_SIZE
bs
)
{
static
VP9_DENOISER_DECISION
update_running_avg
(
const
uint8_t
*
mc_avg
,
int
mc_avg_stride
,
uint8_t
*
avg
,
int
avg_stride
,
const
uint8_t
*
sig
,
int
sig_stride
,
int
increase_denoising
,
BLOCK_SIZE
bs
)
{
int
r
,
c
;
int
diff
,
adj
,
absdiff
;
int
shift_inc1
=
0
,
shift_inc2
=
1
;
...
...
@@ -94,9 +93,12 @@ void copy_block(uint8_t *dest, int dest_stride,
}
}
static
int
perform_motion_compensation
(
VP9_DENOISER
*
denoiser
,
MACROBLOCK
*
mb
,
BLOCK_SIZE
bs
,
int
increase_denoising
,
int
mi_row
,
int
mi_col
)
{
static
VP9_DENOISER_DECISION
perform_motion_compensation
(
VP9_DENOISER
*
denoiser
,
MACROBLOCK
*
mb
,
BLOCK_SIZE
bs
,
int
increase_denoising
,
int
mi_row
,
int
mi_col
)
{
// constants
// TODO(tkopp): empirically determine good constants, or functions of block
// size.
...
...
@@ -228,7 +230,7 @@ static int perform_motion_compensation(VP9_DENOISER *denoiser, MACROBLOCK *mb,
void
vp9_denoiser_denoise
(
VP9_DENOISER
*
denoiser
,
MACROBLOCK
*
mb
,
int
mi_row
,
int
mi_col
,
BLOCK_SIZE
bs
)
{
int
decision
=
COPY
_BLOCK
;
VP9_DENOISER_DECISION
decision
=
FILTER
_BLOCK
;
YV12_BUFFER_CONFIG
avg
=
denoiser
->
running_avg_y
[
INTRA_FRAME
];
YV12_BUFFER_CONFIG
mc_avg
=
denoiser
->
mc_running_avg_y
;
...
...
This diff is collapsed.
Click to expand it.
vp9/encoder/vp9_denoiser.h
+
2
−
2
View file @
1a66dab9
...
...
@@ -18,10 +18,10 @@
extern
"C"
{
#endif
enum
vp9_denoiser_decision
{
typedef
enum
vp9_denoiser_decision
{
COPY_BLOCK
,
FILTER_BLOCK
};
}
VP9_DENOISER_DECISION
;
typedef
struct
vp9_denoiser
{
YV12_BUFFER_CONFIG
running_avg_y
[
MAX_REF_FRAMES
];
...
...
This diff is collapsed.
Click to expand it.
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!
Save comment
Cancel
Please
register
or
sign in
to comment
Menu
Explore
Projects
Groups
Topics
Snippets