Search Unity

Screen Fade - best practices?

Discussion in 'AR/VR (XR) Discussion' started by Rogalog, Aug 10, 2016.

  1. Rogalog

    Rogalog

    Joined:
    Jun 18, 2016
    Posts:
    23
    Hi all,

    Throughout the past few weeks, I've felt the need to have some sort of screen fade when transitioning either between scenes or between destinations in scenes. I had a look around and could only find suggestions of using a giant canvas/plane and attaching it to the HMD, using some method of altering the transparency such as Color.Lerp. Problems that came from this method included objects clipping through the canvas, requiring a custom shader to prevent this from happening.

    Although these methods generally work fine, I was curious to know if anyone has any better ideas that are perhaps more adaptable/easier to use, or if the aforementioned method is the best we have.

    Thank you!
     
  2. Ostwind

    Ostwind

    Joined:
    Mar 22, 2011
    Posts:
    2,804
    Custom image effect attached to camera?
     
  3. Rogalog

    Rogalog

    Joined:
    Jun 18, 2016
    Posts:
    23
    Could you elaborate please? I've never had any experience with custom image effects (still relatively new to Unity).
     
  4. TonyLi

    TonyLi

    Joined:
    Apr 10, 2012
    Posts:
    12,697
    You could add a Screen Overlay effect to the camera and assign a solid black texture. Set the Intensity property to 0. To fade out, gradually increase Intensity to 1.