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
68f10822
Commit
68f10822
authored
Dec 08, 2006
by
Stefan Dösinger
Committed by
Alexandre Julliard
Dec 08, 2006
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
wined3d: Move WINED3DRS_SHADEMODE to the state table.
parent
e4b4c040
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
20 additions
and
18 deletions
+20
-18
device.c
dlls/wined3d/device.c
+1
-17
state.c
dlls/wined3d/state.c
+19
-1
No files found.
dlls/wined3d/device.c
View file @
68f10822
...
...
@@ -3440,26 +3440,10 @@ static HRESULT WINAPI IWineD3DDeviceImpl_SetRenderState(IWineD3DDevice *iface, W
case
WINED3DRS_LIGHTING
:
case
WINED3DRS_ZENABLE
:
case
WINED3DRS_CULLMODE
:
case
WINED3DRS_SHADEMODE
:
StateTable
[
STATE_RENDER
(
State
)].
apply
(
STATE_RENDER
(
State
),
This
->
stateBlock
);
break
;
case
WINED3DRS_SHADEMODE
:
switch
((
WINED3DSHADEMODE
)
Value
)
{
case
WINED3DSHADE_FLAT
:
glShadeModel
(
GL_FLAT
);
checkGLcall
(
"glShadeModel"
);
break
;
case
WINED3DSHADE_GOURAUD
:
glShadeModel
(
GL_SMOOTH
);
checkGLcall
(
"glShadeModel"
);
break
;
case
WINED3DSHADE_PHONG
:
FIXME
(
"WINED3DSHADE_PHONG isn't supported
\n
"
);
break
;
default:
FIXME
(
"Unrecognized/Unhandled WINED3DSHADEMODE value %d
\n
"
,
Value
);
}
break
;
case
WINED3DRS_DITHERENABLE
:
if
(
Value
)
{
...
...
dlls/wined3d/state.c
View file @
68f10822
...
...
@@ -154,6 +154,24 @@ static void state_cullmode(DWORD state, IWineD3DStateBlockImpl *stateblock) {
}
}
static
void
state_shademode
(
DWORD
state
,
IWineD3DStateBlockImpl
*
stateblock
)
{
switch
((
WINED3DSHADEMODE
)
stateblock
->
renderState
[
WINED3DRS_SHADEMODE
])
{
case
WINED3DSHADE_FLAT
:
glShadeModel
(
GL_FLAT
);
checkGLcall
(
"glShadeModel(GL_FLAT)"
);
break
;
case
WINED3DSHADE_GOURAUD
:
glShadeModel
(
GL_SMOOTH
);
checkGLcall
(
"glShadeModel(GL_SMOOTH)"
);
break
;
case
WINED3DSHADE_PHONG
:
FIXME
(
"WINED3DSHADE_PHONG isn't supported
\n
"
);
break
;
default:
FIXME
(
"Unrecognized/Unhandled WINED3DSHADEMODE value %d
\n
"
,
stateblock
->
renderState
[
WINED3DRS_SHADEMODE
]);
}
}
const
struct
StateEntry
StateTable
[]
=
{
/* State name representative, apply function */
...
...
@@ -166,7 +184,7 @@ const struct StateEntry StateTable[] =
{
/* 6, WINED3DRS_WRAPV */
STATE_RENDER
(
WINED3DRS_WRAPV
),
state_unknown
},
{
/* 7, WINED3DRS_ZENABLE */
STATE_RENDER
(
WINED3DRS_ZENABLE
),
state_zenable
},
{
/* 8, WINED3DRS_FILLMODE */
STATE_RENDER
(
WINED3DRS_FILLMODE
),
state_fillmode
},
{
/* 9, WINED3DRS_SHADEMODE */
STATE_RENDER
(
WINED3DRS_SHADEMODE
),
state_
unknown
},
{
/* 9, WINED3DRS_SHADEMODE */
STATE_RENDER
(
WINED3DRS_SHADEMODE
),
state_
shademode
},
{
/* 10, WINED3DRS_LINEPATTERN */
STATE_RENDER
(
WINED3DRS_LINEPATTERN
),
state_unknown
},
{
/* 11, WINED3DRS_MONOENABLE */
STATE_RENDER
(
WINED3DRS_MONOENABLE
),
state_unknown
},
{
/* 12, WINED3DRS_ROP2 */
STATE_RENDER
(
WINED3DRS_ROP2
),
state_unknown
},
...
...
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