physical_sky

Used for operations concerning Physical Sky, assigned to the first layer of Distant Lights.


xshade
scene
physical_sky

List of Methods

get_color Gets the sky color based on specifying the vector from the eye point towards the sky
set_datetime Specifies the date and time
set_datetime_end Specifies the ending date and time for animations
set_now_datetime Specifies the current date and time
set_now_datetime_end Specifies the date and time of the animation end as the current date and time

List of Properties

background_auto_color Automatic adjustment of the background color
direction Direction of the light
color Color of the light (unused)
datetime_day The day (1 - 31)
datetime_day_end The day at the end frame (1 - 31)
datetime_hour The hour (0 - 23)
datetime_hour_end The hour at the end frame (0 - 23)
datetime_minutes The minutes (0 - 59)
datetime_minutes_end The minutes at the end frame (0 - 59)
datetime_month The month (1 - 12)
datetime_month_end The month at the end frame (1 - 12)
datetime_second The seconds (0 - 59)
datetime_second_end The seconds at the end frame (0 - 59)
enable_animation_end Whether or not to execute the animation with a specified end frame
gamma The gamma value of the background and light color
intensity The intensity adjustment
latitude Latitude
longitude Longitude
north_angle Angle of rotation that indicates North
utc UTC (time zone)
turbidity Atmosphere (turbidity)
update_light_color Whether to automatically update the light color
use_background Whether or not to use the upper hemisphere background color to draw the look of the sky based on the direction of the distant lights
use_sun Uses sun calculations for the first distant light




Get Physical Sky objects with xshade.scene().distant_light.physical_sky().

Method Details

get_sky_color

Gets the sky color based on specifying the vector from the eye point towards the sky.
Return value :
  rgb
Arguments :
  vec3 : direction from the eye point to the sky

#Output the sky color looking from the eye point straight up (0, 1, 0)
print xshade.scene().distant_light.physical_sky().get_sky_color([0, 1, 0])

set_datetime

Specifies the date and time.
Arguments :
  int : month (1-12)
  int : day (1-31)
  int : hour (0-23)
  int : minutes (0-59)
  int : seconds (0-59)

#Specify 02/20 14:15:00
print xshade.scene().distant_light.physical_sky().set_datetime(2, 20, 14, 15, 0)

set_datetime_end

Specifies the ending date and time for animations.
Arguments :
  int : month (1-12)
  int : day (1-31)
  int : hour (0-23)
  int : minutes (0-59)
  int : seconds (0-59)

#Specify 02/20 16:15:00 as the ending date and time for the animation
print xshade.scene().distant_light.physical_sky().set_datetime_end(2, 20, 16, 15, 0)

set_now_datetime

Specifies the current date and time.

#Specify the current date and time
print xshade.scene().distant_light.physical_sky().set_now_datetime()

set_now_datetime_end

Specifies the date and time of the animation end as the current date and time

#Set the ending time and date of the animation to the current time and date
print xshade.scene().distant_light.physical_sky().set_now_datetime_end()

Property Details

background_auto_color

Automatic adjustment of the background color.

  • Get
  • Set

Type :
  bool

#Output the Background Auto Color on/off value
print xshade.scene().distant_light.physical_sky().background_auto_color

direction

Direction of the light.

  • Get
  • Set

Type :
  vec3

#Output the direction of the light
print xshade.scene().distant_light.physical_sky().direction

color

The light color.

  • Get
  • Set

Type :
  rgb

Not used in Shade 13.1.

#Output the light color
print xshade.scene().distant_light.physical_sky().color

datetime_day

The day (1 - 31).

  • Get
  • Set

Type :
  int

#Output the day
print xshade.scene().distant_light.physical_sky().datetime_day

datetime_day_end

The day at the end frame (1 - 31).

  • Get
  • Set

Type :
  int

#Output the day at the end frame
print xshade.scene().distant_light.physical_sky().datetime_day_end

datetime_hour

The hour (0 - 23).

  • Get
  • Set

Type :
  int

#Output the hour
print xshade.scene().distant_light.physical_sky().datetime_hour

datetime_hour_end

The hour at the end frame (0 - 23).

  • Get
  • Set

Type :
  int

#Output the hour at the end frame
print xshade.scene().distant_light.physical_sky().datetime_hour_end

datetime_minutes

The minutes (0 - 59).

  • Get
  • Set

Type :
  int

#Output the minutes
print xshade.scene().distant_light.physical_sky().datetime_minutes

datetime_minutes_end

The minutes at the end frame (0 - 59).

  • Get
  • Set

Type :
  int

#Output the minutes at the end frame
print xshade.scene().distant_light.physical_sky().datetime_minutes_end

datetime_month

The month (1 - 12).

  • Get
  • Set

Type :
  int

#Output the month
print xshade.scene().distant_light.physical_sky().datetime_month

datetime_month_end

The month at the end frame (1 - 12).

  • Get
  • Set

Type :
  int

#Output the month at the end frame
print xshade.scene().distant_light.physical_sky().datetime_month_end

datetime_second

The seconds (0 - 59).

  • Get
  • Set

Type :
  int

#Output the seconds
print xshade.scene().distant_light.physical_sky().datetime_second

datetime_second_end

The seconds at the end frame (0 - 59).

  • Get
  • Set

Type :
  int

#Output the seconds at the end frame
print xshade.scene().distant_light.physical_sky().datetime_second_end

enable_animation_end

Whether or not to execute the animation with a specified end frame.

  • Get
  • Set

Type :
  bool

#Output the on/off value of "Enable Animation End Date Time"
print xshade.scene().distant_light.physical_sky().enable_animation_end

gamma

The gamma value of the background and light color.

  • Get
  • Set

Type :
  float

#Output the gamma value
print xshade.scene().distant_light.physical_sky().gamma

intensity

The intensity adjustment.

  • Get
  • Set

Type :
  float

#Output the intensity value
print xshade.scene().distant_light.physical_sky().intensity

latitude

Latitude.

  • Get
  • Set

Type :
  float

#Output the latitude
print xshade.scene().distant_light.physical_sky().latitude

longitude

Longitude.

  • Get
  • Set

Type :
  float

#Output the longitude
print xshade.scene().distant_light.physical_sky().longitude

north_angle

Angle of rotation that indicates North. 0 means North is in the -Z direction.

  • Get
  • Set

Type :
  float

#Output the angle of rotation that indicates North
print xshade.scene().distant_light.physical_sky().north_angle

utc

The UTC (time zone). Japan is 9.0.

  • Get
  • Set

Type :
  float

#Output the UTC
print xshade.scene().distant_light.physical_sky().utc

turbidity

Atmosphere (turbidity). Specify a real number between 0.0 and 1.0.

  • Get
  • Set

Type :
  float

#Output the atmosphere (turbidity) value
print xshade.scene().distant_light.physical_sky().turbidity

update_light_color

Whether to automatically update the light color.

  • Get
  • Set

Type :
  bool

#Output the "Light Color" on/off value
print xshade.scene().distant_light.physical_sky().update_light_color

use_background

Whether or not to use the upper hemisphere background color to draw the look of the sky based on the direction of the distant lights.

  • Get
  • Set

Type :
  bool

#Output the background "Enable" on/off value
print xshade.scene().distant_light.physical_sky().use_background

use_sun

Uses sun calculations for the first distant light.

  • Get
  • Set

Type :
  bool

#Output the sun "Enable" on/off value
print xshade.scene().distant_light.physical_sky().use_sun