Search Unity

  1. Unity 2019.1 beta is now available.
    Dismiss Notice
  2. The Unity Pro & Visual Studio Professional Bundle gives you the tools you need to develop faster & collaborate more efficiently. Learn more.
    Dismiss Notice
  3. We're looking for insight from anyone who has experience with game testing to help us better Unity. Take our survey here. If chosen to participate you'll be entered into a sweepstake to win an Amazon gift card.
    Dismiss Notice
  4. On February 28th the Feedback website will shut down and be redirected to the Unity forums. See the full post for more information.
    Dismiss Notice
  5. Want to provide direct feedback to the Unity team? Join the Unity Advisory Panel.
    Dismiss Notice
  6. Unity 2018.3 is now released.
    Dismiss Notice
  7. Improve your Unity skills with a certified instructor in a private, interactive classroom. Watch the overview now.
    Dismiss Notice

Assets [Unity Awards 2018 - BEST ARTISTIC TOOL Winner] Aura - Volumetric Lighting

Discussion in 'Works In Progress' started by raphick, Nov 16, 2016.

  1. raphick

    raphick

    Joined:
    Nov 15, 2016
    Posts:
    233
    Not with Aura 1, yes with Aura 2
     
    Mark_01 likes this.
  2. ManiaCCC

    ManiaCCC

    Joined:
    Aug 15, 2015
    Posts:
    28
    Thank you very much for your hard work :) Can't wait for Aura 2..
     
    Mark_01 and raphick like this.
  3. lodendsg

    lodendsg

    Joined:
    Sep 1, 2012
    Posts:
    170
    Have used Aura for a fair bit now but never had cause to get it into a build
    We started a new project and are using Aura 1 at the moment ... looks great in editor but is a no show in a build (2018.3.4) not sure why.

    I hadn't heard your doing an Aura 2 till now ... and it looks relly cool .... from what I have read.

    As to the issue with Aura on standalone build, is there a reason it shouldn't be working on 2018.3.4?
    No errors appear in the log, our scene setup might be a bit non-standard though it all plays nice in editor ... details follow.

    We have a 'main scene' which defines the camera and a few UI bits thus it also defines the postprocessing stack and Aura componenet. This main scene has lights or environment. At runtime a enviornment scene is loaded and this does contain aura volumes and lights ... see image below.
    As you can see in editor it does as expected, no errors ... and as noted there are no errors in the logs on build.
    I have tried setting up a Shader Preload incase something was getting stripped but that didn't seem to have any effect ...

    Dev_Screenshots_002.jpg
    As to the attached image
    What you see is a UI which is part of the main scene and an environment with baked lighting, 2 aura volumes and directional light with aura on it. The environment scene is loaded at run time and set as the active scene.

    Log from a test run is attached as well, nothing stood out to me as an issue with Aura
     

    Attached Files:

  4. threeguysgamestudio

    threeguysgamestudio

    Joined:
    Dec 1, 2017
    Posts:
    22
    Awesome asset, and I will be purchasing Aura 2 as soon as it's out!

    I am wondering if you might help me with some flickering, though (through transparent/cutoff shaders) as seen here:



    Reducing Ambient Density to 0 makes the flickers go away. Is there something I need to do with the shader to resolve this problem?

    Thanks!

    [Update]
    So I'm trying to add the code necessary for the shaders to work with Aura, however, I'm not super fluent with shader coding. I'm getting a compile error, <invalid subscript 'frustumSpacePosition'>.

    I'm not clear on what I'm supposed to be adding from the Docs, there's the black background code and then the italicized Aura methods above it...do I use both?

    Probably an example would go a long way to help =)
     
    Last edited: Feb 6, 2019
  5. Leocesar

    Leocesar

    Joined:
    Apr 6, 2011
    Posts:
    45
    Hi Raph! I'm having this problem. In Game view in editor everything works fine, but when I build the game the point lights doesn't work correctly. What am I doing wrong? Thanks. problem.png
     
  6. lodendsg

    lodendsg

    Joined:
    Sep 1, 2012
    Posts:
    170
    I wonder if this is related to the issue we are having. In our case Aura doesn't seem to be at play at all in build but works as expected in editor. Feel like I'm missing something simple.

    In your case is it only point lights or all lights not sure what all you have in the scene you showed ... looks cool by the way.
     
  7. Leocesar

    Leocesar

    Joined:
    Apr 6, 2011
    Posts:
    45
    Thanks for your reply lodendsg! I only used point lights in the scene to test Aura in my game project. But as I needed a volumetric lighting solution asap, I switched from Aura to the Adam project implementation in the following link:
    https://github.com/Unity-Technologies/VolumetricLighting
    It is easyer to setup and tweek and gave me some nice performant results. I'm using the latest Unity version (2018.3.5f1). See image bellow:
    newTest.png
     
  8. threeguysgamestudio

    threeguysgamestudio

    Joined:
    Dec 1, 2017
    Posts:
    22
    I think I'm somewhat getting there, but the Unity Editor gives me this compile error when I try to #Include Aura.cginc:

    Unexpected token '('. Expected one of: ',' ';' at Structs.cginc (32)

    The Structs.cginc line it's talking about is:

    (32) half4x4 ToMatrix() <---this one
    (33) {
    (34) return half4x4(half4(a.x, b.x, c.x, d.x), half4(a.y, b.y, c.y, d.y), half4(a.z, b.z, c.z, d.z), half4(a.w, b.w, c.w, d.w));
    (35) }

    [Update]

    So normally Unity shaders can't declare methods inside structs, however you must be using this for your ComputeShader because when I tried to change things it broke.

    Should I wait til Aura 2 in order to modify my shaders to work, or is there another way around this error?
     
    Last edited: Feb 10, 2019
  9. Leocesar

    Leocesar

    Joined:
    Apr 6, 2011
    Posts:
    45
    It's a known issue with Aura. Reduce the Far Clipping Plane parameter on you main camera and/or increase the Field of View value, values below 50 generates this kind of artifact.
     
    threeguysgamestudio likes this.
  10. lodendsg

    lodendsg

    Joined:
    Sep 1, 2012
    Posts:
    170
    Ive done some additional testing on our build and found that Aura was turning its self off ... but doesn't say why.

    (Filename: Line: 123)

    Located Aura object with enabled status of False

    (Filename: C:\buildslave\unity\build\Runtime/Export/Debug.bindings.h Line: 45)

    Located Aura Volume object (Aura Global Volume) with enabled status of False

    (Filename: C:\buildslave\unity\build\Runtime/Export/Debug.bindings.h Line: 45)

    Located Aura Volume object (Aura Planar Volume) with enabled status of False

    (Filename: C:\buildslave\unity\build\Runtime/Export/Debug.bindings.h Line: 45)

    The above are Debug.Log messages we added to a testing script which on start of the second scene searches for Aura object and the volumes that should be there and simply reports the enabled status of the componenets ...
    For my next trick I will see if I can figure out why they are disabled and what they do if I try to force them back on. The Auto-disable of Aura objects is a bit anoying so to the author I recomend handling that a bit different ... few sugestions follow.

    1st Let the developer choose what to do if some condition is true that the componenet cant be on and should be disabled. You could do this very easily for example by having the validation ran before any of your scripts as its own process and have that validation fire off events for Not Supported, Supported and any other environment type conditions you think should adjust handling. These events could then be used by us developers to call various functions for reporting the issue so its not a black box and possibly for resolving whatever issue there is effectivly overriding or modifying the validation.
    So lets say this Validation script had a Bool on it for IsValid ... we could decide if IsValid should be set to true or false. Each Aura object could then simply test 'IsValid' to see if it should disable its self. You could even be nice and have Aura objects register to this Validation object such that we could iterate over them at run time without having to do a search ... Cinamachine does this with its brain and virtual cameras and its handy.

    What ever solution you choose just make sure that it doesn't auto disable/enable things without telling the developer about it in some way, preferably a loud way thats hard to miss.
     
  11. lodendsg

    lodendsg

    Joined:
    Sep 1, 2012
    Posts:
    170
    Update on my last post ... I have confirmed that if I force the Aura objects to activate all works as expected so the issue appears to be simply that Aura deactivates its self incorrectly.
     
  12. Leocesar

    Leocesar

    Joined:
    Apr 6, 2011
    Posts:
    45
    That was exactly what was happening to me. When I finished the build process, the Aura lights was deactivated. Strange behavior.
     
  13. transat

    transat

    Joined:
    May 5, 2018
    Posts:
    129
    FYI, it's discontinued and doesn't support directional lights, so I'd stick with Aura if I were you.
     
    Subliminum likes this.
  14. lodendsg

    lodendsg

    Joined:
    Sep 1, 2012
    Posts:
    170
    We would recomend Aura for sake of quality as well ... over other options we have played with various ones from Asset Store and GitHub to include Unity's swing at volumetric lighting.

    We had looked at other options in the past and while Aura has its little quarks ... like disabling things for funnsies :/ ... and it can be tricky to learn how to adjust and get the results you want ... but once you overcome thouse which really isn't to hard just takes time and forum posts, we find the results with Aura are closer to our desired look than we could achieve with other options at least that is our experance so far.
     
  15. lodendsg

    lodendsg

    Joined:
    Sep 1, 2012
    Posts:
    170
    We reviewed the source from Aura and from what we could see it should have been that if Aura disabled its self that it should have reported as much to the log however we found no such record in the logs.
    We are trying to track down where exsactly its getting disabled so we can fix that and remove our current hack which is simply to find all the lights, volumes and the image effect and force them back on.
     
  16. raphick

    raphick

    Joined:
    Nov 15, 2016
    Posts:
    233
    Hello everybody thank you again for getting interested in Aura!
    Please remember that it's getting deprecated as Aura 2 will be out soon.

    Yes, this is an artifact coming from the depth occlusion. You can try to select a higher quality or disable it in the Settings tab of the Aura component.

    Unfortunately nothing. There are some case where point lights shadows seem not working. Will be fixed in Aura 2.

    Never encountered this. will keep it in mind for the future! Thanks!

    Not that I know. One possible clue is that the objects loading order has (again) changed and mess with the know problem of ordered activation needed in Aura. If so Aura 2 should solve the problem.
    I read your feedbacks. Thanks. This particular issue is known for a long time and comes from a wrong assumption. Unfortunately the whole architecture revolves around this. Bypassing the deactivation will only cause errors. This hassle is fixed in Aura 2.


    Thank you again all for your interest/investment in Aura 1 for the past year :)
     
  17. Adam-Bailey

    Adam-Bailey

    Joined:
    Feb 17, 2015
    Posts:
    188
    Given the number of people who will still be using Aura V1 and asking questions about it it could be worth creating a new Aura 2 thread when that release time comes.
     
    christoph_r likes this.
  18. lodendsg

    lodendsg

    Joined:
    Sep 1, 2012
    Posts:
    170
    Thanks for your hard work ... looking forward to Aura 2
    Do we know if 'soon' is days, weeks or months yet? I know 'soon' can be a scary thing to say as an indie just looking to adjust my short term tasks to suit.
     
    ledbetterman likes this.
  19. raphick

    raphick

    Joined:
    Nov 15, 2016
    Posts:
    233
    Of course!

    My pleasure!
    We're talking about days :rolleyes:
     
  20. Ruchir

    Ruchir

    Joined:
    May 26, 2015
    Posts:
    34
    Could you provide a comparison of hx volumetric lighting against aura volumetric lighting and unity's own volumetric lighting in hdrp pipeline?:)
     
  21. dienat

    dienat

    Joined:
    May 27, 2016
    Posts:
    261
    I tried to use your asset Aura using Unity 2018.3 but it gives me this error

    MissingReferenceException: The object of type 'ComputeShader' has been destroyed but you are still trying to access it.
    Your script should either check if it is null or you should not destroy the object.
    UnityEngine.ComputeShader.SetTexture (Int32 kernelIndex, System.String name, UnityEngine.Texture texture) (at C:/buildslave/unity/build/Runtime/Export/Shader.cs:672)
    AuraAPI.Frustum.ComputeData () (at Assets/Aura/Classes/Frustum.cs:188)
    AuraAPI.Aura.UpdateFrustrum () (at Assets/Aura/Classes/Aura.cs:351)
    AuraAPI.Aura.OnRenderImage (UnityEngine.RenderTexture src, UnityEngine.RenderTexture dest) (at Assets/Aura/Classes/Aura.cs:189)
     
  22. raphick

    raphick

    Joined:
    Nov 15, 2016
    Posts:
    233
    Read the readme/description and let the compute shader compile ;-)
     
  23. raphick

    raphick

    Joined:
    Nov 15, 2016
    Posts:
    233
    I'll be interviewed on stream with @TheMessyCoder
    this Saturday Feb 23rd on his Twitch channel.
    Last time was a fun!

    It's the opportunity to talk about Aura 2 status and features, join the party!


    aura2_interview.jpg