reckfellENGINE

ProceduralSkyMaterial

A material that defines a simple sky for a Sky resource.

On this page
class ProceduralSkyMaterialReckfellSharpInherits Material

A material that defines a simple sky for a Sky resource.

ProceduralSkyMaterial provides a way to create an effective background quickly by defining procedural parameters for the sun, the sky and the ground. The sky and ground are defined by a main color, a color at the horizon, and an easing curve to interpolate between them. Suns are described by a position in the sky, a color, and a max angle from the sun at which the easing curve ends. The max angle therefore defines the size of the sun in the sky. ProceduralSkyMaterial supports up to 4 suns, using the color, and energy, direction, and angular distance of the first four DirectionalLight3D nodes in the scene. This means that the suns are defined individually by the properties of their corresponding DirectionalLight3Ds and globally by ProceduralSkyMaterial.SunAngleMax and ProceduralSkyMaterial.SunCurve. ProceduralSkyMaterial uses a lightweight shader to draw the sky and is therefore suited for real-time updates. This makes it a great option for a sky that is simple and computationally cheap, but unrealistic. If you need a more realistic procedural option, use PhysicalSkyMaterial.

Declarations checked against C# SDK 1.0.0. Expand a name to see declarations and documentation.

Constructors1

ProceduralSkyMaterialConstructor
# ProceduralSkyMaterial
C#
public ProceduralSkyMaterial();

Properties14

EnergyMultiplierProperty
# EnergyMultiplier
C#
public float EnergyMultiplier { get; set; }

The sky's overall brightness multiplier. Higher values result in a brighter sky.

GroundBottomColorProperty
# GroundBottomColor
C#
public Color GroundBottomColor { get; set; }

Color of the ground at the bottom. Blends with ProceduralSkyMaterial.GroundHorizonColor.

GroundCurveProperty
# GroundCurve
C#
public float GroundCurve { get; set; }

How quickly the ProceduralSkyMaterial.GroundHorizonColor fades into the ProceduralSkyMaterial.GroundBottomColor.

GroundEnergyMultiplierProperty
# GroundEnergyMultiplier
C#
public float GroundEnergyMultiplier { get; set; }

Multiplier for ground color. A higher value will make the ground brighter.

GroundHorizonColorProperty
# GroundHorizonColor
C#
public Color GroundHorizonColor { get; set; }

Color of the ground at the horizon. Blends with ProceduralSkyMaterial.GroundBottomColor.

SkyCoverProperty
# SkyCover
C#
public Texture2D SkyCover { get; set; }

The sky cover texture to use. This texture must use an equirectangular projection (similar to PanoramaSkyMaterial). The texture's colors will be added to the existing sky color, and will be multiplied by ProceduralSkyMaterial.SkyEnergyMultiplier and ProceduralSkyMaterial.SkyCoverModulate. This is mainly suited to displaying stars at night, but it can also be used to display clouds at day or night (with a non-physically-accurate look).

SkyCoverModulateProperty
# SkyCoverModulate
C#
public Color SkyCoverModulate { get; set; }

The tint to apply to the ProceduralSkyMaterial.SkyCover texture. This can be used to change the sky cover's colors or opacity independently of the sky energy, which is useful for day/night or weather transitions. Only effective if a texture is defined in ProceduralSkyMaterial.SkyCover.

SkyCurveProperty
# SkyCurve
C#
public float SkyCurve { get; set; }

How quickly the ProceduralSkyMaterial.SkyHorizonColor fades into the ProceduralSkyMaterial.SkyTopColor.

SkyEnergyMultiplierProperty
# SkyEnergyMultiplier
C#
public float SkyEnergyMultiplier { get; set; }

Multiplier for sky color. A higher value will make the sky brighter.

SkyHorizonColorProperty
# SkyHorizonColor
C#
public Color SkyHorizonColor { get; set; }

Color of the sky at the horizon. Blends with ProceduralSkyMaterial.SkyTopColor.

SkyTopColorProperty
# SkyTopColor
C#
public Color SkyTopColor { get; set; }

Color of the sky at the top. Blends with ProceduralSkyMaterial.SkyHorizonColor.

SunAngleMaxProperty
# SunAngleMax
C#
public float SunAngleMax { get; set; }

Distance from center of sun where it fades out completely.

SunCurveProperty
# SunCurve
C#
public float SunCurve { get; set; }

How quickly the sun fades away between the edge of the sun disk and ProceduralSkyMaterial.SunAngleMax.

UseDebandingProperty
# UseDebanding
C#
public bool UseDebanding { get; set; }

