Image stretching

SteveC steve at fractalus.com
Sat Jun 23 06:56:16 PDT 2001


hi,

I've just come across kaffe's smoothing when stretching an image ie 

 public void paint(Graphics g) {
        g.drawImage(img, [some coordinates that stretch the image] );

Whereas I havn't seen another JVM that actually smoothes. I have a couple
of applets that show portions of an off screen image, stretched, instead
of drawing things bigger. This seemed to be faster that redrawing my stuff
scaled. It was also easier. Unfortunately it looks horrible under kaffe.

Specifically a cellular automata applet, when I zoom 2X orginal size, the
pixels become blury grey, instead of still having sharp squares.

I'm not worried, because the people seeing this will be using IE/NS and
MS/suns jvms which don't smoothe at all. Its a pain, because I also have
to use them now. I was just wondering if this is a departure from the
spec, or if the behavior is selectable, is it done for speed etc?

have fun,

SteveC steve at fractalus.com fractalus.com/steve stevecoast at hushmail.com



More information about the kaffe mailing list