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
b0c7bee2
Commit
b0c7bee2
authored
Jun 29, 2006
by
Stefan Dösinger
Committed by
Alexandre Julliard
Jun 30, 2006
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
ddraw: Fix some material related bugs.
parent
44ace224
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
20 additions
and
3 deletions
+20
-3
device.c
dlls/ddraw/device.c
+18
-2
material.c
dlls/ddraw/material.c
+1
-0
viewport.c
dlls/ddraw/viewport.c
+1
-1
No files found.
dlls/ddraw/device.c
View file @
b0c7bee2
...
...
@@ -1639,7 +1639,7 @@ IDirect3DDeviceImpl_3_GetCurrentViewport(IDirect3DDevice3 *iface,
*
Direct3DViewport3
=
ICOM_INTERFACE
(
This
->
current_viewport
,
IDirect3DViewport3
);
/* AddRef the returned viewport */
IDirect3DViewport3_AddRef
(
*
Direct3DViewport3
);
if
(
*
Direct3DViewport3
)
IDirect3DViewport3_AddRef
(
*
Direct3DViewport3
);
TRACE
(
" returning interface %p
\n
"
,
*
Direct3DViewport3
);
...
...
@@ -2279,7 +2279,23 @@ IDirect3DDeviceImpl_3_SetLightState(IDirect3DDevice3 *iface,
if
(
LightStateType
==
D3DLIGHTSTATE_MATERIAL
/* 1 */
)
{
IDirect3DMaterialImpl
*
mat
=
(
IDirect3DMaterialImpl
*
)
Value
;
IDirect3DMaterialImpl
*
mat
;
if
(
Value
==
0
)
mat
=
NULL
;
else
if
(
Value
>
This
->
numHandles
)
{
ERR
(
"Material handle out of range(%ld)
\n
"
,
Value
);
return
DDERR_INVALIDPARAMS
;
}
else
if
(
This
->
Handles
[
Value
-
1
].
type
!=
DDrawHandle_Material
)
{
ERR
(
"Invalid handle %ld
\n
"
,
Value
);
return
DDERR_INVALIDPARAMS
;
}
else
{
mat
=
(
IDirect3DMaterialImpl
*
)
This
->
Handles
[
Value
-
1
].
ptr
;
}
if
(
mat
!=
NULL
)
{
...
...
dlls/ddraw/material.c
View file @
b0c7bee2
...
...
@@ -311,6 +311,7 @@ IDirect3DMaterialImpl_GetHandle(IDirect3DMaterial3 *iface,
IDirect3DDeviceImpl
*
device
=
ICOM_OBJECT
(
IDirect3DDeviceImpl
,
IDirect3DDevice3
,
lpDirect3DDevice3
);
TRACE
(
"(%p/%p)->(%p,%p)
\n
"
,
This
,
iface
,
device
,
lpHandle
);
This
->
active_device
=
device
;
if
(
!
This
->
Handle
)
{
This
->
Handle
=
IDirect3DDeviceImpl_CreateHandle
(
device
);
...
...
dlls/ddraw/viewport.c
View file @
b0c7bee2
...
...
@@ -310,7 +310,7 @@ IDirect3DViewportImpl_SetViewport(IDirect3DViewport3 *iface,
IDirect3DDevice3_GetCurrentViewport
(
ICOM_INTERFACE
(
This
->
active_device
,
IDirect3DDevice3
),
&
current_viewport
);
if
(
ICOM_OBJECT
(
IDirect3DViewportImpl
,
IDirect3DViewport3
,
current_viewport
)
==
This
)
This
->
activate
(
This
);
IDirect3DViewport3_Release
(
current_viewport
);
if
(
current_viewport
)
IDirect3DViewport3_Release
(
current_viewport
);
}
return
DD_OK
;
...
...
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