If true, enables debanding. Debanding adds a small amount of noise which helps reduce banding that appears from the smooth changes in color in the sky.

Methods28

GetEnergyMultiplierfloat
# GetEnergyMultiplier
C#
public float GetEnergyMultiplier();
Returns float
GetGroundBottomColorColor
# GetGroundBottomColor
C#
public Color GetGroundBottomColor();
Returns Color
GetGroundCurvefloat
# GetGroundCurve
C#
public float GetGroundCurve();
Returns float
GetGroundEnergyMultiplierfloat
# GetGroundEnergyMultiplier
C#
public float GetGroundEnergyMultiplier();
Returns float
GetGroundHorizonColorColor
# GetGroundHorizonColor
C#
public Color GetGroundHorizonColor();
Returns Color
GetSkyCoverTexture2D
# GetSkyCover
C#
public Texture2D GetSkyCover();
Returns Texture2D
GetSkyCoverModulateColor
# GetSkyCoverModulate
C#
public Color GetSkyCoverModulate();
Returns Color
GetSkyCurvefloat
# GetSkyCurve
C#
public float GetSkyCurve();
Returns float
GetSkyEnergyMultiplierfloat
# GetSkyEnergyMultiplier
C#
public float GetSkyEnergyMultiplier();
Returns float
GetSkyHorizonColorColor
# GetSkyHorizonColor
C#
public Color GetSkyHorizonColor();
Returns Color
GetSkyTopColorColor
# GetSkyTopColor
C#
public Color GetSkyTopColor();
Returns Color
GetSunAngleMaxfloat
# GetSunAngleMax
C#
public float GetSunAngleMax();
Returns float
GetSunCurvefloat
# GetSunCurve
C#
public float GetSunCurve();
Returns float
GetUseDebandingbool
# GetUseDebanding
C#
public bool GetUseDebanding();
Returns bool
SetEnergyMultipliervoid
# SetEnergyMultiplier
C#
public void SetEnergyMultiplier(float multiplier);
Parameters
NameTypeDefault
multiplierfloat—
SetGroundBottomColorvoid
# SetGroundBottomColor
C#
public void SetGroundBottomColor(Color color);
Parameters
NameTypeDefault
colorColor—
SetGroundCurvevoid
# SetGroundCurve
C#
public void SetGroundCurve(float curve);
Parameters
NameTypeDefault
curvefloat—
SetGroundEnergyMultipliervoid
# SetGroundEnergyMultiplier
C#
public void SetGroundEnergyMultiplier(float energy);
Parameters
NameTypeDefault
energyfloat—
SetGroundHorizonColorvoid
# SetGroundHorizonColor
C#
public void SetGroundHorizonColor(Color color);
Parameters
NameTypeDefault
colorColor—
SetSkyCovervoid
# SetSkyCover
C#
public void SetSkyCover(Texture2D skyCover);
Parameters
NameTypeDefault
skyCoverTexture2D—
SetSkyCoverModulatevoid
# SetSkyCoverModulate
C#
public void SetSkyCoverModulate(Color color);
Parameters
NameTypeDefault
colorColor—
SetSkyCurvevoid
# SetSkyCurve
C#
public void SetSkyCurve(float curve);
Parameters
NameTypeDefault
curvefloat—
SetSkyEnergyMultipliervoid
# SetSkyEnergyMultiplier
C#
public void SetSkyEnergyMultiplier(float multiplier);
Parameters
NameTypeDefault
multiplierfloat—
SetSkyHorizonColorvoid
# SetSkyHorizonColor
C#
public void SetSkyHorizonColor(Color color);
Parameters
NameTypeDefault
colorColor—
SetSkyTopColorvoid
# SetSkyTopColor
C#
public void SetSkyTopColor(Color color);
Parameters
NameTypeDefault
colorColor—
SetSunAngleMaxvoid
# SetSunAngleMax
C#
public void SetSunAngleMax(float degrees);
Parameters
NameTypeDefault
degreesfloat—
SetSunCurvevoid
# SetSunCurve
C#
public void SetSunCurve(float curve);
Parameters
NameTypeDefault
curvefloat—
SetUseDebandingvoid
# SetUseDebanding
C#
public void SetUseDebanding(bool useDebanding);
Parameters
NameTypeDefault
useDebandingbool—
Reckfell Engine documentationBack to top ↑
QUICK LINKSGetting startedEntity hierarchyC# & .NET 10Scenes and prefabs
Reckfell guides and full API K
reckfellENGINE
RECKFELL ACCOUNT

Sign in

Sign in to your Reckfell account.

One account for the entire Reckfell platform.