Search Unity

  1. Unity Asset Manager is now available in public beta. Try it out now and join the conversation here in the forums.
    Dismiss Notice

How to correctly render the motion velocity buffer with SRP?

Discussion in 'Graphics Experimental Previews' started by polar1225, Sep 27, 2018.

  1. polar1225

    polar1225

    Joined:
    May 19, 2017
    Posts:
    7
    Hi~
    I want to render the object motion velocity buffer in my SRP Pipeline.After reading the HD-Pipeline,I try to implement it with a similar approach
    Code (CSharp):
    1. RenderObjectsVelocity()
    set the camera depthTextureMode to
    Code (CSharp):
    1. DepthTextureMode.MotionVectors | DepthTextureMode.Depth
    set the RendererConfiguration to
    Code (CSharp):
    1. RendererConfiguration.PerObjectMotionVectors
    and render my "MotionVectors" shader pass,i got the buffer rendered successful.But after check the render loop of my pipeline,i found that all of my scene object with the shader which contains the "MotionVectors" is renderering even it is static,i debug the HD-Pipleline,only the moving object is renderer in the stage,what did i missing to get the non-moving object culled ? THX..
     
  2. polar1225

    polar1225

    Joined:
    May 19, 2017
    Posts:
    7
    Need Help~~ ops..
     
  3. SebLagarde

    SebLagarde

    Unity Technologies

    Joined:
    Dec 30, 2015
    Posts:
    934
  4. polar1225

    polar1225

    Joined:
    May 19, 2017
    Posts:
    7
    Em..It works,I really appreciate your replay :):)
     
  5. happyfirecn

    happyfirecn

    Joined:
    Dec 28, 2016
    Posts:
    11
    The document link is invalid now, could you please give a new link?