Search Unity

Rendering objects to shadow map using command buffer

Discussion in 'General Graphics' started by kavaari, Nov 17, 2015.

  1. kavaari

    kavaari

    Joined:
    Nov 17, 2015
    Posts:
    4
    Hi, I was bit experimenting with command buffers but I didn't find a way to properly render stuff to shadow maps. Light object has LightEvent.BeforeShadowMap event but no way to get the shadow projection matrices to properly transform the object to the map.

    Am I missing something or is it impossible to draw object shadows using command buffers?
     
  2. theFrenchDutch

    theFrenchDutch

    Joined:
    May 5, 2014
    Posts:
    25
    Hi, I'm curious about using command buffers to render objects from a native plugin and still have shadows in unity.
    Have you found a solution to this ?

    Thanks :)
     
  3. kavaari

    kavaari

    Joined:
    Nov 17, 2015
    Posts:
    4
    Nope, it seems to be impossible, because there is no way to get the camera's shadow projections. DrawMesh is the only way :<