Search Unity

How to use custom camera with 'collide with depth buffer' node?

Discussion in 'Visual Effect Graph' started by xjynewmedia, Jul 10, 2020.

  1. xjynewmedia

    xjynewmedia

    Joined:
    Jul 10, 2020
    Posts:
    2
    Hello, I use the collide with depth buffer node to create collision, it works nice
    1.PNG
    now I want to make the object invisible but still enable the collision
    so I duplicate the original camera, exactly using same params and position and I change the 'Camera' param in the node to 'Custom' too, but after changing collision doesn't happen any more
    2.PNG
    I use VFX binder to bind the custom camera, it seems to be binded successfully
    3.PNG 4.PNG
    anyone knows the correct way to use a custom camera?
    or other methods to make the object invisible but still enable collision ? I think a shader graph is needed here though
     
    Last edited: Jul 10, 2020
  2. xjynewmedia

    xjynewmedia

    Joined:
    Jul 10, 2020
    Posts:
    2
    Well, I found the solution is that
    you need to switch the camera's space in the blackboard from ‘L’ to 'W' by clicking the ‘L’ by default
     
  3. wechat_os_Qy08s8-uVLA-MjcQ79mcVM7bU

    wechat_os_Qy08s8-uVLA-MjcQ79mcVM7bU

    Joined:
    Jun 6, 2019
    Posts:
    5
    Hey, I am dealing with how to collide with depth buffer too, I want to know how can you bind the camera since I found there is no option for the camera at VFX Property Binder script.
     
  4. devil304

    devil304

    Joined:
    Sep 20, 2013
    Posts:
    11
    He used HDRP Camera option in HDRP category
     
  5. UrbanNuke

    UrbanNuke

    Joined:
    Jun 11, 2019
    Posts:
    21
    Is there any other way to do that without create/duplicate main camera?
    I mean auto create depth buffer from the settings of camera position, rotation, etc.
    It looks like vfx graph allows that, but it doesn't work.