2020-05-31 08:53:11 +00:00
|
|
|
|
|
|
|
#pragma once
|
|
|
|
|
|
|
|
#include <functional>
|
|
|
|
#include <map>
|
|
|
|
#include <array>
|
|
|
|
|
|
|
|
#include "hwrenderer/postprocessing/hw_postprocess.h"
|
2022-12-11 17:30:01 +00:00
|
|
|
#include "zvulkan/vulkanobjects.h"
|
|
|
|
#include "zvulkan/vulkanbuilders.h"
|
2020-05-31 08:53:11 +00:00
|
|
|
#include "vulkan/textures/vk_imagetransition.h"
|
|
|
|
|
|
|
|
class FString;
|
|
|
|
|
|
|
|
class VkPPShader;
|
|
|
|
class VkPPTexture;
|
|
|
|
class PipelineBarrier;
|
2022-12-11 17:30:01 +00:00
|
|
|
class VulkanRenderDevice;
|
2020-05-31 08:53:11 +00:00
|
|
|
|
|
|
|
class VkPostprocess
|
|
|
|
{
|
|
|
|
public:
|
2022-12-11 17:30:01 +00:00
|
|
|
VkPostprocess(VulkanRenderDevice* fb);
|
2020-05-31 08:53:11 +00:00
|
|
|
~VkPostprocess();
|
|
|
|
|
|
|
|
void SetActiveRenderTarget();
|
2020-06-07 13:02:54 +00:00
|
|
|
void PostProcessScene(int fixedcm, float flash, const std::function<void()> &afterBloomDrawEndScene2D);
|
2020-05-31 08:53:11 +00:00
|
|
|
|
|
|
|
void AmbientOccludeScene(float m5);
|
|
|
|
void BlurScene(float gameinfobluramount);
|
|
|
|
void ClearTonemapPalette();
|
|
|
|
|
|
|
|
void UpdateShadowMap();
|
|
|
|
|
|
|
|
void ImageTransitionScene(bool undefinedSrcLayout);
|
|
|
|
|
|
|
|
void BlitSceneToPostprocess();
|
|
|
|
void BlitCurrentToImage(VkTextureImage *image, VkImageLayout finallayout = VK_IMAGE_LAYOUT_SHADER_READ_ONLY_OPTIMAL);
|
|
|
|
void DrawPresentTexture(const IntRect &box, bool applyGamma, bool screenshot);
|
|
|
|
|
2022-07-02 08:09:59 +00:00
|
|
|
int GetCurrentPipelineImage() const { return mCurrentPipelineImage; }
|
|
|
|
|
2020-05-31 08:53:11 +00:00
|
|
|
private:
|
|
|
|
void NextEye(int eyeCount);
|
|
|
|
|
2022-12-11 17:30:01 +00:00
|
|
|
VulkanRenderDevice* fb = nullptr;
|
2020-05-31 08:53:11 +00:00
|
|
|
|
|
|
|
int mCurrentPipelineImage = 0;
|
|
|
|
|
|
|
|
friend class VkPPRenderState;
|
|
|
|
};
|