Win a copy of Cross-Platform Desktop Applications: Using Node, Electron, and NW.js this week in the JavaScript forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic

JAI blurry images  RSS feed

Tom Sullivan
Ranch Hand
Posts: 72
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
For anyone who knows JAI, could you help me out?

I have built a system that converts TIFF images to PNG or JPEG then outputs a byte[] of the images for loading in Flash. The TIFF images are too big though so when I sharpen them, I get an out of memory error. I have to scale them first. After I scale them, I have a series of sharpen matrixes that can be applied to the new image so that you can view it in Flash without distortion. Without sharpening, the images look terrible. But with sharpening, I get blurry (unreadable) text which I think is due to the scale. Below is an example of how I sharpen and scale. Anyone have any ideas on why these images would come out blurry?

If instead of subsamplebinarytogray, I just use "scale" I get a washed out image. If I try to sharpen without scaling, I get outofmemory. If I scale with subsamplebinarytogray, I get a blury image that's not sharpened. If I scale with subsamplebinarytogray and sharpen, I get a sharp blurry image. Any ideas? Original image size is 1728 X 2159.

I get the same problem whether I convert to JPEG or PNG.
[ July 10, 2006: Message edited by: Tom Sullivan ]
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!