AlDeviationLocator

Interface to Alias deviation locator.

Synopsis

#include <AlDeviationLocator.h>
class AlDeviationLocator : public AlLocator
AlDeviationLocator();
~AlDeviationLocator();
virtual AlObject * copyWrapper() const;
virtual AlObjectType type() const;
statusCode create(const AlCurve *, const AlCurve *, double baseParameter = 0.0);
statusCode create(const AlCurveOnSurface *, const AlCurve *, double baseParameter = 0.0);
statusCode create(const AlCurveOnSurface *, const AlCurveOnSurface *, double baseParameter = 0.0);
statusCode deviation(double &) const;
statusCode deviationComponents(double &, double &, double &) const;
statusCode setParameter(double);
statusCode parameter(double &) const;
statusCode parameterTargetCurve(double &) const;
statusCode setOffset(double, double, double);
statusCode offset(double &, double &, double &) const;
statusCode setLength(double);
statusCode length(double &) const;
statusCode setLeftJustify(boolean);
statusCode leftJustify(boolean &) const;

Description

A deviation locator finds and displays the shortest distance between two curves, from a given point on the first curve to the second curve. The two curves can be any of the AlCurve or AlCurveOnSurface. This class contains methods to create the locator, query the minimum distance, and set the display attributes in the Alias windows. If any two curves on which this locator depends is deleted, this locator is automatically deleted.

SUMMARY

AlDeviationLocator::AlDeviationLocator(void)

Description:

Constructs an AlDeviationLocator wrapper object.

AlDeviationLocator::~AlDeviationLocator()

Description:

Deletes an AlDeviationLocator wrapper object.

AlObject *AlDeviationLocator::copyWrapper() const

Description:

Returns an exact copy of the AlDeviation wrapper.

AlObjectType AlDeviationLocator::type() const

Description:

Returns the class identifier kDeviationLocatorType.

statusCode AlDeviationLocator::create(const AlCurve *baseCurve, const AlCurve *targetCurve, double baseParameter)

Description:

Creates a Deviation locator between two curves.

Arguments:

< baseCurve - the curve from which the deviation is calculated

< targetCurve - the curve to which the minimum deviation is calculated.

< baseParameter - The parameter on baseCurve from which the minimum deviation to the target curve is calculated.

Return codes:

sSuccess - the deviation locator was successfully created.

sFailure - the locator was not created.

sAlreadyCreated - object has already been created.

sInvalidArgument - the baseCurve or targetCurve is not valid.

statusCode AlDeviationLocator::create(const AlCurveOnSurface *baseCurve, const AlCurve *targetCurve, double baseParameter)

Description:

Creates a Deviation locator between a curve on surface and a curve.

Arguments:

< baseCurve - the curve on surface from which the deviation is calculated.

< targetCurve - the curve to which the minimum deviation is calculated.

< baseParameter - The parameter on baseCurve from which the minimum deviation to the target curve is calculated.

Return codes:

sSuccess - the deviation locator was successfully created.

sFailure - the locator was not created.

sAlreadyCreated - object has already been created.

sInvalidArgument - the baseCurve or targetCurve is not valid.

statusCode AlDeviationLocator::create(const AlCurveOnSurface *baseCurve, const AlCurveOnSurface *targetCurve, double baseParameter)

Description:

Creates a Deviation locator between two curves on surface.

Arguments:

< baseCurve - the curve on surface from which the deviation is calculated.

< targetCurve - the curve on surface to which the minimum deviation is calculated.

< baseParameter - The parameter on baseCurve from which the minimum deviation to the target curve is calculated.

Return codes:

sSuccess - the deviation locator was successfully created.

sFailure - the locator was not created.

sAlreadyCreated - object has already been created.

sInvalidArgument - the baseCurve or targetCurve is not valid.

statusCode AlDeviationLocator::deviation(double &dev) const

Description:

Finds the minimum deviation as calculated by the deviation locator.

Arguments:

> dev - the minimum deviation.

Return codes:

sSuccess - the deviation was found.

sInvalidObject - the object is not valid.

statusCode AlDeviationLocator::deviationComponents(double &x, double &y, double &z) const

Description:

Finds the components of minimum deviation as calculated by the deviation locator.

Arguments:

> x, y, z - the X, Y, Z components of minimum deviation.

Return codes:

sSuccess - the deviation was found.

sInvalidObject - the object is not valid.

statusCode AlDeviationLocator::setParameter(double param)

Description:

Sets the parameter on the baseCurve from which the minimum deviation to targetCurve is calculated.

Arguments:

< param - the parameter on baseCurve to be set.

Return codes:

sSuccess - the parameter was set successfully.

sInvalidObject - the object is not valid.

statusCode AlDeviationLocator::parameter(double &param) const

Description:

Finds the parameter on the baseCurve from which the minimum deviation to targetCurve is calculated.

Arguments:

> param - the parameter on baseCurve.

Return codes:

sSuccess - the parameter was found successfully.

sInvalidObject - the object is not valid.

statusCode AlDeviationLocator::parameterTargetCurve(double &param) const

Description:

Finds the parameter on the targetCurve which is at the minimum deviation to the baseCurve.

Arguments:

> param - the parameter on targetCurve.

Return codes:

sSuccess - the parameter was found successfully.

sInvalidObject - the object is not valid.

statusCode AlDeviationLocator::setOffset(double x, double y, double z)

Description:

Sets the components of display offset in the deviation locator. The display offset is the relative vector between the deviation locator and start of the leader line which displays the deviation value.

Arguments:

> x, y, z - the offset components.

Return codes:

sSuccess - the components was found successfully.

sInvalidObject - the object is not valid.

statusCode AlDeviationLocator::offset(double &x, double &y, double &z) const

Description:

Finds the components of display offset in the deviation locator.

Arguments:

> x, y, z - the X, Y, Z components of the display offset.

Return codes:

sSuccess - the offset was found successfully.

sInvalidObject - the object is not valid.

statusCode AlDeviationLocator::setLength(double len)

Description:

Sets the length of the leader line in the deviation display in the modeling windows.

Arguments:

< len - the length of the leader line.

Return codes:

sSuccess - the length was set successfully.

sInvalidObject - the object is not valid.

statusCode AlDeviationLocator::length(double &len) const

Description:

Finds the length of the leader line in the deviation locator.

Arguments:

> len - the length of the leader line.

Return codes:

sSuccess - the length was found successfully.

sInvalidObject - the object is not valid.

statusCode AlDeviationLocator::setLeftJustify(boolean leftJustify)

Description:

Sets the justification of the text for the deviation locator. The text can be right justified or left justified.

Arguments:

< leftJustify - a value of true makes the text left justified and a value false makes it right justified.

Return codes:

sSuccess - setting was successful.

sInvalidObject - the object is not valid.

statusCode AlDeviationLocator::leftJustify(boolean &leftJustify) const

Description:

Finds whether the text of deviation locator is left justified or right justified.

Arguments:

> leftJustify - a value of true indicates that it is left justified and false indicates right justification.

Return codes:

sSuccess - the justification was found.

sInvalidObject - the object is not valid.





aliasdocs@aw.sgi.com
Copyright © 1996, Alias|Wavefront, a Silicon Graphics Company. All rights reserved.