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
67e7eda9
Commit
67e7eda9
authored
Jun 25, 2012
by
Alexandre Julliard
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
gdi32: Forward SwapBuffers to opengl32 which in turn calls GdiSwapBuffers.
parent
c0139457
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
22 additions
and
12 deletions
+22
-12
gdi32.spec
dlls/gdi32/gdi32.spec
+1
-1
opengl.c
dlls/gdi32/opengl.c
+15
-0
painting.c
dlls/gdi32/painting.c
+3
-9
wgl.c
dlls/opengl32/wgl.c
+3
-2
No files found.
dlls/gdi32/gdi32.spec
View file @
67e7eda9
...
@@ -218,7 +218,7 @@
...
@@ -218,7 +218,7 @@
@ stub GdiSetServerAttr
@ stub GdiSetServerAttr
# @ stub GdiStartDocEMF
# @ stub GdiStartDocEMF
# @ stub GdiStartPageEMF
# @ stub GdiStartPageEMF
# @ stub GdiSwapBuffers
@ stdcall GdiSwapBuffers(long)
@ stdcall GdiTransparentBlt(long long long long long long long long long long long)
@ stdcall GdiTransparentBlt(long long long long long long long long long long long)
# @ stub GdiValidateHandle
# @ stub GdiValidateHandle
@ stub GdiWinWatchClose
@ stub GdiWinWatchClose
...
...
dlls/gdi32/opengl.c
View file @
67e7eda9
...
@@ -43,6 +43,7 @@ static HMODULE opengl32;
...
@@ -43,6 +43,7 @@ static HMODULE opengl32;
static
INT
(
WINAPI
*
wglChoosePixelFormat
)(
HDC
,
const
PIXELFORMATDESCRIPTOR
*
);
static
INT
(
WINAPI
*
wglChoosePixelFormat
)(
HDC
,
const
PIXELFORMATDESCRIPTOR
*
);
static
INT
(
WINAPI
*
wglDescribePixelFormat
)(
HDC
,
INT
,
UINT
,
PIXELFORMATDESCRIPTOR
*
);
static
INT
(
WINAPI
*
wglDescribePixelFormat
)(
HDC
,
INT
,
UINT
,
PIXELFORMATDESCRIPTOR
*
);
static
BOOL
(
WINAPI
*
wglSetPixelFormat
)(
HDC
,
INT
,
const
PIXELFORMATDESCRIPTOR
*
);
static
BOOL
(
WINAPI
*
wglSetPixelFormat
)(
HDC
,
INT
,
const
PIXELFORMATDESCRIPTOR
*
);
static
BOOL
(
WINAPI
*
wglSwapBuffers
)(
HDC
);
static
HDC
default_hdc
=
0
;
static
HDC
default_hdc
=
0
;
...
@@ -267,3 +268,17 @@ BOOL WINAPI SetPixelFormat( HDC hdc, INT fmt, const PIXELFORMATDESCRIPTOR *pfd )
...
@@ -267,3 +268,17 @@ BOOL WINAPI SetPixelFormat( HDC hdc, INT fmt, const PIXELFORMATDESCRIPTOR *pfd )
}
}
return
wglSetPixelFormat
(
hdc
,
fmt
,
pfd
);
return
wglSetPixelFormat
(
hdc
,
fmt
,
pfd
);
}
}
/******************************************************************************
* SwapBuffers (GDI32.@)
*/
BOOL
WINAPI
SwapBuffers
(
HDC
hdc
)
{
if
(
!
wglSwapBuffers
)
{
if
(
!
opengl32
)
opengl32
=
LoadLibraryW
(
opengl32W
);
if
(
!
(
wglSwapBuffers
=
(
void
*
)
GetProcAddress
(
opengl32
,
"wglSwapBuffers"
)))
return
0
;
}
return
wglSwapBuffers
(
hdc
);
}
dlls/gdi32/painting.c
View file @
67e7eda9
...
@@ -562,17 +562,11 @@ INT WINAPI GdiDescribePixelFormat( HDC hdc, INT iPixelFormat, UINT nBytes,
...
@@ -562,17 +562,11 @@ INT WINAPI GdiDescribePixelFormat( HDC hdc, INT iPixelFormat, UINT nBytes,
/******************************************************************************
/******************************************************************************
* SwapBuffers [GDI32.@]
* GdiSwapBuffers [GDI32.@]
* Exchanges front and back buffers of window
*
*
* PARAMS
* Probably not the correct semantics, it's supposed to be an internal backend for SwapBuffers.
* hdc [I] Device context whose buffers get swapped
*
* RETURNS
* Success: TRUE
* Failure: FALSE
*/
*/
BOOL
WINAPI
SwapBuffers
(
HDC
hdc
)
BOOL
WINAPI
Gdi
SwapBuffers
(
HDC
hdc
)
{
{
INT
bRet
=
FALSE
;
INT
bRet
=
FALSE
;
DC
*
dc
=
get_dc_ptr
(
hdc
);
DC
*
dc
=
get_dc_ptr
(
hdc
);
...
...
dlls/opengl32/wgl.c
View file @
67e7eda9
...
@@ -90,6 +90,7 @@ const GLubyte * WINAPI wine_glGetString( GLenum name );
...
@@ -90,6 +90,7 @@ const GLubyte * WINAPI wine_glGetString( GLenum name );
/* internal GDI functions */
/* internal GDI functions */
extern
INT
WINAPI
GdiDescribePixelFormat
(
HDC
hdc
,
INT
fmt
,
UINT
size
,
PIXELFORMATDESCRIPTOR
*
pfd
);
extern
INT
WINAPI
GdiDescribePixelFormat
(
HDC
hdc
,
INT
fmt
,
UINT
size
,
PIXELFORMATDESCRIPTOR
*
pfd
);
extern
BOOL
WINAPI
GdiSetPixelFormat
(
HDC
hdc
,
INT
fmt
,
const
PIXELFORMATDESCRIPTOR
*
pfd
);
extern
BOOL
WINAPI
GdiSetPixelFormat
(
HDC
hdc
,
INT
fmt
,
const
PIXELFORMATDESCRIPTOR
*
pfd
);
extern
BOOL
WINAPI
GdiSwapBuffers
(
HDC
hdc
);
/***********************************************************************
/***********************************************************************
* wglSetPixelFormat(OPENGL32.@)
* wglSetPixelFormat(OPENGL32.@)
...
@@ -560,7 +561,7 @@ BOOL WINAPI wglSwapLayerBuffers(HDC hdc,
...
@@ -560,7 +561,7 @@ BOOL WINAPI wglSwapLayerBuffers(HDC hdc,
TRACE_
(
opengl
)(
"(%p, %08x)
\n
"
,
hdc
,
fuPlanes
);
TRACE_
(
opengl
)(
"(%p, %08x)
\n
"
,
hdc
,
fuPlanes
);
if
(
fuPlanes
&
WGL_SWAP_MAIN_PLANE
)
{
if
(
fuPlanes
&
WGL_SWAP_MAIN_PLANE
)
{
if
(
!
SwapBuffers
(
hdc
))
return
FALSE
;
if
(
!
Gdi
SwapBuffers
(
hdc
))
return
FALSE
;
fuPlanes
&=
~
WGL_SWAP_MAIN_PLANE
;
fuPlanes
&=
~
WGL_SWAP_MAIN_PLANE
;
}
}
...
@@ -1062,7 +1063,7 @@ void WINAPI wine_glGetIntegerv( GLenum pname, GLint* params )
...
@@ -1062,7 +1063,7 @@ void WINAPI wine_glGetIntegerv( GLenum pname, GLint* params )
*/
*/
BOOL
WINAPI
DECLSPEC_HOTPATCH
wglSwapBuffers
(
HDC
hdc
)
BOOL
WINAPI
DECLSPEC_HOTPATCH
wglSwapBuffers
(
HDC
hdc
)
{
{
return
SwapBuffers
(
hdc
);
return
Gdi
SwapBuffers
(
hdc
);
}
}
/* This is for brain-dead applications that use OpenGL functions before even
/* This is for brain-dead applications that use OpenGL functions before even
...
...
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