Parallax 3d Effect
A simple parallax 3d effect implementation with Corona SDK. This runs on Android and iOS. Gravity data from the accelerometer is then used to offset the angle of view. Illusion of depth is created by slightly moving the layers in the right direction, the magnitude of the movement depending on the distance to the eye.
To manage the scene I created 10 different layers. I placed the smaller shark in the front layer (layer 0), the larger shark in the middle (layer 5) and the back image to the background (layer 10).
Layer 0 has 0% displacement according to gravity, and Layer 10 has 100% displacement.