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
f9240ec0
Commit
f9240ec0
authored
Feb 16, 2015
by
Clément Bœsch
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
avcodec/gif: fix off by one in column offsetting finding
parent
e40e446e
Show whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
17 additions
and
17 deletions
+17
-17
gif.c
libavcodec/gif.c
+2
-2
gifenc-bgr8
tests/ref/fate/gifenc-bgr8
+5
-5
gifenc-pal8
tests/ref/fate/gifenc-pal8
+5
-5
gifenc-rgb8
tests/ref/fate/gifenc-rgb8
+5
-5
No files found.
libavcodec/gif.c
View file @
f9240ec0
...
@@ -108,7 +108,7 @@ static int gif_image_write_image(AVCodecContext *avctx,
...
@@ -108,7 +108,7 @@ static int gif_image_write_image(AVCodecContext *avctx,
/* skip common columns */
/* skip common columns */
while
(
x_start
<
x_end
)
{
while
(
x_start
<
x_end
)
{
int
same_column
=
1
;
int
same_column
=
1
;
for
(
y
=
y_start
;
y
<
y_end
;
y
++
)
{
for
(
y
=
y_start
;
y
<
=
y_end
;
y
++
)
{
if
(
ref
[
y
*
ref_linesize
+
x_start
]
!=
buf
[
y
*
linesize
+
x_start
])
{
if
(
ref
[
y
*
ref_linesize
+
x_start
]
!=
buf
[
y
*
linesize
+
x_start
])
{
same_column
=
0
;
same_column
=
0
;
break
;
break
;
...
@@ -120,7 +120,7 @@ static int gif_image_write_image(AVCodecContext *avctx,
...
@@ -120,7 +120,7 @@ static int gif_image_write_image(AVCodecContext *avctx,
}
}
while
(
x_end
>
x_start
)
{
while
(
x_end
>
x_start
)
{
int
same_column
=
1
;
int
same_column
=
1
;
for
(
y
=
y_start
;
y
<
y_end
;
y
++
)
{
for
(
y
=
y_start
;
y
<
=
y_end
;
y
++
)
{
if
(
ref
[
y
*
ref_linesize
+
x_end
]
!=
buf
[
y
*
linesize
+
x_end
])
{
if
(
ref
[
y
*
ref_linesize
+
x_end
]
!=
buf
[
y
*
linesize
+
x_end
])
{
same_column
=
0
;
same_column
=
0
;
break
;
break
;
...
...
tests/ref/fate/gifenc-bgr8
View file @
f9240ec0
...
@@ -35,15 +35,15 @@
...
@@ -35,15 +35,15 @@
0, 33, 33, 1, 4295, 0xf71b0b38, S=1, 1024, 0xf351799f
0, 33, 33, 1, 4295, 0xf71b0b38, S=1, 1024, 0xf351799f
0, 34, 34, 1, 2044, 0x5adcb93b, S=1, 1024, 0xf351799f
0, 34, 34, 1, 2044, 0x5adcb93b, S=1, 1024, 0xf351799f
0, 35, 35, 1, 3212, 0xcf79eeed, S=1, 1024, 0xf351799f
0, 35, 35, 1, 3212, 0xcf79eeed, S=1, 1024, 0xf351799f
0, 36, 36, 1, 22
81, 0x68464d30
, S=1, 1024, 0xf351799f
0, 36, 36, 1, 22
92, 0xb4386334
, S=1, 1024, 0xf351799f
0, 37, 37, 1, 3633, 0x0010992f, S=1, 1024, 0xf351799f
0, 37, 37, 1, 3633, 0x0010992f, S=1, 1024, 0xf351799f
0, 38, 38, 1, 3552, 0x23697490, S=1, 1024, 0xf351799f
0, 38, 38, 1, 3552, 0x23697490, S=1, 1024, 0xf351799f
0, 39, 39, 1, 3690, 0x62afdbb8, S=1, 1024, 0xf351799f
0, 39, 39, 1, 3690, 0x62afdbb8, S=1, 1024, 0xf351799f
0, 40, 40, 1, 155
8, 0x7a13e53b
, S=1, 1024, 0xf351799f
0, 40, 40, 1, 155
9, 0x5baef54a
, S=1, 1024, 0xf351799f
0, 41, 41, 1, 9
40, 0xb1b6cba2
, S=1, 1024, 0xf351799f
0, 41, 41, 1, 9
54, 0xca75ca79
, S=1, 1024, 0xf351799f
0, 42, 42, 1, 273, 0x3687799b, S=1, 1024, 0xf351799f
0, 42, 42, 1, 273, 0x3687799b, S=1, 1024, 0xf351799f
0, 43, 43, 1, 930, 0x29f3b0c4, S=1, 1024, 0xf351799f
0, 43, 43, 1, 930, 0x29f3b0c4, S=1, 1024, 0xf351799f
0, 44, 44, 1, 271, 0x
e7af807c
, S=1, 1024, 0xf351799f
0, 44, 44, 1, 271, 0x
305e8094
, S=1, 1024, 0xf351799f
0, 45, 45, 1, 196, 0xf5ab51ee, S=1, 1024, 0xf351799f
0, 45, 45, 1, 196, 0xf5ab51ee, S=1, 1024, 0xf351799f
0, 46, 46, 1, 4299, 0x67ec0d55, S=1, 1024, 0xf351799f
0, 46, 46, 1, 4299, 0x67ec0d55, S=1, 1024, 0xf351799f
0, 47, 47, 1, 4895, 0xb394406c, S=1, 1024, 0xf351799f
0, 47, 47, 1, 4895, 0xb394406c, S=1, 1024, 0xf351799f
...
@@ -56,7 +56,7 @@
...
@@ -56,7 +56,7 @@
0, 54, 54, 1, 5179, 0x860fc6a1, S=1, 1024, 0xf351799f
0, 54, 54, 1, 5179, 0x860fc6a1, S=1, 1024, 0xf351799f
0, 55, 55, 1, 5046, 0xce9183d3, S=1, 1024, 0xf351799f
0, 55, 55, 1, 5046, 0xce9183d3, S=1, 1024, 0xf351799f
0, 56, 56, 1, 5140, 0xa6d7b9af, S=1, 1024, 0xf351799f
0, 56, 56, 1, 5140, 0xa6d7b9af, S=1, 1024, 0xf351799f
0, 57, 57, 1, 4
289, 0xb415f717
, S=1, 1024, 0xf351799f
0, 57, 57, 1, 4
301, 0x03b6ef3f
, S=1, 1024, 0xf351799f
0, 58, 58, 1, 5079, 0xa8d59e01, S=1, 1024, 0xf351799f
0, 58, 58, 1, 5079, 0xa8d59e01, S=1, 1024, 0xf351799f
0, 59, 59, 1, 5284, 0xea34e3b3, S=1, 1024, 0xf351799f
0, 59, 59, 1, 5284, 0xea34e3b3, S=1, 1024, 0xf351799f
0, 60, 60, 1, 5426, 0x556a15cd, S=1, 1024, 0xf351799f
0, 60, 60, 1, 5426, 0x556a15cd, S=1, 1024, 0xf351799f
...
...
tests/ref/fate/gifenc-pal8
View file @
f9240ec0
...
@@ -35,15 +35,15 @@
...
@@ -35,15 +35,15 @@
0, 33, 33, 1, 4295, 0xf71b0b38, S=1, 1024, 0xf351799f
0, 33, 33, 1, 4295, 0xf71b0b38, S=1, 1024, 0xf351799f
0, 34, 34, 1, 2044, 0x5adcb93b, S=1, 1024, 0xf351799f
0, 34, 34, 1, 2044, 0x5adcb93b, S=1, 1024, 0xf351799f
0, 35, 35, 1, 3212, 0xcf79eeed, S=1, 1024, 0xf351799f
0, 35, 35, 1, 3212, 0xcf79eeed, S=1, 1024, 0xf351799f
0, 36, 36, 1, 22
81, 0x68464d30
, S=1, 1024, 0xf351799f
0, 36, 36, 1, 22
92, 0xb4386334
, S=1, 1024, 0xf351799f
0, 37, 37, 1, 3633, 0x0010992f, S=1, 1024, 0xf351799f
0, 37, 37, 1, 3633, 0x0010992f, S=1, 1024, 0xf351799f
0, 38, 38, 1, 3552, 0x23697490, S=1, 1024, 0xf351799f
0, 38, 38, 1, 3552, 0x23697490, S=1, 1024, 0xf351799f
0, 39, 39, 1, 3690, 0x62afdbb8, S=1, 1024, 0xf351799f
0, 39, 39, 1, 3690, 0x62afdbb8, S=1, 1024, 0xf351799f
0, 40, 40, 1, 155
8, 0x7a13e53b
, S=1, 1024, 0xf351799f
0, 40, 40, 1, 155
9, 0x5baef54a
, S=1, 1024, 0xf351799f
0, 41, 41, 1, 9
40, 0xb1b6cba2
, S=1, 1024, 0xf351799f
0, 41, 41, 1, 9
54, 0xca75ca79
, S=1, 1024, 0xf351799f
0, 42, 42, 1, 273, 0x3687799b, S=1, 1024, 0xf351799f
0, 42, 42, 1, 273, 0x3687799b, S=1, 1024, 0xf351799f
0, 43, 43, 1, 930, 0x29f3b0c4, S=1, 1024, 0xf351799f
0, 43, 43, 1, 930, 0x29f3b0c4, S=1, 1024, 0xf351799f
0, 44, 44, 1, 271, 0x
e7af807c
, S=1, 1024, 0xf351799f
0, 44, 44, 1, 271, 0x
305e8094
, S=1, 1024, 0xf351799f
0, 45, 45, 1, 196, 0xf5ab51ee, S=1, 1024, 0xf351799f
0, 45, 45, 1, 196, 0xf5ab51ee, S=1, 1024, 0xf351799f
0, 46, 46, 1, 4299, 0x67ec0d55, S=1, 1024, 0xf351799f
0, 46, 46, 1, 4299, 0x67ec0d55, S=1, 1024, 0xf351799f
0, 47, 47, 1, 4895, 0xb394406c, S=1, 1024, 0xf351799f
0, 47, 47, 1, 4895, 0xb394406c, S=1, 1024, 0xf351799f
...
@@ -56,7 +56,7 @@
...
@@ -56,7 +56,7 @@
0, 54, 54, 1, 5179, 0x860fc6a1, S=1, 1024, 0xf351799f
0, 54, 54, 1, 5179, 0x860fc6a1, S=1, 1024, 0xf351799f
0, 55, 55, 1, 5046, 0xce9183d3, S=1, 1024, 0xf351799f
0, 55, 55, 1, 5046, 0xce9183d3, S=1, 1024, 0xf351799f
0, 56, 56, 1, 5140, 0xa6d7b9af, S=1, 1024, 0xf351799f
0, 56, 56, 1, 5140, 0xa6d7b9af, S=1, 1024, 0xf351799f
0, 57, 57, 1, 4
289, 0xb415f717
, S=1, 1024, 0xf351799f
0, 57, 57, 1, 4
301, 0x03b6ef3f
, S=1, 1024, 0xf351799f
0, 58, 58, 1, 5079, 0xa8d59e01, S=1, 1024, 0xf351799f
0, 58, 58, 1, 5079, 0xa8d59e01, S=1, 1024, 0xf351799f
0, 59, 59, 1, 5284, 0xea34e3b3, S=1, 1024, 0xf351799f
0, 59, 59, 1, 5284, 0xea34e3b3, S=1, 1024, 0xf351799f
0, 60, 60, 1, 5426, 0x556a15cd, S=1, 1024, 0xf351799f
0, 60, 60, 1, 5426, 0x556a15cd, S=1, 1024, 0xf351799f
...
...
tests/ref/fate/gifenc-rgb8
View file @
f9240ec0
...
@@ -35,15 +35,15 @@
...
@@ -35,15 +35,15 @@
0, 33, 33, 1, 4295, 0xc1850a80, S=1, 1024, 0xcfc8799f
0, 33, 33, 1, 4295, 0xc1850a80, S=1, 1024, 0xcfc8799f
0, 34, 34, 1, 2044, 0x0440c072, S=1, 1024, 0xcfc8799f
0, 34, 34, 1, 2044, 0x0440c072, S=1, 1024, 0xcfc8799f
0, 35, 35, 1, 3212, 0xe91af08f, S=1, 1024, 0xcfc8799f
0, 35, 35, 1, 3212, 0xe91af08f, S=1, 1024, 0xcfc8799f
0, 36, 36, 1, 22
81, 0x6a414aa1
, S=1, 1024, 0xcfc8799f
0, 36, 36, 1, 22
92, 0x6765633e
, S=1, 1024, 0xcfc8799f
0, 37, 37, 1, 3633, 0xac779aa3, S=1, 1024, 0xcfc8799f
0, 37, 37, 1, 3633, 0xac779aa3, S=1, 1024, 0xcfc8799f
0, 38, 38, 1, 3552, 0xed2c75b2, S=1, 1024, 0xcfc8799f
0, 38, 38, 1, 3552, 0xed2c75b2, S=1, 1024, 0xcfc8799f
0, 39, 39, 1, 3690, 0x2020dd0d, S=1, 1024, 0xcfc8799f
0, 39, 39, 1, 3690, 0x2020dd0d, S=1, 1024, 0xcfc8799f
0, 40, 40, 1, 155
8, 0x2c14e4b2
, S=1, 1024, 0xcfc8799f
0, 40, 40, 1, 155
9, 0x596ef330
, S=1, 1024, 0xcfc8799f
0, 41, 41, 1, 9
40, 0x4927cd90
, S=1, 1024, 0xcfc8799f
0, 41, 41, 1, 9
54, 0xac12c9c5
, S=1, 1024, 0xcfc8799f
0, 42, 42, 1, 273, 0x138c7831, S=1, 1024, 0xcfc8799f
0, 42, 42, 1, 273, 0x138c7831, S=1, 1024, 0xcfc8799f
0, 43, 43, 1, 930, 0xf1c3ae3f, S=1, 1024, 0xcfc8799f
0, 43, 43, 1, 930, 0xf1c3ae3f, S=1, 1024, 0xcfc8799f
0, 44, 44, 1, 271, 0x
6d338044
, S=1, 1024, 0xcfc8799f
0, 44, 44, 1, 271, 0x
921a80af
, S=1, 1024, 0xcfc8799f
0, 45, 45, 1, 196, 0xa5de5322, S=1, 1024, 0xcfc8799f
0, 45, 45, 1, 196, 0xa5de5322, S=1, 1024, 0xcfc8799f
0, 46, 46, 1, 4299, 0x5bac0d86, S=1, 1024, 0xcfc8799f
0, 46, 46, 1, 4299, 0x5bac0d86, S=1, 1024, 0xcfc8799f
0, 47, 47, 1, 4895, 0xc43639a6, S=1, 1024, 0xcfc8799f
0, 47, 47, 1, 4895, 0xc43639a6, S=1, 1024, 0xcfc8799f
...
@@ -56,7 +56,7 @@
...
@@ -56,7 +56,7 @@
0, 54, 54, 1, 5179, 0x97aac3a1, S=1, 1024, 0xcfc8799f
0, 54, 54, 1, 5179, 0x97aac3a1, S=1, 1024, 0xcfc8799f
0, 55, 55, 1, 5046, 0x836a80cd, S=1, 1024, 0xcfc8799f
0, 55, 55, 1, 5046, 0x836a80cd, S=1, 1024, 0xcfc8799f
0, 56, 56, 1, 5140, 0xa725c1e7, S=1, 1024, 0xcfc8799f
0, 56, 56, 1, 5140, 0xa725c1e7, S=1, 1024, 0xcfc8799f
0, 57, 57, 1, 4
289, 0x7b3afbc0
, S=1, 1024, 0xcfc8799f
0, 57, 57, 1, 4
301, 0x0203f239
, S=1, 1024, 0xcfc8799f
0, 58, 58, 1, 5079, 0xb2e7a2de, S=1, 1024, 0xcfc8799f
0, 58, 58, 1, 5079, 0xb2e7a2de, S=1, 1024, 0xcfc8799f
0, 59, 59, 1, 5284, 0xb757dfe1, S=1, 1024, 0xcfc8799f
0, 59, 59, 1, 5284, 0xb757dfe1, S=1, 1024, 0xcfc8799f
0, 60, 60, 1, 5426, 0xf9f11e57, S=1, 1024, 0xcfc8799f
0, 60, 60, 1, 5426, 0xf9f11e57, S=1, 1024, 0xcfc8799f
...
...
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