   Linking d3d9.lib
  Using Visual Studio 2008The Graphics sub-project, which builds a .lib used by the main project, needs to link to d3d9.lib. In the project properties, under "Librarian", d3d9.lib is included. When I compile, I get the following:Warning 1 warning LNK4006: __NULL_IMPORT_DESCRIPTOR already defined in d3d9.lib(d3d9.dll); second definition ignored d3dx9.libWarning 2 warning LNK4221: no public symbols found; archive member will be inaccessible d3dx9.libError 3 error LNK2019: unresolved external symbol _Direct3DCreate9@4 referenced in function "public: bool __thiscall GraphicsEngine::Initialize(struct GraphicsInitParams const &)" (?Initialize@GraphicsEngine@@QAE_NABUGraphicsInitParams@@@Z) Graphics.lib   
  Does it work if you link d3d9.lib from the main application instead of the graphics library?   ;  Thanks for the reply!This doesn't work either. The output is justError1error LNK2019: unresolved external symbol _Direct3DCreate9@4 referenced in function "public: bool __thiscall GraphicsEngine::Initialize(struct GraphicsInitParams const &)" (?Initialize@GraphicsEngine@@QAE_NABUGraphicsInitParams@@@Z)Graphics.lib;  Does d3d9.lib actually exist in the paths set up in visual studio as per This? If the linker can't find a library, it'll silently fail rather than giving a linker error, which is a bit annoying... In particular, make sure the path includes the /x86/ suffix (Assuming a 32-bit build).   ;  well I'm retarded... I was inluding both the x64 and x86 directories -_-Thanks again for the posts   ;Quote:Original post by yxrktwell I'm retarded... I was inluding both the x64 and x86 directories -_-Thanks again for the postsThat's another annoying thing about the visual studio linker - it doesn't give any errors if it comes across a 64-bit library instead of a 32-bit one. I've been bitten by that bug in the past too...   