Search Unity

  1. If you have experience with import & exporting custom (.unitypackage) packages, please help complete a survey (open until May 15, 2024).
    Dismiss Notice
  2. Unity 6 Preview is now available. To find out what's new, have a look at our Unity 6 Preview blog post.
    Dismiss Notice

Will we ever see a truly unified global illumination system?

Discussion in 'General Discussion' started by imaginaryhuman, Apr 1, 2015.

  1. imaginaryhuman

    imaginaryhuman

    Joined:
    Mar 21, 2010
    Posts:
    5,834
    Ok so picture this. One system of light (like real life). The light can produce hard and soft shadows. The light can produce radiosity. The light can reflect off dynamic objects. The light automatically produces ambient occlusion and self-shadowing within surfaces. Unlimited dynamic light sources (within reason maybe). All produced by a single system in realtime.

    I don't know if such a system exists. It seems we hack together different parts - one part for shadows, a part for light probes, a part for radiosity, some other part for ambient occlusion, some amount of baking/pre-computation, some baked light in textures etc. What will it take to make a single system that produces all possible desirable lighting/shadowing in a single unified manner, environment-wide, in realtime? Is this only perhaps possible with radiosity-supporting ray-tracing?

    Imagine all you have to do is put objects in your scene, place some lights, and you get instant perfect lights and shadows and all the rest of it.
     
  2. dovahkiin009087

    dovahkiin009087

    Joined:
    Nov 18, 2014
    Posts:
    10
    Well first your machine would have to be ridiculously good to instantly support the features in realtime with no frame lag so you can edit and design. I would say that when we start designing in stacked layers it could eventually happen in real time.
    Like lets say your working with dynamic models and a sun that rotates constantly
    Load a shadow layer, pre render,
    then a light probe generation sequence that needs to be rendered along with the sun in every step,
    then a radiosity layer thats pre rendered in buildings and certain structures then constantly refreshed along with the light probes,
    then an ambient occlusion generation that is semi constant, meaning the light can gradually increase or decrease due to the time of day or the area you walk or run or fly or etc into,
    then a constant pre render system that uses the gpu compute to help aid the process of smooth rendering, not game quality in real time editing, but the realism could be adjusted dynamically within the settings or the game, like the render settings or the preferences of the game export, something like that.
    I would say that a process such as this is awhile, maybe a year, maybe two away, from becoming real, if a sysetm such as mine could be accomplished
     
  3. the_motionblur

    the_motionblur

    Joined:
    Mar 4, 2008
    Posts:
    1,774
    I'd already be happy if we could even just start by settling on a universal normal mapping format to begin with.
     
    carking1996 likes this.
  4. dovahkiin009087

    dovahkiin009087

    Joined:
    Nov 18, 2014
    Posts:
    10
    id be extremely happy for like a script generator type thing. im gonna go to college for gaming this fall, but scripting is a heavy low point.
     
  5. Deleted User

    Deleted User

    Guest

    It's a good question, but no I doubt it any time soon. Anything like real-time photon mapping would be absolutely awesome, but impossible in games due to hardware.

    Nvidia's VXGI looks nice, still a little heavy though.
     
  6. imaginaryhuman

    imaginaryhuman

    Joined:
    Mar 21, 2010
    Posts:
    5,834
    So, various hacks and 'special cases' for the next few years at least then.
     
  7. Whippets

    Whippets

    Joined:
    Feb 28, 2013
    Posts:
    1,775
    the ultimate photon particle system
     
  8. Deleted User

    Deleted User

    Guest

    Well what are you trying to achieve? A lot of technical solutions out there help you to create real time "realistic" looking games which aren't far out from a true lightmapped solution. Sure it'll never quite be as good but still, it can come pretty close.

    For example this is realtime in UE4:



    Trick is how to pull this off in Unity? Which as a whole us a lot of work to the entire pipeline. Firstly in UT4 I was playing around (or mainly researching) a TDR+ solution instead of LPP, I experimented with SSR, I tried to follow all shading models close to UE4's choices:

    https://de45xmedrsdbp.cloudfront.net/Resources/files/2013SiggraphPresentationsNotes-26915738.pdf

    The final things to do before we hit limits and problems with UT4, was to figure out a way to use approximation GI (whether LPV, or irradiance volumes) before working on improving some of the post. It kind of all fell by the wayside towards the end but I was making progress at some point.

    Now for realtime, UE4 also implemented some other very interesting features which I'm still trying to figure out. One is the use of distance field mesh's to create good looking ambient occlusion based upon skylights. Pre-baked in editor of course (but run in realtime), in short the DM has to be built. Also the use of RT shadows which is split at a variable distance, to offset the heaviness of cascade shadow maps. The other thing I'm interested in is their latest DFAO implementation, which I've not even begun to look at yet.

    All very interesting stuff, but ultimately didn't aspire to much for one reason or another (performance, half finished etc.). But the point of it is, it's possible to get it VERY near but in Unity 4 at least it was too much work.

    I was looking at Jove's implementation, it looks pretty spot on to me and a lot better in places than what I managed to achieve.
     
    Last edited by a moderator: Apr 1, 2015
  9. AcidArrow

    AcidArrow

    Joined:
    May 20, 2010
    Posts:
    11,941
    You forgot to ask for a "make game" button. :p
     
  10. Tomnnn

    Tomnnn

    Joined:
    May 23, 2013
    Posts:
    4,148
    I wouldn't mind a version of global lighting that didn't break when ever you loaded a scene with Application.LoadLevel.

    Downloading 5.0.1 now, maybe it's fixed?
     
    orionburcham likes this.
  11. imaginaryhuman

    imaginaryhuman

    Joined:
    Mar 21, 2010
    Posts:
    5,834
    Well what I'm asking for is a simple, one solution does everything kind of approach, which does away with all the separate pieces. But I suppose there is an argument for... what does it matter, if the end result is the same. Other than that it's more elegant? ... but it does seem like I can't just throw objects into the scene and have them be instantly global illuminated, radiosity, reflective, lit/emissive, with beautiful realistic shadows and occlusion and all that, just 'automatic', behaving like it's a completely unified system, without me having to set things up, bake things, fiddle with settings, bla bla bla.
     
  12. hippocoder

    hippocoder

    Digital Ape

    Joined:
    Apr 11, 2010
    Posts:
    29,723
    Yeah, it's called path tracing and it'll be common place in 10 years, generally replacing most if not all traditional techniques because compute shaders will be insanely fast and tools will have evolved.

    It's available now but you require an expensive GPU for game framerates. That's why I figure it'll be standard (also on mobile) in 10 years. IMHO it's the smart engine company that recognises it this soon.
     
    Kiwasi likes this.
  13. Tomnnn

    Tomnnn

    Joined:
    May 23, 2013
    Posts:
    4,148
    Sounds like something worth discussion in the topic about speculation about the end of Moore's law. It'd be funny (except for UT and others) to invest in a technology that could be deemed impossible :p

    Anyway, path tracing is scrub-ish compared to the lighting techniques and algorithms the GPU & processes that run my dreams. I can have an infinite loop of light voxels reflecting off every vertex of every mesh blending & multiplying the RBG value of each mesh and it still doesn't drop below infinity FPS. And that's on top of running Find every frame to move objects around to assemble the landscape (lag free voxel terrain sculpting with insane resolution).

    Moore's law might end before dreams & VR are indistinguishable :D
     
  14. Kiwasi

    Kiwasi

    Joined:
    Dec 5, 2013
    Posts:
    16,860
    Hardly ultimate. To get the full effect you'll need a system that acknowledges the dual nature of light as both a particle and a ray. I should just be able to fire an xray at a model and get a coherent diffraction pattern on the other side.

    Yeah, games are all about faking it. I'd expect things like path tracing will continue to make our fakery better. But ultimately we are still going to need to fake things somewhere.
     
  15. zendorf

    zendorf

    Joined:
    Mar 11, 2013
    Posts:
    25
    What you are asking for is a "realtime" pathtracing system. The closest you can currently get to this for a commercial solution is Brigade from Otoy(the makers of Octane renderer). GPU's are still way too slow to utilise this without lots of noise but it will happen in the near future, especially if a game utilises cloud rendering of multiple GPU's. There was a nice demo of Brigade at the recent GTC:

     
  16. imaginaryhuman

    imaginaryhuman

    Joined:
    Mar 21, 2010
    Posts:
    5,834
    Looks gorgeous! Yes please.
     
  17. imaginaryhuman

    imaginaryhuman

    Joined:
    Mar 21, 2010
    Posts:
    5,834
    The way I see it, graphics hardware at the moment is entirely backwards from how it needs to function to do raytracing. We submit geometry once and that turns into fragments in screenspace and gets rendered... but what needs to happen is we sort of start at the end pixel and work backwards, when the ray hits an object it has to set up like a mini camera on the surface of the object aligned to the normal and then `look at` the whole rest of the scene again to see what it can see, and onwards... each time having to submit the entire scene to do this.... ie really you have to hold the whole scene data in memory accessible by the gpu then fire the rays into it to discover objects. I guess when compute shaders are more commonplace this may become more possible.