Instance Method

replacingDepthDataMap(with:)

Returns a derivative depth data object by replacing the depth data map.

Declaration

func replacingDepthDataMap(with pixelBuffer: CVPixelBuffer) throws -> Self

Parameters

pixelBuffer

A pixel buffer containing depth or disparity information in a compatible format.

Return Value

A new depth data object containing the pixel buffer.

Discussion

If you apply simple transforms to media containing depth data, you can use the applyingExifOrientation(_:) method to apply parallel transforms to the corresponding depth data. More complex transforms and edits require creating a derivative depth map reflecting whatever edits you make to the corresponding image. In such cases, use this replacingDepthDataMap(with:) method to create a derivative depth data object.

See Also

Transforming and Processing

func applyingExifOrientation(CGImagePropertyOrientation) -> Self

Returns a derivative depth data object by mirroring or rotating it to the specified orientation.

func converting(toDepthDataType: OSType) -> Self

Returns a derivative depth data object by converting the depth data map to the specified data type.

var availableDepthDataTypes: [NSNumber]

The list of depth data formats to which this depth data can be converted.

Beta Software

This documentation contains preliminary information about an API or technology in development. This information is subject to change, and software implemented according to this documentation should be tested with final operating system software.

Learn more about using Apple's beta software