feat(extensions): add ColumnShapeExtension for per-instance bevel shapes#10003
Open
charlieforward9 wants to merge 1 commit intovisgl:masterfrom
Open
feat(extensions): add ColumnShapeExtension for per-instance bevel shapes#10003charlieforward9 wants to merge 1 commit intovisgl:masterfrom
charlieforward9 wants to merge 1 commit intovisgl:masterfrom
Conversation
…pes and radius scaling
Adds a new LayerExtension that enables per-instance dome, cone, and custom
bevel shapes on ColumnLayer columns, with per-instance radius multipliers.
Features:
- getBevel accessor: 'flat' | 'dome' | 'cone' | {segs, height, bulge}
- getRadius accessor: per-instance radius multiplier
- Dome geometry with smooth normals via spherical coordinates
- Bulge effect for convex/concave dome surfaces
- Shader-based vertex transformation for correct elevation/lighting
Use cases: tree canopy visualization, architectural columns, styled 3D bar charts.
Includes documentation, type exports, and unit tests.
Contributor
Author
|
@chrisgervang @felixpalmer I cannot add reviewers so tagging for visibility. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Closes #9942
Adds a new
ColumnShapeExtensionto@deck.gl/extensionsthat enables per-instance dome, cone, and custom bevel shapes onColumnLayer, with per-instance radius multipliers.This is a non-invasive LayerExtension approach — it does not modify ColumnLayer internals. Instead it:
DECKGL_FILTER_SIZE,#main-end) for GPU-side vertex transformationgetGeometryto swap in dome-enabled geometry with concentric bevel rings and smooth normalsinstanceBevelSegs,instanceBevelHeights,instanceBevelBulge,instanceRadii)Features
getBevelaccessor:'flat'|'dome'|'cone'|{segs, height, bulge}per instancegetRadiusaccessor: per-instance radius multiplierUse cases
Example
Prior art
getBevel&getRadius#9933 (getBevel & getRadius proposal)Test plan
test/modules/extensions/column-shape.spec.ts)docs/api-reference/extensions/column-shape-extension.md)@deck.gl/extensionsindex with type exports🤖 Generated with Claude Code