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
78a7c5f2
Commit
78a7c5f2
authored
Oct 03, 2003
by
Jason Edmeades
Committed by
Alexandre Julliard
Oct 03, 2003
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Check for advertized vertex blend support before querying device
capabilities, which silences issues about vertex blending.
parent
72d7e5b1
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
14 additions
and
3 deletions
+14
-3
d3d8_private.h
dlls/d3d8/d3d8_private.h
+1
-0
directx.c
dlls/d3d8/directx.c
+13
-3
No files found.
dlls/d3d8/d3d8_private.h
View file @
78a7c5f2
...
@@ -273,6 +273,7 @@ struct IDirect3D8Impl
...
@@ -273,6 +273,7 @@ struct IDirect3D8Impl
/* IDirect3D8 fields */
/* IDirect3D8 fields */
GL_Info
gl_info
;
GL_Info
gl_info
;
BOOL
isGLInfoValid
;
IDirect3D8Impl
*
direct3d8
;
IDirect3D8Impl
*
direct3d8
;
};
};
...
...
dlls/d3d8/directx.c
View file @
78a7c5f2
...
@@ -55,6 +55,7 @@ static const D3DFORMAT device_formats[NUM_FORMATS] = {
...
@@ -55,6 +55,7 @@ static const D3DFORMAT device_formats[NUM_FORMATS] = {
D3DFMT_X8R8G8B8
D3DFMT_X8R8G8B8
};
};
static
void
IDirect3D8Impl_FillGLCaps
(
LPDIRECT3D8
iface
,
Display
*
display
);
/* retrieve the X display to use on a given DC */
/* retrieve the X display to use on a given DC */
inline
static
Display
*
get_display
(
HDC
hdc
)
inline
static
Display
*
get_display
(
HDC
hdc
)
...
@@ -456,6 +457,10 @@ HRESULT WINAPI IDirect3D8Impl_GetDeviceCaps(LPDIRECT3D8 iface, UINT Adapter, D
...
@@ -456,6 +457,10 @@ HRESULT WINAPI IDirect3D8Impl_GetDeviceCaps(LPDIRECT3D8 iface, UINT Adapter, D
}
else
{
}
else
{
glGetIntegerv
(
GL_MAX_TEXTURE_SIZE
,
&
gl_tex_size
);
glGetIntegerv
(
GL_MAX_TEXTURE_SIZE
,
&
gl_tex_size
);
}
}
/* If we dont know the device settings, go query them now */
if
(
This
->
isGLInfoValid
==
FALSE
)
IDirect3D8Impl_FillGLCaps
(
iface
,
NULL
);
pCaps
->
DeviceType
=
(
DeviceType
==
D3DDEVTYPE_HAL
)
?
D3DDEVTYPE_HAL
:
D3DDEVTYPE_REF
;
/* Not quite true, but use h/w supported by opengl I suppose */
pCaps
->
DeviceType
=
(
DeviceType
==
D3DDEVTYPE_HAL
)
?
D3DDEVTYPE_HAL
:
D3DDEVTYPE_REF
;
/* Not quite true, but use h/w supported by opengl I suppose */
pCaps
->
AdapterOrdinal
=
Adapter
;
pCaps
->
AdapterOrdinal
=
Adapter
;
...
@@ -630,14 +635,14 @@ HRESULT WINAPI IDirect3D8Impl_GetDeviceCaps(LPDIRECT3D8 iface, UINT Adapter, D
...
@@ -630,14 +635,14 @@ HRESULT WINAPI IDirect3D8Impl_GetDeviceCaps(LPDIRECT3D8 iface, UINT Adapter, D
pCaps
->
MaxActiveLights
=
gl_max
;
pCaps
->
MaxActiveLights
=
gl_max
;
TRACE
(
"GLCaps: GL_MAX_LIGHTS=%ld
\n
"
,
pCaps
->
MaxActiveLights
);
TRACE
(
"GLCaps: GL_MAX_LIGHTS=%ld
\n
"
,
pCaps
->
MaxActiveLights
);
#if defined(GL_ARB_vertex_blend)
if
(
GL_SUPPORT
(
ARB_VERTEX_BLEND
))
{
glGetIntegerv
(
GL_MAX_VERTEX_UNITS_ARB
,
&
gl_max
);
glGetIntegerv
(
GL_MAX_VERTEX_UNITS_ARB
,
&
gl_max
);
pCaps
->
MaxVertexBlendMatrices
=
gl_max
;
pCaps
->
MaxVertexBlendMatrices
=
gl_max
;
pCaps
->
MaxVertexBlendMatrixIndex
=
1
;
pCaps
->
MaxVertexBlendMatrixIndex
=
1
;
#else
}
else
{
pCaps
->
MaxVertexBlendMatrices
=
0
;
pCaps
->
MaxVertexBlendMatrices
=
0
;
pCaps
->
MaxVertexBlendMatrixIndex
=
1
;
pCaps
->
MaxVertexBlendMatrixIndex
=
1
;
#endif
}
#if defined(GL_EXT_texture_filter_anisotropic)
#if defined(GL_EXT_texture_filter_anisotropic)
glGetIntegerv
(
GL_MAX_TEXTURE_MAX_ANISOTROPY_EXT
,
&
gl_max
);
glGetIntegerv
(
GL_MAX_TEXTURE_MAX_ANISOTROPY_EXT
,
&
gl_max
);
...
@@ -847,6 +852,7 @@ static void IDirect3D8Impl_FillGLCaps(LPDIRECT3D8 iface, Display* display) {
...
@@ -847,6 +852,7 @@ static void IDirect3D8Impl_FillGLCaps(LPDIRECT3D8 iface, Display* display) {
GL_EXT_FUNCS_GEN
;
GL_EXT_FUNCS_GEN
;
#undef USE_GL_FUNC
#undef USE_GL_FUNC
if
(
display
!=
NULL
)
{
GLX_Extensions
=
glXQueryExtensionsString
(
display
,
DefaultScreen
(
display
));
GLX_Extensions
=
glXQueryExtensionsString
(
display
,
DefaultScreen
(
display
));
FIXME
(
"GLX_Extensions reported:
\n
"
);
FIXME
(
"GLX_Extensions reported:
\n
"
);
...
@@ -866,11 +872,15 @@ static void IDirect3D8Impl_FillGLCaps(LPDIRECT3D8 iface, Display* display) {
...
@@ -866,11 +872,15 @@ static void IDirect3D8Impl_FillGLCaps(LPDIRECT3D8 iface, Display* display) {
if
(
*
GLX_Extensions
==
' '
)
GLX_Extensions
++
;
if
(
*
GLX_Extensions
==
' '
)
GLX_Extensions
++
;
}
}
}
}
}
#define USE_GL_FUNC(type, pfn) This->gl_info.pfn = (type) glXGetProcAddressARB(#pfn);
#define USE_GL_FUNC(type, pfn) This->gl_info.pfn = (type) glXGetProcAddressARB(#pfn);
GLX_EXT_FUNCS_GEN
;
GLX_EXT_FUNCS_GEN
;
#undef USE_GL_FUNC
#undef USE_GL_FUNC
/* Only save the values obtained when a display is provided */
if
(
display
!=
NULL
)
This
->
isGLInfoValid
=
TRUE
;
}
}
HRESULT
WINAPI
IDirect3D8Impl_CreateDevice
(
LPDIRECT3D8
iface
,
HRESULT
WINAPI
IDirect3D8Impl_CreateDevice
(
LPDIRECT3D8
iface
,
...
...
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