Smoothing touch-based animation in iPhone OpenGL?

Posted by quixoto on Stack Overflow See other posts from Stack Overflow or by quixoto
Published on 2010-06-01T00:13:07Z Indexed on 2010/06/01 0:23 UTC
Read the original article Hit count: 567

Filed under:
|
|

I know this is vague, but looking for general tips/help on this, as it's not an area of significant expertise for me.

I have some iPhone code that's basically an EAGL view handling a single touch. The app draws (using GL) a circle via triangle fan at the touch point, and moves it when the user moves the touch point, and re-renders the view then.

When dragging a finger slowly, the circle keeps up and consistent with the finger as it moves.

If I scribble my finger quickly back and forth across the screen, the rendering doesn't keep up with the touch motion, so you see an optical illusion of "multiple" discrete circles on the screen "at once". (Normal persistence of vision illusion).

This optical illusion is jarring. How can I make this look more natural? Can I blur the motion of the circle somehow? Is this result the evidence of some bad frame rate issue? I see this artifact even when nothing else is being rendered, so I think this might just be as fast as we can go.

Any hints or suggestions? Much appreciated. Thanks.

© Stack Overflow or respective owner

Related posts about iphone

Related posts about animation