DXGL

From www.williamfeely.info
Revision as of 20:28, 10 March 2015 by Admin (talk | contribs) (Roadmap)

Jump to: navigation, search
Dxgl.svg


Introduction

DXGL is a project to create a DirectDraw/Direct3D version 1 to 7 implementation that runs on OpenGL 2.x. It is intended to alleviate some of the graphics glitches inherent with using legacy DirectX interfaces on modern video cards. The API will be 100% binary compatible with the system ddraw.dll file.

DXGL is currently in an alpha stage, but several applications and games already work.

System Requirements

  • Windows XP, Vista, 7, 8, 8.1, or 10 (May work under recent builds of Wine)
  • OpenGL 2.0 or higher compatible video card (3.x or higher recommended), with hardware accelerated non-power-of-two size textures
  • Visual C++ 2010 x86 runtime, available at http://www.microsoft.com/en-us/download/details.aspx?id=5555 (will be installed if not present)

Build Requirements

  • Visual Studio 2010 or Visual C++ 2010 Express
  • The following components are optional. The build process will ask for these if they do not exist:
    • TortoiseSVN (to fill in revision on SVN builds)
    • HTML Help Workshop (to build help)
    • NSIS (to build installer, requires TortoiseSVN and HTML Help Workshop to succeed, only 2.46 tested so far)

Build Instructions

Old instrutions; view above video for step by step instructions:
These instructions assume that you do not have any of the required software installed. If you already have any or all of this software installed and set up, skip those steps.

Progress

See DXGL Features for detailed information.

See DXGL Changelog for release information and previous version downloads.

Also see DXGL Test Results.

What works:

  • DirectDraw object creation and destruction (versions 1 to 7)
  • Display mode enumeration and switching (with emulated mode switching)
  • Fullscreen and windowed modes.
  • Basic Blt() functionality
  • 8-bit color emulated with GLSL shader

What partially works:

  • 3D graphics are only partially supported.

What doesn't work:

  • Many functions are stubbed out and return an error

Roadmap

These are goals to be set for future releases. This is completely subject to change at any time.

  • 0.5.8
Add depth buffer fill: Template:Big complete
Rework D3DTLVERTEX rendering: Template:Big complete
Support `Adjust primary resolution` on Direct3D: Template:Big complete
Optimize shader cache: Template:Big complete
Group renderer commands into batches: Template:Big complete
Move surfaces to renderer control.: Template:Big complete
Add framerate limiter: Template:Big complete
Improve fog support: Template:Big complete
  • 0.5.x
Add mipmap surfaces: Template:Big complete
Support D3D2 textures: Template:Big complete
Fix reference counts: Template:Big complete
Implement D3D execute buffers: Template:Big complete
Add software T&L for execute buffers: Template:Big complete
Fix resource leaks: Template:Big complete
Create new/better DXGLCFG application: Template:Big complete
Add client memory surfaces: Template:Big complete
Add multisampling: Template:Big complete
Precompile generated shaders used in previous sessions: Template:Big complete
Fix 16-bit 565 surfaces on ATI Radeon X300 series: Template:Big complete
Fix clippers on NVIDIA GeForce 6 series GPU: Template:Big complete
Fix 8-bit color with Mesa software renderer: Template:Big complete
  • 0.5.x or 0.6.0
Support optional INI files for configuration: Template:Big complete
Optionally delete user settings on uninstall: Template:Big complete
  • Future
Support multiple DirectDraw drivers per process: Template:Big complete
Validate DDraw parameters: Template:Big complete
Support surface color depths: Template:Big complete
Support NULL HWND: Template:Big complete
Implement and improve API functions: Template:Big complete
Convert from C++ to C: Template:Big complete
Add Code::Blocks projects: Template:Big complete
Support GCC/MinGW compilation: Template:Big complete
Create Doxygen documentation: Template:Big complete
Support PBO texture transfer: Template:Big complete
Add optimized texture color conversion: Template:Big complete
Support palette fading without updating primary: Template:Big complete
Advanced VSync support: Template:Big complete
Hook GetCursorPos/SetCursorPos/ClipCursor/GetClipCursor/GetCursorInfo: Template:Big complete
Hook GDI palette function: Template:Big complete

Screenshots and videos

Note: These are old screenshots and videos. DXGL is now capable of running several games.

DXGLTestAppMain1.png DXGLCfg.png

The first screenshot is of the test application for DXGL. The second screenshot is of the config program.

DXGLTest1 ddraw.png DXGLTest1 dxgl001 0.png

The first image is of the direct access/page flipping test in windowed mode, 8-bit color. This is the `reference` shot taken with the system's ddraw.dll. Colors depend on the current system palette. The second image is of the same program rendered in DXGL in fullscreen. The colors are rendered using GLSL, with a luminance texture for the image and a 256x1 BGRA texture for the color palette. The black bars are because the screen was set to 720x480 but DXGL was set to 640x480, using aspect corrected scaling instead of mode switching.

DXGLTest1 dxgl002.png DXGLTest1 dxgl003.png

DXGLTest displaying color patterns in windowed mode; Gradient bar test in 32-bit color

Videos of test runs of dxgltest. The first test currently includes a palette screen and a gradient test. The gradients look ugly in 256 color mode because the routine does not support dithering.

Downloads

These downloads are subject to the GNU Lesser General Public License, version 2.1. To install, simply run the Windows installer. To upgrade, install over the old version. All programs configured by the configuration tool will be automatically updated.

The current available version of DXGL is 0.5.7. Please click one of the links below to download.

Windows installer

Source code

Please see All DXGL Downloads for older versions.

SVN

SVN readonly access is available at:

svn://www.williamfeely.info/dxgl

There is a Mediawiki-based SVN log at:

http://www.williamfeely.info/wiki/Special:Code/DXGL

AppDB

An AppDB system (similar to that on winehq.org) is now available at:

https://www.williamfeely.info/appdb/

This requires a user account separate from the other services.

Discussion boards

You may discuss DXGL at:

https://www.williamfeely.info/phpBB3

You must create a forum account to post content.

Bug reports

Bug reports are managed by a Bugzilla system available at:

https://www.williamfeely.info/bugzilla

A user account needs to be created at this site to post bug reports.

There was a list of current bugs here, but the extension used is not compatible with SQLite.