POV-Ray : Newsgroups : povray.animations : Help with SDL for Bouncing Ball : Help with SDL for Bouncing Ball Server Time
24 Apr 2024 10:39:42 EDT (-0400)
  Help with SDL for Bouncing Ball  
From: Bald Eagle
Date: 27 Dec 2016 17:35:00
Message: <web.5862ebe4a2841af780403a200@news.povray.org>
The subject of creating a "simple" animation of a bouncing ball recently came
up, and as I looked into it, and considered how to do this, it is apparently
less simple than I thought it would be.

I would imagine that a critical factor in making the animation work out well
would be to find the total time for the ball to (practically) come to rest, and
then define the number of frames in the animation based on that.

Perhaps then one could work out the time per fall/bounce, the heights,
velocities, positions, etc. in a fairly straightforward manner.

I think for a good animation, there would need to be a good way to handle the
squashing of the ball and the deceleration prior to restoring the ball to a
sphere and resuming the bouncing cycle.
Probably define a percentage squash factor and use that times the radius to
establish the 'zero' height point.

I searched around for a good thread, because I figured that surely someone had
done something so basic - but there were no example scenes that I found, and
most people were using particle systems of some sort to make more complicated /
more general animations.

I was wondering if anyone had any practical and concrete advice on how to handle
the various parts of the animation, and how to organize the code in a sensible
manner.

I'm traveling and juggling a lot of metaphorical balls at the moment, so it may
not be until next week that a get a chance to sit down, gather my wits about me,
and hammer out some semi-functional SDL, but at least I was hoping to read some
comments advice, and code snippets that would set me on the right track from the
start.


Thanks!   :)


Post a reply to this message

Copyright 2003-2023 Persistence of Vision Raytracer Pty. Ltd.