Graphics programming with Math. Programming a graphical clock. Part 1.
We’re going to use Ruby, Gosu and some trigonometry to create a graphical clock. Specifically, we will be programming the behavior and graphics for the second, minute and hour hands of an analog clock; the face of the clock will be represented by a simple graphic file (a .png, in our case). Following this exercise [...]