|GEF png fails when WebSphere run as a Windows Service [message #485070]
||Thu, 10 September 2009 13:11
Originally posted by: makbulut.us.ibm.com|
We have an SWT-based converter.war file that we deploy on Websphere (and
Tomcat) to convert GEF-based diagrams to PNG or JPG files for a web client.
All works fine, except when Websphere is running as a Windows service.
When we disable running WAS as a service our image conversions work
without issues. However, if we enable running WAS as a service, two
- The images produced appear to be "grainy" and don't look nearly as nice
those produced when NOT running WAS as a service.
- When we attempt to produce "thumbnail" images of our diagrams, the calls
The reason for the "thumbnail" issue is that the following calls:
end up returning 0, when they should instead be returning positive values
they DO do when _not_ running WAS as a service).
More specifically, the code in play is the following:
Image shrunken = new Image(full.getDevice(), size.width, size.height);
GC gc = new GC(shrunken);
0, 0, area / size.width, area / size.height,
0, 0, size.width, size.height);
That last call, gc.drawImage, ends up making the above mentioned calls to
Gdip.Image_GetWidth(img) and Gdip.Image_GetHeight(img).
We've noticed that if we use:
rather than [from above]:
the "thumbnail" conversion WILL work [when running WAS as a service], but
course the thumbnails produced are VERY grainy, so we don't see this as a
Powered by FUDForum
. Page generated in 0.02306 seconds