alias_api.AlDeviationLocator
- class alias_api.AlDeviationLocator
Bases:
AlLocatorInterface to Alias deviation locator.
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.
- attached_to(self: alias_api.AlDeviationLocator) tuple[int, alias_api.AlObject, alias_api.AlObject]
Returns the two objects that are used to create the deviation locator. This locator can be attached to curves on surfaces or curve nodes.
- Returns
A tuple containing: (1) the status code result of the operation:
Success - the attached to objects were found InvalidObject - the object is not valid Failure - the method failed
the first object
the second object
- copy_wrapper(self: alias_api.AlDeviationLocator) alias_api.AlObject
Return an exact duplicate of this AlDeviationLocator wrapper.
- create(*args, **kwargs)
Overloaded function.
create(self: alias_api.AlDeviationLocator, base_curve: alias_api.AlCurve, target_curve: alias_api.AlCurve, base_param: typing.SupportsFloat = 0.0) -> int
Create a Deviation locator between two curves.
- param base_curve
The curve from which the deviation is calculated
- type base_curve
AlCurve
- param target_curve
The curve to which the minimum deviation is calculated
- type target_curve
AlCurve
- param base_param
The parameter on baseCurve from which the minimum deviation to the target curve is calculated.
- type base_paramu
float
- return
The status code result of the operation: Success - the deviation locator was successfully created. Failure - the locator was not created AlreadyCreated - object has already been created InvalidArgument - the baseCurve or targetCurve is not valid.
- rtype
AlStatusCode
create(self: alias_api.AlDeviationLocator, base_curve: alias_api.AlCurveOnSurface, target_curve: alias_api.AlCurve, base_param: typing.SupportsFloat = 0.0) -> int
Create a Deviation locator between a curve on surface an a curve.
- param base_curve
The curve on surface from which the deviation is calculated
- type base_curve
AlCurveOnSurface
- param target_curve
The curve to which the minimum deviation is calculated
- type target_curve
AlCurve
- param base_param
The parameter on baseCurve from which the minimum deviation to the target curve is calculated.
- type base_paramu
float
- return
The status code result of the operation: Success - the deviation locator was successfully created. Failure - the locator was not created AlreadyCreated - object has already been created InvalidArgument - the baseCurve or targetCurve is not valid.
- rtype
AlStatusCode
create(self: alias_api.AlDeviationLocator, base_curve: alias_api.AlCurveOnSurface, target_curve: alias_api.AlCurveOnSurface, base_param: typing.SupportsFloat = 0.0) -> int
Create a Deviation locator between two curves on surface.
- param base_curve
The curve on surface from which the deviation is calculated
- type base_curve
AlCurveOnSurface
- param target_curve
The curve on surfaceto which the minimum deviation is calculated
- type target_curve
AlCurveOnSurface
- param base_param
The parameter on baseCurve from which the minimum deviation to the target curve is calculated.
- type base_paramu
float
- return
The status code result of the operation: Success - the deviation locator was successfully created. Failure - the locator was not created AlreadyCreated - object has already been created InvalidArgument - the baseCurve or targetCurve is not valid.
- rtype
AlStatusCode
- deviation(self: alias_api.AlDeviationLocator) tuple[int, float]
Finds the minimum deviation as calculated by the deviation locator
- Returns
The status code result of the operation: Success - the deviation was found InvalidObject - the object is not valid
- Return type
- deviation_components(self: alias_api.AlDeviationLocator) tuple[int, float, float, float]
Finds the components of minimum deviation as calculated by the deviation locator
- Returns
The status code result of the operation: Success - the deviation components were found InvalidObject - the object is not valid
- Return type
- left_justify(self: alias_api.AlDeviationLocator) tuple[int, int]
Find whether the text of deviation locator is left justified or right justified.
- Returns
A tuple containing: (1) the status code result of the operation:
Success - the justification was found InvalidObject - the object is not valid
a boolean value indicating whether the text is left justified
- Return type
tuple<AlStatusCode, bool>
- length(self: alias_api.AlDeviationLocator) tuple[int, float]
Find the length of the leader line in the deviation locator.
- Returns
The status code result of the operation: Success - the length was found successfully InvalidObject - the object is not valid
- Return type
- offset(self: alias_api.AlDeviationLocator) tuple[int, float, float, float]
Find the components of display offset in the deviation locator
- Returns
A tuple containing: (1) the status code result of the operation:
Success - the offset was found successfully InvalidObject - the object is not valid
the offset x z value
the offset y value
the offset z value
- parameter(self: alias_api.AlDeviationLocator) tuple[int, float]
Get the curve parameter where deviation locator is located.
- Returns
A tuple containing: (1) the status code result of the operation:
Success - the parameter was found
the curve parameter at the locator
- Return type
tuple<AlStatusCode, float>
- parameter_target_curve(self: alias_api.AlDeviationLocator) tuple[int, float]
Finds the parameter on the targetCurve which is at the minimum deviation. to the baseCurve
- param
value: The value of the parameter on targetCurve.
- Returns
The status code result of the operation: Success - the parameter was found InvalidObject - the object is not valid
- Return type
- set_left_justify(self: alias_api.AlDeviationLocator, left_justify: SupportsInt) int
Set the justification of the text for the Deviation locator.
The text can be right justified or left justified.
- Parameters
left_justify (bool) – A value of true makes the text left justified and a value false makes it right justified.
- Returns
The status code result of the operation: Success - setting was successful InvalidObject - the object is not valid
- Return type
- set_length(self: alias_api.AlDeviationLocator, len: SupportsFloat) int
Set the length of the leader line in the deviation display in the modeling windows
- Parameters
len (float) – The length of the leader line
- Returns
The status code result of the operation: Success - the length was set successfully InvalidObject - the object is not valid
- Return type
- set_offset(self: alias_api.AlDeviationLocator, x: SupportsFloat, y: SupportsFloat, z: SupportsFloat) int
Set 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
- Parameters
x (float) – The offset x component
y (float) – The offset y component
z – The offset z component
- set_parameter(self: alias_api.AlDeviationLocator, u: SupportsFloat) int
Set the curve parameter at which the deviation locator is located.
- Parameters
u (float) – The curve parameter
- Returns
The status code result of the operation: Success - the parameter was set InvalidObject - the object is not valid
- Return type
- type(self: alias_api.AlDeviationLocator) alias_api.AlObjectType
Return the AlDeviationLocator type identifier.