Voronoi computation now doesn't freeze the UI. Sundry bugfixes and library upgrades.#101
Merged
Merged
Conversation
MapLibre v5 changed render() from two parameters (gl, matrix) to a
single destructured object ({ gl, modelViewProjectionMatrix }). The
previous fix incorrectly kept two parameters.
https://claude.ai/code/session_013SyD3xCEEcuzNN69ghKo3z
MapLibre v5 render() takes (gl, args) as two separate parameters, not a single destructured object. The matrix is accessed via args.modelViewProjectionMatrix with fallback to args.defaultProjectionData.mainMatrix. https://claude.ai/code/session_013SyD3xCEEcuzNN69ghKo3z
Temporary diagnostics to identify why gradient rendering fails: - Log shader compilation errors (vertex, fragment, program link) - Log render() args keys and matrix properties on first call https://claude.ai/code/session_013SyD3xCEEcuzNN69ghKo3z
…32Array MapLibre GL v5 provides modelViewProjectionMatrix as Float64Array, but WebGL's uniformMatrix4fv requires Float32Array. Also removes debug logging. https://claude.ai/code/session_013SyD3xCEEcuzNN69ghKo3z
MapLibre v5 custom layers need explicit renderingMode: '2d' and gl.disable(gl.DEPTH_TEST) to render correctly over the map. https://claude.ai/code/session_013SyD3xCEEcuzNN69ghKo3z
The official MapLibre v5 custom layer example uses args.defaultProjectionData.mainMatrix, not args.modelViewProjectionMatrix. https://claude.ai/code/session_013SyD3xCEEcuzNN69ghKo3z
Two optimizations to speed up Voronoi recomputation when adjusting the coalesce slider: 1. Use turf.booleanWithin() to detect cells fully inside the boundary and skip the expensive turf.intersect() call (~90% of cells). 2. Replace string-heavy edge key generation (toFixed + join + sort) with pre-quantized integer comparison for faster deduplication. https://claude.ai/code/session_013SyD3xCEEcuzNN69ghKo3z
The coalesce slider was blocking the main thread during expensive turf.intersect operations. Now the full pipeline (coalescing + Delaunay + boundary clipping) runs in a dedicated Web Worker. Uses request IDs to discard stale results when the slider moves faster than computation completes. https://claude.ai/code/session_013SyD3xCEEcuzNN69ghKo3z
Keep async worker-based Voronoi computation from feature branch. Incorporate renderWebGL error handling from main. Drop debug logging that was added on main for troubleshooting. https://claude.ai/code/session_013SyD3xCEEcuzNN69ghKo3z
🚀 Preview Deployment Ready!Preview URL: https://liotier.github.io/Geogizmos/preview/claude-remove-unused-variable-NCvPC/Isosmfar/ Branch: This preview will update automatically with each push to this branch. |
- Remove unused coalescedFeatures destructuring from worker callback - Collapse identical branches (LineString/Point/else all continue) - Use .at(-1) instead of [.length - 1] - Log error in catch instead of swallowing silently https://claude.ai/code/session_013SyD3xCEEcuzNN69ghKo3z
|
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.


No description provided.