---
title: "export(to:metadataURL:modelProvider:exportOptions:)"
framework: roomplan
role: symbol
role_heading: Instance Method
path: "roomplan/capturedstructure/export(to:metadataurl:modelprovider:exportoptions:)"
---

# export(to:metadataURL:modelProvider:exportOptions:)

Produces a 3D asset from the captured structure.

## Declaration

```swift
func export(to url: URL, metadataURL: URL? = nil, modelProvider: CapturedStructure.ModelProvider? = nil, exportOptions: CapturedStructure.USDExportOptions = .mesh) throws
```

## Parameters

- `url`: A location that the captured structure exports to.
- `metadataURL`: A location that the captured room metadata exports to.
- `modelProvider`: A collection of mappings of object categories and attributes to 3D model URLs.
- `exportOptions`: Options that determine the export’s data format.

## Discussion

Discussion The file format of the output is Universal Scene Description (USD). tip: Before iOS 17.4, the first letter of the USD file name needs to be a character other than a number.

## See Also

### Generating a USDZ file

- [CapturedStructure.USDExportOptions](roomplan/capturedstructure/usdexportoptions.md)
- [CapturedStructure.ModelProvider](roomplan/capturedstructure/modelprovider.md)
