fixes to the threadedness of the sw rasteriser

also fix #639 and fix #880
This commit is contained in:
RSDuck
2021-01-26 16:42:27 +01:00
parent ab222ab135
commit b78bc4cb66
8 changed files with 40 additions and 16 deletions

View File

@ -187,6 +187,20 @@ void GPU2D_Soft::DrawScanline(u32 line)
// oddly that's not the case for GPU A
if (Num && !Enabled) forceblank = true;
if (line == 0 && CaptureCnt & (1 << 31) && !forceblank)
CaptureLatch = true;
if (Num == 0)
{
if (!Accelerated)
_3DLine = GPU3D::GetLine(n3dline);
else if (CaptureLatch && (((CaptureCnt >> 29) & 0x3) != 1))
{
_3DLine = GPU3D::GetLine(n3dline);
//GPU3D::GLRenderer::PrepareCaptureFrame();
}
}
if (forceblank)
{
for (int i = 0; i < 256; i++)
@ -202,20 +216,6 @@ void GPU2D_Soft::DrawScanline(u32 line)
u32 dispmode = DispCnt >> 16;
dispmode &= (Num ? 0x1 : 0x3);
if (Num == 0)
{
if (!Accelerated)
_3DLine = GPU3D::GetLine(n3dline);
else if ((CaptureCnt & (1<<31)) && (((CaptureCnt >> 29) & 0x3) != 1))
{
_3DLine = GPU3D::GetLine(n3dline);
//GPU3D::GLRenderer::PrepareCaptureFrame();
}
}
if (line == 0 && CaptureCnt & (1 << 31))
CaptureLatch = true;
// always render regular graphics
DrawScanline_BGOBJ(line);
UpdateMosaicCounters(line);