// // Alphabet Blocks // // This file creates wooden blocks with letters of the alphabet on them. // Each defined block has one letter on its front (+z) side and its ROT13 // equivalent letter on the -z side. For instance, BlockA and Block N have both // A and N on a side. This is not entirely redundant because BlockA and BlockN // come with different pigments. This file uses the TIMROM.TTF font by default, // but you can use a different one if you want, although the letters might not // align properly with other fonts. // The blocks are one unit cubes, with their bottom on the y=0 plane, // centered on the y-axis. They are designed for the left-hand coordinate // system, in which y is up. // // http://www.erols.com/vansickl/povray.htm #declare S0=seed(0) #declare Woody = pigment { wood scale <.1,.1,1> turbulence .05 color_map { [.5, rgb <1,.7,.4> ] [1, rgb <.7,.4,.1> ] } } #declare RedPaint = pigment { gradient z pigment_map { [.48 Woody] [.48 rgb <.75,0,0> ] } } #declare YellowPaint = pigment { gradient z pigment_map { [.48 Woody] [.48 rgb <.95,.9,0> ] } } #declare GreenPaint = pigment { gradient z pigment_map { [.48 Woody] [.48 rgb <0,.5,0> ] } } #declare BluePaint = pigment { gradient z pigment_map { [.48 Woody] [.48 rgb <0,0,.75> ] } } #declare R=.05 #declare W=.5 #declare H=1 #declare B=0 #declare Edge= intersection { merge { cylinder { ,,R } cylinder { ,,R } cylinder { ,,R } cylinder { ,,R } box { <-W, B+R,-.51>, } box { , } } box { , inverse } box { , inverse } plane { z,.5 } plane {-z,.5 } bounded_by { box { <-.51,-.01,-.51>,<.51,1.01,.51> } } } #declare BlockA= merge { object {Edge} text { ttf "timrom.ttf" "A",.1,0 rotate y*180 translate <.37,.15,.5> } text { ttf "timrom.ttf" "N",.1,0 translate <-.37,.15,-.5> } pigment { RedPaint translate vrotate(x*7,z*360*rand(S0)) } } #declare BlockB= merge { object {Edge} text { ttf "timrom.ttf" "B",.1,0 rotate y*180 translate <.32,.15,.5> } text { ttf "timrom.ttf" "O",.1,0 translate <-.32,.15,-.5> } pigment { YellowPaint translate vrotate(x*7,z*360*rand(S0)) } } #declare BlockC= merge { object {Edge} text { ttf "timrom.ttf" "C",.1,0 rotate y*180 translate <.32,.15,.5> } text { ttf "timrom.ttf" "P",.1,0 translate <-.32,.15,-.5> } pigment { GreenPaint translate vrotate(x*7,z*360*rand(S0)) } } #declare BlockD= merge { object {Edge} text { ttf "timrom.ttf" "D",.1,0 rotate y*180 translate <.32,.15,.5> } text { ttf "timrom.ttf" "Q",.1,0 translate <-.32,.15,-.5> } pigment { BluePaint translate vrotate(x*7,z*360*rand(S0)) } } #declare BlockE= merge { object {Edge} text { ttf "timrom.ttf" "E",.1,0 rotate y*180 translate <.32,.15,.5> } text { ttf "timrom.ttf" "R",.1,0 translate <-.32,.15,-.5> } pigment { RedPaint translate vrotate(x*7,z*360*rand(S0)) } } #declare BlockF= merge { object {Edge} text { ttf "timrom.ttf" "F",.1,0 rotate y*180 translate <.32,.15,.5> } text { ttf "timrom.ttf" "S",.1,0 translate <-.32,.15,-.5> } pigment { YellowPaint translate vrotate(x*7,z*360*rand(S0)) } } #declare BlockG= merge { object {Edge} text { ttf "timrom.ttf" "G",.1,0 rotate y*180 translate <.32,.15,.5> } text { ttf "timrom.ttf" "T",.1,0 translate <-.32,.15,-.5> } pigment { GreenPaint translate vrotate(x*7,z*360*rand(S0)) } } #declare BlockH= merge { object {Edge} text { ttf "timrom.ttf" "H",.1,0 rotate y*180 translate <.32,.15,.5> } text { ttf "timrom.ttf" "U",.1,0 translate <-.32,.15,-.5> } pigment { BluePaint translate vrotate(x*7,z*360*rand(S0)) } } #declare BlockI= merge { object {Edge} text { ttf "timrom.ttf" "I",.1,0 rotate y*180 translate <.32,.15,.5> } text { ttf "timrom.ttf" "V",.1,0 translate <-.32,.15,-.5> } pigment { RedPaint translate vrotate(x*7,z*360*rand(S0)) } } #declare BlockJ= merge { object {Edge} text { ttf "timrom.ttf" "J",.1,0 rotate y*180 translate <.32,.15,.5> } text { ttf "timrom.ttf" "W",.1,0 translate <-.32,.15,-.5> } pigment { YellowPaint translate vrotate(x*7,z*360*rand(S0)) } } #declare BlockK= merge { object {Edge} text { ttf "timrom.ttf" "K",.1,0 rotate y*180 translate <.32,.15,.5> } text { ttf "timrom.ttf" "X",.1,0 translate <-.32,.15,-.5> } pigment { GreenPaint translate vrotate(x*7,z*360*rand(S0)) } } #declare BlockL= merge { object {Edge} text { ttf "timrom.ttf" "L",.1,0 rotate y*180 translate <.32,.15,.5> } text { ttf "timrom.ttf" "Y",.1,0 translate <-.32,.15,-.5> } pigment { BluePaint translate vrotate(x*7,z*360*rand(S0)) } } #declare BlockM= merge { object {Edge} text { ttf "timrom.ttf" "M",.1,0 rotate y*180 translate <.32,.15,.5> } text { ttf "timrom.ttf" "Z",.1,0 translate <-.32,.15,-.5> } pigment { RedPaint translate vrotate(x*7,z*360*rand(S0)) } } #declare BlockN= merge { object {Edge} text { ttf "timrom.ttf" "N",.1,0 rotate y*180 translate <.32,.15,.5> } text { ttf "timrom.ttf" "A",.1,0 translate <-.32,.15,-.5> } pigment { YellowPaint translate vrotate(x*7,z*360*rand(S0)) } } #declare BlockO= merge { object {Edge} text { ttf "timrom.ttf" "O",.1,0 rotate y*180 translate <.32,.15,.5> } text { ttf "timrom.ttf" "B",.1,0 translate <-.32,.15,-.5> } pigment { GreenPaint translate vrotate(x*7,z*360*rand(S0)) } } #declare BlockP= merge { object {Edge} text { ttf "timrom.ttf" "P",.1,0 rotate y*180 translate <.32,.15,.5> } text { ttf "timrom.ttf" "C",.1,0 translate <-.32,.15,-.5> } pigment { BluePaint translate vrotate(x*7,z*360*rand(S0)) } } #declare BlockQ= merge { object {Edge} text { ttf "timrom.ttf" "Q",.1,0 rotate y*180 translate <.32,.15,.5> } text { ttf "timrom.ttf" "D",.1,0 translate <-.32,.15,-.5> } pigment { RedPaint translate vrotate(x*7,z*360*rand(S0)) } } #declare BlockR= merge { object {Edge} text { ttf "timrom.ttf" "R",.1,0 rotate y*180 translate <.32,.15,.5> } text { ttf "timrom.ttf" "E",.1,0 translate <-.32,.15,-.5> } pigment { YellowPaint translate vrotate(x*7,z*360*rand(S0)) } } #declare BlockS= merge { object {Edge} text { ttf "timrom.ttf" "S",.1,0 rotate y*180 translate <.32,.15,.5> } text { ttf "timrom.ttf" "F",.1,0 translate <-.32,.15,-.5> } pigment { GreenPaint translate vrotate(x*7,z*360*rand(S0)) } } #declare BlockT= merge { object {Edge} text { ttf "timrom.ttf" "T",.1,0 rotate y*180 translate <.32,.15,.5> } text { ttf "timrom.ttf" "G",.1,0 translate <-.32,.15,-.5> } pigment { BluePaint translate vrotate(x*7,z*360*rand(S0)) } } #declare BlockU= merge { object {Edge} text { ttf "timrom.ttf" "U",.1,0 rotate y*180 translate <.32,.15,.5> } text { ttf "timrom.ttf" "H",.1,0 translate <-.32,.15,-.5> } pigment { RedPaint translate vrotate(x*7,z*360*rand(S0)) } } #declare BlockV= merge { object {Edge} text { ttf "timrom.ttf" "V",.1,0 rotate y*180 translate <.32,.15,.5> } text { ttf "timrom.ttf" "I",.1,0 translate <-.32,.15,-.5> } pigment { YellowPaint translate vrotate(x*7,z*360*rand(S0)) } } #declare BlockW= merge { object {Edge} text { ttf "timrom.ttf" "W",.1,0 rotate y*180 translate <.32,.15,.5> } text { ttf "timrom.ttf" "J",.1,0 translate <-.32,.15,-.5> } pigment { GreenPaint translate vrotate(x*7,z*360*rand(S0)) } } #declare BlockX= merge { object {Edge} text { ttf "timrom.ttf" "X",.1,0 rotate y*180 translate <.32,.15,.5> } text { ttf "timrom.ttf" "K",.1,0 translate <-.32,.15,-.5> } pigment { BluePaint translate vrotate(x*7,z*360*rand(S0)) } } #declare BlockY= merge { object {Edge} text { ttf "timrom.ttf" "Y",.1,0 rotate y*180 translate <.32,.15,.5> } text { ttf "timrom.ttf" "L",.1,0 translate <-.32,.15,-.5> } pigment { RedPaint translate vrotate(x*7,z*360*rand(S0)) } } #declare BlockZ= merge { object {Edge} text { ttf "timrom.ttf" "Z",.1,0 rotate y*180 translate <.32,.15,.5> } text { ttf "timrom.ttf" "M",.1,0 translate <-.32,.15,-.5> } pigment { YellowPaint translate vrotate(x*7,z*360*rand(S0)) } }