Your rendering function is updating the Z coordinate of your image at each frame.
It makes the rendered image move from frame to frame. You can notice that at the start, when the image rotates until the image orientation stabilizes.
Besides, the algorithm uses the rendering surface itself as a source, so if it runs fast enough it will process the transformed image recursively, leading to the "perspective to infinity" effect.
Finally, it doesnt't check for image space coordinates overflow, leading to wraps when an image border overflows to the next scan line.
The rotation formula seems OK (it indeed rotates a point along the specified axis), but the way it is used is pretty weird.
It does rotate the image along the Y axis, like a reversible blackboard flipping on its hinges, then updates the Z coorinate of the image accordingly. The net result is to stretch the 3D image along the original Z axis.
Combined with the incremental modification of the Z values, this seems to converge toward some fixed stretch/rotation applied to the original image, whose computation is beyond my maths.
The original camera object seems to have been discarded (only the mysterious "e" vector is used, as a kind of perspective projection helper).
I suspect the original code did some basic camera projection, but was then fiddled with beyond my ability to understand what was intended.
At any rate, the code does not do what the comments suggest, and modifying the parameters yield pretty weird results.
I wrote a naive piece of code doing a more traditional camera projection. I tried to keep it readable so it's rather slow. Maybe you can start from there and optimize it to suit your needs.
See a working example here. Requires an HTML5 browser with mp4 support. Tested on latest FireFox.
(it's not a JSfiddle since image safety would not allow to see anything, but the code is inside the page).