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
54481679
Commit
54481679
authored
May 13, 2014
by
Stefan Dösinger
Committed by
Alexandre Julliard
May 14, 2014
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
wined3d: Don't update the color table on palette changes.
parent
3cd83f4d
Show whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
11 additions
and
20 deletions
+11
-20
ddraw1.c
dlls/ddraw/tests/ddraw1.c
+2
-2
ddraw2.c
dlls/ddraw/tests/ddraw2.c
+2
-2
ddraw4.c
dlls/ddraw/tests/ddraw4.c
+2
-2
ddraw7.c
dlls/ddraw/tests/ddraw7.c
+2
-2
surface.c
dlls/wined3d/surface.c
+3
-12
No files found.
dlls/ddraw/tests/ddraw1.c
View file @
54481679
...
...
@@ -5126,7 +5126,7 @@ static void test_palette_gdi(void)
i
=
GetDIBColorTable
(
dc
,
4
,
1
,
&
rgbquad
[
4
]);
ok
(
i
==
1
,
"Expected count 1, got %u.
\n
"
,
i
);
todo_wine
ok
(
!
memcmp
(
&
rgbquad
[
4
],
&
expected1
[
4
],
sizeof
(
rgbquad
[
4
])),
ok
(
!
memcmp
(
&
rgbquad
[
4
],
&
expected1
[
4
],
sizeof
(
rgbquad
[
4
])),
"Got color table entry %u r=%#x g=%#x b=%#x, expected r=%#x g=%#x b=%#x.
\n
"
,
i
,
rgbquad
[
4
].
rgbRed
,
rgbquad
[
4
].
rgbGreen
,
rgbquad
[
4
].
rgbBlue
,
expected1
[
4
].
rgbRed
,
expected1
[
4
].
rgbGreen
,
expected1
[
4
].
rgbBlue
);
...
...
@@ -5139,7 +5139,7 @@ static void test_palette_gdi(void)
i
=
GetDIBColorTable
(
dc
,
4
,
1
,
&
rgbquad
[
4
]);
ok
(
i
==
1
,
"Expected count 1, got %u.
\n
"
,
i
);
todo_wine
ok
(
!
memcmp
(
&
rgbquad
[
4
],
&
expected1
[
4
],
sizeof
(
rgbquad
[
4
])),
ok
(
!
memcmp
(
&
rgbquad
[
4
],
&
expected1
[
4
],
sizeof
(
rgbquad
[
4
])),
"Got color table entry %u r=%#x g=%#x b=%#x, expected r=%#x g=%#x b=%#x.
\n
"
,
i
,
rgbquad
[
4
].
rgbRed
,
rgbquad
[
4
].
rgbGreen
,
rgbquad
[
4
].
rgbBlue
,
expected1
[
4
].
rgbRed
,
expected1
[
4
].
rgbGreen
,
expected1
[
4
].
rgbBlue
);
...
...
dlls/ddraw/tests/ddraw2.c
View file @
54481679
...
...
@@ -6194,7 +6194,7 @@ static void test_palette_gdi(void)
i
=
GetDIBColorTable
(
dc
,
4
,
1
,
&
rgbquad
[
4
]);
ok
(
i
==
1
,
"Expected count 1, got %u.
\n
"
,
i
);
todo_wine
ok
(
!
memcmp
(
&
rgbquad
[
4
],
&
expected1
[
4
],
sizeof
(
rgbquad
[
4
])),
ok
(
!
memcmp
(
&
rgbquad
[
4
],
&
expected1
[
4
],
sizeof
(
rgbquad
[
4
])),
"Got color table entry %u r=%#x g=%#x b=%#x, expected r=%#x g=%#x b=%#x.
\n
"
,
i
,
rgbquad
[
4
].
rgbRed
,
rgbquad
[
4
].
rgbGreen
,
rgbquad
[
4
].
rgbBlue
,
expected1
[
4
].
rgbRed
,
expected1
[
4
].
rgbGreen
,
expected1
[
4
].
rgbBlue
);
...
...
@@ -6207,7 +6207,7 @@ static void test_palette_gdi(void)
i
=
GetDIBColorTable
(
dc
,
4
,
1
,
&
rgbquad
[
4
]);
ok
(
i
==
1
,
"Expected count 1, got %u.
\n
"
,
i
);
todo_wine
ok
(
!
memcmp
(
&
rgbquad
[
4
],
&
expected1
[
4
],
sizeof
(
rgbquad
[
4
])),
ok
(
!
memcmp
(
&
rgbquad
[
4
],
&
expected1
[
4
],
sizeof
(
rgbquad
[
4
])),
"Got color table entry %u r=%#x g=%#x b=%#x, expected r=%#x g=%#x b=%#x.
\n
"
,
i
,
rgbquad
[
4
].
rgbRed
,
rgbquad
[
4
].
rgbGreen
,
rgbquad
[
4
].
rgbBlue
,
expected1
[
4
].
rgbRed
,
expected1
[
4
].
rgbGreen
,
expected1
[
4
].
rgbBlue
);
...
...
dlls/ddraw/tests/ddraw4.c
View file @
54481679
...
...
@@ -7096,7 +7096,7 @@ static void test_palette_gdi(void)
i
=
GetDIBColorTable
(
dc
,
4
,
1
,
&
rgbquad
[
4
]);
ok
(
i
==
1
,
"Expected count 1, got %u.
\n
"
,
i
);
todo_wine
ok
(
!
memcmp
(
&
rgbquad
[
4
],
&
expected1
[
4
],
sizeof
(
rgbquad
[
4
])),
ok
(
!
memcmp
(
&
rgbquad
[
4
],
&
expected1
[
4
],
sizeof
(
rgbquad
[
4
])),
"Got color table entry %u r=%#x g=%#x b=%#x, expected r=%#x g=%#x b=%#x.
\n
"
,
i
,
rgbquad
[
4
].
rgbRed
,
rgbquad
[
4
].
rgbGreen
,
rgbquad
[
4
].
rgbBlue
,
expected1
[
4
].
rgbRed
,
expected1
[
4
].
rgbGreen
,
expected1
[
4
].
rgbBlue
);
...
...
@@ -7109,7 +7109,7 @@ static void test_palette_gdi(void)
i
=
GetDIBColorTable
(
dc
,
4
,
1
,
&
rgbquad
[
4
]);
ok
(
i
==
1
,
"Expected count 1, got %u.
\n
"
,
i
);
todo_wine
ok
(
!
memcmp
(
&
rgbquad
[
4
],
&
expected1
[
4
],
sizeof
(
rgbquad
[
4
])),
ok
(
!
memcmp
(
&
rgbquad
[
4
],
&
expected1
[
4
],
sizeof
(
rgbquad
[
4
])),
"Got color table entry %u r=%#x g=%#x b=%#x, expected r=%#x g=%#x b=%#x.
\n
"
,
i
,
rgbquad
[
4
].
rgbRed
,
rgbquad
[
4
].
rgbGreen
,
rgbquad
[
4
].
rgbBlue
,
expected1
[
4
].
rgbRed
,
expected1
[
4
].
rgbGreen
,
expected1
[
4
].
rgbBlue
);
...
...
dlls/ddraw/tests/ddraw7.c
View file @
54481679
...
...
@@ -6818,7 +6818,7 @@ static void test_palette_gdi(void)
i
=
GetDIBColorTable
(
dc
,
4
,
1
,
&
rgbquad
[
4
]);
ok
(
i
==
1
,
"Expected count 1, got %u.
\n
"
,
i
);
todo_wine
ok
(
!
memcmp
(
&
rgbquad
[
4
],
&
expected1
[
4
],
sizeof
(
rgbquad
[
4
])),
ok
(
!
memcmp
(
&
rgbquad
[
4
],
&
expected1
[
4
],
sizeof
(
rgbquad
[
4
])),
"Got color table entry %u r=%#x g=%#x b=%#x, expected r=%#x g=%#x b=%#x.
\n
"
,
i
,
rgbquad
[
4
].
rgbRed
,
rgbquad
[
4
].
rgbGreen
,
rgbquad
[
4
].
rgbBlue
,
expected1
[
4
].
rgbRed
,
expected1
[
4
].
rgbGreen
,
expected1
[
4
].
rgbBlue
);
...
...
@@ -6831,7 +6831,7 @@ static void test_palette_gdi(void)
i
=
GetDIBColorTable
(
dc
,
4
,
1
,
&
rgbquad
[
4
]);
ok
(
i
==
1
,
"Expected count 1, got %u.
\n
"
,
i
);
todo_wine
ok
(
!
memcmp
(
&
rgbquad
[
4
],
&
expected1
[
4
],
sizeof
(
rgbquad
[
4
])),
ok
(
!
memcmp
(
&
rgbquad
[
4
],
&
expected1
[
4
],
sizeof
(
rgbquad
[
4
])),
"Got color table entry %u r=%#x g=%#x b=%#x, expected r=%#x g=%#x b=%#x.
\n
"
,
i
,
rgbquad
[
4
].
rgbRed
,
rgbquad
[
4
].
rgbGreen
,
rgbquad
[
4
].
rgbBlue
,
expected1
[
4
].
rgbRed
,
expected1
[
4
].
rgbGreen
,
expected1
[
4
].
rgbBlue
);
...
...
dlls/wined3d/surface.c
View file @
54481679
...
...
@@ -787,12 +787,6 @@ static void surface_realize_palette(struct wined3d_surface *surface)
}
}
if
(
surface
->
flags
&
SFLAG_DIBSECTION
)
{
TRACE
(
"Updating the DC's palette.
\n
"
);
SetDIBColorTable
(
surface
->
hDC
,
0
,
256
,
palette
->
colors
);
}
/* Propagate the changes to the drawable when we have a palette. */
if
(
surface
->
resource
.
usage
&
WINED3DUSAGE_RENDERTARGET
)
surface_load_location
(
surface
,
surface
->
draw_binding
);
...
...
@@ -1379,17 +1373,14 @@ static void gdi_surface_realize_palette(struct wined3d_surface *surface)
if
(
!
palette
)
return
;
if
(
surface
->
flags
&
SFLAG_DIBSECTION
)
{
TRACE
(
"Updating the DC's palette.
\n
"
);
SetDIBColorTable
(
surface
->
hDC
,
0
,
256
,
palette
->
colors
);
}
/* Update the image because of the palette change. Some games like e.g.
* Red Alert call SetEntries a lot to implement fading. */
/* Tell the swapchain to update the screen. */
if
(
surface
->
swapchain
&&
surface
==
surface
->
swapchain
->
front_buffer
)
{
SetDIBColorTable
(
surface
->
hDC
,
0
,
256
,
palette
->
colors
);
x11_copy_to_screen
(
surface
->
swapchain
,
NULL
);
}
}
static
void
gdi_surface_unmap
(
struct
wined3d_surface
*
surface
)
...
...
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