Use the controls on the left to add animation, apply textures, turn shadowing on and off, and set the opacity. The JScript code used to generate the animation appears below. Note that in order to use shadows you must have Microsoft® DirectX® 6.x or later installed. You will not get an error if you turn on shadows without DirectX 6.x. It will simply have no effect.
Show more
information.
You can construct or import 3-D graphics (DAGeometry objects), and perform sequences of operations on them in any order. The simplest way to construct a geometry behavior is to import a geometry from an .x formatted file. You can import geometries synchronously or asynchronously. You can augment geometry with lights, including ambient, directional, point, and spot lights. You can attach a sound source to a geometry, which is used to give 3-D spatial characteristics to a sound by embedding it in other geometric models. You can also set a shadow for a geometry.
To set shadows correctly, you must create a visible object and the light to cast shadows. Also, you must set the shadow plane and light position correctly. You need a point and a vector to define the shadow plane. The point is a point on the plane, and the vector defines the normal (a vector perpendicular to the plane) at the point that points toward the object. This is the syntax for shadow: geometryObj.Shadow( geoContainingLights, planePoint, planeNormal). Thus, setting the vector to (0 0 1) means the plane is directly behind the object and the normal points ahead toward the object, while setting the vector to (0 0 -1) means the plane is in front of the object and the normal points back to it. Note that changing the position of the light or the shadow plane changes the shadow's location.