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
663e5a6a
Commit
663e5a6a
authored
Mar 26, 2009
by
Henri Verbeet
Committed by
Alexandre Julliard
Mar 26, 2009
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
wined3d: Simplify the "transformed" check in state_lighting().
It doesn't really matter if lighting is enabled or not if we don't have position data.
parent
a7d61285
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
3 additions
and
7 deletions
+3
-7
state.c
dlls/wined3d/state.c
+3
-7
No files found.
dlls/wined3d/state.c
View file @
663e5a6a
...
...
@@ -81,8 +81,6 @@ static void state_fillmode(DWORD state, IWineD3DStateBlockImpl *stateblock, Wine
}
static
void
state_lighting
(
DWORD
state
,
IWineD3DStateBlockImpl
*
stateblock
,
WineD3DContext
*
context
)
{
BOOL
transformed
;
/* Lighting is not enabled if transformed vertices are drawn
* but lighting does not affect the stream sources, so it is not grouped for performance reasons.
* This state reads the decoded vertex declaration, so if it is dirty don't do anything. The
...
...
@@ -93,11 +91,9 @@ static void state_lighting(DWORD state, IWineD3DStateBlockImpl *stateblock, Wine
return
;
}
transformed
=
((
stateblock
->
wineD3DDevice
->
strided_streams
.
u
.
s
.
position
.
lpData
!=
NULL
||
stateblock
->
wineD3DDevice
->
strided_streams
.
u
.
s
.
position
.
VBO
!=
0
)
&&
stateblock
->
wineD3DDevice
->
strided_streams
.
position_transformed
)
?
TRUE
:
FALSE
;
if
(
stateblock
->
renderState
[
WINED3DRS_LIGHTING
]
&&
!
transformed
)
{
if
(
stateblock
->
renderState
[
WINED3DRS_LIGHTING
]
&&
!
stateblock
->
wineD3DDevice
->
strided_streams
.
position_transformed
)
{
glEnable
(
GL_LIGHTING
);
checkGLcall
(
"glEnable GL_LIGHTING"
);
}
else
{
...
...
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