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
3d58a065
Commit
3d58a065
authored
Aug 14, 2007
by
Roderick Colenbrander
Committed by
Alexandre Julliard
Aug 14, 2007
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
wined3d: Load wglGetProcAddress from opengl32.dll instead of gdi32.dll when…
wined3d: Load wglGetProcAddress from opengl32.dll instead of gdi32.dll when USE_WIN32_OPENGL is defined.
parent
6af80e44
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
10 additions
and
1 deletion
+10
-1
directx.c
dlls/wined3d/directx.c
+10
-1
No files found.
dlls/wined3d/directx.c
View file @
3d58a065
...
@@ -414,12 +414,22 @@ BOOL IWineD3DImpl_FillGLCaps(WineD3D_GL_Info *gl_info) {
...
@@ -414,12 +414,22 @@ BOOL IWineD3DImpl_FillGLCaps(WineD3D_GL_Info *gl_info) {
TRACE_
(
d3d_caps
)(
"(%p)
\n
"
,
gl_info
);
TRACE_
(
d3d_caps
)(
"(%p)
\n
"
,
gl_info
);
#ifdef USE_WIN32_OPENGL
#define USE_GL_FUNC(pfn) pfn = (void*)GetProcAddress(mod_gl, (const char *) #pfn);
mod_gl
=
LoadLibraryA
(
"opengl32.dll"
);
if
(
!
mod_gl
)
{
ERR
(
"Can't load opengl32.dll!
\n
"
);
return
FALSE
;
}
#else
#define USE_GL_FUNC(pfn) pfn = (void*)p_wglGetProcAddress( (const char *) #pfn);
/* To bypass the opengl32 thunks load wglGetProcAddress from gdi32 (glXGetProcAddress wrapper) instead of opengl32's */
/* To bypass the opengl32 thunks load wglGetProcAddress from gdi32 (glXGetProcAddress wrapper) instead of opengl32's */
mod_gl
=
LoadLibraryA
(
"gdi32.dll"
);
mod_gl
=
LoadLibraryA
(
"gdi32.dll"
);
if
(
!
mod_gl
)
{
if
(
!
mod_gl
)
{
ERR
(
"Can't load gdi32.dll!
\n
"
);
ERR
(
"Can't load gdi32.dll!
\n
"
);
return
FALSE
;
return
FALSE
;
}
}
#endif
p_wglGetProcAddress
=
(
void
*
)
GetProcAddress
(
mod_gl
,
"wglGetProcAddress"
);
p_wglGetProcAddress
=
(
void
*
)
GetProcAddress
(
mod_gl
,
"wglGetProcAddress"
);
if
(
!
p_wglGetProcAddress
)
{
if
(
!
p_wglGetProcAddress
)
{
...
@@ -428,7 +438,6 @@ BOOL IWineD3DImpl_FillGLCaps(WineD3D_GL_Info *gl_info) {
...
@@ -428,7 +438,6 @@ BOOL IWineD3DImpl_FillGLCaps(WineD3D_GL_Info *gl_info) {
}
}
/* Dynamicly load all GL core functions */
/* Dynamicly load all GL core functions */
#define USE_GL_FUNC(pfn) pfn = (void*)p_wglGetProcAddress( (const char *) #pfn);
GL_FUNCS_GEN
;
GL_FUNCS_GEN
;
#undef USE_GL_FUNC
#undef USE_GL_FUNC
...
...
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