fix memory stomp in latest N64 video (nw)

This commit is contained in:
R. Belmont 2012-02-04 04:46:41 +00:00
parent 8196ab3f5e
commit 1ea1e84fd9
2 changed files with 3 additions and 3 deletions

View File

@ -1800,7 +1800,7 @@ void N64::RDP::Triangle::compute_cvg_noflip(INT32* majorx, INT32* minorx, INT32*
if (length < 0) return;
memset(&m_rdp->Spans[scanline].m_cvg[purgestart], 0, (length + 1) << 2);
memset(&m_rdp->Spans[scanline].m_cvg[purgestart], 0, (length + 1) << 1);
for(int i = 0; i < 4; i++)
{
@ -1873,7 +1873,7 @@ void N64::RDP::Triangle::compute_cvg_flip(INT32* majorx, INT32* minorx, INT32* m
if (length < 0) return;
memset(&m_rdp->Spans[scanline].m_cvg[purgestart], 0, (length + 1) << 2);
memset(&m_rdp->Spans[scanline].m_cvg[purgestart], 0, (length + 1) << 1);
for(int i = 0; i < 4; i++)
{

View File

@ -58,7 +58,7 @@ class Span
SpanParam m_a;
SpanParam m_z;
UINT16 m_cvg[RDP_CVG_SPAN_MAX];
UINT16 m_cvg[RDP_CVG_SPAN_MAX+32];
private:
void RGBAZClip(int sr, int sg, int sb, int sa, int *sz);