mirror of
https://github.com/vrm-c/UniVRM.git
synced 2026-09-11 21:38:56 -05:00
update docfx
This commit is contained in:
@@ -35,3 +35,28 @@ async Task<RuntimeGltfInstance> LoadAsync(string path)
|
||||
}
|
||||
}
|
||||
```
|
||||
|
||||
# Recommended camera layer settings
|
||||
|
||||
Suppose your scene has a camera that represents a head-mounted display and other cameras.
|
||||
|
||||
* FIRSTPERSON_ONLY_LAYER(The gameObject that specifies this layer disappears from other cameras)
|
||||
* THIRDPERSON_ONLY_LAYER(The gameObject that specifies this layer disappears from the head-mounted display)
|
||||
|
||||
Stops drawing the avatar from the head-mounted display perspective and makes it visible to other cameras.
|
||||
|
||||
Example: Stop drawing the avatar's head so you can see the front
|
||||
|
||||
VRM reserves layers named `VRMFirstPersonOnly` and` VRMThirdPersonOnly`.
|
||||
|
||||
Please set `VRMFirstPersonOnly` and` VRMThirdPersonOnly` to `Project Settings`-`Tags and Layers`.
|
||||
|
||||
In the sample, we assign `9` and` 10` to each.
|
||||
|
||||
# Specify layer at initialization
|
||||
|
||||
It can be specified with an additional argument.
|
||||
|
||||
```cs
|
||||
var created = await controller.Vrm.FirstPerson.SetupAsync(controller.gameObject, firstPersonOnlyLayer: 9, thirdPersonOnlyLayer: 10);
|
||||
```
|
||||
|
||||
@@ -1,3 +1,5 @@
|
||||
# Runtime に FirstPerson 機能を有効にする
|
||||
|
||||
VR向け FirstPerson 設定の初期化手順です。
|
||||
|
||||
1. Load する
|
||||
@@ -35,3 +37,30 @@ async Task<RuntimeGltfInstance> LoadAsync(string path)
|
||||
}
|
||||
}
|
||||
```
|
||||
|
||||
# VRMの推奨する VR 向けのカメラ構成
|
||||
|
||||
ヘッドマウントディスプレイを表すカメラ と その他のカメラという2種類のカメラを想定ます。
|
||||
それぞれに対して、
|
||||
|
||||
* FIRSTPERSON_ONLY_LAYER(このレイヤーを指定した gameObject はその他のカメラから消えます)
|
||||
* THIRDPERSON_ONLY_LAYER(このレイヤーを指定した gameObject はヘッドマウントディスプレイから消えます)
|
||||
|
||||
を定義します。
|
||||
これにより、ヘッドマウント視点のアバターの描画を抑止しつつ、他者からは見えるようにします。
|
||||
|
||||
例: アバターの頭の描画を抑止して前が見えるようにする
|
||||
|
||||
VRMは、`VRMFirstPersonOnly` と `VRMThirdPersonOnly` という名前のレイヤーを予約しています。
|
||||
|
||||
`Project Settings` - `Tags and Layers` に `VRMFirstPersonOnly` と `VRMThirdPersonOnly` を
|
||||
設定してください。
|
||||
サンプルでは、それぞれに `9` と `10` を割り当ています。
|
||||
|
||||
# 初期化時に layer を明示する
|
||||
|
||||
追加の引数で指定できます。
|
||||
|
||||
```cs
|
||||
var created = await controller.Vrm.FirstPerson.SetupAsync(controller.gameObject, firstPersonOnlyLayer: 9, thirdPersonOnlyLayer: 10);
|
||||
```
|
||||
|
||||
Reference in New Issue
Block a user