Version: 5.6

Projector

class in UnityEngine

/

継承:Behaviour

マニュアルに切り替える

説明

projector component 用のスクリプトインターフェースです。

The Projector can be used to project any material onto the scene - just like a real world projector. The properties exposed by this class are an exact match for the values in the Projector's inspector.

It can be used to implement blob or projected shadows. You could also project an animated texture or a render texture that films another part of the scene. The projector will render all objects in its view frustum with the provided material.

There is no shortcut property in GameObject or Component to access the Projector, so you must use GetComponent to do it:

using UnityEngine;
using System.Collections;

public class ExampleClass : MonoBehaviour { void Start() { Projector proj = GetComponent<Projector>(); proj.nearClipPlane = 0.5F; } }

関連項目: projector component.

変数

aspectRatioプロジェクターのアスペクト比を設定する
farClipPlaneカメラに映る遠さを表す平面の距離。
fieldOfViewプロジェクションの視野角
ignoreLayers無視されるレイヤーを設定する
materialすべてのオブジェクトに投影されるマテリアルを設定する
nearClipPlaneカメラに映る近さを表す平面の距離。
orthographicプロジェクションを正射影にする場合は true にする
orthographicSize正射影モードのときは、プロジェクションのサイズを半分にする

継承メンバー

変数

enabled有効であれば更新され、無効であれば更新されません。
isActiveAndEnabledBehaviour が有効かどうか
gameObjectこのコンポーネントはゲームオブジェクトにアタッチされます。コンポーネントはいつもゲームオブジェクトにアタッチされています。
tagゲームオブジェクトのタグ
transformThe Transform attached to this GameObject.
hideFlagsオブジェクトは非表示、シーンに保存、ユーザーが編集可能、などを設定する。
nameオブジェクト名

Public 関数

BroadcastMessageゲームオブジェクトまたは子オブジェクトにあるすべての MonoBehaviour を継承したクラスにある methodName 名のメソッドを呼び出します。
CompareTagこのゲームオブジェクトは tag とタグ付けされているかどうか
GetComponentゲームオブジェクトに type がアタッチされている場合は type のタイプを使用してコンポーネントを返します。ない場合は null です
GetComponentInChildren GameObject や深さ優先探索を活用して、親子関係にある子オブジェクトから type のタイプのコンポーネントを取得します。
GetComponentInParent GameObject や深さ優先探索を活用して、親子関係にある親オブジェクトから type のタイプのコンポーネントを取得します。
GetComponents GameObject から type のタイプのコンポーネントを「すべて」取得します。
GetComponentsInChildren GameObject や深さ優先探索を活用して、親子関係にある子オブジェクトから type のタイプのコンポーネントを「すべて」取得します。
GetComponentsInParent GameObject や深さ優先探索を活用して、親子関係にある親オブジェクトから type のタイプのコンポーネントを「すべて」取得します。
SendMessageゲームオブジェクトにアタッチされているすべての MonoBehaviour にある methodName と名付けたメソッドを呼び出します
SendMessageUpwardsゲームオブジェクトと親(の親、さらに親 ... )にアタッチされているすべての MonoBehaviour にある methodName と名付けたメソッドを呼び出します
GetInstanceIDオブジェクトのインスタンス ID を返します
ToStringゲームオブジェクトの名前を返します

Static 関数

Destroyゲームオブジェクトやコンポーネント、アセットを削除します
DestroyImmediateDestroys the object obj immediately. You are strongly recommended to use Destroy instead.
DontDestroyOnLoad新しいシーンを読み込んでもオブジェクトが自動で破壊されないように設定します
FindObjectOfTypeタイプ type から最初に見つけたアクティブのオブジェクトを返します
FindObjectsOfTypeタイプから見つけたすべてのアクティブのオブジェクト配列を返します
Instantiateoriginal のオブジェクトをクローンします

Operator

boolオブジェクトが存在するかどうか
operator !=二つのオブジェクトが異なるオブジェクトを参照しているか比較します
operator ==2つのオブジェクト参照が同じオブジェクトを参照しているか比較します。