Search Unity

Track multiple target and make sure they are always on screen

Discussion in 'Cinemachine' started by libra34567, Apr 21, 2021.

  1. libra34567

    libra34567

    Joined:
    Apr 5, 2014
    Posts:
    62
    So I'm using cinemachine to track multiple target, with target group. But the problem of target group is that it can't ensure all targets are on screen. Shown in the draft drawing below. When all targets have the same weight/radius, and they are positoned like the drawing illustrated, cinemachine can't ensure all of them would be on screen. Is there anyway write extension for cinemachine for that feature? Cinemachine is really convenient in many ways, scripting a whole new camera system would be quite time consuming.

    Looking forward to any suggestion. Best regards

    P.s.
    1. My targets move quite rapidly on the screen. It's ok to lose sight of them for a few seconds.
    2. Adjusting weight to ensure them on screen is too unsable.
    Untitled.png
     
  2. marc_tanenbaum

    marc_tanenbaum

    Unity Technologies

    Joined:
    Oct 22, 2014
    Posts:
    637
    Target Group is designed to solve exactly the problem you're describing. I think it's likely that there's something not quite right in your setup. Maybe take a peek at this short video and see if perhaps you've missed something.

     
    zeimhall likes this.
  3. libra34567

    libra34567

    Joined:
    Apr 5, 2014
    Posts:
    62
    Hi @marc_tanenbaum , thanks for the reply and sorry for the slow response, the internet over my region isn't ideal to say the least :D

    I replicated what the video showed, but the problem actually lies when object change there distance to the camera. Shown in the video I captured below. Is there anyway to solve this? Thank you!.

     
  4. marc_tanenbaum

    marc_tanenbaum

    Unity Technologies

    Joined:
    Oct 22, 2014
    Posts:
    637
    Try changing Transposer to Framing Transposer and see if that gets you closer to what you want.
     
    Burnt3nds likes this.
  5. Gregoryl

    Gregoryl

    Unity Technologies

    Joined:
    Dec 22, 2016
    Posts:
    7,711
    Try also changing the vcam's Adjustment Mode to Zoom Only. The parallax-related effects make framing tricky when members move a lot in Z.
     
    Burnt3nds likes this.