|
Action:
|
Gets the properties of a light.
|
|
|
Filename:
|
rbase/rnd_scm/lite_scm.cxx
|
|
|
APIs:
|
api_rh_get_light_args
|
|
|
Syntax:
|
(light:props light-type)
|
|
|
Arg Types:
|
light-type
|
light
|
|
|
Returns:
|
(string (string . string | integer | real | color | gvector) ...)
|
|
|
Description:
|
This extension returns a list of the
light-type, followed by pairs containing the property name and the present value.
|
|
|
light-type specifies a light entity.
|
|
|
Example:
|
; light:props
|
|
; Create a distant light.
|
|
(define distant1 (light "distant"))
|
|
;; distant1
|
|
; Get the properties of the distant light.
|
|
(light:props distant1)
|
|
;; (("intensity" . 1) ("color" . #[color 1 1 1])
|
|
;; ("location" . #[gvector 0 0 1])
|
|
;; ("to" . #[gvector 0 0 0]) ("shadows" . #f)
|
|
;; ("shadow resolution" . 256) ("shadow quality" . 4)
|
|
;; ("shadow softness" . 1))
|
|
; Create a spot light.
|
|
(define spot1 (light "spot"))
|
|
;; spot1
|
|
; Get the properties of the spot light.
|
|
(light:props spot1)
|
|
;; (("intensity" . 1) ("color" . #[color 1 1 1])
|
|
;; ("location" . #[gvector 0 0 1])
|
|
;; ("to" . #[gvector 0 0 0]) ("fall off" . 0)
|
|
;; ("cone angle" . 60) ("cone delta angle" . 5)
|
|
;; ("beam distribution" . 2) ("shadows" . #f)
|
|
;; ("shadow resolution" . 256) ("shadow quality" . 4)
|
|
;; ("shadow softness" . 1))
|