blob: 928245d1f2a29be317fc44901ac1bf7fb83c3b14 [file] [log] [blame]
Introduction
------------
This file contains information about Wine's implementation of
Direct3D.
The current version requires :
* Mesa (tested with version 3.1 beta)
* a display in 16bpp
To minimize the impact on DirectDraw (i.e. to reuse most of the code
already done for DirectDraw), I decided not to start with an
implementation based on GLX, but on OSMesa. This way, all the OpenGL
rendering are done in a 'private' memory buffer, buffer that will
copied back to the DirectDraw Surface each time a 3D scene
finishes. It is not optimal for execution speed (on each frame, the
OpenGL buffer is converted from 32 to 16 bpp and copied onto the
screen) but is for development (I had almost nothing to change in
DirectDraw). Moreover, 99 % of the code in the Direct3D implementation
is 'device independant' (i.e. GLX / OSMesa / whatever), so that
changing to GLX will have only a minor impact on Direct3D's code.
Where to find Mesa :
--------------------
The home of Mesa should soon be http://www.mesa3d.org/
But for now, check http://www.ssec.wisc.edu/~brianp/Mesa.html
For precompiled RPMs, use AltaVista or FTPSearch, but I prefer to 'Use
the Source' :-)
WARNING : if you experience crashes in D3DTexture2_Load, see file
d3dtexture.c for a 'cure'. You could also patch your version of Mesa
or wait for version 3.2b (that should have the bug corrected).
Code structure
--------------
TODO (well, once the code will be put in the dll/ddraw directory)
Status
------
Some programs with which I tested the code :
* BOIDS.EXE (DX5.0) : works great. Only thing missing is the
texturing and transparency on the spinning gobes. Lighting seems to
be a bit different than the Real One.
* TWIST.EXE (DX3.0) : vertex transformation works as it
should. Texturing and lighting still off.
* Tomb Raider II (DX5.0) : works perfectly (but slowly). All the
calls needed to make TR2 work have been written.
* Jedi Knight (DX3.0) : does not start
* Shadow of the Empire demo (DX3.0) : displays a mangled intro screen
(only blue squares on the screen)
* Forsaken Demo : starts to work. Texturing is missing and it is
really really slow.
* Grim Fandango (DX ?, seems to be 3.0 !!) : does not start.
TODO
----
* work on optimizing Execute Buffers (i.e. Direct3D 3.0)
* real GLX implementation (will need a complete rewrite of DirectDraw
also) to have 3DFx support
* restructuration of all the DDRAW.DLL (put that in the dll
directory, better separation of 'drivers, ...)
* start looking into DirectX 6.0
* inquire on Mesa / XFree86 mailing lists about direct access to
display hardware (for games such as Tomb Raider II that displays
vertices that are already in screen coordinates)
* look into thread safeness...
--
Lionel Ulmer - ulmer@directprovider.net
Last updated : Tue Jan 19 1999