xy63345411 / panoramagl

Automatically exported from code.google.com/p/panoramagl
0 stars 0 forks source link

Stop the rotation function in acceleration #21

Open GoogleCodeExporter opened 8 years ago

GoogleCodeExporter commented 8 years ago
Hi,
I would like to stop the rotation function in acceleration, I wish that the 
rotation was commanded only by dragging touch, can you help me?

Original issue reported on code.google.com by tonn...@libero.it on 4 Jan 2013 at 1:34

GoogleCodeExporter commented 8 years ago
I'm developing on Android 4.0

Original comment by tonn...@libero.it on 4 Jan 2013 at 1:36

GoogleCodeExporter commented 8 years ago
setIsAccelerometerEnabled:NO

Original comment by qingery...@gmail.com on 3 May 2013 at 12:13

GoogleCodeExporter commented 8 years ago
I think I've managed to get it working.

All you have to do is insert a line on PLViewBase.m, at method 
drawViewInternally.

After:

    [camera rotateWithStartPoint:startPoint endPoint:endPoint];

Insert:

    startPoint = endPoint;

This will trick PanoramaGL to assume the "first touch location" as the last 
one, therefore the "distance" between the drag points are always tiny enough to 
make a consistent and smooth scroll.

Then you just need to adjust the sensitivity. 10.0f did fine for me.

Original comment by ares...@gmail.com on 20 Sep 2013 at 3:12