home *** CD-ROM | disk | FTP | other *** search
- #
- # Simple demo of handling coplanar Booleans.
- #
- # Gershon Elber, July 1992.
- #
-
- coplanar=1; # Try it with coplanar = 0 to see the difference.
-
- a = cylin(vector( 0.0, 0.0, 0.0 ), vector( 0.0, 0.0, 1.0 ), 1.0);
- b = cylin(vector( 0.5, 0.0, 0.0 ), vector( 0.0, 0.0, 1.0 ), 1.0);
-
- interact(list(a,b), 0 );
-
- c = a+b;
- interact(list(c), 0 );
-
- c = a*b;
- interact(list(c), 0 );
-
- c = a-b;
- interact(list(c), 0 );
-
- c = b-a;
- interact(list(c), 0 );
-
- a = cylin(vector( 0.0, 0.0, 0.0 ), vector( 0.0, 0.0, 1.0 ), 1.0);
- b = a * scale(vector( 2.0, 0.5, 1.0 ));
- interact(list(a,b), 0 );
-
- c = a+b;
- interact(list(c), 0 );
-
- c = a*b;
- interact(list(c), 0 );
-
- c = a-b;
- interact(list(c), 0 );
-
- c = b-a;
- interact(list(c), 0 );
-
- a = box(vector( -2.0, -2.0, 0.0 ), 4.0, 4.0, 1.0 );
- b = cylin(vector( 0.0, 0.0, 0.0 ), vector( 0.0, 0.0, 2.0 ), 1.0 );
- interact(list(a,b), 0 );
-
- c = a+b;
- interact(list(c), 0 );
-
- c = a*b;
- interact(list(c), 0 );
-
- c = a-b;
- interact(list(c), 0 );
-
- c = b-a;
- interact(list(c), 0 );
-