# Bitmap drawing problem

**URL:** https://forum.kirupa.com/t/bitmap-drawing-problem/326281
**Category:** flash
**Created:** [December 4, 2011, 9:43pm UTC](https://forum.kirupa.com/t/bitmap-drawing-problem/326281 "2011-12-04T21:43:23Z")
**Posts on this page:** 1
**Page:** 1

<div class="post-metadata">

### Author: ![Tompa](https://avatars.discourse-cdn.com/v4/letter/t/6de8d8/32.png) [@Tompa](https://forum.kirupa.com/u/Tompa)
#### Post date: [December 4, 2011, 9:43pm UTC](https://forum.kirupa.com/t/bitmap-drawing-problem/326281/1 "2011-12-04T21:43:23Z")

</div>

Hello!  
_The title might be misleading since i have no idea what’s happening!_  
I have 2x MovieClips which are filled with their own textures  
whenever I press a button but when i add the textures,  
it looks like this:

**But!**  
When i change the size of the Flash Player-window,  
like maximizing or changing the size in any way,  
it now looks like this ( **As it should look like!** )

```auto
function drawMc(w:int, h:int, mc:MovieClip):void{
	var mySprite:Sprite = new Sprite();
	var myBitmap:BitmapData = new BitmapData(loader.width, loader.height);
	myBitmap.draw(loader);
                    
	mySprite.graphics.clear();
	mySprite.graphics.beginBitmapFill(myBitmap);
	mySprite.graphics.drawRect(0,0,w,h);
	mySprite.graphics.endFill();
	mc.addChild(mySprite);
}

```

_Really grateful for help!_  
_~Tompa_
