2D project - using CinemachineVirtualCamera.
The camera follows the character. When setting the damping (Section Body - X Damping or Y Damping), the camera, when the character stops, smoothly slows down the movement.
Everything is as it should be.
But at the last moment, the camera moves by a unit’s share.
That is, the character stopped, the camera caught up with him. Then the camera centers … almost centered on the character and at the last moment moved-jumped by a unit’s share to stand in the center of the character.
It does not look nice.
At the last moment, before stopping, the camera seems to twitch a little.
If you remove the damping, this bug will disappear.
How to solve this problem?
It looks like it’s because you have PixelPerfect enabled. This will round the camera’s position so that it remains on pixel boundaries. If you disable PixelPerfect, then the camera will be smooth.
Indeed I had the PixelPerfect component on my camera. I removed it. I checked that it is not there on either the regular camera or the nested camera.
But the bug did not disappear.
Are you using CM 2.10.2? If so then there is a regression that was discovered yesterday which might be the cause of this. Try reverting to 2.10.1. We are working on publishing 2.10.3, which fixes the issue.
Afterwards, if the problem disappears, you can try re-adding PixelPerfect.
I’m using Unity 2021.3.1.0f1
This is a relatively old version, but some of my programs work with it.
In my project I use CM 2.8.9.
I uninstalled CM 2.8.9. and installed CM 2.10.1. But the bug remained.
There is no PixelPerfect component on any camera now (delete it for this test) - not on the standard camera, not on CM.