static BufferedImage renderShape(Shape shape, int w, int h) { BufferedImage img = newBufferedImage(w, h, Color.white); Graphics2D g = img.createGraphics(); g.setColor(Color.black); g.fill(shape); ret img; }