Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
2 changes: 2 additions & 0 deletions AGENTS.md
Original file line number Diff line number Diff line change
Expand Up @@ -37,6 +37,8 @@
- TypeScript strict mode
- We end lines with semicolons
- Single quotes
- First-party source files with `SPDX-License-Identifier` must also declare each actual copyright holder using `SPDX-FileCopyrightText`.
- Preserve existing license expressions and upstream attribution; do not infer MIT licensing or ownership for generated, vendored, or third-party files.
- Never abbreviate variables, always type out the full name in camelCase (variables, functions, fields), PascalCase (types), CAPITAL_CASE (constant)
- Prefer verbNoun structure for function and method names.
- Keep shipped runtime validation minimal to protect bundle size. Prefer static typing and simple assertions over heavy validation or verbose runtime error paths.
Expand Down
14 changes: 12 additions & 2 deletions docs/api-reference/shadertools/shader-modules/pbr-material.md
Original file line number Diff line number Diff line change
Expand Up @@ -22,9 +22,19 @@ details on how grouped bindings are declared and supplied.

- [Real Shading in Unreal Engine 4](http://blog.selfshadow.com/publications/s2013-shading-course/karis/s2013_pbs_epic_notes_v2.pdf)
- [Physically Based Shading at Disney](http://blog.selfshadow.com/publications/s2012-shading-course/burley/s2012_pbs_disney_brdf_notes_v3.pdf)
- [README.md - Environment Maps](https://github.com/KhronosGroup/glTF-WebGL-PBR/#environment-maps)
- [README.md - Environment Maps](https://github.com/KhronosGroup/glTF-Sample-Viewer/blob/88eda8c5358efe03128b72b6c5f5f6e5b6d023e1/README.md#environment-maps)
- ["An Inexpensive BRDF Model for Physically based Rendering" by Christophe Schlick](https://www.cs.virginia.edu/~jdl/bib/appearance/analytic%20models/schlick94b.pdf)

## Attribution

This implementation of PBR (Physically-Based Rendering) is a fork of the [Khronos Reference Implementation](https://github.com/KhronosGroup/glTF-WebGL-PBR) under the Apache 2.0 license.
The GLSL and WGSL material shaders derive from the historical
[Khronos glTF-WebGL-PBR reference shader](https://github.com/KhronosGroup/glTF-Sample-Viewer/blob/88eda8c5358efe03128b72b6c5f5f6e5b6d023e1/shaders/pbr-frag.glsl).
The version incorporated into luma.gl was distributed under the
[MIT License](https://github.com/KhronosGroup/glTF-Sample-Viewer/blob/88eda8c5358efe03128b72b6c5f5f6e5b6d023e1/LICENSE.md)
with `Copyright (c) 2016-2017 Mohamad Moneimne and Contributors`. Both shaders preserve that
upstream copyright alongside the vis.gl contributors' additions and remain MIT-licensed.

The upstream project has since been renamed
[glTF Sample Viewer](https://github.com/KhronosGroup/glTF-Sample-Viewer), and its current releases
use the [Apache License 2.0](https://github.com/KhronosGroup/glTF-Sample-Viewer/blob/main/LICENSE.md).
That later license does not replace the MIT terms attached to the historical version used here.
2 changes: 1 addition & 1 deletion examples/api/blending/app.ts
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
// luma.gl
// SPDX-License-Identifier: MIT
// Copyright (c) vis.gl contributors
// SPDX-FileCopyrightText: Copyright (c) vis.gl contributors

import {
Texture,
Expand Down
2 changes: 1 addition & 1 deletion examples/api/cubemap/app.ts
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
// luma.gl
// SPDX-License-Identifier: MIT
// Copyright (c) vis.gl contributors
// SPDX-FileCopyrightText: Copyright (c) vis.gl contributors

import {NumberArray3, NumberArray16} from '@math.gl/types';
import {Device} from '@luma.gl/core';
Expand Down
2 changes: 1 addition & 1 deletion examples/api/cubemap/cubemap-cube.ts
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
// luma.gl
// SPDX-License-Identifier: MIT
// Copyright...
// SPDX-FileCopyrightText: Copyright (c) vis.gl contributors

import {Model, type ModelProps, DynamicTexture, CubeGeometry, ShaderInputs} from '@luma.gl/engine';
import type {Device, Texture} from '@luma.gl/core';
Expand Down
2 changes: 1 addition & 1 deletion examples/api/multi-canvas/app.tsx
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
// luma.gl
// SPDX-License-Identifier: MIT
// Copyright (c) vis.gl contributors
// SPDX-FileCopyrightText: Copyright (c) vis.gl contributors

import React from 'react';
import {createRoot, type Root} from 'react-dom/client';
Expand Down
2 changes: 1 addition & 1 deletion examples/api/render-bundles/app.ts
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
// luma.gl
// SPDX-License-Identifier: MIT
// Copyright (c) vis.gl contributors
// SPDX-FileCopyrightText: Copyright (c) vis.gl contributors

import type {Bindings, BindingsByGroup, RenderBundle, RenderPass} from '@luma.gl/core';
import {Buffer, Device, normalizeBindingsByGroup} from '@luma.gl/core';
Expand Down
2 changes: 1 addition & 1 deletion examples/api/texture-compressed/app.ts
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
// luma.gl
// SPDX-License-Identifier: MIT
// Copyright (c) vis.gl contributors
// SPDX-FileCopyrightText: Copyright (c) vis.gl contributors

import type {
Device,
Expand Down
2 changes: 1 addition & 1 deletion examples/api/texture-sampling/app.ts
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
// luma.gl
// SPDX-License-Identifier: MIT
// Copyright (c) vis.gl contributors
// SPDX-FileCopyrightText: Copyright (c) vis.gl contributors

import {
Texture,
Expand Down
2 changes: 1 addition & 1 deletion examples/api/texture-tester/app.tsx
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
// luma.gl
// SPDX-License-Identifier: MIT
// Copyright (c) vis.gl contributors
// SPDX-FileCopyrightText: Copyright (c) vis.gl contributors

import React from 'react';
import {createRoot, type Root} from 'react-dom/client';
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
// luma.gl
// SPDX-License-Identifier: MIT
// Copyright (c) vis.gl contributors
// SPDX-FileCopyrightText: Copyright (c) vis.gl contributors

import * as React from 'react';

Expand Down
2 changes: 1 addition & 1 deletion examples/api/texture-tester/textures-data.ts
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
// loaders.gl
// SPDX-License-Identifier: MIT
// Copyright (c) vis.gl contributors
// SPDX-FileCopyrightText: Copyright (c) vis.gl contributors

export type TextureFormatsInfo = {
formatName: string;
Expand Down
2 changes: 1 addition & 1 deletion examples/api/video-texture/app.ts
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
// luma.gl
// SPDX-License-Identifier: MIT
// Copyright (c) vis.gl contributors
// SPDX-FileCopyrightText: Copyright (c) vis.gl contributors

import type {ExternalTexture, NumberArray, VariableShaderType} from '@luma.gl/core';
import {Texture, UniformStore} from '@luma.gl/core';
Expand Down
2 changes: 1 addition & 1 deletion examples/arrow/arrow-columns/app.ts
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
// luma.gl
// SPDX-License-Identifier: MIT
// Copyright (c) vis.gl contributors
// SPDX-FileCopyrightText: Copyright (c) vis.gl contributors

import {type Device, type Framebuffer, Texture} from '@luma.gl/core';
import type {AnimationProps} from '@luma.gl/engine';
Expand Down
2 changes: 1 addition & 1 deletion examples/arrow/arrow-columns/arrow-column-data-source.ts
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
// luma.gl
// SPDX-License-Identifier: MIT
// Copyright (c) vis.gl contributors
// SPDX-FileCopyrightText: Copyright (c) vis.gl contributors

import {loadArrowColumnSourceData, type ArrowColumnSourceData} from './arrow-column-data';
import {formatArrowColumnRendererMetrics} from './arrow-column-metrics';
Expand Down
2 changes: 1 addition & 1 deletion examples/arrow/arrow-columns/arrow-column-data.ts
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
// luma.gl
// SPDX-License-Identifier: MIT
// Copyright (c) vis.gl contributors
// SPDX-FileCopyrightText: Copyright (c) vis.gl contributors

import {packDggsH3CellKey} from '@luma.gl/arrow';
import * as arrow from 'apache-arrow';
Expand Down
2 changes: 1 addition & 1 deletion examples/arrow/arrow-columns/arrow-column-metrics.ts
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
// luma.gl
// SPDX-License-Identifier: MIT
// Copyright (c) vis.gl contributors
// SPDX-FileCopyrightText: Copyright (c) vis.gl contributors

import type {ArrowColumnRendererMetrics} from './arrow-column-renderer';

Expand Down
2 changes: 1 addition & 1 deletion examples/arrow/arrow-columns/arrow-column-renderer.ts
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
// luma.gl
// SPDX-License-Identifier: MIT
// Copyright (c) vis.gl contributors
// SPDX-FileCopyrightText: Copyright (c) vis.gl contributors

import {
getRequiredArrowGPUVectorDataType,
Expand Down
2 changes: 1 addition & 1 deletion examples/arrow/arrow-columns/column-renderer-geometry.ts
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
// luma.gl
// SPDX-License-Identifier: MIT
// Copyright (c) vis.gl contributors
// SPDX-FileCopyrightText: Copyright (c) vis.gl contributors

import {makeGPUVectorFromArrow} from '@luma.gl/arrow';
import {Buffer, type Binding, type Device, type ShaderLayout} from '@luma.gl/core';
Expand Down
2 changes: 1 addition & 1 deletion examples/arrow/arrow-columns/column-renderer-shaders.ts
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
// luma.gl
// SPDX-License-Identifier: MIT
// Copyright (c) vis.gl contributors
// SPDX-FileCopyrightText: Copyright (c) vis.gl contributors

import {type ShaderLayout} from '@luma.gl/core';
import {type ShaderModule} from '@luma.gl/shadertools';
Expand Down
2 changes: 1 addition & 1 deletion examples/arrow/arrow-columns/control-panel.ts
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
// luma.gl
// SPDX-License-Identifier: MIT
// Copyright (c) vis.gl contributors
// SPDX-FileCopyrightText: Copyright (c) vis.gl contributors

import type {Panel, SettingsChangeDescriptor, SettingsSchema} from '@deck.gl-community/panels';
import {
Expand Down
2 changes: 1 addition & 1 deletion examples/arrow/arrow-dggs-polygons/app.ts
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
// luma.gl
// SPDX-License-Identifier: MIT
// Copyright (c) vis.gl contributors
// SPDX-FileCopyrightText: Copyright (c) vis.gl contributors

import type {AnimationProps} from '@luma.gl/engine';
import {ArrowDggsPolygonDataSourceController} from './arrow-dggs-polygon-data-source';
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
// luma.gl
// SPDX-License-Identifier: MIT
// Copyright (c) vis.gl contributors
// SPDX-FileCopyrightText: Copyright (c) vis.gl contributors

import type {DggsCellEncoding} from '@luma.gl/arrow';
import type {Device} from '@luma.gl/core';
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
// luma.gl
// SPDX-License-Identifier: MIT
// Copyright (c) vis.gl contributors
// SPDX-FileCopyrightText: Copyright (c) vis.gl contributors

import type {ArrowDggsPolygonRendererMetrics} from './arrow-dggs-polygon-renderer';
import type {ArrowDggsPolygonsControlPanelMetrics} from './control-panel';
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
// luma.gl
// SPDX-License-Identifier: MIT
// Copyright (c) vis.gl contributors
// SPDX-FileCopyrightText: Copyright (c) vis.gl contributors

import {
packDggsA5CellKey,
Expand Down
2 changes: 1 addition & 1 deletion examples/arrow/arrow-dggs-polygons/control-panel.ts
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
// luma.gl
// SPDX-License-Identifier: MIT
// Copyright (c) vis.gl contributors
// SPDX-FileCopyrightText: Copyright (c) vis.gl contributors

import type {DggsCellEncoding} from '@luma.gl/arrow';
import {
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
// luma.gl
// SPDX-License-Identifier: MIT
// Copyright (c) vis.gl contributors
// SPDX-FileCopyrightText: Copyright (c) vis.gl contributors

import type {ShaderModule} from '@luma.gl/shadertools';

Expand Down
2 changes: 1 addition & 1 deletion examples/arrow/arrow-dggs-polygons/dggs-polygon-model.ts
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
// luma.gl
// SPDX-License-Identifier: MIT
// Copyright (c) vis.gl contributors
// SPDX-FileCopyrightText: Copyright (c) vis.gl contributors

import type {PreparedDggsCellPathGPUVector} from '@luma.gl/arrow';
import type {Device} from '@luma.gl/core';
Expand Down
2 changes: 1 addition & 1 deletion examples/arrow/arrow-example-input.ts
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
// luma.gl
// SPDX-License-Identifier: MIT
// Copyright (c) vis.gl contributors
// SPDX-FileCopyrightText: Copyright (c) vis.gl contributors

/** Arrow source shapes demonstrated by both luma.gl and deck.gl examples. */
export type ArrowExampleInputMode = 'stream' | 'table' | 'vectors';
Expand Down
2 changes: 1 addition & 1 deletion examples/arrow/arrow-example-panels.ts
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
// luma.gl
// SPDX-License-Identifier: MIT
// Copyright (c) vis.gl contributors
// SPDX-FileCopyrightText: Copyright (c) vis.gl contributors

import {
ArrowBatchesPanel,
Expand Down
2 changes: 1 addition & 1 deletion examples/arrow/arrow-filtering/app.ts
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
// luma.gl
// SPDX-License-Identifier: MIT
// Copyright (c) vis.gl contributors
// SPDX-FileCopyrightText: Copyright (c) vis.gl contributors

import type {AnimationProps} from '@luma.gl/engine';
import {AnimationLoopTemplate} from '@luma.gl/engine';
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
// luma.gl
// SPDX-License-Identifier: MIT
// Copyright (c) vis.gl contributors
// SPDX-FileCopyrightText: Copyright (c) vis.gl contributors

import {makeArrowFilteringTable, type ArrowFilteringTable} from './arrow-filtering-data';
import {ArrowFilteringControlPanel, type ArrowFilteringControlState} from './control-panel';
Expand Down
2 changes: 1 addition & 1 deletion examples/arrow/arrow-filtering/arrow-filtering-data.ts
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
// luma.gl
// SPDX-License-Identifier: MIT
// Copyright (c) vis.gl contributors
// SPDX-FileCopyrightText: Copyright (c) vis.gl contributors

import {makeArrowFixedSizeListVector} from '@luma.gl/arrow';
import * as arrow from 'apache-arrow';
Expand Down
2 changes: 1 addition & 1 deletion examples/arrow/arrow-filtering/arrow-filtering-renderer.ts
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
// luma.gl
// SPDX-License-Identifier: MIT
// Copyright (c) vis.gl contributors
// SPDX-FileCopyrightText: Copyright (c) vis.gl contributors

import {makeGPUTableFromArrowTable} from '@luma.gl/arrow';
import type {Device, RenderPass, ShaderLayout} from '@luma.gl/core';
Expand Down
2 changes: 1 addition & 1 deletion examples/arrow/arrow-filtering/control-panel.ts
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
// luma.gl
// SPDX-License-Identifier: MIT
// Copyright (c) vis.gl contributors
// SPDX-FileCopyrightText: Copyright (c) vis.gl contributors

import type {Panel, SettingsChangeDescriptor, SettingsSchema} from '@deck.gl-community/panels';
import {
Expand Down
2 changes: 1 addition & 1 deletion examples/arrow/arrow-float64-precision/app.ts
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
// luma.gl
// SPDX-License-Identifier: MIT
// Copyright (c) vis.gl contributors
// SPDX-FileCopyrightText: Copyright (c) vis.gl contributors

import type {Device} from '@luma.gl/core';
import type {AnimationProps} from '@luma.gl/engine';
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
// luma.gl
// SPDX-License-Identifier: MIT
// Copyright (c) vis.gl contributors
// SPDX-FileCopyrightText: Copyright (c) vis.gl contributors

import {
makeArrowFloat64PrecisionSourceData,
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
// luma.gl
// SPDX-License-Identifier: MIT
// Copyright (c) vis.gl contributors
// SPDX-FileCopyrightText: Copyright (c) vis.gl contributors

import {getArrowVectorByteLength, makeArrowFixedSizeListVector} from '@luma.gl/arrow';
import * as arrow from 'apache-arrow';
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
// luma.gl
// SPDX-License-Identifier: MIT
// Copyright (c) vis.gl contributors
// SPDX-FileCopyrightText: Copyright (c) vis.gl contributors

import {
ArrowPathRenderer,
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
// luma.gl
// SPDX-License-Identifier: MIT
// Copyright (c) vis.gl contributors
// SPDX-FileCopyrightText: Copyright (c) vis.gl contributors

import type {ShaderLayout} from '@luma.gl/core';
import {ShaderInputs} from '@luma.gl/engine';
Expand Down
2 changes: 1 addition & 1 deletion examples/arrow/arrow-float64-precision/control-panel.ts
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
// luma.gl
// SPDX-License-Identifier: MIT
// Copyright (c) vis.gl contributors
// SPDX-FileCopyrightText: Copyright (c) vis.gl contributors

import {
type Panel,
Expand Down
2 changes: 1 addition & 1 deletion examples/arrow/arrow-geoarrow/app.ts
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
// luma.gl
// SPDX-License-Identifier: MIT
// Copyright (c) vis.gl contributors
// SPDX-FileCopyrightText: Copyright (c) vis.gl contributors

import type {Device} from '@luma.gl/core';
import type {AnimationProps} from '@luma.gl/engine';
Expand Down
2 changes: 1 addition & 1 deletion examples/arrow/arrow-geoarrow/control-panel.ts
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
// luma.gl
// SPDX-License-Identifier: MIT
// Copyright (c) vis.gl contributors
// SPDX-FileCopyrightText: Copyright (c) vis.gl contributors

import type {Panel} from '@deck.gl-community/panels';
import {makeHtmlCustomPanel} from '../../example-panels';
Expand Down
2 changes: 1 addition & 1 deletion examples/arrow/arrow-geoarrow/geoarrow-data-source.ts
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
// luma.gl
// SPDX-License-Identifier: MIT
// Copyright (c) vis.gl contributors
// SPDX-FileCopyrightText: Copyright (c) vis.gl contributors

import {makeGeoArrowExampleData, type GeoArrowExampleData} from './geoarrow-data';
import type {GeoArrowRenderer} from './geoarrow-renderer';
Expand Down
2 changes: 1 addition & 1 deletion examples/arrow/arrow-geoarrow/geoarrow-data.ts
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
// luma.gl
// SPDX-License-Identifier: MIT
// Copyright (c) vis.gl contributors
// SPDX-FileCopyrightText: Copyright (c) vis.gl contributors

import {getArrowVectorByteLength, makeArrowFixedSizeListVector} from '@luma.gl/arrow';
import * as arrow from 'apache-arrow';
Expand Down
2 changes: 1 addition & 1 deletion examples/arrow/arrow-geoarrow/geoarrow-renderer.ts
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
// luma.gl
// SPDX-License-Identifier: MIT
// Copyright (c) vis.gl contributors
// SPDX-FileCopyrightText: Copyright (c) vis.gl contributors

import * as arrow from 'apache-arrow';
import type {CommandEncoder, Device, RenderPass} from '@luma.gl/core';
Expand Down
2 changes: 1 addition & 1 deletion examples/arrow/arrow-instancing/app.ts
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
// luma.gl
// SPDX-License-Identifier: MIT
// Copyright (c) vis.gl contributors
// SPDX-FileCopyrightText: Copyright (c) vis.gl contributors

import type {AnimationProps} from '@luma.gl/engine';
import {ArrowInstancingDataSourceController} from './arrow-instancing-data-source';
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
// luma.gl
// SPDX-License-Identifier: MIT
// Copyright (c) vis.gl contributors
// SPDX-FileCopyrightText: Copyright (c) vis.gl contributors

import {
createArrowPickingManager,
Expand Down
Loading
Loading