My attempt at a D3D11 wrapper is getting nowhere fast :(
After getting it up and running it has only been stable when not doing anything in particular. My first plan was to modify COM interface vtables but I clearly havn't figured out how as it instantly crashes. Have a pretty complete ID3D11Device wrapper class and but it crashes pretty fast after I manage to dump about 100 binary compiled shaders. It would probably be my furthest progress if it didn't end up crashing. Considering I started yesterday I might be happy with a "useless" wrapper that is stable and doesn't crash. I'm not sure if we have a solution to the problem that dx11 recieves binary compiled shaders. Some games might ship more human readable shaders and compile them at some Point but human readable shaders are not guaranteed to even be shipped with a game.
After getting it up and running it has only been stable when not doing anything in particular.

My first plan was to modify COM interface vtables but I clearly havn't figured out how as it instantly crashes.

Have a pretty complete ID3D11Device wrapper class and but it crashes pretty fast after I manage to dump about 100 binary compiled shaders. It would probably be my furthest progress if it didn't end up crashing.

Considering I started yesterday I might be happy with a "useless" wrapper that is stable and doesn't crash.

I'm not sure if we have a solution to the problem that dx11 recieves binary compiled shaders. Some games might ship more human readable shaders and compile them at some Point but human readable shaders are not guaranteed to even be shipped with a game.

Thanks to everybody using my assembler it warms my heart.
To have a critical piece of code that everyone can enjoy!
What more can you ask for?

donations: ulfjalmbrant@hotmail.com

#1
Posted 12/06/2013 06:47 AM   
[url]https://forums.geforce.com/default/topic/549473/3d-vision/indigomod-dx11-wrapper-by-chiri-and-elbarterino-bioshock-infinite/post/3884453/#3884453[/url] Don't ask me how any of its done since I have no idea but he seems to explain your problem.
https://forums.geforce.com/default/topic/549473/3d-vision/indigomod-dx11-wrapper-by-chiri-and-elbarterino-bioshock-infinite/post/3884453/#3884453


Don't ask me how any of its done since I have no idea but he seems to explain your problem.

Co-founder of helixmod.blog.com

If you like one of my helixmod patches and want to donate. Can send to me through paypal - eqzitara@yahoo.com

#2
Posted 12/06/2013 06:52 AM   
Would it help to look at this one and see how it approaches things? You may even be able to develop it further, with Chiri's permission. http://3dmigoto.com/
Would it help to look at this one and see how it approaches things? You may even be able to develop it further, with Chiri's permission.


http://3dmigoto.com/

#3
Posted 12/06/2013 06:53 AM   
There is very Little that can be done when it comes to modifying existing binaries as usually only one guy has the source code who usually is the only one capable of modifying it as well. Helix dx9 dll's are stable enough that they rarely need any change. Game fixes are data driven and don't rely on game specific dll modifications for the most part. Unless I'm mistaken I got Chiri's dll's to instantly crash AC4 as well and I don't want to be responsible for fixing something like that when having enough trouble doing small changes here.
There is very Little that can be done when it comes to modifying existing binaries as usually only one guy has the source code who usually is the only one capable of modifying it as well.

Helix dx9 dll's are stable enough that they rarely need any change.
Game fixes are data driven and don't rely on game specific dll modifications for the most part.

Unless I'm mistaken I got Chiri's dll's to instantly crash AC4 as well and I don't want to be responsible for fixing something like that when having enough trouble doing small changes here.

Thanks to everybody using my assembler it warms my heart.
To have a critical piece of code that everyone can enjoy!
What more can you ask for?

donations: ulfjalmbrant@hotmail.com

#4
Posted 12/06/2013 07:35 AM   
Well, you are much faster than me anyway. It took me several weeks to get a simpler wrapper working without crashing. I've never done any windows programming before though. It doesn't do anything yet, but doesn't crash. You probably already know that all these dlls are wildly threaded, and that the code has to be thread safe in every call. You can't allocate memory at each call, even accidentally, for example. You need a way to debug the crashes, or to step through your code to be sure it's right. I've been using Debugbreak to make it possible to stop at arbitrary points and look at it with the Visual Studio debugger. You can also use logging to a file to see how far it gets and check parameters. As long as you are careful about log file access it seems to be fine to log in the multi-threaded case. You need a way to debug it, you'll never get it working by code inspection. That Helix post that Eqzitara references is probably your best bet. Both Helix and Chiri wrote their own shader decoder. Helix's goes to asm, Chiri's to HLSL.
Well, you are much faster than me anyway. It took me several weeks to get a simpler wrapper working without crashing. I've never done any windows programming before though. It doesn't do anything yet, but doesn't crash.

You probably already know that all these dlls are wildly threaded, and that the code has to be thread safe in every call. You can't allocate memory at each call, even accidentally, for example.

You need a way to debug the crashes, or to step through your code to be sure it's right. I've been using Debugbreak to make it possible to stop at arbitrary points and look at it with the Visual Studio debugger. You can also use logging to a file to see how far it gets and check parameters. As long as you are careful about log file access it seems to be fine to log in the multi-threaded case. You need a way to debug it, you'll never get it working by code inspection.


That Helix post that Eqzitara references is probably your best bet. Both Helix and Chiri wrote their own shader decoder. Helix's goes to asm, Chiri's to HLSL.

Acer H5360 (1280x720@120Hz) - ASUS VG248QE with GSync mod - 3D Vision 1&2 - Driver 372.54
GTX 970 - i5-4670K@4.2GHz - 12GB RAM - Win7x64+evilKB2670838 - 4 Disk X25 RAID
SAGER NP9870-S - GTX 980 - i7-6700K - Win10 Pro 1607
Latest 3Dmigoto Release
Bo3b's School for ShaderHackers

#5
Posted 12/06/2013 10:52 AM   
I would love if chiri/helix would release the source code to a couple of people around the forum so we can take the wrapper to the next level...that would be purely awesome! I know is a tremendous lot of work for one person and it requires a lot of time even to a group of people, that's why I definitely think it should be great/awesome if more of us band up! But then again is not up to me... Still something this unique would be awesome as it can give you access to alot of stuff (not necessarly 3D Vision but the whole rendering pipeline) In conjuration with a wrapper like ENB (that injects stuff) a wrapper that can modify existing shaders would be awesome tools for any person who is passionate about 3D Graphics :) I still hope that one day they will decide to either go fully commercial or release the code as open source (at least to a portion of the community)
I would love if chiri/helix would release the source code to a couple of people around the forum so we can take the wrapper to the next level...that would be purely awesome!
I know is a tremendous lot of work for one person and it requires a lot of time even to a group of people, that's why I definitely think it should be great/awesome if more of us band up!
But then again is not up to me...
Still something this unique would be awesome as it can give you access to alot of stuff (not necessarly 3D Vision but the whole rendering pipeline)
In conjuration with a wrapper like ENB (that injects stuff) a wrapper that can modify existing shaders would be awesome tools for any person who is passionate about 3D Graphics :)

