Original Spec|
Sample
定義
DirectionalLight {
exposedField SFFloat ambientIntensity 0 # [0,1]
exposedField SFColor color 1 1 1 # [0,1]
exposedField SFVec3f direction 0 0 -1 # (-,)
exposedField SFFloat intensity 1 # [0,1]
exposedField SFBool on TRUE
}
- ambientIntensity
- 物体の光の当たっていない面もこの強さのdiffuseColorで光ります。
- color
- 光の色
- direction
- 光の方向
- intensity
- 光の強さ
- on
- 光を発するかどうか
サンプル
光の当たる角度で面の明るさが変わるようにしてみました
#VRML V2.0 utf8
DirectionalLight {
color 0 1 0
direction .5 .7 -1
}
Shape {
geometry Box {}
appearance Appearance { material Material {} }
}
NavigationInfo {
headlight FALSE
type ["EXAMINE" "ANY"]
}
#http://vrmlbyhand.hoops.ne.jp/ref/DirectioanlLight.wrl