pex-renderer
Version:
Physically Based Renderer (PBR) and scene graph designed as ECS for PEX: define entities to be rendered as collections of components with their update orchestrated by systems.
16 lines (15 loc) • 344 B
JavaScript
/**
* Directional light component
* @param {import("../types.js").DirectionalLightComponentOptions} [options]
* @returns {object}
* @alias module:components.directionalLight
*/
export default (options) => ({
color: [1, 1, 1, 1],
intensity: 1,
bias: 0.1,
bulbRadius: 1,
castShadows: true,
shadowMapSize: 2048,
...options,
});