<!--
{
  "availability" : [
    "iOS: 13.0.0 -",
    "iPadOS: 13.0.0 -",
    "macCatalyst: 13.4.0 -",
    "macOS: 10.15.4 -",
    "tvOS: 16.0.0 -",
    "visionOS: -"
  ],
  "documentType" : "symbol",
  "framework" : "Metal",
  "identifier" : "/documentation/Metal/MTLRasterizationRateLayerDescriptor/init(horizontal:vertical:)",
  "metadataVersion" : "0.1.0",
  "role" : "Initializer",
  "symbol" : {
    "kind" : "Initializer",
    "modules" : [
      "Metal"
    ],
    "preciseIdentifier" : "s:So35MTLRasterizationRateLayerDescriptorC5MetalE10horizontal8verticalABSaySfG_AFtcfc"
  },
  "title" : "init(horizontal:vertical:)"
}
-->

# init(horizontal:vertical:)

Initializes a layer rate map with a set of horizontal and vertical rasterization rates.

```
convenience init(horizontal: [Float], vertical: [Float])
```

## Parameters

`horizontal`

An array of the horizontal rates to apply across the grid.

`vertical`

An array of the vertical rates to apply across the grid.

## Return Value

A layer descriptor whose width is the number of horizontal rates and whose height is the number of vertical rates. The layer descriptor copies the values from the input parameters.

## Discussion

---

Copyright &copy; 2026 Apple Inc. All rights reserved. | [Terms of Use](https://www.apple.com/legal/internet-services/terms/site.html) | [Privacy Policy](https://www.apple.com/privacy/privacy-policy)