defineRectLight#
Fully qualified name: usdex::core::defineRectLight
- pxr::UsdLuxRectLight usdex::core::defineRectLight(
- pxr::UsdPrim prim,
- float width,
- float height,
- float intensity = 1.0f,
- std::optional<std::string_view> texturePath = std::nullopt,
Creates a rectangular (rect) light with an optional texture.
This is an overloaded member function, provided for convenience. It differs from the above function only in what arguments it accepts.
- Parameters:
prim – Prim to define the rectangular light on. The prim’s type will be set to
UsdLuxRectLight.width – The width of the rectangular light, in the local X axis.
height – The height of the rectangular light, in the local Y axis.
intensity – The intensity value of the rectangular light.
texturePath – The path to the texture file to use on the rectangular light.
- Returns:
The light if created successfully.