Vk3DVision - A Vulkan 3D Vision Driver

Post Reply
User avatar
helifax
Sharp Eyed Eagle!
Posts: 390
Joined: Tue Jan 12, 2010 5:09 pm
Which stereoscopic 3D solution do you primarily use?: Head Mounted Display (HMD)

Vk3DVision - A Vulkan 3D Vision Driver

Post by helifax »

Update List:

Version 2.0.0 is out!
- Comes it OpenVR support (up to 35% improvements in VR over HelixVision)
- DirectX 9 Compatibility for Nvidia 3D Vision (working on RTX 3000 series and latest NVidia Drivers!)
- And many more!!!

20/09/2020: viewtopic.php?p=173577#p173577
The day has come to release Vk3DVision v.1.0.1 :!: :!: :!: :shutter
And to celebrate this, this initial release also comes with 3"D" fully fixed games:
- Detroit: Become Human :woot
- Doom (2016) :woot
- Doom: Eternal :woot
(hence the 3"D" :lol: )
Image

Lots of updates... Check the latest posts!!!

02/08/2020: :shutter Vk3DVision Updated Demo for Detroit: Become Human - Demo: viewtopic.php?p=172581#p172581 (3D Vision only)
21/07/2020: :shutter Vk3DVision Demo for Detroit: Become Human - Demo: viewtopic.php?p=172178#p172178 (3D Vision only)
12/07/2020: Detroit: Become Human first level/mission in Stereoscopic 3D using Vk3DVision:
:woot
https://www.youtube.com/watch?v=leYdYS7BBv8
:woot

11/07/2020 - Major Performance improvements: viewtopic.php?p=171948#p171948
:idea:
https://www.youtube.com/watch?v=2lxUSFPbNa0
:idea:
10/07/2020 - Getting Vk3DVision to run on Red Dead Redemption 2, YEY: viewtopic.php?p=171924#p171924
07/07/2020 - "Projekt" Update: viewtopic.php?p=171877#p171877
29/06/2020 - Getting the first Vulkan game to render in Stereoscopic 3D (Detroit: Become Human):
:woot :woot
https://www.youtube.com/watch?v=9MQUrCj3hW0
:woot :woot
Going from Single-Thread to Multi-Thread in Shader Decompilation/Injection/Recompilation! More info here: viewtopic.php?p=171760#p171760

- 22/06/2020 - FIRST PERFECT STEREOSCOPIC 3D rendered image from Detroit: Become Human:
Image
(There is ONE thing that is wrong in this image though :D Can you spot it :mrgreen: )

19-22/06/2020 :
- Managed to fix a graphics corruption/driver crash/PC hard lock related to the Description Sets & Layouts injection & modification.
- Worked on the Ability to Change the Shader Source (while the game is running), Recompile & Swap.
- A bit of work on showing the original version of the shader running.
See: viewtopic.php?p=171640#p171640

- 18/06/2020 - Started working on UI for: viewing & editing exported shaders, active shaders responsible for current frame rendering.
- 17/06/2020 - Started working on more fixes for when the decompiler fails to fully decompile to glsl (like special extensions) which results in the compiler failing to compile. Plan is to add a mechanism that handles this gracefully without killing everything.
- 16/06/2020 - Got Exclusive Mode working in DirectX11 and 3DVision Ready monitor & glasses to work. :shutter Tested on 2 games so far. See: viewtopic.php?p=171573#p171573
- 15/06/2020 - Started looking in getting DirectX11 Exclusive Mode working so we can use 3D Vision Automatic to render to a supported 3D Screen.
- 14/06/2020 - Performance Optimisations (40% gain) in Release Build. :woot See: viewtopic.php?p=171526#p171526
- 11/06/2020 - Rendering in :woot Stereo 3D :woot - using Nvidia 3D Vision Discover Mode in Detroit: Become Human: See: viewtopic.php?p=171490#p171490
- 11/06/2020 - Stereo 3D Injection started: Sending Custom Data from CPU to GPU (there are some bugs that I need to track) -> But Mostly Done.
- 10/06/2020 - Vulkan Shader Decompilation/Injection/Recompilation & Swapping at runtime (initial run) -> Done.
- 09/06/2020 - Very promising results on: Vulkan Shader Decompilation/Injection/Recompilation & Swapping.
- 07/06/2020 - Shader Management work: Decompilation of SpirV to GLSL and Shader dumping to disk -> Done.
- 05/06/2020 - Started prototyping: Vulkan Shader Injection & Real time shader changing for Stereorization.

If you want to support this project you can follow me on the Patreon Page for this project: https://www.patreon.com/Vk3DVision. If you don't want to commit to something monthly, but still want to support this project, donations are also appreciated. You can use my Paypal account: tavyhomeppal@hotmail.com
The official page for the project: http://3dsurroundgaming.com/Vk3DVision.html


Original Post:
I've been prototyping a few things over some time (mostly to fool around when I got bored) and I tried a few things in Vulkan ofc:)
Thus, I can present you a first image of a Vulkan game running in 3D Vision (Discover). It also presents fine in HelixVision in VR :

Image

Sure it doesn't look like much... yet, as there is no stereo information added yet to the game. There are still lots of things to do to get there.
Here is the list of what I prototyped and got working:

The easier part:
1. Vulkan to DirectX 11 Interop for sharing resources (including synchronisation) -> Done.
2. 3D Vision Direct over DirectX 11 -> Was mostly Done. (Done as 14/05/2020).
3. Exclusive Fullscreen in DirectX 11 -> Failed. (I tried for a few days to get it working. I managed to make it work at some point but not realiable. I expect the game/app fights with my DXGI Output over exclusivity. More work is required. But hey ^_^ it works in HelixVision in VR :geek: )

The hard part - because each part is a project in itself:
4. SPIRV Shader Decompilation, Conversion to GLSL, Recompilation as SPIRV and fed back to Vulkan Renderer -> BIG CHECK AND DONE! (Some bugs and functionality is lacking still).
5. Vulkan Shader Injection & Real time shader changing for Stereorisation -> Done as of 14/05/2020 (Some bugs are probably still around -> Requires a lot more testing).
6. Vulkan Shader Hunting & RT Debugging and other functionality -> Not started.
7. UI interface -> Not started.
8. Other stuff?! -> Didn't even started thinking about it :)

So far I have forked Reshade by Crosire, simply because I didn't want to WASTE tons of time on implementing all the FLUFF that goes in a wrapper. PLUS, I really loved that Reshade uses the Vulkan Layering Mechanism instead of the plain Hooking of DLLs.
I am aiming for the same approach as I did in my OpenGL3DVision wrapper: It will display SEQUENTIAL frames (This means if a game has a FPS hard-lock of 60 FPS you will literally see 30 FPS in 3D. Most games can be hacked to remove this lock and most current games have unlocked FPS - if you have the hardware)

This is pretty much still in the phase of prototyping and experimentation. As such, I cannot promise anything. If people are interested and want to help with the coding or in any other way you think it will help the project, please let me know.

