Wednesday, April 23, 2008

To Mr. Jonathan Schwartz: Please make JavaFX work on plain CLDC

This entry is half an open-letter and half a rant-blog so if I run with it a bit too far, please bear with me.

Last year Sun introduces JavaFX as a rich multimedia platform for Java (Applet 2.0 ?) , at that time I was busy finding a way to run Flash animations on as many mobile phones as possible. Yes I know about Flashlite but the support of Flashlite are not that extensivise, especially if you include low end / old phones that only support MIDP 2.0. I was jumping up and down when they showed how rich multimedia app can actually run "unharmed" on a phone.

To my dismay, I found out later on that JavaFX only works on CDC (read high-end, almost PDA type phones) and totally ignore CLDC - Ok, that's not really true, they do plan cover CLDC (some time in the future?) but the CLDC phone's JVM must support SVG. (OK that's a whole bunch of acronymes but in short, JavaFX only supports the latest greatest phones).

To add salt to injury, I heard (ok this is only rumours - but it still hurts) that Sun is coming up with a design tool much like Abode Flash to help designers use JavaFX.

Now here's a news for Sun, designers don't use Java or JavaFX or any tool related to them. Designers are trained in schools to use Flash and AI and Photoshop. Heck, even Microsoft had a hard time dethroning Adobe as a design tool company. JavaFX only covers high-end newest-latest phones that already has Flashlite runtime: Why do I as a designer wants to create a JavaFX content when I can just run my swf (read flash) files unchanged on these latest phones?

So, here are a few things I think Sun should do instead:

1) Create a CLDC JavaFX runtime but do not insist on any extra JSR/MSA or whatever. Now how do I know that this is doable? Well because tons of rich multimedia games are already created on plain CLDC phones. Couldn't Sun just leverage the game APIs to create a JavaFX runtime? These APIs are already tried and true stuff and have been shown to be flexible enough to run the most complexe of games: let alone JavaFX content.

2) If Sun is itching to create a designer tool then please do so, but please please create an SWF to JavaFX translator. There are tons of Flash based content out there and IF this SWF to JavaFX tool comes along AND these content can run on any CLDC phone THEN JavaFX will make a killing.

Now, some might say, "hey Azrul, Sun is a server company, why the heck would they want to invest fulfilling your little wet dream". Let me answer that with a story of Sara. Sara is a designer living in Kuala Lumpur, Malaysia. She designs content for mobile phones. With the current technology, Sara could create around 4-5 contents per week (enough to pay her rent and to put food on the table). She uses Flash because that is the tool they taught her in designer school and Flash is flexible enough for her to create really cool stuff. But she has a huge problem: most phones does not support Flashlite. She saved some money and buy a software that converts Flash's swf files to 3gp files (mobile video) and send these 3gp files through MMS to her clients. Unfortunately, her MMS provider informed her that Telco's only supports MMS up to 100kb only. She knows about an alternative to MMS which is WAP push, but Sara allows her clients to include their own text in her content and MMS is the only way to do that right now. Because of this limitation on the size of the files, Sara needs to be extra careful on things like, the number of colors she uses and cool stuff like gradients are next to impossible to do.

Now, Mr. Schwartz, CEO of Sun, after reading a blog by some unknown guy, decided to make JavaFX runtime as standard compliant as possible (read independent of any optional JSR or MSA etc.) by leveraging MIDP's game API. Furthermore, Sun has also created an swf to JavaFX converter. Sara was thrilled when she found out that she can now create Flash content, convert it to JavaFx and run it on almost any phone out there. Her programmer boyfriend told her that JavaFX is based on JavaFX script (i.e. text based ) and therefore can be modified easily. He created for her a software to allow her clients to customise her content on the fly. She was very happy, now that customization can be done on the content itself, she doesn't need to use MMS anymore. Her MMS provider also supports WAP push and she can easily move from one delivery mechanism to another. As a bonus, WAP Push is inherently international. So now Sara can sell her content to Singapore, Philippines and the rest of the world.

What really makes Sara a happy girl is that she can now concentrate on being creative instead of having to count how many colors she is using in her content. Instead of creating 4-5 contents per week, she's now creating tens of them. She even hired a few interns to help her out. Together they create a few hundred contents per month.

One fine day she got a call from her server provider saying that her server just couldn't take the load anymore: too many people are downloading her content, then she remembers Mr. Schwartz's company, Sun Microsystem. They make powerful servers with gazilion of cores embedded inside. (Her programmer boyfriend, who is now her fiancee, just couldn't stop talking about how good those servers are). She call her server provider and ask them if they can use a Sun server instead. They inform her that Sun servers are a bit expensive but she has enough money now.

So Sara uses Sun server to serve her JavaFX mobile content and all thanks to Mr. Schwartz and all those nice people at Sun who made it all possible.

And Sara lives happily ever after...

So you see, making JavaFX work CLDC phones without any extra baggage and making swf to javafx transition to be as smooth as possible actually pays off... even for Sun Microsystems, the server company.

No comments: