A Python binding to the 3DFX Glide libraries.
Information
PyGlide is a Python binding for the Glide rasterization library, the low-level
interface to the 3DFX Voodoo series of cards.
What's it for?
The Glide rasterization library provides a very low-level direct link to
the capabilities of your Voodoo graphics card. It is much smaller than
Direct-X, but is specific to one type of hardware, and leaves you to provide
a lot of the functionality of a 3d library (for example, there are no matrix
or 3d functions, clipping, etc.)
This library could be useful to:
-
People learning how to use the Glide library,
-
People who want powerful graphics capabilities on Voodoo-based hardware,
with the advantage of the high level of the Python language.
-
People who just want to experiment with graphics in Python, and use the
transparency and special effects that Glide provides.
Distribution
PyGlide is completely free, for any kind of use, but I disclaim all responsibility
for anything bad that happens, ever.
Requirements
Python 1.4 or 1.5 (including PythonWin)
for Windows 95/98/NT
Windows 95/98/NT (tested on Windows 95)
A Voodoo Graphics, Voodoo 2 or Voodoo Rush graphics card.
A Glide 3 driver for the above card. (Tested on the 3DFX Glide3.0 reference
driver, using an Orchid Righteous 3D Voodoo card)
A Linux version is planned for development, as soon as I have time.
Version Info
This is version 0.1 beta 1, the first public release of PyGlide.
To Do
-
Fix any bugs found
-
Add the Glide utility functions (gu prefix)
-
Consider adding some other utility functions (input devices, 3d to 2d calculation,
sound etc.) that Glide does not provide
-
Write some more demos
Documentation
Function signatures are mostly similar to those for the C Glide bindings,
but with a few changes. See the online documentation,
or download it with the archive below.
Installation
Installing the PyGlide libraries
You need to have installed Python 1.5 for Windows.
Put the glide.py file in your Python's Lib directory.
Put the pyglide.dll file in the same directory as the python.exe
executable.
You can run the skybox demo by double-clicking the skybox.py Python
script.
Press Control-C to stop the demo.
To check the Python library has installed, type into the Python interactive
prompt
import glide
Test it by typing
glide.grGlideInit()
glide.grSstSelect(0)
glide.grGetString(glide.GR_VENDOR)
glide.grGetString(glide.GR_VERSION)
The third line should print out the vendor of the Glide library, and
the fourth line should print out the version of the Glide library you are
currently using.
Once the Glide library is running, a program should always shut down
the library before exiting. To do this, make sure you run pyglide.grShutdown()
before quitting.
To make sure this happens, even if an error occurs, use a try...finally
block in your code:
import glide
try:
<glide code here >
finally:
glide.grShutdown()
WARNING! Some functions in the Glide library can cause your computer
to hang if you don't know what you are doing. Especially make sure everything
you draw is inside the screen area. Be careful when using the interactive
prompt. If you have only one monitor for both normal and Glide displays,
then once you open the Glide display with grSstWinOpen you will
no longer be able to see the Python console.
E-Mail
Send any questions, bug reports or comments about PyGlide to:
graham.clemo at bigfoot.com
(The above mailto: hyperlink requires Javascript to work, to stop
automatic web page scanners from getting my e-mail address. If you don't
have Javascript, you'll have to type it in, with @ instead of at.)
Relevant Links
3DFX for information on Voodoo graphics
cards and the Glide library.
Python is a powerful interpreted
Object-Oriented language.
Open-GL is a high-level platform-independent
3D graphics library, also with a Python language binding.
Acknowledgements
3DFX, Glide, Voodoo Graphics, Voodoo Rush and Voodoo2 are trademarks
of 3DFX Interactive, Inc.
Microsoft, ActiveMovie, Direct3D, DirectDraw, DirectInput, DirectPlay,
DirectSound, DirectX, MS-DOS, Win32, Windows, Windows 95 and Windows NT
are either registered trademarks or trademarks of Microsoft Corporation
in the United States and/or other countries.
Open-GL is a registered trademark of Silicon Graphics, Inc..
Graham Clemo