Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
W
wine-cw
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-cw
Commits
ad7bc71c
Commit
ad7bc71c
authored
Oct 14, 2006
by
Roderick Colenbrander
Committed by
Alexandre Julliard
Oct 16, 2006
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
wgl: Move wglGetCurrentContext to gdi32.
parent
ef998ea6
Hide whitespace changes
Inline
Side-by-side
Showing
6 changed files
with
17 additions
and
36 deletions
+17
-36
gdi32.spec
dlls/gdi/gdi32.spec
+1
-0
opengl.c
dlls/gdi/opengl.c
+12
-0
opengl32.spec
dlls/opengl32/opengl32.spec
+1
-1
wgl.c
dlls/opengl32/wgl.c
+0
-10
opengl.c
dlls/winex11.drv/opengl.c
+3
-24
winex11.drv.spec
dlls/winex11.drv/winex11.drv.spec
+0
-1
No files found.
dlls/gdi/gdi32.spec
View file @
ad7bc71c
...
...
@@ -499,6 +499,7 @@
# Wine extensions: OpenGL support
#
@ stdcall wglCreateContext(long)
@ stdcall wglGetCurrentContext()
@ stdcall wglMakeCurrent(long long)
@ stdcall wglUseFontBitmapsA(long long long long)
@ stdcall wglUseFontBitmapsW(long long long long)
...
...
dlls/gdi/opengl.c
View file @
ad7bc71c
...
...
@@ -31,6 +31,8 @@
#include "winbase.h"
#include "wingdi.h"
#include "winerror.h"
#include "winternl.h"
#include "winnt.h"
#include "gdi.h"
#include "gdi_private.h"
#include "wine/debug.h"
...
...
@@ -73,6 +75,16 @@ HGLRC WINAPI wglCreateContext(HDC hdc)
}
/***********************************************************************
* wglGetCurrentContext (OPENGL32.@)
*/
HGLRC
WINAPI
wglGetCurrentContext
(
void
)
{
HGLRC
ret
=
NtCurrentTeb
()
->
glContext
;
TRACE
(
" returning %p
\n
"
,
ret
);
return
ret
;
}
/***********************************************************************
* wglMakeCurrent (OPENGL32.@)
*/
BOOL
WINAPI
wglMakeCurrent
(
HDC
hdc
,
HGLRC
hglrc
)
...
...
dlls/opengl32/opengl32.spec
View file @
ad7bc71c
...
...
@@ -381,7 +381,7 @@
@ stdcall wglDeleteContext(long)
@ stdcall wglDescribeLayerPlane(long long long long ptr)
@ stdcall wglDescribePixelFormat(long long long ptr) gdi32.DescribePixelFormat
@ stdcall wglGetCurrentContext()
@ stdcall wglGetCurrentContext()
gdi32.wglGetCurrentContext
@ stdcall wglGetCurrentDC()
@ stub wglGetDefaultProcAddress
@ stdcall wglGetLayerPaletteEntries(long long long long ptr)
...
...
dlls/opengl32/wgl.c
View file @
ad7bc71c
...
...
@@ -48,7 +48,6 @@ WINE_DECLARE_DEBUG_CHANNEL(opengl);
typedef
struct
wine_wgl_s
{
BOOL
WINAPI
(
*
p_wglDeleteContext
)(
HGLRC
hglrc
);
HGLRC
WINAPI
(
*
p_wglGetCurrentContext
)(
void
);
HDC
WINAPI
(
*
p_wglGetCurrentDC
)(
void
);
PROC
WINAPI
(
*
p_wglGetProcAddress
)(
LPCSTR
lpszProc
);
BOOL
WINAPI
(
*
p_wglShareLists
)(
HGLRC
hglrc1
,
HGLRC
hglrc2
);
...
...
@@ -173,14 +172,6 @@ BOOL WINAPI wglDescribeLayerPlane(HDC hdc,
}
/***********************************************************************
* wglGetCurrentContext (OPENGL32.@)
*/
HGLRC
WINAPI
wglGetCurrentContext
(
void
)
{
TRACE
(
"
\n
"
);
return
wine_wgl
.
p_wglGetCurrentContext
();
}
/***********************************************************************
* wglGetCurrentDC (OPENGL32.@)
*/
HDC
WINAPI
wglGetCurrentDC
(
void
)
{
...
...
@@ -650,7 +641,6 @@ static BOOL process_attach(void)
/* Load WGL function pointers from winex11.drv */
wine_wgl
.
p_wglDeleteContext
=
(
void
*
)
GetProcAddress
(
mod
,
"wglDeleteContext"
);
wine_wgl
.
p_wglGetCurrentContext
=
(
void
*
)
GetProcAddress
(
mod
,
"wglGetCurrentContext"
);
wine_wgl
.
p_wglGetCurrentDC
=
(
void
*
)
GetProcAddress
(
mod
,
"wglGetCurrentDC"
);
wine_wgl
.
p_wglGetProcAddress
=
(
void
*
)
GetProcAddress
(
mod
,
"wglGetProcAddress"
);
wine_wgl
.
p_wglShareLists
=
(
void
*
)
GetProcAddress
(
mod
,
"wglShareLists"
);
...
...
dlls/winex11.drv/opengl.c
View file @
ad7bc71c
...
...
@@ -1272,23 +1272,6 @@ BOOL WINAPI X11DRV_wglDeleteContext(HGLRC hglrc)
return
ret
;
}
/* OpenGL32 wglGetCurrentContext() */
HGLRC
WINAPI
X11DRV_wglGetCurrentContext
(
void
)
{
GLXContext
gl_ctx
;
Wine_GLContext
*
ret
;
TRACE
(
"()
\n
"
);
wine_tsx11_lock
();
gl_ctx
=
pglXGetCurrentContext
();
ret
=
get_context_from_GLXContext
(
gl_ctx
);
wine_tsx11_unlock
();
TRACE
(
" returning %p (GL context %p)
\n
"
,
ret
,
gl_ctx
);
return
(
HGLRC
)
ret
;
}
/* OpenGL32 wglGetCurrentDC */
HDC
WINAPI
X11DRV_wglGetCurrentDC
(
void
)
{
GLXContext
gl_ctx
;
...
...
@@ -1417,6 +1400,7 @@ static BOOL WINAPI X11DRV_wglMakeContextCurrentARB(HDC hDrawDC, HDC hReadDC, HGL
wine_tsx11_lock
();
if
(
hglrc
==
NULL
)
{
ret
=
pglXMakeCurrent
(
gdi_display
,
None
,
NULL
);
NtCurrentTeb
()
->
glContext
=
NULL
;
}
else
{
if
(
NULL
==
pglXMakeContextCurrent
)
{
ret
=
FALSE
;
...
...
@@ -1430,6 +1414,7 @@ static BOOL WINAPI X11DRV_wglMakeContextCurrentARB(HDC hDrawDC, HDC hReadDC, HGL
TRACE
(
" created a delayed OpenGL context (%p)
\n
"
,
ctx
->
ctx
);
}
ret
=
pglXMakeContextCurrent
(
ctx
->
display
,
d_draw
,
d_read
,
ctx
->
ctx
);
NtCurrentTeb
()
->
glContext
=
ctx
;
}
}
wine_tsx11_unlock
();
...
...
@@ -2369,7 +2354,7 @@ static GLboolean WINAPI X11DRV_wglBindTexImageARB(HPBUFFERARB hPbuffer, int iBuf
do_init
=
1
;
}
object
->
prev_hdc
=
X11DRV_wglGetCurrentDC
();
object
->
prev_ctx
=
X11DRV_
wglGetCurrentContext
();
object
->
prev_ctx
=
wglGetCurrentContext
();
/* FIXME: This is routed through gdi32.dll to winex11.drv, replace this with GLX calls */
wglMakeCurrent
(
object
->
render_hdc
,
object
->
render_ctx
);
/*
...
...
@@ -2799,12 +2784,6 @@ BOOL WINAPI X11DRV_wglDeleteContext(HGLRC hglrc) {
return
FALSE
;
}
/* OpenGL32 wglGetCurrentContext() */
HGLRC
WINAPI
X11DRV_wglGetCurrentContext
(
void
)
{
ERR_
(
opengl
)(
"No OpenGL support compiled in.
\n
"
);
return
NULL
;
}
/* OpenGL32 wglGetCurrentDC */
HDC
WINAPI
X11DRV_wglGetCurrentDC
(
void
)
{
ERR_
(
opengl
)(
"No OpenGL support compiled in.
\n
"
);
...
...
dlls/winex11.drv/winex11.drv.spec
View file @
ad7bc71c
...
...
@@ -131,7 +131,6 @@
# OpenGL
@ cdecl wglCreateContext(long) X11DRV_wglCreateContext
@ cdecl wglDeleteContext(long) X11DRV_wglDeleteContext
@ cdecl wglGetCurrentContext() X11DRV_wglGetCurrentContext
@ cdecl wglGetCurrentDC() X11DRV_wglGetCurrentDC
@ cdecl wglGetIntegerv(long ptr) X11DRV_wglGetIntegerv
@ cdecl wglGetProcAddress(ptr) X11DRV_wglGetProcAddress
...
...
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