Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 8b3a832c authored by TreeHugger Robot's avatar TreeHugger Robot Committed by Android (Google) Code Review
Browse files

Merge "Remove Skia RenderPipeline saveLayer logic for software layers."

parents 638af473 52230bc2
Loading
Loading
Loading
Loading
+2 −3
Original line number Diff line number Diff line
@@ -56,11 +56,10 @@ class RenderProperties;
// Keep in sync with View.java:LAYER_TYPE_*
enum class LayerType {
    None = 0,
    // Although we cannot build the software layer directly (must be done at
    // record time), this information is used when applying alpha.
    // We cannot build the software layer directly (must be done at record time) and all management
    // of software layers is handled in Java.
    Software = 1,
    RenderLayer = 2,
    // TODO: LayerTypeSurfaceTexture? Maybe?
};

enum ClippingFlags {
+0 −12
Original line number Diff line number Diff line
@@ -226,18 +226,6 @@ void RenderNodeDrawable::drawContent(SkCanvas* canvas) const {
                    canvas->drawRect(bounds, transparentPaint);
                }
            }

            // composing a software layer with alpha
        } else if (properties.effectiveLayerType() == LayerType::Software) {
            SkPaint paint;
            bool needsLayer = layerNeedsPaint(layerProperties, alphaMultiplier, &paint);
            if (needsLayer) {
                canvas->saveLayer(bounds, &paint);
            }
            displayList->draw(canvas);
            if (needsLayer) {
                canvas->restore();
            }
        } else {
            if (alphaMultiplier < 1.0f) {
                // Non-layer draw for a view with getHasOverlappingRendering=false, will apply