0

I want to do some tricky thing for a project: I have a Website which should react on how the smartphone is moved. When the Smartphone is dragged forward and backword it should scroll up and down - same with left/right (the smartphone is on a flat surface).

I gave it a try with detecting the devicemotion but its not as smooth and i can only detect the speed and not in which direction the phone is dragged. I think this cant be done via devicemotion.

Another idea is to detect the motion with the camera (there is an image with a person printed and above this image the phone is dragged. (the phone should show the exact area of an slightly altered image of that person).

Does somebody know if this is possible and with which tools? I have seen some jQuery Facetrackers. I could imagine that i use this facetracker (jQuery headtrackr for example: https://github.com/auduno/headtrackr/).

Anyone experience with such things and can help me?

edit: not and duplicate. the suggested question is only about devicemotion which probably not work in my case and i am more interested in the solution with the camera as i said above

  • 1
    possible duplicate of [How to access accelerometer/gyroscope data from Javascript?](http://stackoverflow.com/questions/4378435/how-to-access-accelerometer-gyroscope-data-from-javascript) – Dave Aug 13 '15 at 17:19
  • not and duplicate. the suggested question is only about devicemotion which probably not work in my case and i am more interested in the solution with the camera as i said above – blacksunshineCoding Aug 13 '15 at 18:02

0 Answers0