I still hope that one day they will decide to either go fully commercial or release the code as open source (at least to a portion of the community)

1x Palit RTX 2080Ti Pro Gaming OC(watercooled and overclocked to hell)
3x 3D Vision Ready Asus VG278HE monitors (5760x1080).
Intel i9 9900K (overclocked to 5.3 and watercooled ofc).
Asus Maximus XI Hero Mobo.
16 GB Team Group T-Force Dark Pro DDR4 @ 3600.
Lots of Disks:
- Raid 0 - 256GB Sandisk Extreme SSD.
- Raid 0 - WD Black - 2TB.
- SanDisk SSD PLUS 480 GB.
- Intel 760p 256GB M.2 PCIe NVMe SSD.
Creative Sound Blaster Z.
Windows 10 x64 Pro.
etc


My website with my fixes and OpenGL to 3D Vision wrapper:
http://3dsurroundgaming.com

(If you like some of the stuff that I've done and want to donate something, you can do it with PayPal at tavyhome@gmail.com)

#6
Posted 12/06/2013 02:20 PM   
Wow it's great to see people looking to tackle this independently - good job everyone. I bought Visual Studio 2010 earlier this year so I could start looking but never did squat with it. Perhaps in the New Year it might be good to start up a little community project - sure we might not get anywhere fast, but it would be fun, pro-active, and we would still learn a lot. Maybe set something up on SourceForge/GitHib/Other? I have a massive work deadline for December 31st so can't start anything now (I am committed to just tinkering with my current batch of DX9 fixes to polish them off), but if anyone has any code or VS Studio Files to share I might get sucked in early... My C++ is definitely rusty nowadays that's for sure (everything where I work is Java, with some C), but I'm confident I'd get back into to it pretty quickly. I read somewhere that VS2012 has better streamlined integration with DX, not sure if that's true - anyone know? It would definitely help with debugging. I work at a University so I can get "academic discount" (read that as the whole $500 package for $80).
Wow it's great to see people looking to tackle this independently - good job everyone. I bought Visual Studio 2010 earlier this year so I could start looking but never did squat with it. Perhaps in the New Year it might be good to start up a little community project - sure we might not get anywhere fast, but it would be fun, pro-active, and we would still learn a lot. Maybe set something up on SourceForge/GitHib/Other? I have a massive work deadline for December 31st so can't start anything now (I am committed to just tinkering with my current batch of DX9 fixes to polish them off), but if anyone has any code or VS Studio Files to share I might get sucked in early... My C++ is definitely rusty nowadays that's for sure (everything where I work is Java, with some C), but I'm confident I'd get back into to it pretty quickly.

I read somewhere that VS2012 has better streamlined integration with DX, not sure if that's true - anyone know? It would definitely help with debugging. I work at a University so I can get "academic discount" (read that as the whole $500 package for $80).

Rig: Intel i7-8700K @4.7GHz, 16Gb Ram, SSD, GTX 1080Ti, Win10x64, Asus VG278

#7
Posted 12/06/2013 03:33 PM   
Too bad I have no idea about programming ;) best thing nvidia could do it to release a tool to fix games in a relatively easy manner, would probably be cheaper than sponsoring titles to be 3d vision ready.
Too bad I have no idea about programming ;) best thing nvidia could do it to release a tool to fix games in a relatively easy manner, would probably be cheaper than sponsoring titles to be 3d vision ready.

