• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

Images

 
Greenhorn
Posts: 1
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Does nyOne know how to copy images from one location to another using the new NIO package,at the same time changing its size and filetype like gif,jpg or jpeg??
 
Wanderer
Posts: 18671
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Well, java.nio can help you copy things very efficiently. However if you want to interpret image data, that's something else altogether, and you probably can't (yet) benefit from the new java.nio classes for this. You should probably check out the new Java Image I/O package.
What exactly do you want to do? When you say "changing its size", do you mean the file size, or the display size? Either way, this will have little to do with java.nio - editing image data to derive a new image representation is much more complex than simply reading and writing data. Similarly, what do you mean about changing jpg to gif? Do you really want to transform a gif file into a jpg, or vice versa? Why? What benefit do you hope to get from this?
 
reply
    Bookmark Topic Watch Topic
  • New Topic