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
d0a61fd2
Commit
d0a61fd2
authored
Aug 27, 2007
by
Chris Robinson
Committed by
Alexandre Julliard
Aug 28, 2007
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
wined3d: Don't assume the fake DC is the current DC.
parent
a8d4779f
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
11 additions
and
2 deletions
+11
-2
directx.c
dlls/wined3d/directx.c
+11
-2
No files found.
dlls/wined3d/directx.c
View file @
d0a61fd2
...
...
@@ -2512,6 +2512,7 @@ BOOL InitAdapters(void) {
WineD3D_PixelFormat
*
cfgs
;
int
attribute
;
DISPLAY_DEVICEW
DisplayDevice
;
HDC
hdc
;
TRACE
(
"Initializing default adapter
\n
"
);
Adapters
[
0
].
monitorPoint
.
x
=
-
1
;
...
...
@@ -2539,6 +2540,14 @@ BOOL InitAdapters(void) {
return
FALSE
;
}
hdc
=
pwglGetCurrentDC
();
if
(
!
ret
)
{
ERR
(
"Failed to get gl HDC
\n
"
);
HeapFree
(
GetProcessHeap
(),
0
,
Adapters
);
WineD3D_ReleaseFakeGLContext
();
return
FALSE
;
}
Adapters
[
0
].
driver
=
"Display"
;
Adapters
[
0
].
description
=
"Direct3D HAL"
;
...
...
@@ -2549,7 +2558,7 @@ BOOL InitAdapters(void) {
strcpyW
(
Adapters
[
0
].
DeviceName
,
DisplayDevice
.
DeviceName
);
attribute
=
WGL_NUMBER_PIXEL_FORMATS_ARB
;
GL_EXTCALL
(
wglGetPixelFormatAttribivARB
(
wined3d_fake_gl_context_
hdc
,
0
,
0
,
1
,
&
attribute
,
&
Adapters
[
0
].
nCfgs
));
GL_EXTCALL
(
wglGetPixelFormatAttribivARB
(
hdc
,
0
,
0
,
1
,
&
attribute
,
&
Adapters
[
0
].
nCfgs
));
Adapters
[
0
].
cfgs
=
HeapAlloc
(
GetProcessHeap
(),
HEAP_ZERO_MEMORY
,
Adapters
[
0
].
nCfgs
*
sizeof
(
WineD3D_PixelFormat
));
cfgs
=
Adapters
[
0
].
cfgs
;
...
...
@@ -2561,7 +2570,7 @@ BOOL InitAdapters(void) {
PUSH1
(
WGL_STENCIL_BITS_ARB
)
for
(
iPixelFormat
=
1
;
iPixelFormat
<=
Adapters
[
0
].
nCfgs
;
iPixelFormat
++
)
{
res
=
GL_EXTCALL
(
wglGetPixelFormatAttribivARB
(
wined3d_fake_gl_context_
hdc
,
iPixelFormat
,
0
,
nAttribs
,
attribs
,
values
));
res
=
GL_EXTCALL
(
wglGetPixelFormatAttribivARB
(
hdc
,
iPixelFormat
,
0
,
nAttribs
,
attribs
,
values
));
if
(
!
res
)
continue
;
...
...
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