Search Unity

Question Post Processing different when seen in editor

Discussion in 'Animation' started by MrBigly, May 19, 2023.

  1. MrBigly

    MrBigly

    Joined:
    Oct 30, 2017
    Posts:
    221
    I have some animation clips for my humanoid model and i do some post processing of the bone orientation in the LateUpdate(). When the model is seen both in the game view port and the editor, all is fine. When the model moves out of view from the editor camera, the rotations don't match what is expected, like the animation engine is doing something differently with its resulting values.

    Anyone heard of this before? Any insight would be appreciated.

    Also.....
    It appears to also that the animation for 2022.1.14f1 has a different behavior from version 5.6.3f1 from several years ago where the values didn't change. I ported the code over to the 2022.1.14f1 engine and the animation seems to behave differently even when in view of the editor camera.





    EDIT:

    I found the problem. There is a flag in the Animator Culling Mode which should be set to Always Animate so that the entire rig is fully animated even when not in view.

    My mistake was that I would flip this switch on the instanced prefab while running in editor and didn't see any change. But when I flipped it on the prefab and then started running in editor, I saw the difference. It seems that unlike Apply Root Motion, the animator property Culling Mode does not reset the animator when changed and the property doesn't take effect immediately.
     
    Last edited: May 24, 2023
  2. MrBigly

    MrBigly

    Joined:
    Oct 30, 2017
    Posts:
    221
    As I look into this further, I have another question. Has Unity improved the animation engine some how that it doesn't actually manipulate the bone orientations when they are not visible in any view port (game view port or editor camera)?

    If so, can this feature be disabled?


    EDIT: I found the issue, see original post.
     
    Last edited: May 24, 2023