On Aug 30, 2011, at 10:04 PM, Diederik van Lierop wrote:
On 08/30/2011 10:10 PM, Diederik van Lierop wrote:
On 08/30/2011 09:51 PM, Johan Engelen wrote:
For LPE, it is also be desirable to cache intermediate results, so something like this would be awesome: SPItem::addItemToCache(string key, any value) optional value SPItem::retrieveFromCache(string key)
That would be great for snapping too! I would use it to store the intersections found within a single path, instead of calculating them over-and-over again on each snap call.
Another idea I dreamed about last night: we could update the item cache in a separate background process. If inkscape sits idle for a few seconds, then it could run code to calculate new bounding boxes, path intersections, etc.
BTW we could store the sbasis representation of a path too.
Yes. Overall caching the *right* stuff, and in the right way, can be a big performance boost. We definitely need to be looking at this from a comprehensive perspective.
Can someone start a wiki page to collect up notes, potential cached items/operations, etc?