Timmy Posted October 31, 2015 Share Posted October 31, 2015 (edited) Hey Everyone,As Jeff mentioned in the 3.8 release thread, i have been working on getting the awesome work anis started here https://github.com/Lopuska/Torque3D/tree/D3D9_D3D11_R%26D up and running. I have fixed a lot of problems, fixed a few performance problems and converted all shaders in the common shader folder to use a new helper macro system to enable Direct3D9 and 11 shaders to place nice together (see post below).It's coming along well and while i wanted to fix a few more things before starting this thread, time has forced my hand. So don't expect it to be full production quality and ready yet, it's not. It's all a work in progress.Source Code:https://github.com/rextimmy/Torque3D/tree/d3d11Problems i know about: Glow blur problem No instancing support yet Windowed mode and editor toggle. See here Feature levels not properly implemented yet Due to the sheer amount of shaders that need switching over to the helper macro system (this does not include shadergen shaders however), without a shadow of doubt i have missed something somewhere. One thing you will notice compared to D3D9 is the dramatic drop in memory usage and a faster loading of levels.There is one performance problem i am aware of involving the constant buffers, long story short i can fix this using 11.1 feature level but unfortunately this is only for Window 8 or above. This is one area i need to really fix up and i will when i get the time. So for now i'm not concerned about performance but rather getting it all working and than i will go and start profiling it in detail and fixing up any performance issues.CompilingIf you are using Windows 10 and want to run in debug mode you must have the graphics tools installed. The easy way to do this via an admin command prompt Dism /online /add-capability /capabilityname:Tools.Graphics.DirectX~~~~0.0.1.0 Unfortunately the old D3D9 is still using the deprecated Microsoft DirectX SDK. This will cause a lot of warnings when you compile and it will fail to compile with VS 2015 due to the use of dxerr . I will fix this up in time but for now i wanted to keep the fully working and 100% tested D3D9 device in place until D3D11 is 100% working.If you use CMake the D3D11 code will be automatically included and if you use the project manager you will have to select "Direct3D 11 Rendering". I have also included VS 2013 to the project generator.It would be great if people could start testing this out and reporting problems, there will be more than what i listed above. Please only use the full template, the empty template has not been updated.There is a second thread over here too about this. Use either thread, doesn't matter. Edited January 8, 2016 by Timmy Quote Link to comment Share on other sites More sharing options...
Timmy Posted October 31, 2015 Author Share Posted October 31, 2015 *Reserved for shader tutorial. Quote Link to comment Share on other sites More sharing options...
RichardM Posted October 31, 2015 Share Posted October 31, 2015 Great job, I will see if I can make some time to test it. Quote Link to comment Share on other sites More sharing options...
J0linar Posted November 1, 2015 Share Posted November 1, 2015 Built with vs2010 using cmakeCrash:GFXD3D11Device::init - D3D11CreateDeviceAndSwapChain failed!My Specs:Windows 8.1i7-3630QM CPU @ 2.40GHz 2.40GHz64 Bit16GB RamGFX: Nividia GeForce GTX 675M Quote Link to comment Share on other sites More sharing options...
Timmy Posted November 2, 2015 Author Share Posted November 2, 2015 I gotta admit i haven't tried it with VS 2010. Was that in debug or release mode? If you get that in debug mode you have to install the Windows Software Development Kit for Win8 Quote Link to comment Share on other sites More sharing options...
J0linar Posted November 2, 2015 Share Posted November 2, 2015 soz was late here,it was in debug and i have the Dev kit for Win8 installed Quote Link to comment Share on other sites More sharing options...
Timmy Posted November 2, 2015 Author Share Posted November 2, 2015 Is VS 2010 definitely finding/using that windows kit directory? You can remove this line if you like https://github.com/rextimmy/Torque3D/blob/d3d11/Engine/source/gfx/D3D11/gfxD3D11Device.cpp#L271 it will work than (should do anyway)If you are not seeing heaps of these type of warning messages than it's not using the windows kit warning C4005: 'D3D11_ERROR_DEFERRED_CONTEXT_MAP_WITHOUT_INITIAL_DISCARD' : macro redefinition (C:\Devel\Torque3D-rex-d3d11\Engine\source\gfx\D3D11\gfxD3D11VertexBuffer.cpp) Quote Link to comment Share on other sites More sharing options...
TorqueFan Posted November 5, 2015 Share Posted November 5, 2015 @Timmy - Wanted to post just to say thanks a lot for tackling this. I look forward to seeing this completed! Quote Link to comment Share on other sites More sharing options...
Timmy Posted January 8, 2016 Author Share Posted January 8, 2016 Thought i would post and let everyone know i haven't forgotten nor given up on the D3D11 code.Anyway it was brought to my attention a few people where having trouble running the code in debug mode. I placed a fix on my repo for this, so if you had this problem before it should be ok now.So in short the debug layers is not essential anymore to run in debug mode but if you do want the extra information this provides you need toWindows 7: Have at least Windows 8.0 SDK installedWindows 10: Have graphics tools installed. See my OP for details.I have started work on the instancing which is the last big feature to add. I have put this in a separate branch until it is finished and than i will merge it over to my main D3D11 branch. If you happen to checkout the d3d11_instancing branch just beware it might not be stable or even work at all, best to stick to the main D3D11.Once instancing is done it's time to fix some of the smaller issues and start cranking out a bit more performance :mrgreen:I will write the shader tutorial tonight, i totally forgot about it :oops: Quote Link to comment Share on other sites More sharing options...
JeffR Posted January 8, 2016 Share Posted January 8, 2016 <3 Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.