From 9bf2705c2d7198e7ee132d6ef5489d325d56168d Mon Sep 17 00:00:00 2001 From: NeoBrainX Date: Tue, 28 Dec 2010 01:10:40 +0000 Subject: [PATCH] Small fix in addition to r6669. git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@6676 8ced0084-cf51-0410-be5f-012b33b47a6e --- Source/Core/VideoCommon/Src/BPFunctions.cpp | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) diff --git a/Source/Core/VideoCommon/Src/BPFunctions.cpp b/Source/Core/VideoCommon/Src/BPFunctions.cpp index ab30645ac3..9cdd8152ed 100644 --- a/Source/Core/VideoCommon/Src/BPFunctions.cpp +++ b/Source/Core/VideoCommon/Src/BPFunctions.cpp @@ -159,7 +159,7 @@ void OnPixelFormatChange(const BPCmd &bp) case PIXELFMT_RGB8_Z24: case PIXELFMT_Z24: // Z24 and RGB8_Z24 are treated equal, so just return in this case - if (new_format == PIXELFMT_RGB565_Z16 || new_format == PIXELFMT_Z24) + if (new_format == PIXELFMT_RGB8_Z24 || new_format == PIXELFMT_Z24) goto skip; if (new_format == PIXELFMT_RGBA6_Z24) @@ -185,8 +185,12 @@ void OnPixelFormatChange(const BPCmd &bp) break; default: - PanicAlert("Unhandled EFB format change: %d to %d\n", old_format, new_format); - goto skip; + break; + } + if (convtype == (unsigned int)-1) + { + PanicAlert("Unhandled EFB format change: %d to %d\n", old_format, new_format); + goto skip; } g_renderer->ReinterpretPixelData(convtype); skip: