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
caf9eb85
Commit
caf9eb85
authored
Nov 12, 2011
by
Mashiat Sarker Shakkhar
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Implement revert_cdlms()
parent
d47782df
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
33 additions
and
0 deletions
+33
-0
wmalosslessdec.c
libavcodec/wmalosslessdec.c
+33
-0
No files found.
libavcodec/wmalosslessdec.c
View file @
caf9eb85
...
...
@@ -873,6 +873,39 @@ static void use_normal_update_speed(WmallDecodeCtx *s, int ich)
}
}
static
void
revert_cdlms
(
WmallDecodeCtx
*
s
,
int
tile_size
)
{
int
icoef
,
ich
;
int32_t
pred
,
channel_coeff
;
int
ilms
,
num_lms
;
for
(
ich
=
0
;
ich
<
s
->
num_channels
;
ich
++
)
{
if
(
!
s
->
is_channel_coded
[
ich
])
continue
;
for
(
icoef
=
0
;
icoef
<
tile_size
;
icoef
++
)
{
num_lms
=
s
->
cdlms_ttl
[
ich
];
channel_coeff
=
s
->
channel_residues
[
ich
][
icoef
];
if
(
icoef
==
s
->
transient_pos
[
ich
])
{
s
->
transient
[
ich
]
=
1
;
use_high_update_speed
(
s
,
ich
);
}
for
(
ilms
=
num_lms
;
ilms
>=
0
;
ilms
--
)
{
pred
=
lms_predict
(
s
,
ich
,
ilms
);
channel_coeff
+=
pred
;
lms_update
(
s
,
ich
,
ilms
,
channel_coeff
,
pred
);
}
if
(
s
->
transient
[
ich
])
{
--
s
->
channel
[
ich
].
transient_counter
;
if
(
!
s
->
channel
[
ich
].
transient_counter
)
use_normal_update_speed
(
s
,
ich
);
}
s
->
channel_coeffs
[
ich
][
icoef
]
=
channel_coeff
;
}
}
}
/**
*@brief Decode a single subframe (block).
*@param s codec context
...
...
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