set_use_caps¶
-
pydl.pydlutils.mangle.
set_use_caps
(polygon, index_list, add=False, tol=1e-10, allow_doubles=False, allow_neg_doubles=False)[source]¶ Set the bits in use_caps for a polygon.
Parameters: polygon :
ManglePolygon
A polygon object.
index_list : array-like
A list of indices of caps to set in the polygon. Should be no longer, nor contain indices greater than the number of caps (
polygon.ncaps
).add :
bool
, optionalIf
True
, don’t initialize the use_caps value to zero, use the existing value associated withpolygon
instead.tol :
float
, optionalTolerance used to determine whether two caps are identical.
allow_doubles :
bool
, optionalNormally, this routine automatically sets use_caps such that no two caps with use_caps set are identical.
allow_neg_doubles :
bool
, optionalNormally, two caps that are identical except for the sign of
cm
would be set unused. This inhibits that behaviour.Returns: Value of use_caps.