Acer H5360 / BenQ XL2420T + 3D Vision 2 Kit - EVGA GTX 980TI 6GB - i7-3930K@4.0GHz - DX79SI- 16GB RAM@2133 - Win10x64 Home - HTC VIVE

#8
Posted 12/06/2013 04:45 PM   
I'm a developer but don't have any experience with shaders or DX development. I did OpenGL a while back and know C++. Would you be able to point to something to read over regarding what you guys work on? Just to gloss over it and see what it's about, a starting point of sorts for development.
I'm a developer but don't have any experience with shaders or DX development. I did OpenGL a while back and know C++.

Would you be able to point to something to read over regarding what you guys work on? Just to gloss over it and see what it's about, a starting point of sorts for development.

#9
Posted 12/08/2013 04:33 AM   
[quote="Manwe"]I'm a developer but don't have any experience with shaders or DX development. I did OpenGL a while back and know C++. Would you be able to point to something to read over regarding what you guys work on? Just to gloss over it and see what it's about, a starting point of sorts for development.[/quote] I found this book useful [url]http://www.amazon.com/Introduction-Game-Programming-With-Directx/dp/1598220160[/url]. If you go here I think this is a PDF of the book, but I've not checked it for completeness [url]https://www.google.com/url?sa=t&rct=j&q=&esrc=s&source=web&cd=2&cad=rja&ved=0CDYQFjAB&url=http%3A%2F%2F3dlearn.googlecode.com%2Ffiles%2F(by%2520kuafu)Introduction%2520to%25203D%2520Game%2520Programming%2520with%2520DirectX90c%2520A%2520Shader%2520Approach.pdf&ei=B_ijUvasIcSikQfi_oGQDA&usg=AFQjCNG_ubHj-6H__TYkyJEiBFaTYMCK9g&sig2=BgWV6N9APawV2S8nbpIn6A&bvm=bv.57752919,d.eW0[/url] It's heavy on the C++, and you might need to google a few tutorials on the web as well. MSDN is a good place to get up to speed with the asm langauge [url]http://msdn.microsoft.com/en-us/library/windows/desktop/bb219840(v=vs.85).aspx[/url]
Manwe said:I'm a developer but don't have any experience with shaders or DX development. I did OpenGL a while back and know C++.

Would you be able to point to something to read over regarding what you guys work on? Just to gloss over it and see what it's about, a starting point of sorts for development.


