home *** CD-ROM | disk | FTP | other *** search
- // Persistence of Vision Raytracer
- // Sample Quartic file
- // by Alexander Enzmann
-
- #include "shapes.dat"
- #include "colors.dat"
- #include "textures.dat"
- #include "shapesq.dat"
-
- #declare Metal_Texture = texture { You need to supply a colour...}
- metallic
- ambient 0.3 diffuse 0.7
- brilliance 6.0
- reflection 0.25
- phong 0.75 phongsize 20
- end_texture
-
- #declare BrassColor = colour red 0.71 green 0.65 blue 0.26
- #declare BrassTexture = texture
- Metal_Texture colour BrassColor
- end_texture
-
- #declare GlassTexture = texture
- color White
- refraction 0.5 reflection 0.5 ior 1.3
- end_texture
-
- composite
- { Lemniscate of Gerono }
- { Top half of hourglass }
- object
- quartic Lemniscate end_quartic
- bounded_by
- sphere <0 0 0> 2.01 end_sphere
- end_bound
- color CRed
- texture GlassTexture end_texture
- rotate <0 0 -90>
- end_object
-
- { Lemniscate of Gerono }
- { Lower half of hourglass }
- object
- quartic Lemniscate end_quartic
- bounded_by
- sphere <0 0 0> 2.01 end_sphere
- end_bound
- color CBlue
- texture GlassTexture end_texture
- rotate <0 0 90>
- end_object
-
- {Top plate }
- object
- intersection Y_Disk end_intersection
- scale <0.9 0.15 0.9>
- translate <0.0 1.0 0.0>
- color CGreen
- texture BrassTexture end_texture
- end_object
- {Lower plate }
- object
- intersection Y_Disk end_intersection
- scale <0.9 0.15 0.9>
- translate <0.0 -1.0 0.0>
- color Cyan
- texture BrassTexture end_texture
- end_object
-
- { 3 Brass pillars }
- object
- intersection Y_Disk end_intersection
- scale <0.075 2.0 0.075>
- translate <0.0 -1.0 0.8>
- color Yellow
- texture BrassTexture end_texture
- end_object
- object
- intersection Y_Disk end_intersection
- scale <0.075 2.0 0.075>
- translate <0.0 -1.0 0.8>
- rotate <0.0 120.0 0.0>
- color Yellow
- texture BrassTexture end_texture
- end_object
- object
- intersection Y_Disk end_intersection
- scale <0.075 2.0 0.075>
- translate <0.0 -1.0 0.8>
- rotate <0.0 240.0 0.0>
- color Yellow
- texture BrassTexture end_texture
- end_object
-
- bounded_by
- intersection Y_Disk
- scale <1.0 2.5 1.0>
- end_intersection
- end_bound
-
- scale <4 4 4>
- rotate <0.0 30.0 0.0>
- translate <0 3 5>
- end_composite
-
- view_point
- location <0.0 3.0 -22.0>
- right <1.0 0.0 0.0>
- up <0.0 1.0 0.0>
- direction <0.0 0.0 2.0>
- look_at <0.0 3.0 0.0>
- end_view_point
-
- object
- sphere <0 0 0 > 1 end_sphere
- translate <200 30 -30>
- texture
- colour White
- ambient 1.0
- diffuse 0.0
- end_texture
- light_source
- colour White
- end_object
-
- object
- sphere <0 0 0> 1 end_sphere
- translate <-200 30 -300>
- texture
- colour White
- ambient 1.0
- diffuse 0.0
- end_texture
- light_source
- colour White
- end_object
-
- { Put down floor }
- {***object
- plane <0.0 1.0 0.0> -30.0 end_plane
- texture
- Dark_Wood
- scale <10 2 2>
- ambient 0.3
- diffuse 0.7
- reflection 0.5
- end_texture
- rotate <5 0 0>
- end_object***}
-
-