SharpDX - SwapChain1 - where are the constructors?

Started by
5 comments, last by Spazzarama 10 years, 1 month ago

I'm currently going through Direct3D Rendering Cookbook, 2nd Edition and in the first chapter it's constructing an instance of SharpDX.DXGI.SwapChain1 and providing a number of parameters, as per the SharpDX source code here. Now, I've installed the latest from the SharpDX website, and am referencing the assemblies in the DirectX11_1-net40 folder, and I'm also running on Windows 8.1 with DirectX 11.2 (which my video card supports), and yet in my code, the only exposed constructor I have access to is SwapChain1(IntPtr nativePtr). There is absolutely no sign of the constructors I linked above in the SharpDX source on Github.

Any idea what I might be doing wrong?

Screenshot of the code from my Kindle Reader:

2014-02-22_1256.png

Screenshot of me not being able to write the above code on my machine:

2014-02-22_1259.png

Advertisement

Well I have my answer. The folks at SharpDX actually haven't updated the main download for a while. I need the DirectX11_2 build of SharpDX, which I kind of have to do myself, it seems.

Using the latest dev package 2.5.1 from the home page, this should be in the folder DirectX11_2-net40 and constructors are available from the DXGI assembly there.

[Edit] You don't need to build yourself, there is a build 2.5.1 package build updated to the latest changes[/Edit]

Well I have my answer. The folks at SharpDX actually haven't updated the main download for a while. I need the DirectX11_2 build of SharpDX, which I kind of have to do myself, it seems.

Make sure to use the "Latest Dev Package" download link on the SharpDX homepage. It includes the binaries for 11_2.

Edit: Xoofx was faster smile.png

current project: Roa

Using the latest dev package 2.5.1 from the home page, this should be in the folder DirectX11_2-net40 and constructors are available from the DXGI assembly there.

[Edit] You don't need to build yourself, there is a build 2.5.1 package build updated to the latest changes[/Edit]

Ahah, thanks, I couldn't get anything to build anyway. Loading the SharpDX solution into Visual Studio 2013 had a tonne of errors. References to methods, identifiers and so forth that did not exist anywhere in the entire code SharpDX base.

Ahah, thanks, I couldn't get anything to build anyway. Loading the SharpDX solution into Visual Studio 2013 had a tonne of errors. References to methods, identifiers and so forth that did not exist anywhere in the entire code SharpDX base.

Compiling SharpDX requires to install prerequisites (as described on the download page: Windows SDK7.1 even for Windows8, DirectX June SDK 2010, Net20/Net35 on Windows8) and select the correct solution target platform (DirectX11_2Debug) when building

I know you already have this sorted axefrog, but for others following this the dev package xoofx refers to is included in the code download for the book as well under the folder .\External\Bin

Justin Stenning | Blog | Book - Direct3D Rendering Cookbook (using C# and SharpDX)

Projects: Direct3D Hook, EasyHook, Shared Memory (IPC), SharpDisasm (x86/64 disassembler in C#)

@spazzarama

 

This topic is closed to new replies.

Advertisement