SpotLight (クラス)
public SpotLight {inherits SceneLight}
パッケージ: CURL.GRAPHICS.SCENE

スポット ライト。点滅ライトと同様 - 円錐内の原点から発せられる光線。


コンストラクタ
default:新規の SpotLight を作成します。
コンストラクタ public {SpotLight.default
position:Distance3d = {Distance3d 0m, 0m, 0m},
direction:Direction3d = {Direction3d 0, 0, -1},
spot-angle:Angle = 30deg,
spot-exponent:double = 3,
diffuse-color:Color = {Palette.get-white},
specular-color:Color = {Palette.get-white},
enabled?:bool = true,
eye-space?:bool = false,
transformation:Transformation3d = {Transformation3d},
visible?:bool = false,
name:#String = null,
...
}

プロパティ
direction:光の方向。
アクセサ public SpotLight.direction:Direction3d
セッター public SpotLight.direction:Direction3d
spot-angle:スポット ライトの円錐角度。
アクセサ public SpotLight.spot-angle:Angle
セッター public SpotLight.spot-angle:Angle
spot-exponent:スポット ライトの減少の指数。
アクセサ public SpotLight.spot-exponent:double
セッター public SpotLight.spot-exponent:double
プロパティ 継承 SceneLight: diffuse-color, enabled?, eye-space?, specular-color
プロパティ 継承 SceneObject: bounding-box-caching-enabled?, bounding-box-or-object-visible?, cached-bounding-box-dirty?, controller, local-bounding-box-color, local-bounding-box-line-width, local-bounding-box-visible?, name, opaque-to-intersection?, parent, parent-bounding-box-color, parent-bounding-box-line-width, parent-bounding-box-visible?, scene, transformation, visible?, world-bounding-box-color, world-bounding-box-line-width, world-bounding-box-visible?, world-position, world-transformation
プロパティ 継承 EventTarget: event-handlers

メソッド
shine:照明のプロパティを設定するために Scene から呼び出すメソッド。
public {SpotLight.shine renderer:Renderer3d}:void
メソッド 継承 SceneLight: get-local-bounding-box
メソッド 継承 SceneObject: get-cached-local-bounding-box, get-parent-bounding-box, get-transformed-bounding-box, get-world-bounding-box, intersect-box, intersect-line, intersect-line-segment, intersect-ray, intersect-sphere, ndc-point-to-ray, paint, point-to-ndc-point, point-to-viewport-point, pre-paint, rotate, scale, set-orientation-and-position, translate, viewport-point-to-ray
メソッド 継承 EventTarget: accepts-event-class?, add-event-handler, event-handler-present?, handle-event, remove-event-handler, verify-event
メソッド 継承 BasicEventTarget: enqueue-event
メソッド 継承 Object: object-describe, object-describe-for-debugging, object-serialize



コンストラクタ詳細
default (コンストラクタ)
public {SpotLight.default
position:Distance3d = {Distance3d 0m, 0m, 0m},
direction:Direction3d = {Direction3d 0, 0, -1},
spot-angle:Angle = 30deg,
spot-exponent:double = 3,
diffuse-color:Color = {Palette.get-white},
specular-color:Color = {Palette.get-white},
enabled?:bool = true,
eye-space?:bool = false,
transformation:Transformation3d = {Transformation3d},
visible?:bool = false,
name:#String = null,
...
}

新規の SpotLight を作成します。

position: 照明の位置 (光線の源)。既定値は {Distance3d 0m, 0m, 0m} になります。
SpotLight.directionSpotLight.spot-angleSpotLight.spot-exponentSpotLight.diffuse-colorSpotLight.specular-colorSpotLight.enabled? および SpotLight.eye-space? については、個々のアクセッサのドキュメントを参照してください。
transformation: SpotLight の初期の Transformation3d。既定値は実体の変換になります。
visible?: SpotLight が可視かどうかを指定するブール値。SpotLight は通常、描画されないのでこのパラメータが普通影響を与えることはありません。
name: SpotLight の名前を表す String。既定値は null になります。
...:
各残余引数は、新規に作成されたオブジェクトの EventTarget.add-event-handler メソッドに送信される EventHandler にする必要があります。
変換に関連する残余引数の詳細については、SceneObject.default を参照してください。



プロパティ詳細
direction (アクセサ)
アクセサ public SpotLight.direction:Direction3d
セッター public SpotLight.direction:Direction3d

光の方向。



spot-angle (アクセサ)
アクセサ public SpotLight.spot-angle:Angle
セッター public SpotLight.spot-angle:Angle

スポット ライトの円錐角度。



spot-exponent (アクセサ)
アクセサ public SpotLight.spot-exponent:double
セッター public SpotLight.spot-exponent:double

スポット ライトの減少の指数。

説明

SpotLight.spot-exponent 円錐の中心から端までの光度の減少度を制御します。SpotLight.spot-exponent = 0の場合は、光度は一切減少しません。SpotLight.spot-exponent = 1 の場合は、光度は線形減少します。1 より大きい値は光度が線形より大きい割合で減少することを意味します。





メソッド詳細
shine (メソッド)
public {SpotLight.shine renderer:Renderer3d}:void

照明のプロパティを設定するために Scene から呼び出すメソッド。