原来这一贴有50分:)VolatileImage offScreenImage;    GraphicsEnvironment ge = GraphicsEnvironment.getLocalGraphicsEnvironment();
    GraphicsDevice gd = ge.getDefaultScreenDevice();
    GraphicsConfiguration gc = gd.getDefaultConfiguration();    offScreenImage = gc.createCompatibleVolatileImage(imageWidth, imageHeight); //创建图像缓冲
    offScreenGraphics = offScreenImage.createGraphics(); //取得缓冲的graphics对象