mirror of https://github.com/PCSX2/pcsx2.git
GSdx: I've mixed up the bits of TEX1.MMIN, sfex looks nice again.
git-svn-id: http://pcsx2.googlecode.com/svn/trunk@4454 96395faa-99c1-11dd-bbfe-3dabce05a288
This commit is contained in:
parent
441ded0788
commit
b1eac6d058
|
@ -353,13 +353,36 @@ void GSRendererSW::GetScanlineGlobalData(GSScanlineGlobalData& gd)
|
|||
|
||||
if(m_mipmap && context->TEX1.MXL > 0 && context->TEX1.MMIN >= 2 && context->TEX1.MMIN <= 5 && m_vt.m_lod.y > 0)
|
||||
{
|
||||
//gd.sel.ltf = context->TEX1.MMIN & 1; // TODO: mmag != (mmin & 1) && lod <= 0
|
||||
gd.sel.mmin = context->TEX1.MMIN >> 1;
|
||||
// TEX1.MMIN
|
||||
// 000 p
|
||||
// 001 l
|
||||
// 010 p round
|
||||
// 011 p tri
|
||||
// 100 l round
|
||||
// 101 l tri
|
||||
|
||||
// TODO: (int)m_vt.m_lod.x >= mxl => LCM == 1
|
||||
|
||||
if(m_vt.m_lod.x > 0)
|
||||
{
|
||||
gd.sel.ltf = (context->TEX1.MMIN & 5) ? 1 : 0;
|
||||
}
|
||||
else
|
||||
{
|
||||
// TODO: isbilinear(mmag) != isbilinear(mmin) && m_vt.m_lod.x <= 0 && m_vt.m_lod.y > 0
|
||||
}
|
||||
|
||||
gd.sel.mmin = (context->TEX1.MMIN & 1) + 1; // 1: round, 2: tri
|
||||
gd.sel.lcm = context->TEX1.LCM;
|
||||
|
||||
int mxl = (std::min<int>((int)context->TEX1.MXL, 6) << 16) - 1;
|
||||
int mxl = (std::min<int>((int)context->TEX1.MXL, 6) << 16);
|
||||
int k = context->TEX1.K << 12;
|
||||
|
||||
if(gd.sel.mmin == 2)
|
||||
{
|
||||
mxl--;
|
||||
}
|
||||
|
||||
gd.mxl = GSVector4((float)mxl);
|
||||
gd.l = GSVector4((float)(-0x10000 << context->TEX1.L));
|
||||
gd.k = GSVector4((float)k);
|
||||
|
|
Loading…
Reference in New Issue