![]() Generated Jan 7, 2000. ©1999 WildTangent Inc. All Rights Reserved. Continuously updated online documentation, samples, and tutorials are available in the Online Reference.
Adds a WTDrop to the camera viewpoint. WTDrop addDrop( WTBitmap image [, BOOL front] )
This method creates a The optional last updated: 09/07/99 01:42PM
Adds a child drop to a parent drop. WTDrop addDrop( WTBitmap bitmap [, int zorder ] )
This method creates a The optional last updated: 09/02/99 01:43AM
Adds the passed object to the group. void addObject( object );
This method is used to add a last updated: 07/22/99 04:44PM
Adds a model or bitmap object to a container so it can be manipulated and displayed. void attach( WTObject object )
This method attaches a model or bitmap object to a container. Every "visual", whether it be a built-in primitive model such as a box or cone, a file-based model, or a bitmap, needs to be attached to a The container must be added to the stage or to a group which has been added to the stage before the attached visual will be rendered. Once attached, objects can be detached with the If the generic last updated: 10/14/99 04:04PM
Adds a WTBitmap object to a container. void attachBitmap( WTBitmap image, float scaleWidth, float scaleHeight, int origin_x, int origin_y )
This method is similar to attach(), but instead of a model, the user supplies a bitmap to be added to the The scaleWidth and scaleHeight parameters alter the scale of the object. For most purposes, use a value of 1 for each, which will display the bitmap in its original size. The origin_x and origin_y parameters are used to specify where the image's center is, in pixels. A 31 pixel by 31 pixel bitmap's natural center would be 16,16. last updated: 08/26/99 02:25PM
Checks the driver version. int checkVersion( string version [, string chkversion ] )
This method checks the current version of the driver or compares two driver versions. If only one parameter, Although versions are passed as strings of the form "X.X.X.X", they are compared internally as four byte sequences, so version 1.2.3.4 would be interpreted as (4 + 256(3 + 256(2 + 256 * 1))). The numerical result is returned by the method. For example, if last updated: 09/09/99 01:27PM
Creates a WTAudioClip object from a media file. WTAudioClip createAudioClip( string path [, int volitility ] )
This method creates a The optional For more information on preparing source media, see the overview. last updated: 09/13/99 11:03AM
Creates a WTBitmap object from a media file. WTBitmap createBitmap( string path [, int volitility ] ) This method creates a WTBitmap object from a media file. Media files must be prepared using the WildConvert utility. The optional For more information on preparing source media, see the overview. Media files load asynchronously; this method returns immediately and the bitmap will start loading. Once the bitmap is fully loaded its If the bitmap file cannot be found or the data is corrupted or incorrect,
last updated: 09/13/99 11:15AM
Creates an empty WTBitmap object. WTBitmap createBlankBitmap( int width, int height ) This method creates an empty bitmap with the dimensions specified. The bitmap serves as a canvas that you can draw on with other bitmap methods. last updated: 09/13/99 11:23AM
Creates a box model. WTModel createBox( float width, float height, float depth [, int tilesPerEdge ] )
Creates a box model that can be used in a scene. To render the box in a scene, it must be added to a DirectX versions 5 and earlier have difficulty rendering textured faces that are not subdivided, causing a 'warping' effect as points of the face travel outside the view's clipping rectangle. If you encounter this problem, the optional last updated: 09/13/99 11:29AM
Creates a camera that the scene can render through. WTCamera createCamera(); This method creates a camera object through which the scene will be rendered. The camera object behaves just like a The resulting camera object is automatically added to the stage -- it's not necessary to use the last updated: 08/30/99 02:14PM
Creates a cone model. createCone( float height, float radius, int sides, int captype )
This method creates a 3D cone model for use in a scene. Use The captype parameter defines the behavior of the base of the cone. A value of 0 creates a solid base that will render when visible. A value of 1 removes the base of the cone and makes any inside portion invisible, while a value of 2 removes the base but renders the interior. A default cone will be positioned with the center of its base at x=0, y=0, z=0, and its tip at x=0, y=height, z=0. last updated: 09/13/99 11:32AM
Creates a container for a model or bitmap. WTContainer createContainer()
To add any visual object to the scene, a last updated: 09/13/99 11:35AM
Creates a cylinder model. WTModel createCylinder( float height, float radius, int sides, int captype )
This method creates a cylinder model The captype parameter determines how the top and bottom of the cylinder will be rendered. A value of 0 will display the top and bottom surfaces when they're visible. A value of 1 removes the top and bottom of the cylinder and makes any inside surfaces invisible, while a value of 2 removes the top and bottom and renders any visible interior surfaces. To use this object in a scene, you must add it to a last updated: 09/13/99 11:39AM
Creates a group to use for placement of child objects. WTGroup createGroup()
This method creates a group object that can be used to manage child objects more efficiently. After being added to a To add an object to a group, use the group's Note that groups can have groups inside them, creating an arbitrary child-parent heirarchy. Each modification made to a group is relative to the parent group. last updated: 09/13/99 11:43AM
Creates a light. WTLight createLight( int type ) This method creates a light of user-specified type. The available types are summarized in the table below.
Lights are similar to containers in that they can be positioned and oriented. For example, you can create a spotight, add it to a stage, and then manipulate it with the Both the color and intensity of a light can be adjusted with the For more information on lighting, see the lighting overview. last updated: 09/13/99 12:11PM
Creates a line model. WTModel createLine( float x1, float y1, float z1, float x2, float y2, float z2, float radius, int sides, int captype, int ltype )
This method creates a 3D line model for use in a scene. The The radius parameter determines the radius of the line. The The The last updated: 09/13/99 12:19PM
Create a model using data loaded from the specified location. WTModel createModel( string path [, int volitility ]);
This method creates a 3D model using data loaded from the file specified. To render the model, it should be associated with a container object using the The only currently supported model file format is the .wt format. These files must be converted from the Microsoft .x format using the WildConvert utility. The optional For more information on preparing source media, see the overview. Models will load asynchronously; the If the model file cannot be found or the data is corrupted or incorrect,
last updated: 09/13/99 12:28PM
Creates a patch model. WTModel createPatch(int nsPts, int ntPts, single sEdgelen, single tEdgelen, single xTL, single zTL)
This method creates a 3D patch model, which initially will look very similar to a 3D plane model. A patch is created with its own set of surface coordinates (s,t). The The primary difference between a patch and a plane is that the patch has its own surface coordinates (s,t) which can be offset from their initial positions after the patch is created. These surface coordinates also allow for precise control over texture positioning. last updated: 10/15/99 11:31AM
Creates a plane model. createPlane( float w, float h [, BOOL doublesided ][, float pivotOffsetX ][, float pivotOffsetY ][, int nTilesPerEdge ] )
This method creates a 3D plane for use in a scene. The resulting plane is The optional The optional A default plane will be positioned with its center (determined by the pivot point) at x=0, y=0, z=0. The plane will be "facing" in the positive z direction. This means that, depending on your camera position, it could be facing away from your camera, making it invisible. Use the DirectX versions 5 and earlier have difficulty rendering textured faces that are not subdivided, causing a 'warping' effect as points of the face travel outside the view's clipping rectangle. If you encounter this problem, the optional last updated: 09/13/99 12:30PM
Create the main stage for the scene. WTStage createStage()
The stage serves as the master parent for all objects created within the scene. The stage does not have a parent. Before a visual object will be rendered, it must be attached to a container and added to the stage, or to a group that is added to the stage. To add an object to the stage, use the stage's last updated: 09/13/99 12:56PM
Opens a debug window. void debugWindow( bool status )
This method displays a debug window that can be used to monitor content during execution. A value of last updated: 09/13/99 12:56PM
Frees the resources associated with a bitmap. destroy()
This method is intended for use with scripting languages that don't provide control over memory management. Invoking this method will cause the last updated: 09/15/99 01:33AM
Detaches an object from a container. void detach(); Detaches a model or bitmap from a container. Detached objects still exist; if an object is attached to several containers then detaching it from one will not detach it from the others. Once detached, an object can be attached back to the original container or any other container. Note that since a container may only hold one visual object, it's not necessary to specify the object to be detached. Use the last updated: 07/23/99 03:15PM
Draws a filled rectangle. void drawFillRect( int x, int y, int width, int height )
This method draws a filled rectangle in the current draw color. The last updated: 09/09/99 01:46PM
Draws a line in the target bitmap. drawLine( int x1, int y1, int x2, int y2 );
This method draws a line between the specified points. The line is drawn in the color last specified using the last updated: 07/27/99 04:23PM
Draws a pixel in the target bitmap. drawPixel( int x, int y );
This method sets a single pixel in the target bitmap to the color last specified using the last updated: 07/27/99 04:20PM
Displays text on a WTBitmap object in the location specified. void drawText( int x_coord, int y_coord, String text );
This method prints a string of text on the target bitmap at the x and y coordinates specified. A group of methods including last updated: 07/23/99 03:21PM
Indicates whether or not a file has been completely read. bool eof(); This method returns TRUE if the file has been completely read and FALSE otherwise. The method will only return TRUE if a read past the end of the file has been attempted. For example, if a file contains two floats, and both have been read, then As an historical note, C, Java, and Basic all work the same way, setting Since calling from JavaScript into the WildTangent Web Driver can be expensive, here is a tip for making fewer eof calls:
Slow code: Fast code: The slow code makes twice as many calls to the WebDriver as the fast code. last updated: 07/26/99 03:28PM
Returns a vector describing the position of the object in world coordinates. WTVector getAbsolutePosition();
This method returns a This position is in world coordinates (relative to the stage). Values for individual axes can be retrieved from the last updated: 07/23/99 03:29PM
Returns the current angle value of a WTOrientation3D object. float getAngle();
Returns the current angle value, in degrees, of a last updated: 07/23/99 03:30PM
Gets the model or bitmap that has been attached to the container. WTObject getAttached(); Gets the model or bitmap that has been attached to the container. This is particularly useful when handling events, since mouse pick events return the container that was picked. Since models may be attached to several containers, there is no corresponding method on the model to get the container to which the model is attached. last updated: 07/23/99 03:32PM
Gets the absolute height of the WTBitmap object found in the WTDrop. int getBitmapHeight();
Gets the absolute height of the last updated: 07/23/99 03:33PM
Gets the absolute width of the WTBitmap object found in the WTDrop. int getBitmapWidth();
Gets the absolute width of the last updated: 07/23/99 03:35PM
Returns the mouse button state during a MouseEvent. int getButtonState() This method returns the state of the mouse buttons and control keys during a mouse event. Since multiple buttons and keys may be depressed simultaneously, the resulting integer is a sum that represents the combined state using one or more of the following values:
For example, a return value of 5 indicates that the left button and shift key were depressed simultaneously. Be aware that this method indicates that the buttons are pressed, not necessarilywhen they were pressed. It should be used to check for buttons when they're used as modifiers for other events - attempting to use them to detect specific press events is inefficient. Instead, use the last updated: 09/22/99 02:00AM
Gets the camera that the mouse is over. WTCamera getCamera(); Gets the camera that the mouse is over. This method is only valid for mouse events. last updated: 07/23/99 03:43PM
Gets the constant attenuation factor for a light. float getConstantAttenuation(); This method returns the constant attentuation factor for a light. The method is only applicable to point and spot lights. See the MicroSoft DirectX programming manuals for a detailed explanation of the lighting modes. last updated: 07/23/99 03:51PM
Gets the constant rotation factor of an object. WTOrientation getConstantRotation();
Gets the constant rotation of a container, camera, light, or group. The constant rotation is the "spin" an object has; it is set with the last updated: 07/23/99 03:53PM
Returns the system CPU type. string getCPU() This method returns a string containing the host system's CPU type. last updated: 10/29/99 12:55AM
Returns the IWT object that created it. IWT getCreator(); Returns the IWT object that created it. last updated: 05/10/99 02:48PM
Returns a WTDrop object, selected by index number. WTDrop getDrop(int index); Returns a drop object, selected by index number. last updated: 07/23/99 03:54PM
Returns the number of drops contained within a parent drop. int getDropCount(); Returns an integer value equal to the number of drops contained within a parent drop. last updated: 07/23/99 04:09PM
Returns the number of either front or back drops within a camera viewpoint. int getDropCount( [bool front] );
Returns an integer value equal to the number of drops within a camera viewpoint. The optional last updated: 07/23/99 04:13PM
Returns the length of an animation. float getDxAnimationLength( [ int index ] )
This method returns the length of a set of animations or a single animation track. Use the optional last updated: 09/07/99 01:07PM
Returns the current playback rate of an animation. int getDxAnimationRate( [ int index ] )
This method will return the current play back rate in frames per second for a set of animations or, using the optional last updated: 09/07/99 03:13PM
Returns an integer value describing the current severity of error handling. int getErrorHandling() Returns an integer value describing the current severity of error handling. last updated: 09/13/99 12:57PM
Returns an error code for the loading state of a media object. int getErrorNumber(); Returns an error code for the loading state of a media object. A 0 value indicates that the media loaded successfully. Error codes are returned for failed attempts.
last updated: 07/23/99 04:27PM
Returns the type of exception that just ocurred. int getExceptionType()
This method can be used to investigate the particular type of exception that has just ocurred. You're informed an exception has ocurred when the event's
last updated: 11/08/99 07:18PM
Returns the current working directory from which external media will be loaded. string getFilesPath() Returns the current working directory from which external media will be loaded. last updated: 09/13/99 12:57PM
Returns the maximum density of the fog at its End Distance. float getFogDensity(); Returns a float value describing the maximum density of the fog at its End Distance. last updated: 07/23/99 04:29PM
Returns a boolean value describing the state of fog in the stage. boolean getFogEnabled(); Returns a boolean value describing the state of fog in the stage. A TRUE value indicates that fog is on, while a FALSE value indicates that it's off. last updated: 07/23/99 04:32PM
Retrieves a float describing the current End Distance of the fog bank, relative to the camera. float getFogEndDistance(); Retrieves a float describing the current End Distance of the fog bank, relative to the camera. last updated: 07/23/99 04:38PM
Returns a float describing the current Start Distance of the fog bank, relative to the camera. float getFogStartDistance(); Returns a float describing the current Start Distance of the fog bank, relative to the camera. last updated: 07/23/99 04:42PM
Returns the current playback frequency of an audio clip in kHz. int getFrequency()
Returns the current playback frequency of an audio clip in kHz. Unless the frequency has been changed using the last updated: 09/27/99 06:10PM
Returns the height of the displayed drop on the scene. int getHeight(); Returns the height, in pixels, of the WTDrop object. last updated: 05/10/99 02:48PM
Returns the height of the driver window. int getHeight() This method returns the height of the driver window, in pixels. last updated: 09/09/99 01:55PM
Return the driver initialization status. bool getInitStatus( int infotype )
This method can be used to check the initialization status of the driver for additional information. The Note that the lack of hardware support for 3D is really a warning rather than an error - the web driver will still do its best with software emulation. If you have complex content that requires hardware support to be useful, however, you may want to check for this condition and handle it accordingly. If a critical error such as the absence of DirectX or an unsupported color depth occurs, then all driver methods except this one will return errors.
last updated: 10/29/99 01:18AM
Returns the time elapsed, in milliseconds, since the last render event notification. int getInterval() Returns the time elapsed, in milliseconds, since the last render event notification. This value is valid only for render events. last updated: 10/07/99 11:54PM
Returns the character code of the keypress firing a KeyboardEvent. int getKey() Returns the character code of the keypress firing a KeyboardEvent. The KeyboardEvent will fire when a key is pressed, and also when it is released. We use Internet Explorer key code values. Only valid for Keyboard events.
Here's a little tool for finding out what the nKey and ieKeys are.
This code was copied from last updated: 06/16/99 02:56PM
Returns the up or down state of the key which fires a KeyboardEvent. int getKeyState() Returns the up or down state of the key which fires a KeyboardEvent. 0 means a key release, while 1 means a keypress. Only valid for Keyboard events. last updated: 06/04/99 12:27PM
Gets the linear attenuation of the light. float getLinearAttenuation() Gets the DirectX linear attenuation for the light. Positioned lights (i.e., not ambient lights) will be effected. See the MicroSoft DirectX programming manuals for a detailed explanation of the lighting modes. last updated: 06/15/99 01:35PM
Returns the current look at target. WTContainer getLookAt()
This method returns the target container, if any, that a container has been set to look at using the last updated: 09/07/99 12:27PM
Returns the current frame rate cap. int getMaxFramesPerSecond() Returns the current framerate cap. last updated: 09/13/99 12:58PM
Returns the system CPU speed. string getMHZ() This method returns a string containing the host system's CPU speed in megahertz. last updated: 10/29/99 12:56AM
Returns the user-specified name of any object. string getName() getName will return a string containing the user-specified name of an object. If the name has not been specified with setName, then getName will return null. This returns a java.lang.String Object, not a JavaScript string object. However to cast it to JavaScript, simply do this:
<SCRIPT LANGUAGE="JavaScript"> Note that LANGUAGE is not "JavaScript1.2". last updated: 08/17/99 03:08PM
Returns the container object the user is pointing to. WTContainer getObject()
Returns the container that the user is pointing to. The contents of the container can be retrieved and manipulated using the container's This method is only valid with Mouse events, and then only if the content author has enabled object picking using the Warning: this method has recently changed. The original method returned the model object, not the container. last updated: 07/13/99 03:57PM
Returns an object's orientation in terms of axes and angle. WTOrientation3d getOrientation() getOrientation returns an object's orientation in terms of angles and axes with a WTOrientation3D object. The resulting object contains 4 values. These values may be retrieved with the getX, getY, getZ, and getAngle methods. last updated: 05/25/99 03:21PM
Returns an object's orientation in terms of angles and axes with a WTOrientation3D object. WTOrientation3D getOrientation() getOrientation returns an object's orientation in terms of angles and axes with a WTOrientation3D object. The resulting object contains 4 values. These values may be retrieved with the getX, getY, getZ, and getAngle methods. last updated: 05/25/99 03:21PM
Returns an object's up vector. WTVector getOrientationUp()
This method returns the up vector of an object. It's generally used in conjunction with last updated: 09/22/99 12:37AM
Returns an object's forward vector. WTVector getOrientationVector()
This method returns the front vector of an object. It's often used in conjunction with last updated: 09/22/99 12:35AM
Returns the system OS type. string getOS() This method returns a string containing the host system's operating system type. last updated: 12/15/99 03:31PM
Returns the system OS version. string getOSVersion() This method returns a string containing the host system's operating system version. last updated: 12/15/99 03:34PM
Returns the parent object. WTObject getOwner()
Returns the parent object of the object calling it. The behavior of this method varies slightly depending on the particular descendent of
last updated: 08/10/99 05:37PM
Returns the pan value of an audio clip. int getPan() Returns the pan value of an audio clip. last updated: 05/25/99 03:58PM
Returns the penumbra (outside cone) angle of a spotlight. float getPenumbra() Returns the DirectX penumbra (outside cone angle) of the light. The method is only applicable to spotlights. The value will be returned in degrees. last updated: 08/31/99 12:34PM
Returns system performance information. WTSysInfo getPerformanceInfo()
This method returns a The user will be presented with a dialog box stating that performance information has been requested. If the user denies permission, then the method will return last updated: 10/29/99 01:16AM
Returns a container's current pick priority. int getPickPriority()
Returns a container's current pick priority. When a container is created, its pick priority is set to "normal". The pick priority can be adjusted using the last updated: 08/10/99 02:45PM
Returns an object's position relative to its parent group. WTVector getPosition();
This method returns a Individual values must be retrieved with the vector's getX, getY and getZ methods. To return an object's position in world coordinates regardless of its grouping, use the last updated: 07/21/99 12:36AM
Gets the quadratic attenuation of the light float getQuadraticAttenuation Gets the DirectX quadratic attenuation for the light. Positioned lights (i.e., not ambient lights) will be effected. See the MicroSoft DirectX programming manuals for a detailed explanation of the lighting modes. last updated: 06/15/99 01:35PM
Returns the system RAM size. string getRAM() This method returns a string containing the host system's RAM size in kilobytes. last updated: 10/29/99 12:58AM
Returns an unsigned, 32-bit number of the current system time in milliseconds DWORD getTime() Returns the current system time in milliseconds. Note that this value can wrap -- if you call this routine twice the second call usually, but not always, returns the larger value. You should always simply subtract the first value from the second to determine the number of milliseconds between events. This must be done using unsigned 32-bit integers. last updated: 06/04/99 12:24PM
Returns the specific type of an event (mouse click, mouse move, render, keypress, etc.). int getType() This method can be used by your event handler to react to specific events or ignore events you have no interest in. It's most useful when responding to events generated by the mouse. The event types are summarized below. Currently in JavaScript, an expression must be compared to the numerical value, however other languages, such as Java, are able to use the English identifiers.
last updated: 11/08/99 07:02PM
Returns the umbra (inside cone) angle of a spotlight. float getUmbra() Returns the DirectX umbra (inside cone angle) of the light. This method is only applicable to spotlights. The angle will be returned in degrees. last updated: 08/31/99 12:34PM
Retrieves the user data associated with an object. variant getUserData()
Use this method to retrieve the application data you've associated with an object using the last updated: 08/04/99 02:19PM
Returns a string describing the installed version of the web driver. string getVersion() Returns a string describing the currently installed version of the web driver. Version strings are of the form "X.X.X.X". last updated: 09/13/99 01:00PM
Returns a vertex's vector. WTVector getVertex( int index ) By supplying the index of the desired vertex, and calling getVertex on its model, a vector describing that vertex relative to its model origin will be returned. last updated: 08/24/99 07:03PM
Returns the visibility status of a container or group. int getVisible() Use this method to check the visibility status of a container or group. A return value of 1 indicates the container or group and its contents are visible, while a value of 0 indicates invisibilty. Keep in mind, when interpreting the return value of this method, that the status of a group takes precedence over its members. For example, if a visible container is placed inside an invisible group, its contents will become invisible, but its last updated: 09/17/99 06:54PM
Returns the current volume of an audio clip. int getVolume() Returns the current volume of an audio clip. last updated: 05/25/99 03:54PM
Gets the absolute width of a WTDrop int getWidth(); Returns the width of the WTDrop. last updated: 05/10/99 02:48PM
Gets the width of the driver window. int getWidth() This method returns the width of the driver window, in pixels. last updated: 09/09/99 01:54PM
Gets the mouse position, in pixels, relative to the WT Object. int getWTX()
Gets the mouse X position, in pixels, relative to the WT object. If is only one camera, and it is positioned over the entire WT object, then this will be the same as the Use Only valid with Mouse events last updated: 06/04/99 11:07AM
Gets the mouse position, in pixels, relative to the WT Object. int getWTY()
Gets the mouse Y position, in pixels, relative to the WT object. If is only one camera, and it is positioned over the entire WT object, then this will be the same as the Use Only valid with Mouse events last updated: 06/04/99 11:06AM
Returns the X value of a WTVector3D object. float getX() Returns the X value of a WTVector3D object. last updated: 05/25/99 03:30PM
Gets the X position of the WTDrop in relation to the scene. int getX() Returns the x-coordinate of the WTDrop's position. last updated: 08/30/99 02:17PM
Returns the current X value of a WTOrientation3D object. float getX() Returns the current X value of a WTOrientation3D object. last updated: 05/25/99 03:48PM
Gets the mouse position, in pixels, relative to the camera. int getX() Gets the mouse X position, in pixels, relative to the camera. If the user is not over a camera, then the position relative to the WT object is returned. Only valid with Mouse events last updated: 06/03/99 07:57PM
Gets the Y position of the WTDrop in relation to the scene. int getY(); Returns the y-coordinate of the WTDrop's position. last updated: 05/25/99 03:27PM
Returns the Y value of a WTVector3D object. float getY() Returns the Y value of a WTVector3D object. last updated: 05/25/99 03:30PM
Returns the current Y value of a WTOrientation3D object. float getY() Returns the current Y value of a WTOrientation3D object. last updated: 05/25/99 03:49PM
Gets the mouse position, in pixels, relative to the camera. int getY() Gets the mouse Y position, in pixels, relative to the camera. If the user is not over a camera, then the position relative to the WT object is returned. Only valid with Mouse events last updated: 06/03/99 07:57PM
Returns the Z value of a WTVector3D object. float getZ() Returns the Z value of a WTVector3D object. last updated: 05/25/99 03:31PM
Returns the current Z value of a WTOrientation3D object. float getZ() Returns the current Z value of a WTOrientation3D object. last updated: 05/25/99 03:49PM
Returns the number of animations available. int hasDxAnimations()
This method returns the number of animations available within a last updated: 09/01/99 05:08PM
Sets the highlight state of a container. void highlight( bool state )
The contents of a container can be "highlighted" using this method. If a value of TRUE is used for the last updated: 08/20/99 03:42PM
Returns the play status of an animation. bool isDxAnimationPlaying( [ int index ] )
Use this method to determine if a model's animation sequence is playing. The optional last updated: 09/07/99 01:09PM
Returns the highlight state of a container. bool isHighlighted() This method retrieves the current highlighting state for a container: TRUE if the contents of the container are currently highlighted, FALSE if they are not. last updated: 08/20/99 03:45PM
Returns the current loading state of a media object. boolean isLoaded()
This method returns a boolean value which is last updated: 09/21/99 11:41PM
Returns TRUE if the audio clip is playing. boolean isPlaying()
This method returns last updated: 09/21/99 11:43PM
Moves an object relative to its current position and orientation. void moveBy( float dx, float dy, float dz )
This method moves an object relative to its frame of reference as defined by its current position and orientation. For example, last updated: 09/22/99 12:39AM
Display a debug string. void outDebugString( string debuginfo ) This method displays a string in the debug window. last updated: 09/03/99 02:42PM
Play an animation. void playDxAnimation( [float start][, float stop][, bool loop][, bool waittoload][, int index] ) This method initiates the playing of an animation which can adjust the position, scaling, and orientation of the model over time. All the method's parameters are optional. If called with no parameters, all animations in the model will begin playing simultaneously. The If the If the The last updated: 09/03/99 04:03PM
Reads a single byte from the file.
char readByte()
Reads a single byte from the file.
If the data read is invalid -- for example, because you are trying to read beyond the end-of-file -- then the returned value is 255 (all-bits-one). In some scripting languages, the value may be minus one instead. last updated: 07/26/99 02:53PM
Reads a double-precision floating point number from the file.
double readDouble()
Reads a double-precision floating point number from the file.
If any the data read is invalid -- for example, because you are trying to read beyond the end-of-file -- then the returned value is minus one (-1). last updated: 07/26/99 02:54PM
Opens a remote or local file for reading.
WTFile readFile( string filename [, byteorder] )
This method opens a remote or local file for reading. The method will return immediately; check the status to find when the file is availible for use.
The optional One common problem encountered with remote files is misspelled file names. If "index.htm" refuses to open, try "index.html" instead - some web browers will helpfully "fix" common problems like this without telling you, so verifying the file name with your web browser may not be sufficient.
last updated: 12/11/99 11:23PM
Reads a single-precision floating point number from the file.
float readFloat()
Reads a single-precision floating point number from the file. Floats are four bytes long.
If any the data read is invalid -- for example, because you are trying to read beyond the end-of-file -- then the returned value is minus one (-1). last updated: 07/26/99 02:55PM
Reads a four-byte integer from the file.
int readInt()
Reads a four-byte integer from the file.
If any the data read is invalid -- for example, because you are trying to read beyond the end-of-file -- then the returned value is minus one (-1). last updated: 07/26/99 02:54PM
Reads a full line from the file.
string readLine()
Reads in a full line from the file. The terminating carriage-return will be stripped from the returned string.
You may need to "trick" JavaScript (and other web scripting languages) into accepting the returned string as a "real" string. Because different web scripting languages treat strings differently, you may have to change the returned Java-type string into something more directly usable. For example, in JavaScript you may need to do the following:
JavaScript will take the last updated: 07/26/99 03:30PM
Reads a two-byte integer from the file.
short readShort()
Reads a two-byte integer from the file.
If any the data read is invalid -- for example, because you are trying to read beyond the end-of-file -- then the returned value is minus one (-1). last updated: 07/26/99 02:55PM
Removes a WTDrop from a camera or parent drop.
void removeDrop( WTDrop drop )
This method removes the specified drop and all its child drops from the camera viewpoint or a parent drop. last updated: 09/07/99 01:47PM
This adds a drop with a bitmap of a red image, then removes it from the viewpoint. A bitmap may be added to any number of drops.
Removes an object from its parent.
void removeObject( object );
This function is called to remove an object from its current parent object. This may be a group or a stage. last updated: 05/25/99 01:55PM
Here, we create a group object, add it to a scene, then remove it from the scene.
Removes the texture currently associated with a WTModel.
void removeTexture( [String modelPart] )
This method removes the texture currently associated with a WTModel object. An optional Hierarchical models separate the different levels with slashes ("/"). The model part can include these slashes & need only partially match.
Example:
In addition, if calling setTexture on a box created with the createBox method, you may specify the face to be textured by name - "front", "back", "top", "bottom", "left", "right".
last updated: 08/26/99 03:28PM
Restore the display to windowed mode.
void restoreResolution()
This method will restore the user's display to windowed display mode. The user may also return to windowed mode at any time by pressing the escape key or the ALT-F4 key combination. last updated: 09/13/99 01:12PM
Resumes a camera's rendering cycle.
int resume()
This method resumes a camera's rendering cycle after it has been suspended. Each call to last updated: 09/07/99 08:04PM
Sets the position of an object using world coordinates.
void setAbsolutePosition( float x_pos, float y_pos, float z_pos );
This method positions an object with reference to the world coordinate system (the stage). To position an object relative to its group, use the last updated: 07/20/99 04:31PM
Scales a model or container along the x, y, and z axes.
void setAbsoluteScale(float x, float y, float z);
You can set the scale of a model or container by specifying float values for the x, y, and z axes. All numbers are multipliers.
Unlike Using You should avoid setting any axis scale to zero; the model may lose its size and position information forever.
If you place a scaled model in a scaled container, both scaling factors are used to determine the final scale of the visible object.
If you attach a model to three containers, and set the scale of each container differently, the model will appear three times with three sizes.
last updated: 07/19/99 04:11PM
Sets the background color for a stage.
void setBGColor( int r, int g, int b )
This methods sets the background color for a stage. All camera views of the stage will be set against the color, which is specified by its red, green, and blue components. last updated: 09/17/99 05:01PM
Sets the opacity (translucency) of a bitmap associated with a container.
setBitmapOpacity( int opacity )
This method sets the opacity (or translucency, if you prefer) of the bitmap attached to a container. Valid values range from 0 to 255, where 0 is completely transparent and 255 is fully opaque. last updated: 08/25/99 09:54PM
Sets an associated bitmap's scaling factors.
void setBitmapSize( float width, float height );
If the container holds a bitmap, the bitmap's scaling factors will be set as specified in the Use The scaling factors can also be set when the last updated: 07/19/99 06:52PM
Sets the front and back clipping planes.
setClipping( float setBack [, setFront ] )
This method allows you to control the size of the universe that the camera renders. Only objects that fall between the front and back clipping planes will be rendered. Normally, the front clipping plane is set to 1, while the back is set to infinity. Setting the back clipping plane to a more reasonable value can result in increased performance for scenes that have large open areas, such as outdoor scenes. Fog is usually used to hide the "end of the world" from the viewer. last updated: 12/13/99 02:07AM
Sets the object to a specified color.
void setColor( int red, int green, int blue );
This method fills a WTBitmap or sets a lighting color with the given RGB values.
Values are decimal by default, but HEX values are supported by prefacing each RGB value with "0x", if your scripting language supports that syntax. (JavaScript does, for example.)
Values for each color component must range from 0 to 255 (0x00 to 0xFF). last updated: 07/19/99 03:31PM
This creates an empty bitmap 100 pixels wide by 100 pixels high, and fills it with the color red.
If the scripting language supports it, then Hexadecimal values can be passed rather than decimal values.
Sets the color of a model or modelPart.
void setColor( int red, int green, int blue [, string modelPart]);
This method colors the model with the supplied RGB values, which must range from 0 to 255 or use the hexadecimal values 0x00 to 0xFF.
An optional For example, if a model contains: Boxes created with the createBox method have six named faces (front, back, top, bottom, left, right), which can all be colored individually. last updated: 07/19/99 03:55PM
Sets a transparency color for a bitmap.
void setColorKey( int red, int green, int blue );
This method specifies the transparency color, or "color key", for a bitmap. Any pixel in the bitmap matching this color will not be rendered, making that area appear transparent. You can use color keys with bitmaps used as textures to create "decals", however it is essential that you set the color key before using the The use of black (red, green, blue = 0) and white (red, green, blue = 255) as color keys should be avoided as many display cards do not support them.
To set the transparency color to "none", use the last updated: 11/08/99 07:38PM
Sets the constant attenuation for the light
setConstantAttenuation (float newval)
Sets the DirectX constant attenuation for the light. Positioned lights (i.e., not ambient lights) will be effected.
See the MicroSoft DirectX programming manuals for a detailed explanation of the lighting modes. last updated: 06/15/99 01:37PM
Continually rotates an object.
void setConstantRotation( float x_axis, float y_axis, float z_axis, float angle )
This method sets an object rotating around the vector specified by The rate of rotation is specified by last updated: 09/01/99 09:19PM
Sets the color to be used for drawing operations.
setDrawColor( int red, int green, int blue );
This method specifies the RGB color to be used for all subsequent drawing operations.
Values are decimal by default, but HEX values are supported by prefacing each RGB value with "0x", if your scripting language supports that syntax. (JavaScript does, for example.)
Values for each color component must range from 0 to 255 (0x00 to 0xFF).
last updated: 07/27/99 04:23PM
Sets the playback rate for an animation.
void setDxAnimationRate( int rate [, int index ] )
This method adjusts the rate at which an animation is played back, as specified by the The default rate is 30 frames per second, with one frame corresponding to one unit in the animation time line. The rate at which an animation is played back is independent of the current rendering frame rate. last updated: 09/07/99 03:04PM
Sets an animation to a particular instant in time.
void setDxAnimationTime( float time [, int index ] )
This method sets an animation to a particular instant in its timeline. The model position will be interpolated if necessary.
The method can be used to "single step" through an animation sequence and can be useful when syncronization multiple animations. last updated: 09/07/99 01:09PM
Sets the severity of error handling for the WT object.
void setErrorHandling( int severity )
Sets the severity of error-handling for the WT object. The possible severities are summarized in the table below.
Regardless of the severity, invalid models will be replaced with cubes, and invalid bitmaps will be replaced with a yellow bitmap. By checking the error number with the object's An object's behavior when encountering errors will always correspond to the error handling severity that was set prior to its initialization. Changes to severity after a media item has begun loading will have no effect on previously initialized objects.
The current error handling severity can be retrieved with the last updated: 09/13/99 06:45PM
Sets the field of view of the camera.
void setFieldOfView( float angle )
This method is used to set the field of view for the camera. The field of view determines the width of the viewport used when rendering. Similar to a wide angle lense in the physical world, increasing the field of view will bring more area into view, but will make objects appear smaller. Decreasing the field of view will decrease the amount of area the camera sees, resulting in a zoom effect that will make objects appear larger.
The Warning: early version of the API incorrectly used radians instead of degrees. This has been fixed in the latest versions. last updated: 08/25/99 09:39PM
Sets the current working directory.
void setFilesPath( string path )
Sets the current working directory from which media will be loaded. For security reasons, this method is not available in Java or browser-hosted scripting languages. last updated: 09/15/99 01:03AM
Sets the RGB color of the fog in a scene.
void setFogColor( int R, int G, int B )
Allows the user to specify the RGB fog color of the scene. Receives three integer values for Red, Green, and Blue, ranging from 0 to 255 last updated: 08/24/99 07:01PM
Sets the maximum opacity of the fog bank in the stage.
void setFogDensity( float density )
Sets the maximum opacity of the fog bank in the stage. This is the opacity of the fog at its End Distance. Valid values range from 0 to 1.0. last updated: 08/24/99 06:55PM
Enables or disables fog in the stage.
void setFogEnabled(boolean fogState)
Enables or disables fog in the stage. An boolean value of true enables fog, while a false value turns it off. last updated: 05/25/99 03:16PM
Sets the current far value of the fog bank, relative to the camera.
void setFogEndDistance(float far)
Sets the current far value of the fog bank, relative to the camera. The 3D space between the near value and the far value will be filled with fog, and the distance between them will describe the density over distance of the fog bank. last updated: 05/25/99 03:14PM
Sets the current near value of the fog bank, relative to the camera.
void setFogStartDistance(float near);
Sets the current near value of the fog bank, relative to the camera. The 3D space between the near value and the far value will be filled with fog, and the distance between them will describe the density over distance of the fog bank. last updated: 05/25/99 03:13PM
Sets the playback frequency for an audio clip.
void setFrequency( int frequency )
Sets the frequency at which an audio clip should play, in kHz. If this frequency differs from the original sampling frequency, then the clip will either play more slowly or more quickly than when it was originally recorded. Use this effect sparingly, as the necessary computations are not hardware supported. last updated: 09/27/99 06:13PM
Sets the linear attenuation of the light.
setLinearAttenuation (float newval)
Sets the DirectX linear attenuation for the light. Positioned lights (i.e., not ambient lights) will be effected.
See the MicroSoft DirectX programming manuals for a detailed explanation of the lighting modes. last updated: 06/15/99 01:37PM
Sets the container to follow a target container.
void setLookAt( WTContainer target[, int looktype ] )
This method attaches a container to a target container. Once attached, the container will reorientate itself automatically to track the target container no matter where it goes.
Although this method can be used to achieve many interesting effects, it's most commonly applied to cameras. If a camera is set to look at another container, the target container will remain in the center of the viewpoint and the camera will follow it until the The optional last updated: 09/02/99 02:58PM
Sets the material properties of a model.
void setMaterial( int er, int eg, int eb, float spower, int sr, int sg, int sb )
This method allows you to set a model's material properties. These properties describe how light affects the model.
The The next four parameters, The modelling of specular highlights is computationally expensive, roughly doubling the number of lighting calculations that need to be performed, so use the effect judiciously. last updated: 09/03/99 02:46PM
Sets the current frame rate cap.
void setMaxFramesPerSecond()
Sets the cap or the upper limit in frames-per-second that the application will allow itself to run. It may still run slower than the cap, but will never exceed it. last updated: 09/13/99 07:02PM
Sets the state of the mouse cursor.
void setMouseCursorState( int state )
This method sets the state of the mouse cursor. Use extreme caution with this method, as you can leave the user without a mouse pointer.
Currently supported states are listed in the table below.
last updated: 09/13/99 07:05PM
Sets the position of the mouse pointer.
void setMousePosition( xpos, ypos )
This method positions the mouse at the X and Y screen coordinates specified by the last updated: 09/13/99 11:48AM
Sets a user-specified name for the object
void setName(string name)
Sets a user-specified name for the object. This value may be retrieved with the getName method. last updated: 05/25/99 02:29PM
Starts or stops sending exception events to an event handler.
void setNotifyExceptionEvent( int detaillevel )
This methods commands the WT object to start or stop sending exception events to an event handler. The For more information on handling events, see the event handling overview. last updated: 09/13/99 07:35PM
Starts or stops sending keyboard events to an event handler.
setNotifyKeyboardEvent( int detaillevel )
This method commmands the WT object to start or stop sending keyboard events to an event handler.
The last updated: 09/13/99 07:46PM
Asks the WT object to start or stop sending Mouse event messages.
setNotifyMouseEvent (int detail_level)
Asks the WT object to start or stop sending WTEvents to a MouseEvent handler.
You can ask for several different levels of detail.
In addition to calling this method, you must also ask the web browser to catch the events. In JavaScript this is done as follows:
where "pwt" is the JavaScript name of the WT object and "render" is the name of a JavaScript routine that will handle the event.
last updated: 06/04/99 01:46PM
Asks the WT object to start or stop sending WTEvents to a RenderEvent handler.
setNotifyRenderEvent (int detail_level)
Asks the WT object to start or stop sending WTEvents to a RenderEvent handler.
Detail level can be either last updated: 09/09/99 05:30PM
Sets a function to be called when a media object finishes loading.
void setOnLoad( Function fname )
This method can be used to designate a function that will be called when a media object has finished loading. The specified function will be passed a single parameter designating the object that triggered the call.
In JScript and JavaScript the function parameter should be the unquoted name of the target function. In Java, C++, and Visual Basic, the parameter should be a class/interface that implements the "WTOnLoadEvent" interface. The "onLoadComplete" method of the class will be called and passed the object that completed loading.
Media objects load asynchronously and can be manipulated before they've finished loading, although they won't be presented to the viewer until the load is complete. For example, you may create a large model with the last updated: 09/07/99 01:30PM
Sets the opacity (translucency) of a model.
setOpacity( int opacity, [string model_part] )
This method sets the opacity (or translucency, if you prefer) of the model. Valid values range from 0 to 255, where 0 is completely transparent and 255 is fully opaque.
If the model is hierarchical, then an optional For example, if a model contains: Boxes created with the last updated: 08/25/99 09:54PM
Sets the orientation of an object in 3D space.
void setOrientation( float x_axis, float y_axis, float z_axis, float angle);
Orients an object in 3D space. By specifying the axis, or axes to rotate around, and the degree value of the rotation angle, an object's orientation will be set.
To set an object back to its default orientation, last updated: 07/14/99 04:05PM
Sets an object's orientation by way of a forward and up vectors.
void setOrientationVector(float forward_x, float forward_y, float forward_z, float up_x, float up_y, float up_z);
By supplying the x, y and z values of a Foward vector and an Up vector, an object's orientation may be set. Use getOrientationVector to get an object's Forward vector and getOrientationUp to get an object's front vector.
The default orientation of an object has a Forward vector of [0, 0, 1] and an Up vector of [0, 1, 0]. last updated: 06/17/99 06:18PM
Sets the left to right pan of an audio clip.
void setPan( int pan )
Sets the left to right pan of an audio clip. Values range from -127 (hard left) to 127 (hard right), respectively. A value of 0 (the default) plays the clip dead-center. last updated: 09/10/99 05:23PM
Sets a specified surface area of a Patch model to correspond to a particular rectangle in texture space.
setPatchAreaUV(int s0, int t0, int s1, int t1, single u0, single v0, single u1, single v1)
A portion of the Patch model surface area is specified by upper left corner last updated: 10/15/99 12:12PM
Sets the min and max local coordinates between which the heights of patch points can be scaled using
setPatchHeightExtents(single min, single max)
When a patch is created, the default values for last updated: 10/15/99 12:34PM
Scales the height of a surface coordinate of a Patch model.
setPatchPtHeight(int s, int t, int h [, int mod ])
Scales the height last updated: 10/15/99 12:36PM
Set the
setPatchPtPos(int s, int t, single x, single y, single z [, int mod ])
The
The default value of the optional last updated: 10/15/99 12:31PM
Sets a surface coordinate of a patch to correspond to a particular texture coordinate.
setPatchPtUV(int s, int t, single u, single v)
The surface coordinate specified by last updated: 10/14/99 05:25PM
Assign a texture quad to a 1x1 sub-area (tile) of a Patch model.
setPatchTileUV(int s0, int t0, single u0, single v0, single u1, single v1, single u2, single v2, single u3, single v3)
A quadrilateral from texture space, specified by last updated: 10/15/99 12:46PM
Sets the penumbra (outside cone) angle of a spotlight.
setPenumbra ( float angle )
Sets the penumbra (outside cone angle) of the light. This method is only applicable to spotlights.
The angle should be specified in degrees. last updated: 08/31/99 12:31PM
Sets the pick priority for a container.
void setPickPriority( int priority )
If your application allows the user to pick objects in the scene using the mouse, you can use this method to determine which container will be returned when the selection is ambiguous. If several containers overlap underneath the mouse pointer, the container with the highest pick priority will be returned. The For more information on handling pick events, see the event overview. last updated: 09/14/99 09:11PM
Positions an object relative to its parent group.
void setPosition( float x_pos, float y_pos, float z_pos);
Use this method to position a grouped object relative to its parent group. If the object is not a member of a group then it will be positioned using the world coordinate system (the stage).
You must set the position after adding the object to the stage or to a group. An attempt to set the position before doing so will fail.
To position a grouped object using world coordinates, use the last updated: 07/20/99 04:23PM
Sets the position of the drop.
void setPosition( int x, int y )
This method sets the drop's position, in pixel values, to the coordinates specified. If the drop is a child of another drop, the position is set relative to the parent. last updated: 09/22/99 01:05AM
Sets the quadratic attenuation for the light
setQuadraticAttenuation (float newval)
Sets the DirectX quadratic attenuation for the light. Positioned lights (i.e., not ambient lights) will be effected.
See the MicroSoft DirectX programming manuals for a detailed explanation of the lighting modes. last updated: 06/15/99 01:38PM
Switches to a full screen display mode.
bool setResolution( int width, int height [, int bitsperpixel ] )
This method provides access to full screen display modes. The performance of fullscreen modes is often superior to windowed modes and offers a more immersive user experience.
The user's permission will be requested using a dialog box before the switch is performed. If permission is granted, then the desktop will be completely covered by your scene. The scene will be positioned in the upper left corner of the display with any excess area filled with black. The mouse cursor will be visible but any dialog boxes, such as those produced by the JavaScript "alert" method, will not.
The desired mode is selected by specifying its width and height in pixels, as well as the number of color bits to be used per pixel (the "color depth"). The modes available will vary depending on the user's display hardware. Palettized display modes ( The The user can return to windowed mode at any time by pressing the escape key or the ALT-F4 key combination. The Since it's possible for the user to deny the request to switch modes, you can't count on them being available. The return value of this method is last updated: 12/11/99 09:52PM
Adds a rotation to an object by the specified axis.
void setRotation( float x_axis, float y_axis, float z_axis, float angle);
This method is similar to The rotation angle should be specified in degrees. last updated: 07/16/99 06:11PM
This example rotates the group 15-degrees on the X-Axis.
Scales a model along the x, y, and z axes.
void setScale( float scalex, float scaley, float scalez );
You can set the scale of a model or container by specifying scaling factors for the x, y, and z axes.
Scaling is cumulative; calling You should avoid setting any scale factor to zero; the model may lose its size and position information forever.
If you place a scaled model in a scaled container, both scaling factors are used to determine the final scale of the visible object.
If you attach a model to three containers, and set the scale of each container differently, the model will appear three times with three sizes.
last updated: 08/02/99 04:59PM
Resets the meaning of 1x1x1 scaling for an object or container
void setScaleTare();
Resets the meaning of The That is, if you do not use the It is most often used with models and almost never with containers. last updated: 07/19/99 06:16PM
Sets the size of the WTBitmap object within the WTDrop.
void setSize( int width, int height )
Sets the dimensions of how the image appears within the drop. The bitmap will be scaled as necessary. last updated: 09/22/99 01:22AM
Sets the color to be displayed behind the printed text.
void setTextBkColor( int red, int green, int blue )
Sets the color to be displayed behind the printed text. Accepts three integer values describing the red, green, and blue levels of the color. last updated: 09/22/99 12:04AM
Turns the bold property on or off for text drawn afterward.
setTextBold( int bold );
This method sets the bold property for text drawn subsequently with the last updated: 07/30/99 12:38AM
Sets the RGB color value of all text to be displayed afterward.
void setTextColor( int red, int gree, int blue )
Sets the RGB color value of all text to be displayed afterward. Accepts three integer values for the red, green, and blue levels of the color. last updated: 09/22/99 12:06AM
Sets the font to be used for text displayed afterward.
void setTextFace( string font )
This method specifies the font to be used for text displayed afterward. The last updated: 09/22/99 12:08AM
Sets the height of the text font in points.
void setTextHeight(int height)
Sets the height of the text font in points. last updated: 05/25/99 03:33PM
Turns the italic property on or off for text drawn afterward.
setTextItalic( int italic );
This method sets the italic property for text drawn subsequently with the last updated: 07/30/99 12:40AM
Sets the properties of text to be displayed afterward.
void setTextProperties(int bold, int italic, int underline, int strikeout, int charset, int quality)
Sets the properties of text to be displayed afterward.
The bold property may vary between 0 and 1000, 1000 being boldest, and 0 being nearly invisible. 400 is the default 'un-bolded' value for any text. 300 is light, and 700 is standard bold.
Italic, underline, and strikeout all accept integer values of 1 or 0. 1 turns them on, and 0 turns them off.
The charset value should always be set to 0, which is the ANSI character set.
At present, the quality value should be set to 0 for non-antialiased, and 4 for antialiased. Intermediate values will be documented in the future. last updated: 05/25/99 03:40PM
Applies a texture to a WTModel object.
void setTexture( WTBitmap image [, String modelPart] [, int size]);
This call takes image and applies it to the calling WTModel object. If the WTModel object is a model (.wt file), then the object will use the mapping coordinates found in the model file.
If the object is a model, then an optional modelPart parameter may be specified. All model components with matching names will be textured. Hierarchical models will separate the different levels with slashes ("/"). The model part can include these slashes & need only partially match.
Example:
In addition, if calling setTexture on a box created with the createBox method, you may specify the face to be textured by name - "front", "back", "top", "bottom", "left", "right".
The size parameter lets you reduce the texture size. Reducing the texture size will both reduce the amount of texture memory that's needed and increase the speed. This value must be a power-of-two like 128 or 256. last updated: 06/04/99 03:15PM
Sets the texture coordinates on the face of a box created with createBox().
void setTextureRect( string face, float left_u_coord, top_v_coord, right_v_coord, bottom_v_coord )
This method is used to set the texture coordinates for the surfaces of boxes created with the createBox method. The target face is specified with the The area of the texture to be mapped onto the face is specified using the last updated: 09/16/99 08:49PM
Notice that without the setTextureRect() method, the back image would appear upside down when the box is rotated around its horizontal center axis.
Sets the umbra (inside cone) angle of a spotlight.
setUmbra ( float angle )
Sets the umbra (inside cone angle) of the light. This method is only applicable to spotlights.
The angle should be specified in degrees. last updated: 08/31/99 12:33PM
Controls the use of hardware rendering capability.
void setUseHAL( bool newval )
Controls the renderer's use of the Hardware Abstraction Layer (HAL) and the Hardware Emulation Layer (HEL). A value of FALSE will force the renderer to use software rendering even when hardware rendering is available. This method can be used to simulate the performance of your content on non-hardware accelerated display cards. The default value is TRUE, instructing the renderer to use hardware rendering when it's available.
This method must be called before you create any cameras or bitmaps and before you start the scene rendering. last updated: 08/11/99 02:41PM
Associates user-supplied data with an object.
void setUserData( variant userdata )
Use this method to associate your own application-specific data with an object. The data types which can be associated are dependent on the language being used, as summarized in the following table.
last updated: 08/20/99 04:59PM
Sets the camera's ViewRect to the supplied HWND's dimensions.
void setViewHWND(HWND hWnd)
Sets the camera's ViewRect to the supplied HWND's dimensions. This is only applicable in languages supporting HWND's, such as Visual Basic. The HWND must be disabled after this call. last updated: 05/25/99 03:24PM
Creates a rectangle of user-specified size into which the camera will render.
setViewRect( int x, int y, int width, int height )
This method is used to create a rectangle to which the camera's view will be rendered. It can be used to create a scene where multiple cameras render simultaneously into different areas of the driver window. last updated: 09/22/99 08:35PM
Sets the visibility of the contents of a container.
void setVisible( visible )
This method hides or reveals the contents of a container or group. If the last updated: 09/17/99 05:10PM
Sets the visibility of a drop.
void setVisible( boolean visibility )
This method is used to turn a drop on or off. Passing last updated: 12/10/99 06:36PM
Sets the playback volume of an audio clip.
void setVolume( int volume )
Sets the current playback volume of an audio clip. Values for the Note that volumne of a sound is actually how much attenuation, not amplification, an audio clip is played with. A value of 127 will play the clip back at the same volume it was originally sampled. Therefore audio clips should be normalized and maximized at the time they're recorded. last updated: 09/27/99 06:15PM
Sets the X value of a WTVector3D object.
void setX(float x)
Sets the X value of a WTVector3D object. last updated: 05/25/99 03:50PM
Sets the Y value of a WTVector3D object.
void setY(float Y)
Sets the Y value of a WTVector3D object. last updated: 05/25/99 03:51PM
Sets the Z value of a WTVector3D object.
void setZ(float z)
Sets the Z value of a WTVector3D object. last updated: 05/25/99 03:51PM
Suspends browser execution for a specified period.
void sleep( int time )
This method suspends the execution of the host browser for The method can be useful when you'd like to free up as much CPU as possible for the driver's use. For example, if you need to wait for a resource such as a model to load before continuing, putting a last updated: 10/15/99 01:14PM
Starts the scene rendering.
void start();
Begins rendering of the scene. This is required for any scene. The scene can be stopped with the stop method. last updated: 05/26/99 01:31PM
Starts an audio clip playing.
void start( [ int loop ][, int waittoload ] )
This method initiates the playing of an audio clip. The optional If a last updated: 09/27/99 12:35PM
Gets the current status of a file
int status()
Returns the status of a file. Possible values include:
last updated: 10/20/99 01:55AM
Stops rendering the scene.
void stop();
Stops the scene's rendering loop. You can restart the scene with the start method. last updated: 09/10/99 05:38PM
Stops an audio clip from playing.
void stop()
Stops an audio clip from playing. Use the last updated: 09/10/99 05:57PM
Stops an animation.
void stopDxAnimation( [ int index ] )
This method causes an animation that's playing to stop. The optional last updated: 09/07/99 03:15PM
Temporarily stops a camera from rendering.
int suspend()
This method will temporarily stop a camera from rendering. It can be used to enhance the performance of content that utilizes multiple cameras. The return value indicates how many suspend operations have been performed on a camera. The first suspend will return 1, the second 2, etc. Each suspend must be matched by a last updated: 09/07/99 08:00PM
Removes any transparency key on a WTBitmap object.
void unsetColorKey();
Removes any transparency key on a WTBitmap object. last updated: 05/10/99 02:48PM
Removes the link associating a container with a target container.
void unsetLookAt()
If the container has a target container that it's following, calling this method will remove its link with the container. last updated: 08/09/99 10:05PM
|