Talk:How to create an image reflection effect in Java ME
This article demonstrates how to implement a cool image reflection in Java ME. The method described is fairly easy to implement and should be easy to implement for even fairly novice Java ME developers. The basic approach consists of:
- Create a new image (image + reflection) the same width as the original and allowing additional height for the reflections
- Get the graphics object for that image using the getGraphics() method
- Fill the image with the background color of the canvas
- Copy the original image to the new image
- Get the red/green/blue array for the original image, line by line, using the getRGB() method.
- Copy the image line by line, adjusting the transparency as required to create the reflection effect.
The article demonstrates a simple, yet effective way of making Java ME applications look more graphically appealing.
Article is a great how to. It shows well explained code that creates reflection for given image. Quite useful if you want to add some interesting and nice looking effects to yours app graphics. It could be used for user's avatar for example.
I think that references to related articles on the web would be useful. For example excerpt from a book Filthy Rich Clients - http://www.informit.com/articles/article.aspx?p=1013851&rll=1&rll=1&rll=1&rll=1&rll=1 It is about Java SE, but it shows the possibilities of image manipulation and effects in Java through shifting RGB values.
Well written, well focused, good how to.