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
7a025001
Commit
7a025001
authored
Jan 02, 2003
by
Lionel Ulmer
Committed by
Alexandre Julliard
Jan 02, 2003
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
- implemented GetTexture
- semi-stubbed ValidateTexture - fixed some errors in logging
parent
6fb7ed8f
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
53 additions
and
28 deletions
+53
-28
main.c
dlls/ddraw/d3ddevice/main.c
+40
-15
main.h
dlls/ddraw/d3ddevice/main.h
+8
-8
mesa.c
dlls/ddraw/d3ddevice/mesa.c
+5
-5
No files found.
dlls/ddraw/d3ddevice/main.c
View file @
7a025001
...
...
@@ -468,12 +468,23 @@ Main_IDirect3DDeviceImpl_7_3T_ComputeSphereVisibility(LPDIRECT3DDEVICE7 iface,
}
HRESULT
WINAPI
Main_IDirect3DDeviceImpl_7_GetTexture
(
LPDIRECT3DDEVICE7
iface
,
DWORD
dwStage
,
LPDIRECTDRAWSURFACE7
*
lpTexture
)
Main_IDirect3DDeviceImpl_7_
3T_
GetTexture
(
LPDIRECT3DDEVICE7
iface
,
DWORD
dwStage
,
LPDIRECTDRAWSURFACE7
*
lpTexture
)
{
ICOM_THIS_FROM
(
IDirect3DDeviceImpl
,
IDirect3DDevice7
,
iface
);
FIXME
(
"(%p/%p)->(%08lx,%p): stub!
\n
"
,
This
,
iface
,
dwStage
,
lpTexture
);
TRACE
(
"(%p/%p)->(%08lx,%p)
\n
"
,
This
,
iface
,
dwStage
,
lpTexture
);
if
(
This
->
current_texture
[
dwStage
]
!=
NULL
)
{
*
lpTexture
=
ICOM_INTERFACE
(
This
->
current_texture
[
dwStage
],
IDirectDrawSurface7
);
}
else
{
*
lpTexture
=
NULL
;
}
TRACE
(
" returning interface at %p (for implementation at %p).
\n
"
,
*
lpTexture
,
This
->
current_texture
[
dwStage
]);
/* Note: should this method increase the reference count for this ?? */
return
DD_OK
;
}
...
...
@@ -514,7 +525,11 @@ Main_IDirect3DDeviceImpl_7_3T_ValidateDevice(LPDIRECT3DDEVICE7 iface,
LPDWORD
lpdwPasses
)
{
ICOM_THIS_FROM
(
IDirect3DDeviceImpl
,
IDirect3DDevice7
,
iface
);
FIXME
(
"(%p/%p)->(%p): stub!
\n
"
,
This
,
iface
,
lpdwPasses
);
FIXME
(
"(%p/%p)->(%p): semi-stub!
\n
"
,
This
,
iface
,
lpdwPasses
);
/* For the moment, we have a VERY good hardware which does everything in one pass :-) */
*
lpdwPasses
=
1
;
return
DD_OK
;
}
...
...
@@ -833,16 +848,6 @@ Main_IDirect3DDeviceImpl_3_2T_SetLightState(LPDIRECT3DDEVICE3 iface,
}
HRESULT
WINAPI
Main_IDirect3DDeviceImpl_3_GetTexture
(
LPDIRECT3DDEVICE3
iface
,
DWORD
dwStage
,
LPDIRECT3DTEXTURE2
*
lplpTexture2
)
{
ICOM_THIS_FROM
(
IDirect3DDeviceImpl
,
IDirect3DDevice3
,
iface
);
FIXME
(
"(%p/%p)->(%08lx,%p): stub!
\n
"
,
This
,
iface
,
dwStage
,
lplpTexture2
);
return
DD_OK
;
}
HRESULT
WINAPI
Main_IDirect3DDeviceImpl_2_SwapTextureHandles
(
LPDIRECT3DDEVICE2
iface
,
LPDIRECT3DTEXTURE2
lpD3DTex1
,
LPDIRECT3DTEXTURE2
lpD3DTex2
)
...
...
@@ -1783,3 +1788,23 @@ Thunk_IDirect3DDeviceImpl_3_DrawIndexedPrimitiveVB(LPDIRECT3DDEVICE3 iface,
dwIndexCount
,
dwFlags
);
}
HRESULT
WINAPI
Thunk_IDirect3DDeviceImpl_3_GetTexture
(
LPDIRECT3DDEVICE3
iface
,
DWORD
dwStage
,
LPDIRECT3DTEXTURE2
*
lplpTexture2
)
{
HRESULT
ret
;
LPDIRECTDRAWSURFACE7
ret_val
;
TRACE
(
"(%p)->(%ld,%p) thunking to IDirect3DDevice7 interface.
\n
"
,
iface
,
dwStage
,
lplpTexture2
);
ret
=
IDirect3DDevice7_GetTexture
(
COM_INTERFACE_CAST
(
IDirect3DDeviceImpl
,
IDirect3DDevice3
,
IDirect3DDevice7
,
iface
),
dwStage
,
&
ret_val
);
*
lplpTexture2
=
COM_INTERFACE_CAST
(
IDirectDrawSurfaceImpl
,
IDirectDrawSurface7
,
IDirect3DTexture2
,
ret_val
);
TRACE
(
" returning interface %p.
\n
"
,
*
lplpTexture2
);
return
ret
;
}
dlls/ddraw/d3ddevice/main.h
View file @
7a025001
...
...
@@ -201,9 +201,9 @@ Main_IDirect3DDeviceImpl_7_3T_ComputeSphereVisibility(LPDIRECT3DDEVICE7 iface,
LPDWORD
lpdwReturnValues
);
HRESULT
WINAPI
Main_IDirect3DDeviceImpl_7_GetTexture
(
LPDIRECT3DDEVICE7
iface
,
DWORD
dwStage
,
LPDIRECTDRAWSURFACE7
*
lpTexture
);
Main_IDirect3DDeviceImpl_7_
3T_
GetTexture
(
LPDIRECT3DDEVICE7
iface
,
DWORD
dwStage
,
LPDIRECTDRAWSURFACE7
*
lpTexture
);
HRESULT
WINAPI
Main_IDirect3DDeviceImpl_7_3T_SetTexture
(
LPDIRECT3DDEVICE7
iface
,
...
...
@@ -345,11 +345,6 @@ Main_IDirect3DDeviceImpl_3_2T_SetLightState(LPDIRECT3DDEVICE3 iface,
DWORD
dwLightState
);
HRESULT
WINAPI
Main_IDirect3DDeviceImpl_3_GetTexture
(
LPDIRECT3DDEVICE3
iface
,
DWORD
dwStage
,
LPDIRECT3DTEXTURE2
*
lplpTexture2
);
HRESULT
WINAPI
Main_IDirect3DDeviceImpl_2_SwapTextureHandles
(
LPDIRECT3DDEVICE2
iface
,
LPDIRECT3DTEXTURE2
lpD3DTex1
,
LPDIRECT3DTEXTURE2
lpD3DTex2
);
...
...
@@ -757,3 +752,8 @@ Thunk_IDirect3DDeviceImpl_3_DrawIndexedPrimitiveVB(LPDIRECT3DDEVICE3 iface,
LPWORD
lpwIndices
,
DWORD
dwIndexCount
,
DWORD
dwFlags
);
HRESULT
WINAPI
Thunk_IDirect3DDeviceImpl_3_GetTexture
(
LPDIRECT3DDEVICE3
iface
,
DWORD
dwStage
,
LPDIRECT3DTEXTURE2
*
lplpTexture2
);
dlls/ddraw/d3ddevice/mesa.c
View file @
7a025001
...
...
@@ -1358,7 +1358,7 @@ GL_IDirect3DDeviceImpl_7_3T_SetTextureStageState(LPDIRECT3DDEVICE7 iface,
gl_state
=
GL_LINEAR
;
break
;
default
:
if
(
TRACE_ON
(
ddraw
))
DPRINTF
(
" state unhandled
.
\n
"
);
if
(
TRACE_ON
(
ddraw
))
DPRINTF
(
" state unhandled
(%ld).
\n
"
,
dwState
);
gl_state
=
GL_LINEAR
;
break
;
}
...
...
@@ -1377,7 +1377,7 @@ GL_IDirect3DDeviceImpl_7_3T_SetTextureStageState(LPDIRECT3DDEVICE7 iface,
gl_state
=
GL_LINEAR
;
break
;
default
:
if
(
TRACE_ON
(
ddraw
))
DPRINTF
(
" state unhandled
.
\n
"
);
if
(
TRACE_ON
(
ddraw
))
DPRINTF
(
" state unhandled
(%ld).
\n
"
,
dwState
);
gl_state
=
GL_LINEAR
;
break
;
}
...
...
@@ -1393,7 +1393,7 @@ GL_IDirect3DDeviceImpl_7_3T_SetTextureStageState(LPDIRECT3DDEVICE7 iface,
case
D3DTADDRESS_WRAP
:
if
(
TRACE_ON
(
ddraw
))
DPRINTF
(
"D3DTADDRESS_WRAP
\n
"
);
arg
=
GL_REPEAT
;
break
;
case
D3DTADDRESS_CLAMP
:
if
(
TRACE_ON
(
ddraw
))
DPRINTF
(
"D3DTADDRESS_CLAMP
\n
"
);
arg
=
GL_CLAMP
;
break
;
case
D3DTADDRESS_BORDER
:
if
(
TRACE_ON
(
ddraw
))
DPRINTF
(
"D3DTADDRESS_BORDER
\n
"
);
arg
=
GL_CLAMP_TO_EDGE
;
break
;
default
:
ERR
(
"Unhandled TEXTUREADDRESS mode %ld !
\n
"
,
dwState
);
default
:
DPRINTF
(
" state unhandled (%ld).
\n
"
,
dwState
);
}
if
((
d3dTexStageStateType
==
D3DTSS_ADDRESS
)
||
(
d3dTexStageStateType
==
D3DTSS_ADDRESSU
))
...
...
@@ -1503,7 +1503,7 @@ ICOM_VTABLE(IDirect3DDevice7) VTABLE_IDirect3DDevice7 =
XCAST
(
DrawPrimitiveVB
)
GL_IDirect3DDeviceImpl_7_3T_DrawPrimitiveVB
,
XCAST
(
DrawIndexedPrimitiveVB
)
GL_IDirect3DDeviceImpl_7_3T_DrawIndexedPrimitiveVB
,
XCAST
(
ComputeSphereVisibility
)
Main_IDirect3DDeviceImpl_7_3T_ComputeSphereVisibility
,
XCAST
(
GetTexture
)
Main_IDirect3DDeviceImpl_7_GetTexture
,
XCAST
(
GetTexture
)
Main_IDirect3DDeviceImpl_7_
3T_
GetTexture
,
XCAST
(
SetTexture
)
GL_IDirect3DDeviceImpl_7_3T_SetTexture
,
XCAST
(
GetTextureStageState
)
Main_IDirect3DDeviceImpl_7_3T_GetTextureStageState
,
XCAST
(
SetTextureStageState
)
GL_IDirect3DDeviceImpl_7_3T_SetTextureStageState
,
...
...
@@ -1571,7 +1571,7 @@ ICOM_VTABLE(IDirect3DDevice3) VTABLE_IDirect3DDevice3 =
XCAST
(
DrawPrimitiveVB
)
Thunk_IDirect3DDeviceImpl_3_DrawPrimitiveVB
,
XCAST
(
DrawIndexedPrimitiveVB
)
Thunk_IDirect3DDeviceImpl_3_DrawIndexedPrimitiveVB
,
XCAST
(
ComputeSphereVisibility
)
Thunk_IDirect3DDeviceImpl_3_ComputeSphereVisibility
,
XCAST
(
GetTexture
)
Main
_IDirect3DDeviceImpl_3_GetTexture
,
XCAST
(
GetTexture
)
Thunk
_IDirect3DDeviceImpl_3_GetTexture
,
XCAST
(
SetTexture
)
Thunk_IDirect3DDeviceImpl_3_SetTexture
,
XCAST
(
GetTextureStageState
)
Thunk_IDirect3DDeviceImpl_3_GetTextureStageState
,
XCAST
(
SetTextureStageState
)
Thunk_IDirect3DDeviceImpl_3_SetTextureStageState
,
...
...
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