| Author |
image manipulation
|
Dieter Merlin
Greenhorn
Joined: Oct 25, 2005
Posts: 9
|
|
Hi, I have some code to create thumbnails of pictures anddisplay them on a site. The problem is that we run into an outofmemoryerror every 2 weeks or so. (heap size = 512mb) The average picture size is +- 1 MB Here is the current code; I know that the ImageIcon(byte[] data).getImage() holds a reference to the data but using Toolkit.createImage fails to work (black image) and using ImageIO.read() doesnt help with the OOM either. Avoiding the BAOS and writing the thumb directly to the ServletOutputStream causes 100% cpu usage and prevents the picture to be loaded. I'm a little desperate on this since I cant find anything usefull that would help. Thanks in advance
|
 |
Bear Bibeault
Author and ninkuma
Marshal
Joined: Jan 10, 2002
Posts: 56531
|
|
|
As the servlet API has no means of image manipulation, this has been moved to the AWT forum.
|
[Smart Questions] [JSP FAQ] [Books by Bear] [Bear's FrontMan] [About Bear]
|
 |
Dieter Merlin
Greenhorn
Joined: Oct 25, 2005
Posts: 9
|
|
|
sorry, its just because we do it from a servlet in a jboss container that I thought it should be there, that it could have a meaning to it
|
 |
 |
|
|
subject: image manipulation
|
|
|