Cheers,
Helifax
Last edited by helifax on Wed Nov 18, 2020 5:42 pm, edited 37 times in total.
http://3dsurroundgaming.com:
- Home of OGL3DVision wrapper & Vk3DVision - Play your favourite OpenGL & Vulkan games in Stereoscopic 3D using Nvidia 3D Vision OR Virtual Reality using HelixVision(https://store.steampowered.com/app/1127310/HelixVision/)
- Home of some of my UHD Surround/Eyefinity/21:9/32:9 Fixes. (Or you can always check http://pcgamingwiki.com/)

Want to contribute to the development of Vk3DVision? You can check my Patreon Page for the project: https://www.patreon.com/Vk3DVision. If you still like my project but don't want to contribute monthly you can always send me a PayPal: tavyhomeppal@hotmail.com.

You can always follow me on Twitter: @OctavianVasilov

User avatar
Chtiblue
Sharp Eyed Eagle!
Posts: 355
Joined: Mon Sep 16, 2019 4:52 am
Which stereoscopic 3D solution do you primarily use?: S-3D HDTV

Re: Vk3DVision - A Vulkan 3D Vision Wrapper

Post by Chtiblue »

Glad to see you Helifax!
Awesome project 8)
Best luck & hope you'll find some coding partners ;)

3DNovice
Cross Eyed!
Posts: 177
Joined: Thu Mar 29, 2012 4:49 pm

Re: Vk3DVision - A Vulkan 3D Vision Wrapper

Post by 3DNovice »

Awesome indeed.

I know next to nothing about this stuff. But I had looked around at it.

A link I found about hacking into Vulkan, but it seems like you have this sorted already.
viewtopic.php?f=181&t=23738&p=168361&hi ... an#p168361

I also imagine that you discovered that they changed the co-ordinate system
https://matthewwellings.com/blog/the-ne ... te-system/

Good Luck though, it seems a lot of Vulkan 3D Stereo is undocumented.

There's this
https://stackoverflow.com/questions/485 ... ith-vulkan

https://vulkan-tutorial.com/Drawing_a_triangle/Setup

and the Rift documentation for dx11, 12 and Vulkan
https://developer.oculus.com/documentat ... dg-render/

User avatar
Skawen
Cross Eyed!
Posts: 126
Joined: Mon Sep 16, 2019 1:36 am
Which stereoscopic 3D solution do you primarily use?: S-3D desktop monitor

Re: Vk3DVision - A Vulkan 3D Vision Wrapper

Post by Skawen »

This is amazing project helifax!

The Doom fix with Your OpenGL3DVision wrapper was best.

User avatar
Necropants
Binocular Vision CONFIRMED!
Posts: 267
Joined: Tue Sep 17, 2019 11:05 pm
Which stereoscopic 3D solution do you primarily use?: S-3D desktop monitor

Re: Vk3DVision - A Vulkan 3D Vision Wrapper

Post by Necropants »

Wow. Doom eternal in 3dvision would be a dream. What a legend. best of luck.

russellk
Cross Eyed!
Posts: 122
Joined: Sun Jan 24, 2010 2:09 pm
Which stereoscopic 3D solution do you primarily use?: S-3D desktop monitor

Re: Vk3DVision - A Vulkan 3D Vision Wrapper

Post by russellk »

Hi mate,

Like I said on the other thread, good to see you around and hope you're well.

I'm not a coder so can't help you in that respect, but if there's anything else, testing, research etc. then please say.
Outside of coding I'm not sure what skills you require, but if you need someone to do a bit of donkey work with testing or just do some reading/2nd opinion etc. then please post here or pm me.

For us laypeople, Is this all based on 3d vision direct and therefore at the mercy of continued community support? Or is it an approach that is independent of Nvidia drivers and support?
Sorry if the answer is implicit in your description above.
Win 10 1903 (Via 3dfix manager - Non DCH), 9700K, Gigabyte 2080Ti OC, BenQ XL2420T 3d surround, LG 3d OLED, 4k Projector (3dtvplay), WMR Odyssey+, WIn 19 1809 (425.31), Win 7 Pro x64

for3donly
Two Eyed Hopeful
Posts: 56
Joined: Tue Apr 21, 2020 7:19 pm

Re: Vk3DVision - A Vulkan 3D Vision Wrapper

Post by for3donly »

Hey Helifax, I'm so glad you started it. I've just sent my 100USD pledge via paypal. Cheers.

User avatar
skyrimer
Binocular Vision CONFIRMED!
Posts: 318
Joined: Sun Sep 22, 2013 11:43 am

Re: Vk3DVision - A Vulkan 3D Vision Wrapper

Post by skyrimer »

Wow Christmas arrived really early this year! Really hoping you can make this work, if you need a beta tester or any kind of help I'm in.
ASUS PG278QR Monitor
Windows 10 1809
AMD Ryzen 5 3600 @3.60ghz
Kingston HyperX Predator DDR4 3200 PC4-25600 16GB 2x8GB CL16
MSI B450 Gaming Plus MAX
Corsair RM650 650W 80 Plus Gold
SSD M.2 2280 500GB
NVIDIA 1080 Ti MSI AERO
VR: Pimax 8k & Index controllers

Visit http://www.gamermovil.com for a ton of mobile news and more!

User avatar
RAGEdemon
Sharp Eyed Eagle!
Posts: 472
Joined: Thu Mar 01, 2007 1:34 pm
Which stereoscopic 3D solution do you primarily use?: S-3D Projector Setup

Re: Vk3DVision - A Vulkan 3D Vision Wrapper

Post by RAGEdemon »

Thank you very much Helifax! I'm happy to help but i'm in the same boat as Russell in that I am not a coder. Anything else, please let us know! :woot

Kind regards!
Edit: Clarity | Windows 10 64-Bit | 7700K @ 5.1GHz | 2080 Ti OC | 32GB 3956MHz CL16 RAM | Optane PCIe SSD | Sound Blaster ZxR | 2x 2000W ButtKicker LFE | nVidia 3D Vision | 3D Projector @ DSR 1600p | Oculus Rift CV1

User avatar
helifax
Sharp Eyed Eagle!
Posts: 390
Joined: Tue Jan 12, 2010 5:09 pm
Which stereoscopic 3D solution do you primarily use?: Head Mounted Display (HMD)

Re: Vk3DVision - A Vulkan 3D Vision Wrapper

Post by helifax »

for3donly wrote: Fri Jun 05, 2020 12:32 pm Hey Helifax, I'm so glad you started it. I've just sent my 100USD pledge via paypal. Cheers.
Many thanks for this! I was definitely not expecting it, but it was a very kind present!

@all:
I really wasn't sure if people are still interested that much in 3D Vision and playing Vulkan games.
Sure, there are quite a few big profile games out there like Red Dead Redemption 2, Wolfenstein II : The new Colossus, Wolfenstein: Youngblood, Detroit: Become Human, DOOM Eternal and maybe others (these are the games that I own) but wasn't sure if I was pursuing an "old & abandoned that no-one cares about" dream. My biggest interest is being able to use HelixVision to play in Virtual Reality. I know ^_^.

As to the technology:
- This will NOT BE EXCLUSIVE to 3D Vision. If you played with my OGL3DVision wrapper, I have added support for generating Stereo3D for SBS/TB images for other display capabilities. The only part that I personally use from Nvidia's 3D Vision is the ability to DISPLAY on a 3D Vision Display or to use 3D Vision Discover Mode that is required for HelixVision.
- All the Stereorization is done manually (or coded) by me, like in my OGL3DVision wrapper. (3D Vision Automatic is the component that stereorizes DX9/DX11 applications and 3D Vision Direct is the component that presents the images to the display - and synchronised with the glasses - with a lot of caveats).

I will update the Original Post with the info I have on the progress :)

Again many thanks for taking an interest in this!

