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
2a839e96
Commit
2a839e96
authored
Sep 13, 2007
by
Roderick Colenbrander
Committed by
Alexandre Julliard
Sep 13, 2007
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
wgl: Fix a major ATI regression.
ATI's latest drivers (8.41.7) don't advertise visualids anymore for GLXFBConfigs.
parent
ce4055c5
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
14 additions
and
12 deletions
+14
-12
opengl.c
dlls/winex11.drv/opengl.c
+14
-12
No files found.
dlls/winex11.drv/opengl.c
View file @
2a839e96
...
...
@@ -814,9 +814,10 @@ static int get_render_type_from_fbconfig(Display *display, GLXFBConfig fbconfig)
static
BOOL
init_formats
(
Display
*
display
,
int
screen
,
Visual
*
visual
)
{
int
fmt_id
,
tmp_
vis_id
,
tmp_
fmt_id
,
nCfgs
,
i
;
int
fmt_id
,
tmp_fmt_id
,
nCfgs
,
i
;
GLXFBConfig
*
cfgs
;
GLXFBConfig
fbconfig
=
NULL
;
XVisualInfo
*
visinfo
;
VisualID
visualid
=
XVisualIDFromVisual
(
visual
);
int
nOffscreenFormats
=
0
;
...
...
@@ -833,17 +834,16 @@ static BOOL init_formats(Display *display, int screen, Visual *visual)
/* Count the number of offscreen formats to determine the size for our pixelformat list */
for
(
i
=
0
;
i
<
nCfgs
;
i
++
)
{
pglXGetFBConfigAttrib
(
display
,
cfgs
[
i
],
GLX_
VISUAL_ID
,
&
tmp_vis
_id
);
pglXGetFBConfigAttrib
(
display
,
cfgs
[
i
],
GLX_
FBCONFIG_ID
,
&
tmp_fmt
_id
);
/* We have found Wine's main visual */
if
(
tmp_vis_id
==
visualid
)
{
visinfo
=
pglXGetVisualFromFBConfig
(
display
,
cfgs
[
i
]);
/* Onscreen formats have a corresponding XVisual, offscreen ones don't */
if
(
!
visinfo
)
{
nOffscreenFormats
++
;
}
else
if
(
visinfo
&&
visinfo
->
visualid
==
visualid
)
{
pglXGetFBConfigAttrib
(
display
,
cfgs
[
i
],
GLX_FBCONFIG_ID
,
&
fmt_id
);
fbconfig
=
cfgs
[
i
];
}
/* We have found an offscreen rendering format :) */
if
(
tmp_vis_id
==
0
)
{
nOffscreenFormats
++
;
XFree
(
visinfo
);
}
}
TRACE
(
"Number of offscreen formats: %d
\n
"
,
nOffscreenFormats
);
...
...
@@ -860,11 +860,11 @@ static BOOL init_formats(Display *display, int screen, Visual *visual)
/* Fill the list with offscreen formats */
for
(
i
=
0
;
i
<
nCfgs
;
i
++
)
{
pglXGetFBConfigAttrib
(
display
,
cfgs
[
i
],
GLX_VISUAL_ID
,
&
tmp_vis_id
);
pglXGetFBConfigAttrib
(
display
,
cfgs
[
i
],
GLX_FBCONFIG_ID
,
&
tmp_fmt_id
);
/* We have found an offscreen rendering format :) */
if
(
tmp_vis_id
==
0
)
{
visinfo
=
pglXGetVisualFromFBConfig
(
display
,
cfgs
[
i
]);
/* We have found an offscreen rendering format when there is no visualinfo :) */
if
(
!
visinfo
)
{
TRACE
(
"Found offscreen format FBCONFIG_ID 0x%x corresponding to iPixelFormat %d at GLX index %d
\n
"
,
tmp_fmt_id
,
WineGLPixelFormatListSize
+
1
,
i
);
WineGLPixelFormatList
[
WineGLPixelFormatListSize
].
iPixelFormat
=
WineGLPixelFormatListSize
+
1
;
/* The index starts at 1 */
WineGLPixelFormatList
[
WineGLPixelFormatListSize
].
fbconfig
=
cfgs
[
i
];
...
...
@@ -872,6 +872,8 @@ static BOOL init_formats(Display *display, int screen, Visual *visual)
WineGLPixelFormatList
[
WineGLPixelFormatListSize
].
render_type
=
get_render_type_from_fbconfig
(
display
,
cfgs
[
i
]);
WineGLPixelFormatList
[
WineGLPixelFormatListSize
].
offscreenOnly
=
TRUE
;
WineGLPixelFormatListSize
++
;
}
else
{
XFree
(
visinfo
);
}
}
...
...
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