You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Currently the animation of the turtle sprite is a bottleneck for performance: you can't go faster than a few hundred moves per second. That is because each time the turtle is moved and a new line segment is drawn, its current position is recomputed in a pretty slow way. (The 2d transforms are zeroed, then the untransformed position is read, then the 2d transforms are reapplied, and the math is done in parallel by hand to see exactly where the transform-origin of the turtle is on the screen.)
We should investigate ways to speed it up, e.g.,:
Assume that the untransformed position doesn't change under certain conditions.
And in those cases assume that we can just cache and read position data on the side instead of deriving it from the dom.
The text was updated successfully, but these errors were encountered:
Relative turtle motions have now been sped up by about tenfold - for example, a classic "fern" fractal example that used to take about 20 seconds to render can be done in one second (which is still not fast enough, but at least it's faster than before). Absolute turtle motions are still slow; these need to be sped up next.
The compromise made is that, as long as a pen is down, the pen location is not sensitive to parent element transformation changes. The parent transforms are read again when the pen is up.
Currently the animation of the turtle sprite is a bottleneck for performance: you can't go faster than a few hundred moves per second. That is because each time the turtle is moved and a new line segment is drawn, its current position is recomputed in a pretty slow way. (The 2d transforms are zeroed, then the untransformed position is read, then the 2d transforms are reapplied, and the math is done in parallel by hand to see exactly where the transform-origin of the turtle is on the screen.)
We should investigate ways to speed it up, e.g.,:
The text was updated successfully, but these errors were encountered: