blog.sketchit.de Glaubt mir ich hab den Weihnachtsmann mit eigenen Augen gesehen…

29Dez/090

QuadTrees Actionscript 3

Note: Hence, I write my articles in english (and I'm glad if you notice any mistake and send it to me).

In our course Computergraphics I've developed an implementation of QuadTrees for Actionscript 3. A QuadTree is a datastructure for increasing the efficiency of collisiondetection or nearest neighbour appointment.

Wiki

You can enable the collisiondetection by hitting a "C" and switch between QuadTree and Bruteforce by hitting Space. The amount of objects can be changed by typing it in the field labeled with 50.
SourceCode: QuadTreeSource

This movie requires Flash Player 9

31Okt/092

QuadTrees Implementierung für AS3, v0.1

Die erste Version der QuadTrees für AS3 läuft soweit. Objekte werden schon mal eingefügt, und der Tree selbst graphisch dargestellt. Beim Klick auf ein Quad werden alle zugehörigen Objekte markiert.
Grundlage für die nächste Version, Nearest Neighbour und Collision Detection.

QuadTrees v0.1