Search Unity

  1. Welcome to the Unity Forums! Please take the time to read our Code of Conduct to familiarize yourself with the forum rules and how to post constructively.
  2. Join us on Dec 8, 2022, between 7 am & 7 pm EST, in the DOTS Dev Blitz Day 2022 - Q&A forum, Discord, and Unity3D Subreddit to learn more about DOTS directly from the Unity Developers.
    Dismiss Notice
  3. Have a look at our Games Focus blog post series which will show what Unity is doing for all game developers – now, next year, and in the future.
    Dismiss Notice

Crazy glitch with dual camera setup

Discussion in '5.4 Beta' started by horatiu665, May 4, 2016.

  1. horatiu665

    horatiu665

    Joined:
    Nov 22, 2012
    Posts:
    20
    Hi,

    I encountered a weird bug where my particle systems sometimes render in a weird way. Here is how it looks:

    https://imgur.com/n44wZUl

    Background: I am working on a VR game for the Vive, and I have a two-camera setup in the scene, one has near plane and far plane quite small (0.1 - 60), clear depth only, and the other is (59-3000) and clear skybox. I have this setup because I am trying to avoid Z-fighting for a very large scene in which I have a procedural mesh (ski slope - red green black texture in the gif) and trampolines/ramps that are placed quite tangential to the slope (cannot see in gif). The particle texture is a white circle, similar to what seems to be the tiled texture in the glitches. On deactivating/reactivating the particle systems, it is obvious they are part of the problem.

    I am sure the dual camera setup is also part of the problem because if I disable either the near or far camera, the other does not show any trace of the glitch. I would be happy to get rid of this setup, if there was some way to avoid Z-fighting.

    The question is: how do I avoid both this glitch AND z-fighting, keeping the maximum visible distance to around 3000?

    PS: please tell me where I should move this thread if this is not the right place for it. Thanks!
     
  2. williamj

    williamj

    Unity Technologies

    Joined:
    May 26, 2015
    Posts:
    94
    Do you mind submitting a bug report with the project attached? I'd like to take a closer look at the camera setup.

    I would definitely keep exploring other options in the meantime though.

    -Will