Archived

This topic is now archived and is closed to further replies.

peter86

Mip mapping

Recommended Posts

peter86    123
Some questions about mip mapping in DX9: How do I tell D3D to use mip maps for rendering? How should the mip map chain be created? Just by a call to D3DXCreateTextureFromFileEx() or do I need to do anything else?

Share this post


Link to post
Share on other sites
treething    122
In D3DXCreateTextureFromFileEx there are 2 parameters that control the mipmaps created. They are explained in the docs.

To control the usage of mipmapping there are a few sampler states.

D3DSAMP_MIPFILTER
D3DSAMP_MIPMAPLODBIAS
D3DSAMP_MAXMIPLEVEL

If you use the default states and D3DX_DEFAULT in the loading function then you should have and be using mipmaps.



Share this post


Link to post
Share on other sites
curtmax_0    100
I don''t have the d3d docs with me. But you can also ''hint'' the video hardware to generate mipmaps with the texture object. It is something like IDirect3DTexture9::GenerateMipMapSublevels() or something...

Share this post


Link to post
Share on other sites