// Persistence of Vision Ray Tracer Scene Description File // File: biohazard.pov // Vers: 3.5 // Desc: a biohazard symbol // Date: 2003.972 // Auth: Bob Hughes // Mail: omniverse@charter.net // Note: fits onto/into a one unit radius sphere or disc. Free to use. // cmd:+oC:\images\biohazard_hf-map.png +w500 +h500 +a0.1 +r4 /* Right-click above command-line to add for HF map-making */ #version 3.5; /* 0 = HF map; 1 = planar; 2 = imprint; 3 = pattern; 4 = convex; */ #local Type=4; #local Rad=no; #local AreaLight=no; #local Focus=no; #local Sky=no; #local Ground=yes; #local Media=no; // use with Type=4 #local HF=yes; // invokes Type 1, overriding others. Use square res.! /* ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ */ global_settings { assumed_gamma 1 #if (Rad=yes) radiosity { gray_threshold 0.4 } ambient_light 0 #end #if (HF=yes) hf_gray_16 on #end } /* --------------------------------------------------------------- */ camera { #if (HF=yes) orthographic // for hf map right 3*x up 3*y location <0,0,-9> look_at 0 #else right image_width/image_height*x angle 30 location <1,2,-6> look_at <0.25,-0.1,0> #end #if (Focus=yes) aperture 1 focal_point 0 blur_samples 30 #end } light_source { -1000*z, 1.5 #if (AreaLight=yes) area_light 50*x,50*y,4,4 jitter circular #end fade_distance 333 rotate <30,30,0> } /* --------------------------------------------------------------- */ #if (Sky=yes & HF=no) // suburban clear sky colors sky_sphere { pigment { gradient y color_map { [0.0 rgb <0.7,0.65,0.75>] [0.025 rgb <0.6,0.6,0.8>] [0.05 rgb <0.4,0.6,1.1>] [0.15 rgb <0.25,0.55,1.2>] [0.4 rgb <0.2,0.45,1.1>] [1.0 rgb <0.15,0.35,0.8>] } } } #end #if (Ground=yes & HF=no) plane { y, -1.1 pigment { color rgb 1 } normal { leopard 1 scale 0.1 } finish { ambient 0.15 diffuse 0.5 specular 0.2 roughness 0.08 crand 0.1 } } #end /* ############################################################### */ #declare Ring= difference { cylinder // outer edge { -z,z,1 } cylinder // inner edge { -1.01*z,z*1.01,0.75 } scale 0.95 } // difference #declare Lobes= difference { merge { cylinder // outer edges { -z,z,0.99 translate 0.75*y } cylinder { -z,z,0.99 translate 0.75*y rotate 120*z } cylinder { -z,z,0.99 translate 0.75*y rotate 240*z } } // merge union // inner edges { cylinder { -1.01*z,z*1.01,0.67 translate y } cylinder { -1.01*z,z*1.01,0.67 translate y rotate 120*z } cylinder { -1.01*z,z*1.01,0.67 translate y rotate 240*z } } // union cylinder // center { -1.01*z,1.01*z,0.2 } union // outer gaps { box { -1,1 scale <0.175,0.1,1.01> translate 1.75*y rotate 0*z } box { -1,1 scale <0.175,0.1,1.01> translate 1.75*y rotate 120*z } box { -1,1 scale <0.175,0.1,1.01> translate 1.75*y rotate 240*z } } // union union // inner gaps { box { -1,1 scale <0.05,0.1,1.01> translate 0.25*y rotate 0*z } box { -1,1 scale <0.05,0.1,1.01> translate 0.25*y rotate 120*z } box { -1,1 scale <0.05,0.1,1.01> translate 0.25*y rotate 240*z } } // union } // difference #declare CutLobes= difference { union // outer edges { cylinder { -z,z,1 translate 0.75*y } cylinder { -z,z,1 translate 0.75*y rotate 120*z } cylinder { -z,z,1 translate 0.75*y rotate 240*z } } // union union // inner edges { cylinder { -1.01*z,z*1.01,0.6 translate y } cylinder { -1.01*z,z*1.01,0.6 translate y rotate 120*z } cylinder { -1.01*z,z*1.01,0.6 translate y rotate 240*z } } // union scale <1,1,1.01> } // difference #declare Bio= union { difference { object { Ring } object { CutLobes } } object { Lobes } scale 0.5 } /* %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% */ #if (HF=yes) #local Type=0; #end #switch (Type) #case (0) // for use in height_field #declare Biohazard= object // no thickness { disc { 0,z,1 } clipped_by { object { Bio } } } object { Biohazard pigment { spherical frequency 1 color_map { [0.1 color rgb 1] [0.3 color rgb 0.75] [0.45 color rgb 0.67] [0.6 color rgb 0.5] [0.75 color rgb 0.33] [1 color rgb 0.25] } scale <0.93,0.93,1.5> } normal { wrinkles 0.1 scale <0.75,0.25,1>/2 rotate 50*z } scale 1.5 translate -0.125*y } #break #case (1) // planar #declare Biohazard= /* intersection // slight thickness { box { -1,1 scale <1,1,0.0001> } object { Bio } } */ object // no thickness { disc { 0,z,1 } clipped_by { object { Bio } } } // sphere {0,1 pigment {rgbft 0.5}} // enclosure object { Biohazard pigment { spherical frequency -1 color_map { [0.1 color rgb 0] [0.3 color rgb <1,0,0>] [0.45 color rgb <1,0.5,0>] [0.6 color rgb <1,1,0>] [0.75 color rgb <0,1,0>] [1 color rgb <0,0,1>] } scale <0.93,0.93,1.5> } normal { wrinkles 0.1 scale <0.75,0.25,1>/2 rotate 50*z } finish { ambient 0.05 diffuse 0.8 specular 0.6 roughness 0.01 phong 0.3 phong_size 9 metallic 0.4 brilliance 2 reflection { 0,0.2 exponent 0.4 } } } #break #case (2) // imprint #declare Biohazard= difference { box { -1,1 scale <1,1,0.5> translate 0.5*z } object { Bio } scale <1,1,0.25> } object { Biohazard pigment { spherical frequency -1 color_map { [0.1 color rgb 0] [0.3 color rgb <1,0,0>] [0.45 color rgb <1,0.5,0>] [0.6 color rgb <1,1,0>] [0.75 color rgb <0,1,0>] [1 color rgb <0,0,1>] } scale <0.93,0.93,1.5> } normal { wrinkles 0.1 scale <0.75,0.25,1>/2 rotate 50*z } finish { ambient 0.05 diffuse 0.8 specular 0.6 roughness 0.01 phong 0.3 phong_size 9 metallic 0.4 brilliance 2 reflection { 0,0.2 exponent 0.4 } } } #break #case (3) // pattern sphere { 0,1 pigment { object { Bio translate -z color rgb <1,1,0>, color rgb <1,0,0> } } normal { wrinkles 0.1 scale <0.75,0.25,1>/2 rotate 50*z } finish { ambient 0.05 diffuse 0.8 specular 0.6 roughness 0.01 phong 0.3 phong_size 9 metallic 0.4 brilliance 2 reflection { 0,0.2 exponent 0.4 } } } #break #case (4) // 3D #declare Biohazard= difference { object { Bio } sphere { 0,1 scale <7/8,7/8,1/5> inverse } } object { Biohazard pigment { spherical frequency -1 color_map { [0.1 color rgbt 0] [0.3 color rgbf <1,0,0,1>] [0.45 color rgbf <1,0.5,0,1>] [0.6 color rgbf <1,1,0,1>] [0.75 color rgbf <0,1,0,1>] [1 color rgbf <0,0,1,1>] } scale <0.93,0.93,1.5> } normal { wrinkles 0.1 scale <0.75,0.25,1>/2 rotate 50*z } finish { ambient 0.05 diffuse 0.8 specular 0.6 roughness 0.01 phong 0.3 phong_size 9 metallic 0.4 brilliance 2 reflection { 0,0.2 exponent 0.4 } } interior { // ior 1.2 #if (Media=yes) media { emission 0.1 scattering { 4,2 } density { spherical frequency -1 density_map { [0.1 color rgb 0] [0.25 color rgb <1,0,0>*3] [0.33 color rgb <1,0.5,0>*3] [0.5 color rgb <1,1,0>*3] [0.75 color rgb <0,1,0>*3] [1 color rgb <0,0,1>*3] } scale <0.93,0.93,1.5> } } #end } hollow } #break #end /* #declare P1= pigment { object { Biohazard color rgb 1, color rgb 0 } } #declare P2= pigment { spherical color_map { [0 rgb 1] [1 rgb 0] } } #declare fn_Biohazard= function { pigment { average pigment_map { [0.75 P1] [1 P2] } } } isosurface { function { (fn_Biohazard(x,y,z).gray*.1) // * //(x*x+y*y+z*z/4) } contained_by { sphere { 0,1 } } threshold .05 max_gradient 86 pigment { rgb 1 } finish { ambient 0.05 diffuse 0.8 specular 0.4 roughness 0.01 } } */