Rotating cube wireframe examples in HTML5 Canvas. Coded during Juspay internship hackathon.
Rotating Cube wireframe: Draw a 3D Cube wireframe and rotate it along the axes that passes through its center. The rotating object should decelerate at a rate of 'X' degrees/sec^2 before it comes to a standstill.
The object should respond as follows to the following user inputs -
Swipe/Drag: Accelerates or decelerates the rotating object as per the difference in velocity between rotation and swipe with the friction factor 'Y'.
Touch/Click: Generates friction that should decelerate the rotation further by a 'Y' (friction factor).
Note: Use basic graphics like Canvas/Bitmap of Android. No CSS rotation transforms or libraries like OpenGL should be used.