Hello everybody. Great to be here! Everyone seems really nice in here and I hope I have nicer time here then other forums I been too hehe Anyway onto my program. I am just a casual Java programmer, sad I know hehe and I havent done anything like this in school or anything but as a keen programmer its fun to try new languages. I was playing around with Java and I thought I would mess about with pictures and images. Now I created a few black and white images in JPEG format. I was hoping to makes a silly little program that would count how many black pixels and how many white pixels but found this to be quite harder then I thought it would be. I heard of using the pixel grabber or something but I dont really know how to get started. Can anyone help me please? Thank you!
These links are part of the Java API documentation. You should familiarize yourself with these docs and learn how to navigate them. They are a great tool to find the methods that you need, or to remind yourself what parameters and return types are used by a particular method that you are already familiar with. Note that the Java API docs are not a tutorial, though. Still, they are handy for reference. If you want tutorials to get you started on particular subjects, Sun (the makers of Java) provide some here. There are also other available online resources, too, but I'll let you google for those.
Search for uses of BufferedImage. Lost of code/examples out there. Used for low-level image manipulation. Might check out VolitileImage as well, as it's newer and makes use of hardware acceleration.
Basanth P Rangadhol
Joined: Nov 22, 2004
yeh.. Layne is wright.. if your not familiar with image classes.. then better to go thru.. also.. in 1.4 there is awhole set of package.. javax.ImageIo.. which has an ImageIO class which takes care of reading and writing image file.. and i have not gone thru the "plugin" classes.. to decompress "*.jpg" files...
still lot more....
Imagination is more important than knowledge - Einstien.