<!--
{
  "availability" : [
    "iOS: 17.0.0 -",
    "iPadOS: 17.0.0 -",
    "macCatalyst: 17.0.0 -",
    "macOS: 14.0.0 -",
    "tvOS: 17.0.0 -",
    "visionOS: 1.0.0 -"
  ],
  "documentType" : "symbol",
  "framework" : "SwiftUI",
  "identifier" : "/documentation/SwiftUI/Shader/Argument/boundingRect",
  "metadataVersion" : "0.1.0",
  "role" : "Type Property",
  "symbol" : {
    "kind" : "Type Property",
    "modules" : [
      "SwiftUI"
    ],
    "preciseIdentifier" : "s:7SwiftUI6ShaderV8ArgumentV12boundingRectAEvpZ"
  },
  "title" : "boundingRect"
}
-->

# boundingRect

Returns an argument value representing the bounding rect of
the shape or view that the shader is attached to, as
`float4(x, y, width, height)`. This value is undefined for
shaders that do not have a natural bounding rect (e.g.
filter effects drawn into `GraphicsContext`).

```
static var boundingRect: Shader.Argument { get }
```

---

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)