hi,
i am kind of desperately trying to get paint2D, or rather the paint() method to work.
drawing strings or shapes works, but not images.
i fetch a byte[] from elsewhere, representing a tiff image.
but
byte[] bi=fetchData();//the image data
Image img = new ImageIcon(bi).getImage().getScaledInstance(200, 200, Image.SCALE_FAST);
g2d.drawImage(img, g2d.getTransform(), null);
does not draw a thing.
i suspect setting the ImageObserver to null is to blame -- but on the other hand: what is the ImageObserver here?
it turned out, the data i got was from a tiff image -- whixh format ImageIO does not handle -- one of those mysterious shortcomings of java's file format handling i constantly keep to forget ...