diff options
author | Tavian Barnes <tavianator@gmail.com> | 2010-04-07 01:17:28 -0400 |
---|---|---|
committer | Tavian Barnes <tavianator@gmail.com> | 2010-04-07 01:17:28 -0400 |
commit | 7d6663eeb68bf9d0a3dff86128827c0c1d85df69 (patch) | |
tree | 7e9c5775d78e0868bf315eeadcfcadacec784707 /tests | |
parent | 2a6bb6c6e0c7d5019e484ab4393941b8801d63ea (diff) | |
download | dimension-7d6663eeb68bf9d0a3dff86128827c0c1d85df69.tar.xz |
Implement CSG in front-end.
Diffstat (limited to 'tests')
-rw-r--r-- | tests/dimension/demo.pov | 46 | ||||
-rwxr-xr-x | tests/dimension/demo.sh | 58 |
2 files changed, 56 insertions, 48 deletions
diff --git a/tests/dimension/demo.pov b/tests/dimension/demo.pov index 3ecc36f..d14cebb 100644 --- a/tests/dimension/demo.pov +++ b/tests/dimension/demo.pov @@ -36,35 +36,37 @@ light_source { <-15, 20, 10>, color rgb <1, 1, 1> } -box { - <-1, -1, -1>, <1, 1, 1> +difference { + box { + <-1, -1, -1>, <1, 1, 1> - rotate 45*x + rotate 45*x - texture { - pigment { - color rgbft <0, 0, 1, 0.25, 0.5> + texture { + pigment { + color rgbft <0, 0, 1, 0.25, 0.5> + } + finish { + reflection { 0.5 } + } } - finish { - reflection { 0.5 } + + interior { + ior 1.1 } } - interior { - ior 1.1 - } -} + sphere { + <0, 0, 0>, 1.25 -sphere { - <0, 0, 0>, 1.25 - - texture { - pigment { - color rgb <0, 1, 0> - } - finish { - phong 0.2 - phong_size 40.0 + texture { + pigment { + color rgb <0, 1, 0> + } + finish { + phong 0.2 + phong_size 40.0 + } } } } diff --git a/tests/dimension/demo.sh b/tests/dimension/demo.sh index f294a4f..687d43c 100755 --- a/tests/dimension/demo.sh +++ b/tests/dimension/demo.sh @@ -35,33 +35,39 @@ demo_exp=$(echo -n \ (light_source (vector (integer -15) (integer 20) (integer 10) (integer 0) (integer 0)) (vector (integer 1) (integer 1) (integer 1) (integer 0) (integer 0))) - (box - (vector (integer -1) (integer -1) (integer -1) (integer 0) (integer 0)) - (vector (integer 1) (integer 1) (integer 1) (integer 0) (integer 0)) - (object-modifiers - (rotate (vector (integer 45) (integer 0) (integer 0) + (difference + (array + (box + (vector (integer -1) (integer -1) (integer -1) (integer 0) (integer 0)) + (vector (integer 1) (integer 1) (integer 1) (integer 0) (integer 0)) + (object-modifiers + (rotate (vector (integer 45) (integer 0) (integer 0) + (integer 0) (integer 0))) + (texture + (pigment + (vector (integer 0) (integer 0) (integer 1) + (float 0.25) (float 0.5))) + (finish + (reflection + (vector (float 0.5) (float 0.5) (float 0.5) + (float 0.5) (float 0.5)) + (vector (float 0.5) (float 0.5) (float 0.5) + (float 0.5) (float 0.5)) + reflection-items))) + (interior + (ior (float 1.1))))) + (sphere + (vector (integer 0) (integer 0) (integer 0) (integer 0) (integer 0)) + (float 1.25) + (object-modifiers + (texture + (pigment + (vector (integer 0) (integer 1) (integer 0) (integer 0) (integer 0))) - (texture - (pigment - (vector (integer 0) (integer 0) (integer 1) - (float 0.25) (float 0.5))) - (finish - (reflection - (vector (float 0.5) (float 0.5) (float 0.5) (float 0.5) (float 0.5)) - (vector (float 0.5) (float 0.5) (float 0.5) (float 0.5) (float 0.5)) - reflection-items))) - (interior - (ior (float 1.1))))) - (sphere - (vector (integer 0) (integer 0) (integer 0) (integer 0) (integer 0)) - (float 1.25) - (object-modifiers - (texture - (pigment - (vector (integer 0) (integer 1) (integer 0) (integer 0) (integer 0))) - (finish - (phong (float 0.2)) - (phong_size (float 40)))))))' \ + (finish + (phong (float 0.2)) + (phong_size (float 40))))))) + object-modifiers))' \ | tr '\n' ' ' | sed -r 's/[[:space:]]+/ /g') if [ "$demo" != "$demo_exp" ]; then |