"Wisdom of Earthquakes" Released at TechCrunch Disrupt Hackathon SF 2011

I'm attending the TechCrunch Disrupt SF 2011 held in San Francisco. Prior to the conference, I've hacked here at the huge hackathon filled with more than 700 hackers. It's a really exciting experience. I started hacking the "Wisdom of Earthquakes" web application and released it at the hackathon.

photo

The hackathon started at Saturday noon and ended at the Sunday noon. Each team of hackers must finish their hack in 24 hours.

photo

I've also posted articles about the event and food for hackers on my Japanese blogs in detail. TechCrunch's official report is here.


Wisdom of Earthquakes

After the lunch, the time has came for me to give a talk about my hack on the stage.

photo

I've hacked "Wisdom of Earthquakes" which is a web application with a calendar and a map to tell the wisdom we can learn from earthquakes.

This calendar shows 500+ memorial days of earthquakes hit in the history of the globe. The oldest one listed is the 62 Pompeii earthquake in Italy. We could see almost every day on the calendar has had one or more earthquakes. The wisdom helps us do something to survive at the next coming disaster.


The app is shipped as an open source at:
http://code.google.com/p/memorial-calendars/wiki/tcdisrupt

iPad 2 JavaScript Benchmark Results 37% Faster Than iPad 1

SunSpider JavaScript Benchmark marks 37% faster score on iPad 2 / iOS 4.3.1 / Mobile Safari 5.0 compared to iPad 1st gen.



Also note that iPad 1 could get significant peformance improvement by updating iOS from 4.2.1 to 4.3.1. This means Mobile Safari 5.0's "Nitro" Engine enabled on iOS 4.3 runs JavaScript quite fast.

Benchmark results captured are below:

iPad 2 - 4.3.1 and 4.3


iPad 1 - 4.3.1 and 4.2.1


PS.
My Mac results 344ms on Chrome and 360ms on Safari.
iPads are still nothing compared to Mac. :-<

* Japanese version of this post is here.

KDrawSprite: Get GPU power without cacheAsBitmapMatrix on AIR for iOS

KDrawSprite is an ActionScript library for mobile AIR applications using Packager for iPhone, AIR for iOS and AIR for Android to get more power of GPU. My iPhone app Korean Alphabet 1.2.2 is using this to get more than 30 fps on older devices, ex. iPod Touch 1st gen. A4 chip powered latest devices, such as iPad and iPhone 4, will performs 100 fps over with KDrawSprite.

Source on github:
https://github.com/kawanet/as3kawalib/raw/master/src/net/kawa/display/KDrawSprite.as
Document:
http://www.kawa.net/works/as/as3kawalib/docs/net/kawa/display/KDrawSprite.html


KDrawSprite draws your vector image onto a bitmap image. You don't need to manipulate cacheAsBitmapMatrix and cacheAsBitmap properties. These are powerful, however, sometimes make our app crashed erratically. You need take more care for iPad which has larger screen but has less memory.

How To Use This

Simply call KDrawSprite.getSprite() instead of setting cacheAsBitmapMatrix and cacheAsBitmap properties.
var sprite:Sprite = new Sprite();
sprite.graphics.beginFill(0x336699);
sprite.graphics.drawCircle(50, 50, 50);

// sprite.cacheAsBitmapMatrix = new Matrix(); // BEFORE
// sprite.cacheAsBitmap = true;


sprite = KDrawSprite.getSprite(sprite);       // AFTER

addChild(sprite);
sprite.x = 100;
sprite.y = 100;
sprite.scaleX = 0.5;
sprite.height = 50;
sprite.rotation = 1;
Bitmap operations such as moving, scaling and rotation will be GPU enabled.
KDrawSprite will also free memory of image rendered when it comes out of the Stage.

You need call getSprite() or draw() method whenever you make changes on the vector source image. This also means any other needless re-rendering will not be invoked. Learn more on document.

Super Sampling Anti-Aliasing (2x SSAA)

KDrawSprite supports 2x SSAA, super sampling anti-aliasing, in addition to NoAA per default.

Note

To get better performance and rendering quality, you MUST set stage.quality as StageQuality.LOW. Also use 2x SSAA when needed.
stage.quality = StageQuality.LOW; // must

* Japanese version of this post is here.