Search Unity

  1. Get the latest news, tutorials and offers directly to your inbox with our newsletters. Sign up now.
    Dismiss Notice

[-50% SALE !] Global Illumination Proxy - Fast fully real time GI, Zero baking, Mobile optimized,IBL

Discussion in 'Assets and Asset Store' started by nasos_333, Aug 9, 2014.

  1. nasos_333

    nasos_333

    Joined:
    Feb 13, 2013
    Posts:
    9,501
    I am not aware of anyone yet, but considering it only uses standard Unity point lights, it should be compatible (as long as Vita has no issue with Unity point lights, that is).

    I will be releasing an even more optimized and specifically for mobile outdoors scene in the next update, with pre-defined settings to allow for minimal bounce light creation.
     
  2. blackbird

    blackbird

    Joined:
    Aug 9, 2011
    Posts:
    538
    does the render imporves like in jove system ?
     
  3. nasos_333

    nasos_333

    Joined:
    Feb 13, 2013
    Posts:
    9,501
    It improves the overall scene shading in the sense the scene is better lit, but is not a different rendering method like Jove.

    That said, it also supports Jove point lights, so you can use it along with the Jove system.
     
  4. nasos_333

    nasos_333

    Joined:
    Feb 13, 2013
    Posts:
    9,501
  5. nasos_333

    nasos_333

    Joined:
    Feb 13, 2013
    Posts:
    9,501
    The offer is still going strong. Get GI Proxy at half price !!! until the end of the year.
     
  6. nasos_333

    nasos_333

    Joined:
    Feb 13, 2013
    Posts:
    9,501
    Grab GI Proxy for half price for a few more days.

    The offer will last until end of December.
     
  7. nasos_333

    nasos_333

    Joined:
    Feb 13, 2013
    Posts:
    9,501
    The review probably wont be done today, so the pack should be half price for a few more days !!! Enjoy :)
     
  8. Deleted User

    Deleted User

    Guest

    I'm interested at this current reduced price point. However, my project is DX11 only, and I see you recommending on this thread to only use this on non-DX11 games. Any particular reasons for this?
     
  9. nasos_333

    nasos_333

    Joined:
    Feb 13, 2013
    Posts:
    9,501
    I dont recall the reason, could you link me to the quote, or post it below ?

    In general i dont think there should be any issue, the system uses the standard Unity point lights, so there is nothing that would not run on every platform.

    The system is made for compatibility and i suppose will run fine if DX11 mode is ok with point lights. I have also included a Jove script that can allow the use of Jove point lights, bringing it to a whole new level.

    As an extra note, the pack is also included whole in Sky Master ULTIMATE version, which is also on sale. I would recommend going for that pack instead, since the GI is also integrated in a full day/night cycle system, besides the numerous other perks of the pack.

    There is also the non ULTIMATE version os Sky Master, that does not include the GI Proxy pack or the Particle Dynamic Magic powered effects, but is cheaper, so there is also the option to combine the two packs later if needed.
     
    Last edited: Jan 22, 2015
  10. Deleted User

    Deleted User

    Guest

    Great to know that it works on DX11. I couldn't see a technical reason it wouldn't work based on your description of how the system works, so I figured I'd directly ask you. I'm glad that I did. Thanks for clarifying!
     
  11. nasos_333

    nasos_333

    Joined:
    Feb 13, 2013
    Posts:
    9,501
    The quote probably meant the DX11 system for GI that was available at some point at the store :), it is a bit confusing as i wrote it :)

    The system will work with Jove as well, so will be a lot better with DX11 in that regard. Also aside the real time gobal illumination, it is a great system to spread lights for lightmapping with a GI arrangement. The trick is to copy the bounce light pool in play mode, after having the right result and paste it to the scene for the baking.

    There is also a hero follow mode that will make bounce lights hit around the hero in an adjustable range, for extra optimization in bigger levels.
     
  12. thanhle

    thanhle

    Joined:
    May 2, 2013
    Posts:
    143
    it work with objects have been render lightingmap ?
     
  13. nasos_333

    nasos_333

    Joined:
    Feb 13, 2013
    Posts:
    9,501
    The system uses standard Unity point lights to emulate the GI, so everything that works with point lights will work with it. I dont know or can guarantee if point lights can be applied over lightmapping though, as i have not done lightmapping before, but i would assume they do, as the lightmap is just a texture.

    One use of the system could be the spread of lights to create the lightmapping as well, only then it would be a static GI. Lightmapping itself is not suitable for real time GI and the system is made with real time dynamic GI in mind, but can be used to bake the GI to lightmaps, by spreading your lights in play mode, copy the bounce light pool while in play mode and paste it in the scene, then do the lightmaping with them.

    One other way i can image the system could be used with the lightmap lights, is to apply the script to a lightmap light and let it spread GI bounce lights in real time, this way you could have the benefit of the lightmap and bounce lights be dynamic.
     
    Last edited: Feb 1, 2015
  14. nasos_333

    nasos_333

    Joined:
    Feb 13, 2013
    Posts:
    9,501
    ARTnGame SALE will end in a few days.

    GI Proxy 50% off for a limited time

    Advanced FX Creator (PDM+GI Proxy bundle) - (50% off - $40 instead of $80)
    Also check this thread for other assets on sale (Sky Master ULTIMATE (includes GI Proxy), InfiniTREE, Particle Dynamic Magic)

    The normal prices of the packs will be submitted this monday and thus the sale will last a few more days, until the review process in the store is finished. I assume it could take up to another 3 days after monday, but the sale officially ends monday.
     
  15. RockSPb

    RockSPb

    Joined:
    Feb 6, 2015
    Posts:
    111
    Hello!
    Looks realy great and I think its first working Gi sollution in Unity store)
    I woud like to buy your asset, but I have a couple questions for.
    So you use cheap piont lights, but how about light liaking?
    Can I use your solution for indor scenes?
    Is it works correct for many rooms with diffenet lighting?

    Thanks!
    ps sorry for my english
     
  16. nasos_333

    nasos_333

    Joined:
    Feb 13, 2013
    Posts:
    9,501
    Hi,

    Since i use simple Unity point lights, the leaking will be limited by the ability of Unity to cut off these lights. That said, i do have many options for the light placement, so if a light needs to be further away from a wall it hits, it can be done with an offset to either the normal of the hit point or a simple height. The radius of the lights can also be adjusted, to better match the wall thickness.

    I use this offset method to also use less more central lights in ourdoors when needed.

    So the options in summary are:

    - In the window case, there is a hero mode that can essentially eliminate lights that are not close to your hero, so it is possible using this technique to remove the bounce lights when far away from the area they hit. For this to work you will need a collider in the walls that sun looks at to stop the rays there. Also there are rules that eliminate the lights, if they are further away from the hero etc

    If you will use the system in a dynamic scenario, then lights get created and removed as you move about, so normally a bounce light in one room will not be there when entering the other one, so there would be no leak by default.

    - If the sun bounce lights are required, you can use the various offset and radius modes, to control the lights so that wont pass through the wall.

    The system, besides its main dynamic nature, can also be used to place lights for baking lightmaps.

    I hope these help.

    EDIT: I created a small demo with your case and will post pics soon. Also another note, this system is included in Sky Master ULTIMATE edition, in case you have the pack or would prefer to get it along with the Sky solution.
     
    Last edited: Feb 16, 2015
  17. nasos_333

    nasos_333

    Joined:
    Feb 13, 2013
    Posts:
    9,501



    Here is a quick demo for the similar case.

    I started with a scene i had that had the light radius very high and there was some leaking (the pics to the right are without GI Proxy), then i reduced the light radius and added a bigger offset from the hit point along normals and the leaking is almost gone, there is some light near the doorway, but that is normal since it is directly connected to the main room.

    I have pics looking at the window and looking at the room next to the one with the window, with and without GI Proxy (to see exactly what lighting comes from Unity and what from the bounce lights)

    Notice how the lights in the second case are more centralized and away from the floor, while in the first almost touch on the surfaces. Depending on your wall thickness, these distances can be optimized so lights are as close to walls without their radius passing over the adjustent walls.

    Let me know what you think. Also keep in mind this was a very fast demo i put together in a few minutes and optimized with a few clicks. The system offers a lot of customization and a big number of parameters you can play with, so this is just one possible solution of the many available.

    EDIT: Another note, on the color difference. The optimized scene has lower radius lights and away from the hit point, so lights that hit the outer wall part in the first case would leak inside as the extra yellow, while in 2ond case that extra light does not reach inside the room.

    If the external lights are not desired, you can also code an elimination method based on the tags of outer walls (like not create bounce lights if the hit surface has a "outer wall" tag, inside the raycaster. There is a plan to provide an automated way to handle side lights in the next update.

    The height cut off for lights created on the roof etc is already an option in the script.
     
    Last edited: Feb 16, 2015
  18. RockSPb

    RockSPb

    Joined:
    Feb 6, 2015
    Posts:
    111
    Oh! Thank you for the detailed answer to the question!
    So, I think that I understat you.
    I do not quite accurately explained the request. Becouse of I would use to this lighting for indoor and outdoor together.
    It must be a compromise.

    Have a question about the right position of sun and hero.
    Right now they are in 0 0 0 (direct Light ofset vertical)
    But lights casts only in half area


     
  19. RockSPb

    RockSPb

    Joined:
    Feb 6, 2015
    Posts:
    111



    need a lot of optimitation, but looks cool!)
     
  20. nasos_333

    nasos_333

    Joined:
    Feb 13, 2013
    Posts:
    9,501
    About the hero mode, there is a x,z offset parameter that will center the lights in relation to the world and your hero. Note that this will not rotate the solution, so if it is a full 3D game it is best to center the grid.

    In order to debug the placement offset, enter play mode and play with the offset to see how it moves the lights, then copy the parameters after exit play mode.

    If you are going to use so many lights, i would suggest Jove as a solution, which can handle 500 point lights.

    It is DX11 only though. For such detail with point lights will need a huge lot of optimization and cut offs, since these could create a lot of fps drop, especially if many are active all at once and not in deferred mode.

    Some solutions are

    1. Play with the grid, the distance of the grid is adjustable, so these lights can be further away from each other and less, then cover with light radius.

    2. Play with offset distance and lights radius, make the grid sparser and increase light radius to cover for the missing in between lights, plus place them further above to better spread the light.

    3. Definitly use hero mode in outdoors, this grid will follow the hero and create GI only around him. In indoors you could remove the hero dependency i guess, but if there is a connected world, it is best to always use it.

    Let me know the progress, you scene looks amazing :). Do you work in Unity 5 Pro and deferred btw ? With so many lights i would expect a bigger drop in fps, unless the limit of concurrent lights is set low.
     
  21. RockSPb

    RockSPb

    Joined:
    Feb 6, 2015
    Posts:
    111
    This scene is for house creator like Sims, so house is a center of scene and rendered inside and outside all the time.
    I reduce count of lights, but now its start flickering like hell. (second bounce on)
    Ps. We use 4.6.1 (5 is still not enough stable for production), that have terreble Deffered render imo
    .
     
  22. nasos_333

    nasos_333

    Joined:
    Feb 13, 2013
    Posts:
    9,501
    I would try playing with light speed if there is flicker, the intensity increase and elimination time will smooth out the sudden instensity changes. Also allow lights to remain a bit longer around, by adjusting the elimination distance, this will smooth out the effect even more.

    There are many more options for smoothing, like a follow last light hit option, for fast moving spot lights (used in the room demo), color change speed adjustment and more.

    Generally each case needs a specific balance to work well. The house in your case should be treated as an outside world i suppose and with hero mode can have a thick enough grid.

    EDIT: Also when using sparse lights, adjust light radius higher to even further smooth out the effect.
     
    Last edited: Feb 16, 2015
  23. RockSPb

    RockSPb

    Joined:
    Feb 6, 2015
    Posts:
    111
    Hello!
    Im in process of adjusting lights. Looks better and better).
    I think we need to disable and enable script when something is change in scene (Eg position of sun, color of wall, etc)
    Because of tracing spend a lot of time for calculating, but it is unnecessary every momet.

    So I would like to ask you, is it possable increace tracing speed of second bounce?
    And how can I limit second bounce light count?
     
  24. RockSPb

    RockSPb

    Joined:
    Feb 6, 2015
    Posts:
    111
    After several tests I have an error (when Second bounce is on)
     
  25. nasos_333

    nasos_333

    Joined:
    Feb 13, 2013
    Posts:
    9,501



    Hi,

    I cannot debug this easilly, since i never had an error while extensively testing the system. If possible you should send me a test scene where this happens or provide some more info, like any changes to the code etc

    If this is the code in the line it happens
    Code (csharp):
    1.  
    2. Destroy (Lights[k].gameObject);
    3.  
    I would add a null check, like this
    Code (csharp):
    1.  
    2. if( Lights[k].gameObject != null){
    3.     Destroy (Lights[k].gameObject);
    4. }
    5.  
    Normally this should not be needed though, so to find the exact cause is rather hard without the exact scene and situation it happens. One cause would be the bounce lights getting controlled by another script that either deletes them or disable before the light manager can manage them properly.

    About the 2ond bounces, there is a parameter "point_light_radius_2ond" that govers the distance of the 2ond bounce raycasts. There is also density control for the casts using the Hor_directions and Ver_directions parameters, those govern the grid thickeness of the spherical casts.Note that this number is hardcoded after entering play mode, so should be changed before entering play mode to the desired.

    To debug the casts for 2ond bounces, enable the "Debug 2ond" option and put the update interval to zero or very low, so the lines can be clearly seen. Note that the update rate will change the system behavior, so when making the final one have the final update enabled, to get the exact look at that rate.

    I hope these help, let me know of the progress :)

    EDIT: About the sun, i have used the system effectively in Sky Master with a simple disable of the bounce light pool after the sun drops below a certain height level. This addition will come to the next version of GI Proxy.

    About the wall color, normally the system can grab the change of colors, check the room scenes, change the wall colors and should change the bounce color.

    EDIT2: Posted a pic with the dynamic color change grab, i just changed the color of the box to blue and bounce lights grabbed the change automatically. Also the pic shows the settings used to get this result.

    EDIT3: And another pic from the room, notice the color change on the fly as we move across the wall, the color is also lerped based on the chose color speed.

    EDIT4: Note the parameter "hit_light_distance", this will eliminate the previous light bounces sooner if set lower, so the new bounces will be updated together with the new light casts. Lower this to get even better and more accurate light grab. It should be balanced between creating many lights and grabing more detail.

    EDIT5: Here are some videos showing the color grab in action


     
    Last edited: Feb 18, 2015
  26. RockSPb

    RockSPb

    Joined:
    Feb 6, 2015
    Posts:
    111
    I just delete the light and add new one and errors gone!
    Found the reason of error. Its occured when I copy script settings from game mode.

    U don understand me about change of colors!
    Its work perfectly, but I want to stop script when nothing change in scene (becouse its house editor and light calculation need only when something change). High settings eats up a lot of cpu time
    Think its not harder and we will be able to use more accurate gi (with more pointlights).

    Thank u for response!
     
  27. RockSPb

    RockSPb

    Joined:
    Feb 6, 2015
    Posts:
    111




    Its test house geometry from very early alpha version (just for material and location tests), but looks very impressive in my opinion)
     
  28. nasos_333

    nasos_333

    Joined:
    Feb 13, 2013
    Posts:
    9,501
    The script keeps temporary lists with the created bounce lights, so it will create an issue when copied from game mode for sure.

    I see what you mean about the calculations, perhaps you could define a static case when sun is not moving for example or copy the light pool and create a light map or even use the lights are they are, if they are not many.

    Unity 5 Pro and deferred mode would help a huge lot when having more lights too.

    The script itself though does not take up that much, the lights are the problem imo. Remember to disable all debug options and play with the update rate as well, this will update the script logic less regularly.

    I can think of many more optimizations too, but most are per case.

    I am glad it now works without issues :), hope you get the exact look you want with the system, let me know for any other questions.

    A review for the pack would be greatly appreciated too.

    EDIT: WOW, i just saw your pics above !!!! That looks amazing :). I have not used the pack with Unity Pro, but i am certain some Pro filters could further enchance the GI effect as well. I will try to offer some insight for this now that i have Unity 5 Pro (the version for asset developers for a limited time).

    EDIT 2: I recall that when i needed to copy the script from game mode, i turned the light to the sky so the light pool was totally emptied and then could copy the script without problem. You can try that method.
     
    Last edited: Feb 18, 2015
  29. nasos_333

    nasos_333

    Joined:
    Feb 13, 2013
    Posts:
    9,501


    Normal price has been submitted to the store and will be up in a few hours (or days).

    Make sure to grab the asset while in discount !!!


    GI Proxy is the perfect companion to Unity 5 as well, it does not need any baking and besides adding an extra real time flavor to the Unity 5 GI (or artistic effects, or be used in scenes that baking can take very long) it can handle real time GI from spot and point lights, complementing Unity 5 GI.
     
  30. RockSPb

    RockSPb

    Joined:
    Feb 6, 2015
    Posts:
    111
    Hello again!
    I think there is another problem with GI.
    All point ligths cast specular highlights on the materials, and when material is shiny this looks realy strange.
    Maybe its posable to create point light that affect only to diffuse?
     
    Last edited: Mar 6, 2015
  31. nasos_333

    nasos_333

    Joined:
    Feb 13, 2013
    Posts:
    9,501
    Unfortunately there is no way to alter that easilly, since the system is not able to create new lighting approach than the one Unity has. It is limited by the way unity point lights work.

    I can definitly look into ways to work around this, but i dont have a ready solution. It would be great if you could provide a sample scene, to work specifically one and try to solve it.

    One solution would be to use a lower light number and a bigger offset from surfaces, so the specular effects wont be as evident.
     
  32. RockSPb

    RockSPb

    Joined:
    Feb 6, 2015
    Posts:
    111
    We decide just almost kill spec highligths.Anyway its incorrect in deffered mode...

    (test it today) No, they don't=) every light still cast several drawcalls ((

    PS
    How soon do you plan to do this?
     
  33. nasos_333

    nasos_333

    Joined:
    Feb 13, 2013
    Posts:
    9,501
    The official update will take some time to do and test, but i can add it as priority and try to do this feature next week and send a version with this added functionality.
     
  34. IanStanbridge

    IanStanbridge

    Joined:
    Aug 26, 2013
    Posts:
    334
    Rockspb you might want to use the Jove 2 renderer rather than the unity 5 deferred one if you need more accurate spot lights for dynamic GI. It is currently being changed into a photo metric clustered rendered and so can solve those issue with specular highlights.

    I'm currently testing an unreleased beta version of it at the moment. The new versions link to proxy gi has stopped working because it now works photo metrically and so doesn't use intensity values but I have made a new script to correct it which I will post below for nasos to include when he updates his packages that include proxy gi.

    Nasos the version that you currently include doesn't covert to unity 5 correctly as well. The new one I've included is made only for unity 5 as a result. There is currently a bug that is being fixed in Jove 2 with radius 0 lights so this script won't work properly until it is fixed. If you need to use it in the mean time though you just need to change the radius not to be 0 and it will work. The size of the radius of the light is what changes the size of the highlights so for GI ideally you want it to be 0.

    Rockspb ,Jove 2 also batches the draw calls more efficiently than Unity's Deferred. The limiting performance for Jove seems to only be how fast the cpu can batch the draw calls. In practice with a large number of lights it is an order of magnitude faster.

    I've been doing some stress tests.

    Unity 5 Deferred 3000 lights 36 ms
    Jove 8000 lights 4 ms

    In short the limiting factor will be how fast proxi gi can calculate the GI lights on the cpu rather than Jove.
     
    Aieth likes this.
  35. IanStanbridge

    IanStanbridge

    Joined:
    Aug 26, 2013
    Posts:
    334
    using UnityEngine;
    using System.Collections;
    using Jove;

    namespace Artngame.GIPROXY {

    public class Control_Jove_light : MonoBehaviour {

    // Use this for initialization
    void Start () {

    //Enable the below if you have Jove

    this.gameObject.AddComponent(typeof(JoveLight));

    //grab Jove light
    This_Jove_light = this.gameObject.GetComponent(typeof(JoveLight)) as JoveLight;

    This_Jove_light.type = JoveLightType.Point;
    This_Jove_light.range = this.GetComponent<Light>().range;
    This_Jove_light.radius = 0; // i dont know what this is exactly, assuming it is the physical size of the point light, need this to be zero so the light source is not visible
    This_Jove_light.color = this.GetComponent<Light>().color;

    This_Jove_light.luminousPower = this.GetComponent<Light>().intensity;


    this.GetComponent<Light>().enabled=false;
    }

    //Enable the below if you have Jove
    JoveLight This_Jove_light;

    // Update is called once per frame
    void Update (){

    //Enable the below if you have Jove
    This_Jove_light.radius = 0; // i dont know what this is exactly, assuming it is the physical size of the point light, need this to be zero so the light source is not visible
    This_Jove_light.color = this.GetComponent<Light>().color;
    This_Jove_light.luminousPower = this.GetComponent<Light>().intensity * 50000 ;

    }
    }
    }
     
  36. nasos_333

    nasos_333

    Joined:
    Feb 13, 2013
    Posts:
    9,501
    Thanks a lot for the update Ian :).

    I will make sure to include this new script in the next update and in Sky Master ULTIMATE as well.
     
  37. Aieth

    Aieth

    Joined:
    Apr 13, 2013
    Posts:
    805
    Not to hijack this thread but instead of multiplying the intensity of a JoveLight by 50 000 do this instead:
    bla = bla * JoveLights.MainDirectional.lux / Mathf.PI
    Bases the intensity on the main directional (assuming you have one in the scene! Otherwise its gonna null) light and factors in a simple lambertian BRDF as well :) Unless you are already doing the lambertian elsewhere, in which case just remove the division by pi.
     
  38. nasos_333

    nasos_333

    Joined:
    Feb 13, 2013
    Posts:
    9,501
    Any insight on the how the system could work best with GI Proxy is more than welcome :), thanks for the input.
     
  39. RockSPb

    RockSPb

    Joined:
    Feb 6, 2015
    Posts:
    111
    we dont have time to lots of test and refubrishing. It would work in production asap)
     
  40. nasos_333

    nasos_333

    Joined:
    Feb 13, 2013
    Posts:
    9,501
    I will have a small window this weekend and i could work on eliminating some of the bounce lights per tag. It should be easy to implemen i think.

    Would it be best to use a tag or layer, or maybe both ?
     
  41. RockSPb

    RockSPb

    Joined:
    Feb 6, 2015
    Posts:
    111
    Sounds good! (Our programmers don't have time for this now)
    Of course it would be better to use both methods for more flexability!
    So if you will do this, maybe you could also add execute option for GI point lights?
    Ps I hope that I will be able to add new screenshots soon
     
  42. nasos_333

    nasos_333

    Joined:
    Feb 13, 2013
    Posts:
    9,501
    The tag system will be global, it will stop bounce lights from any GI Proxy source be created, so this will include point light source by default (and spot light etc)
     
  43. RockSPb

    RockSPb

    Joined:
    Feb 6, 2015
    Posts:
    111
    I mean that the generated light sources were setting executed layers.
     
  44. nasos_333

    nasos_333

    Joined:
    Feb 13, 2013
    Posts:
    9,501
    What are executed layers ? I will check it.
     
  45. RockSPb

    RockSPb

    Joined:
    Feb 6, 2015
    Posts:
    111
    Sorry Its called Culling Mask in unity
     
  46. nasos_333

    nasos_333

    Joined:
    Feb 13, 2013
    Posts:
    9,501
    I dont recall changing or setting layers in the lights. I will check it out.

    EDIT: Do you mean have an option to set the bounce light layer ?

    That is a great idea, i will include it for sure.
     
    Last edited: Mar 13, 2015
  47. nasos_333

    nasos_333

    Joined:
    Feb 13, 2013
    Posts:
    9,501
    Just added the "exlude on tags" option and works like a charm, eliminating all outside wall bounce lights. Moving on to the rest.

    In my sample it was 20 bounce lights before and now uses 8.
     
  48. nasos_333

    nasos_333

    Joined:
    Feb 13, 2013
    Posts:
    9,501
    The script changes are all done. Now bounce lights can be disabled per layer, tag and have culling mask set.

    I have also added the height cut off feature that was first added in the Sky Master version

    I can send the new script in an email.
     
  49. RockSPb

    RockSPb

    Joined:
    Feb 6, 2015
    Posts:
    111
    Exactly what we need! Thank you very mach. It might be useful!
     
    nasos_333 likes this.
  50. nasos_333

    nasos_333

    Joined:
    Feb 13, 2013
    Posts:
    9,501
    I have sent the update. Let me know if there is any clarification needed on the new functionality.
     
unityunity