Linking with d3d11.dll/lib

Sean Cavanaugh WorksOnMyMachine at gmail.com
Fri Feb 24 04:10:55 PST 2012


On 2/23/2012 5:03 PM, John Burton wrote:
> I'm trying to use the d3d11 bindings in
> http://www.dsource.org/projects/bindings/wiki/DirectX to call
> direct3d11 functions from my D program.
>
> I've managed to get the code to compiler but when it links I get
> this error -
>
> Error 42 Symbol Undefined _D3D11CreateDeviceAndSwapChain at 48
>
> I have copied the D3D11.lib from the D3D SDK into my project and
> then run "COFFIMPLIB d3d11.lib -f" to convert it and included the
> library in my project settings.
>
> Is there something else I need to do to make this link? Any help
> appreciated.

I modified my test app to use D3D11CreateDeviceAndSwapChain instead of 
D3D11CreateDevice and it links and runs against either function.  The 
only trouble I had was when I went out of my way to delete the import 
libraries (d3d11.lib) in order to see what the link error looks like.

I am currently using dmd2 2.057 and building my project with Visual 
Studio + VisualD plugin (0.30).


More information about the Digitalmars-d-learn mailing list