Re: [Algorithms] Low pass filter on quaternions
Brought to you by:
vexxed72
From: Tom P. <ga...@fa...> - 2010-03-29 15:48:00
|
> The problem is that Quaternions are not quite linear enough. Running a > naive filter on the axis component when the rotation is close to identity > (and the axis component is small) may cause excessive jitter. Since the rotation is close to zero, though, it doesn't really matter if your axis flips all around. The net result is still one of very little rotation. > I'd also be interested in hearing from anyone who has done this in anger! Years ago, before I had any idea what quaternions meant, I just did IIR-style filtering on them. You know, "add 10% of this frame's value to 90% of the current frame's value, and use that as the new current value." Despite the fact that this is horrifying to many purists, it actually worked out well for the application I was using it in. Doing this with controller input may lead to an undesirable amount of lag, though. When this question was posed, I started wondering how they do it on mouse drivers, since there is no apparent lag between me moving the mouse and the cursor moving on the screen. Maybe the solution there is that they run at a much higher sample rate? Maybe the filtering is done in hardware? Regardless of the solution for the filtered quaternions, I would think that lag would be preferable to overshoot. The IIR filters certainly meet that criteria. :) -tom! -- |