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

Commit df98fb95 authored by Dan Stoza's avatar Dan Stoza Committed by Android (Google) Code Review
Browse files

Merge "SF: Apply translations to transparent region" into nyc-dev

parents 0abac03f 22f7fc45
Loading
Loading
Loading
Loading
+6 −10
Original line number Diff line number Diff line
@@ -1719,7 +1719,6 @@ void SurfaceFlinger::computeVisibleRegions(
                // Remove the transparent area from the visible region
                if (translucent) {
                    const Transform tr(s.active.transform);
                    if (tr.transformed()) {
                    if (tr.preserveRects()) {
                        // transform the transparent region
                        transparentRegion = tr.transform(s.activeTransparentRegion);
@@ -1728,9 +1727,6 @@ void SurfaceFlinger::computeVisibleRegions(
                        // transparent region optimization.
                        transparentRegion.clear();
                    }
                    } else {
                        transparentRegion = s.activeTransparentRegion;
                    }
                }

                // compute the opaque region
+6 −10
Original line number Diff line number Diff line
@@ -1747,7 +1747,6 @@ void SurfaceFlinger::computeVisibleRegions(
                // Remove the transparent area from the visible region
                if (translucent) {
                    const Transform tr(s.active.transform);
                    if (tr.transformed()) {
                    if (tr.preserveRects()) {
                        // transform the transparent region
                        transparentRegion = tr.transform(s.activeTransparentRegion);
@@ -1756,9 +1755,6 @@ void SurfaceFlinger::computeVisibleRegions(
                        // transparent region optimization.
                        transparentRegion.clear();
                    }
                    } else {
                        transparentRegion = s.activeTransparentRegion;
                    }
                }

                // compute the opaque region
+1 −5
Original line number Diff line number Diff line
@@ -87,10 +87,6 @@ const vec3& Transform::operator [] (size_t i) const {
    return mMatrix[i];
}

bool Transform::transformed() const {
    return type() > TRANSLATE;
}

float Transform::tx() const {
    return mMatrix[2][0];
}
@@ -224,7 +220,7 @@ Rect Transform::transform(const Rect& bounds) const
Region Transform::transform(const Region& reg) const
{
    Region out;
    if (CC_UNLIKELY(transformed())) {
    if (CC_UNLIKELY(type() > TRANSLATE)) {
        if (CC_LIKELY(preserveRects())) {
            Region::const_iterator it = reg.begin();
            Region::const_iterator const end = reg.end();
+0 −1
Original line number Diff line number Diff line
@@ -60,7 +60,6 @@ public:
            };

            // query the transform
            bool        transformed() const;
            bool        preserveRects() const;
            uint32_t    getType() const;
            uint32_t    getOrientation() const;