IDirect3DDevice9, setting how textures scale?
In Photoshop you can control how pictures are scaled up and down as 'image interpolation开发者_如何转开发', it has different options like 'Bicubic', 'Bilinear', 'Nearest Neighbour' and such.
I was wondering if I could do something similar in DirectX? Basically if I slap a texture on a quad and stretch the quad how can I control how the texture on the quad is represented?
Thanks for any help!
If you are using fixed function pipeline :
http://msdn.microsoft.com/en-us/library/ee421769(VS.85).aspx
Setting the D3DSAMP_MAGFILTER, D3DSAMP_MINFILTER , D3DSAMP_MIPFILTER values.
Otherwise set the FILTER option of the sampler object if you're using HLSL.
There are 4 type of filtering. NONE, POINT, LINEAR, ANISOTROPIC.
精彩评论