texture_cache: Flush 3D textures in the order they are drawn
This commit is contained in:
parent
4b396f375c
commit
2787a0c287
5 changed files with 44 additions and 19 deletions
|
@ -235,8 +235,9 @@ void SwizzleFunc(MortonSwizzleMode mode, u8* memory, const SurfaceParams& params
|
|||
|
||||
} // Anonymous namespace
|
||||
|
||||
CachedSurface::CachedSurface(const SurfaceParams& params)
|
||||
: VideoCommon::SurfaceBaseContextless<CachedSurfaceView>{params} {
|
||||
CachedSurface::CachedSurface(TextureCacheOpenGL& texture_cache, const SurfaceParams& params)
|
||||
: VideoCommon::SurfaceBaseContextless<TextureCacheOpenGL, CachedSurfaceView>{texture_cache,
|
||||
params} {
|
||||
const auto& tuple{GetFormatTuple(params.GetPixelFormat(), params.GetComponentType())};
|
||||
internal_format = tuple.internal_format;
|
||||
format = tuple.format;
|
||||
|
|
|
@ -26,15 +26,17 @@ using VideoCore::Surface::SurfaceType;
|
|||
|
||||
class CachedSurfaceView;
|
||||
class CachedSurface;
|
||||
class TextureCacheOpenGL;
|
||||
|
||||
using Surface = std::shared_ptr<CachedSurface>;
|
||||
using TextureCacheBase = VideoCommon::TextureCacheContextless<CachedSurface, CachedSurfaceView>;
|
||||
|
||||
class CachedSurface final : public VideoCommon::SurfaceBaseContextless<CachedSurfaceView> {
|
||||
class CachedSurface final
|
||||
: public VideoCommon::SurfaceBaseContextless<TextureCacheOpenGL, CachedSurfaceView> {
|
||||
friend CachedSurfaceView;
|
||||
|
||||
public:
|
||||
explicit CachedSurface(const SurfaceParams& params);
|
||||
explicit CachedSurface(TextureCacheOpenGL& texture_cache, const SurfaceParams& params);
|
||||
~CachedSurface();
|
||||
|
||||
void LoadBuffer();
|
||||
|
|
|
@ -460,7 +460,6 @@ static void APIENTRY DebugHandler(GLenum source, GLenum type, GLuint id, GLenum
|
|||
switch (severity) {
|
||||
case GL_DEBUG_SEVERITY_HIGH:
|
||||
LOG_CRITICAL(Render_OpenGL, format, str_source, str_type, id, message);
|
||||
__debugbreak();
|
||||
break;
|
||||
case GL_DEBUG_SEVERITY_MEDIUM:
|
||||
LOG_WARNING(Render_OpenGL, format, str_source, str_type, id, message);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue