|
From: Roger H. <rog...@mi...> - 2004-07-01 20:03:54
|
I have been investigating why my program is so slow when a user does a marquee selection. I set up a reasonable test case of 50 to 60 spheres and pulled out a rectangle around about 80% of the spheres. Quesa returned about 28000 hits, and my program works through the list asking for the data on each of the hits in turn. I find that when I ask for item N the routine e3pick_hit_find is chasing up a list to a depth of N. So in total that is N squared over 2 - about 392000000 times that it has to do "currentHit = currentHit->nextHit;" I think this might be why this section of my program might be so slow. Would it be feasible to use an array instead of a chain? If so, any hints on how to do it would be appreciated. Roger. |