Lens flare not showing up in game window using Universal Render Pipeline URP (2019.3)
I just want to use Lens Flare in my game, but sometimes is so difficult to do simple things in unity. I imported Unity Standard Assets (Effects) that comes with lens flare. I tried everything and the Lens flare only show in Scene view, not in Game view why? I'm using URP, This works in URP?
Everything I tried
My camera has the flare layer turned on
My camera has a flare layer.
The lens flare is positioned in front of the camera and not show up.
The lens flare is marked as directional in a light gameobject that is the sun of scene
Also tested lens flare not attached to a light, just attached in a empty game object
The lens flare has directional unchecked, also tested with directional checked.
Every object is on default layer
The lens flare is set to ignore nothing
The camera's far plane is 1000
The flare is show up perfectly in Scene view
There are no colliders between camera
The flare has a texture imported from standard asset and is bright enough
The flare has a correct fade speed that shows the flare quickly
There is no setup options for flare in Universal Render Pipeline, not even in Player, and Quality tab in preferences.
I've tried to attach the flare to a point light. There is no Flare setting in point light.
I'm not using VR, is just a simple camera.
Tried using physical camera and normal camera.
Tried to enable and disable post processes from URP
Tried to enable and disable "Use Fog" in Flare asset.
I'm starting to think that flares simply doesn't work in URP.
There is an asset that can give you lens flare, check this out: https://assetstore.unity.com/packages/vfx/shaders/fullscreen-camera-effects/beautify-2-163949
Answer by Meceka · Feb 20, 2020 at 10:03 PM
Lens flares aren't supported in Universal Render Pipeline.
In the Features Comparison Page , you can see that both "Lens Flare" and "Flare Layer" are marked as "Not Supported"
Description of "Not Supported" is as follows.
If a feature is marked as Not supported, it's because Unity is not planning to support it in any release.
Answer by jmarcos007 · Apr 24, 2020 at 03:09 AM
Lens Flare aren't not supported in HDRP also :( https://docs.unity3d.com/Packages/com.unity.render-pipelines.high-definition@7.1/manual/Feature-Comparison.html
If lens flares aren't supported on both Pipelines, how the heck are we supposed to have lens flare in our games then?
It's sad, and they are working in features that in my opinion is less important. The Flare are not even in their to do list. In the features table they even said that "Unity is not planning to support it in any release".
Answer by Jurisdiction · May 04, 2020 at 09:55 AM
If you enable YourRenderPipelineAsset>Quality>HDR it'll work.
Hi, in fact this option exists, is inside UniversalRenderPipelineAsset, but even checking this option, the flare dont work. It's like @$$anonymous$$eceka said, Unity simply don't support this for URP. Sad. This page list all working features.
Answer by hakankaragol · Dec 15, 2021 at 08:26 AM
select camera - (from menu ) component - rendering - flare layer