Search Unity

Blending between two cameras with LookAt target groups

Discussion in 'Cinemachine' started by Partybrian5000, Aug 13, 2019.

  1. Partybrian5000


    Mar 7, 2019
    Hey, I'm having a bit of an issue that I've seen other people ask about before but without an answer that seems to be suitable (e.g. one involved a system-wide hack to change transition behaviour), so I thought I'd ask and see what you guys suggest.

    The main issue is the same as the issue presented in this thread:

    The blend between the two VCams with LookAt targets does a spherical blend that focuses on neither, while I'd much rather it instantly focus on the newly activated camera's target group.

    I understand that if I remove the LookAt target from either I can get the behaviour I want, but the subsequent reassignment of the LookAt target creates an ugly visual effect. I understand I can then lerp from an interim camera without a LookAt target, then towards my intended final camera, but this would create a lot of extra steps in the intended usage - we want to be able to focus on a target object and the player in a target group on a lot of interactable elements within our scenes/game.

    I saw that there's an 'IgnoreLookAtTarget' value in the BlendHintValue enum in the CameraState that's activated in some Aiming conditions, could this not be extended to the BlendHint enum available for selection on each VCam? Or ideally, will there be a system to define the targeting behaviour between camera blends specifically, as opposed to just the more generalised transform interpolation curve stuff?

    Thanks for any help!
  2. Gregoryl


    Unity Technologies

    Dec 22, 2016
    Yes, extending the BlendHint enum would be a good idea. In the meantime, you can work around this by authoring a custom CM extension that sets the bit in the CameraState.