<!--
{
  "availability" : [
    "iOS: 27.0.0 -",
    "iPadOS: 27.0.0 -",
    "macCatalyst: -",
    "macOS: 27.0.0 -",
    "tvOS: 27.0.0 -",
    "visionOS: 27.0.0 -",
    "watchOS: 27.0.0 -"
  ],
  "documentType" : "symbol",
  "framework" : "AVFAudio",
  "identifier" : "/documentation/AVFAudio/AVReadOnlyAudioPCMBuffer/init(copying:)",
  "metadataVersion" : "0.1.0",
  "role" : "Initializer",
  "symbol" : {
    "kind" : "Initializer",
    "modules" : [
      "AVFAudio"
    ],
    "preciseIdentifier" : "s:8AVFAudio24AVReadOnlyAudioPCMBufferV7copyingACSo07AVAudioE0C_tcfc"
  },
  "title" : "init(copying:)"
}
-->

# init(copying:)

Creates a read-only buffer by copying audio data from an existing PCM buffer.

```
init(copying buffer: AVAudioPCMBuffer)
```

## Parameters

`buffer`

The source PCM buffer to copy from.

## Discussion

This initializer creates a new `AVAudioPCMBuffer` and copies all audio data,
ensuring the original buffer can continue to be used safely.

---

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)