---
title: "matrix4x4h::transformPosition"
framework: Compute Graph
role: symbol
role_heading: Function
platforms: [iOS 27.0+, iPadOS 27.0+, macOS 27.0+, tvOS 27.0+, visionOS 27.0+]
path: computegraph/matrix4x4h/transformposition
---

# matrix4x4h::transformPosition

Transforms a half-precision position by a 4x4 matrix, including translation.

## Declaration

```swift
half3 matrix4x4h::transformPosition(half4x4 matrix, half3 position)
```

## Parameters

- `matrix`: The 4x4 transformation matrix to apply.
- `position`: The 3D position to transform.

## Return Value

Return Value The transformed 3D position.

## Discussion

Discussion Multiplies the position by the matrix with a w component of 1.0, so rotation, scale, and translation are all applied. This is appropriate for points in space that should be fully transformed by the matrix. note:
