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
94a7cd42
Commit
94a7cd42
authored
Mar 26, 2009
by
Tobias Jakobi
Committed by
Alexandre Julliard
Mar 31, 2009
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
wined3d: Simplify sampler_texmatrix using pow2Matrix_identity.
parent
38239be5
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
2 additions
and
17 deletions
+2
-17
state.c
dlls/wined3d/state.c
+2
-17
No files found.
dlls/wined3d/state.c
View file @
94a7cd42
...
...
@@ -3290,8 +3290,7 @@ static void tex_bumpenvlscale(DWORD state, IWineD3DStateBlockImpl *stateblock, W
}
static
void
sampler_texmatrix
(
DWORD
state
,
IWineD3DStateBlockImpl
*
stateblock
,
WineD3DContext
*
context
)
{
BOOL
texIsPow2
=
FALSE
;
DWORD
sampler
=
state
-
STATE_SAMPLER
(
0
);
const
DWORD
sampler
=
state
-
STATE_SAMPLER
(
0
);
IWineD3DBaseTexture
*
texture
=
stateblock
->
textures
[
sampler
];
TRACE
(
"state %#x, stateblock %p, context %p
\n
"
,
state
,
stateblock
,
context
);
...
...
@@ -3305,21 +3304,7 @@ static void sampler_texmatrix(DWORD state, IWineD3DStateBlockImpl *stateblock, W
* misc pipeline
*/
if
(
sampler
<
MAX_TEXTURES
)
{
UINT
texture_dimensions
=
IWineD3DBaseTexture_GetTextureDimensions
(
texture
);
if
(
texture_dimensions
==
GL_TEXTURE_2D
||
texture_dimensions
==
GL_TEXTURE_RECTANGLE_ARB
)
{
if
(((
IWineD3DTextureImpl
*
)
texture
)
->
baseTexture
.
pow2Matrix
[
0
]
!=
1
.
0
||
((
IWineD3DTextureImpl
*
)
texture
)
->
baseTexture
.
pow2Matrix
[
5
]
!=
1
.
0
)
{
texIsPow2
=
TRUE
;
}
}
else
if
(
texture_dimensions
==
GL_TEXTURE_CUBE_MAP_ARB
)
{
if
(((
IWineD3DCubeTextureImpl
*
)
texture
)
->
baseTexture
.
pow2Matrix
[
0
]
!=
1
.
0
)
{
texIsPow2
=
TRUE
;
}
}
const
BOOL
texIsPow2
=
!
((
IWineD3DBaseTextureImpl
*
)
texture
)
->
baseTexture
.
pow2Matrix_identity
;
if
(
texIsPow2
||
(
context
->
lastWasPow2Texture
&
(
1
<<
sampler
)))
{
...
...
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