Search Unity

  1. Unity support for visionOS is now available. Learn more in our blog post.
    Dismiss Notice

Graphics MF.SSGI [V1.0 LIVE] - Bridging the gap between URP and HDRP - Global Illumination & Occlusion

Discussion in 'Tools In Progress' started by Michiel-Frankfort, Nov 30, 2022.

  1. Michiel-Frankfort

    Michiel-Frankfort

    Joined:
    Sep 7, 2014
    Posts:
    218
    --------------
    Update: V1.0 is live in the store! V1.1. coming soon!
    --------------

    Hi!

    Some of you may already have been following my progress here, but I just submitted Screen Space Global Illumination for URP! This asset has some unique features such as OpenGL ES3 support and even runs on budget smartphones, WebGL and Nintendo Switch. All thanks to good-old Shader-model-3 code.

    A big thanks for @ShermanWaffleStudios allowing me to use his asset as a showcase. If you like these screenshots, please make sure to check his storepage too! Also a big thanks for my Beta-testers, all your input has been super valuable!

    Want to give it a try? Please check out my WebGL demo (Its PC targeted)
    I also have various video's online, included 3 tutorials if you want to see if this tool could work for you.
    You can find all the videos here!

    MF.SSGI - Kowloon - Alley.png

    So why Realtime SSGI? Because not all games allow for baked GI (i.e. Sim City) and it will speedup your development process quite a lot. It saves a ton of lightmaps and keeps your project lightweight.

    So what makes MF.SSGI unique?
    • Runs on DX11 | DX12 | OpenGL | OpenGL ES3 | Nintendo Switch | WebGL
    • Comes with Raymarched contact & casted shadows, creating beautiful soft occlusion.
    • If a lightsource move off screen, a Reflection-probes fallback kicks in and fills the missing GI
    • Multiple quality presets included, ready to support High-end PC's all the way to Nintendo Switch.
    • Uses Post-process volume overrides, with a ton of artistic settings to tweak
    • It has an extensive debugger, helping you to setup Raymarched shadows, Lightstrips, etc
    • Great alternative for baked GI and Lightprobes
    And to tackle most frequently asked question:
    • Yes, I plan on porting it to Built-in as well.
    • The asset was submitted yesterday (after months of work) and the current estimate 20-30 business-days for it to be approved.
    • If you want to give it a try before that, please send me a DM!
    Thank you all and spread the word!
    MF.SSGI - Kowloon - Alley.png

    MF.SSGI - V1.1 - WebGL demo scene - Compare.jpg

    MF.SSGI - BlitzGT - Factory - Car - Lightprobes.png

    MF.SSGI - Kowloon - Alley - Debug view.png

    MF.SSGI - Japan - Reflection probe fallback.png
     
    Last edited: Jan 12, 2023
  2. Michiel-Frankfort

    Michiel-Frankfort

    Joined:
    Sep 7, 2014
    Posts:
    218
  3. Kichang-Kim

    Kichang-Kim

    Joined:
    Oct 19, 2010
    Posts:
    1,003
    Hi. It looks cool. Do this work with Vulkan too?
     
    Michiel-Frankfort likes this.
  4. thelebaron

    thelebaron

    Joined:
    Jun 2, 2013
    Posts:
    837
    great trailer, cant wait to buy this :)
     
    Michiel-Frankfort likes this.
  5. Michiel-Frankfort

    Michiel-Frankfort

    Joined:
    Sep 7, 2014
    Posts:
    218
    I will give it a try! Should work to be honest, shaders don't use any fancy features, its all good-old-shader-model-3 HLSL. I will post an update once properly tested!
     
  6. Michiel-Frankfort

    Michiel-Frankfort

    Joined:
    Sep 7, 2014
    Posts:
    218
    A little status update: I'm currently 1201 in Queue for submission. I started 1361 on Wednesday, so it appears we have to wait for at least 20 business days indeed :(

    In the meantime I'm working on a new Mobile testscene with a Cornell-box (already looks amazing) and I have a whole bunch of improvements planned already for a day-1 update!
     
  7. Kichang-Kim

    Kichang-Kim

    Joined:
    Oct 19, 2010
    Posts:
    1,003
    If you can, I also want to know whether it works on iOS Metal too :)
     
    Michiel-Frankfort likes this.
  8. Michiel-Frankfort

    Michiel-Frankfort

    Joined:
    Sep 7, 2014
    Posts:
    218
    Yes for sure, if you like, you can give it a try yourself. Send me a DM and we can setup some testing
     
  9. Michiel-Frankfort

    Michiel-Frankfort

    Joined:
    Sep 7, 2014
    Posts:
    218
    Hi!

    While waiting for submission to clear: I improved the way SSGI lightdirections are handled. Its subtle, but if you look at the normal-map on the characters chest and her face definition, you can clearly tell the light comes from the right-side of the screen, where previously it was a bit 'flat'.

    Hope you enjoy it!
    MF.SSGI - New light direction system.png
     
  10. Spikebor

    Spikebor

    Joined:
    May 30, 2019
    Posts:
    278
    Don't worry about the number.
    We're in era of AI. I bet tons of those new assets are just AI made "200 icon packs" and the likes, asset store can go through them fast since there's not much to check about.
     
    Michiel-Frankfort likes this.
  11. Michiel-Frankfort

    Michiel-Frankfort

    Joined:
    Sep 7, 2014
    Posts:
    218
    Yeah I kept track of it the past few days, it averages around 75 reduction in queue a day. Perhaps with Hollidays coming submissions will slow down a bit, it appears to gain some momentum.
     
    Spikebor likes this.
  12. Michiel-Frankfort

    Michiel-Frankfort

    Joined:
    Sep 7, 2014
    Posts:
    218
    Hi all!

    I have something to test for those interested. I created a new test-demo scene, a Cornell-box with an emissie Quad as an animated light-strip. This new demo runs on Android on Vulkan and can be downloaded here:
    - With raymarched shadows
    - Without raymarched shadows


    You can also just check my video that I quickly threw together if you are curious.

    upload_2022-12-6_13-37-59.png

    The raymarched version runs steady 30 fps+ on a budget smartphone (Samsung Galaxy A52s), and without shadows roughly at 40 fps. The double-camera setup takes most of the performance away. Please send me a DM if you have it running on your smartphone and you want to share the numbers, I'm very interested what it does on various devices.

    Also I updated the WebGL demo again; this time with the new Directional-light encoding mentioned earlier. This boosts normal-maps and makes the scene look more realistic at a very little performance hit. In general the performance has increased and shadows a much cleaner / more stable in this version too.

    upload_2022-12-6_13-33-34.png upload_2022-12-6_13-34-23.png
    The image on the left has more normal-map definition and looks more natural and detailed because of it.

    This will all be part of my Day-1 update. According to Unity my position is 999 in queue, so hopefully by this rate, next week Wednesday will be launch day!

    Let me know your thoughts!
     

    Attached Files:

  13. jjejj87

    jjejj87

    Joined:
    Feb 2, 2013
    Posts:
    1,113
    Might be a good time to showcase a desktop standalone demo for HDRP. You have me very interested :)
     
    Michiel-Frankfort likes this.
  14. buFFalo94

    buFFalo94

    Joined:
    Sep 14, 2015
    Posts:
    273
    You should consider an OpenGL ES3 build, vulkan android drivers are mostly sh*t and the performance is almost everytime inferior to ES3
     
    Michiel-Frankfort likes this.
  15. buFFalo94

    buFFalo94

    Joined:
    Sep 14, 2015
    Posts:
    273
    Regarding the numbers
    32 fps with raymarched shadow
    36 fps without raymarched shadow

    Very old phone Galaxy S8
    Will probably give you more perf stats once I test on my Xiaomi
     
    Michiel-Frankfort likes this.
  16. Michiel-Frankfort

    Michiel-Frankfort

    Joined:
    Sep 7, 2014
    Posts:
    218

    Yes, good idea. I did a ES3 build in the past, interesting to see if indeed it is faster. I'll post new OpenGL builds soon
     
    buFFalo94 likes this.
  17. Michiel-Frankfort

    Michiel-Frankfort

    Joined:
    Sep 7, 2014
    Posts:
    218

    Well HDRP already has SSGI, so that's why I'm targeting URP (and later build-in) first.
     
  18. Michiel-Frankfort

    Michiel-Frankfort

    Joined:
    Sep 7, 2014
    Posts:
    218

    You were right! OpenGL ES3 is faster then Vulkan, wow did not see that coming. To be fair, its only a little bit faster, but its true indeed. I went from max 32 Fps average to 36Fps average. This should have been the other way around, but there you go...

    You can download the OpenGL-version here, with Raymarched-shadows. Let me know your results.
     
    buFFalo94 likes this.
  19. buFFalo94

    buFFalo94

    Joined:
    Sep 14, 2015
    Posts:
    273
    Indeed it's faster went from
    ~32fps to ~37-38fps

    As you said it's should be the other way around but Android manufacturers don't bother update their drivers that's the real issue you will most likely get better performance on Vulkan when comparing ES3 and Vulkan on High-end devices
     
  20. buFFalo94

    buFFalo94

    Joined:
    Sep 14, 2015
    Posts:
    273
    I just realized that phone was in power saving mode
    now the fps avg 48
     
    Michiel-Frankfort likes this.
  21. fuzzy3d

    fuzzy3d

    Joined:
    Jun 17, 2009
    Posts:
    228
    Do you think it could work in Quest 2 as well?
     
    Michiel-Frankfort likes this.
  22. Michiel-Frankfort

    Michiel-Frankfort

    Joined:
    Sep 7, 2014
    Posts:
    218
    Performance-wise; maybe, but at the moment VR is not supported. I will put stereo-rendering on the todo-list
     
    fuzzy3d likes this.
  23. Michiel-Frankfort

    Michiel-Frankfort

    Joined:
    Sep 7, 2014
    Posts:
    218
    A little status update: the submission Queue has slowed down a bit, so I think we are still 2 weeks out before its validated :(
     
    blueivy likes this.
  24. Michiel-Frankfort

    Michiel-Frankfort

    Joined:
    Sep 7, 2014
    Posts:
    218
    One more status update before we head into the holidays: The queue decrement slowed down to only few a day.

    Being stuck halfway 550 in queue, I feel Unity has dropped the ball as it has been submitted nearly 3 weeks ago. The estimate was 2 to 3 weeks, but I think end of Januari is more likely looking at the way it goes right now.

    If that turns out to be true, it would bring it to 2 full months of review time... And than it could even bounce because its the first time. I always believed the Asset-store is where Unity could battle the likes of Unreal, but as it turns out, Unity doesn't want content creators to succeed it feels. I'm greatly disappointed by this to be honest and I hope Unity can bring its team back in order early 2023.

    I hope you guys are well and I wish everyone an amazing Christmas and new year!
     
  25. Lars-Steenhoff

    Lars-Steenhoff

    Joined:
    Aug 7, 2007
    Posts:
    3,509
    I wish you great Holiday and New year too!

    And as for the slowdown Unity is not alone in this, Apple also slows down in December, Hope you get trough soon.
     
    Michiel-Frankfort likes this.
  26. Michiel-Frankfort

    Michiel-Frankfort

    Joined:
    Sep 7, 2014
    Posts:
    218
    Hi all,

    While waiting for approval, I'm now spending some time optimizing MF.SSGI. I just prototyped multi-frame reprojection and it's looking good! This allows for smoother surfaces at much lower sample-counts. I hope to update the mobile versions soon, let's see if we can achieve 60 fps on Switch with raymarched shadows
     
  27. Michiel-Frankfort

    Michiel-Frankfort

    Joined:
    Sep 7, 2014
    Posts:
    218
    Happy new year all! I wish you all the best, lets hope 2023 will be a more peaceful year.

    While waiting for Unity to clear v1.0 (has taken nearly 2 months and still 400 in queue), I'm hard at work to prep a massive day-1 update V1.1.

    Little v1.1 status update; now that reprojection is done, I'm focusing on general performance and Anti Alias quality. Already made some big gains in both areas, so I think I will do a V1.0 vs V1.1 compare video soon. A lot has happened since the initial submit;

    - Light-direction encoding: correctly lights normalmaps even in dark areas.
    - Shadow denoise improvement: less flickering and improved image stability
    - GI reprojection: using Motion-vectors MF.SSGI is now able to 're-use' the GI from previous frames. New GI will be rendered if the reprojected pixels are 'old' or are misplaced. This allows for fast moving emissive objects to be rendered correctly.
    - New AA algorithm: At very little GPU cost edged will be detected and multiple samples will be validated, resulting in ultra-sharp AA, even if the GI is rendered at 20% Screensize.
    - A ton tiny of bug fixes

    I hope you guys and galls are well, stay tuned for the update-video! Hopefully somewhere this week.

    Cheers!
     
  28. j_ho_74

    j_ho_74

    Joined:
    Aug 13, 2014
    Posts:
    24
    Hi
    really looking forward to buy your asset. Even more so if there would be a VR option ;)

    Cheers J
     
    Michiel-Frankfort likes this.
  29. Michiel-Frankfort

    Michiel-Frankfort

    Joined:
    Sep 7, 2014
    Posts:
    218
    Hi Guys, I updated my WebGL-demo using the latest V1.1 tech! On my PC (Laptop GTX 3070) I went from 70 (V1.0) to 125 Fps, with much higher shadow quality!

    In case you just want to look at some pretty pics, I have comparisons some right here. Enjoy!

    SSGI - V1.0 vs V1.1 update - 3.jpg

    SSGI - V1.0 vs V1.1 update - 1.jpg


    SSGI - V1.0 vs V1.1 update - 2.jpg
     
  30. Michiel-Frankfort

    Michiel-Frankfort

    Joined:
    Sep 7, 2014
    Posts:
    218
    Another V1.1 update: I created a new Android-build. This time only OpenGL-ES3 as (due to poorly updated drivers) Vulkan usually runs a bit slower.

    On my (budget) Samsung Galaxy A52s I achieve a max framerate of 60 fps! This used to be 30+ fps with raymarched shadows, and this time the AA and shadow definitions are much better. So check out the screenshots below or test it yourself!

    If you like to compare, here are the download links:
    - Android OpenGL - V1.0 download
    - Android OpenGL - V1.1 download (NEW)

    Have a great day!

    SSGI - Samsung demo - 1.jpg

    SSGI - Samsung demo - 2.jpg

    SSGI - Samsung demo - 3.jpg

     
    Last edited: Jan 4, 2023
    ejoflo, blueivy, Vincentin and 4 others like this.
  31. Lars-Steenhoff

    Lars-Steenhoff

    Joined:
    Aug 7, 2007
    Posts:
    3,509
    Great progress! These performance updates will be very welcome for lower end devices.

    ( And little tip: make sure to press release first when its accepted, before sending in an update for review as an update before release will put it back in the queue )
     
    Michiel-Frankfort likes this.
  32. Michiel-Frankfort

    Michiel-Frankfort

    Joined:
    Sep 7, 2014
    Posts:
    218

    Yeah Unity claims updating or re-uploading the asset will not affect the queue, but I'm not so sure indeed. So I plan to release first, then change the store-copy and explain that V.1.1 is ready and submit right after it's live like you said.
     
    Lars-Steenhoff likes this.
  33. Michiel-Frankfort

    Michiel-Frankfort

    Joined:
    Sep 7, 2014
    Posts:
    218
    :D :D :D WOW! ITS LIVE!!!! :D :D :D

    I'm super happy to report that I'm caught a bit by surprise, but it's finally available in the assets store!!!

    To all my testers and people here on the forum: Thank you for testing, great feature requests and feedback and I hope to submit the improved V1.1 early next week!

    @Spikebor created an amazing video-review of the asset. Please show him your support and check it out!

    Love you all, 2023 will be exiting!
     
  34. Spikebor

    Spikebor

    Joined:
    May 30, 2019
    Posts:
    278
    Congratulation on new release, wish you the best!
     
  35. Lars-Steenhoff

    Lars-Steenhoff

    Joined:
    Aug 7, 2007
    Posts:
    3,509
    Yes great start of the new year! Congrats on the release!
     
  36. fragilecontinuum

    fragilecontinuum

    Joined:
    Jan 12, 2020
    Posts:
    54
    I figure it's better to query beforehand, but does this work on 2022.2 ? :)
     
    Michiel-Frankfort likes this.
  37. j_ho_74

    j_ho_74

    Joined:
    Aug 13, 2014
    Posts:
    24
    Bought it.

    Looking forward to try it out.

    Cheers J
     
    Michiel-Frankfort likes this.
  38. ikemen_blueD

    ikemen_blueD

    Joined:
    Jan 19, 2013
    Posts:
    341
    freaking crazily mentally WOW haha I wait for so long a GEM like this, to make URP on par to UNREAL graphic, much much thanks. Please do not abandon it, plz keep updates ^^ CHEERS, Trần Thiết Duy
     
    Michiel-Frankfort likes this.
  39. Michiel-Frankfort

    Michiel-Frankfort

    Joined:
    Sep 7, 2014
    Posts:
    218
    Yes it does!
     
  40. Michiel-Frankfort

    Michiel-Frankfort

    Joined:
    Sep 7, 2014
    Posts:
    218
    Thank you for your support!!! V1.1 is very close to being published, so massive improvements comming soon!
     
  41. Michiel-Frankfort

    Michiel-Frankfort

    Joined:
    Sep 7, 2014
    Posts:
    218
    Wow, thank you for the kind words!
     
  42. Michiel-Frankfort

    Michiel-Frankfort

    Joined:
    Sep 7, 2014
    Posts:
    218
    Hi all!

    First of all: Big big thanks to everyone that bought MF.SSGI! Much love!!!

    V1.1 is nearly ready for submission. In the meantime I updated the WebGL demo again. Check it out!!!

    MF.SSGI - V1.1 - WebGL demo scene - Compare.jpg
     
  43. Michiel-Frankfort

    Michiel-Frankfort

    Joined:
    Sep 7, 2014
    Posts:
    218
    Hi all, V1.1.1 IS LIVE!!! (Yes, already a hot fix haha)

    It has many many improvements as mentioned before. If you want to learn more about it, I MADE A VIDEO that highlights the new tech.

    There is an upgrade-guide in the package for those that already purchased v1.0.

    Enjoy and thank you all for buying/supporting MF.SSGI!!!
     
  44. Michiel-Frankfort

    Michiel-Frankfort

    Joined:
    Sep 7, 2014
    Posts:
    218
    So to give you an idea whats next: I'm planning on improving the Reflection-probe fallbacks. Better falloff, improved visuals, etc.

    What I'm currently prototyping are 2.5 D Raymarched shadows for the reflection-probes as well. As you can see in the screenshots below, the light on the pillar in the background (center) is now correctly occluded, same goes for the floor behind the barrels and barrels at the back of the pack.

    Note: This is just rapid prototyping so the result is a bit subtle, I'm sure the final version will look even better!

    The reason I want this is because this will make large open scenes (i.e. city streets) look more natural as they often have a lot of reflection-probes hanging around.

    Raymarched Shadows ON:
    upload_2023-1-18_9-9-30.png


    Raymarched shadows OFF:
    upload_2023-1-18_9-8-35.png

    SSGI completely off:
    upload_2023-1-18_9-10-44.png
     
    blueivy and Vincentin like this.
  45. Michiel-Frankfort

    Michiel-Frankfort

    Joined:
    Sep 7, 2014
    Posts:
    218
    Another example of the prototype:

    Reflection probe fallback Raymarch OFF (with exaggerated intensity for compare)
    upload_2023-1-18_9-21-9.png

    Reflection probe fallback Raymarch ON
    upload_2023-1-18_9-22-34.png
     

    Attached Files:

  46. JoergHofmann74

    JoergHofmann74

    Joined:
    Oct 31, 2017
    Posts:
    17
    Hi
    cool to see you progress and looking forward to the new features. I really like your asset.
    For the future versions, could you please provide more samples like indoor, outdoor szenarios?
    And of course I would like to have MF.SSGI in VR :)

    Cheers J
     
    Michiel-Frankfort likes this.
  47. Michiel-Frankfort

    Michiel-Frankfort

    Joined:
    Sep 7, 2014
    Posts:
    218

    By popular request: Here you go!

    MF.SSGI - Sci-Fi - 1.gif

    MF.SSGI - Sci-Fi - 2.gif

    MF.SSGI - Sci-Fi - 3.gif

    MF.SSGI - Sci-Fi - 4.gif

    MF.SSGI - Sci-Fi - 5.gif
     
    lukasynthetic, blueivy and Vincentin like this.
  48. Michiel-Frankfort

    Michiel-Frankfort

    Joined:
    Sep 7, 2014
    Posts:
    218
    Ill capture a 'How-to' video soon using this asset or something simular. It litterly took me 15 minutes to set it up. I need permission from the creator though...
     
  49. JoergHofmann74

    JoergHofmann74

    Joined:
    Oct 31, 2017
    Posts:
    17
  50. mgear

    mgear

    Joined:
    Aug 3, 2010
    Posts:
    9,268
    Looks great!

    +1 for VR support (desktop vr).


    *getting these errors on new project (2021.3.12f1+ URP 12.1.7)
    Shader error in 'MF_SSGI/ExpandVertices': Couldn't open include file 'Packages/com.unity.render-pipelines.core/ShaderLibrary/Color.hlsl'. at line 731
    Shader error in 'MF_SSGI/SSGIObjects': Couldn't open include file 'Packages/com.unity.render-pipelines.core/ShaderLibrary/Color.hlsl'. at line 719
     
    Last edited: Jan 19, 2023