I'm trying to make the feature of gyroscope using camera movement and accelerometer using JavaScript
with
navigator.mediaDevices.getUserMedia
and
Accelerometer()
I've noticed codes and tutorials for motion detection using canvas api by substracting the last frame[image] from the current frame.
it wont be accurate like gyroscope, but i only need is a function [side] which returns 'towards right' or 'towards left'
like how panorama shot detects
this app does exactly what i need:
Home Theater VR