I'm guessing the point is to create a scaled version for some reason;) if not well yes thats even easier:)
On Thu, Mar 5, 2009 at 5:02 PM, Keith Reinfeld <keithreinf...@comcast.net>wrote: > > > > How to create img2 correctly? > > The same way you created img: > > duplicateMovieClipImage(mc,img2); > img2._xscale=50; > img2._yscale=50; > > > Regards, > > -Keith > http://keithreinfeld.home.comcast.net > > > > -----Original Message----- > > From: flashcoders-boun...@chattyfig.figleaf.com [mailto:flashcoders- > > boun...@chattyfig.figleaf.com] On Behalf Of natalia Vikhtinskaya > > Sent: Thursday, March 05, 2009 5:54 AM > > To: Flash Coders List > > Subject: Re: [Flashcoders] Duplicate Bitmap and scale question > > > > How to create img2 correctly? > > > > 2009/3/4 Hans Wichman <j.c.wich...@objectpainters.com>: > > > Hi, > > > > > > you create a clip based on mc's width, called img. > > > then you scale image, so its width is half of what it used to be. > > > Then you draw img into img2. Img2's size is based on half the height > and > > > width, but the draw method ignores those transformation, so it draws an > > > unscaled version of img in img2. > > > > > > regards > > > JC > > > > > > On Sun, Mar 1, 2009 at 3:58 PM, natalia Vikhtinskaya > > > <natavi.m...@gmail.com>wrote: > > > > > >> Hi > > >> Please explain what is wrong in this code: > > >> function duplicateMovieClipImage(from:MovieClip, target:MovieClip){ > > >> var visuals = new flash.display.BitmapData(from._width, > > >> from._height); > > >> visuals.draw(from); > > >> target.attachBitmap(visuals, 1,"auto",true); > > >> > > >> } > > >> > > >> duplicateMovieClipImage(mc,img) > > >> img._xscale=50; > > >> img._yscale=50; > > >> duplicateMovieClipImage(img,img2) > > >> I expected that img1 and img2 have the same scale. Instead of that > > >> img2 show 50% of mc. > > >> _______________________________________________ > > >> Flashcoders mailing list > > >> Flashcoders@chattyfig.figleaf.com > > >> http://chattyfig.figleaf.com/mailman/listinfo/flashcoders > > >> > > > _______________________________________________ > > > Flashcoders mailing list > > > Flashcoders@chattyfig.figleaf.com > > > http://chattyfig.figleaf.com/mailman/listinfo/flashcoders > > > > > > > _______________________________________________ > > Flashcoders mailing list > > Flashcoders@chattyfig.figleaf.com > > http://chattyfig.figleaf.com/mailman/listinfo/flashcoders > > > _______________________________________________ > Flashcoders mailing list > Flashcoders@chattyfig.figleaf.com > http://chattyfig.figleaf.com/mailman/listinfo/flashcoders > _______________________________________________ Flashcoders mailing list Flashcoders@chattyfig.figleaf.com http://chattyfig.figleaf.com/mailman/listinfo/flashcoders