summaryrefslogtreecommitdiffstats
path: root/tests/dimension
diff options
context:
space:
mode:
Diffstat (limited to 'tests/dimension')
-rwxr-xr-xtests/dimension/arithexp.sh9
-rwxr-xr-xtests/dimension/csg.sh35
-rwxr-xr-xtests/dimension/demo.sh26
-rwxr-xr-xtests/dimension/directives.sh23
-rwxr-xr-xtests/dimension/transformations.sh7
5 files changed, 57 insertions, 43 deletions
diff --git a/tests/dimension/arithexp.sh b/tests/dimension/arithexp.sh
index 014da06..917f6bc 100755
--- a/tests/dimension/arithexp.sh
+++ b/tests/dimension/arithexp.sh
@@ -21,10 +21,11 @@
arithexp=$(${top_builddir}/dimension/dimension --parse ${srcdir}/arithexp.pov)
arithexp_exp="$(echo -n \
-'((sphere
- (vector (float 2) (float 2) (float 3) (integer 0) (integer 0))
- (float 0.718282)
- object-modifiers))' \
+'((object
+ (sphere
+ (vector (float 2) (float 2) (float 3) (integer 0) (integer 0))
+ (float 0.718282))
+ object-modifiers))' \
| tr '\n' ' ' | sed -r 's/[[:space:]]+/ /g')"
if [ "$arithexp" != "$arithexp_exp" ]; then
diff --git a/tests/dimension/csg.sh b/tests/dimension/csg.sh
index 360398c..8a45a78 100755
--- a/tests/dimension/csg.sh
+++ b/tests/dimension/csg.sh
@@ -30,33 +30,35 @@ csg_exp="$(echo -n \
(integer 0) (integer 0))))
(background
(vector (integer 0) (float 0.1) (float 0.2) (float 0.1) (integer 0)))
- (union
- (array
- (sphere
- (vector (float -1.5) (float 0) (float 0) (float 0) (float 0))
- (integer 1)
+ (object
+ (union
+ (object
+ (sphere
+ (vector (float -1.5) (float 0) (float 0) (float 0) (float 0))
+ (integer 1))
(object-modifiers
(pigment
(vector (integer 1) (integer 0) (integer 0)
(integer 0) (integer 0))
pigment-modifiers))))
object-modifiers)
- (union
- (array
+ (object
+ (union
(light_source
(vector (integer 0) (integer 20) (integer 0) (integer 0) (integer 0))
(vector (float 0.5) (float 0.5) (float 0.5) (integer 0) (integer 0))
object-modifiers))
object-modifiers)
- (difference
- (array
+ (object
+ (difference
(light_source
(vector (integer -15) (integer 0) (integer 0) (integer 0) (integer 0))
(vector (float 0.5) (float 0.5) (float 0.5) (integer 0) (integer 0))
object-modifiers)
- (sphere
- (vector (float 1.5) (float -20) (float 0) (float 0) (float 0))
- (integer 1)
+ (object
+ (sphere
+ (vector (float 1.5) (float -20) (float 0) (float 0) (float 0))
+ (integer 1))
(object-modifiers
(pigment
(vector (integer 0) (integer 1) (integer 0)
@@ -66,9 +68,12 @@ csg_exp="$(echo -n \
(vector (integer 15) (integer 0) (integer 0) (integer 0) (integer 0))
(vector (float 0.5) (float 0.5) (float 0.5) (integer 0) (integer 0))
object-modifiers)
- (box
- (vector (float 0.7) (float -20.8) (float -0.8) (integer 0) (integer 0))
- (vector (float 2.3) (float -19.2) (float 0.8) (integer 0) (integer 0))
+ (object
+ (box
+ (vector (float 0.7) (float -20.8) (float -0.8)
+ (integer 0) (integer 0))
+ (vector (float 2.3) (float -19.2) (float 0.8)
+ (integer 0) (integer 0)))
(object-modifiers
(pigment
(vector (integer 0) (integer 0) (integer 1)
diff --git a/tests/dimension/demo.sh b/tests/dimension/demo.sh
index 18f1c05..a5f05a5 100755
--- a/tests/dimension/demo.sh
+++ b/tests/dimension/demo.sh
@@ -37,11 +37,13 @@ demo_exp=$(echo -n \
(vector (integer -15) (integer 20) (integer 10) (integer 0) (integer 0))
(vector (integer 1) (integer 1) (integer 1) (integer 0) (integer 0))
object-modifiers)
- (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
+ (difference
+ (object
+ (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
(transformation
(rotation (vector (integer 45) (integer 0) (integer 0)
@@ -60,9 +62,10 @@ demo_exp=$(echo -n \
reflection-items)))
(interior
(ior (float 1.1)))))
- (sphere
- (vector (integer 0) (integer 0) (integer 0) (integer 0) (integer 0))
- (float 1.25)
+ (object
+ (sphere
+ (vector (integer 0) (integer 0) (integer 0) (integer 0) (integer 0))
+ (float 1.25))
(object-modifiers
(texture
(pigment
@@ -73,9 +76,10 @@ demo_exp=$(echo -n \
(phong (float 0.2))
(phong_size (float 40)))))))
object-modifiers)
- (plane
- (vector (integer 0) (integer 1) (integer 0) (integer 0) (integer 0))
- (integer -2)
+ (object
+ (plane
+ (vector (integer 0) (integer 1) (integer 0) (integer 0) (integer 0))
+ (integer -2))
(object-modifiers
(pigment
(vector (integer 1) (integer 1) (integer 1)
diff --git a/tests/dimension/directives.sh b/tests/dimension/directives.sh
index 9bd4c24..3e0233c 100755
--- a/tests/dimension/directives.sh
+++ b/tests/dimension/directives.sh
@@ -73,23 +73,26 @@ directives_exp="$(echo -n \
})' \
| tr '\n' ' ' | sed -r 's/[[:space:]]+/ /g')
$(echo -n \
-'((sphere
- (vector (integer 0) (integer 0) (integer 0) (integer 0) (integer 0))
- (integer 1)
+'((object
+ (sphere
+ (vector (integer 0) (integer 0) (integer 0) (integer 0) (integer 0))
+ (integer 1))
(object-modifiers
(pigment
(vector (integer 1) (integer 1) (integer 1) (integer 0) (integer 0))
pigment-modifiers)))
- (sphere
- (vector (integer 0) (integer 1) (integer 0) (integer 0) (integer 0))
- (integer 1)
+ (object
+ (sphere
+ (vector (integer 0) (integer 1) (integer 0) (integer 0) (integer 0))
+ (integer 1))
(object-modifiers
(pigment
(vector (integer 1) (integer 1) (integer 1) (integer 0) (integer 0))
- pigment-modifiers)))
- (box
- (vector (integer -1) (integer -1) (integer -1) (integer 0) (integer 0))
- (vector (integer 1) (integer 1) (integer 1) (integer 0) (integer 0))
+ pigment-modifiers)))
+ (object
+ (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
(pigment
(vector (integer 1) (integer 1) (integer 1) (integer 0) (integer 0))
diff --git a/tests/dimension/transformations.sh b/tests/dimension/transformations.sh
index 3e6b8e2..65f8b1b 100755
--- a/tests/dimension/transformations.sh
+++ b/tests/dimension/transformations.sh
@@ -21,9 +21,10 @@
transformations=$(${top_builddir}/dimension/dimension --parse ${srcdir}/transformations.pov)
transformations_exp="$(echo -n \
-'((sphere
- (vector (integer 0) (integer 0) (integer 0) (integer 0) (integer 0))
- (integer 0)
+'((object
+ (sphere
+ (vector (integer 0) (integer 0) (integer 0) (integer 0) (integer 0))
+ (integer 0))
(object-modifiers
(transformation
(translation