GPU: Cleanup leftover postshader stuff.

This commit is contained in:
Unknown W. Brackets 2020-05-10 17:14:20 -07:00
parent b6b0f11f6c
commit fa6544b737
10 changed files with 2 additions and 55 deletions

View File

@ -21,7 +21,6 @@
#include <cmath> #include <cmath>
#include "ext/native/thin3d/thin3d.h" #include "ext/native/thin3d/thin3d.h"
#include "base/timeutil.h"
#include "gfx_es2/gpu_features.h" #include "gfx_es2/gpu_features.h"
#include "i18n/i18n.h" #include "i18n/i18n.h"
@ -32,7 +31,6 @@
#include "Core/CoreParameter.h" #include "Core/CoreParameter.h"
#include "Core/Host.h" #include "Core/Host.h"
#include "Core/Reporting.h" #include "Core/Reporting.h"
#include "Core/ELF/ParamSFO.h"
#include "Core/System.h" #include "Core/System.h"
#include "GPU/Common/DrawEngineCommon.h" #include "GPU/Common/DrawEngineCommon.h"
#include "GPU/Common/FramebufferCommon.h" #include "GPU/Common/FramebufferCommon.h"

View File

@ -176,7 +176,6 @@ class DrawContext;
} }
struct GPUDebugBuffer; struct GPUDebugBuffer;
struct PostShaderUniforms;
class DrawEngineCommon; class DrawEngineCommon;
class PresentationCommon; class PresentationCommon;
class ShaderManagerCommon; class ShaderManagerCommon;

View File

@ -15,6 +15,7 @@
// Official git repository and contact information can be found at // Official git repository and contact information can be found at
// https://github.com/hrydgard/ppsspp and http://www.ppsspp.org/. // https://github.com/hrydgard/ppsspp and http://www.ppsspp.org/.
#include <algorithm>
#include <d3d11.h> #include <d3d11.h>
#include <D3Dcompiler.h> #include <D3Dcompiler.h>
@ -22,12 +23,9 @@
#include "math/lin/matrix4x4.h" #include "math/lin/matrix4x4.h"
#include "ext/native/thin3d/thin3d.h" #include "ext/native/thin3d/thin3d.h"
#include "base/basictypes.h" #include "base/basictypes.h"
#include "file/vfs.h"
#include "file/zip_read.h"
#include "Common/ColorConv.h" #include "Common/ColorConv.h"
#include "Common/MathUtil.h" #include "Common/MathUtil.h"
#include "Core/Host.h"
#include "Core/MemMap.h" #include "Core/MemMap.h"
#include "Core/Config.h" #include "Core/Config.h"
#include "Core/ConfigValues.h" #include "Core/ConfigValues.h"
@ -38,7 +36,6 @@
#include "GPU/Debugger/Stepping.h" #include "GPU/Debugger/Stepping.h"
#include "GPU/Common/FramebufferCommon.h" #include "GPU/Common/FramebufferCommon.h"
#include "GPU/Common/PostShader.h"
#include "GPU/Common/PresentationCommon.h" #include "GPU/Common/PresentationCommon.h"
#include "GPU/Common/ShaderTranslation.h" #include "GPU/Common/ShaderTranslation.h"
#include "GPU/Common/TextureDecoder.h" #include "GPU/Common/TextureDecoder.h"
@ -47,10 +44,6 @@
#include "GPU/D3D11/TextureCacheD3D11.h" #include "GPU/D3D11/TextureCacheD3D11.h"
#include "GPU/D3D11/DrawEngineD3D11.h" #include "GPU/D3D11/DrawEngineD3D11.h"
#include "ext/native/thin3d/thin3d.h"
#include <algorithm>
#ifdef _M_SSE #ifdef _M_SSE
#include <emmintrin.h> #include <emmintrin.h>
#endif #endif

View File

@ -25,7 +25,6 @@
#include "GPU/GPUCommon.h" #include "GPU/GPUCommon.h"
#include "GPU/Common/FramebufferCommon.h" #include "GPU/Common/FramebufferCommon.h"
#include "Core/Config.h"
#include "ext/native/thin3d/thin3d.h" #include "ext/native/thin3d/thin3d.h"
class TextureCacheD3D11; class TextureCacheD3D11;
@ -98,7 +97,6 @@ private:
u8 *convBuf = nullptr; u8 *convBuf = nullptr;
int plainColorLoc_;
ID3D11PixelShader *stencilUploadPS_ = nullptr; ID3D11PixelShader *stencilUploadPS_ = nullptr;
ID3D11VertexShader *stencilUploadVS_ = nullptr; ID3D11VertexShader *stencilUploadVS_ = nullptr;
ID3D11InputLayout *stencilUploadInputLayout_ = nullptr; ID3D11InputLayout *stencilUploadInputLayout_ = nullptr;
@ -111,8 +109,4 @@ private:
TextureCacheD3D11 *textureCacheD3D11_; TextureCacheD3D11 *textureCacheD3D11_;
ShaderManagerD3D11 *shaderManagerD3D11_; ShaderManagerD3D11 *shaderManagerD3D11_;
DrawEngineD3D11 *drawEngineD3D11_; DrawEngineD3D11 *drawEngineD3D11_;
// Used by post-processing shader
// Postprocessing
static const D3D11_INPUT_ELEMENT_DESC g_PostVertexElements[2];
}; };

