Bug 1247445 - Rename Layer::GetEffectiveVisibleRegion GetLocalVisibleRegion. r=botond

This commit is contained in:
Michelangelo De Simone 2016-02-13 16:50:51 -08:00
parent b105bab818
commit 1f2d76da50
16 changed files with 37 additions and 37 deletions

View File

@ -76,8 +76,8 @@ static gfxFloat RecoverZDepth(const Matrix4x4& aTransform, const gfxPoint& aPoin
* unsolved without changing our rendering code. * unsolved without changing our rendering code.
*/ */
static LayerSortOrder CompareDepth(Layer* aOne, Layer* aTwo) { static LayerSortOrder CompareDepth(Layer* aOne, Layer* aTwo) {
gfxRect ourRect = ThebesRect(aOne->GetEffectiveVisibleRegion().ToUnknownRegion().GetBounds()); gfxRect ourRect = ThebesRect(aOne->GetLocalVisibleRegion().ToUnknownRegion().GetBounds());
gfxRect otherRect = ThebesRect(aTwo->GetEffectiveVisibleRegion().ToUnknownRegion().GetBounds()); gfxRect otherRect = ThebesRect(aTwo->GetLocalVisibleRegion().ToUnknownRegion().GetBounds());
MOZ_ASSERT(aOne->GetParent() && aOne->GetParent()->Extend3DContext() && MOZ_ASSERT(aOne->GetParent() && aOne->GetParent()->Extend3DContext() &&
aTwo->GetParent() && aTwo->GetParent()->Extend3DContext()); aTwo->GetParent() && aTwo->GetParent()->Extend3DContext());

View File

@ -131,7 +131,7 @@ struct LayerPropertiesBase : public LayerProperties
explicit LayerPropertiesBase(Layer* aLayer) explicit LayerPropertiesBase(Layer* aLayer)
: mLayer(aLayer) : mLayer(aLayer)
, mMaskLayer(nullptr) , mMaskLayer(nullptr)
, mVisibleRegion(mLayer->GetEffectiveVisibleRegion().ToUnknownRegion()) , mVisibleRegion(mLayer->GetLocalVisibleRegion().ToUnknownRegion())
, mInvalidRegion(aLayer->GetInvalidRegion()) , mInvalidRegion(aLayer->GetInvalidRegion())
, mPostXScale(aLayer->GetPostXScale()) , mPostXScale(aLayer->GetPostXScale())
, mPostYScale(aLayer->GetPostYScale()) , mPostYScale(aLayer->GetPostYScale())

View File

@ -602,7 +602,7 @@ Layer::GetEffectiveClipRect()
} }
const LayerIntRegion& const LayerIntRegion&
Layer::GetEffectiveVisibleRegion() Layer::GetLocalVisibleRegion()
{ {
if (LayerComposite* shadow = AsLayerComposite()) { if (LayerComposite* shadow = AsLayerComposite()) {
return shadow->GetShadowVisibleRegion(); return shadow->GetShadowVisibleRegion();
@ -1017,7 +1017,7 @@ Layer::GetVisibleRegionRelativeToRootLayer(nsIntRegion& aResult,
} }
IntPoint offset; IntPoint offset;
aResult = GetEffectiveVisibleRegion().ToUnknownRegion(); aResult = GetLocalVisibleRegion().ToUnknownRegion();
for (Layer* layer = this; layer; layer = layer->GetParent()) { for (Layer* layer = this; layer; layer = layer->GetParent()) {
gfx::Matrix matrix; gfx::Matrix matrix;
if (!layer->GetLocalTransform().Is2D(&matrix) || if (!layer->GetLocalTransform().Is2D(&matrix) ||
@ -1054,7 +1054,7 @@ Layer::GetVisibleRegionRelativeToRootLayer(nsIntRegion& aResult,
// Retreive the translation from sibling to |layer|. The accumulated // Retreive the translation from sibling to |layer|. The accumulated
// visible region is currently oriented with |layer|. // visible region is currently oriented with |layer|.
IntPoint siblingOffset = RoundedToInt(siblingMatrix.GetTranslation()); IntPoint siblingOffset = RoundedToInt(siblingMatrix.GetTranslation());
nsIntRegion siblingVisibleRegion(sibling->GetEffectiveVisibleRegion().ToUnknownRegion()); nsIntRegion siblingVisibleRegion(sibling->GetLocalVisibleRegion().ToUnknownRegion());
// Translate the siblings region to |layer|'s origin. // Translate the siblings region to |layer|'s origin.
siblingVisibleRegion.MoveBy(-siblingOffset.x, -siblingOffset.y); siblingVisibleRegion.MoveBy(-siblingOffset.x, -siblingOffset.y);
// Apply the sibling's clip. // Apply the sibling's clip.
@ -1443,7 +1443,7 @@ ContainerLayer::DefaultComputeEffectiveTransforms(const Matrix4x4& aTransformToS
// transform while 2D is expected. // transform while 2D is expected.
idealTransform.ProjectTo2D(); idealTransform.ProjectTo2D();
} }
mUseIntermediateSurface = useIntermediateSurface && !GetEffectiveVisibleRegion().IsEmpty(); mUseIntermediateSurface = useIntermediateSurface && !GetLocalVisibleRegion().IsEmpty();
if (useIntermediateSurface) { if (useIntermediateSurface) {
ComputeEffectiveTransformsForChildren(Matrix4x4::From2D(residual)); ComputeEffectiveTransformsForChildren(Matrix4x4::From2D(residual));
} else { } else {
@ -1473,7 +1473,7 @@ ContainerLayer::DefaultComputeSupportsComponentAlphaChildren(bool* aNeedsSurface
bool needsSurfaceCopy = false; bool needsSurfaceCopy = false;
CompositionOp blendMode = GetEffectiveMixBlendMode(); CompositionOp blendMode = GetEffectiveMixBlendMode();
if (UseIntermediateSurface()) { if (UseIntermediateSurface()) {
if (GetEffectiveVisibleRegion().GetNumRects() == 1 && if (GetLocalVisibleRegion().GetNumRects() == 1 &&
(GetContentFlags() & Layer::CONTENT_OPAQUE)) (GetContentFlags() & Layer::CONTENT_OPAQUE))
{ {
mSupportsComponentAlphaChildren = true; mSupportsComponentAlphaChildren = true;

View File

@ -1485,7 +1485,7 @@ public:
// values that should be used when drawing this layer to screen, // values that should be used when drawing this layer to screen,
// accounting for this layer possibly being a shadow. // accounting for this layer possibly being a shadow.
const Maybe<ParentLayerIntRect>& GetEffectiveClipRect(); const Maybe<ParentLayerIntRect>& GetEffectiveClipRect();
const LayerIntRegion& GetEffectiveVisibleRegion(); const LayerIntRegion& GetLocalVisibleRegion();
bool Extend3DContext() { bool Extend3DContext() {
return GetContentFlags() & CONTENT_EXTEND_3D_CONTEXT; return GetContentFlags() & CONTENT_EXTEND_3D_CONTEXT;
@ -1507,7 +1507,7 @@ public:
// For containers extending 3D context, visible region // For containers extending 3D context, visible region
// is meaningless, since they are just intermediate result of // is meaningless, since they are just intermediate result of
// content. // content.
return !GetEffectiveVisibleRegion().IsEmpty() || Extend3DContext(); return !GetLocalVisibleRegion().IsEmpty() || Extend3DContext();
} }
/** /**
@ -2100,7 +2100,7 @@ public:
RenderTargetIntRect GetIntermediateSurfaceRect() RenderTargetIntRect GetIntermediateSurfaceRect()
{ {
NS_ASSERTION(mUseIntermediateSurface, "Must have intermediate surface"); NS_ASSERTION(mUseIntermediateSurface, "Must have intermediate surface");
return RenderTargetIntRect::FromUnknownRect(GetEffectiveVisibleRegion().ToUnknownRegion().GetBounds()); return RenderTargetIntRect::FromUnknownRect(GetLocalVisibleRegion().ToUnknownRegion().GetBounds());
} }
/** /**

View File

@ -63,7 +63,7 @@ FindBackgroundLayer(ReadbackLayer* aLayer, nsIntPoint* aOffset)
nsIntPoint backgroundOffset(int32_t(backgroundTransform._31), int32_t(backgroundTransform._32)); nsIntPoint backgroundOffset(int32_t(backgroundTransform._31), int32_t(backgroundTransform._32));
IntRect rectInBackground(transformOffset - backgroundOffset, aLayer->GetSize()); IntRect rectInBackground(transformOffset - backgroundOffset, aLayer->GetSize());
const nsIntRegion visibleRegion = l->GetEffectiveVisibleRegion().ToUnknownRegion(); const nsIntRegion visibleRegion = l->GetLocalVisibleRegion().ToUnknownRegion();
if (!visibleRegion.Intersects(rectInBackground)) if (!visibleRegion.Intersects(rectInBackground))
continue; continue;
// Since l is present in the background, from here on we either choose l // Since l is present in the background, from here on we either choose l

View File

@ -30,7 +30,7 @@ void RenderTraceLayers(Layer *aLayer, const char *aColor, const gfx::Matrix4x4 a
gfx::Matrix4x4 trans = aRootTransform * aLayer->GetTransform(); gfx::Matrix4x4 trans = aRootTransform * aLayer->GetTransform();
trans.ProjectTo2D(); trans.ProjectTo2D();
gfx::IntRect clipRect = aLayer->GetEffectiveVisibleRegion().GetBounds(); gfx::IntRect clipRect = aLayer->GetLocalVisibleRegion().GetBounds();
Rect rect(clipRect.x, clipRect.y, clipRect.width, clipRect.height); Rect rect(clipRect.x, clipRect.y, clipRect.width, clipRect.height);
trans.TransformBounds(rect); trans.TransformBounds(rect);

View File

@ -222,13 +222,13 @@ RotatedContentBuffer::DrawTo(PaintedLayer* aLayer,
if (!aLayer->GetValidRegion().Contains(BufferRect()) || if (!aLayer->GetValidRegion().Contains(BufferRect()) ||
(ToData(aLayer)->GetClipToVisibleRegion() && (ToData(aLayer)->GetClipToVisibleRegion() &&
!aLayer->GetVisibleRegion().ToUnknownRegion().Contains(BufferRect())) || !aLayer->GetVisibleRegion().ToUnknownRegion().Contains(BufferRect())) ||
IsClippingCheap(aTarget, aLayer->GetEffectiveVisibleRegion().ToUnknownRegion())) { IsClippingCheap(aTarget, aLayer->GetLocalVisibleRegion().ToUnknownRegion())) {
// We don't want to draw invalid stuff, so we need to clip. Might as // We don't want to draw invalid stuff, so we need to clip. Might as
// well clip to the smallest area possible --- the visible region. // well clip to the smallest area possible --- the visible region.
// Bug 599189 if there is a non-integer-translation transform in aTarget, // Bug 599189 if there is a non-integer-translation transform in aTarget,
// we might sample pixels outside GetEffectiveVisibleRegion(), which is wrong // we might sample pixels outside GetLocalVisibleRegion(), which is wrong
// and may cause gray lines. // and may cause gray lines.
gfxUtils::ClipToRegion(aTarget, aLayer->GetEffectiveVisibleRegion().ToUnknownRegion()); gfxUtils::ClipToRegion(aTarget, aLayer->GetLocalVisibleRegion().ToUnknownRegion());
clipped = true; clipped = true;
} }

View File

@ -109,7 +109,7 @@ BasicContainerLayer::ChildrenPartitionVisibleRegion(const gfx::IntRect& aInRect)
return false; return false;
nsIntPoint offset(int32_t(transform._31), int32_t(transform._32)); nsIntPoint offset(int32_t(transform._31), int32_t(transform._32));
gfx::IntRect rect = aInRect.Intersect(GetEffectiveVisibleRegion().ToUnknownRegion().GetBounds() + offset); gfx::IntRect rect = aInRect.Intersect(GetLocalVisibleRegion().ToUnknownRegion().GetBounds() + offset);
nsIntRegion covered; nsIntRegion covered;
for (Layer* l = mFirstChild; l; l = l->GetNextSibling()) { for (Layer* l = mFirstChild; l; l = l->GetNextSibling()) {
@ -121,7 +121,7 @@ BasicContainerLayer::ChildrenPartitionVisibleRegion(const gfx::IntRect& aInRect)
ThebesMatrix(childTransform).HasNonIntegerTranslation() || ThebesMatrix(childTransform).HasNonIntegerTranslation() ||
l->GetEffectiveOpacity() != 1.0) l->GetEffectiveOpacity() != 1.0)
return false; return false;
nsIntRegion childRegion = l->GetEffectiveVisibleRegion().ToUnknownRegion(); nsIntRegion childRegion = l->GetLocalVisibleRegion().ToUnknownRegion();
childRegion.MoveBy(int32_t(childTransform._31), int32_t(childTransform._32)); childRegion.MoveBy(int32_t(childTransform._31), int32_t(childTransform._32));
childRegion.And(childRegion, rect); childRegion.And(childRegion, rect);
if (l->GetClipRect()) { if (l->GetClipRect()) {

View File

@ -260,7 +260,7 @@ public:
// Set the opaque rect to match the bounds of the visible region. // Set the opaque rect to match the bounds of the visible region.
void AnnotateOpaqueRect() void AnnotateOpaqueRect()
{ {
const nsIntRegion visibleRegion = mLayer->GetEffectiveVisibleRegion().ToUnknownRegion(); const nsIntRegion visibleRegion = mLayer->GetLocalVisibleRegion().ToUnknownRegion();
const IntRect& bounds = visibleRegion.GetBounds(); const IntRect& bounds = visibleRegion.GetBounds();
DrawTarget *dt = mTarget->GetDrawTarget(); DrawTarget *dt = mTarget->GetDrawTarget();
@ -447,7 +447,7 @@ MarkLayersHidden(Layer* aLayer, const IntRect& aClipRect,
return; return;
} }
nsIntRegion region = aLayer->GetEffectiveVisibleRegion().ToUnknownRegion(); nsIntRegion region = aLayer->GetLocalVisibleRegion().ToUnknownRegion();
IntRect r = region.GetBounds(); IntRect r = region.GetBounds();
TransformIntRect(r, transform, ToOutsideIntRect); TransformIntRect(r, transform, ToOutsideIntRect);
r.IntersectRect(r, aDirtyRect); r.IntersectRect(r, aDirtyRect);
@ -932,7 +932,7 @@ BasicLayerManager::FlushGroup(PaintLayerContext& aPaintContext, bool aNeedsClipT
if (!mTransactionIncomplete) { if (!mTransactionIncomplete) {
if (aNeedsClipToVisibleRegion) { if (aNeedsClipToVisibleRegion) {
gfxUtils::ClipToRegion(aPaintContext.mTarget, gfxUtils::ClipToRegion(aPaintContext.mTarget,
aPaintContext.mLayer->GetEffectiveVisibleRegion().ToUnknownRegion()); aPaintContext.mLayer->GetLocalVisibleRegion().ToUnknownRegion());
} }
CompositionOp op = GetEffectiveOperator(aPaintContext.mLayer); CompositionOp op = GetEffectiveOperator(aPaintContext.mLayer);
@ -1043,7 +1043,7 @@ BasicLayerManager::PaintLayer(gfxContext* aTarget,
paintLayerContext.Apply2DTransform(); paintLayerContext.Apply2DTransform();
const nsIntRegion visibleRegion = aLayer->GetEffectiveVisibleRegion().ToUnknownRegion(); const nsIntRegion visibleRegion = aLayer->GetLocalVisibleRegion().ToUnknownRegion();
// If needsGroup is true, we'll clip to the visible region after we've popped the group // If needsGroup is true, we'll clip to the visible region after we've popped the group
if (needsClipToVisibleRegion && !needsGroup) { if (needsClipToVisibleRegion && !needsGroup) {
gfxUtils::ClipToRegion(aTarget, visibleRegion); gfxUtils::ClipToRegion(aTarget, visibleRegion);
@ -1064,7 +1064,7 @@ BasicLayerManager::PaintLayer(gfxContext* aTarget,
if (is2D) { if (is2D) {
if (needsGroup) { if (needsGroup) {
PushedGroup pushedGroup = PushedGroup pushedGroup =
PushGroupForLayer(aTarget, aLayer, aLayer->GetEffectiveVisibleRegion().ToUnknownRegion()); PushGroupForLayer(aTarget, aLayer, aLayer->GetLocalVisibleRegion().ToUnknownRegion());
PaintSelfOrChildren(paintLayerContext, pushedGroup.mGroupTarget); PaintSelfOrChildren(paintLayerContext, pushedGroup.mGroupTarget);
PopGroupForLayer(pushedGroup); PopGroupForLayer(pushedGroup);
} else { } else {

View File

@ -63,7 +63,7 @@ BasicPaintedLayer::PaintThebes(gfxContext* aContext,
mValidRegion.SetEmpty(); mValidRegion.SetEmpty();
mContentClient->Clear(); mContentClient->Clear();
nsIntRegion toDraw = IntersectWithClip(GetEffectiveVisibleRegion().ToUnknownRegion(), aContext); nsIntRegion toDraw = IntersectWithClip(GetLocalVisibleRegion().ToUnknownRegion(), aContext);
RenderTraceInvalidateStart(this, "FFFF00", toDraw.GetBounds()); RenderTraceInvalidateStart(this, "FFFF00", toDraw.GetBounds());
@ -169,7 +169,7 @@ BasicPaintedLayer::Validate(LayerManager::DrawPaintedLayerCallback aCallback,
// from RGB to RGBA, because we might need to repaint with // from RGB to RGBA, because we might need to repaint with
// subpixel AA) // subpixel AA)
state.mRegionToInvalidate.And(state.mRegionToInvalidate, state.mRegionToInvalidate.And(state.mRegionToInvalidate,
GetEffectiveVisibleRegion().ToUnknownRegion()); GetLocalVisibleRegion().ToUnknownRegion());
SetAntialiasingFlags(this, target); SetAntialiasingFlags(this, target);
RenderTraceInvalidateStart(this, "FFFF00", state.mRegionToDraw.GetBounds()); RenderTraceInvalidateStart(this, "FFFF00", state.mRegionToDraw.GetBounds());

View File

@ -75,7 +75,7 @@ ClientPaintedLayer::PaintThebes()
// from RGB to RGBA, because we might need to repaint with // from RGB to RGBA, because we might need to repaint with
// subpixel AA) // subpixel AA)
state.mRegionToInvalidate.And(state.mRegionToInvalidate, state.mRegionToInvalidate.And(state.mRegionToInvalidate,
GetEffectiveVisibleRegion().ToUnknownRegion()); GetLocalVisibleRegion().ToUnknownRegion());
bool didUpdate = false; bool didUpdate = false;
RotatedContentBuffer::DrawIterator iter; RotatedContentBuffer::DrawIterator iter;

View File

@ -97,7 +97,7 @@ static void DrawLayerInfo(const RenderTargetIntRect& aClipRect,
template<class ContainerT> template<class ContainerT>
static gfx::IntRect ContainerVisibleRect(ContainerT* aContainer) static gfx::IntRect ContainerVisibleRect(ContainerT* aContainer)
{ {
gfx::IntRect surfaceRect = aContainer->GetEffectiveVisibleRegion().ToUnknownRegion().GetBounds(); gfx::IntRect surfaceRect = aContainer->GetLocalVisibleRegion().ToUnknownRegion().GetBounds();
return surfaceRect; return surfaceRect;
} }
@ -109,8 +109,8 @@ static void PrintUniformityInfo(Layer* aLayer)
} }
// Don't want to print a log for smaller layers // Don't want to print a log for smaller layers
if (aLayer->GetEffectiveVisibleRegion().GetBounds().width < 300 || if (aLayer->GetLocalVisibleRegion().GetBounds().width < 300 ||
aLayer->GetEffectiveVisibleRegion().GetBounds().height < 300) { aLayer->GetLocalVisibleRegion().GetBounds().height < 300) {
return; return;
} }
@ -234,7 +234,7 @@ ContainerRenderVR(ContainerT* aContainer,
IntRectToRect(static_cast<CanvasLayer*>(layer)->GetBounds()); IntRectToRect(static_cast<CanvasLayer*>(layer)->GetBounds());
} else { } else {
layerBounds = layerBounds =
IntRectToRect(layer->GetEffectiveVisibleRegion().ToUnknownRegion().GetBounds()); IntRectToRect(layer->GetLocalVisibleRegion().ToUnknownRegion().GetBounds());
} }
const gfx::Matrix4x4 childTransform = layer->GetEffectiveTransform(); const gfx::Matrix4x4 childTransform = layer->GetEffectiveTransform();
layerBounds = childTransform.TransformBounds(layerBounds); layerBounds = childTransform.TransformBounds(layerBounds);
@ -625,7 +625,7 @@ CreateOrRecycleTarget(ContainerT* aContainer,
Compositor* compositor = aManager->GetCompositor(); Compositor* compositor = aManager->GetCompositor();
SurfaceInitMode mode = INIT_MODE_CLEAR; SurfaceInitMode mode = INIT_MODE_CLEAR;
gfx::IntRect surfaceRect = ContainerVisibleRect(aContainer); gfx::IntRect surfaceRect = ContainerVisibleRect(aContainer);
if (aContainer->GetEffectiveVisibleRegion().GetNumRects() == 1 && if (aContainer->GetLocalVisibleRegion().GetNumRects() == 1 &&
(aContainer->GetContentFlags() & Layer::CONTENT_OPAQUE)) (aContainer->GetContentFlags() & Layer::CONTENT_OPAQUE))
{ {
mode = INIT_MODE_NONE; mode = INIT_MODE_NONE;
@ -650,7 +650,7 @@ CreateTemporaryTargetAndCopyFromBackground(ContainerT* aContainer,
LayerManagerComposite* aManager) LayerManagerComposite* aManager)
{ {
Compositor* compositor = aManager->GetCompositor(); Compositor* compositor = aManager->GetCompositor();
gfx::IntRect visibleRect = aContainer->GetEffectiveVisibleRegion().ToUnknownRegion().GetBounds(); gfx::IntRect visibleRect = aContainer->GetLocalVisibleRegion().ToUnknownRegion().GetBounds();
RefPtr<CompositingRenderTarget> previousTarget = compositor->GetCurrentRenderTarget(); RefPtr<CompositingRenderTarget> previousTarget = compositor->GetCurrentRenderTarget();
gfx::IntRect surfaceRect = gfx::IntRect(visibleRect.x, visibleRect.y, gfx::IntRect surfaceRect = gfx::IntRect(visibleRect.x, visibleRect.y,
visibleRect.width, visibleRect.height); visibleRect.width, visibleRect.height);
@ -718,7 +718,7 @@ ContainerRender(ContainerT* aContainer,
return; return;
} }
gfx::Rect visibleRect(aContainer->GetEffectiveVisibleRegion().ToUnknownRegion().GetBounds()); gfx::Rect visibleRect(aContainer->GetLocalVisibleRegion().ToUnknownRegion().GetBounds());
RefPtr<Compositor> compositor = aManager->GetCompositor(); RefPtr<Compositor> compositor = aManager->GetCompositor();
#ifdef MOZ_DUMP_PAINTING #ifdef MOZ_DUMP_PAINTING
if (gfxEnv::DumpCompositorTextures()) { if (gfxEnv::DumpCompositorTextures()) {

View File

@ -1207,7 +1207,7 @@ LayerManagerComposite::ComputeRenderIntegrityInternal(Layer* aLayer,
} }
// See if there's any incomplete rendering // See if there's any incomplete rendering
nsIntRegion incompleteRegion = aLayer->GetEffectiveVisibleRegion().ToUnknownRegion(); nsIntRegion incompleteRegion = aLayer->GetLocalVisibleRegion().ToUnknownRegion();
incompleteRegion.Sub(incompleteRegion, paintedLayer->GetValidRegion()); incompleteRegion.Sub(incompleteRegion, paintedLayer->GetValidRegion());
if (!incompleteRegion.IsEmpty()) { if (!incompleteRegion.IsEmpty()) {

View File

@ -577,7 +577,7 @@ RenderWithAllMasks(Layer* aLayer, Compositor* aCompositor,
// into. The final mask gets rendered into the original render target. // into. The final mask gets rendered into the original render target.
// Calculate the size of the intermediate surfaces. // Calculate the size of the intermediate surfaces.
gfx::Rect visibleRect(aLayer->GetEffectiveVisibleRegion().ToUnknownRegion().GetBounds()); gfx::Rect visibleRect(aLayer->GetLocalVisibleRegion().ToUnknownRegion().GetBounds());
gfx::Matrix4x4 transform = aLayer->GetEffectiveTransform(); gfx::Matrix4x4 transform = aLayer->GetEffectiveTransform();
// TODO: Use RenderTargetIntRect and TransformBy here // TODO: Use RenderTargetIntRect and TransformBy here
gfx::IntRect surfaceRect = gfx::IntRect surfaceRect =

View File

@ -112,7 +112,7 @@ PaintedLayerComposite::RenderLayer(const gfx::IntRect& aClipRect)
mBuffer->GetLayer() == this, mBuffer->GetLayer() == this,
"buffer is corrupted"); "buffer is corrupted");
const nsIntRegion visibleRegion = GetEffectiveVisibleRegion().ToUnknownRegion(); const nsIntRegion visibleRegion = GetLocalVisibleRegion().ToUnknownRegion();
#ifdef MOZ_DUMP_PAINTING #ifdef MOZ_DUMP_PAINTING
if (gfxEnv::DumpCompositorTextures()) { if (gfxEnv::DumpCompositorTextures()) {

View File

@ -280,7 +280,7 @@ HwcComposer2D::PrepareLayerList(Layer* aLayer,
bool fillColor = false; bool fillColor = false;
const nsIntRegion visibleRegion = aLayer->GetEffectiveVisibleRegion().ToUnknownRegion(); const nsIntRegion visibleRegion = aLayer->GetLocalVisibleRegion().ToUnknownRegion();
if (visibleRegion.IsEmpty()) { if (visibleRegion.IsEmpty()) {
return true; return true;
} }