gsdx state: split IsMipmapActive in 2 pieces

This way we can test if a draw call requires a triliner filtering.
It will be used in next commit to implement automatic trilinear
This commit is contained in:
Gregory Hainaut 2016-10-02 13:23:38 +02:00
parent 1b9b47dd6a
commit c2777ff989
2 changed files with 7 additions and 1 deletions

View File

@ -3183,9 +3183,14 @@ bool GSState::IsOpaque()
return context->ALPHA.IsOpaque(amin, amax);
}
bool GSState::IsMipMapDraw()
{
return m_context->TEX1.MXL > 0 && m_context->TEX1.MMIN >= 2 && m_context->TEX1.MMIN <= 5 && m_vt.m_lod.y > 0;
}
bool GSState::IsMipMapActive()
{
return m_mipmap && m_context->TEX1.MXL > 0 && m_context->TEX1.MMIN >= 2 && m_context->TEX1.MMIN <= 5 && m_vt.m_lod.y > 0;
return m_mipmap && IsMipMapDraw();
}
GIFRegTEX0 GSState::GetTex0Layer(int lod)

View File

@ -204,6 +204,7 @@ protected:
void GetAlphaMinMax();
bool TryAlphaTest(uint32& fm, uint32& zm);
bool IsOpaque();
bool IsMipMapDraw();
bool IsMipMapActive();
GIFRegTEX0 GetTex0Layer(int lod);