Sometimes we may want to animate our points. Main reason for that is to try algorithms with different 2D point combinations. . We can have a chance to see if there is a weakness in our algorithm.
Here, you will introduce with a new function named loop( ) which we use for creating an animation.
animate( ) function has two alternatives. Let's have a look at them:
In this example we will not use any function. Here is the live example:
Now, we will call convexHull( ) function with initially random 5 points. Then as we animate through points we will call that function repetitively.
Here another function miniDisc( ) which finds smallest Enclosing Disk.
Now, we will call convexHull( ) function with another type of animation.