• 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
1
Question by jc_lvngstn · Jun 27, 2012 at 08:09 PM · cameralayerglow

How to apply post processing only to objects drawn by that camera?

I'm trying to get specific objects to glow on mouseover or selection. But the glow post processing assigned to my glow camera is being applied to the results of all cameras.

I have a main camera, and a "Glow" camera. The glow camera only displays items on the glow layer. The camera has the "Glow" post process effect assigned to it. Any item that I want to glow, I assign it to the glow layer, and the glow camera draws it and applies the post processing effect.

My glow camera is rendered after the main camera. The problem: The glow is applied to the entire scene, not just assigned to the glow layer. My main camera renders the environment, and the glow camera renders the glow object...but it also applies the glow effect to the scene rendered by the main camera.

It seems that ideally, I could draw items on a separate camera, with a transparent background, apply the post processing effects, and THEN overlay that onto my previous camera scene. Any suggestions/thoughts?

Comment
Add comment · Show 2
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
avatar image jc_lvngstn · Jun 28, 2012 at 02:59 PM 0
Share

Should the topic be reworded: How to apply post processing effects ONLY to objects drawn by that camera?

avatar image SubBassman · Jul 09, 2012 at 09:21 AM 0
Share

Anyone can answer this?

2 Replies

· Add your reply
  • Sort: 
avatar image
3

Answer by hydrix · Jan 30, 2017 at 07:39 AM

here's how I did this: alt text

main camera:

"clear flags": depth only

"culling mask": layer I named "PrePostProcess"

"depth": higher than other camera- 2

secondary camera with postprocessing effects:

"clear flags": skybox

"culling mask": everything I want postprocessed- "Everything" except "PrePostProcess"

"depth": lower than other camera- 1

finally:

I went around marking everything I wanted not to be postprocessed with the layer "PrePostProcess"


selection-001.jpg (8.1 kB)
Comment
Add comment · Show 1 · 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
avatar image abeldantas · May 29, 2018 at 03:02 PM 0
Share

In your example the postprocessing camera is rendering the background. So this doesn't work if you want to apply postprocessing to 3d objects above a 2d background.

avatar image
-1

Answer by SubBassman · Jul 09, 2012 at 01:03 PM

Anyone can answer this?

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

The best place to ask and answer questions about development with Unity.

To help users navigate the site we have posted a site navigation guide.

If you are a new user to Unity Answers, check out our FAQ for more information.

Make sure to check out our Knowledge Base for commonly asked Unity questions.

If you are a moderator, see our Moderator Guidelines page.

We are making improvements to UA, see the list of changes.



Follow this Question

Answers Answers and Comments

7 People are following this question.

avatar image avatar image avatar image avatar image avatar image avatar image avatar image

Related Questions

How do you get particles to be ignored by cameras? 1 Answer

Why post process layer script doesn't consider the layer in AR? 0 Answers

How can I add flare layer via code? 1 Answer

Is there an easy way to apply the same tag to all children of an object? 4 Answers

Blur the camera and overlay them (Add) 0 Answers

  • Anonymous
  • Sign in
  • Create
  • Ask a question
  • Spaces
  • Default
  • Help Room
  • META
  • Moderators
  • Explore
  • Topics
  • Questions
  • Users
  • Badges