-
January 23, 2009
America, fuck yeah!
GeneralJust saw this stunning page by photographer Phillip Toledano. What me really struck was the fact that this combination of kitch with ghastly images of Guantanamo is not very far fetched. During our trip to San Francisco last year we visited the Alcatraz gift shop, have a look at what I found:
“Alcatraz swim team” -toddler-wear? Oh, come on!
-
January 13, 2009
Photoshopped!
Culture
This one made me laugh hard. An advertisement displaying Britney Spears, Leona Lewis and Christina Aguilera in the Berlin subway was masterfully “busted” by street artists Epoxy, Baveux and Mr Talion (links lead to their Flickr accounts). Have a look at Epoxy’s gallery to see various photos of the adbust.
Anyone familiar with a little photo-editing in Photoshop will appreciate the great details: the history palette attest extensive use of the clone tool (aka swiss knife of retouching) and the layer palette looks exactly like during a elaborate digital make-over (note the layer named “Nose -20%”).
-
January 12, 2009
AS3: What were they thinking?
CodeI had to use as3 extensively in the last days and I am amazed by its mixture of great improvements (over as2, that is) and extremely bad design choices. One of the new “features” is that blocks (everything inside “{}”) do not have their own scope (except function blocks, of course). Which means that the following
for( var i:int = 0; i < 100; ++i ) { // do something... } for( var i:int = 0; i < 20; ++i ) { // do something else... }will issue an “Warning: 3596: Duplicate variable definition”. Great. Instead one is expected to write
for( var i:int = 0; i < 100; ++i ) { // do something... } for( i = 0; i < 20; ++i ) { // do something else... }thus declaring i only once. While I skimmed various blogs and sites for a solution (I was thinking of some kind of compiler-flag to use normal scopes) I found precious advices like this that told me that the above was “good code”… did I miss some kind of paradigm shift? Since when are sloppy scopes “good code”?! While we’re at it, why don’t we dismiss this whole scope-thing and make every variable global? Yeah, sounds like a great idea! And GOTOs! Let’s have them, too!
But seriously, I got badly annoyed when the following situation occured:
for( var i:int = 0; i < someArray.length; ++i ) { var model:A= someArray[i] as A; // do something with model } for( var i:int = 0; i < otherArray.length; ++i ) { var model:B= someArray[i] as B; // do something with model }I like to write “parallel code”, that is: code that does something similar should looks similar. It helps me memorize my code and it appeals to my aesthetic sense (yes, I think code should look nice). But in AS3 it is simply not possible: the variable model has the type A as of the first declaration and cannot be re-declared in the second loop. This forced me to come up with variable names like modelA and modelB (only that A and B are types with real names like SystemView or Markable) — déjà-vu?
The only thing that I could do to minimize the agony was to turn of warnings (File->Publish->Publish Settings->ActionScript3 Settings) and use the above bastardization of hungarian postfixes. Yuck.


