Name
ManualArrangeIsValidAddCut
When to use it
When the optimization process is NOT running.
NOT during the OnFinish or OnAfterManualArrange event.
After all other information has been set.
Prototype
HRESULT ManualArrangeIsValidAddCut(
X: long /*[in]*/,
Y: long /*[in]*/,
CutType: long /*[in]*/,
CutThickness: long /*[in]*/,
AllowCut: long /*[out]*/
);
Explanations
Checks if a cut can be performed. The cut must be inside of an existing waste rectangle. That waste will be split into 2 smaller waste rectangles.
Parameters
- X, Y - the coordinates of a point inside an existing waste rectangle. The cut will contain this point. The direction of the cut is given by the CutType parameter.
- CutType - 0 = best cut (the shortest one); 1 = Left Right first and then Top-Bottom; 2 = Top-Bottom first and then Left-Right. The value of this parameter is not important when multi-stages optimization is performed.
- CutThickness - the actual thickness of a cut. This can be anywhere between 0 and the BladeWidth.
- AllowCut - This parameter will receive value 1 if the cut operation is possible. Otherwise it will be set to 0.
See also
How to arrange pieces manually, ManualArrangeAddCut, ManualArrangeRemoveCut, OnAfterManualArrange.
Links