This is the mail archive of the
mailing list for the Cygwin project.
Re: DirectX8/DirectInput + cygwin
- From: "Barubary" <barubary at cox dot net>
- To: <cygwin at cygwin dot com>
- Date: Wed, 6 Feb 2002 03:11:14 -0800
- Subject: Re: DirectX8/DirectInput + cygwin
- References: <002301c1aef8$228e5440$2801a8c0@dcuthbert2k>
Getting DirectX to work from cygwin GCC essentially can't be done from C++,
but can be done from C. It can't be done from C++ because of the way COM
virtual tables work. GCC can't clone Visual C++'s method because Microsoft
holds a U.S. patent on their exact method. Just try using MFC from GCC and
you'll know exactly what I mean.
In C, the virtual table system is done by actually creating the vtable
structure in the header file, so this isn't a problem. If you modify the
DirectX header files, you could fix this for C++, but you'd have to
do ->lpVtable all the time, like in C.
GCC, or rather binutils, can't handle the Microsoft import library format.
binutils of course has its own, so you could make your own from the DLL.
If import libraries don't work, you could always GetProcAddress on
DirectInputCreate8 after loading dinput8.dll. Then the problem becomes how
to get to the weird global functions (D3DX matrix stuff, for instance).
----- Original Message -----
From: "Dylan Cuthbert" <email@example.com>
To: "Cygwin@Cygwin. Com" <firstname.lastname@example.org>
Sent: Wednesday, February 06, 2002 2:22 AM
Subject: DirectX8/DirectInput + cygwin
> When compiling a DirectInput8 function such as DirectInput8Create() I get
> error linking:
> Unable to resolve DirectInput8Create@20
Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple
Bug reporting: http://cygwin.com/bugs.html