Hi all !

i trying to create DirectX8 program at masm32 and get strange error :

VC++ text looks:

D3DXCreateTextureFromFile( p_d3d_Device, "Texture179.bmp", &g_pTexture)

and it well compiles and works... now i trying to make it with MASM:

includelib d:\masm32\lib\d3dx8.lib

D3DXCreateTextureFromFileA proto :DWORD,:DWORD,:DWORD
.data
TextureName db "Texture179.bmp",0

<...some win32 code from Iczelion tute01 ... >

lea ecx,PointerToTexture
push ecx
lea ecx,TextureName
push ecx
mov eax,Pointer_D3D_Device
mov ecx,
push ecx
call D3DXCreateTextureFromFileA

now it assembles OK, but when i try to link it with

link /SUBSYSTEM:WINDOWS /LIBPATH:d:\masm32\lib wind_03.obj

it produces LOT of 'unresolved symbol' ERRORS in d3dx8.lib ! how it is possible ???

d3dx8.lib(x3d_vec3.obj) : error LNK2001: unresolved external symbol
__fltused
d3dx8.lib(jidctflt.obj) : error LNK2001: unresolved external symbol
__fltused
d3dx8.lib(d3dxtrigsse.obj) : error LNK2001: unresolved external symbol
__fltused
d3dx8.lib(d3dxtrigsse2.obj) : error LNK2001: unresolved external symbol
__fltused
d3dx8.lib(d3dxmathsse.obj) : error LNK2001: unresolved external symbol
__fltused
d3dx8.lib(d3dxquatsse.obj) : error LNK2001: unresolved external symbol
__fltused
...
finally : wind_03.exe : fatal error LNK1120: 28 unresolved externals

any way to link it ? if VC++ can do it why masm32 can not ?
Posted on 2002-10-20 05:34:07 by Drakon Rider
The DX library uses C library functions so you'll need to link to those libraries as well. Scronty uses another version of the library which is a DLL and an import library (unlike your library which is a static library), but IIRC this DLL is not included in directX by default as it's the debug version of the library you are using.

Thomas
Posted on 2002-10-20 05:53:55 by Thomas