Search Unity

Mixing video track over live cinemachine "scene" camera?

Discussion in 'Timeline' started by Sun-Dog, Mar 18, 2019.

  1. Sun-Dog

    Sun-Dog

    Joined:
    Mar 23, 2009
    Posts:
    144
    I am currently researching and I’ve not yet started to experiment. I want to have a video track playable in timeline where I lay down prerecorded video timed to the scene; then I want to mix it over the contents of a cinemachine "scene" camera. At this point, let’s assume a 50/50 mix of the video over the top of the scene camera for the duration of a "scene".

    The research I’ve done into video playables leads me to this:
    https://forum.unity.com/threads/video-player-custom-playable.511895/
    This indicates that video playables are still fairly fragile.

    The thread on cross fading indicates the need for a render texture:
    https://forum.unity.com/threads/is-...ages-instead-of-position.541865/#post-3573211

    At this point I would assume that I’ll need to update the 2017 default video playable code with the forum code and lay that as the primary track in timeline; then render the cinemachine camera to a render texture for the duration of the scene so it can be mixed? I would have initially thought the video would be a good candidate for the render texture layer, but I can’t see how to do that and maintain sync control with timeline.

    Has anyone done this that can point me in the right direction? Or does anyone have any better thoughts on how to mix prerecorded video over the live camera?