OSDN Git Service

Fix unintended switch case fall-through.
authorNicolas Capens <capn@google.com>
Thu, 11 Jun 2015 20:44:39 +0000 (16:44 -0400)
committerNicolas Capens <capn@google.com>
Thu, 11 Jun 2015 20:46:08 +0000 (20:46 +0000)
Bug 21766174

Change-Id: I1428bcceb2fbf6c649632112f773c3a0625e3775
Reviewed-on: https://swiftshader-review.googlesource.com/3479
Reviewed-by: Nicolas Capens <capn@google.com>
Tested-by: Nicolas Capens <capn@google.com>
src/OpenGL/libGLES_CM/Context.cpp

index 4151de7..8cacba3 100644 (file)
@@ -1881,6 +1881,7 @@ void Context::applyTextures()
                                                // Cv = Cs, Av = Ap\r
                                                device->setStageOperation(unit, sw::TextureStage::STAGE_SELECTARG1);\r
                                                device->setStageOperationAlpha(unit, sw::TextureStage::STAGE_SELECTARG2);\r
+                                               break;\r
                                        case GL_LUMINANCE_ALPHA:\r
                                        case GL_RGBA:\r
                                        case GL_BGRA_EXT:\r
@@ -1904,6 +1905,7 @@ void Context::applyTextures()
                                                // Cv = CpCs, Av = Ap\r
                                                device->setStageOperation(unit, sw::TextureStage::STAGE_MODULATE);\r
                                                device->setStageOperationAlpha(unit, sw::TextureStage::STAGE_SELECTARG2);\r
+                                               break;\r
                                        case GL_LUMINANCE_ALPHA:\r
                                        case GL_RGBA:\r
                                        case GL_BGRA_EXT:\r
@@ -1928,6 +1930,7 @@ void Context::applyTextures()
                                                // Cv = Cs, Av = Ap\r
                                                device->setStageOperation(unit, sw::TextureStage::STAGE_SELECTARG1);\r
                                                device->setStageOperationAlpha(unit, sw::TextureStage::STAGE_SELECTARG2);\r
+                                               break;\r
                                        case GL_RGBA:\r
                                        case GL_BGRA_EXT:\r
                                                // Cv = Cp(1 ? As) + CsAs, Av = Ap\r
@@ -1950,6 +1953,7 @@ void Context::applyTextures()
                                                // Cv = Cp(1 ? Cs) + CcCs, Av = Ap\r
                                                device->setStageOperation(unit, sw::TextureStage::STAGE_LERP);   // Arg3 * (Arg1 - Arg2) + Arg2\r
                                                device->setStageOperationAlpha(unit, sw::TextureStage::STAGE_SELECTARG2);\r
+                                               break;\r
                                        case GL_LUMINANCE_ALPHA:\r
                                        case GL_RGBA:\r
                                        case GL_BGRA_EXT:\r
@@ -1973,6 +1977,7 @@ void Context::applyTextures()
                                                // Cv = Cp + Cs, Av = Ap\r
                                                device->setStageOperation(unit, sw::TextureStage::STAGE_ADD);\r
                                                device->setStageOperationAlpha(unit, sw::TextureStage::STAGE_SELECTARG2);\r
+                                               break;\r
                                        case GL_LUMINANCE_ALPHA:\r
                                        case GL_RGBA:\r
                                        case GL_BGRA_EXT:\r