"""Draw polygon-based text. Depends on fonttools: http://sourceforge.net/projects/fonttools/ FIXME: Mouse movement slows down animation (only with polytext). by stephan) """ from slut import * textstring = "voodoo programming: n. 1. The use by guess or cookbook of \ an obscure or hairy system, feature, or algorithm that one does not truly \ understand. The implication is that the technique may not work, and if it \ doesn't, one will never know why. Almost synonymous with black magic, except \ that black magic typically isn't documented and nobody understands it. \ Compare magic, deep magic, heavy wizardry, rain dance, cargo cult \ programming, wave a dead chicken, SCSI voodoo." class Atlantis(World): def onSetup(self): self.name = "Polygonal Text" self.width = 800 self.height = 600 st = SpriteText(self, 'sp0', "euromode") st.setText(textstring) st.setExtrusion(0.05) st.setColor(0.8, 0.0, 0.0, 1.0) st.enableMouseEvents() st.rotBy(0.0, 90.0, 0.0) st.scaleTo(1.8, 0.8, 0.8) st.moveBy(Thrust(0.0, 0.0, 0.5)) self.camera.orbitBy(SineTween(20.0, -50.0, 0.0, 4.0)) atlantis = Atlantis() atlantis.run()