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
31581603
Commit
31581603
authored
Apr 24, 2012
by
Michael Niedermayer
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
ffv1: move the decoder side ac->vlc switch to decode_slice()
Signed-off-by:
Michael Niedermayer
<
michaelni@gmx.at
>
parent
44f789c0
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
8 additions
and
11 deletions
+8
-11
ffv1.c
libavcodec/ffv1.c
+8
-11
No files found.
libavcodec/ffv1.c
View file @
31581603
...
@@ -1614,6 +1614,13 @@ static int decode_slice(AVCodecContext *c, void *arg){
...
@@ -1614,6 +1614,13 @@ static int decode_slice(AVCodecContext *c, void *arg){
x
=
fs
->
slice_x
;
x
=
fs
->
slice_x
;
y
=
fs
->
slice_y
;
y
=
fs
->
slice_y
;
if
(
!
fs
->
ac
){
fs
->
ac_byte_count
=
f
->
version
>
2
||
(
!
x
&&!
y
)
?
fs
->
c
.
bytestream
-
fs
->
c
.
bytestream_start
-
1
:
0
;
init_get_bits
(
&
fs
->
gb
,
fs
->
c
.
bytestream_start
+
fs
->
ac_byte_count
,
(
fs
->
c
.
bytestream_end
-
fs
->
c
.
bytestream_start
-
fs
->
ac_byte_count
)
*
8
);
}
av_assert1
(
width
&&
height
);
av_assert1
(
width
&&
height
);
if
(
f
->
colorspace
==
0
){
if
(
f
->
colorspace
==
0
){
const
int
chroma_width
=
-
((
-
width
)
>>
f
->
chroma_h_shift
);
const
int
chroma_width
=
-
((
-
width
)
>>
f
->
chroma_h_shift
);
...
@@ -1999,17 +2006,7 @@ static int decode_frame(AVCodecContext *avctx, void *data, int *data_size, AVPac
...
@@ -1999,17 +2006,7 @@ static int decode_frame(AVCodecContext *avctx, void *data, int *data_size, AVPac
}
}
if
(
i
){
if
(
i
){
if
(
fs
->
ac
){
ff_init_range_decoder
(
&
fs
->
c
,
buf_p
,
v
);
ff_init_range_decoder
(
&
fs
->
c
,
buf_p
,
v
);
}
else
{
init_get_bits
(
&
fs
->
gb
,
buf_p
,
v
*
8
);
}
}
else
{
if
(
!
f
->
ac
){
bytes_read
=
c
->
bytestream
-
c
->
bytestream_start
-
1
;
if
(
bytes_read
==
0
)
av_log
(
avctx
,
AV_LOG_ERROR
,
"error at end of AC stream
\n
"
);
//FIXME
init_get_bits
(
&
fs
->
gb
,
buf
+
bytes_read
,
(
buf_size
-
bytes_read
)
*
8
);
}
}
}
}
}
...
...
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