• Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Reading .gif Images from a file

 
Vanitha Sugumaran
Ranch Hand
Posts: 356
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi,
Can anyone give me idea how to read images from a file. To load the image in a frame we can use ToolKit, but I have to read the image. I read about JAI (Java Advanced Imaging), I am not sure about using it.
Thanks,
Vanitha.
 
Shital Shisode
Greenhorn
Posts: 7
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Foll code is used to load an image from a file.
Image im = getToolkit().getImage("imgFile.gif");
Let me know if you need anything else.
Hope it helps !!

------------------
 
Vanitha Sugumaran
Ranch Hand
Posts: 356
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Thanks for your reply. I have used Toolkit to load the image into the Frame. What I really want to know is how to get the details about the image, like getting the height, width.. of the image.
Vanitha.
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic