---
title: "presentingViewController(for:)"
framework: visionkit
role: symbol
role_heading: Instance Method
path: "visionkit/imageanalysisinteractiondelegate/presentingviewcontroller(for:)"
---

# presentingViewController(for:)

Provides the view controller that presents the interface objects.

## Declaration

```swift
@MainActor func presentingViewController(for interaction: ImageAnalysisInteraction) -> UIViewController?
```

## Parameters

- `interaction`: The associated interaction object for the presented view.

## Return Value

Return Value The view controller that presents the interaction object’s highlights, menus, and other elements.

## Discussion

Discussion The default return value is the window’s root view controller.

## See Also

### Providing interface details

- [contentView(for:)](visionkit/imageanalysisinteractiondelegate/contentview(for:).md)
- [contentsRect(for:)](visionkit/imageanalysisinteractiondelegate/contentsrect(for:).md)
