- implement wipe screen copy

This commit is contained in:
Magnus Norddahl 2019-03-13 02:23:33 +01:00
commit d78cb959a7
7 changed files with 98 additions and 7 deletions

View file

@ -546,6 +546,32 @@ void VulkanFrameBuffer::UpdatePalette()
mPostprocess->ClearTonemapPalette();
}
FTexture *VulkanFrameBuffer::WipeStartScreen()
{
const auto &viewport = screen->mScreenViewport;
auto tex = new FWrapperTexture(viewport.width, viewport.height, 1);
auto systex = static_cast<VkHardwareTexture*>(tex->GetSystemTexture());
systex->CreateWipeTexture(viewport.width, viewport.height, "WipeStartScreen");
return tex;
}
FTexture *VulkanFrameBuffer::WipeEndScreen()
{
GetPostprocess()->SetActiveRenderTarget();
Draw2D();
Clear2D();
const auto &viewport = screen->mScreenViewport;
auto tex = new FWrapperTexture(viewport.width, viewport.height, 1);
auto systex = static_cast<VkHardwareTexture*>(tex->GetSystemTexture());
systex->CreateWipeTexture(viewport.width, viewport.height, "WipeEndScreen");
return tex;
}
void VulkanFrameBuffer::BeginFrame()
{
SetViewportRects(nullptr);