mirror of
https://github.com/RPCS3/rpcs3.git
synced 2025-04-20 11:36:13 +00:00
gl: Fix crash when launching multiple games with MSAA enabled
This commit is contained in:
parent
0d4f3cf0a5
commit
485927ed0d
4 changed files with 12 additions and 1 deletions
|
@ -4,6 +4,7 @@
|
|||
#include "GLGSRender.h"
|
||||
#include "GLCompute.h"
|
||||
#include "GLDMA.h"
|
||||
#include "GLResolveHelper.h"
|
||||
|
||||
#include "Emu/Memory/vm_locking.h"
|
||||
#include "Emu/RSX/rsx_methods.h"
|
||||
|
@ -429,6 +430,7 @@ void GLGSRender::on_exit()
|
|||
gl::destroy_compute_tasks();
|
||||
gl::destroy_overlay_passes();
|
||||
gl::clear_dma_resources();
|
||||
gl::clear_resolve_helpers();
|
||||
|
||||
gl::destroy_global_texture_resources();
|
||||
|
||||
|
|
|
@ -671,7 +671,7 @@ void gl::render_target::memory_barrier(gl::command_context& cmd, rsx::surface_ac
|
|||
}
|
||||
|
||||
// MSAA support
|
||||
gl::viewable_image* gl::render_target::get_resolve_target_safe(gl::command_context& cmd)
|
||||
gl::viewable_image* gl::render_target::get_resolve_target_safe(gl::command_context& /*cmd*/)
|
||||
{
|
||||
if (!resolve_surface)
|
||||
{
|
||||
|
|
|
@ -10,6 +10,14 @@ namespace gl
|
|||
std::unordered_map<GLuint, std::unique_ptr<ds_resolve_pass_base>> g_depth_resolvers;
|
||||
std::unordered_map<GLuint, std::unique_ptr<ds_resolve_pass_base>> g_depth_unresolvers;
|
||||
|
||||
void clear_resolve_helpers()
|
||||
{
|
||||
g_resolve_helpers.clear();
|
||||
g_unresolve_helpers.clear();
|
||||
g_depth_resolvers.clear();
|
||||
g_depth_unresolvers.clear();
|
||||
}
|
||||
|
||||
static const char* get_format_string(gl::texture::internal_format format)
|
||||
{
|
||||
switch (format)
|
||||
|
|
|
@ -7,6 +7,7 @@ namespace gl
|
|||
{
|
||||
void resolve_image(gl::command_context& cmd, gl::viewable_image* dst, gl::viewable_image* src);
|
||||
void unresolve_image(gl::command_context& cmd, gl::viewable_image* dst, gl::viewable_image* src);
|
||||
void clear_resolve_helpers();
|
||||
|
||||
struct cs_resolve_base : compute_task
|
||||
{
|
||||
|
|
Loading…
Add table
Reference in a new issue