---
title: "simdConvertVector(_:from:)"
framework: scenekit
role: symbol
role_heading: Instance Method
path: "scenekit/scnnode/simdconvertvector(_:from:)"
---

# simdConvertVector(_:from:)

Converts a direction vector to the node’s local coordinate space from that of another node.

## Declaration

```swift
func simdConvertVector(_ vector: simd_float3, from node: SCNNode?) -> simd_float3
```

## Parameters

- `vector`: A direction vector in the local coordinate space defined by the other node.
- `node`: Another node in the same scene graph as the node, or nil to convert from the scene’s world coordinate space.

## Return Value

Return Value A direction vector in the node’s local coordinate space.

## Discussion

Discussion Unlike the simdConvertPosition(_:from:) method, this method ignores the translational aspect of both nodes’ transforms. As such, this method is more appropriate for use with vectors that represent only directional information, such as velocity or facing.

## See Also

### Related Documentation

- [convertVector(_:from:)](scenekit/scnnode/convertvector(_:from:).md)

### Converting Between Coordinate Spaces

- [simdConvertPosition(_:from:)](scenekit/scnnode/simdconvertposition(_:from:).md)
- [simdConvertPosition(_:to:)](scenekit/scnnode/simdconvertposition(_:to:).md)
- [simdConvertTransform(_:from:)](scenekit/scnnode/simdconverttransform(_:from:).md)
- [simdConvertTransform(_:to:)](scenekit/scnnode/simdconverttransform(_:to:).md)
- [simdConvertVector(_:to:)](scenekit/scnnode/simdconvertvector(_:to:).md)
