Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 6 additions & 3 deletions MarathonRecomp/gpu/video.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -3474,8 +3474,7 @@ static void SetDefaultViewport(GuestDevice* device, GuestSurface* surface)

static void SetRenderTarget(GuestDevice* device, uint32_t index, GuestSurface* renderTarget)
{
// printf("SetRenderTarget %x %d %x\n", device, index, renderTarget);
if (renderTarget != nullptr)
if (index == 0)
{
RenderCommand cmd;
cmd.type = RenderCommandType::SetRenderTarget;
Expand All @@ -3484,6 +3483,11 @@ static void SetRenderTarget(GuestDevice* device, uint32_t index, GuestSurface* r

SetDefaultViewport(device, renderTarget);
}
else
{
// Multiple targets are not currently handled. Make sure any attempt to set them is nullptr.
assert(renderTarget == nullptr);
}
}

static void ProcSetRenderTarget(const RenderCommand& cmd)
Expand All @@ -3499,7 +3503,6 @@ static void ProcSetRenderTarget(const RenderCommand& cmd)

static void SetDepthStencilSurface(GuestDevice* device, GuestSurface* depthStencil)
{
// printf("SetDepthStencilSurface: %x\n", depthStencil);
RenderCommand cmd;
cmd.type = RenderCommandType::SetDepthStencilSurface;
cmd.setDepthStencilSurface.depthStencil = depthStencil;
Expand Down
Loading