import java.awt.*;
import java.applet.*;
public class FishImage extends Applet
{
public void init()
{
setBackground(Color.black);
}
public void paint(Graphics g)
{
/* First, you must have an image (e.g. jpeg or gif)
in the same folder as your class. */
Image fishPicture = getImage(getDocumentBase(),"fish.gif");
/* Second, you use the draw image method.
first argument is the name of the jpeg
next two are the coordinates
the last is the imageobserver, you will usually put "this" */
g.drawImage(fishPicture, 50, 50, this);
}
}