From: <ma...@us...> - 2003-06-12 18:36:43
|
Update of /cvsroot/jrman/drafts/src/org/jrman/parser In directory sc8-pr-cvs1:/tmp/cvs-serv2346/src/org/jrman/parser Modified Files: Parser.java Log Message: Implemented mipmapped textures. Index: Parser.java =================================================================== RCS file: /cvsroot/jrman/drafts/src/org/jrman/parser/Parser.java,v retrieving revision 1.51 retrieving revision 1.52 diff -C2 -d -r1.51 -r1.52 *** Parser.java 3 Jun 2003 05:19:08 -0000 1.51 --- Parser.java 12 Jun 2003 18:36:09 -0000 1.52 *************** *** 21,24 **** --- 21,25 ---- import java.io.FileInputStream; + import java.io.IOException; import java.io.InputStreamReader; import java.io.StreamTokenizer; *************** *** 50,53 **** --- 51,55 ---- import org.jrman.geom.PerspectiveTransform; import org.jrman.geom.Transform; + import org.jrman.maps.MipMap; import org.jrman.options.CameraProjection; import org.jrman.options.Display; *************** *** 171,174 **** --- 173,177 ---- } catch (Exception pe) { System.err.println("Error: " + pe); + pe.printStackTrace(); } } *************** *** 1087,1089 **** --- 1090,1112 ---- } + + public void makeTexture( + String picturename, + String texturename, + String swrap, + String twrap, + String filter, + int swidth, + int twidth) { + try { + MipMap.makeMipMap( + picturename, + texturename, + MipMap.Mode.getNamed(swrap), + MipMap.Mode.getNamed(twrap)); + } catch (IOException e) { + throw new IllegalArgumentException("Can't create texture: " + picturename); + } + } + } |