@luma.gl/graph 10.0.0-alpha.8 → 10.0.0-beta.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (493) hide show
  1. package/LICENSE +4 -4
  2. package/THIRD-PARTY-NOTICES.md +19 -0
  3. package/dist/arrow/arrow-colors.cjs +99 -18
  4. package/dist/arrow/arrow-colors.d.ts +27 -10
  5. package/dist/arrow/arrow-colors.d.ts.map +1 -1
  6. package/dist/arrow/arrow-colors.js +107 -24
  7. package/dist/arrow/arrow-colors.js.map +1 -1
  8. package/dist/arrow/arrow-utils/arrow-paths.cjs +4 -3
  9. package/dist/arrow/arrow-utils/arrow-paths.d.ts.map +1 -1
  10. package/dist/arrow/arrow-utils/arrow-paths.js +5 -4
  11. package/dist/arrow/arrow-utils/arrow-paths.js.map +1 -1
  12. package/dist/arrow/cpu/arrow-coordinate-projection.cjs +30 -0
  13. package/dist/arrow/cpu/arrow-coordinate-projection.d.ts +5 -0
  14. package/dist/arrow/cpu/arrow-coordinate-projection.d.ts.map +1 -0
  15. package/dist/arrow/cpu/arrow-coordinate-projection.js +9 -0
  16. package/dist/arrow/cpu/arrow-coordinate-projection.js.map +1 -0
  17. package/dist/arrow/cpu/arrow-cpu-pipelines.cjs +31 -0
  18. package/dist/arrow/cpu/arrow-cpu-pipelines.d.ts +2 -0
  19. package/dist/arrow/cpu/arrow-cpu-pipelines.d.ts.map +1 -0
  20. package/dist/arrow/cpu/arrow-cpu-pipelines.js +5 -0
  21. package/dist/arrow/cpu/arrow-cpu-pipelines.js.map +1 -0
  22. package/dist/arrow/cpu/arrow-cpu-vector-adapters.cjs +99 -0
  23. package/dist/arrow/cpu/arrow-cpu-vector-adapters.d.ts +9 -0
  24. package/dist/arrow/cpu/arrow-cpu-vector-adapters.d.ts.map +1 -0
  25. package/dist/arrow/cpu/arrow-cpu-vector-adapters.js +100 -0
  26. package/dist/arrow/cpu/arrow-cpu-vector-adapters.js.map +1 -0
  27. package/dist/arrow/geoarrow/arrow-geoarrow-adapter.cjs +9 -371
  28. package/dist/arrow/geoarrow/arrow-geoarrow-adapter.d.ts +8 -28
  29. package/dist/arrow/geoarrow/arrow-geoarrow-adapter.d.ts.map +1 -1
  30. package/dist/arrow/geoarrow/arrow-geoarrow-adapter.js +4 -381
  31. package/dist/arrow/geoarrow/arrow-geoarrow-adapter.js.map +1 -1
  32. package/dist/arrow/geoarrow/arrow-geoarrow-conversion.cjs +11 -11
  33. package/dist/arrow/geoarrow/arrow-geoarrow-conversion.d.ts +2 -0
  34. package/dist/arrow/geoarrow/arrow-geoarrow-conversion.d.ts.map +1 -1
  35. package/dist/arrow/geoarrow/arrow-geoarrow-conversion.js +4 -4
  36. package/dist/arrow/geoarrow/arrow-geoarrow-conversion.js.map +1 -1
  37. package/dist/arrow/geoarrow/arrow-polygon-tessellation.cjs +2 -2
  38. package/dist/arrow/geoarrow/arrow-polygon-tessellation.js +1 -1
  39. package/dist/arrow/geoarrow/arrow-polygon-tessellation.js.map +1 -1
  40. package/dist/arrow/gpu/arrow-column-gpu-vector.cjs +27 -8
  41. package/dist/arrow/gpu/arrow-column-gpu-vector.d.ts +11 -1
  42. package/dist/arrow/gpu/arrow-column-gpu-vector.d.ts.map +1 -1
  43. package/dist/arrow/gpu/arrow-column-gpu-vector.js +33 -8
  44. package/dist/arrow/gpu/arrow-column-gpu-vector.js.map +1 -1
  45. package/dist/arrow/gpu/arrow-gpu-table-conversion.cjs +68 -3
  46. package/dist/arrow/gpu/arrow-gpu-table-conversion.d.ts +9 -2
  47. package/dist/arrow/gpu/arrow-gpu-table-conversion.d.ts.map +1 -1
  48. package/dist/arrow/gpu/arrow-gpu-table-conversion.js +76 -3
  49. package/dist/arrow/gpu/arrow-gpu-table-conversion.js.map +1 -1
  50. package/dist/arrow/gpu/arrow-gpu-vector-adapters.cjs +8 -6
  51. package/dist/arrow/gpu/arrow-gpu-vector-adapters.d.ts +1 -0
  52. package/dist/arrow/gpu/arrow-gpu-vector-adapters.d.ts.map +1 -1
  53. package/dist/arrow/gpu/arrow-gpu-vector-adapters.js +17 -7
  54. package/dist/arrow/gpu/arrow-gpu-vector-adapters.js.map +1 -1
  55. package/dist/arrow/gpu/arrow-gpu-vector-conversion.cjs +35 -5
  56. package/dist/arrow/gpu/arrow-gpu-vector-conversion.d.ts +6 -1
  57. package/dist/arrow/gpu/arrow-gpu-vector-conversion.d.ts.map +1 -1
  58. package/dist/arrow/gpu/arrow-gpu-vector-conversion.js +40 -5
  59. package/dist/arrow/gpu/arrow-gpu-vector-conversion.js.map +1 -1
  60. package/dist/arrow/index.cjs +19 -2
  61. package/dist/arrow/index.cjs.map +3 -3
  62. package/dist/arrow/index.d.ts +5 -2
  63. package/dist/arrow/index.d.ts.map +1 -1
  64. package/dist/arrow/index.js +4 -1
  65. package/dist/arrow/index.js.map +1 -1
  66. package/dist/arrow/internal.cjs.map +2 -2
  67. package/dist/dist.dev.js +3820 -1646
  68. package/dist/dist.min.js +450 -136
  69. package/dist/experimental/index.cjs.map +1 -1
  70. package/dist/experimental/simulation/index.cjs.map +1 -1
  71. package/dist/geospatial/gpu-point-spatial-query.cjs +2 -15
  72. package/dist/geospatial/gpu-point-spatial-query.d.ts.map +1 -1
  73. package/dist/geospatial/gpu-point-spatial-query.js +2 -15
  74. package/dist/geospatial/gpu-point-spatial-query.js.map +1 -1
  75. package/dist/geospatial/index.cjs.map +2 -2
  76. package/dist/gpu-a5/index.cjs.map +1 -1
  77. package/dist/gpu-core/compiled-gpu-graph.cjs +47 -0
  78. package/dist/gpu-core/compiled-gpu-graph.d.ts +5 -0
  79. package/dist/gpu-core/compiled-gpu-graph.d.ts.map +1 -1
  80. package/dist/gpu-core/compiled-gpu-graph.js +54 -1
  81. package/dist/gpu-core/compiled-gpu-graph.js.map +1 -1
  82. package/dist/gpu-core/gpu-command-graph-compiler.cjs +11 -2
  83. package/dist/gpu-core/gpu-command-graph-compiler.d.ts +2 -1
  84. package/dist/gpu-core/gpu-command-graph-compiler.d.ts.map +1 -1
  85. package/dist/gpu-core/gpu-command-graph-compiler.js +13 -2
  86. package/dist/gpu-core/gpu-command-graph-compiler.js.map +1 -1
  87. package/dist/gpu-core/gpu-command-graph-types.d.ts +16 -1
  88. package/dist/gpu-core/gpu-command-graph-types.d.ts.map +1 -1
  89. package/dist/gpu-core/gpu-command-graph-types.js.map +1 -1
  90. package/dist/gpu-core/gpu-command-graph.cjs +34 -11
  91. package/dist/gpu-core/gpu-command-graph.d.ts +17 -8
  92. package/dist/gpu-core/gpu-command-graph.d.ts.map +1 -1
  93. package/dist/gpu-core/gpu-command-graph.js +39 -11
  94. package/dist/gpu-core/gpu-command-graph.js.map +1 -1
  95. package/dist/gpu-core/gpu-cpu-execution.cjs +279 -0
  96. package/dist/gpu-core/gpu-cpu-execution.d.ts +22 -0
  97. package/dist/gpu-core/gpu-cpu-execution.d.ts.map +1 -0
  98. package/dist/gpu-core/gpu-cpu-execution.js +294 -0
  99. package/dist/gpu-core/gpu-cpu-execution.js.map +1 -0
  100. package/dist/gpu-core/gpu-cpu-operation.cjs +54 -0
  101. package/dist/gpu-core/gpu-cpu-operation.d.ts +40 -0
  102. package/dist/gpu-core/gpu-cpu-operation.d.ts.map +1 -0
  103. package/dist/gpu-core/gpu-cpu-operation.js +35 -0
  104. package/dist/gpu-core/gpu-cpu-operation.js.map +1 -0
  105. package/dist/gpu-core/gpu-dispatch-utils.cjs +7 -3
  106. package/dist/gpu-core/gpu-dispatch-utils.d.ts +2 -0
  107. package/dist/gpu-core/gpu-dispatch-utils.d.ts.map +1 -1
  108. package/dist/gpu-core/gpu-dispatch-utils.js +4 -1
  109. package/dist/gpu-core/gpu-dispatch-utils.js.map +1 -1
  110. package/dist/gpu-core/gpu-expression-operation.cjs +2 -2
  111. package/dist/gpu-core/gpu-expression-operation.d.ts +1 -1
  112. package/dist/gpu-core/gpu-expression-operation.d.ts.map +1 -1
  113. package/dist/gpu-core/gpu-expression-operation.js +1 -1
  114. package/dist/gpu-core/gpu-expression-operation.js.map +1 -1
  115. package/dist/gpu-core/gpu-expression-plan.cjs +5 -1
  116. package/dist/gpu-core/gpu-expression-plan.d.ts +3 -2
  117. package/dist/gpu-core/gpu-expression-plan.d.ts.map +1 -1
  118. package/dist/gpu-core/gpu-expression-plan.js +7 -1
  119. package/dist/gpu-core/gpu-expression-plan.js.map +1 -1
  120. package/dist/gpu-core/gpu-graph-compiler.cjs +48 -0
  121. package/dist/gpu-core/gpu-graph-compiler.d.ts +1 -0
  122. package/dist/gpu-core/gpu-graph-compiler.d.ts.map +1 -1
  123. package/dist/gpu-core/gpu-graph-compiler.js +50 -0
  124. package/dist/gpu-core/gpu-graph-compiler.js.map +1 -1
  125. package/dist/gpu-core/gpu-graph.d.ts +2 -2
  126. package/dist/gpu-core/gpu-graph.d.ts.map +1 -1
  127. package/dist/gpu-core/gpu-graph.js.map +1 -1
  128. package/dist/gpu-core/gpu-grid-aggregation.cjs +2 -5
  129. package/dist/gpu-core/gpu-grid-aggregation.d.ts.map +1 -1
  130. package/dist/gpu-core/gpu-grid-aggregation.js +2 -5
  131. package/dist/gpu-core/gpu-grid-aggregation.js.map +1 -1
  132. package/dist/gpu-core/gpu-grid-binning.cjs +2 -5
  133. package/dist/gpu-core/gpu-grid-binning.d.ts.map +1 -1
  134. package/dist/gpu-core/gpu-grid-binning.js +2 -5
  135. package/dist/gpu-core/gpu-grid-binning.js.map +1 -1
  136. package/dist/gpu-core/gpu-grid-coordinate.cjs +41 -0
  137. package/dist/gpu-core/gpu-grid-coordinate.d.ts +7 -0
  138. package/dist/gpu-core/gpu-grid-coordinate.d.ts.map +1 -0
  139. package/dist/gpu-core/gpu-grid-coordinate.js +24 -0
  140. package/dist/gpu-core/gpu-grid-coordinate.js.map +1 -0
  141. package/dist/gpu-core/gpu-grid-index-internals.cjs +2 -15
  142. package/dist/gpu-core/gpu-grid-index-internals.d.ts.map +1 -1
  143. package/dist/gpu-core/gpu-grid-index-internals.js +2 -15
  144. package/dist/gpu-core/gpu-grid-index-internals.js.map +1 -1
  145. package/dist/gpu-core/gpu-grid-index-query.cjs +2 -16
  146. package/dist/gpu-core/gpu-grid-index-query.d.ts.map +1 -1
  147. package/dist/gpu-core/gpu-grid-index-query.js +2 -16
  148. package/dist/gpu-core/gpu-grid-index-query.js.map +1 -1
  149. package/dist/gpu-core/gpu-group-aggregation.cjs +7 -15
  150. package/dist/gpu-core/gpu-group-aggregation.d.ts.map +1 -1
  151. package/dist/gpu-core/gpu-group-aggregation.js +7 -18
  152. package/dist/gpu-core/gpu-group-aggregation.js.map +1 -1
  153. package/dist/gpu-core/gpu-operation.d.ts +4 -4
  154. package/dist/gpu-core/gpu-operation.d.ts.map +1 -1
  155. package/dist/gpu-core/gpu-operation.js.map +1 -1
  156. package/dist/gpu-core/gpu-reduction.cjs +6 -14
  157. package/dist/gpu-core/gpu-reduction.d.ts.map +1 -1
  158. package/dist/gpu-core/gpu-reduction.js +6 -15
  159. package/dist/gpu-core/gpu-reduction.js.map +1 -1
  160. package/dist/gpu-core/gpu-render-operation.cjs +39 -0
  161. package/dist/gpu-core/gpu-render-operation.d.ts +21 -0
  162. package/dist/gpu-core/gpu-render-operation.d.ts.map +1 -0
  163. package/dist/gpu-core/gpu-render-operation.js +22 -0
  164. package/dist/gpu-core/gpu-render-operation.js.map +1 -0
  165. package/dist/gpu-core/gpu-scan.cjs +46 -32
  166. package/dist/gpu-core/gpu-scan.d.ts.map +1 -1
  167. package/dist/gpu-core/gpu-scan.js +56 -44
  168. package/dist/gpu-core/gpu-scan.js.map +1 -1
  169. package/dist/gpu-core/gpu-segmented-reduction.cjs +12 -9
  170. package/dist/gpu-core/gpu-segmented-reduction.d.ts +1 -1
  171. package/dist/gpu-core/gpu-segmented-reduction.d.ts.map +1 -1
  172. package/dist/gpu-core/gpu-segmented-reduction.js +12 -9
  173. package/dist/gpu-core/gpu-segmented-reduction.js.map +1 -1
  174. package/dist/gpu-core/gpu-segmented-scan.cjs +73 -16
  175. package/dist/gpu-core/gpu-segmented-scan.d.ts.map +1 -1
  176. package/dist/gpu-core/gpu-segmented-scan.js +73 -16
  177. package/dist/gpu-core/gpu-segmented-scan.js.map +1 -1
  178. package/dist/gpu-core/gpu-semantic-aggregation-operation.cjs +112 -0
  179. package/dist/gpu-core/gpu-semantic-aggregation-operation.d.ts +71 -0
  180. package/dist/gpu-core/gpu-semantic-aggregation-operation.d.ts.map +1 -0
  181. package/dist/gpu-core/gpu-semantic-aggregation-operation.js +92 -0
  182. package/dist/gpu-core/gpu-semantic-aggregation-operation.js.map +1 -0
  183. package/dist/gpu-core/gpu-shader-pass-kernel.cjs +267 -0
  184. package/dist/gpu-core/gpu-shader-pass-kernel.d.ts +29 -0
  185. package/dist/gpu-core/gpu-shader-pass-kernel.d.ts.map +1 -0
  186. package/dist/gpu-core/gpu-shader-pass-kernel.js +260 -0
  187. package/dist/gpu-core/gpu-shader-pass-kernel.js.map +1 -0
  188. package/dist/gpu-core/gpu-shader-pass-operation.cjs +85 -0
  189. package/dist/gpu-core/gpu-shader-pass-operation.d.ts +32 -0
  190. package/dist/gpu-core/gpu-shader-pass-operation.d.ts.map +1 -0
  191. package/dist/gpu-core/gpu-shader-pass-operation.js +74 -0
  192. package/dist/gpu-core/gpu-shader-pass-operation.js.map +1 -0
  193. package/dist/gpu-core/gpu-texture-plan.d.ts +3 -2
  194. package/dist/gpu-core/gpu-texture-plan.d.ts.map +1 -1
  195. package/dist/gpu-core/gpu-texture-plan.js.map +1 -1
  196. package/dist/gpu-core/index.cjs +32 -0
  197. package/dist/gpu-core/index.cjs.map +3 -3
  198. package/dist/gpu-core/index.d.ts +21 -1
  199. package/dist/gpu-core/index.d.ts.map +1 -1
  200. package/dist/gpu-core/index.js +10 -0
  201. package/dist/gpu-core/index.js.map +1 -1
  202. package/dist/gpu-data/color-conversion.cjs +105 -0
  203. package/dist/gpu-data/color-conversion.d.ts +30 -0
  204. package/dist/gpu-data/color-conversion.d.ts.map +1 -0
  205. package/dist/gpu-data/color-conversion.js +109 -0
  206. package/dist/gpu-data/color-conversion.js.map +1 -0
  207. package/dist/gpu-data/cpu-data.cjs +60 -0
  208. package/dist/gpu-data/cpu-data.d.ts +28 -0
  209. package/dist/gpu-data/cpu-data.d.ts.map +1 -0
  210. package/dist/gpu-data/cpu-data.js +41 -0
  211. package/dist/gpu-data/cpu-data.js.map +1 -0
  212. package/dist/gpu-data/cpu-gpu-vector-transfer.cjs +98 -0
  213. package/dist/gpu-data/cpu-gpu-vector-transfer.d.ts +9 -0
  214. package/dist/gpu-data/cpu-gpu-vector-transfer.d.ts.map +1 -0
  215. package/dist/gpu-data/cpu-gpu-vector-transfer.js +85 -0
  216. package/dist/gpu-data/cpu-gpu-vector-transfer.js.map +1 -0
  217. package/dist/gpu-data/cpu-vector.cjs +42 -0
  218. package/dist/gpu-data/cpu-vector.d.ts +17 -0
  219. package/dist/gpu-data/cpu-vector.d.ts.map +1 -0
  220. package/dist/gpu-data/cpu-vector.js +21 -0
  221. package/dist/gpu-data/cpu-vector.js.map +1 -0
  222. package/dist/gpu-data/gpu-data-buffer-props.cjs +41 -0
  223. package/dist/gpu-data/gpu-data-buffer-props.d.ts +5 -0
  224. package/dist/gpu-data/gpu-data-buffer-props.d.ts.map +1 -0
  225. package/dist/gpu-data/gpu-data-buffer-props.js +19 -0
  226. package/dist/gpu-data/gpu-data-buffer-props.js.map +1 -0
  227. package/dist/gpu-data/gpu-vector-wgsl-layout.cjs +50 -0
  228. package/dist/gpu-data/gpu-vector-wgsl-layout.d.ts +41 -0
  229. package/dist/gpu-data/gpu-vector-wgsl-layout.d.ts.map +1 -0
  230. package/dist/gpu-data/gpu-vector-wgsl-layout.js +45 -0
  231. package/dist/gpu-data/gpu-vector-wgsl-layout.js.map +1 -0
  232. package/dist/gpu-data/index.cjs +21 -2
  233. package/dist/gpu-data/index.cjs.map +3 -3
  234. package/dist/gpu-data/index.d.ts +6 -0
  235. package/dist/gpu-data/index.d.ts.map +1 -1
  236. package/dist/gpu-data/index.js +5 -0
  237. package/dist/gpu-data/index.js.map +1 -1
  238. package/dist/gpu-dataframe/gpu-data-frame-query.cjs +1 -16
  239. package/dist/gpu-dataframe/gpu-data-frame-query.d.ts.map +1 -1
  240. package/dist/gpu-dataframe/gpu-data-frame-query.js +1 -23
  241. package/dist/gpu-dataframe/gpu-data-frame-query.js.map +1 -1
  242. package/dist/gpu-dataframe/gpu-expression.cjs +91 -2
  243. package/dist/gpu-dataframe/gpu-expression.d.ts +37 -0
  244. package/dist/gpu-dataframe/gpu-expression.d.ts.map +1 -1
  245. package/dist/gpu-dataframe/gpu-expression.js +106 -0
  246. package/dist/gpu-dataframe/gpu-expression.js.map +1 -1
  247. package/dist/gpu-dataframe/index.cjs +12 -2
  248. package/dist/gpu-dataframe/index.cjs.map +3 -3
  249. package/dist/gpu-dataframe/index.d.ts +4 -0
  250. package/dist/gpu-dataframe/index.d.ts.map +1 -1
  251. package/dist/gpu-dataframe/index.js +2 -0
  252. package/dist/gpu-dataframe/index.js.map +1 -1
  253. package/dist/gpu-dataframe/portable-expression.cjs +103 -0
  254. package/dist/gpu-dataframe/portable-expression.d.ts +19 -0
  255. package/dist/gpu-dataframe/portable-expression.d.ts.map +1 -0
  256. package/dist/gpu-dataframe/portable-expression.js +98 -0
  257. package/dist/gpu-dataframe/portable-expression.js.map +1 -0
  258. package/dist/gpu-dggs/benchmarks.cjs.map +1 -1
  259. package/dist/gpu-dggs/index.cjs.map +1 -1
  260. package/dist/gpu-geometry/index.cjs.map +1 -1
  261. package/dist/gpu-graph/index.cjs +8 -0
  262. package/dist/gpu-graph/index.cjs.map +3 -3
  263. package/dist/gpu-graph/index.d.ts +4 -0
  264. package/dist/gpu-graph/index.d.ts.map +1 -1
  265. package/dist/gpu-graph/index.js +2 -0
  266. package/dist/gpu-graph/index.js.map +1 -1
  267. package/dist/gpu-graph-algorithms/benchmarks.cjs.map +2 -2
  268. package/dist/gpu-graph-algorithms/gpu-graph-spatial-force-layout-internals.cjs +2 -15
  269. package/dist/gpu-graph-algorithms/gpu-graph-spatial-force-layout-internals.d.ts.map +1 -1
  270. package/dist/gpu-graph-algorithms/gpu-graph-spatial-force-layout-internals.js +2 -15
  271. package/dist/gpu-graph-algorithms/gpu-graph-spatial-force-layout-internals.js.map +1 -1
  272. package/dist/gpu-graph-algorithms/index.cjs.map +2 -2
  273. package/dist/gpu-h3/index.cjs.map +1 -1
  274. package/dist/gpu-physics/gpu-rigid-body-world.cjs +162 -2
  275. package/dist/gpu-physics/gpu-rigid-body-world.d.ts +25 -0
  276. package/dist/gpu-physics/gpu-rigid-body-world.d.ts.map +1 -1
  277. package/dist/gpu-physics/gpu-rigid-body-world.js +181 -2
  278. package/dist/gpu-physics/gpu-rigid-body-world.js.map +1 -1
  279. package/dist/gpu-physics/index.cjs.map +2 -2
  280. package/dist/gpu-physics/index.d.ts +1 -0
  281. package/dist/gpu-physics/index.d.ts.map +1 -1
  282. package/dist/gpu-physics/rigid-body-parallel-shaders.cjs +24 -9
  283. package/dist/gpu-physics/rigid-body-parallel-shaders.d.ts +1 -1
  284. package/dist/gpu-physics/rigid-body-parallel-shaders.d.ts.map +1 -1
  285. package/dist/gpu-physics/rigid-body-parallel-shaders.js +28 -9
  286. package/dist/gpu-physics/rigid-body-parallel-shaders.js.map +1 -1
  287. package/dist/gpu-physics/rigid-body-shaders.cjs +2 -2
  288. package/dist/gpu-physics/rigid-body-shaders.d.ts +1 -1
  289. package/dist/gpu-physics/rigid-body-shaders.d.ts.map +1 -1
  290. package/dist/gpu-physics/rigid-body-shaders.js +2 -2
  291. package/dist/gpu-physics/rigid-body-shaders.js.map +1 -1
  292. package/dist/gpu-physics/rigid-body-vehicle.cjs +90 -0
  293. package/dist/gpu-physics/rigid-body-vehicle.d.ts +35 -0
  294. package/dist/gpu-physics/rigid-body-vehicle.d.ts.map +1 -0
  295. package/dist/gpu-physics/rigid-body-vehicle.js +66 -0
  296. package/dist/gpu-physics/rigid-body-vehicle.js.map +1 -0
  297. package/dist/gpu-pointcloud/index.cjs.map +1 -1
  298. package/dist/gpu-project/benchmarks.cjs.map +2 -2
  299. package/dist/gpu-project/coordinate-projection-graph.cjs +59 -0
  300. package/dist/gpu-project/coordinate-projection-graph.d.ts +23 -0
  301. package/dist/gpu-project/coordinate-projection-graph.d.ts.map +1 -0
  302. package/dist/gpu-project/coordinate-projection-graph.js +40 -0
  303. package/dist/gpu-project/coordinate-projection-graph.js.map +1 -0
  304. package/dist/gpu-project/cpu-geoarrow.cjs +112 -0
  305. package/dist/gpu-project/cpu-geoarrow.d.ts +10 -0
  306. package/dist/gpu-project/cpu-geoarrow.d.ts.map +1 -0
  307. package/dist/gpu-project/cpu-geoarrow.js +103 -0
  308. package/dist/gpu-project/cpu-geoarrow.js.map +1 -0
  309. package/dist/gpu-project/cpu-geometry-pipelines.cjs +134 -0
  310. package/dist/gpu-project/cpu-geometry-pipelines.d.ts +19 -0
  311. package/dist/gpu-project/cpu-geometry-pipelines.d.ts.map +1 -0
  312. package/dist/gpu-project/cpu-geometry-pipelines.js +114 -0
  313. package/dist/gpu-project/cpu-geometry-pipelines.js.map +1 -0
  314. package/dist/gpu-project/cpu-projection-operation.cjs +54 -0
  315. package/dist/gpu-project/cpu-projection-operation.d.ts +14 -0
  316. package/dist/gpu-project/cpu-projection-operation.d.ts.map +1 -0
  317. package/dist/gpu-project/cpu-projection-operation.js +37 -0
  318. package/dist/gpu-project/cpu-projection-operation.js.map +1 -0
  319. package/dist/gpu-project/crs.cjs.map +2 -2
  320. package/dist/gpu-project/geoarrow.cjs +36 -0
  321. package/dist/gpu-project/geoarrow.cjs.map +6 -0
  322. package/dist/gpu-project/geoarrow.d.ts +3 -0
  323. package/dist/gpu-project/geoarrow.d.ts.map +1 -0
  324. package/dist/gpu-project/geoarrow.js +7 -0
  325. package/dist/gpu-project/geoarrow.js.map +1 -0
  326. package/dist/gpu-project/graph.cjs +27 -0
  327. package/dist/gpu-project/graph.cjs.map +6 -0
  328. package/dist/gpu-project/graph.d.ts +2 -0
  329. package/dist/gpu-project/graph.d.ts.map +1 -0
  330. package/dist/gpu-project/graph.js +6 -0
  331. package/dist/gpu-project/graph.js.map +1 -0
  332. package/dist/gpu-project/index.cjs +3 -0
  333. package/dist/gpu-project/index.cjs.map +3 -3
  334. package/dist/gpu-project/index.d.ts +1 -0
  335. package/dist/gpu-project/index.d.ts.map +1 -1
  336. package/dist/gpu-project/index.js +1 -0
  337. package/dist/gpu-project/index.js.map +1 -1
  338. package/dist/gpu-simple-graph/compiled-gpu-expression-graph.cjs +75 -5
  339. package/dist/gpu-simple-graph/compiled-gpu-expression-graph.d.ts +5 -1
  340. package/dist/gpu-simple-graph/compiled-gpu-expression-graph.d.ts.map +1 -1
  341. package/dist/gpu-simple-graph/compiled-gpu-expression-graph.js +86 -6
  342. package/dist/gpu-simple-graph/compiled-gpu-expression-graph.js.map +1 -1
  343. package/dist/gpu-simple-graph/gpu-simple-graph-lowering.cjs +9 -0
  344. package/dist/gpu-simple-graph/gpu-simple-graph-lowering.d.ts +2 -0
  345. package/dist/gpu-simple-graph/gpu-simple-graph-lowering.d.ts.map +1 -1
  346. package/dist/gpu-simple-graph/gpu-simple-graph-lowering.js +10 -0
  347. package/dist/gpu-simple-graph/gpu-simple-graph-lowering.js.map +1 -1
  348. package/dist/gpu-simple-graph/gpu-simple-graph.cjs +126 -10
  349. package/dist/gpu-simple-graph/gpu-simple-graph.d.ts +36 -11
  350. package/dist/gpu-simple-graph/gpu-simple-graph.d.ts.map +1 -1
  351. package/dist/gpu-simple-graph/gpu-simple-graph.js +137 -12
  352. package/dist/gpu-simple-graph/gpu-simple-graph.js.map +1 -1
  353. package/dist/gpu-simple-graph/index.cjs.map +3 -3
  354. package/dist/gpu-simple-graph/index.d.ts +1 -1
  355. package/dist/gpu-simple-graph/index.d.ts.map +1 -1
  356. package/dist/gpu-simple-graph/index.js.map +1 -1
  357. package/dist/gpu-simple-graph/operation/gpu-data-evaluator.cjs +25 -0
  358. package/dist/gpu-simple-graph/operation/gpu-data-evaluator.d.ts +6 -0
  359. package/dist/gpu-simple-graph/operation/gpu-data-evaluator.d.ts.map +1 -1
  360. package/dist/gpu-simple-graph/operation/gpu-data-evaluator.js +28 -0
  361. package/dist/gpu-simple-graph/operation/gpu-data-evaluator.js.map +1 -1
  362. package/dist/gpu-simple-graph/operation/gpu-vector-evaluator.cjs +7 -0
  363. package/dist/gpu-simple-graph/operation/gpu-vector-evaluator.d.ts +2 -0
  364. package/dist/gpu-simple-graph/operation/gpu-vector-evaluator.d.ts.map +1 -1
  365. package/dist/gpu-simple-graph/operation/gpu-vector-evaluator.js +7 -0
  366. package/dist/gpu-simple-graph/operation/gpu-vector-evaluator.js.map +1 -1
  367. package/dist/gpu-simple-graph/operations/convert-colors.cjs +6 -6
  368. package/dist/gpu-simple-graph/operations/convert-colors.d.ts +5 -1
  369. package/dist/gpu-simple-graph/operations/convert-colors.d.ts.map +1 -1
  370. package/dist/gpu-simple-graph/operations/convert-colors.js +12 -7
  371. package/dist/gpu-simple-graph/operations/convert-colors.js.map +1 -1
  372. package/dist/gpu-simple-graph/operations/cpu/convert-colors.cjs +16 -33
  373. package/dist/gpu-simple-graph/operations/cpu/convert-colors.d.ts.map +1 -1
  374. package/dist/gpu-simple-graph/operations/cpu/convert-colors.js +22 -35
  375. package/dist/gpu-simple-graph/operations/cpu/convert-colors.js.map +1 -1
  376. package/dist/gpu-simple-graph/operations/cpu/index.cjs.map +3 -3
  377. package/dist/gpu-simple-graph/operations/webgl/index.cjs.map +3 -3
  378. package/dist/gpu-simple-graph/operations/webgpu/convert-colors.cjs +31 -13
  379. package/dist/gpu-simple-graph/operations/webgpu/convert-colors.d.ts.map +1 -1
  380. package/dist/gpu-simple-graph/operations/webgpu/convert-colors.js +42 -13
  381. package/dist/gpu-simple-graph/operations/webgpu/convert-colors.js.map +1 -1
  382. package/dist/gpu-simple-graph/operations/webgpu/index.cjs.map +1 -1
  383. package/dist/gpu-sql/gpu-sql.cjs +376 -0
  384. package/dist/gpu-sql/gpu-sql.d.ts +36 -0
  385. package/dist/gpu-sql/gpu-sql.d.ts.map +1 -0
  386. package/dist/gpu-sql/gpu-sql.js +374 -0
  387. package/dist/gpu-sql/gpu-sql.js.map +1 -0
  388. package/dist/gpu-sql/index.cjs +5 -5
  389. package/dist/gpu-sql/index.cjs.map +3 -3
  390. package/dist/gpu-sql/index.d.ts +2 -2
  391. package/dist/gpu-sql/index.d.ts.map +1 -1
  392. package/dist/gpu-sql/index.js +1 -1
  393. package/dist/gpu-sql/index.js.map +1 -1
  394. package/dist/gpu-tables/index.cjs.map +2 -2
  395. package/dist/gpu-tables/table/gpu-table.cjs +2 -2
  396. package/dist/gpu-tables/table/gpu-table.d.ts.map +1 -1
  397. package/dist/gpu-tables/table/gpu-table.js +2 -2
  398. package/dist/gpu-tables/table/gpu-table.js.map +1 -1
  399. package/dist/gpu-timeseries/index.cjs.map +1 -1
  400. package/dist/index.cjs +11 -0
  401. package/dist/index.cjs.map +3 -3
  402. package/dist/index.d.ts +7 -1
  403. package/dist/index.d.ts.map +1 -1
  404. package/dist/index.js +3 -0
  405. package/dist/index.js.map +1 -1
  406. package/package.json +21 -7
  407. package/src/arrow/arrow-colors.ts +194 -33
  408. package/src/arrow/arrow-utils/arrow-paths.ts +5 -3
  409. package/src/arrow/cpu/arrow-coordinate-projection.ts +18 -0
  410. package/src/arrow/cpu/arrow-cpu-pipelines.ts +9 -0
  411. package/src/arrow/cpu/arrow-cpu-vector-adapters.ts +153 -0
  412. package/src/arrow/geoarrow/arrow-geoarrow-adapter.ts +21 -493
  413. package/src/arrow/geoarrow/arrow-geoarrow-conversion.ts +7 -5
  414. package/src/arrow/geoarrow/arrow-polygon-tessellation.ts +1 -1
  415. package/src/arrow/gpu/arrow-column-gpu-vector.ts +67 -14
  416. package/src/arrow/gpu/arrow-gpu-table-conversion.ts +96 -4
  417. package/src/arrow/gpu/arrow-gpu-vector-adapters.ts +20 -7
  418. package/src/arrow/gpu/arrow-gpu-vector-conversion.ts +49 -6
  419. package/src/arrow/index.ts +14 -0
  420. package/src/geospatial/gpu-point-spatial-query.ts +2 -15
  421. package/src/gpu-core/compiled-gpu-graph.ts +73 -1
  422. package/src/gpu-core/gpu-command-graph-compiler.ts +25 -2
  423. package/src/gpu-core/gpu-command-graph-types.ts +20 -0
  424. package/src/gpu-core/gpu-command-graph.ts +48 -11
  425. package/src/gpu-core/gpu-cpu-execution.ts +345 -0
  426. package/src/gpu-core/gpu-cpu-operation.ts +65 -0
  427. package/src/gpu-core/gpu-dispatch-utils.ts +13 -1
  428. package/src/gpu-core/gpu-expression-operation.ts +1 -1
  429. package/src/gpu-core/gpu-expression-plan.ts +11 -3
  430. package/src/gpu-core/gpu-graph-compiler.ts +61 -0
  431. package/src/gpu-core/gpu-graph.ts +3 -3
  432. package/src/gpu-core/gpu-grid-aggregation.ts +2 -5
  433. package/src/gpu-core/gpu-grid-binning.ts +2 -5
  434. package/src/gpu-core/gpu-grid-coordinate.ts +24 -0
  435. package/src/gpu-core/gpu-grid-index-internals.ts +2 -15
  436. package/src/gpu-core/gpu-grid-index-query.ts +2 -16
  437. package/src/gpu-core/gpu-group-aggregation.ts +38 -50
  438. package/src/gpu-core/gpu-operation.ts +9 -7
  439. package/src/gpu-core/gpu-reduction.ts +32 -42
  440. package/src/gpu-core/gpu-render-operation.ts +42 -0
  441. package/src/gpu-core/gpu-scan.ts +59 -45
  442. package/src/gpu-core/gpu-segmented-reduction.ts +20 -10
  443. package/src/gpu-core/gpu-segmented-scan.ts +82 -17
  444. package/src/gpu-core/gpu-semantic-aggregation-operation.ts +150 -0
  445. package/src/gpu-core/gpu-shader-pass-kernel.ts +307 -0
  446. package/src/gpu-core/gpu-shader-pass-operation.ts +103 -0
  447. package/src/gpu-core/gpu-texture-plan.ts +3 -2
  448. package/src/gpu-core/index.ts +39 -0
  449. package/src/gpu-data/color-conversion.ts +158 -0
  450. package/src/gpu-data/cpu-data.ts +62 -0
  451. package/src/gpu-data/cpu-gpu-vector-transfer.ts +110 -0
  452. package/src/gpu-data/cpu-vector.ts +31 -0
  453. package/src/gpu-data/gpu-data-buffer-props.ts +25 -0
  454. package/src/gpu-data/gpu-vector-wgsl-layout.ts +79 -0
  455. package/src/gpu-data/index.ts +15 -0
  456. package/src/gpu-dataframe/gpu-data-frame-query.ts +6 -26
  457. package/src/gpu-dataframe/gpu-expression.ts +135 -0
  458. package/src/gpu-dataframe/index.ts +11 -0
  459. package/src/gpu-dataframe/portable-expression.ts +117 -0
  460. package/src/gpu-graph/index.ts +17 -0
  461. package/src/gpu-graph-algorithms/gpu-graph-spatial-force-layout-internals.ts +2 -15
  462. package/src/gpu-physics/gpu-rigid-body-world.ts +227 -2
  463. package/src/gpu-physics/index.ts +1 -0
  464. package/src/gpu-physics/rigid-body-parallel-shaders.ts +32 -9
  465. package/src/gpu-physics/rigid-body-shaders.ts +3 -2
  466. package/src/gpu-physics/rigid-body-vehicle.ts +99 -0
  467. package/src/gpu-project/README.md +4 -4
  468. package/src/gpu-project/coordinate-projection-graph.ts +59 -0
  469. package/src/gpu-project/cpu-geoarrow.ts +135 -0
  470. package/src/gpu-project/cpu-geometry-pipelines.ts +159 -0
  471. package/src/gpu-project/cpu-projection-operation.ts +49 -0
  472. package/src/gpu-project/geoarrow.ts +11 -0
  473. package/src/gpu-project/graph.ts +10 -0
  474. package/src/gpu-project/index.ts +2 -0
  475. package/src/gpu-simple-graph/compiled-gpu-expression-graph.ts +97 -6
  476. package/src/gpu-simple-graph/gpu-simple-graph-lowering.ts +11 -0
  477. package/src/gpu-simple-graph/gpu-simple-graph.ts +163 -19
  478. package/src/gpu-simple-graph/index.ts +1 -0
  479. package/src/gpu-simple-graph/operation/gpu-data-evaluator.ts +24 -0
  480. package/src/gpu-simple-graph/operation/gpu-vector-evaluator.ts +7 -0
  481. package/src/gpu-simple-graph/operations/convert-colors.ts +22 -7
  482. package/src/gpu-simple-graph/operations/cpu/convert-colors.ts +31 -48
  483. package/src/gpu-simple-graph/operations/webgpu/convert-colors.ts +47 -13
  484. package/src/gpu-sql/gpu-sql.ts +494 -0
  485. package/src/gpu-sql/index.ts +2 -2
  486. package/src/gpu-tables/table/gpu-table.ts +2 -1
  487. package/src/index.ts +21 -0
  488. package/dist/gpu-sql/lu-sql.cjs +0 -499
  489. package/dist/gpu-sql/lu-sql.d.ts +0 -36
  490. package/dist/gpu-sql/lu-sql.d.ts.map +0 -1
  491. package/dist/gpu-sql/lu-sql.js +0 -497
  492. package/dist/gpu-sql/lu-sql.js.map +0 -1
  493. package/src/gpu-sql/lu-sql.ts +0 -599
