PDA

View Full Version : Artifacts in moving images


SilverVenom
01-26-2007, 02:42 AM
Hi, I was wondering if there was a solution to the "square box" artifacts when an image is being moved.

The .jpg is already sized to the correct size, and then it is put in a movie, which rotates in a carousel effect. If the carousel is moving slowly, the images begin to show serious "box" artifacts which are really annoying. Flash isn't resizing them, increasing the frame rate doesn't help, I've tried cacheAsBitmap, and a few other things, but nothing is helping. Is there a way to make flash antialias the dynamically loaded images?

Any solutions to this problem? Or am I stuck?

happycoder242
01-27-2007, 05:57 PM
try updateAfterEvent()

the following is taken from the help in Flash 8:

updateAfterEvent function
updateAfterEvent() : Void

Updates the display (independent of the frames per second set for the movie) when you call it within an onClipEvent() handler or as part of a function or method that you pass to setInterval(). Flash ignores calls to updateAfterEvent that are not within an onClipEvent() handler or part of a function or method passed to setInterval(). This function works only with certain Mouse and MovieClip handlers: the mouseDown, mouseUp, mouseMove, keyDown and keyUp handlers for the Mouse class; the onMouseMove, onMouseDown, onMouseUp, onKeyDown, and onKeyUp handlers for the MovieClip class. It does not work with the Key class.

Availability: ActionScript 1.0; Flash Player 5

Example
The following example show how to create a custom cursor called cursor_mc. ActionScript is used to replace the mouse cursor with cursor_mc. Then updateAfterEvent() is used to continually refresh the Stage to make the cursor's movement appear smooth.

Mouse.hide();
cursor_mc.onMouseMove = function() {
this._x = this._parent._xmouse;
this._y = this._parent._ymouse;
updateAfterEvent();
};