I second the quad tree suggestion. Back in the day, I worked on a project with tens of thousands of items, and a quad tree approach kept the drawing quite fast, even on what we would now consider to be *very* slow machines.
Tim > -----Original Message----- > From: [EMAIL PROTECTED] > [mailto:[EMAIL PROTECTED] Behalf Of > Frank Condello > Sent: Sunday, January 21, 2007 12:15 PM > To: REALbasic NUG > Subject: Re: Super canvas ? > > > On 21-Jan-07, at 2:23 PM, Trausti Thor Johannsson wrote: > > > Has anyone got a solution for a super canvas ? > > > > My problem is this. > > > > I draw objects into a canvas depending if they are in view or not, > > not in view, I don't draw them. > > > > Sounds simple enough, except my problem is that the total big > > picture can easily get to be a few million pixles in height and > > width, and of course when I have an array of few hundred items > > scattered around, this gets really slow really fast. > > > > And now on a G5 and MBP Intel it is almost to the point of being > > useless. > > > > Any ideas ? > > Use some sort of space partitioning to enable coarser visibility > tests. A quad tree would be my first choice for a 2D canvas, but it > all depends on the data you're drawing. A Google search for "quad > tree" or "space partitioning" should turn up some good resources. > > Frank. > <http://developer.chaoticbox.com/> > > > _______________________________________________ > Unsubscribe or switch delivery mode: > <http://www.realsoftware.com/support/listmanager/> > > Search the archives of this list here: > <http://support.realsoftware.com/listarchives/lists.html> > > -- > No virus found in this incoming message. > Checked by AVG Free Edition. > Version: 7.5.432 / Virus Database: 268.17.3/642 - Release Date: > 1/20/2007 10:31 PM > -- No virus found in this outgoing message. Checked by AVG Free Edition. Version: 7.5.432 / Virus Database: 268.17.3/642 - Release Date: 1/20/2007 10:31 PM _______________________________________________ Unsubscribe or switch delivery mode: <http://www.realsoftware.com/support/listmanager/> Search the archives of this list here: <http://support.realsoftware.com/listarchives/lists.html>