@@ -76,6 +76,8 @@ import {
76
76
  import {addRigidBodyPosePublication, type GPURigidBodyBounds} from './rigid-body-publication';
77
77
  import {getRigidBodyShader} from './rigid-body-shaders';
78
78
 
79
+ import {VEHICLE_SHADER, type GPURigidBodyVehicle} from './rigid-body-vehicle';
80
+
79
81
  type Vector3 = readonly [number, number, number];
80
82
  import {
81
83
  decodeRigidBodyContactEvents,
@@ -128,6 +130,8 @@ export type GPURigidBodyWorldProps = {
128
130
  /** Up to 64 joints. Parallel solving supports static-anchored distance joints only. */
129
131
  joints?: readonly GPURigidBodyJoint[];
130
132
  gravity?: Vector3;
133
+ /** Optional four-wheel suspension evaluated against static terrain each fixed step. */
134
+ vehicle?: GPURigidBodyVehicle;
131
135
  timeStep?: number;
132
136
  iterations?: number;
133
137
  contactSlop?: number;
@@ -139,6 +143,10 @@ export type GPURigidBodyWorldProps = {
139
143
  maximumRecoverySpeed?: number;
140
144
  /** Additional under-relaxation for the parallel solver, in (0, 1]. Default 1. */
141
145
  parallelRelaxation?: number;
146
+ /** Contact scheduling within a parallel manifold. Block uses two local sweeps before gathering.
147
+ * Default scalar preserves the original per-contact relaxation path.
148
+ */
149
+ parallelContactSolver?: 'scalar' | 'block';
142
150
  /** Small worlds retain the all-pairs numerical oracle; larger worlds use sparse discovery. */
143
151
  /** Independent equal collider blocks; currently excludes joints, CCD and authored triggers. */
144
152
  collisionPartitionSize?: number;
@@ -224,6 +232,7 @@ export class GPURigidBodyWorld {
224
232
  private eventRead: Promise<GPURigidBodyContactBatch> | null = null;
225
233
  private queryComputation: BoundKernel | null = null;
226
234
  private queryReduction: BoundKernel | null = null;
235
+ private vehicleBuffer: Buffer | null = null;
227
236
  private querySettings: Buffer | null = null;
228
237
  private querySelection: Buffer | null = null;
229
238
  private queryOutput: Buffer | null = null;
@@ -271,6 +280,8 @@ export class GPURigidBodyWorld {
271
280
  this.solver = props.solver ?? 'ordered';
272
281
  if (!['ordered', 'parallel'].includes(this.solver))
273
282
  throw new Error('Invalid rigid-body solver');
283
+ if (!['scalar', 'block'].includes(props.parallelContactSolver ?? 'scalar'))
284
+ throw new Error('Invalid parallel contact solver');
274
285
  validateRigidBodyJoints(props.joints ?? [], props.bodies, this.solver);
275
286
  const colliderCount = props.bodies.reduce(
276
287
  (sum, body) => sum + (body.colliders?.length ?? 1),
@@ -499,8 +510,35 @@ export class GPURigidBodyWorld {
499
510
  }
500
511
  // Clone together so collider edits preserve geometry identity in captured body definitions.
501
512
  const definitions = structuredClone({colliders, props});
502
- this.colliders = definitions.colliders;
503
513
  this.props = definitions.props;
514
+ this.colliders = definitions.colliders;
515
+ const vehicle = this.props.vehicle;
516
+ if (vehicle) {
517
+ const terrain = this.colliders[vehicle.terrainCollider];
518
+ const chassis = this.props.bodies[vehicle.chassis];
519
+ const ground = terrain && this.props.bodies[terrain.body];
520
+ if (
521
+ !chassis ||
522
+ !ground ||
523
+ vehicle.chassis === terrain.body ||
524
+ (chassis.mode ?? (chassis.mass === 0 ? 'static' : 'dynamic')) !== 'dynamic' ||
525
+ (ground.mode ?? (ground.mass === 0 ? 'static' : 'dynamic')) !== 'static' ||
526
+ vehicle.wheels.length !== 4 ||
527
+ this.props.failurePolicy === 'rollback' ||
528
+ this.props.ensembleBodiesPerInstance ||
529
+ ![vehicle.radius, vehicle.travel, vehicle.springRate, vehicle.wheelInertia].every(
530
+ value => Number.isFinite(value) && value > 0
531
+ ) ||
532
+ ![vehicle.damping, vehicle.grip, vehicle.motorTorque, vehicle.brakeTorque].every(
533
+ value => Number.isFinite(value) && value >= 0
534
+ ) ||
535
+ vehicle.wheels.some(
536
+ wheel => wheel.mount.length !== 3 || !wheel.mount.every(Number.isFinite)
537
+ )
538
+ )
539
+ throw new Error('Invalid vehicle configuration');
540
+ }
541
+
504
542
  if (props.ensembleBodiesPerInstance)
505
543
  this.initialEnsembleBodies = this.props.bodies.slice(0, props.ensembleBodiesPerInstance);
506
544
  }
@@ -535,6 +573,8 @@ export class GPURigidBodyWorld {
535
573
  this.props.ensembleBodiesPerInstance ? this.count / this.props.ensembleBodiesPerInstance : 0
536
574
  )
537
575
  };
576
+ if (this.props.vehicle)
577
+ storage.buffers.push({name: 'vehicle', byteLength: 512, uniform: false});
538
578
  if (this.props.continuous?.mode === 'convex') {
539
579
  storage.buffers = storage.buffers.filter(buffer => buffer.name !== 'continuous-previous');
540
580
  storage.buffers.push({name: 'continuous-dispatch', byteLength: 16, uniform: false});
@@ -1043,7 +1083,8 @@ export class GPURigidBodyWorld {
1043
1083
  this.props.joints?.length ?? 0,
1044
1084
  this.props.compactContacts ?? true,
1045
1085
  this.props.collisionPartitionSize,
1046
- this.props.ensembleBodiesPerInstance
1086
+ this.props.ensembleBodiesPerInstance,
1087
+ this.props.parallelContactSolver === 'block'
1047
1088
  );
1048
1089
  const parallelBindings: Record<string, readonly string[]> = {
1049
1090
  parallelReset: ['parallelState'],
@@ -1228,6 +1269,120 @@ export class GPURigidBodyWorld {
1228
1269
  parallelMarkSleep: 'Identify islands whose bodies are quiet enough to sleep.',
1229
1270
  parallelSleep: 'Put quiet constraint islands to sleep.'
1230
1271
  };
1272
+ const vehicle = this.props.vehicle;
1273
+ if (vehicle) {
1274
+ const data = new Float32Array(128);
1275
+ data.set(
1276
+ [
1277
+ vehicle.radius,
1278
+ vehicle.travel,
1279
+ vehicle.springRate,
1280
+ vehicle.damping,
1281
+ vehicle.grip,
1282
+ vehicle.motorTorque,
1283
+ vehicle.brakeTorque,
1284
+ vehicle.wheelInertia
1285
+ ],
1286
+ 4
1287
+ );
1288
+ new Uint32Array(data.buffer).set([vehicle.chassis, vehicle.terrainCollider], 12);
1289
+ vehicle.wheels.forEach((wheel, index) => {
1290
+ const offset = 16 + index * 12;
1291
+ data.set(wheel.mount, offset);
1292
+ data.set([Number(Boolean(wheel.steer)), Number(Boolean(wheel.drive))], offset + 4);
1293
+ data[offset + 10] = vehicle.travel;
1294
+ data.set(
1295
+ [
1296
+ 1,
1297
+ 0,
1298
+ 0,
1299
+ 0,
1300
+ 0,
1301
+ 1,
1302
+ 0,
1303
+ 0,
1304
+ 0,
1305
+ 0,
1306
+ 1,
1307
+ 0,
1308
+ wheel.mount[0],
1309
+ wheel.mount[1],
1310
+ wheel.mount[2] - vehicle.travel,
1311
+ 1
1312
+ ],
1313
+ 64 + 16 * index
1314
+ );
1315
+ });
1316
+ this.vehicleBuffer = allocate('vehicle', data);
1317
+ const vehicleBindings = [
1318
+ ...bindings.filter(binding =>
1319
+ [
1320
+ 'settings',
1321
+ 'positions',
1322
+ 'orientations',
1323
+ 'velocities',
1324
+ 'angularVelocities',
1325
+ 'bodies',
1326
+ 'sleepStates'
1327
+ ].includes(binding.name)
1328
+ ),
1329
+ {
1330
+ name: 'vehicle',
1331
+ location: 12,
1332
+ buffer: this.vehicleBuffer,
1333
+ resource: graph.importBuffer(
1334
+ {id: this.id + '-vehicle', byteLength: data.byteLength, usage: Buffer.STORAGE},
1335
+ this.vehicleBuffer
1336
+ )
1337
+ }
1338
+ ];
1339
+ const properties: BoundKernelProps = {
1340
+ id: this.id + '-suspension',
1341
+ source: source + RIGID_BODY_QUERY_GEOMETRY_SHADER + VEHICLE_SHADER,
1342
+ entryPoint: 'advanceVehicle',
1343
+ shaderLayout: {
1344
+ bindings: vehicleBindings.map(
1345
+ ({name, location}): BindingDeclaration =>
1346
+ name === 'settings'
1347
+ ? {name, location, group: 0, type: 'uniform'}
1348
+ : {
1349
+ name,
1350
+ location,
1351
+ group: 0,
1352
+ type: name === 'bodies' ? 'read-only-storage' : 'storage'
1353
+ }
1354
+ )
1355
+ }
1356
+ };
1357
+ const executable = (
1358
+ computation: BoundKernel
1359
+ ): GPUCommandGraphComputeExecutable<Parameters> => ({
1360
+ encode: ({computePass, getBuffer}) => {
1361
+ Object.assign(
1362
+ computation.bindings,
1363
+ Object.fromEntries(
1364
+ vehicleBindings.map(binding => [binding.name, getBuffer(binding.resource)])
1365
+ )
1366
+ );
1367
+ computation.kernel.dispatch(computePass, {bindings: computation.bindings, x: 1});
1368
+ },
1369
+ destroy: () => computation.kernel.destroy()
1370
+ });
1371
+ graph.addComputePass({
1372
+ id: properties.id!,
1373
+ resources: vehicleBindings.map(binding => ({
1374
+ buffer: binding.resource,
1375
+ usage:
1376
+ binding.name === 'settings'
1377
+ ? 'uniform'
1378
+ : binding.name === 'bodies'
1379
+ ? 'storage-read'
1380
+ : 'storage-read-write'
1381
+ })),
1382
+ compile: () => executable(createBoundKernel(graph.device, properties)),
1383
+ compileAsync: async () => executable(await createBoundKernelAsync(graph.device, properties))
1384
+ });
1385
+ }
1231
1386
  for (const entryPoint of [
1232
1387
  ...(this.ensembleBuffer
1233
1388
  ? ['ensembleClear', 'ensembleMark', 'ensembleCompact', 'ensembleDispatch']
@@ -1981,6 +2136,76 @@ struct Command { impulse: vec4f, point: vec4f, orientation: vec4f, bodyIndex: ve
1981
2136
  : undefined;
1982
2137
  }
1983
2138
 
2139
+ /** Set signed throttle, steering angle in radians and brake fraction for upcoming substeps. */
2140
+ setVehicleControls(throttle: number, steering: number, brake: number): void {
2141
+ if (
2142
+ !this.vehicleBuffer ||
2143
+ this.destroyed ||
2144
+ ![throttle, steering, brake].every(Number.isFinite)
2145
+ )
2146
+ throw new Error('Invalid vehicle controls');
2147
+ this.vehicleBuffer.write(
2148
+ new Float32Array([
2149
+ Math.max(-1, Math.min(1, throttle)),
2150
+ steering,
2151
+ Math.max(0, Math.min(1, brake)),
2152
+ 0
2153
+ ])
2154
+ );
2155
+ }
2156
+
2157
+ /** Borrow four column-major wheel transforms relative to the chassis node, ordered by mount. */
2158
+ get vehicleWheelPoses() {
2159
+ return this.vehicleBuffer && !this.destroyed
2160
+ ? {buffer: this.vehicleBuffer, byteOffset: 256, byteLength: 256}
2161
+ : null;
2162
+ }
2163
+
2164
+ /** Transfer wheel motion between rebuilt worlds for wheels with matching chassis-local mounts. */
2165
+ copyVehicleMotionFrom(previous: GPURigidBodyWorld): void {
2166
+ const sourceBuffer = previous.vehicleBuffer;
2167
+ const destinationBuffer = this.vehicleBuffer;
2168
+ const previousVehicle = previous.props.vehicle;
2169
+ if (!this.device || !sourceBuffer || !destinationBuffer || !previousVehicle) return;
2170
+ const encoder = this.device.createCommandEncoder();
2171
+ this.props.vehicle?.wheels.forEach((wheel, index) => {
2172
+ const sourceIndex = previousVehicle.wheels.findIndex(source =>
2173
+ source.mount.every((coordinate, axis) => coordinate === wheel.mount[axis])
2174
+ );
2175
+ if (sourceIndex < 0) return;
2176
+ encoder.copyBufferToBuffer({
2177
+ sourceBuffer,
2178
+ destinationBuffer,
2179
+ sourceOffset: 96 + sourceIndex * 48,
2180
+ destinationOffset: 96 + index * 48,
2181
+ size: 16
2182
+ });
2183
+ encoder.copyBufferToBuffer({
2184
+ sourceBuffer,
2185
+ destinationBuffer,
2186
+ sourceOffset: 256 + sourceIndex * 64,
2187
+ destinationOffset: 256 + index * 64,
2188
+ size: 64
2189
+ });
2190
+ });
2191
+ this.device.submit(encoder.finish());
2192
+ }
2193
+
2194
+ /** Read wheel spin, angle, suspension length and normal load after submitted steps. */
2195
+ async readVehicleWheels() {
2196
+ if (!this.vehicleBuffer || this.destroyed) throw new Error('Vehicle unavailable');
2197
+ const values = new Float32Array((await this.vehicleBuffer.readAsync(0, 256)).buffer);
2198
+ return Array.from({length: 4}, (_, index) => {
2199
+ const offset = 24 + index * 12;
2200
+ return {
2201
+ speed: values[offset],
2202
+ angle: values[offset + 1],
2203
+ length: values[offset + 2],
2204
+ load: values[offset + 3]
2205
+ };
2206
+ });
2207
+ }
2208
+
1984
2209
  /** Submit an impulse at a world-space point, or the current GPU center of mass when omitted. */
1985
2210
  applyImpulse(body: number, impulse: Vector3, point?: Vector3): void {
1986
2211
  if (
@@ -116,3 +116,4 @@ export type {GPURigidBodyJointLimit, GPURigidBodyJointDrive} from './joint-types
116
116
 
117
117
  export {rotateRigidBodyVector, normalizeRigidBodyRotation} from './rigid-body-properties';
118
118
  export type {GPURigidBodyGeneralConstraint} from './rigid-body-general-joints';
119
+ export type {GPURigidBodyVehicle} from './rigid-body-vehicle';
@@ -3,7 +3,7 @@
3
3
  // SPDX-FileCopyrightText: Copyright (c) vis.gl contributors
4
4
 
5
5
  /** Sparse contact adjacency and block-Jacobi impulses; each dispatch has exclusive output owners. */
6
- export function getRigidBodyParallelShader(ensemble: boolean): string {
6
+ export function getRigidBodyParallelShader(ensemble: boolean, blockContacts = false): string {
7
7
  return /* wgsl */ `
8
8
  struct ParallelState {
9
9
  diagnostics:array<atomic<u32>,4>,
@@ -173,32 +173,55 @@ fn writePairDeltas(pair:u32,first:u32,second:u32,impulse:vec3f,firstTorque:vec3f
173
173
  let relaxation=settings.stability.w/f32(max(1u,max(atomicLoad(&parallelState.degrees[first]),atomicLoad(&parallelState.degrees[second]))));
174
174
  var firstLinear=velocities[first].xyz;var secondLinear=velocities[second].xyz;
175
175
  var firstAngular=angularVelocities[first].xyz;var secondAngular=angularVelocities[second].xyz;
176
+ ${
177
+ blockContacts
178
+ ? `
179
+ // Solve the contact patch locally, then relax the whole block once. No extra dispatches.
180
+ var contacts:array<Contact,4>;
181
+ for(var slot=0u;slot<manifolds[pair].count;slot++){contacts[slot]=manifolds[pair].contacts[slot];}
182
+ for(var sweep=0u;sweep<2u;sweep++){
183
+ `
184
+ : ''
185
+ }
176
186
  for(var slot=0u;slot<manifolds[pair].count;slot++){
177
- var contact=manifolds[pair].contacts[slot];let point=contact.point.xyz;let normal=contact.normal.xyz;
187
+ var contact=${blockContacts ? 'contacts[slot]' : 'manifolds[pair].contacts[slot]'};let point=contact.point.xyz;let normal=contact.normal.xyz;
178
188
  let firstLever=point-positions[first].xyz;let secondLever=point-positions[second].xyz;
179
189
  let relative=secondLinear+cross(secondAngular,secondLever)-firstLinear-cross(firstAngular,firstLever);
180
190
  let normalMass=effectiveMass(first,second,point,normal);if(normalMass<=0.0){continue;}
181
191
  let bias=min(settings.stability.z,settings.stability.y*max(0.0,contact.point.w-settings.solver.x)/settings.gravity.w);
182
192
  let desiredImpulse=max(0.0,contact.impulse.x+(max(bias,contact.normal.w)-dot(relative,normal))/normalMass);
183
- let change=(desiredImpulse-contact.impulse.x)*relaxation;contact.impulse.x+=change;
193
+ let change=(desiredImpulse-contact.impulse.x)*${blockContacts ? '1.0' : 'relaxation'};contact.impulse.x+=change;
184
194
  var impulse=normal*change;
185
195
  if(dynamic(first)){firstLinear-=impulse*velocities[first].w;firstAngular-=inverseInertia(first,cross(firstLever,impulse));}
186
196
  if(dynamic(second)){secondLinear+=impulse*velocities[second].w;secondAngular+=inverseInertia(second,cross(secondLever,impulse));}
187
197
  let after=secondLinear+cross(secondAngular,secondLever)-firstLinear-cross(firstAngular,firstLever);
188
198
  let tangent=solveFriction(firstCollider,secondCollider,contact,after);
189
- var relaxedTangent=contact.tangent.xyz+(tangent-contact.tangent.xyz)*relaxation;
199
+ var relaxedTangent=contact.tangent.xyz+(tangent-contact.tangent.xyz)*${blockContacts ? '1.0' : 'relaxation'};
190
200
  // A falling normal impulse must shrink the cone even when under-relaxing.
191
201
  let staticLimit=frictionCoefficient(firstCollider,secondCollider,false)*contact.impulse.x;
192
202
  if(length(relaxedTangent)>staticLimit){relaxedTangent*=staticLimit/max(1e-30,length(relaxedTangent));}
193
203
  impulse=relaxedTangent-contact.tangent.xyz;contact.tangent=vec4f(relaxedTangent,0);
194
204
  if(dynamic(first)){firstLinear-=impulse*velocities[first].w;firstAngular-=inverseInertia(first,cross(firstLever,impulse));}
195
205
  if(dynamic(second)){secondLinear+=impulse*velocities[second].w;secondAngular+=inverseInertia(second,cross(secondLever,impulse));}
196
- manifolds[pair].contacts[slot]=contact;
206
+ ${blockContacts ? 'contacts[slot]' : 'manifolds[pair].contacts[slot]'}=contact;
207
+ }
208
+ ${
209
+ blockContacts
210
+ ? `
211
+ }
212
+ // Interpolation of feasible impulses preserves the friction cone, including unloading.
213
+ for(var slot=0u;slot<manifolds[pair].count;slot++){
214
+ let previous=manifolds[pair].contacts[slot];
215
+ manifolds[pair].contacts[slot].impulse.x=mix(previous.impulse.x,contacts[slot].impulse.x,relaxation);
216
+ manifolds[pair].contacts[slot].tangent=mix(previous.tangent,contacts[slot].tangent,relaxation);
217
+ }
218
+ `
219
+ : ''
197
220
  }
198
- parallelState.deltas[pair*4u]=vec4f(firstLinear-velocities[first].xyz,0);
199
- parallelState.deltas[pair*4u+1u]=vec4f(firstAngular-angularVelocities[first].xyz,0);
200
- parallelState.deltas[pair*4u+2u]=vec4f(secondLinear-velocities[second].xyz,0);
201
- parallelState.deltas[pair*4u+3u]=vec4f(secondAngular-angularVelocities[second].xyz,0);
221
+ parallelState.deltas[pair*4u]=vec4f((firstLinear-velocities[first].xyz)*${blockContacts ? 'relaxation' : '1.0'},0);
222
+ parallelState.deltas[pair*4u+1u]=vec4f((firstAngular-angularVelocities[first].xyz)*${blockContacts ? 'relaxation' : '1.0'},0);
223
+ parallelState.deltas[pair*4u+2u]=vec4f((secondLinear-velocities[second].xyz)*${blockContacts ? 'relaxation' : '1.0'},0);
224
+ parallelState.deltas[pair*4u+3u]=vec4f((secondAngular-angularVelocities[second].xyz)*${blockContacts ? 'relaxation' : '1.0'},0);
202
225
  }
203
226
  @compute @workgroup_size(64) fn parallelGather(@builtin(global_invocation_id) invocation:vec3u){
204
227
  var body=invocation.x;
@@ -29,7 +29,8 @@ export function getRigidBodyShader(
29
29
  jointCount = 0,
30
30
  compactContacts = true,
31
31
  collisionPartitionSize?: number,
32
- ensembleBodiesPerInstance?: number
32
+ ensembleBodiesPerInstance?: number,
33
+ blockContacts = false
33
34
  ): string {
34
35
  return /* wgsl */ `
35
36
  const COMPACT_CONTACTS:bool=${compactContacts};
@@ -390,7 +391,7 @@ ${
390
391
  }
391
392
  manifolds[pair].count=contactCount;
392
393
  }
393
- ${parallel ? getRigidBodyParallelShader(Boolean(ensembleBodiesPerInstance)) : ''}
394
+ ${parallel ? getRigidBodyParallelShader(Boolean(ensembleBodiesPerInstance), blockContacts) : ''}
394
395
  ${(parallel || hasJoints) && extended ? '@compute @workgroup_size(1) fn meshCollect(){collectMeshContacts();}' : ''}
395
396
  ${jointShader}
396
397
  ${parallel && hasJoints ? '@compute @workgroup_size(1) fn parallelJointWarm(){solveJoints(true);} @compute @workgroup_size(1) fn parallelJointSolve(){solveJoints(false);}' : ''}
@@ -0,0 +1,99 @@
1
+ // luma.gl
2
+ // SPDX-License-Identifier: MIT
3
+ // SPDX-FileCopyrightText: Copyright (c) vis.gl contributors
4
+
5
+ /** Four independently sprung wheels in a chassis frame with +X forward and +Z up. */
6
+ export type GPURigidBodyVehicle = {
7
+ /** Index of the dynamic chassis body. */
8
+ chassis: number;
9
+ /** Index of the static collider sampled by all wheels. */
10
+ terrainCollider: number;
11
+ /** Four independently suspended wheels, in rendering and telemetry order. */
12
+ wheels: readonly {
13
+ /** At full compression the wheel center is here, in chassis node coordinates (meters). */
14
+ mount: readonly [number, number, number];
15
+ /** Turn this wheel about chassis +Z by the commanded steering angle. */
16
+ steer?: boolean;
17
+ /** Apply the commanded drive torque to this wheel. */
18
+ drive?: boolean;
19
+ }[];
20
+ /** Wheel contact sphere radius in meters. */
21
+ radius: number;
22
+ /** Maximum downward distance of the wheel center from its mount in meters. */
23
+ travel: number;
24
+ /** Per-wheel spring stiffness in newtons per meter. */
25
+ springRate: number;
26
+ /** Per-wheel damping coefficient in newton seconds per meter. */
27
+ damping: number;
28
+ /** Dimensionless tire friction coefficient limiting combined longitudinal and lateral force. */
29
+ grip: number;
30
+ /** Torque per driven wheel in N m. */
31
+ motorTorque: number;
32
+ /** Maximum braking torque per wheel in newton meters. */
33
+ brakeTorque: number;
34
+ /** Rotational inertia of one wheel in kilogram meters squared. */
35
+ wheelInertia: number;
36
+ };
37
+
38
+ /** One invocation owns the chassis. All wheels sample the same pre-step velocity. */
39
+ export const VEHICLE_SHADER = /* wgsl */ `
40
+ struct Wheel { mount:vec4f, flags:vec4f, state:vec4f }
41
+ struct Vehicle { controls:vec4f, geometry:vec4f, tire:vec4f, indices:vec4u, wheels:array<Wheel,4>, poses:array<mat4x4f,4> }
42
+ @group(0) @binding(12) var<storage,read_write> vehicle:Vehicle;
43
+ @compute @workgroup_size(1) fn advanceVehicle() {
44
+ let chassis=vehicle.indices.x;
45
+ let terrain=vehicle.indices.y;
46
+ let rotation=orientations[chassis];
47
+ let center=positions[chassis].xyz;
48
+ let down=rotate(rotation,vec3f(0,0,-1));
49
+ let radius=vehicle.geometry.x;
50
+ let travel=vehicle.geometry.y;
51
+ let timestep=settings.gravity.w;
52
+ var impulse=vec3f(0);
53
+ var torque=vec3f(0);
54
+ for(var index=0u;index<4u;index++){
55
+ let wheel=vehicle.wheels[index];
56
+ let mount=center+rotate(rotation,wheel.mount.xyz-bodyCenter(chassis));
57
+ let hit=sweepSphere(terrain,colliderLocal(terrain,mount-colliderPosition(terrain)),colliderLocal(terrain,down),travel,radius,false);
58
+ var speed=wheel.state.x+vehicle.controls.x*vehicle.tire.y*wheel.flags.y*timestep/vehicle.tire.w;
59
+ speed-=sign(speed)*min(abs(speed),vehicle.controls.z*vehicle.tire.z*timestep/vehicle.tire.w);
60
+ let steering=vehicle.controls.y*wheel.flags.x;
61
+ var lengthNow=travel;
62
+ var load=0.0;
63
+ if(hit.hit!=0u && hit.complete!=0u){
64
+ let normal=rotate(colliderRotation(terrain),hit.normal);
65
+ let support=dot(normal,-down);
66
+ if(support>0.15){
67
+ lengthNow=hit.distance;
68
+ let lever=colliderPosition(terrain)+rotate(colliderRotation(terrain),hit.point)-center;
69
+ let velocity=velocities[chassis].xyz+cross(angularVelocities[chassis].xyz,lever);
70
+ load=max(0.0,(travel-lengthNow)*vehicle.geometry.z-vehicle.geometry.w*dot(velocity,normal)/support);
71
+ let heading=rotate(rotation,vec3f(cos(steering),sin(steering),0));
72
+ let side=normalize(cross(normal,heading));
73
+ let forward=cross(side,normal);
74
+ let slip=vec2f(speed*radius-dot(velocity,forward),-dot(velocity,side));
75
+ let demand=slip*load*vec2f(1.1,1.5);
76
+ var friction=demand*min(1.0,vehicle.tire.x*load/max(length(demand),0.0001));
77
+ // Bound tire feedback so a light wheel cannot overshoot rolling speed in one step.
78
+ let longitudinalLimit=abs(slip.x)*vehicle.tire.w/(radius*radius*timestep);
79
+ friction.x=clamp(friction.x,-longitudinalLimit,longitudinalLimit);
80
+ let change=(normal*load+forward*friction.x+side*friction.y)*timestep;
81
+ impulse+=change;
82
+ torque+=cross(lever,change);
83
+ speed-=friction.x*radius*timestep/vehicle.tire.w;
84
+ }
85
+ }
86
+ let angle=wheel.state.y+speed*timestep;
87
+ vehicle.wheels[index].state=vec4f(speed,angle,lengthNow,load);
88
+ let heading=vec3f(cos(steering),sin(steering),0);
89
+ let axle=vec3f(-sin(steering),cos(steering),0);
90
+ let vertical=vec3f(0,0,1);
91
+ let hub=wheel.mount.xyz-vertical*lengthNow;
92
+ vehicle.poses[index]=mat4x4f(vec4f(heading*cos(angle)-vertical*sin(angle),0),
93
+ vec4f(axle,0),vec4f(heading*sin(angle)+vertical*cos(angle),0),vec4f(hub,1));
94
+ }
95
+ velocities[chassis]=vec4f(velocities[chassis].xyz+impulse*velocities[chassis].w,velocities[chassis].w);
96
+ angularVelocities[chassis]=vec4f(angularVelocities[chassis].xyz+inverseInertia(chassis,torque),0);
97
+ sleepStates[chassis]=vec4f(0);
98
+ }
99
+ `;
@@ -419,7 +419,7 @@ the environment variable selects a representative dataset while ordinary CI
419
419
  uses a small smoke-test dataset:
420
420
 
421
421
  ```sh
422
- VITE_LUPROJ_BENCHMARK_ROWS=16384 yarn test-headless \
422
+ VITE_GPU_PROJECT_BENCHMARK_ROWS=16384 yarn test-headless \
423
423
  modules/graph/test/gpu-project/projection-benchmark.spec.ts --reporter=verbose
424
424
  ```
425
425
 
@@ -445,7 +445,7 @@ provider is math.gl's JavaScript proj4 adapter, not native C++ PROJ; its old ora
445
445
  timing is retained separately from the matched consumer work.
446
446
 
447
447
  ```sh
448
- LUMA_TEST_BROWSER_BENCHMARKS=true VITE_LUPROJ_BENCHMARK_ROWS=65536 \
448
+ LUMA_TEST_BROWSER_BENCHMARKS=true VITE_GPU_PROJECT_BENCHMARK_ROWS=65536 \
449
449
  yarn test-headless --no-coverage --silent=false --reporter=verbose \
450
450
  modules/graph/test/gpu-project/projection-program-benchmark.spec.ts
451
451
  ```
@@ -456,12 +456,12 @@ It reports 1/4-consumer reuse and actual multi-patch costs without changing prec
456
456
 
457
457
  ```sh
458
458
  LUMA_TEST_BROWSER_BENCHMARKS=true \
459
- VITE_LUPROJ_SWEEP_ROWS=1024,16384,65536 VITE_LUPROJ_SWEEP_CONSUMERS=1,4 \
459
+ VITE_GPU_PROJECT_SWEEP_ROWS=1024,16384,65536 VITE_GPU_PROJECT_SWEEP_CONSUMERS=1,4 \
460
460
  yarn test-headless --no-coverage --silent=false --reporter=verbose \
461
461
  modules/graph/test/gpu-project/projection-performance.spec.ts
462
462
  ```
463
463
 
464
- This sweep defaults to uninstrumented timing; set `VITE_LUPROJ_SWEEP_GPU_TIMING=true` for a separate
464
+ This sweep defaults to uninstrumented timing; set `VITE_GPU_PROJECT_SWEEP_GPU_TIMING=true` for a separate
465
465
  GPU-timestamp run. JSON reports begin with `PROJECTION_PERFORMANCE_SWEEP`. These synthetic workloads
466
466
  do not replace production-consumer or cross-vendor evidence.
467
467
 
@@ -0,0 +1,59 @@
1
+ // luma.gl
2
+ // SPDX-License-Identifier: MIT
3
+ // SPDX-FileCopyrightText: Copyright (c) vis.gl contributors
4
+ // SPDX-FileComment: Independently implemented for WebGPU; inspired by NVIDIA RAPIDS cuProj.
5
+
6
+ import {assert, type Device} from '@luma.gl/core';
7
+ import {CPUVector, GPUVector} from '@luma.gl/graph/gpu-data';
8
+ import {GPUSimpleGraph} from '../gpu-simple-graph/gpu-simple-graph';
9
+ import {GPUGraph} from '../gpu-core/gpu-graph';
10
+ import type {CompiledGPUGraph} from '../gpu-core/compiled-gpu-graph';
11
+ import type {CompiledGPUSimpleExpressionGraph} from '../gpu-simple-graph/compiled-gpu-expression-graph';
12
+ import {gpuGraph} from '../gpu-core/gpu-graph-value';
13
+ import {CPUProjectionOperation, type CPUProjectionOperationProps} from './cpu-projection-operation';
14
+
15
+ export type CoordinateProjectionGraphProps = {
16
+ format: 'float32x2' | 'float32x3';
17
+ projection: CPUProjectionOperationProps['projection'];
18
+ };
19
+ export type ProjectedCoordinateResult = {
20
+ positions: GPUVector;
21
+ /** Release this invocation's GPU result after downstream consumers finish. */
22
+ destroy(): void;
23
+ };
24
+
25
+ /** Reusable layer-facing point-coordinate pipeline. Projection loading remains caller-owned. */
26
+ export class CoordinateProjectionGraph {
27
+ private readonly graph: CompiledGPUGraph | CompiledGPUSimpleExpressionGraph;
28
+ readonly format: CoordinateProjectionGraphProps['format'];
29
+
30
+ constructor(device: Device, props: CoordinateProjectionGraphProps) {
31
+ this.format = props.format;
32
+ const graph = device.type === 'webgpu' ? new GPUGraph() : new GPUSimpleGraph();
33
+ graph.addInput('source', gpuGraph.vector(props.format));
34
+ graph.add(
35
+ new CPUProjectionOperation({
36
+ id: 'project-coordinates',
37
+ input: 'source',
38
+ output: 'positions',
39
+ format: props.format,
40
+ projection: props.projection
41
+ })
42
+ );
43
+ this.graph = graph.compile(device, {outputs: ['positions']});
44
+ }
45
+
46
+ /** Borrow input storage and preserve row/chunk boundaries; each result owns independent storage. */
47
+ async run(source: CPUVector | GPUVector): Promise<ProjectedCoordinateResult> {
48
+ assert(source.format === this.format);
49
+ // Point layers must handle null filtering before this numeric projection boundary.
50
+ assert(source.data.every(chunk => !chunk.nullBitmap && !chunk.valueOffsets));
51
+ const {positions} = await this.graph.run({inputs: {source}});
52
+ return {positions, destroy: () => positions.destroy()};
53
+ }
54
+
55
+ /** Destroy the compiled pipeline. Previously returned results remain caller-owned. */
56
+ destroy(): void {
57
+ this.graph.destroy();
58
+ }
59
+ }