import java.awt.*;import java.io.*;import javax.imageio.*;import javax.swing.*;...class MyPanel extends JPanel{ public MyPanel(){ try { img = ImageIO.read(new File("c:\\image00001x.jpg")); } catch (IOException ex) { ex.printStackTrace(); } } public void paintComponent(final Graphics g){ super.paintComponent(g); g.drawImage(img,0,0,null); } private Image img;}