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
1fd69243
Commit
1fd69243
authored
Dec 02, 2011
by
Peter Ross
Committed by
Michael Niedermayer
Dec 02, 2011
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
pictordec: support uncompressed images
Signed-off-by:
Michael Niedermayer
<
michaelni@gmx.at
>
parent
bba8975a
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
7 additions
and
4 deletions
+7
-4
pictordec.c
libavcodec/pictordec.c
+7
-4
No files found.
libavcodec/pictordec.c
View file @
1fd69243
...
...
@@ -198,10 +198,10 @@ static int decode_frame(AVCodecContext *avctx,
buf
+=
esize
;
x
=
0
;
y
=
s
->
height
-
1
;
plane
=
0
;
if
(
bytestream_get_le16
(
&
buf
))
{
x
=
0
;
plane
=
0
;
while
(
y
>=
0
&&
buf_end
-
buf
>=
6
)
{
const
uint8_t
*
buf_pend
=
buf
+
FFMIN
(
AV_RL16
(
buf
),
buf_end
-
buf
);
//ignore uncompressed block size reported at buf[2]
...
...
@@ -228,8 +228,11 @@ static int decode_frame(AVCodecContext *avctx,
}
}
}
else
{
av_log_ask_for_sample
(
avctx
,
"uncompressed image
\n
"
);
return
buf_size
;
while
(
y
>=
0
&&
buf
<
buf_end
)
{
memcpy
(
s
->
frame
.
data
[
0
]
+
y
*
s
->
frame
.
linesize
[
0
],
buf
,
FFMIN
(
avctx
->
width
,
buf_end
-
buf
));
buf
+=
avctx
->
width
;
y
--
;
}
}
*
data_size
=
sizeof
(
AVFrame
);
...
...
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