<!--
{
  "availability" : [
    "iOS: 18.0.0 -",
    "iPadOS: 18.0.0 -",
    "macCatalyst: 18.0.0 -",
    "macOS: 15.0.0 -",
    "tvOS: 26.0.0 -",
    "visionOS: 2.0.0 -"
  ],
  "documentType" : "symbol",
  "framework" : "RealityKit",
  "identifier" : "/documentation/RealityKit/AnchoringComponent/ObjectAnchoringSource",
  "metadataVersion" : "0.1.0",
  "role" : "Structure",
  "symbol" : {
    "kind" : "Structure",
    "modules" : [
      "RealityKit"
    ],
    "preciseIdentifier" : "s:17RealityFoundation18AnchoringComponentV06ObjectC6SourceV"
  },
  "title" : "AnchoringComponent.ObjectAnchoringSource"
}
-->

# AnchoringComponent.ObjectAnchoringSource

Defines the source of object anchoring target based on how it is created.

```
struct ObjectAnchoringSource
```

## Topics

### Creating an object anchoring source

[`init(referenceObject: Data)`](/documentation/RealityKit/AnchoringComponent/ObjectAnchoringSource/init(referenceObject:))

Creates the object anchoring source by reference object file data.

### Initializers

[`init(URL)`](/documentation/RealityKit/AnchoringComponent/ObjectAnchoringSource/init(_:))

Creates the object anchoring source by reference object file URL.

[`init(group: String, name: String)`](/documentation/RealityKit/AnchoringComponent/ObjectAnchoringSource/init(group:name:))

Creates the object anchoring source by group and name in AR Resources.

[`init(name: String, in: Bundle)`](/documentation/RealityKit/AnchoringComponent/ObjectAnchoringSource/init(name:in:))

Creates the object anchoring source by reference object file asset with provided name and bundle.

## Relationships

### Conforms To

[`Hashable`](/documentation/Swift/Hashable)

[`Equatable`](/documentation/Swift/Equatable)

---

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)