Xah Lee, 2006-12-20
LiveGraphics3D is a Java Applet that reads a text file of Mathematica graphics and allows the user to view and rotate it dynamically in a web browser. This page is a short tutorial on how to use set up LiveGraphics3D to view Mathematica graphics.
First, LiveGraphics3D is written by Martin Kraus in around 1995. It's home page is at LiveGraphics3D ↗. It is free for non-commercial use, and its home page has complete documentation. This page will be a quick outline on setting it up for experienced programers.
First, you need to download the live.jar file at the LiveGraphics3D website. live.jar is the engine that does the live rotation.
Then, you need a file of Mathematica graphics. Suppose this is your graphics file: mathematica_graphics.m. (if you are not familiar with Mathematica graphics see: Introduction To Mathematica's 3D Graphics Format. )
Now, create a file lg3d-test.html with the following content:
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"> <html> <head> <title>LiveGraphics3D Test</title> </head> <body> <APPLET ARCHIVE="live.jar" CODE="Live.class" WIDTH="650" HEIGHT="650"> <PARAM NAME="INPUT_FILE" VALUE="mathematica_graphics.m"> </APPLET> </body> </html>
Now, you are all done. Open the lg3d-test.html file with a web browser, and you should see your graphics in live rotation.
Often, a Mathematica graphic contains thousands of polygons, resulting a large file. LiveGraphics3D also support reading in a zip compressed file, by using the INPUT_ARCHIVE applet parameter, like this:
<PARAM NAME="INPUT_ARCHIVE" VALUE="mathematica_graphics.m.zip">
Note that, the INPUT_FILE parameter still needs to be present. Its value should be the file name inside the zip archive.
See also:
Page created: 2006-12. © 2006 by Xah Lee.