# Generate(Mesh, SpriteShapeParameters, ShapeControlPoint[], SpriteShapeMetaData[], AngleRangeInfo[], Sprite[], Sprite[])

> Generate a mesh based on input parameters.

## Definition

* **Type:** Method
* **Namespace:** [UnityEngine.U2D](/engine/6000.6/script-reference/unityengine/u2d.md)
* **Assembly:** UnityEngine.SpriteShapeModule

```csharp
public static int[] Generate(Mesh mesh, SpriteShapeParameters shapeParams, ShapeControlPoint[] points, SpriteShapeMetaData[] metaData, AngleRangeInfo[] angleRange, Sprite[] sprites, Sprite[] corners)
```

### Parameters

**** (\[Mesh]\(/engine/6000.6/script-reference/unityengine/mesh)): The output mesh.**** (\[SpriteShapeParameters]\(/engine/6000.6/script-reference/unityengine/u2d/spriteshapeparameters)): Input parameters for the SpriteShape tessellator.**** (\[ShapeControlPoint\[]]\(/engine/6000.6/script-reference/unityengine/u2d/shapecontrolpoint)): A list of control points that describes the shape.**** (\[SpriteShapeMetaData\[]]\(/engine/6000.6/script-reference/unityengine/u2d/spriteshapemetadata)): Additional data about the shape's control point. This is useful during tessellation of the shape.**** (\[AngleRangeInfo\[]]\(/engine/6000.6/script-reference/unityengine/u2d/anglerangeinfo)): A parameter that determins how to tessellate each of the edge.**** (\[Sprite\[]]\(/engine/6000.6/script-reference/unityengine/sprite)): The list of Sprites that could be used for the edges.**** (\[Sprite\[]]\(/engine/6000.6/script-reference/unityengine/sprite)): The list of Sprites that could be used for the corners.

### Returns

| Type                                                           | Description |
| -------------------------------------------------------------- | ----------- |
| [int\[\]](https://learn.microsoft.com/dotnet/api/system.int32) |             |
