Report a DrawTargetTiled as a capture if it is made of captures (bug 1425056, r=bas)
authorRyan Hunt <rhunt@eqrion.net>
Wed, 13 Dec 2017 09:27:07 -0600
changeset 452958 af2ed1a4a02bb8b4c2c3a22589398ecff4fdcba3
parent 452957 4d88e13db33bf9c01a89475ab423192df94f4628
child 452959 1cbfd11a64c8e8c790eae0852fa3e492f40282c8
push id1648
push usermtabara@mozilla.com
push dateThu, 01 Mar 2018 12:45:47 +0000
treeherdermozilla-release@cbb9688c2eeb [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersbas
bugs1425056
milestone59.0a1
first release with
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
last release without
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
Report a DrawTargetTiled as a capture if it is made of captures (bug 1425056, r=bas) This will make it so that we avoid main thread rasterization for box shadows. MozReview-Commit-ID: 9Tg4dsH21V6
gfx/2d/DrawTargetTiled.h
--- a/gfx/2d/DrawTargetTiled.h
+++ b/gfx/2d/DrawTargetTiled.h
@@ -37,16 +37,17 @@ class DrawTargetTiled : public DrawTarge
 {
 public:
   DrawTargetTiled();
 
   bool Init(const TileSet& mTiles);
 
   virtual bool IsTiledDrawTarget() const override { return true; }
 
+  virtual bool IsCaptureDT() const override { return mTiles[0].mDrawTarget->IsCaptureDT(); }
   virtual DrawTargetType GetType() const override { return mTiles[0].mDrawTarget->GetType(); }
   virtual BackendType GetBackendType() const override { return mTiles[0].mDrawTarget->GetBackendType(); }
   virtual already_AddRefed<SourceSurface> Snapshot() override;
   virtual void DetachAllSnapshots() override;
   virtual IntSize GetSize() override {
     MOZ_ASSERT(mRect.Width() > 0 && mRect.Height() > 0);
     return IntSize(mRect.XMost(), mRect.YMost());
   }