Cheers,
Helifax
Last edited by helifax on Sat Jun 06, 2020 5:23 pm, edited 1 time in total.
http://3dsurroundgaming.com:
- Home of OGL3DVision wrapper & Vk3DVision - Play your favourite OpenGL & Vulkan games in Stereoscopic 3D using Nvidia 3D Vision OR Virtual Reality using HelixVision(https://store.steampowered.com/app/1127310/HelixVision/)
- Home of some of my UHD Surround/Eyefinity/21:9/32:9 Fixes. (Or you can always check http://pcgamingwiki.com/)

Want to contribute to the development of Vk3DVision? You can check my Patreon Page for the project: https://www.patreon.com/Vk3DVision. If you still like my project but don't want to contribute monthly you can always send me a PayPal: tavyhomeppal@hotmail.com.

You can always follow me on Twitter: @OctavianVasilov

User avatar
masterotaku
Cross Eyed!
Posts: 114
Joined: Sun Sep 22, 2019 4:43 am
Which stereoscopic 3D solution do you primarily use?: S-3D desktop monitor

Re: Vk3DVision - A Vulkan 3D Vision Wrapper

Post by masterotaku »

Supporting Vulkan is starting to be a necessity, much like DX11 before 3Dmigoto was born (although I don't know how much difference in number of games there is between first game using the API and X years after, for both APIs).

Thank you for leading us towards a new 3D era, Helifax :).

bo3bber
Binocular Vision CONFIRMED!
Posts: 339
Joined: Thu Dec 27, 2012 4:22 am

Re: Vk3DVision - A Vulkan 3D Vision Wrapper

Post by bo3bber »

helifax wrote: Fri Jun 05, 2020 4:31 pmAs to the technology:
- This will NOT BE EXCLUSIVE to 3D Vision. If you played with my OGL3DVision wrapper, I have added support for generating Stereo3D for SBS/TB images for other display capabilities. The only part that I personally use from Nvidia's 3D Vision is the ability to DISPLAY on a 3D Vision Display or to use 3D Vision Discover Mode that is required for HelixVision.
- All the Stereorization is done manually (or coded) by me, like in my OGL3DVision wrapper. (3D Vision Automatic is the component that stereorizes DX9/DX11 applications and 3D Vision Direct is the component that presents the images to the display - and synchronised with the glasses - with a lot of caveats).
Awesome stuff there!

If you don't want to tie the wrapper to 3D Vision Direct, I can always add SBS support in HelixVision. It's on my list, because I also desperately want Trine and SOTTR to run in HelixVision as well.

At the moment, I'm in the middle of adding driver support, so that we'll be able to drop the Schwing hacked video driver into a game folder only, and not have to modify the system driver. So it'll be awhile before I can get to SBS, but just letting you know that is coming at some point.

Vaeltaja
Two Eyed Hopeful
Posts: 65
Joined: Sun Sep 15, 2019 4:54 am
Which stereoscopic 3D solution do you primarily use?: S-3D desktop monitor

Re: Vk3DVision - A Vulkan 3D Vision Wrapper

Post by Vaeltaja »

Glad to see you back in 3D stuff, there are lots of us who appreciate your work!

User avatar
helifax
Sharp Eyed Eagle!
Posts: 390
Joined: Tue Jan 12, 2010 5:09 pm
Which stereoscopic 3D solution do you primarily use?: Head Mounted Display (HMD)

Re: Vk3DVision - A Vulkan 3D Vision Wrapper

Post by helifax »

bo3bber wrote: Sat Jun 06, 2020 4:27 am
helifax wrote: Fri Jun 05, 2020 4:31 pmAs to the technology:
- This will NOT BE EXCLUSIVE to 3D Vision. If you played with my OGL3DVision wrapper, I have added support for generating Stereo3D for SBS/TB images for other display capabilities. The only part that I personally use from Nvidia's 3D Vision is the ability to DISPLAY on a 3D Vision Display or to use 3D Vision Discover Mode that is required for HelixVision.
- All the Stereorization is done manually (or coded) by me, like in my OGL3DVision wrapper. (3D Vision Automatic is the component that stereorizes DX9/DX11 applications and 3D Vision Direct is the component that presents the images to the display - and synchronised with the glasses - with a lot of caveats).
Awesome stuff there!

If you don't want to tie the wrapper to 3D Vision Direct, I can always add SBS support in HelixVision. It's on my list, because I also desperately want Trine and SOTTR to run in HelixVision as well.

At the moment, I'm in the middle of adding driver support, so that we'll be able to drop the Schwing hacked video driver into a game folder only, and not have to modify the system driver. So it'll be awhile before I can get to SBS, but just letting you know that is coming at some point.
Hi Bo3b,

This would be awesome!
For the traditional SBS I have to renderer the frames at full Width & Height anyway, only later to "discard" half the Width pixels to show SBS on a monitor. If I could send this information directly to Katanga this would be awesome as we would not require 3D Vision to run only for the output. I know, 3D Vision Direct it is very fast, but for HelixVision and in this case (same as the OGL3DVision wrapper) 3D Vision is not necessarily required.

Yes, having a per game hacked video driver next to the game would be great as currently I am using 3DFixManager with HelixVision to play games like SOTTR and Mass Effect: Andromeda in VR (Man this game looks gorgeous on a 3D Theatre screen especially since we also fixed TAA in the game. The resulted image is pure perfection ^_^).

Cheers!
Helifax
http://3dsurroundgaming.com:
- Home of OGL3DVision wrapper & Vk3DVision - Play your favourite OpenGL & Vulkan games in Stereoscopic 3D using Nvidia 3D Vision OR Virtual Reality using HelixVision(https://store.steampowered.com/app/1127310/HelixVision/)
- Home of some of my UHD Surround/Eyefinity/21:9/32:9 Fixes. (Or you can always check http://pcgamingwiki.com/)

Want to contribute to the development of Vk3DVision? You can check my Patreon Page for the project: https://www.patreon.com/Vk3DVision. If you still like my project but don't want to contribute monthly you can always send me a PayPal: tavyhomeppal@hotmail.com.

You can always follow me on Twitter: @OctavianVasilov

bo3bber
Binocular Vision CONFIRMED!
Posts: 339
Joined: Thu Dec 27, 2012 4:22 am

Re: Vk3DVision - A Vulkan 3D Vision Wrapper

Post by bo3bber »

helifax wrote: Sat Jun 06, 2020 9:32 amHi Bo3b,

This would be awesome!
For the traditional SBS I have to renderer the frames at full Width & Height anyway, only later to "discard" half the Width pixels to show SBS on a monitor. If I could send this information directly to Katanga this would be awesome as we would not require 3D Vision to run only for the output. I know, 3D Vision Direct it is very fast, but for HelixVision and in this case (same as the OGL3DVision wrapper) 3D Vision is not necessarily required.

Yes, having a per game hacked video driver next to the game would be great as currently I am using 3DFixManager with HelixVision to play games like SOTTR and Mass Effect: Andromeda in VR (Man this game looks gorgeous on a 3D Theatre screen especially since we also fixed TAA in the game. The resulted image is pure perfection ^_^).

Cheers!
Helifax
Oh, yes, this will be even better! When we both get a little closer to done here, let's collaborate on this and make a direct connection to HelixVision.

Previously we thought that HelixVision had no future because of the driver problem, so I wasn't planning on doing anything heroic to keep it working. However- we now have a solution to the driver problem (Thanks Schwing!), and thus with a potential longer future I'm coming back to some things I've always wanted to fix. One of which is the hooking and grabbing the backbuffer.

Currently I'm hooking into games at the same time that 3Dmigoto is hooking into games. This works OK, but 3Dmigoto is already hooked in and ready to go, and has access to everything HelixVision needs. So, as part of the change to adding driver loading support in 3Dmigoto, I'm going to circle back and also add a direct-to-HelixVision comm channel of some form, probably an IPC like a named pipe to pass the backbuffer reference I need. The driver override is going to require a special 3Dmigoto build that will always ship with 3DFM/HelixVision that I'm building out right now. Connecting the backbuffer sharing via IPC will bypass any hooking or waiting for exes or any of the other workarounds, and will make the launches for DX11 100% reliable.

We can do the same thing with Vk3DVision. We'll work out whatever the IPC is that HelixVision needs, and we can just directly pass the output buffer reference. No need to convert to SBS or Direct3D or anything else. We can do the same thing if we want on your OpenGL wrapper.

Will be super cool. :ugeek: For Vulkan and likely OpenGL- no 3D Vision required at all. :woot

User avatar
helifax
Sharp Eyed Eagle!
Posts: 390
Joined: Tue Jan 12, 2010 5:09 pm
Which stereoscopic 3D solution do you primarily use?: Head Mounted Display (HMD)

Re: Vk3DVision - A Vulkan 3D Vision Wrapper

Post by helifax »

bo3bber wrote: Sat Jun 06, 2020 4:59 pm
helifax wrote: Sat Jun 06, 2020 9:32 amHi Bo3b,

This would be awesome!
For the traditional SBS I have to renderer the frames at full Width & Height anyway, only later to "discard" half the Width pixels to show SBS on a monitor. If I could send this information directly to Katanga this would be awesome as we would not require 3D Vision to run only for the output. I know, 3D Vision Direct it is very fast, but for HelixVision and in this case (same as the OGL3DVision wrapper) 3D Vision is not necessarily required.

Yes, having a per game hacked video driver next to the game would be great as currently I am using 3DFixManager with HelixVision to play games like SOTTR and Mass Effect: Andromeda in VR (Man this game looks gorgeous on a 3D Theatre screen especially since we also fixed TAA in the game. The resulted image is pure perfection ^_^).

Cheers!
Helifax
Oh, yes, this will be even better! When we both get a little closer to done here, let's collaborate on this and make a direct connection to HelixVision.

Previously we thought that HelixVision had no future because of the driver problem, so I wasn't planning on doing anything heroic to keep it working. However- we now have a solution to the driver problem (Thanks Schwing!), and thus with a potential longer future I'm coming back to some things I've always wanted to fix. One of which is the hooking and grabbing the backbuffer.

Currently I'm hooking into games at the same time that 3Dmigoto is hooking into games. This works OK, but 3Dmigoto is already hooked in and ready to go, and has access to everything HelixVision needs. So, as part of the change to adding driver loading support in 3Dmigoto, I'm going to circle back and also add a direct-to-HelixVision comm channel of some form, probably an IPC like a named pipe to pass the backbuffer reference I need. The driver override is going to require a special 3Dmigoto build that will always ship with 3DFM/HelixVision that I'm building out right now. Connecting the backbuffer sharing via IPC will bypass any hooking or waiting for exes or any of the other workarounds, and will make the launches for DX11 100% reliable.

We can do the same thing with Vk3DVision. We'll work out whatever the IPC is that HelixVision needs, and we can just directly pass the output buffer reference. No need to convert to SBS or Direct3D or anything else. We can do the same thing if we want on your OpenGL wrapper.

Will be super cool. :ugeek: For Vulkan and likely OpenGL- no 3D Vision required at all. :woot
This! It is just awesome!!! :woot
I bet we can get the output part fixed for Virtual Reality without the 3D Vision requirement (currently in place) for both OpenGL and Vulkan games!
I still want to support displaying on 3D Vision Displays (and while it is unfortunate that 3D Vision requires Exclusive Fullscreen access to display, DX9 doesn't. I bet I can add another layer of Interop between DX11 and DX9 for 3D Vision displays - so I can present in DX9 even in non-exclusive mode on 3D Vision displays (like I do in my OGL3DVision wrapper). Maybe we don't need to go there, if I can figure out the DX11/DXGI exclusive fullscreen problem that I have ^_^).|

Having the ability to present FULL screen frames in HelixVision without 3DVision is an awesome thing! And I want to thank you for all your current work & future work on HelixVision! :geek:
I am still cracking at Vulkan and shaders ^_^ Yesterday & today was very instructive for me and I believe I learned quite a lot and have a solution for shader injection^_^. Time to try it out ^_^.

I know some people don't like the Frame Sequential approach that I am using :( But, if this proves that it works we can always, later, try and add the duplication of draw calls instead (which involves quite a lot of work to get it working ^_^).

Cheers,
Helifax
http://3dsurroundgaming.com:
- Home of OGL3DVision wrapper & Vk3DVision - Play your favourite OpenGL & Vulkan games in Stereoscopic 3D using Nvidia 3D Vision OR Virtual Reality using HelixVision(https://store.steampowered.com/app/1127310/HelixVision/)
- Home of some of my UHD Surround/Eyefinity/21:9/32:9 Fixes. (Or you can always check http://pcgamingwiki.com/)

Want to contribute to the development of Vk3DVision? You can check my Patreon Page for the project: https://www.patreon.com/Vk3DVision. If you still like my project but don't want to contribute monthly you can always send me a PayPal: tavyhomeppal@hotmail.com.

You can always follow me on Twitter: @OctavianVasilov

User avatar
helifax
Sharp Eyed Eagle!
Posts: 390
Joined: Tue Jan 12, 2010 5:09 pm
Which stereoscopic 3D solution do you primarily use?: Head Mounted Display (HMD)

Re: Vk3DVision - A Vulkan 3D Vision Wrapper

Post by helifax »

I managed to get a good start with the Shader Manager.
I can now reliably decompile from SpirV to GLSL and dump the shaders to disk across all working threads the game is using (For example: Detroit:Become Human uses 8 worker threads for shader compilation and graphics pipeline creation)
We also have access to a lot of shader reflection as you can see below.

Here is an example of how a Decompiled Shader Looks like:
1b48acd0198f77e2_VS.glsl

Code: Select all

#version 450
#extension GL_EXT_nonuniform_qualifier : require
#extension GL_ARB_shader_draw_parameters : require
#extension GL_ARB_shader_ballot : require

out float gl_ClipDistance[1];

invariant gl_Position;

struct S_MATRICES
{
    mat4 _mModelViewProj;
    mat4 _mModelViewProjPrevious;
    mat4 _mModelView;
    mat4 _mInvModelView;
};

struct unaligned_float3
{
    float x;
    float y;
    float z;
};

struct S_INDICES
{
    uint _uiObjectIndex;
    uint _uiMaterialIndex;
    uint _uiMaterialInstanceIndex;
    uint _uiLastFrameMaterialIndex;
    uint _uiLastFrameMaterialInstanceIndex;
    uint _uiPositionsBufferIndex;
    uint _uiPrevPositionsBufferIndex;
    uint _uiNormalsBufferIndex;
    uint _uiPositionOffset;
    uint _uiPrevPositionOffset;
    uint _uiNormalOffset;
    uint _uiMatricesIndex;
};

struct S_MAIN_DEFAULT
{
    S_INDICES _Indices;
};

struct S_MAIN_DEFAULT_ARRAY
{
    S_MAIN_DEFAULT _aMain[32];
};

struct S_MESH_OBJECT
{
    mat4 _mModel;
    mat4 _mModelLast;
    mat4 _mInvModel;
    mat4 _mInvModelLast;
    vec4 _vDiversityOffset;
    uint _uiSceneZoneIndex;
    uint _uiNeighborSceneZoneIndex;
    uint _uiDisplayFlags;
    uint _uiPackedLocalExposureCompensation;
    vec4 _vPortalDirAndDistance;
    int _iPickingID[2];
    float _fLocalExposureCompensation;
    float _fLocalExposureCompensationEV100;
};

struct S_MATERIAL
{
    vec4 _vErrorColor;
    float _fDepthBias;
    float _fDummy0;
    float _fDummy1;
    float _fDummy2;
    float c0;
    float c1;
    float c2;
    float c3;
    float c4;
    float c5;
    float c6;
    float c7;
    uint s0;
    uint s1;
    uint s2;
    uint s3;
};

struct S_MATERIAL_INSTANCE
{
    float c0;
    float c1;
    float c2;
    float c3;
    float _fGloubiboulga;
};

struct S_PASS_MATRICES
{
    mat4 _mViewJitteredProj;
    mat4 _mViewProj;
    mat4 _mView;
    mat4 _mInvView;
    mat4 _mJitteredProj;
};

struct S_EYE_DATA
{
    S_PASS_MATRICES _mCurrentFrameMatrices[2];
    S_PASS_MATRICES _mPreviousFrameMatrices[2];
    mat4 _mJitteredProjection[2];
    mat4 _mNoJitterProjection[2];
    mat4 _mInvViewJitteredProj[2];
    vec4 _vWorldSpaceCameraVector[2];
    vec4 _vWorldSpaceCameraPosition[2];
    vec4 _vFrameBufferScale;
    vec4 _vFrameBufferViewportSize;
    vec4 _vFrameBufferOneOnViewportSize;
    vec4 _vViewportSize;
    vec4 _vFogSubCrop;
    uint _uiAlignment0;
    uint _uiAlignment1;
    float _vCameraJitterDeltaX;
    float _vCameraJitterDeltaY;
    vec4 _vfRcpFVolumetricFogDepthTileSize;
};

struct S_CASCADED_SHADOW
{
    mat4 _mCascadeMatrix[2][8];
    mat4 _mViewSpaceToStaticShadowMapSpace[2];
    vec4 _vfCascadeShadowAttenuation;
    vec4 _vfShadowCascadeTextureTexelSize;
    vec4 _vfStaticShadowBlurRadius;
    vec4 _vfCascadeLinearZProjFactors[8];
    vec4 _vfCascadeParams[8];
};

struct S_CLUSTER_LIGHT_SETUP
{
    S_CASCADED_SHADOW _CascadedShadow;
    vec4 _vfSkinUVParamsAndNormalBias;
    vec4 _vfShadowTextureTexelSize;
    vec4 _vfDummy_SkinFresnelF0AndF90;
    uint _uiCascadedUsed;
    float _fSSSWidth;
    float _fOffsetBias;
    float _fDummy;
};

struct S_CLUSTER_INFO
{
    mat4 _mViewToClusterView[2];
    mat4 _mClusterProjMatrix;
    mat4 _mClusterInvProjMatrix;
    vec4 _vfLeftEyeToCombinedEyeVsDeltaXZ;
    uint _uiFinestMipWidth;
    uint _uiFinestMipHeight;
    uint _uiFinestMipDepth;
    uint _uiFinestMipWidthHeight;
    float _fZSliceGeomFactor;
    float _fRcpLogZSliceGeomFactor;
    float _fDummy0;
    float _fDummy1;
    float _fNearP;
    float _fInvNearP;
    float _fFarP;
    float _fClusterCoincidentWithCamera;
};

struct S_PASS
{
    S_EYE_DATA _EyeData;
    vec4 _avFrustumCorners[4];
    vec4 _vTime;
    vec4 _cFogColor;
    vec4 _vFogSetup;
    vec4 _cSunColor;
    vec4 _vSunDir;
    vec4 _vProjectionSetup;
    vec4 _vProjectionCoeff;
    vec4 _vOutputColor;
    vec4 _vfVsClippingPlane[2];
    S_CLUSTER_LIGHT_SETUP _LightSetup;
    S_CLUSTER_INFO _ClusterInfo;
    float _fIBLIntensity;
    float _fGIIntensity;
    float _fAmbiantOcclusionDirectIntensity;
    float _fAmbiantOcclusionIndirectIntensity;
    float _fNormalSign;
    int _iFogType;
    float _fSelfOcclusionDebugRatio;
    float _fEmissive;
    int _iEnableSkinSSSSS;
    int _iUseHairOpaquePrepass;
    float _fLocalSceneExposure;
    uint _uiDebugMode;
    uint _sFlags;
    float _fTAADropsSharpness;
    uint _uNeoScaleX;
    uint _uNeoScaleY;
    uint _uiDirectOverdrawFilter;
    float _fCoderTest0;
    float _fCoderTest1;
    float _fCoderTest2;
    uint _uiBakeOutput;
    float _fDefaultAmbientIntensity;
    float _fDefaultLightingIntensity;
    uint _uiOutputColor;
    float _fAARotation;
    float _fClampDirectSpecular;
    float _fNearPlane;
    float _fFarPlane;
    float _fNDFFilteringScreenSpaceVariance;
    float _fNDFFilteringThreshold;
    float _fNDFFilteringScreenSpaceVariance_EyeShader;
    float _fNDFFilteringThreshold_EyeShader;
    float _fSurfaceGradientTextureFiltering;
    float _fZero;
    uint _uDepthClamp;
    uint _uiLightDebugMode;
    vec4 _vfFragCoordToDepthTexFactor;
    vec4 _vfFragCoordToDepthTexFactor_HalfRes;
    uint _uHdr;
    uint _uiDrawMayaSwatch;
    float _fEyeRoughnessBias;
    float _fDummy1;
};

layout(set = 1, binding = 24, std430) readonly buffer stc_g_rbMatrices_Layout
{
    S_MATRICES g_rbMatrices[];
} _166;

layout(set = 1, binding = 39, std430) readonly buffer g_rbVertices_Layout
{
    unaligned_float3 g_rbVertices[];
} g_rbVertices_Buffer[];

layout(set = 1, binding = 40, std430) readonly buffer g_rbNormals_Layout
{
    int g_rbNormals[];
} g_rbNormals_Buffer[];

layout(set = 0, binding = 52, std140) uniform dyn_CONSTANT_BUFFER_BLOCK_CB_S_MAIN_ARRAY_BINDING
{
    S_MAIN_DEFAULT_ARRAY g_cbMainArray;
} _948;

layout(set = 1, binding = 33, std430) readonly buffer g_rbObjects_Layout
{
    S_MESH_OBJECT g_rbObjects[];
} g_rbObjects_Buffer[];

layout(set = 1, binding = 34, std430) readonly buffer g_rbMaterials_Layout
{
    S_MATERIAL g_rbMaterials[];
} g_rbMaterials_Buffer[];

layout(set = 1, binding = 35, std430) readonly buffer g_rbMaterialInstances_Layout
{
    S_MATERIAL_INSTANCE g_rbMaterialInstances[];
} g_rbMaterialInstances_Buffer[];

layout(set = 2, binding = 53, std140) uniform dyn_CONSTANT_BUFFER_BLOCK_CB_S_PASS_BINDING
{
    S_PASS g_cbPass;
} _1179;

layout(binding = 28) uniform sampler2D g_rb2DTextures[];

layout(location = 8) in vec4 in_uv0;
layout(location = 8) out vec4 interp_uv0;
layout(location = 21) out vec3 interp_vfVsPosition;
layout(location = 13) out vec3 interp_vfVsNormal;
layout(location = 23) out float interp_instanceID;

vec3 _7146;

void main()
{
    int _938 = gl_InstanceIndex + gl_DrawIDARB;
    int _939 = readFirstInvocationARB(_938);
    uint _2843 = uint(gl_VertexIndex);
    uint _2846 = _2843 + _948.g_cbMainArray._aMain[_939]._Indices._uiPositionOffset;
    uint _2866 = _2843 + _948.g_cbMainArray._aMain[_939]._Indices._uiNormalOffset;
    int _2885 = g_rbNormals_Buffer[_948.g_cbMainArray._aMain[_939]._Indices._uiNormalsBufferIndex].g_rbNormals[_2866] & 1023;
    int _2888 = (g_rbNormals_Buffer[_948.g_cbMainArray._aMain[_939]._Indices._uiNormalsBufferIndex].g_rbNormals[_2866] >> 10) & 1023;
    int _2891 = (g_rbNormals_Buffer[_948.g_cbMainArray._aMain[_939]._Indices._uiNormalsBufferIndex].g_rbNormals[_2866] >> 20) & 1023;
    int _7133;
    if (_2885 > 512)
    {
        _7133 = _2885 | (-1024);
    }
    else
    {
        _7133 = _2885;
    }
    int _7135;
    if (_2888 > 512)
    {
        _7135 = _2888 | (-1024);
    }
    else
    {
        _7135 = _2888;
    }
    int _7137;
    if (_2891 > 512)
    {
        _7137 = _2891 | (-1024);
    }
    else
    {
        _7137 = _2891;
    }
    vec4 _2995 = vec4(g_rbVertices_Buffer[_948.g_cbMainArray._aMain[_939]._Indices._uiPositionsBufferIndex].g_rbVertices[_2846].x, g_rbVertices_Buffer[_948.g_cbMainArray._aMain[_939]._Indices._uiPositionsBufferIndex].g_rbVertices[_2846].y, g_rbVertices_Buffer[_948.g_cbMainArray._aMain[_939]._Indices._uiPositionsBufferIndex].g_rbVertices[_2846].z, 1.0);
    vec4 _2996 = g_rbObjects_Buffer[_948.g_cbMainArray._aMain[_939]._Indices._uiObjectIndex].g_rbObjects[0]._mModel * _2995;
    vec3 _2997 = _2996.xyz;
    vec3 _3240 = vec3(g_rbMaterials_Buffer[_948.g_cbMainArray._aMain[_939]._Indices._uiMaterialIndex].g_rbMaterials[0].c0) + ((_2997 * 1.0) * vec3(0.100000001490116119384765625));
    float _3242 = _3240.x;
    vec3 _7077 = _7146;
    _7077.x = textureLod(g_rb2DTextures[g_rbMaterials_Buffer[_948.g_cbMainArray._aMain[_939]._Indices._uiMaterialIndex].g_rbMaterials[0].s0], vec2(_3242, _3240.y), 0.0).x;
    vec3 _7082 = _7077;
    _7082.y = textureLod(g_rb2DTextures[g_rbMaterials_Buffer[_948.g_cbMainArray._aMain[_939]._Indices._uiMaterialIndex].g_rbMaterials[0].s0], vec2(_3242, _3240.z), 0.0).x;
    vec3 _7087 = _7082;
    _7087.z = textureLod(g_rb2DTextures[g_rbMaterials_Buffer[_948.g_cbMainArray._aMain[_939]._Indices._uiMaterialIndex].g_rbMaterials[0].s0], vec2(_3240.yz), 0.0).x;
    vec3 _3315 = _7087 * vec3(2.0);
    vec3 _3319 = _3315 - vec3(1.0);
    vec3 _7089 = _7146;
    _7089.x = g_rbMaterialInstances_Buffer[_948.g_cbMainArray._aMain[_939]._Indices._uiMaterialInstanceIndex].g_rbMaterialInstances[0].c0;
    vec3 _7091 = _7146;
    _7091.x = g_rbMaterials_Buffer[_948.g_cbMainArray._aMain[_939]._Indices._uiMaterialIndex].g_rbMaterials[0].c4;
    vec3 _3339 = min(_7089, _7091);
    float _3341 = _3339.x;
    vec3 _7094 = _7146;
    _7094.x = mix(0.0, 1.0, pow(clamp(_3341 * 4.9997501373291015625, 0.0, 1.0), 0.5));
    vec3 _7097 = _7146;
    _7097.x = mix(2.0, 1.0, pow(clamp((_3341 - 0.20000000298023223876953125) * 1.24998438358306884765625, 0.0, 1.0), 0.5));
    vec3 _7100 = _7146;
    _7100.x = (_7094 * _7097).x;
    vec3 _7102 = _7146;
    _7102.x = g_rbMaterials_Buffer[_948.g_cbMainArray._aMain[_939]._Indices._uiMaterialIndex].g_rbMaterials[0].c5;
    vec3 _3389 = _7100 * _7102;
    float _3391 = _3389.x;
    vec3 _7105 = _7146;
    _7105.x = _3391;
    vec3 _7108 = _7105;
    _7108.y = _3391;
    vec3 _7111 = _7108;
    _7111.z = _3391;
    vec3 _3401 = _3319 * _7111;
    vec3 _3405 = _3401 * vec3(0.5);
    vec3 _3428 = _2997 + _3405;
    float _3493 = _3428.x;
    float _3494 = _3428.y;
    float _3495 = _3428.z;
    vec4 _3496 = vec4(_3493, _3494, _3495, 1.0);
    vec4 _3497 = _1179.g_cbPass._EyeData._mCurrentFrameMatrices[0]._mView * _3496;
    vec4 _3513 = _1179.g_cbPass._EyeData._mCurrentFrameMatrices[0]._mViewProj * _3496;
    vec4 _7143;
    if (_1179.g_cbPass._uDepthClamp == 4294967295u)
    {
        float _3528 = _3513.w;
        vec4 _7144;
        if ((_3513.z / _3528) > 1.0)
        {
            vec4 _7145;
            if (_3497.z > _1179.g_cbPass._fNearPlane)
            {
                vec4 _7119 = _3513;
                _7119.z = _3528;
                _7145 = _7119;
            }
            else
            {
                _7145 = _3513;
            }
            _7144 = _7145;
        }
        else
        {
            _7144 = _3513;
        }
        _7143 = _7144;
    }
    else
    {
        _7143 = _3513;
    }
    interp_instanceID = float(_938) + 0.5;
    float _2731 = _3497.x;
    float _2732 = _3497.y;
    float _2733 = _3497.z;
    vec4 _2734 = vec4(_2731, _2732, _2733, 1.0);
    float _2735 = dot(_1179.g_cbPass._vfVsClippingPlane[0], _2734);
    float _2736 = -_2735;
    gl_ClipDistance[0] = _2736;
    interp_uv0 = in_uv0;
    interp_vfVsPosition = _3497.xyz;
    interp_vfVsNormal = mat3(_166.g_rbMatrices[_948.g_cbMainArray._aMain[_939]._Indices._uiMatricesIndex]._mModelView[0].xyz, _166.g_rbMatrices[_948.g_cbMainArray._aMain[_939]._Indices._uiMatricesIndex]._mModelView[1].xyz, _166.g_rbMatrices[_948.g_cbMainArray._aMain[_939]._Indices._uiMatricesIndex]._mModelView[2].xyz) * (vec3(float(_7133), float(_7135), float(_7137)) * vec3(0.001956947147846221923828125));
    gl_Position = _7143;
}
Next part is code injection and handling uniform buffers for Stereo.

Cheers,
Helifax
http://3dsurroundgaming.com:
- Home of OGL3DVision wrapper & Vk3DVision - Play your favourite OpenGL & Vulkan games in Stereoscopic 3D using Nvidia 3D Vision OR Virtual Reality using HelixVision(https://store.steampowered.com/app/1127310/HelixVision/)
- Home of some of my UHD Surround/Eyefinity/21:9/32:9 Fixes. (Or you can always check http://pcgamingwiki.com/)

Want to contribute to the development of Vk3DVision? You can check my Patreon Page for the project: https://www.patreon.com/Vk3DVision. If you still like my project but don't want to contribute monthly you can always send me a PayPal: tavyhomeppal@hotmail.com.

You can always follow me on Twitter: @OctavianVasilov

User avatar
Blacksmith60
Cross Eyed!
Posts: 122
Joined: Thu Oct 17, 2019 10:55 am

Re: Vk3DVision - A Vulkan 3D Vision Wrapper

Post by Blacksmith60 »

I can't get my hands down !!!!!!!!

A HUGE thanks for your continued support !

User avatar
helifax
Sharp Eyed Eagle!
Posts: 390
Joined: Tue Jan 12, 2010 5:09 pm
Which stereoscopic 3D solution do you primarily use?: Head Mounted Display (HMD)

Re: Vk3DVision - A Vulkan 3D Vision Wrapper

Post by helifax »

Blacksmith60 wrote: Sun Jun 07, 2020 11:40 am I can't get my hands down !!!!!!!!

A HUGE thanks for your continued support !
^_^
On a separate note, God I LOVE Multi-threaded code! /not :geek:

New milestone!
I killed the GPU driver 100 times today! (Real count!)
I am still amazed it recovered after the 100th Device Removed hard-crash that I provoked and is still working fine! (What sorcery is this?!) :shock:
(My Windows 7 Driver crashes are still fresh in my memory! One hard crash and you literally had to reboot/reset your PC if you wanted to do anything! :roll: )
http://3dsurroundgaming.com:
- Home of OGL3DVision wrapper & Vk3DVision - Play your favourite OpenGL & Vulkan games in Stereoscopic 3D using Nvidia 3D Vision OR Virtual Reality using HelixVision(https://store.steampowered.com/app/1127310/HelixVision/)
- Home of some of my UHD Surround/Eyefinity/21:9/32:9 Fixes. (Or you can always check http://pcgamingwiki.com/)

Want to contribute to the development of Vk3DVision? You can check my Patreon Page for the project: https://www.patreon.com/Vk3DVision. If you still like my project but don't want to contribute monthly you can always send me a PayPal: tavyhomeppal@hotmail.com.

You can always follow me on Twitter: @OctavianVasilov

Shift-E
Cross Eyed!
Posts: 195
Joined: Mon Sep 16, 2019 11:26 am
Which stereoscopic 3D solution do you primarily use?: S-3D HDTV

Re: Vk3DVision - A Vulkan 3D Vision Wrapper

Post by Shift-E »

helifax wrote: Fri Jun 05, 2020 4:31 pm @all:
I really wasn't sure if people are still interested that much in 3D Vision and playing Vulkan games.
Sure, there are quite a few big profile games out there like Red Dead Redemption 2, Wolfenstein II : The new Colossus, Wolfenstein: Youngblood, Detroit: Become Human, DOOM Eternal and maybe others (these are the games that I own) but wasn't sure if I was pursuing an "old & abandoned that no-one cares about" dream. My biggest interest is being able to use HelixVision to play in Virtual Reality. I know ^_^.
This is amazing news. First off, hell yeah we are interested in playing Vulkan games in true 3D! :D
If I am ever able to play RDR2 again, but this time in TaB S3D - my head will explode :woot Second, very cool of you to proactively take a look into this...its a major step for the future of 3D gaming when it looked so bleak some months ago. I wish you all the luck in the world, and appreciate the effort and talent employed in such an endeavor.

also, didn't Star Citizen switch to Vulkan exclusively... I mean, if it ever comes out of course :lol:

User avatar
helifax
Sharp Eyed Eagle!
Posts: 390
Joined: Tue Jan 12, 2010 5:09 pm
Which stereoscopic 3D solution do you primarily use?: Head Mounted Display (HMD)

Re: Vk3DVision - A Vulkan 3D Vision Wrapper

Post by helifax »

Shift-E wrote: Mon Jun 08, 2020 7:27 am
helifax wrote: Fri Jun 05, 2020 4:31 pm @all:
I really wasn't sure if people are still interested that much in 3D Vision and playing Vulkan games.
Sure, there are quite a few big profile games out there like Red Dead Redemption 2, Wolfenstein II : The new Colossus, Wolfenstein: Youngblood, Detroit: Become Human, DOOM Eternal and maybe others (these are the games that I own) but wasn't sure if I was pursuing an "old & abandoned that no-one cares about" dream. My biggest interest is being able to use HelixVision to play in Virtual Reality. I know ^_^.
This is amazing news. First off, hell yeah we are interested in playing Vulkan games in true 3D! :D
If I am ever able to play RDR2 again, but this time in TaB S3D - my head will explode :woot Second, very cool of you to proactively take a look into this...its a major step for the future of 3D gaming when it looked so bleak some months ago. I wish you all the luck in the world, and appreciate the effort and talent employed in such an endeavor.

also, didn't Star Citizen switch to Vulkan exclusively... I mean, if it ever comes out of course :lol:
It will take quite some time to get there. I am still working on the basics parts to get to the point where we can actually start looking into injecting stereo.
But yes, it would be awesome to be able to play those games in S3D I agree :3D
http://3dsurroundgaming.com:
- Home of OGL3DVision wrapper & Vk3DVision - Play your favourite OpenGL & Vulkan games in Stereoscopic 3D using Nvidia 3D Vision OR Virtual Reality using HelixVision(https://store.steampowered.com/app/1127310/HelixVision/)
- Home of some of my UHD Surround/Eyefinity/21:9/32:9 Fixes. (Or you can always check http://pcgamingwiki.com/)

Want to contribute to the development of Vk3DVision? You can check my Patreon Page for the project: https://www.patreon.com/Vk3DVision. If you still like my project but don't want to contribute monthly you can always send me a PayPal: tavyhomeppal@hotmail.com.

You can always follow me on Twitter: @OctavianVasilov

User avatar
helifax
Sharp Eyed Eagle!
Posts: 390
Joined: Tue Jan 12, 2010 5:09 pm
Which stereoscopic 3D solution do you primarily use?: Head Mounted Display (HMD)

Re: Vk3DVision - A Vulkan 3D Vision Wrapper

Post by helifax »

I know it doesn't look like much :)
But, here is me playing with Shader: De-compilation, Injection, Re-compilation and swapping :) (No 3D in this one. Just regular 2D with shader manipulation)

I displaced all the vertex shaders on the x axis by 0.5. Oops :ugeek:
Image

One step closer :)
I can now see why most developers hate Vulkan/DX12 (all the fluff and micro-management that you have to do!) You do get "better" performance if you write your engine the right way, but there is definitely extra time to be added to developing the engine! And... now me trying to reverse-engineer it! Oh the JOY of MT! :ugeek:

Cheers!
Helifax
http://3dsurroundgaming.com:
- Home of OGL3DVision wrapper & Vk3DVision - Play your favourite OpenGL & Vulkan games in Stereoscopic 3D using Nvidia 3D Vision OR Virtual Reality using HelixVision(https://store.steampowered.com/app/1127310/HelixVision/)
- Home of some of my UHD Surround/Eyefinity/21:9/32:9 Fixes. (Or you can always check http://pcgamingwiki.com/)

Want to contribute to the development of Vk3DVision? You can check my Patreon Page for the project: https://www.patreon.com/Vk3DVision. If you still like my project but don't want to contribute monthly you can always send me a PayPal: tavyhomeppal@hotmail.com.

You can always follow me on Twitter: @OctavianVasilov

User avatar
Losti
Diamond Eyed Freakazoid!
Posts: 725
Joined: Tue Sep 17, 2019 5:30 am

Re: Vk3DVision - A Vulkan 3D Vision Wrapper

Post by Losti »

Woooooow Heli!!! Much appreciate!!!! Looking forward to your Magic!

mistersvin21
One Eyed Hopeful
Posts: 18
Joined: Mon Sep 16, 2019 3:06 am

Re: Vk3DVision - A Vulkan 3D Vision Wrapper

Post by mistersvin21 »

Helifax ! Glad to see you back :-)

User avatar
helifax
Sharp Eyed Eagle!
Posts: 390
Joined: Tue Jan 12, 2010 5:09 pm
Which stereoscopic 3D solution do you primarily use?: Head Mounted Display (HMD)

Re: Vk3DVision - A Vulkan 3D Vision Wrapper

Post by helifax »

Not sure how interesting is this to most of you, but I find it awesome:)

Made quite nice progress on the shader pipelines:
- Fixed some Decompilation errors.
- Fixed compilation errors.
- Added ability to inject all Vertex, Frag & Compute shaders.
- Made lots of fixes on the overall Shader Handling Pipeline.
- Full ability to dump the decompiled source code of all the shaders.
-> Working on generating unique shader hashes based on the pipeline information.

Got all the shaders: Vertex, Fragment/Pixel, Compute to properly decompile, inject, recompile, and swap. (Other stages like Tesselation, Ray-tracing currently not supported ^_^. Will add them later.)
I prevent the game making the original shaders and instead everything is handled by the wrapper (shader decompilation/injetion/compilation & swapping). If there is something wrong in the decompiler, recompiler or injection & swapping the game will fail (for example RTX shaders)

Here is a debug output log for example from Detroit, where I handle all the shaders as described above:
https://controlc.com/b7cf3940

Almost there with the shader decompilation, recompilation & injection!!!

And new lovely screenshot showing the vertex position displacement injection in place (0.1 on the x axis of all vertex shaders output) :ugeek:
Image
(Will definitely be a lot of shader hunting and fixing in this game ^_^, as I can tell right away we can't target all shaders like this :ugeek: )

Cheers,
Helifax
Last edited by helifax on Tue Jun 09, 2020 4:14 pm, edited 1 time in total.
http://3dsurroundgaming.com:
- Home of OGL3DVision wrapper & Vk3DVision - Play your favourite OpenGL & Vulkan games in Stereoscopic 3D using Nvidia 3D Vision OR Virtual Reality using HelixVision(https://store.steampowered.com/app/1127310/HelixVision/)
- Home of some of my UHD Surround/Eyefinity/21:9/32:9 Fixes. (Or you can always check http://pcgamingwiki.com/)

Want to contribute to the development of Vk3DVision? You can check my Patreon Page for the project: https://www.patreon.com/Vk3DVision. If you still like my project but don't want to contribute monthly you can always send me a PayPal: tavyhomeppal@hotmail.com.

You can always follow me on Twitter: @OctavianVasilov

bo3bber
Binocular Vision CONFIRMED!
Posts: 339
Joined: Thu Dec 27, 2012 4:22 am

Re: Vk3DVision - A Vulkan 3D Vision Wrapper

Post by bo3bber »

helifax wrote: Tue Jun 09, 2020 2:02 pm Not sure how interesting is this to most of you, but I find it awesome:)

-> Working on generating unique shader hashes based on the pipeline information.
Awesome in my book! Love to see the progress. Plus I also am keen to play Detroit in 3D. ;)

Re: hash function.

Awhile back I did a deep dive on hash functions for 3Dmigoto. Short story- unless you have unique requirements, use the crc32 hash function that is built into the CPU. There is a package we added to 3Dmigoto that does the crc32 that you can just grab and use.

This function is on the order of 10x faster than any other solution, and is worth the risk of possible collisions.

User avatar
helifax
Sharp Eyed Eagle!
Posts: 390
Joined: Tue Jan 12, 2010 5:09 pm
Which stereoscopic 3D solution do you primarily use?: Head Mounted Display (HMD)

Re: Vk3DVision - A Vulkan 3D Vision Wrapper

Post by helifax »

bo3bber wrote: Tue Jun 09, 2020 3:56 pm
helifax wrote: Tue Jun 09, 2020 2:02 pm Not sure how interesting is this to most of you, but I find it awesome:)

-> Working on generating unique shader hashes based on the pipeline information.
Awesome in my book! Love to see the progress. Plus I also am keen to play Detroit in 3D. ;)

Re: hash function.

Awhile back I did a deep dive on hash functions for 3Dmigoto. Short story- unless you have unique requirements, use the crc32 hash function that is built into the CPU. There is a package we added to 3Dmigoto that does the crc32 that you can just grab and use.

This function is on the order of 10x faster than any other solution, and is worth the risk of possible collisions.
Many thanks for the info! That is really awesome!
I am currently using the MurmurHash to hash: https://en.wikipedia.org/wiki/MurmurHash
However, one thing I noticed, like in OGL, Vulkan reuses tthe same shaders to generate different Graphics Pipelines. ( You don't bind individual shaders like in DX11) You bind a pipeline (that you made before) which automatically binds all the VS/FS/CS etc shaders and the layout to send data from CPU to GPU :geek:.
I am now trying to figure out "what makes a pipeline unique" and somehow reflect it in the shader hashes (and to be deterministic as Vulkan is heavily MT).

Thanks again! Will definitely look at the CRC32 from 3DMigoto!

Cheers,
Helifax
http://3dsurroundgaming.com:
- Home of OGL3DVision wrapper & Vk3DVision - Play your favourite OpenGL & Vulkan games in Stereoscopic 3D using Nvidia 3D Vision OR Virtual Reality using HelixVision(https://store.steampowered.com/app/1127310/HelixVision/)
- Home of some of my UHD Surround/Eyefinity/21:9/32:9 Fixes. (Or you can always check http://pcgamingwiki.com/)

Want to contribute to the development of Vk3DVision? You can check my Patreon Page for the project: https://www.patreon.com/Vk3DVision. If you still like my project but don't want to contribute monthly you can always send me a PayPal: tavyhomeppal@hotmail.com.

You can always follow me on Twitter: @OctavianVasilov

UnityBeing
One Eyed Hopeful
Posts: 3
Joined: Fri Dec 20, 2019 1:03 am

Re: Vk3DVision - A Vulkan 3D Vision Wrapper

Post by UnityBeing »

Congratulations old friend in having progress in Vulkan 3D . I hope we can make vulken3D a reality together. I wish you Godspeed in your endeavor. I certainly can’t wait for Star Citizen in 3D with the vulkan engine.

Kind Regards,

UB

bo3bber
Binocular Vision CONFIRMED!
Posts: 339
Joined: Thu Dec 27, 2012 4:22 am

Re: Vk3DVision - A Vulkan 3D Vision Wrapper

Post by bo3bber »

helifax wrote: Tue Jun 09, 2020 4:09 pmMany thanks for the info! That is really awesome!
I am currently using the MurmurHash to hash: https://en.wikipedia.org/wiki/MurmurHash
...
Thanks again! Will definitely look at the CRC32 from 3DMigoto!
Yep, crc32 is quite a lot faster than Murmur, I tested that one as part of my experiments. We were initially worried about the 32 bit hash maybe having collisions, but in testing some 100 games, I never saw a collision.

We needed a good hash for textures, and the hash we started with was showing up as significantly expensive. Hashing shaders is probably not going to ever be a performance problem, so we left our original sort of lame hash function in place. Since you are starting from scratch, there is no reason to use anything slow.

With textures, we very occasionally see hash collisions on weird or degenerate textures like empty textures, or all black, and put in handling to include other pieces beyond just the raw data to make them distinct.


The full pipeline being required is interesting and different. 32 bit hash would be no problem there because it's going to have so many pieces.

As an actual CPU instruction, the crc32 function is atomic, which might help the Multithreading.

Great stuff, thanks for sharing the details too.

Ixomack
One Eyed Hopeful
Posts: 34
Joined: Tue May 05, 2020 9:26 am

Re: Vk3DVision - A Vulkan 3D Vision Wrapper

Post by Ixomack »

It seems that Bloodborne PC will be using Vulkan.
Bloodborne in 3D would be really awesome !

russellk
Cross Eyed!
Posts: 122
Joined: Sun Jan 24, 2010 2:09 pm
Which stereoscopic 3D solution do you primarily use?: S-3D desktop monitor

Re: Vk3DVision - A Vulkan 3D Vision Wrapper

Post by russellk »

Call me a grumpy git but I wish people wouldn't just post and drop hints about what games they want to play in 3d.

1. There is a very long way to go and this is all one person doing this off their own back.
2. Someone then still has to fix the game.
3. This isn't the thread to talk about games, it's better left to anyone that can or is willing to offer help with the wrapper.
Win 10 1903 (Via 3dfix manager - Non DCH), 9700K, Gigabyte 2080Ti OC, BenQ XL2420T 3d surround, LG 3d OLED, 4k Projector (3dtvplay), WMR Odyssey+, WIn 19 1809 (425.31), Win 7 Pro x64

User avatar
helifax
Sharp Eyed Eagle!
Posts: 390
Joined: Tue Jan 12, 2010 5:09 pm
Which stereoscopic 3D solution do you primarily use?: Head Mounted Display (HMD)

Re: Vk3DVision - A Vulkan 3D Vision Wrapper

Post by helifax »

Ixomack wrote: Thu Jun 11, 2020 1:41 am It seems that Bloodborne PC will be using Vulkan.
Bloodborne in 3D would be really awesome !
Indeed! :3D
http://3dsurroundgaming.com:
- Home of OGL3DVision wrapper & Vk3DVision - Play your favourite OpenGL & Vulkan games in Stereoscopic 3D using Nvidia 3D Vision OR Virtual Reality using HelixVision(https://store.steampowered.com/app/1127310/HelixVision/)
- Home of some of my UHD Surround/Eyefinity/21:9/32:9 Fixes. (Or you can always check http://pcgamingwiki.com/)

Want to contribute to the development of Vk3DVision? You can check my Patreon Page for the project: https://www.patreon.com/Vk3DVision. If you still like my project but don't want to contribute monthly you can always send me a PayPal: tavyhomeppal@hotmail.com.

You can always follow me on Twitter: @OctavianVasilov

User avatar
helifax
Sharp Eyed Eagle!
Posts: 390
Joined: Tue Jan 12, 2010 5:09 pm
Which stereoscopic 3D solution do you primarily use?: Head Mounted Display (HMD)

Re: Vk3DVision - A Vulkan 3D Vision Wrapper

Post by helifax »

russellk wrote: Thu Jun 11, 2020 11:16 am Call me a grumpy git but I wish people wouldn't just post and drop hints about what games they want to play in 3d.

1. There is a very long way to go and this is all one person doing this off their own back.
2. Someone then still has to fix the game.
3. This isn't the thread to talk about games, it's better left to anyone that can or is willing to offer help with the wrapper.
It's fine ;)
I know not everyone is versed in coding and let alone reverse engineering and trying to piece together multiple pieces of tech :geek:
We all wish to play a Vulkan game in stereo3D (including me ^_^) ! So, I understand his wish!

But you are right! I am currently working on making the tool (wrapper) that allows us both to generate a image in Stereo3D and provide the toolbox so we can make fixes. I am not working or tailoring this for a specific game, but I aim to target all Vulkan games. Obviously that is a very tall order, so I'm limiting currently to test on a few games like Detroit:Become Human and some in-house apps that I made to test various things :ugeek:

Cheers,
Helifax
http://3dsurroundgaming.com:
- Home of OGL3DVision wrapper & Vk3DVision - Play your favourite OpenGL & Vulkan games in Stereoscopic 3D using Nvidia 3D Vision OR Virtual Reality using HelixVision(https://store.steampowered.com/app/1127310/HelixVision/)
- Home of some of my UHD Surround/Eyefinity/21:9/32:9 Fixes. (Or you can always check http://pcgamingwiki.com/)

Want to contribute to the development of Vk3DVision? You can check my Patreon Page for the project: https://www.patreon.com/Vk3DVision. If you still like my project but don't want to contribute monthly you can always send me a PayPal: tavyhomeppal@hotmail.com.

You can always follow me on Twitter: @OctavianVasilov

User avatar
helifax
Sharp Eyed Eagle!
Posts: 390
Joined: Tue Jan 12, 2010 5:09 pm
Which stereoscopic 3D solution do you primarily use?: Head Mounted Display (HMD)

Re: Vk3DVision - A Vulkan 3D Vision Wrapper

Post by helifax »

Detroit: Become Human rendering in :woot Stereo 3D :woot
Image
:3D

Sure, the rendering of the scene is wrong, that is simply because I put ZERO effort in trying to fix anything. (Some halos, double stereo in some places, etc :geek: )
This is the result of stereorizing everything I can! So, it is to be expected :geek:

Hope you like it!
Cheers,
Helifax
http://3dsurroundgaming.com:
- Home of OGL3DVision wrapper & Vk3DVision - Play your favourite OpenGL & Vulkan games in Stereoscopic 3D using Nvidia 3D Vision OR Virtual Reality using HelixVision(https://store.steampowered.com/app/1127310/HelixVision/)
- Home of some of my UHD Surround/Eyefinity/21:9/32:9 Fixes. (Or you can always check http://pcgamingwiki.com/)

Want to contribute to the development of Vk3DVision? You can check my Patreon Page for the project: https://www.patreon.com/Vk3DVision. If you still like my project but don't want to contribute monthly you can always send me a PayPal: tavyhomeppal@hotmail.com.

You can always follow me on Twitter: @OctavianVasilov

User avatar
Chtiblue
Sharp Eyed Eagle!
Posts: 355
Joined: Mon Sep 16, 2019 4:52 am
Which stereoscopic 3D solution do you primarily use?: S-3D HDTV

Re: Vk3DVision - A Vulkan 3D Vision Wrapper

Post by Chtiblue »

Awesome progress Helifax :woot

User avatar
Skawen
Cross Eyed!
Posts: 126
Joined: Mon Sep 16, 2019 1:36 am
Which stereoscopic 3D solution do you primarily use?: S-3D desktop monitor

Re: Vk3DVision - A Vulkan 3D Vision Wrapper

Post by Skawen »

This is amazing progress! Wish You all the best with this hard task.

thebigdogma
Binocular Vision CONFIRMED!
Posts: 207
Joined: Mon Sep 16, 2019 8:29 am

Re: Vk3DVision - A Vulkan 3D Vision Wrapper

Post by thebigdogma »

Just found this thread... awesome news!

User avatar
Losti
Diamond Eyed Freakazoid!
Posts: 725
Joined: Tue Sep 17, 2019 5:30 am

Re: Vk3DVision - A Vulkan 3D Vision Wrapper

Post by Losti »

YEAH, a vulkan 3D tool would be loving amazing ! Love to see the progress here!

User avatar
Blacksmith60
Cross Eyed!
Posts: 122
Joined: Thu Oct 17, 2019 10:55 am

Re: Vk3DVision - A Vulkan 3D Vision Wrapper

Post by Blacksmith60 »

Ohh yeah... Helifax rules again !!

This is an AWESOME project, fingers crossed for further development, but so far so good...

User avatar
helifax
Sharp Eyed Eagle!
Posts: 390
Joined: Tue Jan 12, 2010 5:09 pm
Which stereoscopic 3D solution do you primarily use?: Head Mounted Display (HMD)

Re: Vk3DVision - A Vulkan 3D Vision Wrapper

Post by helifax »

I know some people told me the framerate wasn't looking great in the above screenshots. I don't blame them and I understand totally!
In most of my screenshots I was running a debug build which takes up to 10 minutes to load! (Since every line of code is un-optimised and the debugger traces all the variables and function calls etc - and I need FULL debug information when I am developing all the pieces required: Shader Decompilation,Injection, Recompilation, CPU-GPU data transfer of Uniform Buffers and Stereo3D Rendering to 3D Vision Automatic).

One of the major things I wanted, was to get the full performance of the Vulkan game rendering in 2D, in Stereo3D.
I've been hammering this "egg" for the last 3 days (being convinced I found the culprit - only to go down a WRONG rabbit whole).
But I finally found it! ( I was convinced I was doing something, which I wasn't... guess who looked like a donkey when I found out.... Me ofc ^_^).

In any case, here is Detroit: Become Human rendering in stereo3D at (120FPS 2D, 60FPS 3D - I am using sequential frames so the 2D framerate always is /2). (Taking a screenshot always drops your FPS by 2-5 frames as it stalls the CPU sending commands to the GPU and the game rendering - hence why the 58 frames and not the full 60).
This is using a fully optimised RELEASE Build (and the game takes 15 seconds to load - just for comparison )
:woot
Image

If, before, I was getting a max of 50 FPS 3D (100FPS in 2D) in a Release Build (fully optimised), I now get the full FAT 60 FPS 3D (120FPS in 2D).
Thus, I get the 40% performance back compared to my earlier iterations :) And I am now ON PAR with the native game running in 2D - performance wise!

Hope you like it,
Cheers,
Helifax

PS:
When I say 40% increase, it's compared to the 2D version where I get up to 144FPS. Nvidia 3D Vision Automatic only goes up to 120FPS and locks there if you sync to V-sync, which I do.
If I run without the VSYNC I can get up to 144FPS in 2D and 72 FPS in 3D. As I said, the lock at 60 FPS is coming from 3D Vision Automatic and locking at Vsync.

The game was running on Ultra settings on my Alienware Area51m desktop-replacement laptop (using a full i9 9900k & RTX 2080 GPU) - which I use to test my wrapper iterations, while coding on my desktop.
After crashing the Nvidia driver 100 times and requiring to reboot the PC every single time, it became quite cumbersome to always: reboot, start Visual studio, code a bit, run the game -> crash, reboot and start all over again ^_^.
The reasons the clocks on the CPU & GPU are "lower" compared to to the normal clocks, it's because I don't want the laptop fans to kick in while coding :)
Last edited by helifax on Sun Jun 14, 2020 4:02 pm, edited 1 time in total.
http://3dsurroundgaming.com:
- Home of OGL3DVision wrapper & Vk3DVision - Play your favourite OpenGL & Vulkan games in Stereoscopic 3D using Nvidia 3D Vision OR Virtual Reality using HelixVision(https://store.steampowered.com/app/1127310/HelixVision/)
- Home of some of my UHD Surround/Eyefinity/21:9/32:9 Fixes. (Or you can always check http://pcgamingwiki.com/)

Want to contribute to the development of Vk3DVision? You can check my Patreon Page for the project: https://www.patreon.com/Vk3DVision. If you still like my project but don't want to contribute monthly you can always send me a PayPal: tavyhomeppal@hotmail.com.

You can always follow me on Twitter: @OctavianVasilov

Post Reply

Return to “NVIDIA GeForce 3D Vision Driver Forums”