Essentially this:
PHP Code:
#ifdef __ANISOTROPIC
if (g_option.m_nAnisotropy == 0 )
{
d3dDevice->SetSamplerState(0, D3DSAMP_MINFILTER, D3DTEXF_LINEAR);
d3dDevice->SetSamplerState(0, D3DSAMP_MINFILTER, D3DTEXF_LINEAR);
}
else if (g_option.m_nAnisotropy > 0 && g_option.m_nAnisotropy < 5 )
{
int MaxAni;
if (g_option.m_nAnisotropy == 1 ) {
MaxAni = 2; }
else if (g_option.m_nAnisotropy > 2 ) {
MaxAni = 4; }
else if (g_option.m_nAnisotropy > 3 ) {
MaxAni = 8; }
else if (g_option.m_nAnisotropy > 4 ) {
MaxAni = 16; }
d3dDevice->SetSamplerState(0, D3DSAMP_MAXANISOTROPY, MaxAni);
d3dDevice->SetSamplerState(0, D3DSAMP_MINFILTER, D3DTEXF_ANISOTROPIC);
d3dDevice->SetSamplerState(0, D3DSAMP_MINFILTER, D3DTEXF_ANISOTROPIC);
}
#else
d3dDevice->SetSamplerState(0, D3DSAMP_MINFILTER, D3DTEXF_LINEAR);
d3dDevice->SetSamplerState(0, D3DSAMP_MINFILTER, D3DTEXF_LINEAR);
#endif
HwOption.h
You could figure out the rest from that. I would post the rest, but I'm not around any source codes to check.