Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

CCLayerPanZoom drifts towards anchor point after pinch zoom #91

Open
doppelgangerx4 opened this issue Dec 2, 2011 · 1 comment
Open

Comments

@doppelgangerx4
Copy link

Zooming in and zooming out both translate a CCLayerPanZoom layer and its children slightly closer to the CCLayerPanZoom's anchor point, rather than the center of each pinch. I've been able to replicate this behavior with several different CCSprites and CCTMXTiledMaps, as well as an unmodified CCLayerPanZoomTestLayer.

Set a CCLayerPanZoom's anchorPoint to (0,0), add a CCSprite to a CCLayerPanZoom, and repeatedly pinch in and out over the sprite, and the CCLayerPanZoom will drift away from the sprite, towards the lower left corner. Set the anchorPoint to (1,1) and it will drift towards the upper right.

@vaultdweller1611
Copy link

I'm having this issue too with a CCTMXTiledMap within a normal CCLayer. Just repeat zooming with the pinch gesture over and over in small steps and the view will move slowly to the left lower bottom.

Anyway, thanks for this great controller, I appreciate your work very much.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants