Bug 1066147: Clear new DrawTargets upon creation in D2D 1.1 backend. r=jrmuizel
authorBas Schouten <bschouten@mozilla.com>
Sun, 14 Sep 2014 23:51:33 +0200
changeset 205254 47a39c2ed71a3efe0ed18edcd5d5f3b018e889b6
parent 205253 97e016e1192ad4f39f463b052c2b120c3ad39359
child 205255 c4a053c8a202bcbb3acb5aa893491fc5d289fca7
push id49118
push userbschouten@mozilla.com
push dateSun, 14 Sep 2014 21:53:14 +0000
treeherdermozilla-inbound@8e28464849fa [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersjrmuizel
bugs1066147
milestone35.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
Bug 1066147: Clear new DrawTargets upon creation in D2D 1.1 backend. r=jrmuizel
gfx/2d/DrawTargetD2D1.cpp
--- a/gfx/2d/DrawTargetD2D1.cpp
+++ b/gfx/2d/DrawTargetD2D1.cpp
@@ -770,16 +770,18 @@ DrawTargetD2D1::Init(const IntSize &aSiz
   }
 
   mDC->CreateBitmap(D2DIntSize(aSize), nullptr, 0, props, (ID2D1Bitmap1**)byRef(mTempBitmap));
 
   mDC->SetTarget(mBitmap);
 
   mDC->BeginDraw();
 
+  mDC->Clear();
+
   mFormat = aFormat;
   mSize = aSize;
 
   return true;
 }
 
 /**
  * Private helpers.