README for OpenGL Support Kit for Delphi 2.0 and 3.0
----------------------------------------------------

This source code is freeware. For licensing details, please refer
to the Licensing section.

=======================================================================

Revision 1.0 of August 25, 1997. Copyright 1997 Alexander Staubo
<alex@powertech.no>.

=======================================================================


Contents
--------

About This Source Code
Installation
How to Use the Units
Licensing
Feedback and Support
Disclaimer


=======================================================================


About This Source Code
----------------------

This is a translation of the "OpenGL for Windows from Silicon
Graphics Inc." (hereafter the OpenGL SDK) header files to
ObjectPascal and Borland Delphi.

The units have been briefly tested with Delphi 3.0 with the
OpenGL SDK installed; it should be compatible with Delphi 2.0x.
Only 32-bit compilation is supported.

The units provide fallback to the Microsoft OpenGL 1.1
implementation for Windows95 and NT. This means that if the SGI
DLLs are not installed, the Microsoft DLLs will be used instead.
It is also possible to initialize the units with a DLL name, if
the application depends on a specific implementation.

This translation is in compliance with the OpenGL SDK license
agreement.

Aside from the dynamic DLL loading code, the source code was in
completeness converted using my header translator program, the
imaginatively-titled Header Translator for Delphi. You should be
able to download a ridiculously early beta version of this
program at <http://home.powertech.no/alex/>.


Installation
------------

1. Copy the source files into a directory, eg. c:\gld.

2. Ensure that OpenGL is installed. You can download the OpenGL
SDK from <http://www.sgi.com>.

3. For any applications that must use the units, add the line

  uses Gl, Glu;

to the program or unit. See the following section for details
about usage.


How to Use the Units
--------------------

Documenting OpenGL is of course waay beyond the scope of this
readme file. In order to use the OpenGL API, however, you need to
ensure that the application calls the auxilary functions
GlInitialize (or GlInitializeFromLibrary) and, if it uses the GLU
API, GluInitialize (or GluInitializeFromLibrary).


The following auxilary functions are available:

GlInitialize: Loads the OpenGL DLL, with additional fallback to
  the Microsoft OpenGL implementation. If the OpenGL DLLs do not
  include the WinGDI extensions (ChoosePixelFormat et al), they
  will be loaded from the Win32 GDI.

GlInitializeFromLibrary: Loads a custom OpenGL DLL, with no
  fallback. Pass the library name as the first parameter.

GlUninitialize: Unloads the OpenGL DLL.

GluInitialize: Load the GLU (OpenGL Utility) DLL, with fallback.

GluInitializeFromLibrary: Loads a custom GLU DLL, with no
  fallback. Pass the library name as the first parameter.

GluUninitialize: Unloads the GLU DLL.


The API will be unloaded upon exit, although you may call these
functions at any point during the program.

NOTE: An exception is raised if there is a problem loading any
DLL. However: In this release, the standard OpenGL function
imports are NOT verified. Thus, if an import is missing from the
DLL, the function will be unavailable but no exception will be
raised; further, attempting to call the missing function will
result in an access violation.


Licensing
---------

This software is released as "freeware". You are encouraged to
redistribute unmodified copies this software, as long as no fee
is charged for the software, directly or indirectly, separately
or as part of ("bundled with") another software product, without
the express permission of the author (Alexander Staubo). Users
are encouraged to improve the source code, and you may modify
this software as long as you do not redistribute the modified
version.


Feedback and Support
--------------------

You are encouraged to send bug reports and suggestions.
Contributors will be rewarded by having their names mentioned in
the "readme" file of every subsequent release. Fame and glory is
optional. If you modify the source code, you are also encouraged
to email me your modified version if you think your additions
would be worthwhile to other users.

This software is not supported. Hence, your technical questions
may or may not be answered. If they're sufficiently intelligent
and well-written, however, there is a good chance they will.

Questions, bug reports, comments and suggestions should all be
sent to <alex@powertech.no>, subject line "OpenGL headers".

While I would be happy to answer questions, my resources are
limited, time is money, and money is in limited supply, please do
not bother me with unrelated questions such as "What is OpenGL?",
unless you can show me a fat wad of dollar bills as well.


Legal Disclaimer
----------------

ANY USE BY YOU OF THE SOFTWARE IS AT YOUR OWN RISK. THE SOFTWARE
IS PROVIDED FOR USE "AS IS" WITHOUT WARRANTY OF ANY KIND. TO THE
MAXIMUM EXTENT PERMITTED BY LAW, THE AUTHOR (ALEXANDER STAUBO)
DISCLAIMS ALL WARRANTIES OF ANY KIND, EITHER EXPRESS OR IMPLIED,
INCLUDING, WITHOUT LIMITATION, IMPLIED WARRANTIES OF
MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
NONINFRINGEMENT. THE AUTHOR (ALEXANDER STAUBO) IS NOT OBLIGATED
TO PROVIDE ANY UPDATES TO THE SOFTWARE.


=======================================================================


