Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Contribute to GitLab
Sign in / Register
Toggle navigation
F
ffmpeg.wasm-core
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Linshizhi
ffmpeg.wasm-core
Commits
c8a596d2
Commit
c8a596d2
authored
Jan 12, 2006
by
Michael Niedermayer
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
bugs found by valgrind
Originally committed as revision 4841 to
svn://svn.ffmpeg.org/ffmpeg/trunk
parent
517840c6
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
17 additions
and
16 deletions
+17
-16
snow.c
libavcodec/snow.c
+11
-10
ffmpeg.regression.ref
tests/ffmpeg.regression.ref
+3
-3
rotozoom.regression.ref
tests/rotozoom.regression.ref
+3
-3
No files found.
libavcodec/snow.c
View file @
c8a596d2
...
...
@@ -3116,13 +3116,14 @@ static int get_block_rd(SnowContext *s, int mb_x, int mb_y, int plane_index, con
BlockNode
*
top
=
y
?
&
s
->
block
[
index
-
b_stride
]
:
&
null_block
;
BlockNode
*
tl
=
y
&&
x
?
&
s
->
block
[
index
-
b_stride
-
1
]
:
left
;
BlockNode
*
tr
=
y
&&
x
+
1
<
b_stride
?
&
s
->
block
[
index
-
b_stride
+
1
]
:
tl
;
int
dmx
=
b
->
mx
-
mid_pred
(
left
->
mx
,
top
->
mx
,
tr
->
mx
);
int
dmy
=
b
->
my
-
mid_pred
(
left
->
my
,
top
->
my
,
tr
->
my
);
int
dmx
,
dmy
;
// int mx_context= av_log2(2*ABS(left->mx - top->mx));
// int my_context= av_log2(2*ABS(left->my - top->my));
if
(
x
<
0
||
x
>=
b_stride
||
y
>=
b_height
)
continue
;
dmx
=
b
->
mx
-
mid_pred
(
left
->
mx
,
top
->
mx
,
tr
->
mx
);
dmy
=
b
->
my
-
mid_pred
(
left
->
my
,
top
->
my
,
tr
->
my
);
/*
1 0 0
01X 1-2 1
...
...
@@ -3206,14 +3207,14 @@ static void iterative_me(SnowContext *s){
BlockNode
backup
;
const
int
index
=
mb_x
+
mb_y
*
b_stride
;
BlockNode
*
block
=
&
s
->
block
[
index
];
BlockNode
*
tb
=
mb_y
?
&
s
->
block
[
index
-
b_stride
]
:
&
null_block
;
BlockNode
*
lb
=
mb_x
?
&
s
->
block
[
index
-
1
]
:
&
null_block
;
BlockNode
*
rb
=
mb_x
<
b_width
?
&
s
->
block
[
index
+
1
]
:
&
null_block
;
BlockNode
*
bb
=
mb_y
<
b_height
?
&
s
->
block
[
index
+
b_stride
]
:
&
null_block
;
BlockNode
*
tlb
=
mb_x
&&
mb_y
?
&
s
->
block
[
index
-
b_stride
-
1
]
:
&
null_block
;
BlockNode
*
trb
=
mb_x
<
b_width
&&
mb_y
?
&
s
->
block
[
index
-
b_stride
+
1
]
:
&
null_block
;
BlockNode
*
blb
=
mb_x
&&
mb_y
<
b_height
?
&
s
->
block
[
index
+
b_stride
-
1
]
:
&
null_block
;
BlockNode
*
brb
=
mb_x
<
b_width
&&
mb_y
<
b_height
?
&
s
->
block
[
index
+
b_stride
+
1
]
:
&
null_block
;
BlockNode
*
tb
=
mb_y
?
&
s
->
block
[
index
-
b_stride
]
:
&
null_block
;
BlockNode
*
lb
=
mb_x
?
&
s
->
block
[
index
-
1
]
:
&
null_block
;
BlockNode
*
rb
=
mb_x
+
1
<
b_width
?
&
s
->
block
[
index
+
1
]
:
&
null_block
;
BlockNode
*
bb
=
mb_y
+
1
<
b_height
?
&
s
->
block
[
index
+
b_stride
]
:
&
null_block
;
BlockNode
*
tlb
=
mb_x
&&
mb_y
?
&
s
->
block
[
index
-
b_stride
-
1
]
:
&
null_block
;
BlockNode
*
trb
=
mb_x
+
1
<
b_width
&&
mb_y
?
&
s
->
block
[
index
-
b_stride
+
1
]
:
&
null_block
;
BlockNode
*
blb
=
mb_x
&&
mb_y
+
1
<
b_height
?
&
s
->
block
[
index
+
b_stride
-
1
]
:
&
null_block
;
BlockNode
*
brb
=
mb_x
+
1
<
b_width
&&
mb_y
+
1
<
b_height
?
&
s
->
block
[
index
+
b_stride
+
1
]
:
&
null_block
;
const
int
b_w
=
(
MB_SIZE
>>
s
->
block_max_depth
);
uint8_t
obmc_edged
[
b_w
*
2
][
b_w
*
2
];
...
...
tests/ffmpeg.regression.ref
View file @
c8a596d2
...
...
@@ -119,9 +119,9 @@ a7ef4746f27be309138c188e327d3ebe *./data/a-ffv1.avi
2653642 ./data/a-ffv1.avi
799d3db687f6cdd7a837ec156efc171f *./data/out.yuv
stddev: 0.00 PSNR:99.99 bytes:7602176
14fa515bf25a47fc2ad3d18b726e8e31
*./data/a-snow.avi
119
7138
./data/a-snow.avi
e7c746171b092266b0cf55bb5de2a40a
*./data/out.yuv
97c7066617d9e6c86a43a2736b3e9f16
*./data/a-snow.avi
119
0760
./data/a-snow.avi
7e4d9c61252ff22b1a0d4e892cc1d957
*./data/out.yuv
stddev: 2.89 PSNR:38.87 bytes:7602176
11fd61ee7e67ef7a7b2a3df973691305 *./data/a-snow53.avi
3533710 ./data/a-snow53.avi
...
...
tests/rotozoom.regression.ref
View file @
c8a596d2
...
...
@@ -119,9 +119,9 @@ d0831a8339491fd680b650f05262e5d9 *./data/a-ffv1.avi
3524768 ./data/a-ffv1.avi
dde5895817ad9d219f79a52d0bdfb001 *./data/out.yuv
stddev: 0.00 PSNR:99.99 bytes:7602176
b926518ac399c7af0f218a7115315b4f
*./data/a-snow.avi
286
800
./data/a-snow.avi
6c59db71d950610f854d05e2cef18609
*./data/out.yuv
7345af7da71320bf87d3c950252b4341
*./data/a-snow.avi
286
798
./data/a-snow.avi
cc5ef1eda02091fbf9a85887bad47bc4
*./data/out.yuv
stddev: 2.32 PSNR:40.80 bytes:7602176
3f20642bb789dfb75ae3e8c03f9b425c *./data/a-snow53.avi
2725570 ./data/a-snow53.avi
...
...
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