[MagicWand PIC] Chapter 10.5.  Waving a Magic Wand

This chapter does not appear in the book.

 
[Webcam PIC]

Would you like to shoot blasts of awesome cosmic energy from a magic wand? This chapter looks at how to replace boring key presses and mouse clicks by graceful wand waving, and there's no need to attend Hogwarts, or even Miss Cackle's Academy for Witches, to do it.

The picture at the top of the page shows the MagicWand application in action.

The picture on the right reveals the input technology: a web camera focused on my real-world 'magic wand'. As I wave the wand around, the on-screen wand moves in a similar way.

Blasts are emitted from the wand at regular intervals, and follow a path set by the current direction of the wand. The blasts don't do anything, but it wouldn't be hard to extend the sprite code to blow something up, or knock something down.

[Wand PIC]

The wand isn't an expensive item from Ollivanders; I created it out of coloured card and sticky tape (see the picture on the right). The yellow and blue squares represent the 'head' and 'tail' of the wand.

 

Downloads


Navigation:


Dr. Andrew Davison
E-mail: ad@fivedots.coe.psu.ac.th
Back to my home page