I am designing a web application that does server side image processing in real time. Processing tasks include applying different effects like grayscale, blur, oil paint, pencil sketch etc on images in various formats. I want to build it using java/servlets which I am already familiar with. I found 3 options,
1) Use pure java imaging libraries like java.awt or http://www.jhlabs.com/ip/index.html 2) Use command line tools like Gimp/ImageMagick 3) Use c,c++ image libraries that have java bindings.
I don't know which of the above options is good keeping the performance in mind. It looks like option 2) and 3) are good performance wise, but I want to be sure before I rule out 1). I have also heard gimp cannot be run using command line unless gtk or xwindows is already installed on the server. Will there be any such problems with 2) or 3) while running them server side?
Also please suggest any good image processing libraries for this purpose.
Imagemagick or graphicsmagick are pretty good, you can find wrappers for them in most languages.
There are quite a few online examples and tutorials for image manipulation using these libraries too
I think the best thing to do is try option 1), and if it is not fast enough, try option 2). I am doing server-side image processing in some of my applications and I have found the performances to be quiet good.
I wont be having my own servers. I will have to go with a hosting provider. This makes it a bit complicated when it comes to installing softwares that might require root permissions.
I deployed java servlet on a hosted environment using jhlabs library for simple image processing operations like gray scaling and observed 2 things
Java would have similar problems in a headless environment were Using Headless Mode in the Java SE Platform not available.
I am developing a web applicaton for online image creation and processing, called rastaq (first preview on http://rq-online.deesceha.de). It is a Java Web Application and all graphics are based on Java 2D. It is extensible by new Operators and Types. Play around and see, how long it takes to recompute an image with new parameters.
The hardware platform is an Intel Quad-Core, 8GB RAM machine.