Update to OrbitControls for three.js to Handle Pinch Zoom on Mobile

We have patched the the OrbitControls to handle pinch zoom on mobile. A long time ago we added some code to OrbitControls to handle various ZIM things. Two of these lines surprisingly prevented zooming with pinch and we had always thought orbitcontrols did not support that. So we have reverted the lines, done testing on ZIM in three.js (TextureActive) and three.js in ZIM and all seems good. We have updated our TextureActive examples to 017 - thanks Ferudun Vural for the persistence.

You can test on mobile here - note that you can pinch to zoom in and out:

https://zimjs.com/015/textureactive3.html

image

2 Likes

waauw yes super! thanks to make it possible!
also all 35 https://zimjs.com/studio/list examples can zoom now on mobile?m.. but can a max and mininumum zoom been ser?