Now that we know you can use
int keys with
Object, it’s time to test whether or not this is any faster than
String keys. Today’s article does just that and also tests
String keys with
Pop quiz: what’s the difference between an
Object and a
Dictionary? If you said “
Dictionary can have non-
String keys”, you bought into a common myth. Today’s article shows the cases where the lowly
Object class will use non-
String keys whether you like it or not. Read on for the details.
I’ve recently been notified of a way to dramatically speed up
for-in loops. I’ve tested this method out and indeed there is a 5x speedup. Employing the technique is also really easy. Unfortunately, the speedup is sometimes an illusion. Read on to learn a little more about
for-in loops and how you could potentially speed yours up by 5x.
Sometimes the old, legacy option is faster than the new one you’re supposed to use. That happens to be the case with XML in Flash:
XMLDocument is quicker than
XML. Today’s article tests its performance to figure out just how much faster it is and if it can keep up with plain
Object and typed
If you deal with XML documents, you probably appreciate AS3′s support for the E4X operators. These make it really easy to access the
XML class like any old object with the
.x (dot) operator as well as XML-specific operators like
..x for descendants and
@x for attributes. Even fancier, there’s support for arbitrary expressions like
.(@id == "123"). With all this convenience we should wonder- how slow are the E4X expressions?
Your computer has RAM, but it also has much faster forms of memory. If you want your app to run quickly, you need to be aware of these other memories. Today’s article discusses them and shows two AS3 examples that, even with such a high level language, you can still take advantage of them.
In almost all circumstances,
Stage3D requires you to provide textures with power-of-two dimensions. This is often inconvenient as most images are not already sized that way. Today’s article provides a simple class to easily build a texture with power-of-two dimensions. An example app is also provided.
AS3 has always had great support for XML built right into the language, but how fast is it? Today’s article compares the performance of operators that work on
XML objects like
["x"] against their equivalents in plain
Object instances and typed
class instances. Just how slow are the XML operators? Read on to find out.