diff --git a/gfx/layers/LayerTreeInvalidation.cpp b/gfx/layers/LayerTreeInvalidation.cpp index 13319271d2d7..470f29b41838 100644 --- a/gfx/layers/LayerTreeInvalidation.cpp +++ b/gfx/layers/LayerTreeInvalidation.cpp @@ -59,12 +59,14 @@ AddTransformedRegion(nsIntRegion& aDest, const nsIntRegion& aSource, const gfx3D while ((r = iter.Next())) { aDest.Or(aDest, TransformRect(*r, aTransform)); } + aDest.SimplifyOutward(20); } static void AddRegion(nsIntRegion& aDest, const nsIntRegion& aSource) { aDest.Or(aDest, aSource); + aDest.SimplifyOutward(20); } static nsIntRegion diff --git a/gfx/layers/basic/BasicThebesLayer.h b/gfx/layers/basic/BasicThebesLayer.h index c84060aa8925..5af62dc67c77 100644 --- a/gfx/layers/basic/BasicThebesLayer.h +++ b/gfx/layers/basic/BasicThebesLayer.h @@ -53,6 +53,7 @@ public: NS_ASSERTION(BasicManager()->InConstruction(), "Can only set properties in construction phase"); mInvalidRegion.Or(mInvalidRegion, aRegion); + mInvalidRegion.SimplifyOutward(20); mValidRegion.Sub(mValidRegion, mInvalidRegion); } diff --git a/gfx/layers/client/ClientThebesLayer.h b/gfx/layers/client/ClientThebesLayer.h index 7ee9b9c4c8cf..098013167ac6 100644 --- a/gfx/layers/client/ClientThebesLayer.h +++ b/gfx/layers/client/ClientThebesLayer.h @@ -60,6 +60,7 @@ public: NS_ASSERTION(ClientManager()->InConstruction(), "Can only set properties in construction phase"); mInvalidRegion.Or(mInvalidRegion, aRegion); + mInvalidRegion.SimplifyOutward(20); mValidRegion.Sub(mValidRegion, mInvalidRegion); } diff --git a/gfx/layers/d3d10/ThebesLayerD3D10.cpp b/gfx/layers/d3d10/ThebesLayerD3D10.cpp index 6fabe8678eda..976aae3b842a 100644 --- a/gfx/layers/d3d10/ThebesLayerD3D10.cpp +++ b/gfx/layers/d3d10/ThebesLayerD3D10.cpp @@ -47,7 +47,7 @@ void ThebesLayerD3D10::InvalidateRegion(const nsIntRegion &aRegion) { mInvalidRegion.Or(mInvalidRegion, aRegion); - mInvalidRegion.SimplifyOutward(10); + mInvalidRegion.SimplifyOutward(20); mValidRegion.Sub(mValidRegion, mInvalidRegion); } diff --git a/gfx/layers/d3d9/ThebesLayerD3D9.cpp b/gfx/layers/d3d9/ThebesLayerD3D9.cpp index 500aa9cd4c6e..f692a158b5bc 100644 --- a/gfx/layers/d3d9/ThebesLayerD3D9.cpp +++ b/gfx/layers/d3d9/ThebesLayerD3D9.cpp @@ -50,6 +50,7 @@ void ThebesLayerD3D9::InvalidateRegion(const nsIntRegion &aRegion) { mInvalidRegion.Or(mInvalidRegion, aRegion); + mInvalidRegion.SimplifyOutward(20); mValidRegion.Sub(mValidRegion, mInvalidRegion); }