1 /*
2 * jcurl java curling software framework https://JCurl.mro.name
3 * Copyright (C) 2005-2009 M. Rohrmoser
4 *
5 * This program is free software; you can redistribute it and/or modify it
6 * under the terms of the GNU General Public License as published by the
7 * Free Software Foundation; either version 2 of the License, or (at your
8 * option) any later version.
9 *
10 * This program is distributed in the hope that it will be useful, but
11 * WITHOUT ANY WARRANTY; without even the implied warranty of
12 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General
13 * Public License for more details.
14 *
15 * You should have received a copy of the GNU General Public License along
16 * with this program; if not, write to the Free Software Foundation, Inc.,
17 * 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
18 */
19 package org.jcurl.demo.util;
20
21 import java.awt.Graphics;
22 import java.awt.image.BufferedImage;
23 import java.io.File;
24 import java.io.IOException;
25
26 import javax.imageio.ImageIO;
27
28 import org.jcurl.core.api.RockSetUtils;
29 import org.jcurl.core.helpers.NotImplementedYetException;
30 import org.jcurl.core.ui.Zoomer;
31
32 /**
33 * @author <a href="mailto:JCurl@mro.name">M. Rohrmoser </a>
34 * @version $Id:IconGenerator.java 378 2007-01-24 01:18:35Z mrohrmoser $
35 */
36 public class IconGenerator {
37
38 /**
39 * @param loc
40 * @param zoom
41 * @param dst
42 * @throws IOException
43 */
44 public static void savePng(final RockSetUtils loc, final Zoomer zoom,
45 final File dst) throws IOException {
46 // Create image and graphics.
47 final BufferedImage img = new BufferedImage(1024, 768,
48 BufferedImage.TYPE_INT_ARGB);
49 final Graphics g = img.getGraphics();
50 // FIXME !!!
51 // final PositionDisplay jp = new PositionDisplay();
52 // jp.setPos(loc);
53 // jp.setZoom(zoom);
54 // jp.setSize(img.getWidth(), img.getHeight());
55 // jp.paint(g);
56 g.dispose();
57 ImageIO.write(img, "png", dst);
58 throw new NotImplementedYetException();
59 }
60 }