• Advertisement
Sign in to follow this  

anisotropic filtering not making any differnece

This topic is 3737 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

I'm trying to enable anisotropic filtering in DirectX 9 and it seems to be a fairly straightforward process. However, when I enable and disable the filtering, it makes 0 difference on the texture quality when viewed at an angle, they still look awful. Is there a step I'm missing? d3ddev->SetSamplerState( 0, D3DSAMP_MAXANISOTROPY, 16 ); d3ddev->SetSamplerState( 0, D3DSAMP_MIPFILTER, D3DTEXF_ANISOTROPIC ); d3ddev->SetSamplerState( 0, D3DSAMP_MAGFILTER, D3DTEXF_ANISOTROPIC ); d3ddev->SetSamplerState( 0, D3DSAMP_MINFILTER, D3DTEXF_ANISOTROPIC );

Share this post


Link to post
Share on other sites
Advertisement
If you're using shaders and not fixed function, the sampler states in the shader might be overriding your SetSamplerState().

Share this post


Link to post
Share on other sites
Anisotropic Filtering only makes sense for the MINFILTER sampler state, in fact I think the D3D debug runtimes will give you a warning if you set it for the MIPFILTER sampler state. When minifying a texture, anisotropic filtering takes into account multiple samples to improve the quality of textures that are viewed at an angle and so stretched along one axis. It doesn't make sense as a MIPFILTER and although D3D seems to support anisotropic filtering as a MAGFILTER, I'm not sure what that's supposed to mean and I haven't seen any hardware that supports it.

The effect is quite subtle but should be noticeable if you switch back and forth with the same scene, providing the textures you are viewing are being minified and not magnified. Have you tried debugging your scene in PIX to verify that the sampler states are set correctly for the draw call you're interested in?

Share this post


Link to post
Share on other sites
Maybe check out the driver panel as well. To allow the app to choose the anisotropy, the corresponding bar in the NV panel must be grayed.

Share this post


Link to post
Share on other sites
Sign in to follow this  

  • Advertisement