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
7f21a9a7
Commit
7f21a9a7
authored
May 30, 2006
by
Loren Merritt
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Snow: cosmetics
Originally committed as revision 5428 to
svn://svn.ffmpeg.org/ffmpeg/trunk
parent
871371a7
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
22 additions
and
22 deletions
+22
-22
snow.c
libavcodec/snow.c
+22
-22
No files found.
libavcodec/snow.c
View file @
7f21a9a7
...
@@ -2659,7 +2659,7 @@ assert(src_stride > 2*MB_SIZE + 5);
...
@@ -2659,7 +2659,7 @@ assert(src_stride > 2*MB_SIZE + 5);
}
}
//FIXME name clenup (b_w, block_w, b_width stuff)
//FIXME name clenup (b_w, block_w, b_width stuff)
static
always_inline
void
add_yblock
(
SnowContext
*
s
,
DWTELEM
*
dst
,
uint8_t
*
dst8
,
uint8_t
*
obmc
,
int
src_x
,
int
src_y
,
int
b_w
,
int
b_h
,
int
w
,
int
h
,
int
dst_stride
,
int
src_stride
,
int
obmc_stride
,
int
b_x
,
int
b_y
,
int
add
,
int
offset_dst
,
int
plane_index
){
static
always_inline
void
add_yblock
(
SnowContext
*
s
,
DWTELEM
*
dst
,
uint8_t
*
dst8
,
const
uint8_t
*
obmc
,
int
src_x
,
int
src_y
,
int
b_w
,
int
b_h
,
int
w
,
int
h
,
int
dst_stride
,
int
src_stride
,
int
obmc_stride
,
int
b_x
,
int
b_y
,
int
add
,
int
offset_dst
,
int
plane_index
){
const
int
b_width
=
s
->
b_width
<<
s
->
block_max_depth
;
const
int
b_width
=
s
->
b_width
<<
s
->
block_max_depth
;
const
int
b_height
=
s
->
b_height
<<
s
->
block_max_depth
;
const
int
b_height
=
s
->
b_height
<<
s
->
block_max_depth
;
const
int
b_stride
=
b_width
;
const
int
b_stride
=
b_width
;
...
@@ -3303,14 +3303,14 @@ static void iterative_me(SnowContext *s){
...
@@ -3303,14 +3303,14 @@ static void iterative_me(SnowContext *s){
BlockNode
backup
,
ref_b
;
BlockNode
backup
,
ref_b
;
const
int
index
=
mb_x
+
mb_y
*
b_stride
;
const
int
index
=
mb_x
+
mb_y
*
b_stride
;
BlockNode
*
block
=
&
s
->
block
[
index
];
BlockNode
*
block
=
&
s
->
block
[
index
];
BlockNode
*
tb
=
mb_y
?
&
s
->
block
[
index
-
b_stride
]
:
&
null_block
;
BlockNode
*
tb
=
mb_y
?
&
s
->
block
[
index
-
b_stride
]
:
NULL
;
BlockNode
*
lb
=
mb_x
?
&
s
->
block
[
index
-
1
]
:
&
null_block
;
BlockNode
*
lb
=
mb_x
?
&
s
->
block
[
index
-
1
]
:
NULL
;
BlockNode
*
rb
=
mb_x
+
1
<
b_width
?
&
s
->
block
[
index
+
1
]
:
&
null_block
;
BlockNode
*
rb
=
mb_x
+
1
<
b_width
?
&
s
->
block
[
index
+
1
]
:
NULL
;
BlockNode
*
bb
=
mb_y
+
1
<
b_height
?
&
s
->
block
[
index
+
b_stride
]
:
&
null_block
;
BlockNode
*
bb
=
mb_y
+
1
<
b_height
?
&
s
->
block
[
index
+
b_stride
]
:
NULL
;
BlockNode
*
tlb
=
mb_x
&&
mb_y
?
&
s
->
block
[
index
-
b_stride
-
1
]
:
&
null_block
;
BlockNode
*
tlb
=
mb_x
&&
mb_y
?
&
s
->
block
[
index
-
b_stride
-
1
]
:
NULL
;
BlockNode
*
trb
=
mb_x
+
1
<
b_width
&&
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
;
BlockNode
*
blb
=
mb_x
&&
mb_y
+
1
<
b_height
?
&
s
->
block
[
index
+
b_stride
-
1
]
:
&
null_block
;
BlockNode
*
blb
=
mb_x
&&
mb_y
+
1
<
b_height
?
&
s
->
block
[
index
+
b_stride
-
1
]
:
NULL
;
BlockNode
*
brb
=
mb_x
+
1
<
b_width
&&
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
;
const
int
b_w
=
(
MB_SIZE
>>
s
->
block_max_depth
);
const
int
b_w
=
(
MB_SIZE
>>
s
->
block_max_depth
);
uint8_t
obmc_edged
[
b_w
*
2
][
b_w
*
2
];
uint8_t
obmc_edged
[
b_w
*
2
][
b_w
*
2
];
...
@@ -3397,13 +3397,13 @@ static void iterative_me(SnowContext *s){
...
@@ -3397,13 +3397,13 @@ static void iterative_me(SnowContext *s){
check_block_inter
(
s
,
mb_x
,
mb_y
,
mvr
[
0
][
0
],
mvr
[
0
][
1
],
*
obmc_edged
,
&
best_rd
);
check_block_inter
(
s
,
mb_x
,
mb_y
,
mvr
[
0
][
0
],
mvr
[
0
][
1
],
*
obmc_edged
,
&
best_rd
);
check_block_inter
(
s
,
mb_x
,
mb_y
,
0
,
0
,
*
obmc_edged
,
&
best_rd
);
check_block_inter
(
s
,
mb_x
,
mb_y
,
0
,
0
,
*
obmc_edged
,
&
best_rd
);
if
(
tb
!=&
null_block
)
if
(
tb
)
check_block_inter
(
s
,
mb_x
,
mb_y
,
mvr
[
-
b_stride
][
0
],
mvr
[
-
b_stride
][
1
],
*
obmc_edged
,
&
best_rd
);
check_block_inter
(
s
,
mb_x
,
mb_y
,
mvr
[
-
b_stride
][
0
],
mvr
[
-
b_stride
][
1
],
*
obmc_edged
,
&
best_rd
);
if
(
lb
!=&
null_block
)
if
(
lb
)
check_block_inter
(
s
,
mb_x
,
mb_y
,
mvr
[
-
1
][
0
],
mvr
[
-
1
][
1
],
*
obmc_edged
,
&
best_rd
);
check_block_inter
(
s
,
mb_x
,
mb_y
,
mvr
[
-
1
][
0
],
mvr
[
-
1
][
1
],
*
obmc_edged
,
&
best_rd
);
if
(
rb
!=&
null_block
)
if
(
rb
)
check_block_inter
(
s
,
mb_x
,
mb_y
,
mvr
[
1
][
0
],
mvr
[
1
][
1
],
*
obmc_edged
,
&
best_rd
);
check_block_inter
(
s
,
mb_x
,
mb_y
,
mvr
[
1
][
0
],
mvr
[
1
][
1
],
*
obmc_edged
,
&
best_rd
);
if
(
bb
!=&
null_block
)
if
(
bb
)
check_block_inter
(
s
,
mb_x
,
mb_y
,
mvr
[
b_stride
][
0
],
mvr
[
b_stride
][
1
],
*
obmc_edged
,
&
best_rd
);
check_block_inter
(
s
,
mb_x
,
mb_y
,
mvr
[
b_stride
][
0
],
mvr
[
b_stride
][
1
],
*
obmc_edged
,
&
best_rd
);
/* fullpel ME */
/* fullpel ME */
...
@@ -3442,14 +3442,14 @@ static void iterative_me(SnowContext *s){
...
@@ -3442,14 +3442,14 @@ static void iterative_me(SnowContext *s){
//FIXME RD style color selection
//FIXME RD style color selection
#endif
#endif
if
(
!
same_block
(
block
,
&
backup
)){
if
(
!
same_block
(
block
,
&
backup
)){
if
(
tb
!=
&
null_block
)
tb
->
type
&=
~
BLOCK_OPT
;
if
(
tb
)
tb
->
type
&=
~
BLOCK_OPT
;
if
(
lb
!=
&
null_block
)
lb
->
type
&=
~
BLOCK_OPT
;
if
(
lb
)
lb
->
type
&=
~
BLOCK_OPT
;
if
(
rb
!=
&
null_block
)
rb
->
type
&=
~
BLOCK_OPT
;
if
(
rb
)
rb
->
type
&=
~
BLOCK_OPT
;
if
(
bb
!=
&
null_block
)
bb
->
type
&=
~
BLOCK_OPT
;
if
(
bb
)
bb
->
type
&=
~
BLOCK_OPT
;
if
(
tlb
!=
&
null_block
)
tlb
->
type
&=
~
BLOCK_OPT
;
if
(
tlb
)
tlb
->
type
&=
~
BLOCK_OPT
;
if
(
trb
!=
&
null_block
)
trb
->
type
&=
~
BLOCK_OPT
;
if
(
trb
)
trb
->
type
&=
~
BLOCK_OPT
;
if
(
blb
!=
&
null_block
)
blb
->
type
&=
~
BLOCK_OPT
;
if
(
blb
)
blb
->
type
&=
~
BLOCK_OPT
;
if
(
brb
!=
&
null_block
)
brb
->
type
&=
~
BLOCK_OPT
;
if
(
brb
)
brb
->
type
&=
~
BLOCK_OPT
;
change
++
;
change
++
;
}
}
}
}
...
@@ -3463,7 +3463,7 @@ static void iterative_me(SnowContext *s){
...
@@ -3463,7 +3463,7 @@ static void iterative_me(SnowContext *s){
int
change
=
0
;
int
change
=
0
;
for
(
mb_y
=
0
;
mb_y
<
b_height
;
mb_y
+=
2
){
for
(
mb_y
=
0
;
mb_y
<
b_height
;
mb_y
+=
2
){
for
(
mb_x
=
0
;
mb_x
<
b_width
;
mb_x
+=
2
){
for
(
mb_x
=
0
;
mb_x
<
b_width
;
mb_x
+=
2
){
int
dia_change
,
i
,
j
;
int
i
;
int
best_rd
,
init_rd
;
int
best_rd
,
init_rd
;
const
int
index
=
mb_x
+
mb_y
*
b_stride
;
const
int
index
=
mb_x
+
mb_y
*
b_stride
;
BlockNode
*
b
[
4
];
BlockNode
*
b
[
4
];
...
...
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