Wayback Machinekoobas.hobune.stream
May JUN Jul
Previous capture 13 Next capture
2021 2022 2023
1 capture
13 Jun 22 - 13 Jun 22
sparklines
Close Help
  • 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 Kromleck · Nov 12, 2013 at 01:44 PM · transparencynormalsshadingbuffer

Odd transparency effects

Hi.

I'm working on a mesh and I have to allow user to control transparency of the mesh through a controler. Fact : when i turn every materials in Transparent one, i get very odds transparency effects even with 0 transparency, it's like some normals were suddendly inverted.

alt text

I've tried to make my own custom script, it actually works (+ specular yay) but i still have this effect...

Thanks a lot for whom will be able to help me, i'm stuck on this problem till 4 hours.

capture.png (246.8 kB)
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 Bart_Tamarin · Nov 13, 2013 at 01:11 AM 0
Share

I can't tell this way, but perhaps you can single out the object and tell a bit more about the material ?

$$anonymous$$y first thought was z-fighting, but I assume there's nothing wrong with the object itself ? (like accidentally duplicated polygons).

avatar image Kromleck · Nov 13, 2013 at 08:02 AM 0
Share

I've spend some hours on the deep internet trying to solve this.

I came to the point that it's due to the way unity is rendering objects when there is transparent object ; zbuffer apparently trigger its rendering priority from back to front (of the camera). And because the ground is "flat" and is as "near" as "far" of the camera, the ground is rendered first, and only after this the building is rendered, making this odd effect : the ground is above the building...

The only way i've found to counter this is to change priority in RenderTag of the Shader. Technically, if i write 1 shader per $$anonymous$$aterial (~10 for my scene), and i put in RenderTag = Transparent+1 / +2 / +3 etc... i'd be able to change the rendering priority order.

I'm trying to script this ; at Start, the script is changing the RenderTag of each $$anonymous$$aterial to renders each $$anonymous$$aterial properly.

But so far this is where i'm stucked, i don't know if it's even possible to change the RenderTag through a script :/ $$anonymous$$y line looks like this :

function Start(){ for (var child in Transform){ child.renderer.material.TagRenderer = ("Geometry+"+$i); $i++; }

Anyone knows how to change/instantiate TagRenderer through of 1 Shader applied on 10 $$anonymous$$aterials with a single script ?

0 Replies

· Add your reply
  • Sort: 

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.

Follow this Question

Answers Answers and Comments

17 People are following this question.

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

Related Questions

Edge Detection (effect normals) with water (transparent) error. 0 Answers

Receiving shadows by transparent floor 0 Answers

Transparency / Fade Material Shading Issues 0 Answers

surface shading with transparency 1 Answer

Shader Question about Alpha 0 Answers


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