home *** CD-ROM | disk | FTP | other *** search
- ;---------------------------------------------
- ;File name: 3dmeshes.SCR
- ;Purpose: Demonstrate
- ;
- ;Last Modified: 3/18/98
- ;---------------------------------------------
- CMDECHO
- 0
- PICKBOX
- 3
- APERTURE
- 10
- ;
- ; Erase anything that's there already.
- erase
- all
-
- ; Turn blips off
- blipmode
- off
- ; Set the current layer to zero.
- layer
- s
- 0
-
- color
- bylayer
- ; Look at the whole scene from just below the SouthWest Isometric Viewpoint.
- vpoint
- -1,-1,.7
- ; Zoom to a big window.
- zoom
- c
- 118,80
- 500
- ; Setting all the other necessary system variables:
- elev
- 0
- 0
- gridmode
- 0
- fillmode
- 1
- snapmode
- 0
- linetype
- s
- bylayer
-
- ; Draw everything in continuous lines.
- linetype
- s
- continuous
-
- ; Draw 8 white lines for visual reference.
- line
- 0,240
- 200,240
-
- line
- 0,200
- 200,200
-
- line
- 0,160
- 200,160
-
- line
- 0,120
- 200,120
-
- line
- 0,80
- 200,80
-
- line
- 0,40
- 200,40
-
- line
- 0,0
- 200,0
-
- line
- 0,-40
- 200,-40
-
- line
- 240,-40
- 240,200
- ;*************************************************************************
- ;*************************************************************************
- ;BOXES
- ;*************************************************************************
- ;*************************************************************************
-
- ; Draw the boxes in red.
- layer
- m
- boxes3dm
- c
- red
-
-
- ; Draw 2 boxes (not cubes) next to each other.
- box
- 10,120,0
- length
- 16
- 12
- 8
- box
- 26,118,0
- length
- 16
- 16
- 10
- ; Draw a stack of 3 cubes by specifying starting points and lengths.
- box
- 50,120,0
- c
- 10
- box
- 51,121,10
- c
- 8
- box
- 52,122,18
- c
- 6
- ; Draw 4 concentric cubes by specifying centers and cube lengths.
- box
- c
- 100,130,10
- c
- 20
- box
- c
- 100,130,10
- c
- 15
- box
- c
- 100,130,10
- c
- 10
- box
- c
- 100,130,10
- c
- 5
- ;Boxes using Center and length, width and height
- box
- c
- 127,160
- l
- 10
- 10
- 10
- box
- c
- 140,160,10
- l
- 5
- 5
- 5
- ;Boxes using center, corner and height
- box
- c
- 155,160
- 161,167
- 5
- box
- c
- 155,160,10
- 157,163,5
- ;Boxes using Corner, and then other Corner and Height
- box
- 176,160
- 188,168
- 5
- box
- 176,160,20
- 180,168,20
- 5
- box
- 176,160,10
- 180,168,15
- ;3D>Box command using Corner, length, cube and rotation
- 3D
- box
- 193,160
- 193,169
- cube
- 15
- ;3D>Box command using corner, length, width, height and rotation
- 3D
- box
- 193,160
- 20
- 15
- 5
- 15
- ; Show what the boxes look like.
- ; hide
- ;*************************************************************************
- ;*************************************************************************
- ;SPHERES
- ;*************************************************************************
- ;*************************************************************************
- ; Make a blue layer for spheres.
- layer
- m
- spheres3dm
- c
- blue
-
-
- ; Draw 2 spheres by specifying centers and radii.
- ; Accept the defaults of 16 segments in both directions.
- 3d
- sphere
- 10,80,10
- 10
-
-
- 3d
- sphere
- 30,80,10
- 10
-
-
- ;Again, but with negative values
- 3d
- sphere
- 10,80,-10
- 10
-
-
- ; And with no Z value
- 3d
- sphere
- 30,80
- 5
-
-
- ; Draw a stack of spheres by specifying centers and diameters.
- 3d
- sphere
- 80,80,10
- d
- 20
- 32
- 32
- ;Draw these spheres using Sphere, rather than 3d > Sphere
- sphere
- 80,80,26
- 6
- sphere
- 80,80,35
- d
- 6
- ; Draw 4 concentric spheres.
- 3d
- sphere
- 120,80,20
- 20
- 32
- 16
- color
- green
- 3d
- sphere
- 120,80,20
- 15
- 20
- 10
- color
- yellow
- 3d
- sphere
- 120,80,20
- 10
- 16
- 8
- color
- white
- 3d
- sphere
- 120,80,20
- 5
- 6
- 4
- color
- bylayer
- ; Show what we have so far.
- ; hide
- ;*************************************************************************
- ;*************************************************************************
- ;WEDGES & 3D WEDGES
- ;*************************************************************************
- ;*************************************************************************
- ; Make a layer for wedges specified by their corners.
- layer
- m
- wedges-corner3dm
- c
- yellow
-
-
- ; Draw 4 wedges (all back-to-back) using opposite corners.
- wedge
- 20,40,0
- 30,60,10
- wedge
- 20,40,0
- 10,60,0
- 10
- wedge
- 20,40,0
- 30,60,-10
- wedge
- 20,40,0
- 10,60,-10
- ; Draw 4 wedges using corner/cube method. Command should repeat on its own.
- wedge
- 50,40,0
- c
- 20
-
- 70,60,20
- c
- -20
-
- 50,60,0
- c
- -20
-
- 30,40,-20
- c
- 20
- ; Draw wedges using opposite corners and height.
- wedge
- 80,60
- 100,40
- 5
- wedge
- 100,40
- 120,60
- 15
- ; Draw 4 wedges using length, width and height.
- wedge
- 130,40,0
- length
- -10
- 30
- 15
-
- 130,40,0
- length
- 10
- 30
- 15
-
- 130,50,0
- length
- -10
- -10
- -30
-
- 130,50,0
- length
- 10
- -10
- -30
- ;hide
- ; Make a new layer for wedges specified by their centers.
- layer
- m
- wedges-center3dm
- c
- green
-
-
- ; Draw little spheres to show where the centers of the wedges are.
- ; The spheres should end up being "embedded" in the faces of each wedge.
- 3d
- sphere
- 0,0,0
- 1
- 4
- 4
- 3d
- sphere
- 20,0,0
- 1
- 4
- 4
- 3d
- sphere
- 40,0,0
- 1
- 4
- 4
- 3d
- sphere
- 60,0,0
- 1
- 4
- 4
- 3d
- sphere
- 80,0,0
- 1
- 4
- 4
- 3d
- sphere
- 100,0,0
- 1
- 4
- 4
- ; Draw wedges by specifying the center first.
- ; First, center, 3D-corner
- wedge
- c
- 0,0,0
- -5,5,5
- ; Next, center, 2D-corner, height
- wedge
- c
- 20,0,0
- 22,16
- 12
- ; Center, cube, length
- wedge
- c
- 40,0,0
- cube
- 10
-
- c
- 60,0,0
- cube
- -10
- ; Center, length, width, height
- wedge
- c
- 80,0,20
- l
- 15
- 30
- 10
- wedge
- c
- 100,0,20
- l
- -15
- -30
- -10
- ; Again, but with no Z values
- wedge
- c
- 80,0
- l
- 15
- 30
- 10
- wedge
- c
- 100,0
- l
- -15
- -30
- -10
- ; Using 3D > Wedge
- 3d
- wedge
- 80,0,-30
- 10
- 10
- 10
- 15
- ; Another one, but with no z value
- 3d
- wedge
- 80,30
- 10
- 10
- 10
- 15
- ; Show what we have so far.
- ;hide
- ;*************************************************************************
- ;*************************************************************************
- ;CONES
- ;*************************************************************************
- ;*************************************************************************
- ; Make a magenta layer for cones
- layer
- m
- cones3dm
- c
- magenta
-
-
- ; Draw some cylindrical pointy cones next to the yellow wedges.
- ; The first 4 are specified by radius.
- 3d
- cone
- 160,40,0
- 8
- 0
- 30
- 16
- ; This one should accept the default of zero for the radius of the top.
- 3d
- cone
- 180,40,0
- 8
-
- 20
- 8
- 3d
- cone
- 200,40,0
- .0001
- 6
- 30
- 12
- 3d
- cone
- 200,40,30
- 6
- 0
- 30
- 12
- ; These pointy cones use diameter.
- 3d
- cone
- 120,0,-50
- d
- .0001
- 10
- 50
- 32
- 3d
- cone
- 140,0,0
- d
- 20
- 0
- 10
- 32
- 3d
- cone
- 140,0,-10
- d
- .0001
- 10
- 10
- 32
- 3d
- cone
- 160,0,0
- d
- 16
- 0
- 20
- 32
- 3d
- cone
- 160,0,-20
- d
- .0001
- 8
- 20
- 32
- ; Draw cut-off cones using radius and diameter along the first line (-40)
- ; The first one uses radii in both places.
- 3d
- cone
- 0,-40,0
- 10
- 5
- 10
- 24
- ; The second one uses diameters in both places.
- 3d
- cone
- 20,-40,0
- d
- 20
- d
- 10
- 10
- 24
- ; This one should look "upside down".
- 3d
- cone
- 40,-40,0
- 5
- 10
- 20
- 32
- ; This last set should look like a slow-motion water drop...sort of.
- 3d
- cone
- 180,-40,0
- 20
- 40
- 5
- 64
- 3d
- cone
- 180,-40,0
- 20
- 10
- 7
- 32
- 3d
- cone
- 180,-40,0
- 6
- 10
- 7
- 24
- 3d
- cone
- 180,-40,0
- 6
- 0
- 15
- 16
- ;This cone uses radius and then diameter
- 3d
- cone
- 200,120
- 10
- d
- 1
- 10
- 4
- ;cone with elliptical > center > height
- cone
- e
- c
- 98,200
- 98,215
- 97,184
- 10
- ;Again, with 3d points
- cone
- e
- c
- 98,200,10
- 98,215,10
- 97,184,10
- 10
- ;Here's a spare sphere
- 3d
- sphere
- 180,-40,25
- 2
- 8
- 8
- ;Cone with elliptical > axis > height
- cone
- e
- 52,200
- 51,212
- 52,192
- 15
- ;Another one with Z values
- cone
- e
- 52,200,10
- 51,212,10
- 52,192,10
- 15
- ;Cone with Centerpoint > Diameter > Apex
- Cone
- 81,200
- d
- 10
- a
- 81,200,20
- ;Again, but with X, Y and Z values.
- cone
- 81,200,20
- d
- 10
- a
- 81,200,40
- ;Again, but with negative values
- cone
- 81,200,0
- d
- 10
- a
- 81,200,-20
- ;Cone with Centerpoint > Diameter > Height
- cone
- 98,200
- d
- 10
- 10
- ;Again, with Z values
- cone
- 98,200,20
- d
- 10
- 10
- ;Again, with negative values - Commented out until fixed
- cone
- 98,200,-10
- d
- 10
- -10
- ;Cone with Centerpoint > Radius >Apex
- cone
- 116,200
- 8
- a
- 116,208
- ;Again, with Z values
- cone
- 116,200,10
- 8
- a
- 116,200,20
- ;Cone with Centerpoint > Radius > Height
- cone
- 135,200
- 6
- 15
- ;Again, with Z values
- cone
- 135,200,20
- 6
- 5
- ;Again, with negative values
- cone
- 135,200,-10
- 6
- 5
- ;
- ;hide
- ;*************************************************************************
- ;*************************************************************************
- ;TORI
- ;*************************************************************************
- ;*************************************************************************
- ; Now we'll do toruses/tori.
- layer
- m
- toriods3dm
- c
- green
-
-
- ; The first two should look the same, one hovering over the other.
- ; Torus > Radius > Radius
- 3d
- torus
- 20,200,4
- 20
- 4
- 16
- 32
- ; Torus > Radius > Diameter
- 3d
- torus
- 20,200,50
- 10
- d
- 4
- 30
- 20
- ; Again using no z value
- 3d torus
- 20,200
- 10
- d
- 4
- 30
- 20
- ; Torus using Center > Diameter > Radius
- 3d
- torus
- 20,200,80
- d
- 10
- 2
- 12
- 12
- ; Again, but no z value
- 3d
- torus
- 40,200
- d
- 10
- 2
- 12
- 12
- ; Again, but with a negative z value
- 3d
- torus
- 20,200,-30
- d
- 10
- 2
- 3
- 12
- ; 3D >Torus using Center > Diameter > Diameter
- 3d
- torus
- 20,200,24
- d
- 40
- d
- 8
- 16
- 32
- ; Torus without 3D > Center > Radius > Radius
- Torus
- 20,200,60
- 10
- 4
- ;Torus without 3D > Center > Radius > Diameter
- torus
- 20,200,50
- 20
- d
- 5
- ; Again, but with no Z value
- torus
- 70,200
- 20
- d
- 5
- ; Torus without 3d > Center > Diameter
- torus
- 70,200,50
- d
- 20
- d
- 5
- ; Again, but with no z
- torus
- 70,200
- d
- 20
- d
- 5
- zoom
- c
- 118,80
- 200
- ; Show what we have so far, then regen to show everything.
- hide
- setvar
- cmdecho
- 0
- ;----------------------------------------------------------------------
- ;Now for the grand finale
- text
- -67,15,0
- 6
-
- Done!
-
-
-
- ;----------------------------------------------------------------------
-