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
481bcdfe
Commit
481bcdfe
authored
Apr 06, 2008
by
Stefan Dösinger
Committed by
Alexandre Julliard
Apr 09, 2008
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
wined3d: Disable MAG filters on formats that do not support them.
parent
a22203ad
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
12 additions
and
1 deletion
+12
-1
basetexture.c
dlls/wined3d/basetexture.c
+1
-1
device.c
dlls/wined3d/device.c
+6
-0
directx.c
dlls/wined3d/directx.c
+3
-0
wined3d_private.h
dlls/wined3d/wined3d_private.h
+2
-0
No files found.
dlls/wined3d/basetexture.c
View file @
481bcdfe
...
...
@@ -434,7 +434,7 @@ void WINAPI IWineD3DBaseTextureImpl_ApplyStateChanges(IWineD3DBaseTexture *iface
if
(
state
<
WINED3DTEXF_NONE
||
state
>
WINED3DTEXF_ANISOTROPIC
)
{
FIXME
(
"Unrecognized or unsupported MAGFILTER* value %d
\n
"
,
state
);
}
glValue
=
magLookup
[
state
-
WINED3DTEXF_NONE
];
glValue
=
(
*
This
->
baseTexture
.
magLookup
)
[
state
-
WINED3DTEXF_NONE
];
TRACE
(
"ValueMAG=%d setting MAGFILTER to %x
\n
"
,
state
,
glValue
);
glTexParameteri
(
textureDimensions
,
GL_TEXTURE_MAG_FILTER
,
glValue
);
/* We need to reset the Anisotropic filtering state when we change the mag filter to WINED3DTEXF_ANISOTROPIC (this seems a bit weird, check the documentation to see how it should be switched off. */
...
...
dlls/wined3d/device.c
View file @
481bcdfe
...
...
@@ -792,8 +792,10 @@ static HRESULT WINAPI IWineD3DDeviceImpl_CreateTexture(IWineD3DDevice *iface, U
if
(
glDesc
->
Flags
&
WINED3DFMT_FLAG_FILTERING
)
{
object
->
baseTexture
.
minMipLookup
=
&
minMipLookup
;
object
->
baseTexture
.
magLookup
=
&
magLookup
;
}
else
{
object
->
baseTexture
.
minMipLookup
=
&
minMipLookup_noFilter
;
object
->
baseTexture
.
magLookup
=
&
magLookup_noFilter
;
}
/** Non-power2 support **/
...
...
@@ -942,8 +944,10 @@ static HRESULT WINAPI IWineD3DDeviceImpl_CreateVolumeTexture(IWineD3DDevice *ifa
if
(
glDesc
->
Flags
&
WINED3DFMT_FLAG_FILTERING
)
{
object
->
baseTexture
.
minMipLookup
=
&
minMipLookup
;
object
->
baseTexture
.
magLookup
=
&
magLookup
;
}
else
{
object
->
baseTexture
.
minMipLookup
=
&
minMipLookup_noFilter
;
object
->
baseTexture
.
magLookup
=
&
magLookup_noFilter
;
}
/* Calculate levels for mip mapping */
...
...
@@ -1095,8 +1099,10 @@ static HRESULT WINAPI IWineD3DDeviceImpl_CreateCubeTexture(IWineD3DDevice *iface
if
(
glDesc
->
Flags
&
WINED3DFMT_FLAG_FILTERING
)
{
object
->
baseTexture
.
minMipLookup
=
&
minMipLookup
;
object
->
baseTexture
.
magLookup
=
&
magLookup
;
}
else
{
object
->
baseTexture
.
minMipLookup
=
&
minMipLookup_noFilter
;
object
->
baseTexture
.
magLookup
=
&
magLookup_noFilter
;
}
/* Calculate levels for mip mapping */
...
...
dlls/wined3d/directx.c
View file @
481bcdfe
...
...
@@ -163,6 +163,9 @@ DWORD minMipLookup_noFilter[WINED3DTEXF_ANISOTROPIC + 1][WINED3DTEXF_LINEAR + 1]
};
DWORD
magLookup
[
WINED3DTEXF_ANISOTROPIC
+
1
];
DWORD
magLookup_noFilter
[
WINED3DTEXF_ANISOTROPIC
+
1
]
=
{
GL_NEAREST
,
GL_NEAREST
,
GL_NEAREST
,
GL_NEAREST
};
/* drawStridedSlow attributes */
glAttribFunc
position_funcs
[
WINED3DDECLTYPE_UNUSED
];
...
...
dlls/wined3d/wined3d_private.h
View file @
481bcdfe
...
...
@@ -113,6 +113,7 @@ extern DWORD *stateLookup[MAX_LOOKUPS];
typedef
DWORD
magLookup_t
[
WINED3DTEXF_ANISOTROPIC
+
1
];
extern
magLookup_t
magLookup
;
extern
magLookup_t
magLookup_noFilter
;
typedef
DWORD
minMipLookup_t
[
WINED3DTEXF_ANISOTROPIC
+
1
][
WINED3DTEXF_LINEAR
+
1
];
extern
minMipLookup_t
minMipLookup
;
...
...
@@ -1095,6 +1096,7 @@ typedef struct IWineD3DBaseTextureClass
WINED3DFORMAT
shader_conversion_group
;
float
pow2Matrix
[
16
];
minMipLookup_t
*
minMipLookup
;
magLookup_t
*
magLookup
;
}
IWineD3DBaseTextureClass
;
typedef
struct
IWineD3DBaseTextureImpl
...
...
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