Search Unity

  1. We've closed the job boards. If you're looking for work, or looking to hire check out Unity Connect. You can see more information here.
    Dismiss Notice
  2. Unity 2017.3 has arrived! Read about it here.
    Dismiss Notice
  3. Want to see the most recent patch releases? Take a peek at the patch release page.
    Dismiss Notice

New Cinemachine v1.5

Discussion in 'Cinemachine' started by Adam_Myhill, Mar 5, 2017.

  1. Skyfly

    Skyfly

    Joined:
    Jan 25, 2014
    Posts:
    90
    I have a vive running while developing, I hope it should work with a connected vive?
     
  2. Skyfly

    Skyfly

    Joined:
    Jan 25, 2014
    Posts:
    90
    Figured it out, if the Vive is activated ('Virtual Reality Support' on player settings), it will always override what cinemachine does, thus CM looks a if it does nothing (in fact it just can't). Now that I know this I can workaround it.
     
  3. Adam_Myhill

    Adam_Myhill

    Unity Technologies

    Joined:
    Dec 22, 2016
    Posts:
    254
    @Skyfly try going through the steps in the enclosed CinemachineBaseRigManual.pdf. It's something on your end, if you see the camera following but it's not active then you've got some higher priority camera overriding the one you want to look at
     
  4. Adam_Myhill

    Adam_Myhill

    Unity Technologies

    Joined:
    Dec 22, 2016
    Posts:
    254
    Yes a Vive will activate it's own camera which will steal priority
     
  5. BinaryByron

    BinaryByron

    Joined:
    Sep 16, 2016
    Posts:
    3
    I'm getting all sorts of errors when trying to compile for windows store. Should I stay away from CM 2 and Unity 5.6?

    Cinemachine-2-b8-2017-05-09
    Unity: 5.6.1f1
    Code (CSharp):
    1.  
    2. Assets\Cinemachine\Blackboard\Reactor.cs(282,45): error CS1061: 'Type' does not contain a definition for 'IsSubclassOf' and no extension method 'IsSubclassOf' accepting a first argument of type 'Type' could be found (are you missing a using directive or an assembly reference?)
    3.  
    4. Assets\Cinemachine\Base\Runtime\Core\ReflectionHelpers.cs(71,37): error CS0234: The type or namespace name 'AppDomain' does not exist in the namespace 'System' (are you missing an assembly reference?)
    5.  
    6. Assets\Cinemachine\Base\Runtime\Core\CinemachineDebugLogger.cs(22,67): error CS0117: 'Assembly' does not contain a definition for 'GetExecutingAssembly'
     
    Last edited: May 20, 2017
  6. Adam_Myhill

    Adam_Myhill

    Unity Technologies

    Joined:
    Dec 22, 2016
    Posts:
    254
    @BinaryByron CM2 and Unity 5.6 aren't officially supported. We know that it's possible to make it work, however. We will have a look at your errors and get back to you shortly
     
  7. Gregoryl

    Gregoryl

    Unity Technologies

    Joined:
    Dec 22, 2016
    Posts:
    668
    @Skyfly CM 2.0 doesn't officially support Unity 5.x, but there are easy fixes for your error messages. Just comment out the lines in CinemachineComposerEditor.cs that re generating the errors. They are both related to displaying the composer guides correctly in certain rare special cases:
    1. if you are using CM on a camera that renders to a texture
    2. if you are using CM on a camera that does not render to the full screen (e.g. inset)
    Even in those special cases, the worst that can happen with those lines commented out is that the screen guides won't be displayed correctly. I think you can safely disable them and use CM in 5.5.
     
  8. Gregoryl

    Gregoryl

    Unity Technologies

    Joined:
    Dec 22, 2016
    Posts:
    668
    We seem to be dealing with an SDK incompatibility here. I've created an issue for these things and we will address them in an upcoming release.

    In the meantime, you can work around it. With a little massaging, I was able to get a Windows Store build with the following settings:
    WindowsBuild.PNG

    To get this to work, I had to do 2 things:
    1. Delete Cinemachine/Reactor from project assets (it's an add-on and you can get by without it)
    2 .Import the attached patch

    Give it a try, and let me know.
     

    Attached Files:

  9. Danirey

    Danirey

    Joined:
    Apr 3, 2013
    Posts:
    486
    Hi guys,

    I moved to CM2. And i'm trying tocicle between 3 cameras. With 1.1, just by enabling or disabling the cameras, it worked brilliant. Now with 1.5 and 2, i can move from one to another, but there is no blending from cam 1 to 3(1->2->3). But if i cicle back to the first camera(3->2->1) and that way it blends fine.

    My code is quite simple using arrows and a list cicling through the index. The blending is exactly as the sample scene. I can't find the problem, since it is just enabling the cameras, right?

    Any clue? And by the way, any docs about using state driven cameras?

    Thanks a lot
     
  10. Skyfly

    Skyfly

    Joined:
    Jan 25, 2014
    Posts:
    90
    Have CM2 working with 561f1. I like the cloud feature. Right now I have to setup triggers and connect them to the cams, is it planned to streamline that a bit more?
     
  11. Gregoryl

    Gregoryl

    Unity Technologies

    Joined:
    Dec 22, 2016
    Posts:
    668
    The most recently-enabled camera of the highest priority will become the active one. It will blend in, in accordance with the blend settings. Are you saying that in your case 2->1 will blend, but 1->2 will cut? You can set up that situation with specific blend settings. Maybe you did that by mistake? Try with a brand-new scene, no blend settings other than a default blend.

    The State-Driven-Camera must be associated with an existing animation state machine. When you set that up, you will notice in the SDC inspector that you can create cameras that map to specific states in the state machine. When the state becomes active, so will the associated camera. It's fairly straightforward. (No docs yet, sorry)
     
    Danirey likes this.
  12. Danirey

    Danirey

    Joined:
    Apr 3, 2013
    Posts:
    486
    Hi, Thanks for the explanation. In my case, 1->2 and 2->3 will cut and only blend backwards.

    I'll clear all cameras from the scene and try again.

    Thanks a lot!
     
  13. Adam_Myhill

    Adam_Myhill

    Unity Technologies

    Joined:
    Dec 22, 2016
    Posts:
    254
    @Danirey You can set entirely custom blends between any cameras by creating a Custom Blend asset and defining them. There is wild card support too so you can go **From any, ** To any which allows for all sorts of configurations.

    To confirm any issues, delete the custom blend asset and set the default blend to be Ease In Out and you should always get that blend no matter what
    upload_2017-5-22_16-32-11.png
     
    Danirey likes this.
  14. Danirey

    Danirey

    Joined:
    Apr 3, 2013
    Posts:
    486
    Thanks a lot guys!

    It is working fine now. Brilliant!!!!

    Great asset, really!
     
    Adam_Myhill likes this.
  15. alanmthomas

    alanmthomas

    Joined:
    Sep 7, 2015
    Posts:
    47
    Perhaps a really stupid question, but if I'm working in the current release version of 5.6, which version of Cinemachine should I be using? I'm hesitant to jump into the 2017 beta as I have some assets that don't yet support it.
     
    pixelsteam likes this.
  16. Kmausser

    Kmausser

    Joined:
    Feb 17, 2016
    Posts:
    23
    Hey, sorry if this has been answered but I've never used cinemachine before. I saw that this is advertised as doing everything without code. I want to "zoom & orbit" to objects in the scene to reveal more detailed info attached to that part when the user decides to click on it. How would I trigger the transitions to the camera and object animations when the objects are clicked?
     
  17. Adam_Myhill

    Adam_Myhill

    Unity Technologies

    Joined:
    Dec 22, 2016
    Posts:
    254
    Hi @Kmausser . That sounds like a great use of Timeline and Cinemachine. You can trigger a Timeline when you click on a character and put some animated cameras in there which procedurally target your subject.

    You can get an idea of how to do that here in this video
     
  18. Kmausser

    Kmausser

    Joined:
    Feb 17, 2016
    Posts:
    23
    I should be more specific. How do I trigger a timeline animation to play when I click on one object, then reset/reverse that animation when the user clicks another object to start another timeline animation associated with that object?

    Basically, I'm trying to have parts with info text pop out of a chassis and have the user examine them.
     
  19. moonmenlabs

    moonmenlabs

    Joined:
    Mar 27, 2017
    Posts:
    3
    Was this not fixed in the last update of Cinemachine 2.0.1 I'm running Unity 2017.1 and getting the same errors when trying to run the universal windows platform build
     
  20. morphex

    morphex

    Joined:
    Dec 18, 2012
    Posts:
    67
    Hey, not sure if its the correct place, but using Orbital Transposer, isn't there a option like the "normal" transposer, to align to the character up vector? basicly imagine a thirdperson character controller, where you can run up vertical walls, currently the orbital Transposer does not take in account the character direction like the "align to charcter " feature of transposer, is there a setting I missing, or is it even possible?
     
  21. Gregoryl

    Gregoryl

    Unity Technologies

    Joined:
    Dec 22, 2016
    Posts:
    668
    Unfortunately this fix did not make it into the release, but it will be in the next one.
    Until then, if you're being blocked by this you can patch it yourself:
    In ReflectionHelpers.cs: put #if UNITY_EDITOR around the offending methods
    In Reactor.cs: just comment out the whole module (it's experimental and not used with standard Cinemachine)
     
  22. Gregoryl

    Gregoryl

    Unity Technologies

    Joined:
    Dec 22, 2016
    Posts:
    668
    Excellent idea. It's on the TODO list. Thanks!
     
    Jokonut likes this.
  23. bome99

    bome99

    Joined:
    Sep 14, 2009
    Posts:
    105
    Hi,

    I get this Error

    Assets/Cinemachine/Timeline/CinemachineMixer.cs(19,30): error CS0115: `Cinemachine.Timeline.CinemachineMixer.ProcessFrame(UnityEngine.Playables.Playable, FrameData, object)' is marked as an override but no suitable method found to override

    Everything looks fine:
    ProcessFrame is virtual and CinemahineMixer is PlayableBehaviour

    public virtual void ProcessFrame(Playable playable, FrameData info, object playerData);

    Haven't changes anything just importet to my project

    Using Unity 2017 1.0f3
     
  24. Gregoryl

    Gregoryl

    Unity Technologies

    Joined:
    Dec 22, 2016
    Posts:
    668
    What version Unity?
    What version CM?
     
  25. bome99

    bome99

    Joined:
    Sep 14, 2009
    Posts:
    105
    sorry just added it to my post when I saw I fogot :)

    Using Unity 2017 1.0f3
    Newest from assetstore 2.0 CM
     
  26. bome99

    bome99

    Joined:
    Sep 14, 2009
    Posts:
    105
    Adding CM to an empty project works
     
  27. Gregoryl

    Gregoryl

    Unity Technologies

    Joined:
    Dec 22, 2016
    Posts:
    668
    You possibly have something strange going on in your project. I suggest you create an empty project, add CM to it, then import your assets gradually until you find the incompatibility.
     
  28. bome99

    bome99

    Joined:
    Sep 14, 2009
    Posts:
    105
    Thanks I'll try that.
     
  29. bome99

    bome99

    Joined:
    Sep 14, 2009
    Posts:
    105
    I had my own FrameData class, thank you for the quick respons
     
  30. DamiaBonet

    DamiaBonet

    Joined:
    Jul 26, 2017
    Posts:
    7
    Hi! I have this errors trying to compile an script in a project with cinemachine
    I have the lastest version of unity 2017.1

    Can somebody help me?? errors.png
     
    Last edited: Jul 29, 2017
  31. JacobSmaga

    JacobSmaga

    Joined:
    Aug 5, 2015
    Posts:
    237
    Try re-importing Cinemachine.
     
  32. Gregoryl

    Gregoryl

    Unity Technologies

    Joined:
    Dec 22, 2016
    Posts:
    668
    We don't get these errors with CM on an empty project. Probably there is a naming conflict between CM and something else in your project. Try starting with an empty project, import CM, then the other assets in your project, gradually, until you find the conflict.
     
  33. DamiaBonet

    DamiaBonet

    Joined:
    Jul 26, 2017
    Posts:
    7
    Hi, thank you for the response,
    however the problem persist...:(:(

    I created a new project, and after importing CM, I created a script called "ActivarCamera", and when I try to compile these errors appear.
    the error says:
    "'Cinemachine.LensSettings.Orthographic' must be fully assigned before control is returned to the caller. Consider calling the default constructor from a constructor initializer."
     
  34. Gregoryl

    Gregoryl

    Unity Technologies

    Joined:
    Dec 22, 2016
    Posts:
    668
    Show me the script
     
  35. DamiaBonet

    DamiaBonet

    Joined:
    Jul 26, 2017
    Posts:
    7
    Code (CSharp):
    1. using System.Collections;
    2. using System.Collections.Generic;
    3. using UnityEngine;
    4. using Cinemachine;
    5.  
    6. public class activarCamera : MonoBehaviour {
    7.     public CinemachineVirtualCamera camera_;
    8.  
    9.  
    10.     void Awake(){
    11.         camera_ = GetComponent<CinemachineVirtualCamera> ();
    12.     }
    13.  
    14.     void OnTriggerEnter(){
    15.         camera_.enabled = true;
    16.     }
    17.  
    18.     void OnTriggerExit(){
    19.         camera_.enabled = false;
    20.     }
    21.  
    22. }
    23.  

    if I comment all the lines or if i delete my script of the assets, the problem is the same...
     
  36. Gregoryl

    Gregoryl

    Unity Technologies

    Joined:
    Dec 22, 2016
    Posts:
    668
    OK, I did this:

    Unity 2017.1
    Create new project
    Import Cinemachine 2
    Cinemachine/Create virtual camera
    Add activarCamera behaviour to the vcam

    Result: no problems.
    Run the scene: no problems.

    What exactly are you doing?
     
  37. DamiaBonet

    DamiaBonet

    Joined:
    Jul 26, 2017
    Posts:
    7
  38. Rami_FallDamage

    Rami_FallDamage

    Joined:
    Apr 4, 2017
    Posts:
    3
    In the older versions of Cinemachine there was a camera settings file that you could use to share settings between cameras. I can't seem to find this feature in the latest version. Has it been removed?

    Also, copying component values to a different object seems to completely brake Cinemachine. After the copy/paste operation, the component stops working (No changes can be made) and Cinemachine starts instantiating objects in the editor named "cm" with a Cinemachine pipeline component on it.

    Running 2.0 in unity 2017.1
     
  39. Gregoryl

    Gregoryl

    Unity Technologies

    Joined:
    Dec 22, 2016
    Posts:
    668
    Hmmm... how very interesting. This problem does not show up in Visual Studio - only in MonoDevelop. It is easily resolved, and the fix will be in the next CM point release. In the meantime, you can fix it yourself by adding calls to the default constructor in the two offending methods, as follows:

    Code (CSharp):
    1.         public LensSettings(Camera fromCamera) : this()
    2.         {
    3.             ...
    4.         }
    5.  
    6.  
    7.         public LensSettings(
    8.             float fov, float orthographicSize,
    9.             float nearClip, float farClip, float dutch,
    10.             bool ortho, float aspect) : this()
    11.         {
    12.             ...
    13.         }
    Thanks for reporting this, and for being so persistent!
     
    DamiaBonet likes this.
  40. Gregoryl

    Gregoryl

    Unity Technologies

    Joined:
    Dec 22, 2016
    Posts:
    668
    Yes, in older versions of CM there were shared asset files containing the camera settings. Those asset files have been removed, and now the settings are contained individually in every vcam. The custom blend settings are still shared assets, however, as are the noise profiles.

    Copy/paste is supported by Cinemachine. I have tried to reproduce the problem you mention, but have not been able to observe any issues. It works for me. Could you be more specific, and give the repro steps? Thanks.
     
  41. DamiaBonet

    DamiaBonet

    Joined:
    Jul 26, 2017
    Posts:
    7
    OH YEAH! thank you, the problem is solved!
    thank you so much :D:D:D:)
     
  42. Little_Gorilla

    Little_Gorilla

    Joined:
    Oct 11, 2013
    Posts:
    32
    Hey just tried out Cinemachine and it's very powerful and easy to use!

    I was wondering if the Reactor camera from the Game Rig is anywhere to be found in Cinemachine as mentioned here: http://www.cinemachineimagery.com/game-modules/

    The Orbital Transpose virtual camera has been closest to what I'm looking for for a racing game, but when the "Recenter to Target Heading" is enabled, it's pretty jerky since the camera is always rotating to look towards the front of the car. It seems like it needs some damping, so might need to make some modifications if Reactor's not available yet.
     
  43. Adam_Myhill

    Adam_Myhill

    Unity Technologies

    Joined:
    Dec 22, 2016
    Posts:
    254
    Hi @Little_Gorilla, Reactor is on hold for the moment. It's a really solid idea but it requires a number of Unity components like a blackboard system which really want to be more exposed and universally done than Cinemachine doing it's own (like we already did, sort of). It's on our roadmap and we will get to it but it's going to be a while because of this.

    The new Orbital Transposer which is coming out very shortly has some improved damping functionality and it might be just what you're looking for. We want it to be a very straightforward but versatile follow camera for driving games and any other kind of camera-following-something setups.

    It's in testing now, we'll let you know when it's up on the store. Soon !
     
  44. Little_Gorilla

    Little_Gorilla

    Joined:
    Oct 11, 2013
    Posts:
    32
    Yep sounds like the new Transposer might be perfect then, can't wait to try it out!
     
  45. Futurristic

    Futurristic

    Joined:
    Jun 21, 2016
    Posts:
    11
    Hi All,

    has anyone tried using cinemachine in VR scene? I'm trying to integrate but not able to execute it.

    thanks
     
  46. rrabassa

    rrabassa

    Joined:
    Jul 17, 2013
    Posts:
    50
    Hello!


    The Cinemachine VM seems to keep forgetting it's Look at and Follow Objects. I keep having to drag them back in. Any ideas? Im' on version 2.0
     
  47. Gregoryl

    Gregoryl

    Unity Technologies

    Joined:
    Dec 22, 2016
    Posts:
    668
  48. asotelo94

    asotelo94

    Joined:
    Jan 26, 2013
    Posts:
    10
    Currently working on UWP with the latest SDK 10.0.16299.0. I am getting 2 compiler errors.

    Assets\Cinemachine\Blackboard\Reactor.cs(314,67): error CS1061: 'Type' does not contain a definition for 'IsSubclassOf' and no extension method 'IsSubclassOf' accepting a first argument of type 'Type' could be found (are you missing a using directive or an assembly reference?)
    Comming from this line: !fieldInfo.FieldType.IsSubclassOf(typeof(Component)

    Assets\Cinemachine\Base\Runtime\Core\ReflectionHelpers.cs(87,20): error CS0234: The type or namespace name 'AppDomain' does not exist in the namespace 'System' (are you missing an assembly reference?)
    Coming from this line: System.AppDomain.CurrentDomain.GetAssemblies();

    Is there any workaround for this? I am using CM 2.0
     
  49. Gregoryl

    Gregoryl

    Unity Technologies

    Joined:
    Dec 22, 2016
    Posts:
    668
    Yes, upgrade to CM 2.1. The latest RC is available here: https://forum.unity.com/threads/cm-v2-1-release-candidate.497202/