title: AS3 Blitting - Copy Pixels getting some of the source image
body: <p>I am trying to draw something on the screen and then, copy that onto a bitmap which is on stage.</p>
  
  <p>I have done this before, with a procedurally drawn shape like a circle but when I use a library item most of the source pixels get cut off.</p>
  
  <p>here's my code - in another function the bitmap object is added to the stage and I can see that copyPixels work but as I have said copies only some of the pixels. I have tried playing with the Rectangle but no luck so far.</p>
  
  <pre><code>var s:StarAsset = new StarAsset();
  
          s.x = e.stageX;
          s.y = e.stageY;
          s.scaleX = e.pressure * 10;
          s.scaleY = e.pressure * 10;
          s.rotation = Math.random() * 360;
  
  
  
          var bms:BitmapData = new BitmapData(s.width + 6, s.height + 6, true, 0x00000000);
          bms.draw(s);
  
          var srect:Rectangle = new Rectangle();
          srect.width = s.width + 6;
          srect.height = s.height + 6;
  
          var destpoint:Point = new Point(s.x, s.y);
          bmcontainer.copyPixels(bms, srect, destpoint, null, null, true);
  </code></pre>