Bug 805792 - Avoid another extra copie when calling RenderTile. r=Cwiiis
authorBenoit Girard <b56girard@gmail.com>
Fri, 26 Oct 2012 10:44:48 -0400
changeset 111686 3083e652374ae9b39ee2cbbca501be1479a1c798
parent 111685 2373c969584c51e46467c1a9762c57aef19e21e8
child 111687 1d857107b77883abebf8122b7d3c8b11806071d7
push id93
push usernmatsakis@mozilla.com
push dateWed, 31 Oct 2012 21:26:57 +0000
reviewersCwiiis
bugs805792
milestone19.0a1
Bug 805792 - Avoid another extra copie when calling RenderTile. r=Cwiiis
gfx/layers/opengl/TiledThebesLayerOGL.cpp
gfx/layers/opengl/TiledThebesLayerOGL.h
layout/style/test/test_rem_unit.html
--- a/gfx/layers/opengl/TiledThebesLayerOGL.cpp
+++ b/gfx/layers/opengl/TiledThebesLayerOGL.cpp
@@ -192,17 +192,17 @@ TiledThebesLayerOGL::ProcessUploadQueue(
   // FIXME: This wont be needed when we do progressive upload and lock
   // tile by tile.
   mMainMemoryTiledBuffer = BasicTiledLayerBuffer();
   mRegionToUpload = nsIntRegion();
 
 }
 
 void
-TiledThebesLayerOGL::RenderTile(TiledTexture aTile,
+TiledThebesLayerOGL::RenderTile(const TiledTexture& aTile,
                                 const gfx3DMatrix& aTransform,
                                 const nsIntPoint& aOffset,
                                 const nsIntRegion& aScreenRegion,
                                 const nsIntPoint& aTextureOffset,
                                 const nsIntSize& aTextureBounds,
                                 Layer* aMaskLayer)
 {
     gl()->fBindTexture(LOCAL_GL_TEXTURE_2D, aTile.mTextureHandle);
--- a/gfx/layers/opengl/TiledThebesLayerOGL.h
+++ b/gfx/layers/opengl/TiledThebesLayerOGL.h
@@ -126,17 +126,17 @@ public:
        OptionalThebesBuffer* aReadOnlyFront, nsIntRegion* aFrontUpdatedRegion)
   {
     NS_ABORT_IF_FALSE(false, "Not supported");
   }
   void PaintedTiledLayerBuffer(const BasicTiledLayerBuffer* mTiledBuffer);
   void ProcessUploadQueue();
 
   // Renders a single given tile.
-  void RenderTile(TiledTexture aTile,
+  void RenderTile(const TiledTexture& aTile,
                   const gfx3DMatrix& aTransform,
                   const nsIntPoint& aOffset,
                   const nsIntRegion& aScreenRegion,
                   const nsIntPoint& aTextureOffset,
                   const nsIntSize& aTextureBounds,
                   Layer* aMaskLayer);
 
 private: