Results 1 to 7 of 7

Thread: How to program a carousel?

  1. #1

    Thread Starter
    New Member
    Join Date
    Aug 2008
    Posts
    4

    How to program a carousel?

    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.

    Any help would be appreciated. Thanks.

  2. #2
    I'm about to be a PowerPoster! Hack's Avatar
    Join Date
    Aug 2001
    Location
    Searching for mendhak
    Posts
    58,333

    Re: How to program a carousel?

    Welcome to the forums.

    What programming language will you be using?

  3. #3

    Thread Starter
    New Member
    Join Date
    Aug 2008
    Posts
    4

    Re: How to program a carousel?

    Probably just Flash / FLEX and Papervision3D.

  4. #4
    Lively Member CADman's Avatar
    Join Date
    Aug 2007
    Posts
    92

    Re: How to program a carousel?

    I will use VB as an example but the approach may work in many languages. Let's say you have 12 'horses' on the carousel. You will need to use image boxes as they have a stretch capability. Make the outer images fairly thin and widen them as they approach the center of the carousel. It would look something like:
    .. .... ...... ...... .... ..
    It will take a little math to move them across the screen while adjusting their widths. When one image becomes nearly zero width make it invisible and move the next image into place at the other end. There will be some distortion of the image but that may be acceptable for your purpose.

    Cadman

  5. #5

    Thread Starter
    New Member
    Join Date
    Aug 2008
    Posts
    4

    Re: How to program a carousel?

    Thanks much for taking time to reply. Did you embed some images in your post? I don't see either code or images?

  6. #6
    Lively Member CADman's Avatar
    Join Date
    Aug 2007
    Posts
    92

    Re: How to program a carousel?

    What it wrote was pseudocode or a method to consider as an approach to solve the problem. I don't know Flash / FLEX or Papervision3D but those languages may have similar controls that mimic VB. This sounds like an interesting photo display. Give it a go and if you get stuck then post your problem.

    Cadman

  7. #7
    Interweb adm/o/distrator Paul M's Avatar
    Join Date
    Nov 2006
    Location
    Australia, Melbourne
    Posts
    2,306

    Re: How to program a carousel?

    This is basically my understanding of what you need, you need to billboard the images quite frankly. So you basically rotate them to continuously face the camera. Here is an example image...



    So load them into the 3D environment then rotate them to face the camera. Since you are using Flash this concept of billboarding might not apply, i am not familiar with Flash so sorry.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width