Hello,

just want to chime in and say that fc2 does hit-testing differently,  
similar to the way you patched the fc1 code (bounding box as the first  
coarse test). It also uses the spatial query facility (that's what  
hit-testing is called in fc2) to cull away objects that are not within the  
viewport. This can give speedups if you are only viewing mostly portions  
of the view as only the objects which are actually in the viewport have to  
be drawn.

Right now the culling and hit-testing is done in a linear fashion, by  
iterating over all objects in a list. However, there's already a stub  
implementation in the rtree.py file (which does things in the linear  
fashion right now). It is likely not difficult to integrate it with  
http://pypi.python.org/pypi/Rtree (C library for rtrees) to perform  
hit-testing and culling in a much faster way.

Not sure if this helps you, but I wanted to mention it before you do a lot  
of extra work...

-Matthias
_______________________________________________
FloatCanvas mailing list
[email protected]
http://mail.mithis.com/cgi-bin/mailman/listinfo/floatcanvas

Reply via email to