Path2Bvr Class

Creates an object that represents a path behavior for two-dimensional space. A path behavior consists of a sequence of two-dimensional point behaviors and is typically used to draw images consisting of line segments or to define borders for geometric shapes.

For more information about behaviors, see the Behavior class.

For relevant methods from the Statics class, see Statics Methods Relevant to Path2Bvr Objects.

Path2Bvr Methods

boundingBox Creates a Path2Bvr object that is a visible bounding box.
close Adds a line segment from the end of the path to the start. This method is useful for animating closed regions.
draw Renders the Path2Bvr object into an ImageBvr object. The image is unfilled, which means only the outline is rendered.
fill Renders the Path2Bvr object into an ImageBvr object.
transform Creates a new path behavior that is the result of applying the given transformation behavior to the points in the original path behavior.
newUninitBvr Enables you to refer to a Path2Bvr behavior before that behavior has been defined.

boundingBox

Path2Bvr Class

Creates a Path2Bvr object that is a visible bounding box.

Syntax

public Bbox2Bvr boundingBox( LineStyleBvr style );

Parameters

style
LineStyleBvr object that defines the line style of the path. This argument is ignored. The linestyle is always the default linestyle and has a width of 0.

Return Value

Returns the Path2Bvr object.

close

Path2Bvr Class

Adds a line segment from the end of the path to the start. This method is useful for animating closed regions.

Syntax

public Path2Bvr close( );

Return Value

Returns the Path2Bvr object.

draw

Path2Bvr Class

Renders the Path2Bvr object into an ImageBvr object. The image is unfilled, which means only the outline is rendered.

Syntax

public ImageBvr draw( LineStyleBvr ls );

Parameters

ls
LineStyleBvr used to render the image.

Return Value

Returns the ImageBvr object.

fill

Path2Bvr Class

Renders the Path2Bvr object into an ImageBvr object. The ls argument specifies the LineStyleBvr that is used to draw the outline. The im parameter specifies the image used to fill in the new ImageBvr object.

Syntax

public ImageBvr fill( LineStyleBvr ls, ImageBvr im );

Parameters

ls
LineStyleBvr object used to draw the path.
im
ImageBvr object used as the fill pattern.

Return Value

Returns the ImageBvr object.

transform

Path2Bvr Class

Creates a new path behavior that is the result of applying the given transformation behavior to the points in the original path behavior.

Syntax

public Path2Bvr transform( Transform2Bvr xf );

Parameters

xf
Transform2Bvr object representing the transformation to apply to the original path.

Return Value

Returns the Path2Bvr object.

Remarks

This attribute composes values.

newUninitBvr

Path2Bvr Class

Enables you to refer to a Path2Bvr behavior before that behavior has been defined. With this method you can create the behavior and use it in the definition of other behaviors, but not actually define its contents until some later point. (This is accomplished with the init method, which is available on all behaviors.) The system generates a run-time error if you initialize a non-uninitialized behavior, initialize an uninitialized behavior that has already been initialized, or run an initialized behavior that has not yet been initialized.

Syntax

public static Path2Bvr newUninitBvr( );

Return Value

Returns the Path2Bvr object.


Top of Page Top of Page
© 2000 Microsoft and/or its suppliers. All rights reserved. Terms of Use.