When to use it
You may get the waste during the OnFinish event.
Otherwise the returned value is undefined.
BarIndex : Long /*in*/,
Waste : Double /*out*/,
RepositoryIndex: Long /*[out]*/,
RepositoryExternalID: Long /*[out]*/
The waste obtained for a particular bar from Repository.
Even if the input data are given as integer numbers, the GetWaste may be real-valued, because of some cosine functions involved in the computing of BladeWidth parameter for angle cuttings.
BarIndex - is the index of the bar whose waste is request. BarIndex must be between 0 and TotalNumberOfUtilizedRepositoryPieces.
Waste - the result of calling this method is stored in this variable.
RepositoryIndex is the index of bar as it was set by the SetRepositoryPiece method. RepositoryIndex is between 0 and NumberOfRepositoryPieces - 1.
RepositoryExternalID is the external ID of the repository piece whose input index is BarIndex. External ID is an integer number which was assigned to each piece in order to be easier identified.
The waste piece has the angles for both extremities equals to 90 degrees !
The last cut should always be performed vertically in order to reduce the waste generated by the cutting blade.
The waste computed after this operation as can be seen in the picture below:
If the length of the remaining material (from the end of the useful part to the end of the bar) is less than the BladeWidth, the resulted Waste is 0.
back to index