Documentation
¶
Overview ¶
Package OmniLight3D provides methods for working with OmniLight3D object instances.
Index ¶
- type Advanced
- type Any
- type Extension
- func (self *Extension[T]) AsLight3D() Light3D.Instance
- func (self *Extension[T]) AsNode() Node.Instance
- func (self *Extension[T]) AsNode3D() Node3D.Instance
- func (self *Extension[T]) AsObject() [1]gd.Object
- func (self *Extension[T]) AsOmniLight3D() Instance
- func (self *Extension[T]) AsVisualInstance3D() VisualInstance3D.Instance
- type ID
- type Instance
- func (self Instance) AsLight3D() Light3D.Instance
- func (self Instance) AsNode() Node.Instance
- func (self Instance) AsNode3D() Node3D.Instance
- func (self Instance) AsObject() [1]gd.Object
- func (self Instance) AsOmniLight3D() Instance
- func (self Instance) AsVisualInstance3D() VisualInstance3D.Instance
- func (self Instance) ID() ID
- func (self Instance) OmniShadowMode() ShadowMode
- func (self *Instance) SetObject(obj [1]gd.Object) bool
- func (self Instance) SetOmniShadowMode(value ShadowMode)
- func (self *Instance) UnsafePointer() unsafe.Pointer
- func (self Instance) Virtual(name string) reflect.Value
- type ShadowMode
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Advanced ¶
type Advanced = class
Advanced exposes a 1:1 low-level instance of the class, undocumented, for those who know what they are doing.
type Extension ¶
Extension can be embedded in a new struct to create an extension of this class. T should be the type that is embedding this Extension
func (*Extension[T]) AsOmniLight3D ¶
func (*Extension[T]) AsVisualInstance3D ¶
func (self *Extension[T]) AsVisualInstance3D() VisualInstance3D.Instance
type ID ¶
ID is a typed object ID (reference) to an instance of this class, use it to store references to objects with unknown lifetimes, as an ID will not panic on use if the underlying object has been destroyed.
type Instance ¶
type Instance [1]gdclass.OmniLight3D
An Omnidirectional light is a type of [Light3D] that emits light in all directions. The light is attenuated by distance and this attenuation can be configured by changing its energy, radius, and attenuation parameters. [b]Note:[/b] When using the Mobile rendering method, only 8 omni lights can be displayed on each mesh resource. Attempting to display more than 8 omni lights on a single mesh resource will result in omni lights flickering in and out as the camera moves. When using the Compatibility rendering method, only 8 omni lights can be displayed on each mesh resource by default, but this can be increased by adjusting [member ProjectSettings.rendering/limits/opengl/max_lights_per_object]. [b]Note:[/b] When using the Mobile or Compatibility rendering methods, omni lights will only correctly affect meshes whose visibility AABB intersects with the light's AABB. If using a shader to deform the mesh in a way that makes it go outside its AABB, [member GeometryInstance3D.extra_cull_margin] must be increased on the mesh. Otherwise, the light may not be visible on the mesh.
var Nil Instance
Nil is a nil/null instance of the class. Equivalent to the zero value.
func (Instance) AsOmniLight3D ¶
func (Instance) AsVisualInstance3D ¶
func (self Instance) AsVisualInstance3D() VisualInstance3D.Instance
func (Instance) OmniShadowMode ¶
func (self Instance) OmniShadowMode() ShadowMode
func (Instance) SetOmniShadowMode ¶
func (self Instance) SetOmniShadowMode(value ShadowMode)
func (*Instance) UnsafePointer ¶
type ShadowMode ¶
type ShadowMode int //gd:OmniLight3D.ShadowMode
const ( /*Shadows are rendered to a dual-paraboloid texture. Faster than [constant SHADOW_CUBE], but lower-quality.*/ ShadowDualParaboloid ShadowMode = 0 /*Shadows are rendered to a cubemap. Slower than [constant SHADOW_DUAL_PARABOLOID], but higher-quality.*/ ShadowCube ShadowMode = 1 )