//My US Flag image // image_width/image_height 610/350 // Vers: 3.6 // Auth: Leroy Whetstone Email llrwii@joplin.com #ifndef(Get) #declare Get=yes;#local Getp=yes; #end #include "StarPigTex.pov" #ifdef(Getp) #undef Get #undef Getp #end #include "colors.inc" #ifndef(Get) camera{ location <0,0,-75> look_at <0,0,0> right x*image_width/image_height } light_source{<0,30,0> color White} light_source{<0,10,-10> color White} #default { finish{ambient 1 diffuse 0} } #background{White} //plane{y,-3 pigment{Green}} #end #local LrBlue=Blue*.6; #local LrRed=Red*.8; #local Stripe=pigment{gradient y color_map{[.5 LrRed][.5 White]} scale 11.5} #local Star= box{<-5,-2,0>,<5,2,.1> pigment{Star_Pig(2,.75, 5,LrBlue,White)scale 1.25 rotate x*90 }} #local Fil= box{<0,-2,0>,<5,2,.1> pigment{LrBlue}} //object{Star} //object{Fil translate -2*x} #local Slprt6=union{ #local Cnt = 0; #while (Cnt < 6) object{Star translate <10*Cnt,4,0>} #local Cnt = Cnt+1; #end } #local Sline=union{ object{Slprt6} object{Fil translate <-5,0,0>} #local Cnt = 0; #while (Cnt < 5) object{Star translate <10*Cnt+5,0,0>} #local Cnt = Cnt+1; #end object{Fil translate <10*Cnt,0,0>} } //feild #declare USFlag= union{ object{Slprt6} #local Cnt = 0; #while (Cnt < 4) object{Sline translate <0,8*Cnt+8,0>} #local Cnt = Cnt+1; #end box{<-5,.0,.1><55,2,0> pigment{LrBlue}} box{<-5,38,.1><55,40,0> pigment{LrBlue}} box{<55,40,.01><125,0,0> pigment{Stripe}} box{<-5,0,.01><125,-34.6,0> pigment{Stripe}} } #local Mn=min_extent(USFlag); #local Mx=max_extent(USFlag); #local Ct=(Mn+Mx)/2; #debug concat("Mn =>",vstr(3,Mn,",",3,3),"\n") #debug concat("Mx =>",vstr(3,Mx,",",3,3),"\n") #ifndef(Get) object{USFlag translate -Ct} #end