Bug 1408383 - Dead code in GetSurfaceSnapshot r?jgilbert draft
authorSylvestre Ledru <sledru@mozilla.com>
Fri, 13 Oct 2017 15:32:22 +0200
changeset 680049 3707381868f07717ace471bf69d93457f7b762ed
parent 676750 f14f1218655d66e77873f088855c605dc299472a
child 735750 6979b6970644efe2037333c4fdb4975aa87a936f
push id84384
push userbmo:sledru@mozilla.com
push dateFri, 13 Oct 2017 13:33:54 +0000
reviewersjgilbert
bugs1408383
milestone58.0a1
Bug 1408383 - Dead code in GetSurfaceSnapshot r?jgilbert MozReview-Commit-ID: 2AS1OwFdiMq
dom/canvas/WebGLContext.cpp
--- a/dom/canvas/WebGLContext.cpp
+++ b/dom/canvas/WebGLContext.cpp
@@ -1980,17 +1980,16 @@ WebGLContext::GetSurfaceSnapshot(gfxAlph
     }
 
     if (out_alphaType) {
         *out_alphaType = alphaType;
     } else {
         // Expects Opaque or Premult
         if (alphaType == gfxAlphaType::NonPremult) {
             gfxUtils::PremultiplyDataSurface(surf, surf);
-            alphaType = gfxAlphaType::Premult;
         }
     }
 
     RefPtr<DrawTarget> dt =
         Factory::CreateDrawTarget(gfxPlatform::GetPlatform()->GetSoftwareBackend(),
                                   IntSize(mWidth, mHeight),
                                   SurfaceFormat::B8G8R8A8);
     if (!dt)