# Interface: ITransformData

[Transform](/miniprogram/dev/reference/xr-frame/api/classes/Transform)组件数据接口。

## Table of contents

### Properties

- layer
- nodeId
- position
- rotation
- scale
- visible

## Properties

### layer

• `Optional` **layer**: `number`

节点的层级，作为控制节点以及子节点是否可见的一部分，配合[Camera.cullMask](../classes/Camera#cullMask)使用。
判定规则为自顶层节点向下，只有全部通过了判定才能显示。
`xml`中的数据类型为`number`，默认为`0`。

___

### nodeId

• **nodeId**: `string`

设置一个唯一的节点Id，区别于`xml`上的那个`id`。
`xml`中的数据类型为`string`。

___

### position

• **position**: `number`[]

节点的位移。
`xml`中的数据类型为`number-array`，默认为`0 0 0`。

___

### rotation

• **rotation**: `number`[]

节点的旋转，注意此处为**角度**。
`xml`中的数据类型为`number-array`，默认为`0 0 0`。

___

### scale

• **scale**: `number`[]

节点的位缩放。
`xml`中的数据类型为`number-array`，默认为`1 1 1`。

___

### visible

• `Optional` **visible**: `boolean`

节点的可见性，可以控制该节点以及所有子节点是否可见。
`xml`中的数据类型为`boolean`，默认为`true`。
