All posts tagged array


Benchmarks: Dictionary vs. Object vs. Array vs. LookupList

[Update: I put the code of the LookupList class at the bottom of the article] [BIG Update: there was an error in the LookupList class -> now it’s much slower than the rest] And another benchmark comparing various ways of getting an object for a key that is stored in a table. The key is […]

Filters Manager in AS3 (BitmapEffects Manager) or how to add, remove and modify a filter from a DisplayObject

First of all, to understand the need of a centralized manager for filters in flash, we need to understand how filters are set on a DisplayObject. To set a filter, we first need to create a BitmapFilter object : [sourcecode language=’as3′] // create a new blur filter var blur:BlurFilter = new BlurFilter(4.0, 4.0, 1); [/sourcecode] […]

Nice AS3 Performance tester (loops, arrays, division, instantiations, constants, …)

When you look for something, there are always more chances that you don’t find it when you need it. It’s only weeks later, when looking for something else that you step on it. (some unwritten laws that I know most of you have encountered many times) Anyway, here is a great open-source performance tester written […]

AS3 arrays against linked lists performance benchmarking

Let’s have a look at arrays vs. linked lists, and for what use. Here, the assumption is that we need to access a property and/or call a function from a lot of objects in a list at the highest speed possible. Let’s say we are making a game and we want to go through all […]