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 Ogdy · May 14, 2015 at 04:24 PM · shadermeshrenderingglitchclipping

A mesh behind other meshes appears above depending on viewing distance.

Hi.

I am have some trouble with my rendering. It seems like meshes renders weirdly depending on their distance from the viewing point (not even the camera since I have this glitch also in the editor window)

It might be difficult to understand the problem I'm having since it is difficult to explain and I don't have a perfect english, so here is a picture to explain myself :

alt text

  • As you can see on the first picture I can see the crystal and the shadow (it's a plane mesh with a particle shader) of the tower.

  • On the second picture, I went a bit backwards and the shadow disapeared and the ground (also a plane with a texture on it) appears on top of the crystal.

  • If I disable the ground, I can see the shadow and the crystal normally no matter the distance, so I guess the issue comes from my ground prefab. Thank you for your help :)

probleme.jpg (259.9 kB)
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
1
Best Answer

Answer by FortisVenaliter · May 14, 2015 at 04:32 PM

Two things I recommend you check:

  1. Make sure all materials that do not contain transparency are set to "Opaque". Otherwise, they may be rendering out-of order.

  2. Make sure your camera's near and far clip values are not too far apart. Rule of thumb is that a ratio of 1:1000 for near:far is the maximum. If they're too far, you'll get what is called "Z-fighting"

Comment
Add comment · Show 2 · 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 Ogdy · May 14, 2015 at 10:30 PM 0
Share

I think your point 1 is the way to go. The problem comes from the shaders.

  • When I change the transparent material of the crystal and I change the shadows with an opaque shader everything is O$$anonymous$$.(it's obviously not what I'm looking for but it's just for testing).

  • If I use a "Cutout" or "Transparent" shader of the ground material everything is also O$$anonymous$$. However for some reason when I export to android cutout textures are invisible so I try to stick with vertexlit opaque shaders.

All my shaders are derived from $$anonymous$$obile/VertexLit exept for the transparent ones like the shadows and the crystal.

avatar image Ogdy · May 15, 2015 at 09:55 AM 0
Share

O$$anonymous$$ so I can't really tell why but everything is fine now. I haven't really changed anything but the issue was certainly in the shaders. Thank you. Problem solved !

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

2 People are following this question.

avatar image avatar image

Related Questions

3D Object Scrolling Panel 0 Answers

Mesh Clipping / Cross Sections 1 Answer

stencil mesh,stencil mesh-how to i get a stencil mesh to a camra rendering pipe to cull the mesh behand the mesh. dimish the draw call count 0 Answers

How to acheive wireframe effect with dots? 0 Answers

Render inside of mesh as black 2 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