linker error

Started by
3 comments, last by phil67rpg 12 years, 5 months ago
I am using c++ and dx9.I am getting the folowing linker error.
[font="Consolas"][size="1"][font="Consolas"][size="1"]>main.obj : error LNK2019: unresolved external symbol _D3DXCreateTextureFromFileExA@56 referenced in function _WinMain@16

1>main.obj : error LNK2019: unresolved external symbol _D3DXCreateSprite@8 referenced in function _WinMain@16

1>c:\users\phil\documents\visual studio 2010\Projects\dx9s\Debug\dx9s.exe : fatal error LNK1120: 2 unresolved externals

========== Build: 0 succeeded, 1 failed, 0 up-to-date, 0 skipped ==========
I am probably missing a lib file.

[/font][/font]
Advertisement
It can't find the D3DX functions. I'm guessing you're missing d3dx9.lib in your project linker inputs.
I already linked in d3dx9.lib.however it still does not work.

I already linked in d3dx9.lib.however it still does not work.

Have you setup the paths correctly for DirectX SDK so the linker can actually find the .lib file. Also make sure you are linking against the correct one so 64 bit link against the one in 64bit dir and 32 one against the one in the 32 bit dir.

Worked on titles: CMR:DiRT2, DiRT 3, DiRT: Showdown, GRID 2, theHunter, theHunter: Primal, Mad Max, Watch Dogs: Legion

everything appears to be ok but I am still stuck.

This topic is closed to new replies.

Advertisement