---
title: "init(sampleCount:)"
framework: metal
role: symbol
role_heading: Initializer
path: "metal/mtlrasterizationratelayerdescriptor/init(samplecount:)"
---

# init(sampleCount:)

Initializes the layer map with an empty grid.

## Declaration

```swift
init(sampleCount: MTLSize)
```

## Parameters

- `sampleCount`: The size of the grid. Specify the width and height to determine the number of columns and rows in the layer map. The initializer ignores the depth component.

## Return Value

Return Value A layer descriptor with a grid of the specified size. All of the rasterization rates are set to 0.0.

## See Also

### Creating a layer rasterization rate descriptor

- [init(horizontal:vertical:)](metal/mtlrasterizationratelayerdescriptor/init(horizontal:vertical:).md)
