pov-ray/csgdemo.pov

56 lines
1014 B
POVRay
Raw Normal View History

2014-02-01 23:10:16 -06:00
#version 3.7;
#include "colors.inc"
global_settings {
2014-02-03 20:32:32 -06:00
assumed_gamma 1.8
2014-02-01 23:10:16 -06:00
}
camera {
right x*1280/720
location <0, 1, -10>
look_at 0
angle 36
}
light_source { <500, 500, -1000> White }
plane { y, -1.5
pigment { checker Green White }
}
#declare lens_hole = difference {
intersection {
sphere { <0, 0, 0>, 1
translate -0.5*x
}
sphere { <0, 0, 0>, 1
translate 0.5*x
}
rotate 90*y
}
cylinder { <0, 0, -1> <0, 0, 1>, .35
}
}
#declare thing = merge {
object { lens_hole translate <-.65, .65, 0> }
object { lens_hole translate <.65, .65, 0> }
object { lens_hole translate <-.65, -.65, 0> }
object { lens_hole translate <.65, -.65, 0> }
pigment { Red filter .4 }
}
#declare abox = difference {
box { -1, 1 pigment { Red } }
cylinder { -1.001*z, 1.001*z, 0.5 pigment { Green } }
}
intersection {
object { thing }
object { abox }
translate <0 ,.25, 0>
}