---
title: "VisionResult.detectRectangles(_:_:)"
framework: vision
role: symbol
role_heading: Case
path: "vision/visionresult/detectrectangles(_:_:)"
---

# VisionResult.detectRectangles(_:_:)

A result from performing a detect rectangles request.

## Declaration

```swift
case detectRectangles(DetectRectanglesRequest, [RectangleObservation])
```

## See Also

### Getting the optical flow, rectangle and barcode detection result

- [VisionResult.trackOpticalFlow(_:_:)](vision/visionresult/trackopticalflow(_:_:).md)
- [VisionResult.detectBarcodes(_:_:)](vision/visionresult/detectbarcodes(_:_:).md)
