Home

Documentation

Download:
   Windows
   Macintosh
   Linux

What's new in Visual 5

Recent developments

VPython wiki

Mailing list

Contributed programs

For developers

Python web site

 

Download
for
Linux

crystal

For proper performance, it is important to update the driver for your graphics card, especially if you have a Radeon card. For a desktop machine, go to the web site of the manufacturer of the graphics card. For a laptop, you should normally go to the web site of the laptop manufacturer, though for NVIDIA you may now find a newer driver available from NVIDIA.

First check to see whether VPython is already available as a package for your Linux. For example, there is a "python-visual" package on Ubuntu. (Unfortunately, this package for Ubuntu 9.10 is broken; to make it work you need to install the Boost 1.38 libraries referenced below. The package for Ubuntu 10.04 does work, and you might consider upgrading to 10.04.).

Here is the latest source package for use with Python 2.5 or Python 2.6:

Download and unpack visual-5.32_release.tar.bz2

Study the instructions in INSTALL.txt, which are necessarily quite complicated.
If you are new to Linux, it is strongly advised to use the Linux package manager instead.
Note the special instructions about site-packages on Ubuntu 9.04 and later.

There is a bug in the standard Boost libraries on Ubuntu 9.10, and to build VPython
you must first install Boost 1.38 libraries from https://launchpad.net/~ajmitch/+archive/ppa.
Be sure to read and follow ALL of the instructions; click on everything in sight on that web page.

In support of the 3D text object, you will need to install the font-handling modules FontTools, ttfquery (version 1.0.4 or later), and Polygon (all available from pypi.python.org), for which the following conditions apply: "Polygon is being distributed subject to the following conditions: This distribution contains code from the GPC Library, and/or code resulting from the use of the GPC Library. This usage has been authorized by The University of Manchester, on the understanding that the GPC-related features are used only in the context of this distribution. It is not permitted to extract the GPC code from the distribution as the basis for commercial exploitation, unless a GPC Commercial Use Licence is obtained from The University of Manchester, contact: http://www.cs.man.ac.uk/~toby/gpc/".

After installing VPython, start IDLE (you may have to install it). Assuming your Python is /usr/bin/python,
      1) You can execute python /usr/lib/python2.6/idlelib/idle.pyw.
      2) You may be able simply to execute "idle", depending on your flavor of Linux.
      3) Open an example program in /usr/lib/python2.6/site-packages/visual/examples,
          for example, bounce2.py.
Press F5 to run (or use the Run menu).
Every time you run, your files are automatically saved (if you have changed them).
Documentation is found at /usr/lib/python2.6/site-packages/visual/docs/index.html

The Visual installation creates a shell script for starting up IDLE in the example directory. This shell script is in /usr/bin/vpython, but it doesn't work properly because it's missing a line "prefix=/usr" that must precede the use of {prefix} in the shell script.

RECOMMENDED: An alternative version of IDLE that fixes some problems with the standard IDLE

Materials such as wood

Materials such as wood will work with graphics cards that support Pixel Shader 3.0 ("PS 3.0"). See
http://en.wikipedia.org/wiki/Pixel_shader#Hardware. Some materials may work with graphics cards that support PS 2.0, but other materials may need to be manually disabled; see instructions in the site-settings.py module in the Visual package in your site-packages folder. If the graphics hardware does not support pixel shaders, the material property is ignored. If you think you should be able to use materials but have trouble with their display or performance, we highly recommend upgrading your video card drivers to the latest version.

Other features new in Visual 5, such as transparency and local lights, work with all graphics cards.