Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
W
wine-winehq
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
Registry
Registry
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
wine
wine-winehq
Commits
f6c73a22
Commit
f6c73a22
authored
Jul 19, 2013
by
Dmitry Timoshkov
Committed by
Alexandre Julliard
Jul 19, 2013
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
windowscodecs/tests: Add a test for global GIF palette exposed by recent Windows versions.
parent
5cbf1736
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
29 additions
and
3 deletions
+29
-3
gifformat.c
dlls/windowscodecs/tests/gifformat.c
+29
-3
No files found.
dlls/windowscodecs/tests/gifformat.c
View file @
f6c73a22
...
...
@@ -271,8 +271,9 @@ static void test_local_gif_palette(void)
IWICBitmapDecoder
*
decoder
;
IWICBitmapFrameDecode
*
frame
;
IWICPalette
*
palette
;
WICBitmapPaletteType
type
;
GUID
format
;
UINT
count
,
ret
;
UINT
count
,
ret
,
i
;
WICColor
color
[
256
];
decoder
=
create_decoder
(
gif_local_palette
,
sizeof
(
gif_local_palette
));
...
...
@@ -283,8 +284,28 @@ static void test_local_gif_palette(void)
/* global palette */
hr
=
IWICBitmapDecoder_CopyPalette
(
decoder
,
palette
);
ok
(
hr
==
WINCODEC_ERR_FRAMEMISSING
,
"expected WINCODEC_ERR_FRAMEMISSING, got %#x
\n
"
,
hr
);
todo_wine
ok
(
hr
==
S_OK
||
broken
(
hr
==
WINCODEC_ERR_FRAMEMISSING
),
"CopyPalette %#x
\n
"
,
hr
);
if
(
hr
==
S_OK
)
{
type
=
-
1
;
hr
=
IWICPalette_GetType
(
palette
,
&
type
);
ok
(
hr
==
S_OK
,
"GetType error %#x
\n
"
,
hr
);
ok
(
type
==
WICBitmapPaletteTypeCustom
,
"expected WICBitmapPaletteTypeCustom, got %#x
\n
"
,
type
);
hr
=
IWICPalette_GetColorCount
(
palette
,
&
count
);
ok
(
hr
==
S_OK
,
"GetColorCount error %#x
\n
"
,
hr
);
ok
(
count
==
256
,
"expected 256, got %u
\n
"
,
count
);
hr
=
IWICPalette_GetColors
(
palette
,
count
,
color
,
&
ret
);
ok
(
hr
==
S_OK
,
"GetColors error %#x
\n
"
,
hr
);
ok
(
ret
==
count
,
"expected %u, got %u
\n
"
,
count
,
ret
);
ok
(
color
[
0
]
==
0xff000000
,
"expected 0xff000000, got %#x
\n
"
,
color
[
0
]);
ok
(
color
[
1
]
==
0x00ffffff
,
"expected 0x00ffffff, got %#x
\n
"
,
color
[
1
]);
for
(
i
=
2
;
i
<
256
;
i
++
)
ok
(
color
[
i
]
==
0xff000000
,
"expected 0xff000000, got %#x
\n
"
,
color
[
i
]);
}
/* frame palette */
hr
=
IWICBitmapDecoder_GetFrame
(
decoder
,
0
,
&
frame
);
...
...
@@ -302,6 +323,11 @@ static void test_local_gif_palette(void)
ok
(
hr
==
S_OK
,
"GetColorCount error %#x
\n
"
,
hr
);
ok
(
count
==
4
,
"expected 4, got %u
\n
"
,
count
);
type
=
-
1
;
hr
=
IWICPalette_GetType
(
palette
,
&
type
);
ok
(
hr
==
S_OK
,
"GetType error %#x
\n
"
,
hr
);
ok
(
type
==
WICBitmapPaletteTypeCustom
,
"expected WICBitmapPaletteTypeCustom, got %#x
\n
"
,
type
);
hr
=
IWICPalette_GetColors
(
palette
,
count
,
color
,
&
ret
);
ok
(
hr
==
S_OK
,
"GetColors error %#x
\n
"
,
hr
);
ok
(
ret
==
count
,
"expected %u, got %u
\n
"
,
count
,
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