View File

@ -19,7 +19,6 @@
#include "ext/native/thin3d/thin3d.h" #include "ext/native/thin3d/thin3d.h"
#include "Common/ColorConv.h" #include "Common/ColorConv.h"
#include "Core/Host.h"
#include "Core/MemMap.h" #include "Core/MemMap.h"
#include "Core/Config.h" #include "Core/Config.h"
#include "Core/ConfigValues.h" #include "Core/ConfigValues.h"

View File

@ -27,7 +27,6 @@
#include "GPU/GPUCommon.h" #include "GPU/GPUCommon.h"
#include "GPU/Common/FramebufferCommon.h" #include "GPU/Common/FramebufferCommon.h"
#include "Core/Config.h"
#include "ext/native/thin3d/thin3d.h" #include "ext/native/thin3d/thin3d.h"
namespace DX9 { namespace DX9 {
@ -97,7 +96,6 @@ private:
u8 *convBuf = nullptr; u8 *convBuf = nullptr;
int plainColorLoc_;
LPDIRECT3DPIXELSHADER9 stencilUploadPS_ = nullptr; LPDIRECT3DPIXELSHADER9 stencilUploadPS_ = nullptr;
LPDIRECT3DVERTEXSHADER9 stencilUploadVS_ = nullptr; LPDIRECT3DVERTEXSHADER9 stencilUploadVS_ = nullptr;
bool stencilUploadFailed_ = false; bool stencilUploadFailed_ = false;

View File

@ -23,13 +23,7 @@
#include "gfx/gl_debug_log.h" #include "gfx/gl_debug_log.h"
#include "gfx_es2/glsl_program.h" #include "gfx_es2/glsl_program.h"
#include "thin3d/thin3d.h" #include "thin3d/thin3d.h"
#include "base/timeutil.h"
#include "file/vfs.h"
#include "math/lin/matrix4x4.h"
#include "Common/ColorConv.h" #include "Common/ColorConv.h"
#include "Core/Host.h"
#include "Core/MemMap.h" #include "Core/MemMap.h"
#include "Core/Config.h" #include "Core/Config.h"
#include "Core/ConfigValues.h" #include "Core/ConfigValues.h"
@ -38,9 +32,7 @@
#include "GPU/ge_constants.h" #include "GPU/ge_constants.h"
#include "GPU/GPUState.h" #include "GPU/GPUState.h"
#include "GPU/Common/FramebufferCommon.h" #include "GPU/Common/FramebufferCommon.h"
#include "GPU/Common/PostShader.h"
#include "GPU/Common/PresentationCommon.h" #include "GPU/Common/PresentationCommon.h"
#include "GPU/Common/ShaderTranslation.h"
#include "GPU/Common/TextureDecoder.h" #include "GPU/Common/TextureDecoder.h"
#include "GPU/Debugger/Stepping.h" #include "GPU/Debugger/Stepping.h"
#include "GPU/GLES/FramebufferManagerGLES.h" #include "GPU/GLES/FramebufferManagerGLES.h"
@ -158,11 +150,6 @@ void FramebufferManagerGLES::DestroyDeviceObjects() {
render_->DeleteProgram(draw2dprogram_); render_->DeleteProgram(draw2dprogram_);
draw2dprogram_ = nullptr; draw2dprogram_ = nullptr;
} }
// Will usually be clear already.
for (auto iter : postShaderModules_) {
render_->DeleteShader(iter);
}
postShaderModules_.clear();
if (drawPixelsTex_) { if (drawPixelsTex_) {
render_->DeleteTexture(drawPixelsTex_); render_->DeleteTexture(drawPixelsTex_);
drawPixelsTex_ = 0; drawPixelsTex_ = 0;

View File

@ -22,7 +22,6 @@
// Also provides facilities for drawing and later converting raw // Also provides facilities for drawing and later converting raw
// pixel data. // pixel data.
#include "Core/Config.h"
#include "GPU/GPUCommon.h" #include "GPU/GPUCommon.h"
#include "GPU/Common/FramebufferCommon.h" #include "GPU/Common/FramebufferCommon.h"
#include "thin3d/GLRenderManager.h" #include "thin3d/GLRenderManager.h"
@ -91,12 +90,10 @@ private:
u8 *convBuf_ = nullptr; u8 *convBuf_ = nullptr;
u32 convBufSize_ = 0; u32 convBufSize_ = 0;
GLRProgram *draw2dprogram_ = nullptr; GLRProgram *draw2dprogram_ = nullptr;
std::vector<GLRShader *> postShaderModules_;
GLRProgram *stencilUploadProgram_ = nullptr; GLRProgram *stencilUploadProgram_ = nullptr;
int u_stencilUploadTex = -1; int u_stencilUploadTex = -1;
int u_stencilValue = -1; int u_stencilValue = -1;
int u_postShaderTex = -1;
GLRProgram *depthDownloadProgram_ = nullptr; GLRProgram *depthDownloadProgram_ = nullptr;
int u_depthDownloadTex = -1; int u_depthDownloadTex = -1;
@ -107,12 +104,6 @@ private:
// Cached uniform locs // Cached uniform locs
int u_draw2d_tex = -1; int u_draw2d_tex = -1;
int plainColorLoc_ = -1;
int videoLoc_ = -1;
int timeLoc_ = -1;
int pixelDeltaLoc_ = -1;
int deltaLoc_ = -1;
TextureCacheGLES *textureCacheGL_ = nullptr; TextureCacheGLES *textureCacheGL_ = nullptr;
ShaderManagerGLES *shaderManagerGL_ = nullptr; ShaderManagerGLES *shaderManagerGL_ = nullptr;
DrawEngineGLES *drawEngineGL_ = nullptr; DrawEngineGLES *drawEngineGL_ = nullptr;

View File

@ -21,10 +21,8 @@
#include "profiler/profiler.h" #include "profiler/profiler.h"
#include "base/display.h" #include "base/display.h"
#include "base/timeutil.h"
#include "math/lin/matrix4x4.h" #include "math/lin/matrix4x4.h"
#include "math/dataconv.h" #include "math/dataconv.h"
#include "ext/native/file/vfs.h"
#include "ext/native/thin3d/thin3d.h" #include "ext/native/thin3d/thin3d.h"
#include "Common/Vulkan/VulkanContext.h" #include "Common/Vulkan/VulkanContext.h"
@ -32,7 +30,6 @@
#include "Common/Vulkan/VulkanImage.h" #include "Common/Vulkan/VulkanImage.h"
#include "thin3d/VulkanRenderManager.h" #include "thin3d/VulkanRenderManager.h"
#include "Common/ColorConv.h" #include "Common/ColorConv.h"
#include "Core/Host.h"
#include "Core/MemMap.h" #include "Core/MemMap.h"
#include "Core/Config.h" #include "Core/Config.h"
#include "Core/ConfigValues.h" #include "Core/ConfigValues.h"
@ -40,17 +37,12 @@
#include "Core/Reporting.h" #include "Core/Reporting.h"
#include "Core/HLE/sceDisplay.h" #include "Core/HLE/sceDisplay.h"
#include "GPU/ge_constants.h" #include "GPU/ge_constants.h"
#include "GPU/GPUInterface.h"
#include "GPU/GPUState.h" #include "GPU/GPUState.h"
#include "GPU/Common/ShaderTranslation.h"
#include "GPU/Common/PostShader.h"
#include "GPU/Common/TextureDecoder.h" #include "GPU/Common/TextureDecoder.h"
#include "GPU/Common/FramebufferCommon.h" #include "GPU/Common/FramebufferCommon.h"
#include "GPU/Debugger/Stepping.h" #include "GPU/Debugger/Stepping.h"
#include "GPU/GPUInterface.h"
#include "GPU/GPUState.h"
#include "Common/Vulkan/VulkanImage.h"
#include "GPU/Vulkan/FramebufferVulkan.h" #include "GPU/Vulkan/FramebufferVulkan.h"
#include "GPU/Vulkan/DrawEngineVulkan.h" #include "GPU/Vulkan/DrawEngineVulkan.h"
#include "GPU/Vulkan/TextureCacheVulkan.h" #include "GPU/Vulkan/TextureCacheVulkan.h"

View File

@ -104,9 +104,6 @@ private:
MAX_COMMAND_BUFFERS = 32, MAX_COMMAND_BUFFERS = 32,
}; };
// This gets copied to the current frame's push buffer as needed.
PostShaderUniforms postUniforms_;
VkPipelineCache pipelineCache2D_; VkPipelineCache pipelineCache2D_;
// Basic shaders // Basic shaders
@ -116,7 +113,6 @@ private:
VkShaderModule stencilVs_ = VK_NULL_HANDLE; VkShaderModule stencilVs_ = VK_NULL_HANDLE;
VkShaderModule stencilFs_ = VK_NULL_HANDLE; VkShaderModule stencilFs_ = VK_NULL_HANDLE;
VkPipeline cur2DPipeline_ = VK_NULL_HANDLE; VkPipeline cur2DPipeline_ = VK_NULL_HANDLE;
VkSampler linearSampler_; VkSampler linearSampler_;