Partilhar via


Class PointLightComponent

A light source that emits light uniformly into all directions.

Point lights are used for local lights such as light bulbs.

class Microsoft::Azure::RemoteRendering::PointLightComponent final : public Microsoft::Azure::RemoteRendering::LightComponentBase

Properties

AttenuationCutoff

Custom interval of min/max distances over which the light's attenuated intensity is scaled down to zero.

This option can be used to enforce a smaller range of influence. By default these values are implicitly derived from the light's intensity. Use this option if you want to create a light source that should be bright, but with a relatively small area of influence.

A Result.InvalidParam error occurs if the value is negative, NaN or infinite.

auto GetAttenuationCutoff() const noexcept -> Microsoft::Azure::RemoteRendering::Float2;
auto SetAttenuationCutoff(Microsoft::Azure::RemoteRendering::Float2 const& value) noexcept -> Microsoft::Azure::RemoteRendering::Status;

Length

The length of the light emitting shape.

A Result.InvalidParam error occurs if the value is negative, NaN or infinite.

auto GetLength() const noexcept -> float;
auto SetLength(float value) noexcept -> Microsoft::Azure::RemoteRendering::Status;

See also

ProjectedCubeMap

Optional cubemap Texture to be projected onto surrounding geometry.

The orientation of the owner Entity determines how the cubemap is projected onto surrounding geometry. The color from the cubemap is used to modulate the light's color.

A Result.InvalidType error occurs if a texture is set that is not a cubemap.

auto GetProjectedCubeMap() const noexcept -> ApiHandle<Microsoft::Azure::RemoteRendering::Texture>;
auto SetProjectedCubeMap(ApiHandle<Microsoft::Azure::RemoteRendering::Texture> const& value) noexcept -> Microsoft::Azure::RemoteRendering::Status;

Radius

The radius of the light emitting shape.

By default the radius is zero and the emitting shape is just a point. If the radius is set to a larger value, the shape becomes a sphere or even a tube, if PointLightComponent.Length is also set.

A non-zero radius yields more realistic lighting for light bulbs and other objects that have a glowing surface. However, for performance reasons the computation is only an approximation of an area light. If such a light source comes too close to geometry or even intersects with it, the resulting lighting won't be physically correct.

A Result.InvalidParam error occurs if the value is negative, NaN or infinite.

auto GetRadius() const noexcept -> float;
auto SetRadius(float value) noexcept -> Microsoft::Azure::RemoteRendering::Status;

See also