• Products
  • Solutions
  • Made with Unity
  • Learning
  • Support & Services
  • Community
  • Asset Store
  • Get Unity

UNITY ACCOUNT

You need a Unity Account to shop in the Online and Asset Stores, participate in the Unity Community and manage your license portfolio. Login Create account
  • Blog
  • Forums
  • Answers
  • Evangelists
  • User Groups
  • Beta Program
  • Advisory Panel

Navigation

  • Home
  • Products
  • Solutions
  • Made with Unity
  • Learning
  • Support & Services
  • Community
    • Blog
    • Forums
    • Answers
    • Evangelists
    • User Groups
    • Beta Program
    • Advisory Panel

Unity account

You need a Unity Account to shop in the Online and Asset Stores, participate in the Unity Community and manage your license portfolio. Login Create account

Language

  • Chinese
  • Spanish
  • Japanese
  • Korean
  • Portuguese
  • Ask a question
  • Spaces
    • Default
    • Help Room
    • META
    • Moderators
    • Topics
    • Questions
    • Users
    • Badges
  • Home /
avatar image
0
Question by zafadadynamic · Apr 27, 2015 at 01:25 AM · cameralens-flare

Lens Flare 'Ignore Layers' Not Functioning

Well, the title says it all, but I'll add some details.

I have two cameras for lens flares, flare 1 and flare 2. Depth is 90 and 91 respectively.

Just for organization's sake, I place these cameras in layers 'flare 1' and 'flare 2' which are at layer indices (indexes?) 25 and 26.

In the camera options I have the culling mask for each camera set to 'flare 1' and 'flare 2.'

Near and far ranges for both cameras are 0.1 to 5000.

The camera type is perspective and orthographic. I needed to have two types of cameras for flares because flares would not align properly in perspective mode except for a few objects.

Now, my main problem is that I just want to have some flares to show in only one layer, while the other flares show for the other.

I created a test GAMEOBJECT (important) and Ignore Layers works when done this way, however ignoring layers did not work when my flare was on a light of any kind.

I was hoping I could just duplicate this functional flare to the object that needs the flare which is situated within a few parent objects, but Ignore Layers just goes back to not responding to my selection once the object's moved within the gameobject's hierarchy.

The main parent and everything below it, minus the objects with flares on them, are in a 'Ship Intro' layer whereas the objects containing the flares are in the 'flare 1' layer so I was wondering if children inherited the parent object's layer. This didn't seem to be the case when I changed the entire object, including parents, over to 'flare 1.' The flare was still duplicated onto the other flare camera.

The flares work, but they are being duplicated onto both cameras regardless of what I do.

I could do a dirty workaround where I only enable the 'flare 2' camera when it's needed, which is like for five seconds at a time, but I feel it's just a little too messy for my taste and I usually like to cut down on how many things are being enabled/disabled through the game.

Well, as usual I'll probably fix this problem (hopefully) before y'all respond because that's how my luck works lol, so thanks in advance just in case that happens.

Comment
Add comment
10 |3000 characters needed characters left characters exceeded
▼
  • Viewable by all users
  • Viewable by moderators
  • Viewable by moderators and the original poster
  • Advanced visibility
Viewable by all users

1 Reply

· Add your reply
  • Sort: 
avatar image
0

Answer by Brian-FJ · Oct 31, 2017 at 03:29 PM

Old post but Exsecratus answered this in another old post incase people are still looking for an answer.

http://answers.unity3d.com/questions/1278405/lens-flares-are-rendered-regardless-of-culling-mas.html

Comment
Add comment · Share
10 |3000 characters needed characters left characters exceeded
▼
  • Viewable by all users
  • Viewable by moderators
  • Viewable by moderators and the original poster
  • Advanced visibility
Viewable by all users

Your answer

Hint: You can notify a user about this post by typing @username

Up to 2 attachments (including images) can be used with a maximum of 524.3 kB each and 1.0 MB total.

Welcome to Unity Answers

If you’re new to Unity Answers, please check our User Guide to help you navigate through our website and refer to our FAQ for more information.

Before posting, make sure to check out our Knowledge Base for commonly asked Unity questions.

Check our Moderator Guidelines if you’re a new moderator and want to work together in an effort to improve Unity Answers and support our users.

Follow this Question

Answers Answers and Comments

3 People are following this question.

avatar image avatar image avatar image

Related Questions

How to hide anamorphic lens flare when out of camera view and occluded? -1 Answers

Flare Layer on, off? 2 Answers

Persistent Lens Flare 0 Answers

How to make camera position relative to a specific target. 1 Answer

Lens Flares are rendered regardless of culling mask? 1 Answer


Enterprise
Social Q&A

Social
Subscribe on YouTube social-youtube Follow on LinkedIn social-linkedin Follow on Twitter social-twitter Follow on Facebook social-facebook Follow on Instagram social-instagram

Footer

  • Purchase
    • Products
    • Subscription
    • Asset Store
    • Unity Gear
    • Resellers
  • Education
    • Students
    • Educators
    • Certification
    • Learn
    • Center of Excellence
  • Download
    • Unity
    • Beta Program
  • Unity Labs
    • Labs
    • Publications
  • Resources
    • Learn platform
    • Community
    • Documentation
    • Unity QA
    • FAQ
    • Services Status
    • Connect
  • About Unity
    • About Us
    • Blog
    • Events
    • Careers
    • Contact
    • Press
    • Partners
    • Affiliates
    • Security
Copyright © 2020 Unity Technologies
  • Legal
  • Privacy Policy
  • Cookies
  • Do Not Sell My Personal Information
  • Cookies Settings
"Unity", Unity logos, and other Unity trademarks are trademarks or registered trademarks of Unity Technologies or its affiliates in the U.S. and elsewhere (more info here). Other names or brands are trademarks of their respective owners.
  • Anonymous
  • Sign in
  • Create
  • Ask a question
  • Spaces
  • Default
  • Help Room
  • META
  • Moderators
  • Explore
  • Topics
  • Questions
  • Users
  • Badges