Home My Page Projects Code Snippets Project Openings 3D graphics for Standard ML
Summary Activity SCM

SCM Repository

[sml3d] View of /trunk/sml3d/README
ViewVC logotype

View of /trunk/sml3d/README

Parent Directory Parent Directory | Revision Log Revision Log


Revision 383 - (download) (annotate)
Sun Jan 11 16:35:03 2009 UTC (10 years, 7 months ago) by jhr
File size: 4601 byte(s)
  Update ROADMAP
SUMMARY

  A suite of libraries to support real-time 3D programming in SML using OpenGL.

INSTALLATION

  This library requires the MLton SML compiler (mlton.org).  Because of
  a bug in handling of 8-bit signed integers, it does not build using
  the 20070826 release, but will build under the latest version of MLton
  from svn.

  After unpacking, run the configure script and then make.  You can then
  try out some of the example programs.

  The process is a bit more complicated if you are installing sml3d from
  the SVN repository.  See the instructions below for details.

USAGE

  Depending on which components of the SML3D library you are using, you
  will need to pass additional flags and (possibly) additional object files
  to the mlton commmand line.  We have packaged up this behavior in a shell
  script (bin/config-cmd.sh).  Thus, you can invoke mlton as follows

	MLTONFLAGS=`config-sml3d.sh components`

	EXTRAOBJS=`config-sml3d.sh objs components`

	mlton $MLTONFLAGS project.mlb $EXTRAOBJS

  where "project.mlb" is your project's MLB file.  Note that we use the
  config-sml3d.sh command twice: once to generate the command-line options
  and once to get the list of extra object files.  The "components" argument
  to the script specifies which components your project is using.  The values
  are:

	no-opengl	Do not use OpenGL support (incompatable with glut
			option)
	glut		Use the GLUT library
	sdl		Use SDL (incompatable with GLUT).
	sdl-ttf		Use the SDL True-type font library (implies sdl
			option).
	sdl-image	Use the SDL True-type font library (implies sdl
			option)
	sdl-mixer	Use the SDL audio mixer library (implies sdl
			option)
	openal		Use the OpenAL library (incompatable with sdl-mixer)
	devil		Use the DevIL image library

  If you use GNU make to build your project, you may want to include the
  mk/config.gmk file in your makefile.  Define the SML3D_CONFIG_OPTIONS make
  variable to the components that you are using and use the MLTON_FLAGS
  variable as an argument to the mlton command.


WINDOWS

  The sml3d library has been ported to work on Windows XP and Windows
  Vista using the MinGW/MSys installation that comes with the MLton
  MSI files (http://mlton.org/Experimental).  When using the GLUT library
  on Windows, you need to make sure that Windows can find the GLUT DLL.
  If your sml3d tree is in

	c:\Users\yourlogin\sml3d

  then add

	c:\Users\yourlogin\sml3d\windows\bin

  to your PATH variable.


DEPENDENCIES

  The SML3d library assumes that your system has OpenGL 2.1 available.
  It can be configured to use other libraries:

	GLUT		Available with most OpenGL systems.  An alternative
			is available from http://freeglut.sourceforge.net.
			For Windows systems (using MinGW), we have included
			GLUT support in the SML3d distribution.
	SDL		http://www.libsdl.org
	SDL_image	http://www.libsdl.org/projects/SDL_image
	SDL_ttf		http://www.libsdl.org/projects/SDL_ttf
	SDL_mixer	http://www.libsdl.org/projects/SDL_mixer
	OpenAL		http://openal.org
	DevIL		http://openil.sourceforge.net

ROADMAP

	doc/
	src/
	  base/
	    common	- SML code for vectors, matrices, etc.
	    opengl	- SML interfaces to the GL and GLU libraries
	    util	- various utility modules
	  devil		- support for image I/O based on DevIL
	  glut		- SML interface to the GLUT library
	  gui		- A simple, GLUT-based, GUI library
	  image		- basic image support
	  loaders	- loaders for some 3D file formats
	  openal	- SML interfaces to OpenAL
	  particles	- A library for particle effects.
	  sdl		- SML interfaces to SDL and related libraries
	  tests		- test programs
	examples/	- some example programs
	gen/		- code to generate the FFI glue code for OpenGL.
	windows/	- extra support files for Windows systems (requires
			  MinGW)

BUILDING FROM SVN

  If you have downloaded the sml3d sources from svn, then you need a few
  extra steps to build the system.

	1) generating glue code.  The FFI glue code is generated from
	   a XML description.  To build the glue code, you will need a
	   recent version of SML/NJ (110.68+).  Then execute the following
	   steps.

		% cd gen
		% sml
		- CM.make "sources.cm";
		- Gen.default ();

	2) The next step is to generate the configure file.  From the
	   sml3d directory,

		% autoconf -Iconfig

	3) follow the INSTALLATION instructions from above.


TODO
	image loaders (ppm, pgm, png, jpeg)
	model loaders (obj and mtl files)
	SDL

This software is Copyright (c) 2008 John Reppy (All rights reserved).  It is
distributed under the GNU GENERAL PUBLIC LICENSE (Version 2).  See the COPYING
file for details.

root@smlnj-gforge.cs.uchicago.edu
ViewVC Help
Powered by ViewVC 1.0.0