Relate
This file contains relate stitch functionality, you can create relate stitch, delete relate etc...
BwApiRelateCreate
Create a new relate between two edges.
Python
BwApi.RelateCreate(garmentId, side1, side2, autoRelateOtherEdges)
C++
BwApiRelateCreate(garmentId, side1, side2, autoRelateOtherEdges, newRelateIds);
C#
BwApi.RelateCreate(garmentId, side1, side2, autoRelateOtherEdges);
Parameters
Param | Variable | Description |
In | garmentId | Existing garment ID. |
In | side1 | 1st side of the relate stitch. |
In | side2 | 2nd side of the relate stitch. |
In | autoRelateOtherEdges | Automatically relate other edges of the shape if both shape have same number of edges (1/0). |
Out | newRelateIds | Array of all generated relate edges. |
Returns: Error/success code (see BwApiErrorCodes enum).
---
BwApiRelateCreateEx
Create a new relate with support for internal point.
Python
BwApi.RelateCreateEx(garmentId, side1, side2, autoRelateOtherEdges)
C++
BwApiRelateCreateEx(garmentId, side1, side2, autoRelateOtherEdges, newRelateIds);
C#
BwApi.RelateCreateEx(garmentId, side1, side2, autoRelateOtherEdges);
Parameters
Param | Variable | Description |
In | garmentId | Existing garment ID. |
In | side1 | 1st side of the relate stitch. |
In | side2 | 2nd side of the relate stitch. |
In | autoRelateOtherEdges | Automatically relate other edges of the shape if both shape have same number of edges (1/0). |
Out | newRelateIds | Array of all generated relate edges. |
Returns: Error/success code (see BwApiErrorCodes enum).
---
BwApiRelateMultiCreateEx
Create a new multi relate with support for internal point.
Python
BwApi.RelateMultiCreateEx(garmentId, side1, side2, autoRelateOtherEdges, includeSym)
C++
BwApiRelateMultiCreateEx(garmentId, side1, side2, autoRelateOtherEdges, includeSym, newRelateIds);
C#
BwApi.RelateMultiCreateEx(garmentId, side1, side2, autoRelateOtherEdges, includeSym);
Parameters
Param | Variable | Description |
In | garmentId | Existing garment ID. |
In | side1 | 1st side of the stitch. |
In | side2 | 2nd side of the stitch. |
In | autoRelateOtherEdges | Automatically relate other edges of the shape if both shape have same number of edges (1/0). |
In | includeSym | Include symmetry |
Out | newRelateIds | The newly created stitch IDs. |
Returns: Error/success code (see BwApiErrorCodes enum).
---
BwApiRelateIds
Get all relate IDs for the current garment.
Python
BwApi.RelateIds(garmentId)
C++
BwApiRelateIds(garmentId, relateIds);
C#
BwApi.RelateIds(garmentId);
Parameters
Param | Variable | Description |
In | garmentId | Existing garment ID. |
Out | relateIds | Array of int containing the relate IDs. |
Returns: Error/success code (see BwApiErrorCodes enum).
---
BwApiRelateDelete
Delete a relate.
Python
BwApi.RelateDelete(garmentId, relateId)
C++
BwApiRelateDelete(garmentId, relateId);
C#
BwApi.RelateDelete(garmentId, relateId);
Parameters
Param | Variable | Description |
In | garmentId | Existing garment ID. |
In | relateId | The relate ID to delete. |
Returns: Error/success code (see BwApiErrorCodes enum).
---
BwApiRelateSidesGet
Get a relate's side parameters.
Python
BwApi.RelateSidesGet(garmentId, relateId)
C++
BwApiRelateSidesGet(garmentId, relateId, side1, side2);
C#
BwApi.RelateSidesGet(garmentId, relateId);
Parameters
Param | Variable | Description |
In | garmentId | Existing garment ID. |
In | relateId | The relate ID. |
Out | side1 | The 1st side of the stitch (see BwApiStitchSide). |
Out | side2 | The 2nd side of the stitch (see BwApiStitchSide). |
Returns: Error/success code (see BwApiErrorCodes enum).
---
BwApiRelateSidesGetEx
Get a relate's side parameters with support for internal point.
Python
BwApi.RelateSidesGetEx(garmentId, relateId)
C++
BwApiRelateSidesGetEx(garmentId, relateId, side1, side2);
C#
BwApi.RelateSidesGetEx(garmentId, relateId);
Parameters
Param | Variable | Description |
In | garmentId | Existing garment ID. |
In | relateId | The relate ID. |
Out | side1 | The 1st side of the relate (see BwApiStitchSideEx). |
Out | side2 | The 2nd side of the relate (see BwApiStitchSideEx). |
Returns: Error/success code (see BwApiErrorCodes enum).
---
BwApiRelatesGet
Get all the relate IDs from two BwApiStitchSide.
Python
BwApi.RelatesGet(garmentId, side1, side2)
C++
BwApiRelatesGet(garmentId, side1, side2, relateIds);
C#
BwApi.RelatesGet(garmentId, side1, side2);
Parameters
Param | Variable | Description |
In | garmentId | Existing garment ID. |
In | side1 | The 1st side of the relate (see BwApiStitchSide). |
In | side2 | The 2nd side of the relate (see BwApiStitchSide). |
Out | relateIds | The relates IDs. |
Returns: Error/success code (see BwApiErrorCodes enum).
Note: Markers have no effect on the output.
---
BwApiRelatesGetEx
Get all the relates IDs from two BwApiStitchSideEx.
Python
BwApi.RelatesGetEx(garmentId, side1, side2)
C++
BwApiRelatesGetEx(garmentId, side1, side2, relateIds);
C#
BwApi.RelatesGetEx(garmentId, side1, side2);
Parameters
Param | Variable | Description |
In | garmentId | Existing garment ID. |
In | side1 | The 1st side of the relate (see BwApiStitchSideEx). |
In | side2 | The 2nd side of the relate (see BwApiStitchSideEx). |
Out | relateIds | The relates IDs. |
Returns: Error/success code (see BwApiErrorCodes enum).
Note: Markers have no effect on the output.
---