Mumble char-camera inconsistencies
Averaging camera space character positions seems to work well against the issue, but it does introduce a quite noticeable latency when the camera distance changes too fast.
What you’re experiencing here is probably simply the result of a dirty read.
The character moves, “away” from the camera. GW2 updates the MumbleLink data. Probably first the character position, then the camera position. If you access the data between those two, you already have the new character position, but still the old camera position, which is the reason why the distance fluctuates.
There’s no way around that. GW2 could set a “writing” flag in the mumble data during the write process, which could be used in conjunction with the tick field to identify most dirty reads, but that would still be a bandaid fix.
Alright, I take that back.
The camera lags behind. Without touching the mouse, only while running around, I compared the distance traveled by the camera to the distance traveled by the avatar. While moving the character on an even underground, the distance traveled by the avatar is significantly larger than the distance traveled by the camera (and this difference jitters quite a lot). When I then stop moving, the difference shrinks back to roughly 0 (only roughly because of rounding errors I presume).
So yeah, there’s something odd about that data. Maybe in the on-frame calculations, the camera’s position is adjusted to the avatar’s position after the Mumble data was pushed out.