Click to See Complete Forum and Search --> : Mathematics for programming graphical representation of a carousel?


pluviosilla
August 8th, 2008, 12:16 PM
I would like to program a 3D representation of a carousel of photo images. Anyone know where I can find the mathematical formulas for that? The carousel is rotating about a central axis, obviously, but you also have to make each individual photo (or slide) rotate about its axis in a way that is dependent on the rotation of the carousel.

Picture of a classic slide carousel:

http://images.google.com/imgres?imgurl=http://www.istockphoto.com/file_thumbview_approve/4605976/2/istockphoto_4605976_slide_carousel.jpg&imgrefurl=http://www.istockphoto.com/file_closeup/object/4605976_slide_carousel.php%3Fid%3D4605976%26refnum%3D1796500&h=254&w=380&sz=33&hl=en&start=54&um=1&tbnid=aDZ8B683rV4XSM:&tbnh=82&tbnw=123&prev=/images%3Fq%3Dcarousel%2Bslideshow%2Bprojector%26start%3D40%26ndsp%3D20%26um%3D1%26hl%3Den%26sa%3DN

Any help would be appreciated. Thanks.

Amleto
August 15th, 2008, 02:53 PM
If I understand you correctly, the rotation of the photo is just its starting rotation, plus the rotation of the carousel.

if the first photo (n=0) is defined so that it has 0 starting rotation, then the nth photo of N photos has starting rotation (in degrees) of

(360/N) * (n - 1).

e.g. you want 5 photos

360/5 = 72 degrees. The starting rotation of the photos are as follows:


n rotation
0 0
1 72
2 144
3 216
4 288