diff options
| author | 2010-12-02 21:32:29 -0800 | |
|---|---|---|
| committer | 2010-12-03 17:35:06 -0800 | |
| commit | 733189d408e13b54fd70971b265244367efd0f51 (patch) | |
| tree | 11bcc133818c471421d21eb877d46d6ec77a6450 /services/surfaceflinger/LayerBase.cpp | |
| parent | 678bdd6349344df254cc0c3377a40fd99e216635 (diff) | |
[3171580] Fix two typos related to fixed-size buffers
mFixedSize was never set, this bug was introduced during some "cleanup", in
practice this could cause some issues when a fixed-size buffer was used and
the window was resized.
Layer::drawForSreenShot() had a typo that had no effect.
mFixedSize was used to determine if filtering was needed, which was a bit too
conservative and created a dependency between filtering and "fixed size" states
which should exist.
Now we enable filtering based on the size of the buffer vs. the size of the layer.
Change-Id: I32044e91b0c944c1b137efdceb3f01dfaa78119d
Diffstat (limited to 'services/surfaceflinger/LayerBase.cpp')
| -rw-r--r-- | services/surfaceflinger/LayerBase.cpp | 12 |
1 files changed, 4 insertions, 8 deletions
diff --git a/services/surfaceflinger/LayerBase.cpp b/services/surfaceflinger/LayerBase.cpp index 64eed4b55f..79c6d0d62f 100644 --- a/services/surfaceflinger/LayerBase.cpp +++ b/services/surfaceflinger/LayerBase.cpp @@ -216,14 +216,10 @@ uint32_t LayerBase::doTransaction(uint32_t flags) flags |= eVisibleRegion; this->contentDirty = true; - mNeedsFiltering = false; - if (!(mFlags & DisplayHardware::SLOW_CONFIG)) { - // we may use linear filtering, if the matrix scales us - const uint8_t type = temp.transform.getType(); - if (!temp.transform.preserveRects() || (type >= Transform::SCALE)) { - mNeedsFiltering = true; - } - } + // we may use linear filtering, if the matrix scales us + const uint8_t type = temp.transform.getType(); + mNeedsFiltering = (!temp.transform.preserveRects() || + (type >= Transform::SCALE)); } // Commit the transaction |