I found this book useful http://www.amazon.com/Introduction-Game-Programming-With-Directx/dp/1598220160. If you go here I think this is a PDF of the book, but I've not checked it for completeness https://www.google.com/url?sa=t&rct=j&q=&esrc=s&source=web&cd=2&cad=rja&ved=0CDYQFjAB&url=http%3A%2F%2F3dlearn.googlecode.com%2Ffiles%2F(by%2520kuafu)Introduction%2520to%25203D%2520Game%2520Programming%2520with%2520DirectX90c%2520A%2520Shader%2520Approach.pdf&ei=B_ijUvasIcSikQfi_oGQDA&usg=AFQjCNG_ubHj-6H__TYkyJEiBFaTYMCK9g&sig2=BgWV6N9APawV2S8nbpIn6A&bvm=bv.57752919,d.eW0

It's heavy on the C++, and you might need to google a few tutorials on the web as well. MSDN is a good place to get up to speed with the asm langauge http://msdn.microsoft.com/en-us/library/windows/desktop/bb219840(v=vs.85).aspx

Rig: Intel i7-8700K @4.7GHz, 16Gb Ram, SSD, GTX 1080Ti, Win10x64, Asus VG278

#10
Posted 12/08/2013 04:49 AM   
Big thanks mike_ar69 for the book. I have a few of them but somehow missed this one and I already found a couple of interesting things inside! Again big thx:)
Big thanks mike_ar69 for the book. I have a few of them but somehow missed this one and I already found a couple of interesting things inside!

Again big thx:)

1x Palit RTX 2080Ti Pro Gaming OC(watercooled and overclocked to hell)
3x 3D Vision Ready Asus VG278HE monitors (5760x1080).
Intel i9 9900K (overclocked to 5.3 and watercooled ofc).
Asus Maximus XI Hero Mobo.
16 GB Team Group T-Force Dark Pro DDR4 @ 3600.
Lots of Disks:
- Raid 0 - 256GB Sandisk Extreme SSD.
- Raid 0 - WD Black - 2TB.
- SanDisk SSD PLUS 480 GB.
- Intel 760p 256GB M.2 PCIe NVMe SSD.
Creative Sound Blaster Z.
Windows 10 x64 Pro.
etc


My website with my fixes and OpenGL to 3D Vision wrapper:
http://3dsurroundgaming.com

(If you like some of the stuff that I've done and want to donate something, you can do it with PayPal at tavyhome@gmail.com)

#11
Posted 12/09/2013 12:26 AM   
You're welcome :-) Just a note also that all the source code is freely available and downloadable too. If you can't find it, I can probably share it, though it was setup for older versions of Visual Studio and needs a bit of converting.
You're welcome :-) Just a note also that all the source code is freely available and downloadable too. If you can't find it, I can probably share it, though it was setup for older versions of Visual Studio and needs a bit of converting.

Rig: Intel i7-8700K @4.7GHz, 16Gb Ram, SSD, GTX 1080Ti, Win10x64, Asus VG278

#12
Posted 12/09/2013 12:33 AM   
I'm a developer too so I always find this stuff interesting, however I am old. I started out with COBOL and punched cards thats how old I am LOL. As a result, my enthusiasm for home projects has waned over the years, but I dumped that book into iBooks for some bedtime reading. Thanks Mike.
I'm a developer too so I always find this stuff interesting, however I am old. I started out with COBOL and punched cards thats how old I am LOL. As a result, my enthusiasm for home projects has waned over the years, but I dumped that book into iBooks for some bedtime reading. Thanks Mike.

#13
Posted 12/09/2013 01:20 AM   
After feeling a bit ill as well as frustrated over zero progress I took Another stab today. Wrapper has currently <400 lines of code. Currently it's only dumping shaders and calculating crc values. Loading AC4 resulted in about 1200 pixel shaders and another 500 vertex shaders. I made a quick stab using D3DDisassemble() but it caused a crash and I don't know why yet.
After feeling a bit ill as well as frustrated over zero progress I took Another stab today.

Wrapper has currently <400 lines of code.

Currently it's only dumping shaders and calculating crc values.

Loading AC4 resulted in about 1200 pixel shaders and another 500 vertex shaders.

I made a quick stab using D3DDisassemble() but it caused a crash and I don't know why yet.

Thanks to everybody using my assembler it warms my heart.
To have a critical piece of code that everyone can enjoy!
What more can you ask for?

donations: ulfjalmbrant@hotmail.com

#14
Posted 12/09/2013 11:47 AM   
Scroll To Top