PDA

View Full Version : curveTo rendering problem's


zeman
02-08-2005, 12:59 AM
Has anyone had problems with curveTo rendering errors?

Take a look at the map I'm developing.

photoblog world map (http://www.allthegoodness.com/scarytan/)

If you keep zooming further and further into Europe you'll start to see random lines appear and disappear.

The line is redrawn with every zoom and I've double checked to make sure the location points aren't moving. In fact the lines between locations are drawn correctly, there just seem to be extra random lines appearing the further you zoom in.

I've tried switching to lineTo and get the same problem.

Any thoughts or code to try out would be very appreciated.

Here's the line drawing code I'm using.


with (_root.path) {
lineStyle (0, 0x666666, 60);
imageX = point.x + imageX;
imageY = point.y + imageY;
if (_root.pathstartX < imageX) {
thispathcurveX = _root.pathstartX + ((imageX - _root.pathstartX) / 2);
} else {
thispathcurveX = imageX + ((_root.pathstartX - imageX) / 2);
}
if (_root.pathstartY < imageY) {
thispathcurveY = _root.pathstartY;
} else {
thispathcurveY = imageY;
}
// draw curve
curveTo(thispathcurveX, thispathcurveY, imageX, imageY);
}
// set next pathstart var
_root.pathstartX = imageX;
_root.pathstartY = imageY;

ericlin
02-10-2005, 05:43 PM
I guess it is out of the limit Flash can accept.

I did a simple test. If I supply an x value bigger than 40729, then even the lineTo would go wrong. I did not test curve to.

You can trace those coordinates in your map. I guess some values are too big.