Thursday, June 28, 2007

Added a new features to my blog. You can now see daily top ten list along the right side of this blog. You can also express your opinion by voting on the items in the list. If it is a media item, you can also click on the link next to the item to visit the item listing on I hope this feature will add more interactivity to my blog and make things more fun.
Two products from internet innovators that are for limited number of users are the EC2 from Amazon and Google's Mashup editor. Both are radically different products and have nothing in common but that they are for limited trial offers. Amazon EC2 is a business model thought up by Amazon founder Jeff Bezos and relies on making available servers and hardware on a as needed basis. This means that you don't have to pay for computing resources you don't need right now. The exact nature of the program is still not clear as the offer was limited to only 10000 users and was taken up in no time at all. In fact, the story goes that one would-be participant who missed out was ready to offer $20000 for a seat to another who was successful but his offer was turned down. Such was the attraction that the Ec2 program had on the internet community.
Google Mashup editor is a relatively new offering from Google. It is amied at making building mashups easy and should pave the way for better mashups in less time. It isn't appear to be in the same league as EC2 in business terms. Google nevertheless is testing the water before making it available for public consumption. A couple I have tried myself include
1. A wiki based product from IBM alphaworks
2. A great product from openkapow

Would have loved to get my hands on Google's mashup editor though.

Wednesday, June 27, 2007

I had this requirement to pick the pixel color from an image. I usually use a image editor program that I have to select the color. Iam aware that programs like photoshop would do this kind of thing quite easily. But it didn't make sense to start photoshop if it wasn't already running just for this small requirement. As usually the case with free programs, the image editor software started acting strange and would not tell me the color. So I began searching the net for ColorPicker programs. Most of the results were for html websites that allow you to select web safe colors. There was a flash based one which I couldn't use because I didn't have flash installed. Another was a COM based google gadget which I couldn't test because I didn't have google desktop installed. So I went to the usually reliable Java for a solution. Only in this case it didn't prove so reliable after all. I call it usually reliable because there's always some java code out there that does what you want. A small example would be when I had to capture a screenshot and the print screen function was not working. A java code I found on the net did just what I wanted. I was hoping for something similar to happen with the color picker as well. But no luck. To select a color from an image, you would have to be able to manipulate the image at the pixel level. Java 2D allowed you to do that. But life is never simple, is it? I was working with a jpg file and to obtain a BufferedImage from a jpg file, you need a jpeg decoder. The sample code said that this could be done using something like below:

InputStream in = ClipImage.class.getResourceAsStream(imgFile);
JPEGImageDecoder decoder = JPEGDecoder.createJPEGDecoder(in);
final BufferedImage bufferedImage = decoder.decodeAsBufferedImage();

Only the jai-imageio project which contained JPEGImageDecoder did not have any JPEGDecoder in it. So it was back to search for JPEGDecoder and there were very few hits. The GNU classpath project had a JPEGDecoder and after getting all the files, it became evident that it wasn't quite the same as the decoder I wanted. The documentation was also scarce and by then I was able to get the color I wanted by running the image editor on my laptop.

Moral of the story: Don't go on a wild goose chase

Tuesday, June 05, 2007

This year's javaone a 'damp squib'? It sure does appear like it. Considering all the hype that was generated before the conference, this years' javaone definitely was pretty ordinary compared to previous years conferences. After thge keynotes and the announcement about JavaFX, it was as if they all had into a deep slumber only to wake up once the conference was over. Or maybe a Maoist regime had taken over the moscone center and imposed a blanket ban on any news getting out. Whatever be the reason, if the powers behind javaone think that 1 solitary announcement maketh a conference, they better think again. With the likes of Microsoft and Adobe coming out with new platforms for computing, java would have to buck up and get going if it does not want to get left behind.