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
58ded09b
Commit
58ded09b
authored
Feb 03, 2016
by
Timothy Gu
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
dirac_dwt: Rename init2 to init
The functions are all private.
parent
6cdde20b
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
16 additions
and
16 deletions
+16
-16
dirac_dwt.c
libavcodec/dirac_dwt.c
+6
-6
dirac_dwt.h
libavcodec/dirac_dwt.h
+3
-3
dirac_dwt_template.c
libavcodec/dirac_dwt_template.c
+5
-5
diracdec.c
libavcodec/diracdec.c
+2
-2
No files found.
libavcodec/dirac_dwt.c
View file @
58ded09b
...
...
@@ -33,9 +33,9 @@
#define TEMPLATE_12bit
#include "dirac_dwt_template.c"
int
ff_spatial_idwt_init
2
(
DWTContext
*
d
,
uint8_t
*
buffer
,
int
width
,
int
height
,
int
stride
,
enum
dwt_type
type
,
int
decomposition_count
,
uint8_t
*
temp
,
int
bit_depth
)
int
ff_spatial_idwt_init
(
DWTContext
*
d
,
uint8_t
*
buffer
,
int
width
,
int
height
,
int
stride
,
enum
dwt_type
type
,
int
decomposition_count
,
uint8_t
*
temp
,
int
bit_depth
)
{
int
ret
=
0
;
...
...
@@ -47,11 +47,11 @@ int ff_spatial_idwt_init2(DWTContext *d, uint8_t *buffer, int width, int height,
d
->
temp
=
temp
;
if
(
bit_depth
==
8
)
ret
=
ff_spatial_idwt_init
2
_8bit
(
d
,
type
);
ret
=
ff_spatial_idwt_init_8bit
(
d
,
type
);
else
if
(
bit_depth
==
10
)
ret
=
ff_spatial_idwt_init
2
_10bit
(
d
,
type
);
ret
=
ff_spatial_idwt_init_10bit
(
d
,
type
);
else
if
(
bit_depth
==
12
)
ret
=
ff_spatial_idwt_init
2
_12bit
(
d
,
type
);
ret
=
ff_spatial_idwt_init_12bit
(
d
,
type
);
else
av_log
(
NULL
,
AV_LOG_WARNING
,
"Unsupported bit depth = %i
\n
"
,
bit_depth
);
...
...
libavcodec/dirac_dwt.h
View file @
58ded09b
...
...
@@ -76,9 +76,9 @@ enum dwt_type {
};
// -1 if an error occurred, e.g. the dwt_type isn't recognized
int
ff_spatial_idwt_init
2
(
DWTContext
*
d
,
uint8_t
*
buffer
,
int
width
,
int
height
,
int
stride
,
enum
dwt_type
type
,
int
decomposition_count
,
uint8_t
*
temp
,
int
bit_depth
);
int
ff_spatial_idwt_init
(
DWTContext
*
d
,
uint8_t
*
buffer
,
int
width
,
int
height
,
int
stride
,
enum
dwt_type
type
,
int
decomposition_count
,
uint8_t
*
temp
,
int
bit_depth
);
void
ff_spatial_idwt_init_x86
(
DWTContext
*
d
,
enum
dwt_type
type
);
void
ff_spatial_idwt_slice2
(
DWTContext
*
d
,
int
y
);
...
...
libavcodec/dirac_dwt_template.c
View file @
58ded09b
...
...
@@ -476,7 +476,7 @@ static void RENAME(spatial_compose_daub97i_dy)(DWTContext *d, int level, int wid
cs
->
y
+=
2
;
}
static
void
RENAME
(
spatial_compose97i_init
2
)(
DWTCompose
*
cs
,
uint8_t
*
buffer
,
int
height
,
int
stride
)
static
void
RENAME
(
spatial_compose97i_init
)(
DWTCompose
*
cs
,
uint8_t
*
buffer
,
int
height
,
int
stride
)
{
cs
->
b
[
0
]
=
buffer
+
avpriv_mirror
(
-
3
-
1
,
height
-
1
)
*
stride
;
cs
->
b
[
1
]
=
buffer
+
avpriv_mirror
(
-
3
,
height
-
1
)
*
stride
;
...
...
@@ -485,7 +485,7 @@ static void RENAME(spatial_compose97i_init2)(DWTCompose *cs, uint8_t *buffer, in
cs
->
y
=
-
3
;
}
static
void
RENAME
(
spatial_compose53i_init
2
)(
DWTCompose
*
cs
,
uint8_t
*
buffer
,
int
height
,
int
stride
)
static
void
RENAME
(
spatial_compose53i_init
)(
DWTCompose
*
cs
,
uint8_t
*
buffer
,
int
height
,
int
stride
)
{
cs
->
b
[
0
]
=
buffer
+
avpriv_mirror
(
-
1
-
1
,
height
-
1
)
*
stride
;
cs
->
b
[
1
]
=
buffer
+
avpriv_mirror
(
-
1
,
height
-
1
)
*
stride
;
...
...
@@ -516,7 +516,7 @@ static void RENAME(spatial_compose_dd137i_init)(DWTCompose *cs, uint8_t *buffer,
cs
->
y
=
-
5
;
}
static
int
RENAME
(
ff_spatial_idwt_init
2
)(
DWTContext
*
d
,
enum
dwt_type
type
)
static
int
RENAME
(
ff_spatial_idwt_init
)(
DWTContext
*
d
,
enum
dwt_type
type
)
{
int
level
;
...
...
@@ -531,7 +531,7 @@ static int RENAME(ff_spatial_idwt_init2)(DWTContext *d, enum dwt_type type)
RENAME
(
spatial_compose_dd97i_init
)(
d
->
cs
+
level
,
d
->
buffer
,
hl
,
stride_l
);
break
;
case
DWT_DIRAC_LEGALL5_3
:
RENAME
(
spatial_compose53i_init
2
)(
d
->
cs
+
level
,
d
->
buffer
,
hl
,
stride_l
);
RENAME
(
spatial_compose53i_init
)(
d
->
cs
+
level
,
d
->
buffer
,
hl
,
stride_l
);
break
;
case
DWT_DIRAC_DD13_7
:
RENAME
(
spatial_compose_dd137i_init
)(
d
->
cs
+
level
,
d
->
buffer
,
hl
,
stride_l
);
...
...
@@ -541,7 +541,7 @@ static int RENAME(ff_spatial_idwt_init2)(DWTContext *d, enum dwt_type type)
d
->
cs
[
level
].
y
=
1
;
break
;
case
DWT_DIRAC_DAUB9_7
:
RENAME
(
spatial_compose97i_init
2
)(
d
->
cs
+
level
,
d
->
buffer
,
hl
,
stride_l
);
RENAME
(
spatial_compose97i_init
)(
d
->
cs
+
level
,
d
->
buffer
,
hl
,
stride_l
);
break
;
default:
d
->
cs
[
level
].
y
=
0
;
...
...
libavcodec/diracdec.c
View file @
58ded09b
...
...
@@ -1755,8 +1755,8 @@ static int dirac_decode_frame_internal(DiracContext *s)
memset
(
p
->
idwt_buf
,
0
,
p
->
idwt_stride
*
p
->
idwt_height
);
decode_component
(
s
,
comp
);
/* [DIRAC_STD] 13.4.1 core_transform_data() */
}
ret
=
ff_spatial_idwt_init
2
(
&
d
,
p
->
idwt_buf
,
p
->
idwt_width
,
p
->
idwt_height
,
p
->
idwt_stride
,
s
->
wavelet_idx
+
2
,
s
->
wavelet_depth
,
p
->
idwt_tmp
,
s
->
bit_depth
);
ret
=
ff_spatial_idwt_init
(
&
d
,
p
->
idwt_buf
,
p
->
idwt_width
,
p
->
idwt_height
,
p
->
idwt_stride
,
s
->
wavelet_idx
+
2
,
s
->
wavelet_depth
,
p
->
idwt_tmp
,
s
->
bit_depth
);
if
(
ret
<
0
)
return
ret
;
...
...
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