Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

Here's a nice arcball demo that does work on mobile (and also uses multi touch, which allows you to do things which are a pain with the single cursor of a mouse, like rotating about the camera axis) https://threejs.org/examples/misc_controls_arcball.html


See, I don't think it's nice because it's not a proper arcball implementation.

This is what my pet peeve is about!

* There's gimbal lock at 180 degrees: you can only do some rotations with a single drag, and others require several

* Orient the gun so that the barrel is point straight at you, with handle down. Rotate it so that it continues pointing at you, but the handle points up. (It's.. not trivial with this interface).

* Drag the mouse horizontally along the top edge of the screen. I have no idea what's going on with the rotation.

Oh, and here's the thing that only arcball can do:

* Reset the rotation. Mark a rectangle on your screen (or put a pop-up window, e.g. the on-screen keyboard in Windows, over the demo). Start at a corner, and drag the mouse along the four edges, returning to the same position. The gun should return to the same initial orientation.

* Now do the same, but release the mouse at the corners of the rectangle - so you do four drags along the same path. Where's the gun facing now?




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: