# world_matrix()

把这根骨骼的当前位置读成 4×4 矩阵。不会移动画面。

省略 `space` 就是世界坐标。`"local"` 是相对父骨骼。用了 `"local"` 但还不知道父子关系，会 `SessionError`。`world` 和 `local` 以外的文字会被拒绝。

只需要 Show Transform 窗口里的数字时，[trs](trs.md) 更好读。

### 签名
```python
bone.world_matrix(space="world") -> 4x4
```

| space | 含义 |
|---|---|
| `"world"` | 场景空间。默认。 |
| `"local"` | 相对父骨骼。 |

### 示例
```python
bone = api.bone("Bip001 Spine")
print(bone.world_matrix())
print(bone.world_matrix("local"))
```