hi
this is my first time here so, hi to all!
so, i’m having a problem with the smoothing bitmap property that’s really getting my nerves. here’s part of the code.
function imgLoad() {
var img:MovieClip=new empty();
var imgRequest:URLRequest=new URLRequest(unescape(infoXml.firstChild.childNodes[actImg].childNodes[0].childNodes.toString()));
var imgIn:MovieClip=new empty();
var imgLoader:Loader=new Loader();
imgLoader.load(imgRequest);
imgLoader.contentLoaderInfo.addEventListener('complete',imgLoaded);
imgIn.addChild(imgLoader);
img.imagePath=unescape(infoXml.firstChild.childNodes[actImg].childNodes[0].childNodes.toString());
img.addChild(imgIn);
img.x=pos;
var over:MovieClip=new hover();
over.x=-9;
over.blendMode=BlendMode.OVERLAY;
img.addChild(over);
img.addEventListener(MouseEvent.ROLL_OVER,overBtn);
img.addEventListener(MouseEvent.ROLL_OUT,outBtn);
img.addEventListener(MouseEvent.CLICK,external,false, 0, true);
img.buttonMode=true;
placer_mc.addChild(img);
}
function imgLoaded(event:Event) {
var imagem:Bitmap=event.currentTarget.content as Bitmap;
imagem.smoothing=true;
imagem.width=imagem.width/(imagem.height/99);
imagem.height=99;
imagem.smoothing=true;
MovieClip(imagem.parent.parent.parent).getChildAt(1).width=imagem.width;
MovieClip(imagem.parent.parent.parent).getChildAt(1).alpha=0;
imagem.smoothing=true;
pos+=imagem.width+1+MovieClip(imagem.parent.parent).x;
actImg+=1;
if (actImg<infoXml.firstChild.childNodes.length) {
imgLoad();
}
}
the thing is that my image isn’t getting smoothed and i don’t understand why
i’m new to AS3 so, it’s the first time i try to use the smoothing property here. before, with AS2, I used forceSmoothing to the _mc where the image was and it worked fine.
as you can see, i’m trying to smooth the image several times so that i’m sure it stays “true” for the intire script( i googled in this subject and found something about this property, sometimes, turned to “false”, when the some image properties were changed)
so, if someone could help me i would very thankful
(if someone could also tell me if my code is “AS3 good”, it would be cool, since i’m learning it all by myself and i’m not sure if i’m doing everithing right)
see ya and thank you all