POLYVIEW

Synopsis
POLYVIEW
Description

POLYVIEW erases the screen and renders all polygons defined with POLYSTART and POLYEND as shaded polygons. Only shaded polygons are shown. Polygons are illuminated according to the position of the light source using SETTURTLE -3 and lighting configuration that was set with SETLIGHT. Make sure you understand the Polygon Restrictions.

If you need to add other things to your drawing such as LABELs or BITMAPs etc., you must do them after the last POLYVIEW.

You can call POLYVIEW immediately after any POLYEND to watch polygons get shaded as your program builds your object. But keep in mind POLYVIEW is an expensive operation and slows down the program considerably if you call it with every POLYEND.

POLYVIEW is designed to run in PERSPECTIVE mode and does not run in 2D modes.

Example
TO SQUARE
  POLYSTART
  REPEAT 4 [FORWARD 100 RIGHT 90]
  POLYEND
END

PERSPECTIVE
REPEAT 72 [SQUARE RIGHTROLL 5]
POLYVIEW

SourceForge.net Logo