@flighthq/render-wgpu 0.5.1-next.973.788d3d7 → 0.6.0

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 (407) hide show
  1. package/README.md +2 -2
  2. package/dist/.tsbuildinfo.compressed-texture-decoder-contract +1 -0
  3. package/dist/.tsbuildinfo.contract +1 -0
  4. package/dist/.tsbuildinfo.runtime +1 -0
  5. package/dist/compressed-texture-decoder-contract/WgpuCompressedTextureDecoder.d.ts +3 -0
  6. package/dist/compressed-texture-decoder-contract/WgpuCompressedTextureDecoder.d.ts.map +1 -0
  7. package/dist/compressed-texture-decoder-contract/WgpuCompressedTextureDecoder.js +2 -0
  8. package/dist/compressed-texture-decoder-contract/WgpuCompressedTextureDecoder.js.map +1 -0
  9. package/dist/compressed-texture-decoder-contract/compressedTextureDecoderContract.d.ts +2 -0
  10. package/dist/compressed-texture-decoder-contract/compressedTextureDecoderContract.d.ts.map +1 -0
  11. package/dist/compressed-texture-decoder-contract/compressedTextureDecoderContract.js +2 -0
  12. package/dist/compressed-texture-decoder-contract/compressedTextureDecoderContract.js.map +1 -0
  13. package/dist/contract.d.ts +32 -34
  14. package/dist/contract.d.ts.map +1 -1
  15. package/dist/contract.js +32 -34
  16. package/dist/contract.js.map +1 -1
  17. package/dist/contract.render-wgpu-types.d.ts +55 -0
  18. package/dist/contract.render-wgpu-types.d.ts.map +1 -0
  19. package/dist/contract.render-wgpu-types.js +5 -0
  20. package/dist/contract.render-wgpu-types.js.map +1 -0
  21. package/dist/enableWgpuTextureResolverGuards.d.ts +3 -2
  22. package/dist/enableWgpuTextureResolverGuards.d.ts.map +1 -1
  23. package/dist/enableWgpuTextureResolverGuards.js +12 -9
  24. package/dist/enableWgpuTextureResolverGuards.js.map +1 -1
  25. package/dist/explainWgpuTextureResolution.d.ts +2 -1
  26. package/dist/explainWgpuTextureResolution.d.ts.map +1 -1
  27. package/dist/explainWgpuTextureResolution.js +2 -5
  28. package/dist/explainWgpuTextureResolution.js.map +1 -1
  29. package/dist/explainWgpuUniformEndianness.d.ts +3 -0
  30. package/dist/explainWgpuUniformEndianness.d.ts.map +1 -0
  31. package/dist/explainWgpuUniformEndianness.js +25 -0
  32. package/dist/explainWgpuUniformEndianness.js.map +1 -0
  33. package/dist/index.d.ts +20 -1
  34. package/dist/index.d.ts.map +1 -1
  35. package/dist/index.js +20 -1
  36. package/dist/index.js.map +1 -1
  37. package/dist/types/Host.d.ts +5 -0
  38. package/dist/types/Host.d.ts.map +1 -0
  39. package/dist/types/Host.js +2 -0
  40. package/dist/types/Host.js.map +1 -0
  41. package/dist/types/WgpuAdapter.d.ts +14 -0
  42. package/dist/types/WgpuAdapter.d.ts.map +1 -0
  43. package/dist/types/WgpuAdapter.js +2 -0
  44. package/dist/types/WgpuAdapter.js.map +1 -0
  45. package/dist/types/WgpuAdapterCapabilities.d.ts +7 -0
  46. package/dist/types/WgpuAdapterCapabilities.d.ts.map +1 -0
  47. package/dist/types/WgpuAdapterCapabilities.js +2 -0
  48. package/dist/types/WgpuAdapterCapabilities.js.map +1 -0
  49. package/dist/types/WgpuBindGroup.d.ts +23 -0
  50. package/dist/types/WgpuBindGroup.d.ts.map +1 -0
  51. package/dist/types/WgpuBindGroup.js +2 -0
  52. package/dist/types/WgpuBindGroup.js.map +1 -0
  53. package/dist/types/WgpuBindGroupLayout.d.ts +45 -0
  54. package/dist/types/WgpuBindGroupLayout.d.ts.map +1 -0
  55. package/dist/types/WgpuBindGroupLayout.js +7 -0
  56. package/dist/types/WgpuBindGroupLayout.js.map +1 -0
  57. package/dist/types/WgpuBuffer.d.ts +34 -0
  58. package/dist/types/WgpuBuffer.d.ts.map +1 -0
  59. package/dist/types/WgpuBuffer.js +19 -0
  60. package/dist/types/WgpuBuffer.js.map +1 -0
  61. package/dist/types/WgpuCanvasContext.d.ts +17 -0
  62. package/dist/types/WgpuCanvasContext.d.ts.map +1 -0
  63. package/dist/types/WgpuCanvasContext.js +2 -0
  64. package/dist/types/WgpuCanvasContext.js.map +1 -0
  65. package/dist/types/WgpuColorAdjustmentMaterialFeature.d.ts +14 -0
  66. package/dist/types/WgpuColorAdjustmentMaterialFeature.d.ts.map +1 -0
  67. package/dist/types/WgpuColorAdjustmentMaterialFeature.js +2 -0
  68. package/dist/types/WgpuColorAdjustmentMaterialFeature.js.map +1 -0
  69. package/dist/types/WgpuCommandBuffer.d.ts +5 -0
  70. package/dist/types/WgpuCommandBuffer.d.ts.map +1 -0
  71. package/dist/types/WgpuCommandBuffer.js +2 -0
  72. package/dist/types/WgpuCommandBuffer.js.map +1 -0
  73. package/dist/types/WgpuCommandEncoder.d.ts +12 -0
  74. package/dist/types/WgpuCommandEncoder.d.ts.map +1 -0
  75. package/dist/types/WgpuCommandEncoder.js +2 -0
  76. package/dist/types/WgpuCommandEncoder.js.map +1 -0
  77. package/dist/types/WgpuCompressedTextureSupport.d.ts +6 -0
  78. package/dist/types/WgpuCompressedTextureSupport.d.ts.map +1 -0
  79. package/dist/types/WgpuCompressedTextureSupport.js +2 -0
  80. package/dist/types/WgpuCompressedTextureSupport.js.map +1 -0
  81. package/dist/types/WgpuCompressedTextureUploader.d.ts +6 -0
  82. package/dist/types/WgpuCompressedTextureUploader.d.ts.map +1 -0
  83. package/dist/types/WgpuCompressedTextureUploader.js +2 -0
  84. package/dist/types/WgpuCompressedTextureUploader.js.map +1 -0
  85. package/dist/types/WgpuCustomMaterialShaderSource.d.ts +2 -0
  86. package/dist/types/WgpuCustomMaterialShaderSource.d.ts.map +1 -0
  87. package/dist/types/WgpuCustomMaterialShaderSource.js +2 -0
  88. package/dist/types/WgpuCustomMaterialShaderSource.js.map +1 -0
  89. package/dist/types/WgpuDevice.d.ts +76 -0
  90. package/dist/types/WgpuDevice.d.ts.map +1 -0
  91. package/dist/types/WgpuDevice.js +2 -0
  92. package/dist/types/WgpuDevice.js.map +1 -0
  93. package/dist/types/WgpuDeviceRuntime.d.ts +53 -0
  94. package/dist/types/WgpuDeviceRuntime.d.ts.map +1 -0
  95. package/dist/types/WgpuDeviceRuntime.js +2 -0
  96. package/dist/types/WgpuDeviceRuntime.js.map +1 -0
  97. package/dist/types/WgpuDeviceSignals.d.ts +6 -0
  98. package/dist/types/WgpuDeviceSignals.d.ts.map +1 -0
  99. package/dist/types/WgpuDeviceSignals.js +2 -0
  100. package/dist/types/WgpuDeviceSignals.js.map +1 -0
  101. package/dist/types/WgpuDeviceState.d.ts +7 -0
  102. package/dist/types/WgpuDeviceState.d.ts.map +1 -0
  103. package/dist/types/WgpuDeviceState.js +2 -0
  104. package/dist/types/WgpuDeviceState.js.map +1 -0
  105. package/dist/types/WgpuEffectState.d.ts +19 -0
  106. package/dist/types/WgpuEffectState.d.ts.map +1 -0
  107. package/dist/types/WgpuEffectState.js +2 -0
  108. package/dist/types/WgpuEffectState.js.map +1 -0
  109. package/dist/types/WgpuExternalImageSource.d.ts +18 -0
  110. package/dist/types/WgpuExternalImageSource.d.ts.map +1 -0
  111. package/dist/types/WgpuExternalImageSource.js +2 -0
  112. package/dist/types/WgpuExternalImageSource.js.map +1 -0
  113. package/dist/types/WgpuFullscreenPipeline.d.ts +14 -0
  114. package/dist/types/WgpuFullscreenPipeline.d.ts.map +1 -0
  115. package/dist/types/WgpuFullscreenPipeline.js +2 -0
  116. package/dist/types/WgpuFullscreenPipeline.js.map +1 -0
  117. package/dist/types/WgpuGpu.d.ts +7 -0
  118. package/dist/types/WgpuGpu.d.ts.map +1 -0
  119. package/dist/types/WgpuGpu.js +2 -0
  120. package/dist/types/WgpuGpu.js.map +1 -0
  121. package/dist/types/WgpuHost.d.ts +44 -0
  122. package/dist/types/WgpuHost.d.ts.map +1 -0
  123. package/dist/types/WgpuHost.js +2 -0
  124. package/dist/types/WgpuHost.js.map +1 -0
  125. package/dist/types/WgpuMeshMaterialRenderer.d.ts +11 -0
  126. package/dist/types/WgpuMeshMaterialRenderer.d.ts.map +1 -0
  127. package/dist/types/WgpuMeshMaterialRenderer.js +2 -0
  128. package/dist/types/WgpuMeshMaterialRenderer.js.map +1 -0
  129. package/dist/types/WgpuModifierSnippet.d.ts +16 -0
  130. package/dist/types/WgpuModifierSnippet.d.ts.map +1 -0
  131. package/dist/types/WgpuModifierSnippet.js +2 -0
  132. package/dist/types/WgpuModifierSnippet.js.map +1 -0
  133. package/dist/types/WgpuParticleResources.d.ts +12 -0
  134. package/dist/types/WgpuParticleResources.d.ts.map +1 -0
  135. package/dist/types/WgpuParticleResources.js +2 -0
  136. package/dist/types/WgpuParticleResources.js.map +1 -0
  137. package/dist/types/WgpuPipelineLayout.d.ts +8 -0
  138. package/dist/types/WgpuPipelineLayout.d.ts.map +1 -0
  139. package/dist/types/WgpuPipelineLayout.js +2 -0
  140. package/dist/types/WgpuPipelineLayout.js.map +1 -0
  141. package/dist/types/WgpuQuadBatchResources.d.ts +12 -0
  142. package/dist/types/WgpuQuadBatchResources.d.ts.map +1 -0
  143. package/dist/types/WgpuQuadBatchResources.js +2 -0
  144. package/dist/types/WgpuQuadBatchResources.js.map +1 -0
  145. package/dist/types/WgpuQuadMaterialRenderer.d.ts +9 -0
  146. package/dist/types/WgpuQuadMaterialRenderer.d.ts.map +1 -0
  147. package/dist/types/WgpuQuadMaterialRenderer.js +2 -0
  148. package/dist/types/WgpuQuadMaterialRenderer.js.map +1 -0
  149. package/dist/types/WgpuQueue.d.ts +12 -0
  150. package/dist/types/WgpuQueue.d.ts.map +1 -0
  151. package/dist/types/WgpuQueue.js +2 -0
  152. package/dist/types/WgpuQueue.js.map +1 -0
  153. package/dist/types/WgpuRenderOptions.d.ts +14 -0
  154. package/dist/types/WgpuRenderOptions.d.ts.map +1 -0
  155. package/dist/types/WgpuRenderOptions.js +2 -0
  156. package/dist/types/WgpuRenderOptions.js.map +1 -0
  157. package/dist/types/WgpuRenderPass.d.ts +31 -0
  158. package/dist/types/WgpuRenderPass.d.ts.map +1 -0
  159. package/dist/types/WgpuRenderPass.js +2 -0
  160. package/dist/types/WgpuRenderPass.js.map +1 -0
  161. package/dist/types/WgpuRenderPassEncoder.d.ts +52 -0
  162. package/dist/types/WgpuRenderPassEncoder.d.ts.map +1 -0
  163. package/dist/types/WgpuRenderPassEncoder.js +2 -0
  164. package/dist/types/WgpuRenderPassEncoder.js.map +1 -0
  165. package/dist/types/WgpuRenderPipeline.d.ts +96 -0
  166. package/dist/types/WgpuRenderPipeline.d.ts.map +1 -0
  167. package/dist/types/WgpuRenderPipeline.js +9 -0
  168. package/dist/types/WgpuRenderPipeline.js.map +1 -0
  169. package/dist/types/WgpuRenderState.d.ts +249 -0
  170. package/dist/types/WgpuRenderState.d.ts.map +1 -0
  171. package/dist/types/WgpuRenderState.js +2 -0
  172. package/dist/types/WgpuRenderState.js.map +1 -0
  173. package/dist/types/WgpuRenderStateOptions.d.ts +31 -0
  174. package/dist/types/WgpuRenderStateOptions.d.ts.map +1 -0
  175. package/dist/types/WgpuRenderStateOptions.js +2 -0
  176. package/dist/types/WgpuRenderStateOptions.js.map +1 -0
  177. package/dist/types/WgpuRenderTarget.d.ts +62 -0
  178. package/dist/types/WgpuRenderTarget.d.ts.map +1 -0
  179. package/dist/types/WgpuRenderTarget.js +2 -0
  180. package/dist/types/WgpuRenderTarget.js.map +1 -0
  181. package/dist/types/WgpuRenderTexture.d.ts +25 -0
  182. package/dist/types/WgpuRenderTexture.d.ts.map +1 -0
  183. package/dist/types/WgpuRenderTexture.js +2 -0
  184. package/dist/types/WgpuRenderTexture.js.map +1 -0
  185. package/dist/types/WgpuSampler.d.ts +19 -0
  186. package/dist/types/WgpuSampler.d.ts.map +1 -0
  187. package/dist/types/WgpuSampler.js +2 -0
  188. package/dist/types/WgpuSampler.js.map +1 -0
  189. package/dist/types/WgpuScene3DRuntime.d.ts +6 -0
  190. package/dist/types/WgpuScene3DRuntime.d.ts.map +1 -0
  191. package/dist/types/WgpuScene3DRuntime.js +2 -0
  192. package/dist/types/WgpuScene3DRuntime.js.map +1 -0
  193. package/dist/types/WgpuShaderModule.d.ts +6 -0
  194. package/dist/types/WgpuShaderModule.d.ts.map +1 -0
  195. package/dist/types/WgpuShaderModule.js +2 -0
  196. package/dist/types/WgpuShaderModule.js.map +1 -0
  197. package/dist/types/WgpuShapeMesh.d.ts +7 -0
  198. package/dist/types/WgpuShapeMesh.d.ts.map +1 -0
  199. package/dist/types/WgpuShapeMesh.js +2 -0
  200. package/dist/types/WgpuShapeMesh.js.map +1 -0
  201. package/dist/types/WgpuSkinningAdapter.d.ts +18 -0
  202. package/dist/types/WgpuSkinningAdapter.d.ts.map +1 -0
  203. package/dist/types/WgpuSkinningAdapter.js +2 -0
  204. package/dist/types/WgpuSkinningAdapter.js.map +1 -0
  205. package/dist/types/WgpuSurface.d.ts +5 -0
  206. package/dist/types/WgpuSurface.d.ts.map +1 -0
  207. package/dist/types/WgpuSurface.js +2 -0
  208. package/dist/types/WgpuSurface.js.map +1 -0
  209. package/dist/types/WgpuTexture.d.ts +58 -0
  210. package/dist/types/WgpuTexture.d.ts.map +1 -0
  211. package/dist/types/WgpuTexture.js +9 -0
  212. package/dist/types/WgpuTexture.js.map +1 -0
  213. package/dist/types/WgpuTextureFormat.d.ts +2 -0
  214. package/dist/types/WgpuTextureFormat.d.ts.map +1 -0
  215. package/dist/types/WgpuTextureFormat.js +2 -0
  216. package/dist/types/WgpuTextureFormat.js.map +1 -0
  217. package/dist/types/WgpuTextureResolver.d.ts +4 -0
  218. package/dist/types/WgpuTextureResolver.d.ts.map +1 -0
  219. package/dist/types/WgpuTextureResolver.js +2 -0
  220. package/dist/types/WgpuTextureResolver.js.map +1 -0
  221. package/dist/types/WgpuTextureView.d.ts +16 -0
  222. package/dist/types/WgpuTextureView.d.ts.map +1 -0
  223. package/dist/types/WgpuTextureView.js +2 -0
  224. package/dist/types/WgpuTextureView.js.map +1 -0
  225. package/dist/types/WgpuUniformEndianness.d.ts +7 -0
  226. package/dist/types/WgpuUniformEndianness.d.ts.map +1 -0
  227. package/dist/types/WgpuUniformEndianness.js +2 -0
  228. package/dist/types/WgpuUniformEndianness.js.map +1 -0
  229. package/dist/types/WgpuVelocityWriter.d.ts +11 -0
  230. package/dist/types/WgpuVelocityWriter.d.ts.map +1 -0
  231. package/dist/types/WgpuVelocityWriter.js +2 -0
  232. package/dist/types/WgpuVelocityWriter.js.map +1 -0
  233. package/dist/wgpuAdapterCapabilities.d.ts +2 -2
  234. package/dist/wgpuAdapterCapabilities.d.ts.map +1 -1
  235. package/dist/wgpuAdapterCapabilities.js.map +1 -1
  236. package/dist/wgpuCompressedTexture.d.ts +7 -5
  237. package/dist/wgpuCompressedTexture.d.ts.map +1 -1
  238. package/dist/wgpuCompressedTexture.js +10 -18
  239. package/dist/wgpuCompressedTexture.js.map +1 -1
  240. package/dist/wgpuDeviceLoss.d.ts +2 -2
  241. package/dist/wgpuDeviceLoss.d.ts.map +1 -1
  242. package/dist/wgpuDeviceLoss.js +1 -1
  243. package/dist/wgpuDeviceLoss.js.map +1 -1
  244. package/dist/wgpuDraw.d.ts +11 -5
  245. package/dist/wgpuDraw.d.ts.map +1 -1
  246. package/dist/wgpuDraw.js +21 -20
  247. package/dist/wgpuDraw.js.map +1 -1
  248. package/dist/wgpuExternalImageSource.d.ts +3 -2
  249. package/dist/wgpuExternalImageSource.d.ts.map +1 -1
  250. package/dist/wgpuExternalImageSource.js.map +1 -1
  251. package/dist/wgpuExternalTexture.d.ts +7 -3
  252. package/dist/wgpuExternalTexture.d.ts.map +1 -1
  253. package/dist/wgpuExternalTexture.js +5 -5
  254. package/dist/wgpuExternalTexture.js.map +1 -1
  255. package/dist/wgpuFrame.d.ts +23 -0
  256. package/dist/wgpuFrame.d.ts.map +1 -0
  257. package/dist/{wgpuBackground.js → wgpuFrame.js} +67 -122
  258. package/dist/wgpuFrame.js.map +1 -0
  259. package/dist/wgpuFullscreenPass.d.ts +5 -4
  260. package/dist/wgpuFullscreenPass.d.ts.map +1 -1
  261. package/dist/wgpuFullscreenPass.js +22 -8
  262. package/dist/wgpuFullscreenPass.js.map +1 -1
  263. package/dist/wgpuHost.d.ts +4 -7
  264. package/dist/wgpuHost.d.ts.map +1 -1
  265. package/dist/wgpuHost.js +81 -70
  266. package/dist/wgpuHost.js.map +1 -1
  267. package/dist/wgpuMipmap.d.ts +2 -2
  268. package/dist/wgpuMipmap.d.ts.map +1 -1
  269. package/dist/wgpuMipmap.js +4 -3
  270. package/dist/wgpuMipmap.js.map +1 -1
  271. package/dist/wgpuQuadMaterialRegistry.d.ts +7 -0
  272. package/dist/wgpuQuadMaterialRegistry.d.ts.map +1 -0
  273. package/dist/wgpuQuadMaterialRegistry.js +33 -0
  274. package/dist/wgpuQuadMaterialRegistry.js.map +1 -0
  275. package/dist/wgpuRenderPass.d.ts +9 -0
  276. package/dist/wgpuRenderPass.d.ts.map +1 -0
  277. package/dist/wgpuRenderPass.js +210 -0
  278. package/dist/wgpuRenderPass.js.map +1 -0
  279. package/dist/wgpuRenderState.d.ts +16 -12
  280. package/dist/wgpuRenderState.d.ts.map +1 -1
  281. package/dist/wgpuRenderState.js +104 -149
  282. package/dist/wgpuRenderState.js.map +1 -1
  283. package/dist/wgpuRenderTarget.d.ts +13 -29
  284. package/dist/wgpuRenderTarget.d.ts.map +1 -1
  285. package/dist/wgpuRenderTarget.js +20 -253
  286. package/dist/wgpuRenderTarget.js.map +1 -1
  287. package/dist/wgpuRenderTargetPool.d.ts +8 -6
  288. package/dist/wgpuRenderTargetPool.d.ts.map +1 -1
  289. package/dist/wgpuRenderTargetPool.js +9 -9
  290. package/dist/wgpuRenderTargetPool.js.map +1 -1
  291. package/dist/wgpuRenderTexture.d.ts +7 -4
  292. package/dist/wgpuRenderTexture.d.ts.map +1 -1
  293. package/dist/wgpuRenderTexture.js +15 -17
  294. package/dist/wgpuRenderTexture.js.map +1 -1
  295. package/dist/wgpuRenderTexturePool.d.ts +3 -1
  296. package/dist/wgpuRenderTexturePool.d.ts.map +1 -1
  297. package/dist/wgpuRenderTexturePool.js +5 -7
  298. package/dist/wgpuRenderTexturePool.js.map +1 -1
  299. package/dist/wgpuScissor.d.ts +3 -3
  300. package/dist/wgpuScissor.d.ts.map +1 -1
  301. package/dist/wgpuScissor.js +8 -5
  302. package/dist/wgpuScissor.js.map +1 -1
  303. package/dist/wgpuScreenAntialias.d.ts +3 -0
  304. package/dist/wgpuScreenAntialias.d.ts.map +1 -0
  305. package/dist/wgpuScreenAntialias.js +120 -0
  306. package/dist/wgpuScreenAntialias.js.map +1 -0
  307. package/dist/wgpuScreenCapture.d.ts +6 -0
  308. package/dist/wgpuScreenCapture.d.ts.map +1 -0
  309. package/dist/wgpuScreenCapture.js +138 -0
  310. package/dist/wgpuScreenCapture.js.map +1 -0
  311. package/dist/wgpuScreenRenderTarget.d.ts +11 -0
  312. package/dist/wgpuScreenRenderTarget.d.ts.map +1 -0
  313. package/dist/wgpuScreenRenderTarget.js +121 -0
  314. package/dist/wgpuScreenRenderTarget.js.map +1 -0
  315. package/dist/wgpuShader.d.ts +11 -8
  316. package/dist/wgpuShader.d.ts.map +1 -1
  317. package/dist/wgpuShader.js +11 -10
  318. package/dist/wgpuShader.js.map +1 -1
  319. package/dist/wgpuShaderBinding.d.ts +3 -1
  320. package/dist/wgpuShaderBinding.d.ts.map +1 -1
  321. package/dist/wgpuShaderBinding.js +1 -1
  322. package/dist/wgpuShaderBinding.js.map +1 -1
  323. package/dist/wgpuShaderRegistry.d.ts +1 -1
  324. package/dist/wgpuShaderRegistry.d.ts.map +1 -1
  325. package/dist/wgpuShaderRegistry.js +1 -1
  326. package/dist/wgpuShaderRegistry.js.map +1 -1
  327. package/dist/wgpuTestHelper.d.ts +11 -2
  328. package/dist/wgpuTestHelper.d.ts.map +1 -1
  329. package/dist/wgpuTestHelper.js +50 -38
  330. package/dist/wgpuTestHelper.js.map +1 -1
  331. package/dist/wgpuTextureRenderTarget.d.ts +22 -0
  332. package/dist/wgpuTextureRenderTarget.d.ts.map +1 -0
  333. package/dist/wgpuTextureRenderTarget.js +123 -0
  334. package/dist/wgpuTextureRenderTarget.js.map +1 -0
  335. package/dist/wgpuTextureResolver.d.ts +5 -1
  336. package/dist/wgpuTextureResolver.d.ts.map +1 -1
  337. package/dist/wgpuTextureResolver.js +13 -12
  338. package/dist/wgpuTextureResolver.js.map +1 -1
  339. package/dist/wgpuTextureUpload.d.ts +5 -4
  340. package/dist/wgpuTextureUpload.d.ts.map +1 -1
  341. package/dist/wgpuTextureUpload.js +1 -1
  342. package/dist/wgpuTextureUpload.js.map +1 -1
  343. package/package.json +33 -13
  344. package/src/enableWgpuTextureResolverGuards.test.ts +40 -19
  345. package/src/explainWgpuTextureResolution.test.ts +6 -6
  346. package/src/explainWgpuUniformEndianness.test.ts +11 -0
  347. package/src/types/WgpuBindGroupLayout.test.ts +9 -0
  348. package/src/types/WgpuBuffer.test.ts +26 -0
  349. package/src/types/WgpuGpu.test.ts +56 -0
  350. package/src/types/WgpuRenderPipeline.test.ts +12 -0
  351. package/src/types/WgpuTexture.test.ts +15 -0
  352. package/src/wgpuAdapterCapabilities.test.ts +5 -4
  353. package/src/wgpuCompressedTexture.test.ts +31 -37
  354. package/src/wgpuDeviceLoss.test.ts +31 -24
  355. package/src/wgpuDraw.test.ts +21 -24
  356. package/src/wgpuExternalImageSource.test.ts +12 -11
  357. package/src/wgpuExternalTexture.test.ts +7 -6
  358. package/src/{wgpuBackground.test.ts → wgpuFrame.test.ts} +47 -29
  359. package/src/wgpuFullscreenPass.test.ts +8 -8
  360. package/src/wgpuHost.test.ts +57 -186
  361. package/src/wgpuMipmap.test.ts +15 -9
  362. package/src/wgpuQuadMaterialRegistry.test.ts +132 -0
  363. package/src/wgpuRenderPass.test.ts +239 -0
  364. package/src/wgpuRenderState.test.ts +215 -550
  365. package/src/wgpuRenderTarget.test.ts +44 -220
  366. package/src/wgpuRenderTargetPool.test.ts +23 -23
  367. package/src/wgpuRenderTexture.test.ts +21 -18
  368. package/src/wgpuRenderTexturePool.test.ts +3 -3
  369. package/src/wgpuScissor.test.ts +50 -19
  370. package/src/wgpuScreenAntialias.test.ts +65 -0
  371. package/src/wgpuScreenCapture.test.ts +165 -0
  372. package/src/wgpuScreenRenderTarget.test.ts +172 -0
  373. package/src/wgpuShader.test.ts +12 -11
  374. package/src/wgpuShaderBinding.test.ts +4 -4
  375. package/src/wgpuShaderRegistry.test.ts +4 -5
  376. package/src/wgpuTestHelper.test.ts +8 -7
  377. package/src/wgpuTextureRenderTarget.test.ts +129 -0
  378. package/src/wgpuTextureResolver.test.ts +25 -14
  379. package/src/wgpuTextureUpload.test.ts +15 -10
  380. package/dist/wgpuAntialias.d.ts +0 -14
  381. package/dist/wgpuAntialias.d.ts.map +0 -1
  382. package/dist/wgpuAntialias.js +0 -155
  383. package/dist/wgpuAntialias.js.map +0 -1
  384. package/dist/wgpuBackground.d.ts +0 -20
  385. package/dist/wgpuBackground.d.ts.map +0 -1
  386. package/dist/wgpuBackground.js.map +0 -1
  387. package/dist/wgpuElement.d.ts +0 -7
  388. package/dist/wgpuElement.d.ts.map +0 -1
  389. package/dist/wgpuElement.js +0 -20
  390. package/dist/wgpuElement.js.map +0 -1
  391. package/dist/wgpuMaterialRegistry.d.ts +0 -5
  392. package/dist/wgpuMaterialRegistry.d.ts.map +0 -1
  393. package/dist/wgpuMaterialRegistry.js +0 -32
  394. package/dist/wgpuMaterialRegistry.js.map +0 -1
  395. package/dist/wgpuPipeline.d.ts +0 -6
  396. package/dist/wgpuPipeline.d.ts.map +0 -1
  397. package/dist/wgpuPipeline.js +0 -33
  398. package/dist/wgpuPipeline.js.map +0 -1
  399. package/dist/wgpuSurface.d.ts +0 -6
  400. package/dist/wgpuSurface.d.ts.map +0 -1
  401. package/dist/wgpuSurface.js +0 -155
  402. package/dist/wgpuSurface.js.map +0 -1
  403. package/src/wgpuAntialias.test.ts +0 -239
  404. package/src/wgpuElement.test.ts +0 -145
  405. package/src/wgpuMaterialRegistry.test.ts +0 -100
  406. package/src/wgpuPipeline.test.ts +0 -62
  407. package/src/wgpuSurface.test.ts +0 -141
@@ -0,0 +1,55 @@
1
+ export type { HostWgpuCapabilities } from './types/Host.ts';
2
+ export type { WgpuAdapterCapabilities } from './types/WgpuAdapterCapabilities.ts';
3
+ export type { WgpuCompressedTextureDecoder } from '@flighthq/render-wgpu/compressed-texture-decoder-contract';
4
+ export type { WgpuCompressedTextureSupport } from './types/WgpuCompressedTextureSupport.ts';
5
+ export type { WgpuCompressedTextureUploader } from './types/WgpuCompressedTextureUploader.ts';
6
+ export type { WgpuColorAdjustmentMaterialFeature, WgpuColorAdjustmentMaterialFeatureGuard, } from './types/WgpuColorAdjustmentMaterialFeature.ts';
7
+ export type { WgpuCustomMaterialShaderSource } from './types/WgpuCustomMaterialShaderSource.ts';
8
+ export type { WgpuDeviceRuntime, WgpuDeviceRuntimeResources } from './types/WgpuDeviceRuntime.ts';
9
+ export type { WgpuDeviceSignals } from './types/WgpuDeviceSignals.ts';
10
+ export type { WgpuDeviceState } from './types/WgpuDeviceState.ts';
11
+ export type { WgpuEffectContext, WgpuEffectRegistration, WgpuEffectResolver, WgpuEffectRunner, } from './types/WgpuEffectState.ts';
12
+ export type { WgpuFullscreenPipeline } from './types/WgpuFullscreenPipeline.ts';
13
+ export type { HostWgpuCapability, WgpuHostAcquisition, WgpuHostAcquisitionOptions, WgpuPresentationSurface, WgpuSurfaceAttachResult, WgpuSurfaceAttachment, } from './types/WgpuHost.ts';
14
+ export type { WgpuMeshMaterialRenderer } from './types/WgpuMeshMaterialRenderer.ts';
15
+ export type { WgpuModifierCompileContext, WgpuModifierContribution, WgpuModifierSnippet, } from './types/WgpuModifierSnippet.ts';
16
+ export type { WgpuParticleResources } from './types/WgpuParticleResources.ts';
17
+ export type { WgpuQuadBatchResources } from './types/WgpuQuadBatchResources.ts';
18
+ export type { WgpuQuadMaterialRenderer } from './types/WgpuQuadMaterialRenderer.ts';
19
+ export type { WgpuRenderOptions } from './types/WgpuRenderOptions.ts';
20
+ export type { WgpuRenderPass, WgpuRenderPassViewport, WgpuSavedPassState } from './types/WgpuRenderPass.ts';
21
+ export type { WgpuBindGroupLayouts, WgpuBitmapShader, WgpuClipContourEntry, WgpuClipContourPipelines, WgpuColorAdjustmentFlush, WgpuMeshInstanceBufferSlot, WgpuOffscreenRenderStateResult, WgpuQuadBatchWriterBufferSlot, WgpuRenderRegistries, WgpuRenderState, WgpuRenderStateRuntime, WgpuScissorRect, WgpuShapeMeshBuffers, WgpuShapeMeshPipeline, WgpuTextureBindings, WgpuTextureEntry, WgpuTextureResource, WgpuTextureSourceTextureEntry, WgpuVideoTextureEntry, } from './types/WgpuRenderState.ts';
22
+ export type { WgpuRenderStateOptions } from './types/WgpuRenderStateOptions.ts';
23
+ export type { WgpuRenderTarget, WgpuRenderTargetPool, WgpuScreenRenderTarget, WgpuScreenRenderTargetOptions, WgpuTextureRenderTarget, } from './types/WgpuRenderTarget.ts';
24
+ export type { WgpuRenderTextureEntry, WgpuRenderTextureExplanation, WgpuRenderTextureGuard, WgpuRenderTexturePool, WgpuRenderTextureStatus, } from './types/WgpuRenderTexture.ts';
25
+ export type { WgpuScene3DPass } from './types/WgpuScene3DRuntime.ts';
26
+ export type { WgpuShapeMesh } from './types/WgpuShapeMesh.ts';
27
+ export type { WgpuSkinningAdapter } from './types/WgpuSkinningAdapter.ts';
28
+ export type { WgpuSurface } from './types/WgpuSurface.ts';
29
+ export type { WgpuTextureResolver } from './types/WgpuTextureResolver.ts';
30
+ export type { WgpuUniformEndiannessExplanation, WgpuUniformEndiannessStatus } from './types/WgpuUniformEndianness.ts';
31
+ export type { WgpuVelocityContext, WgpuVelocityWriter } from './types/WgpuVelocityWriter.ts';
32
+ export type { WgpuAdapter, WgpuPowerPreference, WgpuRequestAdapterOptions } from './types/WgpuAdapter.ts';
33
+ export type { WgpuBindGroup, WgpuBindGroupDescriptor, WgpuBindGroupEntry, WgpuBindingResource, WgpuBufferBinding, } from './types/WgpuBindGroup.ts';
34
+ export { WgpuShaderStage } from './types/WgpuBindGroupLayout.ts';
35
+ export type { WgpuBindGroupLayout, WgpuBindGroupLayoutDescriptor, WgpuBindGroupLayoutEntry, WgpuBufferBindingLayout, WgpuBufferBindingType, WgpuExternalTextureBindingLayout, WgpuSamplerBindingLayout, WgpuSamplerBindingType, WgpuStorageTextureAccess, WgpuStorageTextureBindingLayout, WgpuTextureBindingLayout, WgpuTextureSampleType, } from './types/WgpuBindGroupLayout.ts';
36
+ export { WgpuBufferUsage, WgpuMapMode } from './types/WgpuBuffer.ts';
37
+ export type { WgpuBuffer, WgpuBufferDescriptor, WgpuBufferMapState, WgpuBufferSource } from './types/WgpuBuffer.ts';
38
+ export type { WgpuCanvasAlphaMode, WgpuCanvasConfiguration, WgpuCanvasContext } from './types/WgpuCanvasContext.ts';
39
+ export type { WgpuCommandBuffer, WgpuCommandBufferDescriptor } from './types/WgpuCommandBuffer.ts';
40
+ export type { WgpuCommandEncoder, WgpuCommandEncoderDescriptor } from './types/WgpuCommandEncoder.ts';
41
+ export type { WgpuDevice, WgpuDeviceDescriptor, WgpuDeviceLostInfo, WgpuDeviceLostReason, WgpuFeatureName, WgpuQueueDescriptor, WgpuSupportedFeatures, WgpuSupportedLimits, } from './types/WgpuDevice.ts';
42
+ export type { WgpuCopyExternalImageDestInfo, WgpuCopyExternalImageSourceInfo, WgpuExternalImageSource, WgpuExternalTexture, WgpuOrigin2D, WgpuOrigin2DDict, } from './types/WgpuExternalImageSource.ts';
43
+ export type { WgpuGpu } from './types/WgpuGpu.ts';
44
+ export type { WgpuPipelineLayout, WgpuPipelineLayoutDescriptor } from './types/WgpuPipelineLayout.ts';
45
+ export type { WgpuQueue } from './types/WgpuQueue.ts';
46
+ export type { WgpuColor, WgpuColorDict, WgpuLoadOp, WgpuRenderPassColorAttachment, WgpuRenderPassDepthStencilAttachment, WgpuRenderPassDescriptor, WgpuRenderPassEncoder, WgpuStoreOp, } from './types/WgpuRenderPassEncoder.ts';
47
+ export { WgpuColorWrite } from './types/WgpuRenderPipeline.ts';
48
+ export type { WgpuBlendComponent, WgpuBlendFactor, WgpuBlendOperation, WgpuBlendState, WgpuColorTargetState, WgpuCullMode, WgpuDepthStencilState, WgpuFragmentState, WgpuFrontFace, WgpuIndexFormat, WgpuMultisampleState, WgpuPrimitiveState, WgpuPrimitiveTopology, WgpuProgrammableStage, WgpuRenderPipeline, WgpuRenderPipelineDescriptor, WgpuStencilFaceState, WgpuStencilOperation, WgpuVertexAttribute, WgpuVertexBufferLayout, WgpuVertexFormat, WgpuVertexState, WgpuVertexStepMode, } from './types/WgpuRenderPipeline.ts';
49
+ export type { WgpuAddressMode, WgpuCompareFunction, WgpuFilterMode, WgpuMipmapFilterMode, WgpuSampler, WgpuSamplerDescriptor, } from './types/WgpuSampler.ts';
50
+ export type { WgpuShaderModule, WgpuShaderModuleDescriptor } from './types/WgpuShaderModule.ts';
51
+ export { WgpuTextureUsage } from './types/WgpuTexture.ts';
52
+ export type { WgpuExtent3D, WgpuExtent3DDict, WgpuOrigin3D, WgpuOrigin3DDict, WgpuTexelCopyBufferInfo, WgpuTexelCopyBufferLayout, WgpuTexelCopyTextureInfo, WgpuTexture, WgpuTextureAspect, WgpuTextureDescriptor, WgpuTextureDimension, } from './types/WgpuTexture.ts';
53
+ export type { WgpuTextureFormat } from './types/WgpuTextureFormat.ts';
54
+ export type { WgpuTextureView, WgpuTextureViewDescriptor, WgpuTextureViewDimension } from './types/WgpuTextureView.ts';
55
+ //# sourceMappingURL=contract.render-wgpu-types.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"contract.render-wgpu-types.d.ts","sourceRoot":"","sources":["../src/contract.render-wgpu-types.ts"],"names":[],"mappings":"AAAA,YAAY,EAAE,oBAAoB,EAAE,MAAM,iBAAiB,CAAC;AAC5D,YAAY,EAAE,uBAAuB,EAAE,MAAM,oCAAoC,CAAC;AAClF,YAAY,EAAE,4BAA4B,EAAE,MAAM,2DAA2D,CAAC;AAC9G,YAAY,EAAE,4BAA4B,EAAE,MAAM,yCAAyC,CAAC;AAC5F,YAAY,EAAE,6BAA6B,EAAE,MAAM,0CAA0C,CAAC;AAC9F,YAAY,EACV,kCAAk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B,gBAAgB,EAChB,eAAe,EACf,kBAAkB,GACnB,MAAM,+BAA+B,CAAC;AACvC,YAAY,EACV,eAAe,EACf,mBAAmB,EACnB,cAAc,EACd,oBAAoB,EACpB,WAAW,EACX,qBAAqB,GACtB,MAAM,wBAAwB,CAAC;AAChC,YAAY,EAAE,gBAAgB,EAAE,0BAA0B,EAAE,MAAM,6BAA6B,CAAC;AAChG,OAAO,EAAE,gBAAgB,EAAE,MAAM,wBAAwB,CAAC;AAC1D,YAAY,EACV,YAAY,EACZ,gBAAgB,EAChB,YAAY,EACZ,gBAAgB,EAChB,uBAAuB,EACvB,yBAAyB,EACzB,wBAAwB,EACxB,WAAW,EACX,iBAAiB,EACjB,qBAAqB,EACrB,oBAAoB,GACrB,MAAM,wBAAwB,CAAC;AAChC,YAAY,EAAE,iBAAiB,EAAE,MAAM,8BAA8B,CAAC;AACtE,YAAY,EAAE,eAAe,EAAE,yBAAyB,EAAE,wBAAwB,EAAE,MAAM,4BAA4B,CAAC"}
@@ -0,0 +1,5 @@
1
+ export { WgpuShaderStage } from './types/WgpuBindGroupLayout.js';
2
+ export { WgpuBufferUsage, WgpuMapMode } from './types/WgpuBuffer.js';
3
+ export { WgpuColorWrite } from './types/WgpuRenderPipeline.js';
4
+ export { WgpuTextureUsage } from './types/WgpuTexture.js';
5
+ //# sourceMappingURL=contract.render-wgpu-types.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"contract.render-wgpu-types.js","sourceRoot":"","sources":["../src/contract.render-wgpu-types.ts"],"names":[],"mappings":"AA0FA,OAAO,EAAE,eAAe,EAAE,MAAM,gCAAgC,CAAC;AAejE,OAAO,EAAE,eAAe,EAAE,WAAW,EAAE,MAAM,uBAAuB,CAAC;AAoCrE,OAAO,EAAE,cAAc,EAAE,MAAM,+BAA+B,CAAC;AAmC/D,OAAO,EAAE,gBAAgB,EAAE,MAAM,wBAAwB,CAAC"}
@@ -1,4 +1,5 @@
1
- import type { WgpuRenderState } from '@flighthq/types/contract';
1
+ import type { LogState } from '@flighthq/log/contract';
2
+ import type { WgpuRenderState } from './contract.render-wgpu-types.ts';
2
3
  export declare function areWgpuTextureResolverGuardsEnabled(state: WgpuRenderState): boolean;
3
- export declare function enableWgpuTextureResolverGuards(state: WgpuRenderState): void;
4
+ export declare function enableWgpuTextureResolverGuards(state: WgpuRenderState, logState: LogState | null): void;
4
5
  //# sourceMappingURL=enableWgpuTextureResolverGuards.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"enableWgpuTextureResolverGuards.d.ts","sourceRoot":"","sources":["../src/enableWgpuTextureResolverGuards.ts"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,0BAA0B,CAAC;AAKhE,wBAAgB,mCAAmC,CAAC,KAAK,EAAE,eAAe,GAAG,OAAO,CAEnF;AAED,wBAAgB,+BAA+B,CAAC,KAAK,EAAE,eAAe,GAAG,IAAI,CAI5E"}
1
+ {"version":3,"file":"enableWgpuTextureResolverGuards.d.ts","sourceRoot":"","sources":["../src/enableWgpuTextureResolverGuards.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,QAAQ,EAAE,MAAM,wBAAwB,CAAC;AAIvD,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,iCAAiC,CAAC;AAGvE,wBAAgB,mCAAmC,CAAC,KAAK,EAAE,eAAe,GAAG,OAAO,CAEnF;AAED,wBAAgB,+BAA+B,CAAC,KAAK,EAAE,eAAe,EAAE,QAAQ,EAAE,QAAQ,GAAG,IAAI,GAAG,IAAI,CAIvG"}
@@ -1,17 +1,20 @@
1
1
  import { logOnce } from '@flighthq/log/contract';
2
- import { areRenderRegistryGuardsEnabled, enableRenderRegistryGuards } from '@flighthq/render/contract';
3
- import { LogLevel } from '@flighthq/types/contract';
4
- import { getWgpuRenderStateRuntime } from './wgpuRenderState';
2
+ import { LogLevel } from '@flighthq/log/contract';
3
+ import { areRenderRegistriesGuardsEnabled, enableRenderRegistriesGuards } from '@flighthq/render/contract';
4
+ import { getWgpuRenderStateRuntime } from './wgpuRenderState.js';
5
5
  export function areWgpuTextureResolverGuardsEnabled(state) {
6
- return areRenderRegistryGuardsEnabled(state);
6
+ return areRenderRegistriesGuardsEnabled(state);
7
7
  }
8
- export function enableWgpuTextureResolverGuards(state) {
9
- enableRenderRegistryGuards(state);
8
+ export function enableWgpuTextureResolverGuards(state, logState) {
9
+ enableRenderRegistriesGuards(state, logState);
10
10
  const runtime = getWgpuRenderStateRuntime(state);
11
- runtime.mipmapDegradedGuard = warnOnMipmapDegradation;
11
+ runtime.mipmapDegradedGuard = (degradedState) => warnOnMipmapDegradation(logState, degradedState);
12
12
  }
13
- function warnOnMipmapDegradation(state) {
14
- logOnce('render-wgpu:mipmap-degraded', LogLevel.Warn, {
13
+ function warnOnMipmapDegradation(logState, state) {
14
+ if (logState === null)
15
+ return;
16
+ // The render guards take no clock, so the warning is stamped at time zero.
17
+ logOnce(logState, 0, 'render-wgpu:mipmap-degraded', LogLevel.Warn, {
15
18
  message: 'bindWgpuBitmapTexture: mipmaps requested but no WGPU mipmap generator registered — texture allocated with a single mip level (bilinear fallback). Call registerWgpuMipmapGeneration(state) to enable trilinear/anisotropic sampling.',
16
19
  state,
17
20
  }, 'render-wgpu');
@@ -1 +1 @@
1
- {"version":3,"file":"enableWgpuTextureResolverGuards.js","sourceRoot":"","sources":["../src/enableWgpuTextureResolverGuards.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,OAAO,EAAE,MAAM,wBAAwB,CAAC;AACjD,OAAO,EAAE,8BAA8B,EAAE,0BAA0B,EAAE,MAAM,2BAA2B,CAAC;AAEvG,OAAO,EAAE,QAAQ,EAAE,MAAM,0BAA0B,CAAC;AAEpD,OAAO,EAAE,yBAAyB,EAAE,MAAM,mBAAmB,CAAC;AAE9D,MAAM,UAAU,mCAAmC,CAAC,KAAsB;IACxE,OAAO,8BAA8B,CAAC,KAAK,CAAC,CAAC;AAC/C,CAAC;AAED,MAAM,UAAU,+BAA+B,CAA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OAAsO;QACxO,KAAK;KACN,EACD,aAAa,CACd,CAAC;AACJ,CAAC"}
@@ -1,3 +1,4 @@
1
- import type { TextureLike, TextureResolutionExplanation, WgpuRenderState } from '@flighthq/types/contract';
1
+ import type { TextureLike, TextureResolutionExplanation } from '@flighthq/texture/contract';
2
+ import type { WgpuRenderState } from './contract.render-wgpu-types.ts';
2
3
  export declare function explainWgpuTextureResolution(state: WgpuRenderState, texture: Readonly<TextureLike>): TextureResolutionExplanation;
3
4
  //# sourceMappingURL=explainWgpuTextureResolution.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"explainWgpuTextureResolution.d.ts","sourceRoot":"","sources":["../src/explainWgpuTextureResolution.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,WAAW,EAAE,4BAA4B,EAAE,eAAe,EAAE,MAAM,0BAA0B,CAAC;AAK3G,wBAAgB,4BAA4B,CAC1C,KAAK,EAAE,eAAe,EACtB,OAAO,EAAE,QAAQ,CAAC,WAAW,CAAC,GAC7B,4BAA4B,CAU9B"}
1
+ {"version":3,"file":"explainWgpuTextureResolution.d.ts","sourceRoot":"","sources":["../src/explainWgpuTextureResolution.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,WAAW,EAAE,4BAA4B,EAAE,MAAM,4BAA4B,CAAC;AAE5F,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,iCAAiC,CAAC;AAGvE,wBAAgB,4BAA4B,CAC1C,KAAK,EAAE,eAAe,EACtB,OAAO,EAAE,QAAQ,CAAC,WAAW,CAAC,GAC7B,4BAA4B,CAO9B"}
@@ -1,15 +1,12 @@
1
1
  import { getTextureSourceKind } from '@flighthq/texture/contract';
2
- import { RegistryEntryState } from '@flighthq/types/contract';
3
- import { getWgpuRenderStateRuntime } from './wgpuRenderState';
2
+ import { getWgpuRenderStateRuntime } from './wgpuRenderState.js';
4
3
  export function explainWgpuTextureResolution(state, texture) {
5
4
  const kind = getTextureSourceKind(texture);
6
5
  if (kind === null)
7
6
  return { kind, status: 'missing-kind' };
8
7
  return {
9
8
  kind,
10
- status: getWgpuRenderStateRuntime(state).registries.textureResolvers.entries.get(kind)?.state === RegistryEntryState.Bound
11
- ? 'registered'
12
- : 'missing-resolver',
9
+ status: getWgpuRenderStateRuntime(state).registries.textureResolvers.has(kind) ? 'registered' : 'missing-resolver',
13
10
  };
14
11
  }
15
12
  //# sourceMappingURL=explainWgpuTextureResolution.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"explainWgpuTextureResolution.js","sourceRoot":"","sources":["../src/explainWgpuTextureResolution.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,oBAAoB,EAAE,MAAM,4BAA4B,CAAC;AAElE,OAAO,EAAE,kBAAkB,EAAE,MAAM,0BAA0B,CAAC;AAE9D,OAAO,EAAE,yBAAyB,EAAE,MAAM,mBAAmB,CAAC;AAE9D,MAAM,UAAU,4BAA4B,CAC1C,KAAsB,EACtB,OAA8B;IAE9B,MAAM,IAAI,GAAG,oBAAoB,CAAC,OAAO,CAAC,CAAC;IAC3C,IAAI,IAAI,KAAK,IAAI;QAAE,OAAO,EAAE,IAAI,EAAE,MAAM,EAAE,cAAc,EAAE,CAAC;IAC3D,OAAO;QACL,IAAI;QACJ,MAAM,EACJ,yBAAyB,CAAC,KAAK,CAAC,CAAC,UAAU,CAAC,gBAAgB,CAAC,OAAO,CAAC,GAAG,CAAC,IAAI,CAAC,EAAE,KAAK,KAAK,kBAAkB,CAAC,KAAK;YAChH,CAAC,CAAC,YAAY;YACd,CAAC,CAAC,kBAAkB;KACzB,CAAC;AACJ,CAAC"}
1
+ {"version":3,"file":"explainWgpuTextureResolution.js","sourceRoot":"","sources":["../src/explainWgpuTextureResolution.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,oBAAoB,EAAE,MAAM,4BAA4B,CAAC;AAIlE,OAAO,EAAE,yBAAyB,EAAE,MAAM,sBAAsB,CAAC;AAEjE,MAAM,UAAU,4BAA4B,CAC1C,KAAsB,EACtB,OAA8B;IAE9B,MAAM,IAAI,GAAG,oBAAoB,CAAC,OAAO,CAAC,CAAC;IAC3C,IAAI,IAAI,KAAK,IAAI;QAAE,OAAO,EAAE,IAAI,EAAE,MAAM,EAAE,cAAc,EAAE,CAAC;IAC3D,OAAO;QACL,IAAI;QACJ,MAAM,EAAE,yBAAyB,CAAC,KAAK,CAAC,CAAC,UAAU,CAAC,gBAAgB,CAAC,GAAG,CAAC,IAAI,CAAC,CAAC,CAAC,CAAC,YAAY,CAAC,CAAC,CAAC,kBAAkB;KACnH,CAAC;AACJ,CAAC"}
@@ -0,0 +1,3 @@
1
+ import type { WgpuUniformEndiannessExplanation } from './contract.render-wgpu-types.ts';
2
+ export declare function explainWgpuUniformEndianness(): WgpuUniformEndiannessExplanation;
3
+ //# sourceMappingURL=explainWgpuUniformEndianness.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"explainWgpuUniformEndianness.d.ts","sourceRoot":"","sources":["../src/explainWgpuUniformEndianness.ts"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,gCAAgC,EAAE,MAAM,iCAAiC,CAAC;AAOxF,wBAAgB,4BAA4B,IAAI,gCAAgC,CAG/E"}
@@ -0,0 +1,25 @@
1
+ // WGPU uniform buffers use a Uint32Array/Int32Array view over a Float32Array's backing buffer to
2
+ // write integer values (boolean flags, enum selects) alongside float uniforms. The two views share
3
+ // the same ArrayBuffer, so the byte layout is host-determined. This has been validated on
4
+ // little-endian hosts only; a big-endian or unknown host may still produce correct output (CPU and
5
+ // GPU share byte order on the same hardware), but the result is unvalidated.
6
+ export function explainWgpuUniformEndianness() {
7
+ const endianness = probeEndianness();
8
+ return { endianness, status: endianness === 'little' ? 'validated' : 'unvalidated' };
9
+ }
10
+ function probeEndianness() {
11
+ try {
12
+ const buf = new ArrayBuffer(2);
13
+ new Uint16Array(buf)[0] = 0x0102;
14
+ const bytes = new Uint8Array(buf);
15
+ if (bytes[0] === 0x01)
16
+ return 'big';
17
+ if (bytes[0] === 0x02)
18
+ return 'little';
19
+ }
20
+ catch {
21
+ // ArrayBuffer unavailable.
22
+ }
23
+ return 'unknown';
24
+ }
25
+ //# sourceMappingURL=explainWgpuUniformEndianness.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"explainWgpuUniformEndianness.js","sourceRoot":"","sources":["../src/explainWgpuUniformEndianness.ts"],"names":[],"mappings":"AAIA,iGAAiG;AACjG,mGAAmG;AACnG,0FAA0F;AAC1F,mGAAmG;AACnG,6EAA6E;AAC7E,MAAM,UAAU,4BAA4B;IAC1C,MAAM,UAAU,GAAG,eAAe,EAAE,CAAC;IACrC,OAAO,EAAE,UAAU,EAAE,MAAM,EAAE,UAAU,KAAK,QAAQ,CAAC,CAAC,CAAC,WAAW,CAAC,CAAC,CAAC,aAAa,EAAE,CAAC;AACvF,CAAC;AAED,SAAS,eAAe;IACtB,IAAI,CAAC;QACH,MAAM,GAAG,GAAG,IAAI,WAAW,CAAC,CAAC,CAAC,CAAC;QAC/B,IAAI,WAAW,CAAC,GAAG,CAAC,CAAC,CAAC,CAAC,GAAG,MAAM,CAAC;QACjC,MAAM,KAAK,GAAG,IAAI,UAAU,CAAC,GAAG,CAAC,CAAC;QAClC,IAAI,KAAK,CAAC,CAAC,CAAC,KAAK,IAAI;YAAE,OAAO,KAAK,CAAC;QACpC,IAAI,KAAK,CAAC,CAAC,CAAC,KAAK,IAAI;YAAE,OAAO,QAAQ,CAAC;IACzC,CAAC;IAAC,MAAM,CAAC;QACP,2BAA2B;IAC7B,CAAC;IACD,OAAO,SAAS,CAAC;AACnB,CAAC"}
package/dist/index.d.ts CHANGED
@@ -1,2 +1,21 @@
1
- export { acquireWgpuRenderTexture, beginWgpuFrame, beginWgpuRenderPass, bindWgpuRenderTexture, createBitmapFromWgpuRenderState, createExternalWgpuTexture, createWgpuCanvasElement, createWgpuRenderSurface, createWgpuOffscreenRenderState, createWgpuPipeline, createWgpuAcquisitionFromCanvasElement, createWgpuDeviceState, createWgpuRenderState, createWgpuRenderStateFromCanvasElement, disposeWgpuDeviceSignals, enableWgpuDeviceSignals, getWgpuDeviceLoss, isWgpuDeviceLost, releaseWgpuAcquisition, createWgpuRenderTexturePool, createWgpuRenderTarget, destroyWgpuRenderTexture, destroyWgpuRenderTexturePool, destroyWgpuRenderState, disposeExternalWgpuTexture, enableWgpuBlendModeSupport, enableWgpuFrameCapture, enableWgpuTextureResolverGuards, endWgpuRenderPass, explainWgpuRenderTexture, explainWgpuTextureResolution, isWgpuRenderTextureReady, registerWgpuBitmapTextureResolver, registerWgpuCompressedImageTextureResolver, registerWgpuImageTextureResolver, registerWgpuRenderTextureResolver, registerStandardWgpuTextureResolvers, registerWgpuTextureResolver, registerWgpuCompressedTextureDecoder, registerWgpuCompressedTextureUpload, registerWgpuMipmapGeneration, releaseWgpuRenderTexture, renderIntoWgpuRenderTexture, renderWgpuBackground, resolveWgpuApplyBlendMode, resolveWgpuTexture, resolveWgpuSmoothingBindGroup, setWgpuRenderTransform2D, submitWgpuRenderPass, withWgpuRenderTextures, withWgpuFrameBorrow, } from './contract';
1
+ export { WgpuBufferUsage, WgpuColorWrite, WgpuMapMode, WgpuShaderStage, WgpuTextureUsage } from './contract.ts';
2
+ export { enableWgpuTextureResolverGuards } from './enableWgpuTextureResolverGuards.ts';
3
+ export * from './explainWgpuTextureResolution.ts';
4
+ export { explainWgpuUniformEndianness } from './explainWgpuUniformEndianness.ts';
5
+ export { registerWgpuCompressedTextureDecoder, registerWgpuCompressedTextureUpload } from './wgpuCompressedTexture.ts';
6
+ export { disposeWgpuDeviceSignals, enableWgpuDeviceSignals, getWgpuDeviceLoss, isWgpuDeviceLost, } from './wgpuDeviceLoss.ts';
7
+ export { enableWgpuBlendModeSupport } from './wgpuDraw.ts';
8
+ export { createExternalWgpuTexture, disposeExternalWgpuTexture } from './wgpuExternalTexture.ts';
9
+ export { beginWgpuFrame, submitWgpuFrame, withWgpuFrameBorrow } from './wgpuFrame.ts';
10
+ export { registerWgpuMipmapGeneration } from './wgpuMipmap.ts';
11
+ export * from './wgpuQuadMaterialRegistry.ts';
12
+ export { beginWgpuRenderPass, endWgpuRenderPass } from './wgpuRenderPass.ts';
13
+ export { buildWgpuRenderRegistries, createWgpuAcquisition, createWgpuDeviceState, createWgpuOffscreenRenderState, createWgpuRenderState, destroyWgpuRenderState, releaseWgpuAcquisition, } from './wgpuRenderState.ts';
14
+ export { destroyWgpuRenderTexture, explainWgpuRenderTexture, isWgpuRenderTextureReady, renderIntoWgpuRenderTexture, } from './wgpuRenderTexture.ts';
15
+ export { acquireWgpuRenderTexture, createWgpuRenderTexturePool, destroyWgpuRenderTexturePool, releaseWgpuRenderTexture, withWgpuRenderTextures, } from './wgpuRenderTexturePool.ts';
16
+ export * from './wgpuScreenAntialias.ts';
17
+ export { createBitmapFromWgpuScreenRenderTarget, enableWgpuScreenRenderTargetCapture } from './wgpuScreenCapture.ts';
18
+ export { createWgpuScreenRenderTarget, destroyWgpuScreenRenderTarget } from './wgpuScreenRenderTarget.ts';
19
+ export { createWgpuTextureRenderTarget, destroyWgpuTextureRenderTarget } from './wgpuTextureRenderTarget.ts';
20
+ export * from './wgpuTextureResolver.ts';
2
21
  //# sourceMappingURL=index.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,wBAAwB,EACxB,cAAc,EACd,mBAAmB,EACnB,qBAAqB,EACrB,+BAA+B,EAC/B,yBAAyB,EACzB,uBAAuB,EACvB,uBAAuB,EACvB,8BAA8B,EAC9B,kBAAkB,EAClB,sCAAsC,EACtC,qBAAqB,EACrB,qBAAqB,EACrB,sCAAsC,EACtC,wBAAwB,EACxB,uBAAuB,EACvB,iBAAiB,EACjB,gBAAgB,EAChB,sBAAsB,EACtB,2BAA2B,EAC3B,sBAAsB,EACtB,wBAAwB,EACxB,4BAA4B,EAC5B,sBAAsB,EACtB,0BAA0B,EAC1B,0BAA0B,EAC1B,sBAAsB,EACtB,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qB,EACrB,8BAA8B,EAC9B,qBAAqB,EACrB,sBAAsB,EACtB,sBAAsB,GACvB,MAAM,sBAAsB,CAAC;AAC9B,OAAO,EACL,wBAAwB,EACxB,wBAAwB,EACxB,wBAAwB,EACxB,2BAA2B,GAC5B,MAAM,wBAAwB,CAAC;AAChC,OAAO,EACL,wBAAwB,EACxB,2BAA2B,EAC3B,4BAA4B,EAC5B,wBAAwB,EACxB,sBAAsB,GACvB,MAAM,4BAA4B,CAAC;AACpC,cAAc,0BAA0B,CAAC;AACzC,OAAO,EAAE,sCAAsC,EAAE,mCAAmC,EAAE,MAAM,wBAAwB,CAAC;AACrH,OAAO,EAAE,4BAA4B,EAAE,6BAA6B,EAAE,MAAM,6BAA6B,CAAC;AAC1G,OAAO,EAAE,6BAA6B,EAAE,8BAA8B,EAAE,MAAM,8BAA8B,CAAC;AAC7G,cAAc,0BAA0B,CAAC"}
package/dist/index.js CHANGED
@@ -1,2 +1,21 @@
1
- export { acquireWgpuRenderTexture, beginWgpuFrame, beginWgpuRenderPass, bindWgpuRenderTexture, createBitmapFromWgpuRenderState, createExternalWgpuTexture, createWgpuCanvasElement, createWgpuRenderSurface, createWgpuOffscreenRenderState, createWgpuPipeline, createWgpuAcquisitionFromCanvasElement, createWgpuDeviceState, createWgpuRenderState, createWgpuRenderStateFromCanvasElement, disposeWgpuDeviceSignals, enableWgpuDeviceSignals, getWgpuDeviceLoss, isWgpuDeviceLost, releaseWgpuAcquisition, createWgpuRenderTexturePool, createWgpuRenderTarget, destroyWgpuRenderTexture, destroyWgpuRenderTexturePool, destroyWgpuRenderState, disposeExternalWgpuTexture, enableWgpuBlendModeSupport, enableWgpuFrameCapture, enableWgpuTextureResolverGuards, endWgpuRenderPass, explainWgpuRenderTexture, explainWgpuTextureResolution, isWgpuRenderTextureReady, registerWgpuBitmapTextureResolver, registerWgpuCompressedImageTextureResolver, registerWgpuImageTextureResolver, registerWgpuRenderTextureResolver, registerStandardWgpuTextureResolvers, registerWgpuTextureResolver, registerWgpuCompressedTextureDecoder, registerWgpuCompressedTextureUpload, registerWgpuMipmapGeneration, releaseWgpuRenderTexture, renderIntoWgpuRenderTexture, renderWgpuBackground, resolveWgpuApplyBlendMode, resolveWgpuTexture, resolveWgpuSmoothingBindGroup, setWgpuRenderTransform2D, submitWgpuRenderPass, withWgpuRenderTextures, withWgpuFrameBorrow, } from './contract';
1
+ export { WgpuBufferUsage, WgpuColorWrite, WgpuMapMode, WgpuShaderStage, WgpuTextureUsage } from './contract.js';
2
+ export { enableWgpuTextureResolverGuards } from './enableWgpuTextureResolverGuards.js';
3
+ export * from './explainWgpuTextureResolution.js';
4
+ export { explainWgpuUniformEndianness } from './explainWgpuUniformEndianness.js';
5
+ export { registerWgpuCompressedTextureDecoder, registerWgpuCompressedTextureUpload } from './wgpuCompressedTexture.js';
6
+ export { disposeWgpuDeviceSignals, enableWgpuDeviceSignals, getWgpuDeviceLoss, isWgpuDeviceLost, } from './wgpuDeviceLoss.js';
7
+ export { enableWgpuBlendModeSupport } from './wgpuDraw.js';
8
+ export { createExternalWgpuTexture, disposeExternalWgpuTexture } from './wgpuExternalTexture.js';
9
+ export { beginWgpuFrame, submitWgpuFrame, withWgpuFrameBorrow } from './wgpuFrame.js';
10
+ export { registerWgpuMipmapGeneration } from './wgpuMipmap.js';
11
+ export * from './wgpuQuadMaterialRegistry.js';
12
+ export { beginWgpuRenderPass, endWgpuRenderPass } from './wgpuRenderPass.js';
13
+ export { buildWgpuRenderRegistries, createWgpuAcquisition, createWgpuDeviceState, createWgpuOffscreenRenderState, createWgpuRenderState, destroyWgpuRenderState, releaseWgpuAcquisition, } from './wgpuRenderState.js';
14
+ export { destroyWgpuRenderTexture, explainWgpuRenderTexture, isWgpuRenderTextureReady, renderIntoWgpuRenderTexture, } from './wgpuRenderTexture.js';
15
+ export { acquireWgpuRenderTexture, createWgpuRenderTexturePool, destroyWgpuRenderTexturePool, releaseWgpuRenderTexture, withWgpuRenderTextures, } from './wgpuRenderTexturePool.js';
16
+ export * from './wgpuScreenAntialias.js';
17
+ export { createBitmapFromWgpuScreenRenderTarget, enableWgpuScreenRenderTargetCapture } from './wgpuScreenCapture.js';
18
+ export { createWgpuScreenRenderTarget, destroyWgpuScreenRenderTarget } from './wgpuScreenRenderTarget.js';
19
+ export { createWgpuTextureRenderTarget, destroyWgpuTextureRenderTarget } from './wgpuTextureRenderTarget.js';
20
+ export * from './wgpuTextureResolver.js';
2
21
  //# sourceMappingURL=index.js.map
package/dist/index.js.map CHANGED
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,wBAAwB,EACxB,cAAc,EACd,mBAAmB,EACnB,qBAAqB,EACrB,+BAA+B,EAC/B,yBAAyB,EACzB,uBAAuB,EACvB,uBAAuB,EACvB,8BAA8B,EAC9B,kBAAkB,EAClB,sCAAsC,EACtC,qBAAqB,EACrB,qBAAqB,EACrB,sCAAsC,EACtC,wBAAwB,EACxB,uBAAuB,EACvB,iBAAiB,EACjB,gBAAgB,EAChB,sBAAsB,EACtB,2BAA2B,EAC3B,sBAAsB,EACtB,wBAAwB,EACxB,4BAA4B,EAC5B,sBAAsB,EACtB,0BAA0B,EAC1B,0BAA0B,EAC1B,sBAAsB,EACtB,+BAA+B,EAC/B,iBAAiB,EACjB,wBAAwB,EACxB,4BAA4B,EAC5B,wBAAwB,EACxB,iCAAiC,EACjC,0CAA0C,EAC1C,gCAAgC,EAChC,iCAAiC,EACjC,oCAAoC,EACpC,2BAA2B,EAC3B,oCAAoC,EACpC,mCAAmC,EACnC,4BAA4B,EAC5B,wBAAwB,EACxB,2BAA2B,EAC3B,oBAAoB,EACpB,yBAAyB,EACzB,kBAAkB,EAClB,6BAA6B,EAC7B,wBAAwB,EACxB,oBAAoB,EACpB,sBAAsB,EACtB,mBAAmB,GACpB,MAAM,YAAY,CAAC"}
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":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MAAM,6BAA6B,CAAC;AAC1G,OAAO,EAAE,6BAA6B,EAAE,8BAA8B,EAAE,MAAM,8BAA8B,CAAC;AAC7G,cAAc,0BAA0B,CAAC"}
@@ -0,0 +1,5 @@
1
+ import type { HostWgpuCapability } from './WgpuHost.ts';
2
+ export interface HostWgpuCapabilities {
3
+ readonly context?: HostWgpuCapability;
4
+ }
5
+ //# sourceMappingURL=Host.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"Host.d.ts","sourceRoot":"","sources":["../../src/types/Host.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,kBAAkB,EAAE,MAAM,eAAe,CAAC;AAExD,MAAM,WAAW,oBAAoB;IACnC,QAAQ,CAAC,OAAO,CAAC,EAAE,kBAAkB,CAAC;CACvC"}
@@ -0,0 +1,2 @@
1
+ export {};
2
+ //# sourceMappingURL=Host.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"Host.js","sourceRoot":"","sources":["../../src/types/Host.ts"],"names":[],"mappings":""}
@@ -0,0 +1,14 @@
1
+ import type { WgpuDevice, WgpuDeviceDescriptor, WgpuSupportedFeatures, WgpuSupportedLimits } from './WgpuDevice.ts';
2
+ export interface WgpuAdapter {
3
+ readonly features: WgpuSupportedFeatures;
4
+ readonly limits: WgpuSupportedLimits;
5
+ requestDevice(descriptor?: Readonly<WgpuDeviceDescriptor>): Promise<WgpuDevice>;
6
+ }
7
+ export type WgpuPowerPreference = 'high-performance' | 'low-power';
8
+ export interface WgpuRequestAdapterOptions {
9
+ featureLevel?: string;
10
+ forceFallbackAdapter?: boolean;
11
+ powerPreference?: WgpuPowerPreference;
12
+ xrCompatible?: boolean;
13
+ }
14
+ //# sourceMappingURL=WgpuAdapter.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"WgpuAdapter.d.ts","sourceRoot":"","sources":["../../src/types/WgpuAdapter.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,UAAU,EAAE,oBAAoB,EAAE,qBAAqB,EAAE,mBAAmB,EAAE,MAAM,iBAAiB,CAAC;AAEpH,MAAM,WAAW,WAAW;IAC1B,QAAQ,CAAC,QAAQ,EAAE,qBAAqB,CAAC;IACzC,QAAQ,CAAC,MAAM,EAAE,mBAAmB,CAAC;IACrC,aAAa,CAAC,UAAU,CAAC,EAAE,QAAQ,CAAC,oBAAoB,CAAC,GAAG,OAAO,CAAC,UAAU,CAAC,CAAC;CACjF;AAED,MAAM,MAAM,mBAAmB,GAAG,kBAAkB,GAAG,WAAW,CAAC;AAEnE,MAAM,WAAW,yBAAyB;IACxC,YAAY,CAAC,EAAE,MAAM,CAAC;IACtB,oBAAoB,CAAC,EAAE,OAAO,CAAC;IAC/B,eAAe,CAAC,EAAE,mBAAmB,CAAC;IACtC,YAAY,CAAC,EAAE,OAAO,CAAC;CACxB"}
@@ -0,0 +1,2 @@
1
+ export {};
2
+ //# sourceMappingURL=WgpuAdapter.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"WgpuAdapter.js","sourceRoot":"","sources":["../../src/types/WgpuAdapter.ts"],"names":[],"mappings":""}
@@ -0,0 +1,7 @@
1
+ export interface WgpuAdapterCapabilities {
2
+ supportsFloat32Filterable: boolean;
3
+ supportsTimestampQuery: boolean;
4
+ maxSampleCount: number;
5
+ maxTextureDimension2D: number;
6
+ }
7
+ //# sourceMappingURL=WgpuAdapterCapabilities.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"WgpuAdapterCapabilities.d.ts","sourceRoot":"","sources":["../../src/types/WgpuAdapterCapabilities.ts"],"names":[],"mappings":"AAAA,MAAM,WAAW,uBAAuB;IACtC,yBAAyB,EAAE,OAAO,CAAC;IACnC,sBAAsB,EAAE,OAAO,CAAC;IAChC,cAAc,EAAE,MAAM,CAAC;IACvB,qBAAqB,EAAE,MAAM,CAAC;CAC/B"}
@@ -0,0 +1,2 @@
1
+ export {};
2
+ //# sourceMappingURL=WgpuAdapterCapabilities.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"WgpuAdapterCapabilities.js","sourceRoot":"","sources":["../../src/types/WgpuAdapterCapabilities.ts"],"names":[],"mappings":""}
@@ -0,0 +1,23 @@
1
+ import type { WgpuBindGroupLayout } from './WgpuBindGroupLayout.ts';
2
+ import type { WgpuBuffer } from './WgpuBuffer.ts';
3
+ import type { WgpuExternalTexture } from './WgpuExternalImageSource.ts';
4
+ import type { WgpuSampler } from './WgpuSampler.ts';
5
+ import type { WgpuTexture } from './WgpuTexture.ts';
6
+ import type { WgpuTextureView } from './WgpuTextureView.ts';
7
+ export type WgpuBindGroup = GPUBindGroup;
8
+ export interface WgpuBindGroupDescriptor {
9
+ entries: readonly Readonly<WgpuBindGroupEntry>[];
10
+ label?: string;
11
+ layout: WgpuBindGroupLayout;
12
+ }
13
+ export interface WgpuBindGroupEntry {
14
+ binding: number;
15
+ resource: WgpuBindingResource;
16
+ }
17
+ export type WgpuBindingResource = Readonly<WgpuBufferBinding> | WgpuBuffer | WgpuExternalTexture | WgpuSampler | WgpuTexture | WgpuTextureView;
18
+ export interface WgpuBufferBinding {
19
+ buffer: WgpuBuffer;
20
+ offset?: number;
21
+ size?: number;
22
+ }
23
+ //# sourceMappingURL=WgpuBindGroup.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"WgpuBindGroup.d.ts","sourceRoot":"","sources":["../../src/types/WgpuBindGroup.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,mBAAmB,EAAE,MAAM,0BAA0B,CAAC;AACpE,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,iBAAiB,CAAC;AAClD,OAAO,KAAK,EAAE,mBAAmB,EAAE,MAAM,8BAA8B,CAAC;AACxE,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,kBAAkB,CAAC;AACpD,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,kBAAkB,CAAC;AACpD,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,sBAAsB,CAAC;AAI5D,MAAM,MAAM,aAAa,GAAG,YAAY,CAAC;AAEzC,MAAM,WAAW,uBAAuB;IACtC,OAAO,EAAE,SAAS,QAAQ,CAAC,kBAAkB,CAAC,EAAE,CAAC;IACjD,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,MAAM,EAAE,mBAAmB,CAAC;CAC7B;AAED,MAAM,WAAW,kBAAkB;IACjC,OAAO,EAAE,MAAM,CAAC;IAChB,QAAQ,EAAE,mBAAmB,CAAC;CAC/B;AAED,MAAM,MAAM,mBAAmB,GAC3B,QAAQ,CAAC,iBAAiB,CAAC,GAC3B,UAAU,GACV,mBAAmB,GACnB,WAAW,GACX,WAAW,GACX,eAAe,CAAC;AAEpB,MAAM,WAAW,iBAAiB;IAChC,MAAM,EAAE,UAAU,CAAC;IACnB,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB,IAAI,CAAC,EAAE,MAAM,CAAC;CACf"}
@@ -0,0 +1,2 @@
1
+ export {};
2
+ //# sourceMappingURL=WgpuBindGroup.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"WgpuBindGroup.js","sourceRoot":"","sources":["../../src/types/WgpuBindGroup.ts"],"names":[],"mappings":""}
@@ -0,0 +1,45 @@
1
+ import type { WgpuTextureFormat } from './WgpuTextureFormat.ts';
2
+ import type { WgpuTextureViewDimension } from './WgpuTextureView.ts';
3
+ export type WgpuBindGroupLayout = GPUBindGroupLayout;
4
+ export interface WgpuBindGroupLayoutDescriptor {
5
+ entries: readonly Readonly<WgpuBindGroupLayoutEntry>[];
6
+ label?: string;
7
+ }
8
+ export interface WgpuBindGroupLayoutEntry {
9
+ binding: number;
10
+ buffer?: Readonly<WgpuBufferBindingLayout>;
11
+ externalTexture?: Readonly<WgpuExternalTextureBindingLayout>;
12
+ sampler?: Readonly<WgpuSamplerBindingLayout>;
13
+ storageTexture?: Readonly<WgpuStorageTextureBindingLayout>;
14
+ texture?: Readonly<WgpuTextureBindingLayout>;
15
+ visibility: number;
16
+ }
17
+ export interface WgpuBufferBindingLayout {
18
+ hasDynamicOffset?: boolean;
19
+ minBindingSize?: number;
20
+ type?: WgpuBufferBindingType;
21
+ }
22
+ export type WgpuBufferBindingType = 'read-only-storage' | 'storage' | 'uniform';
23
+ export type WgpuExternalTextureBindingLayout = object;
24
+ export interface WgpuSamplerBindingLayout {
25
+ type?: WgpuSamplerBindingType;
26
+ }
27
+ export type WgpuSamplerBindingType = 'comparison' | 'filtering' | 'non-filtering';
28
+ export declare const WgpuShaderStage: {
29
+ readonly COMPUTE: 4;
30
+ readonly FRAGMENT: 2;
31
+ readonly VERTEX: 1;
32
+ };
33
+ export type WgpuStorageTextureAccess = 'read-only' | 'read-write' | 'write-only';
34
+ export interface WgpuStorageTextureBindingLayout {
35
+ access?: WgpuStorageTextureAccess;
36
+ format: WgpuTextureFormat;
37
+ viewDimension?: WgpuTextureViewDimension;
38
+ }
39
+ export interface WgpuTextureBindingLayout {
40
+ multisampled?: boolean;
41
+ sampleType?: WgpuTextureSampleType;
42
+ viewDimension?: WgpuTextureViewDimension;
43
+ }
44
+ export type WgpuTextureSampleType = 'depth' | 'float' | 'sint' | 'uint' | 'unfilterable-float';
45
+ //# sourceMappingURL=WgpuBindGroupLayout.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"WgpuBindGroupLayout.d.ts","sourceRoot":"","sources":["../../src/types/WgpuBindGroupLayout.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,wBAAwB,CAAC;AAChE,OAAO,KAAK,EAAE,wBAAwB,EAAE,MAAM,sBAAsB,CAAC;AAIrE,MAAM,MAAM,mBAAmB,GAAG,kBAAkB,CAAC;AAErD,MAAM,WAAW,6BAA6B;IAC5C,OAAO,EAAE,SAAS,QAAQ,CAAC,wBAAwB,CAAC,EAAE,CAAC;IACvD,KAAK,CAAC,EAAE,MAAM,CAAC;CAChB;AAED,MAAM,WAAW,wBAAwB;IACvC,OAAO,EAAE,MAAM,CAAC;IAChB,MAAM,CAAC,EA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,GAAG,MAAM,GAAG,MAAM,GAAG,oBAAoB,CAAC"}
@@ -0,0 +1,7 @@
1
+ // Shader stages a binding is visible to, combined with `|`. The numeric values are WGPU's own.
2
+ export const WgpuShaderStage = {
3
+ COMPUTE: 0x4,
4
+ FRAGMENT: 0x2,
5
+ VERTEX: 0x1,
6
+ };
7
+ //# sourceMappingURL=WgpuBindGroupLayout.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"WgpuBindGroupLayout.js","sourceRoot":"","sources":["../../src/types/WgpuBindGroupLayout.ts"],"names":[],"mappings":"AAuCA,+FAA+F;AAC/F,MAAM,CAAC,MAAM,eAAe,GAAG;IAC7B,OAAO,EAAE,GAAG;IACZ,QAAQ,EAAE,GAAG;IACb,MAAM,EAAE,GAAG;CACH,CAAC"}
@@ -0,0 +1,34 @@
1
+ export interface WgpuBuffer {
2
+ readonly mapState?: WgpuBufferMapState;
3
+ readonly size: number;
4
+ readonly usage: number;
5
+ destroy(): void;
6
+ getMappedRange(offset?: number, size?: number): ArrayBuffer;
7
+ mapAsync(mode: number, offset?: number, size?: number): Promise<void>;
8
+ unmap(): void;
9
+ }
10
+ export interface WgpuBufferDescriptor {
11
+ label?: string;
12
+ mappedAtCreation?: boolean;
13
+ size: number;
14
+ usage: number;
15
+ }
16
+ export type WgpuBufferMapState = 'mapped' | 'pending' | 'unmapped';
17
+ export type WgpuBufferSource = ArrayBufferLike | ArrayBufferView<ArrayBufferLike>;
18
+ export declare const WgpuBufferUsage: {
19
+ readonly COPY_DST: 8;
20
+ readonly COPY_SRC: 4;
21
+ readonly INDEX: 16;
22
+ readonly INDIRECT: 256;
23
+ readonly MAP_READ: 1;
24
+ readonly MAP_WRITE: 2;
25
+ readonly QUERY_RESOLVE: 512;
26
+ readonly STORAGE: 128;
27
+ readonly UNIFORM: 64;
28
+ readonly VERTEX: 32;
29
+ };
30
+ export declare const WgpuMapMode: {
31
+ readonly READ: 1;
32
+ readonly WRITE: 2;
33
+ };
34
+ //# sourceMapping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CAAM;CACL,CAAC"}
@@ -0,0 +1,19 @@
1
+ // Usage flags a buffer is created with, combined with `|`. The numeric values are WGPU's own, so a
2
+ // descriptor built from these is valid on every backend.
3
+ export const WgpuBufferUsage = {
4
+ COPY_DST: 0x0008,
5
+ COPY_SRC: 0x0004,
6
+ INDEX: 0x0010,
7
+ INDIRECT: 0x0100,
8
+ MAP_READ: 0x0001,
9
+ MAP_WRITE: 0x0002,
10
+ QUERY_RESOLVE: 0x0200,
11
+ STORAGE: 0x0080,
12
+ UNIFORM: 0x0040,
13
+ VERTEX: 0x0020,
14
+ };
15
+ export const WgpuMapMode = {
16
+ READ: 0x0001,
17
+ WRITE: 0x0002,
18
+ };
19
+ //# sourceMappingURL=WgpuBuffer.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"WgpuBuffer.js","sourceRoot":"","sources":["../../src/types/WgpuBuffer.ts"],"names":[],"mappings":"AAwBA,mGAAmG;AACnG,yDAAyD;AACzD,MAAM,CAAC,MAAM,eAAe,GAAG;IAC7B,QAAQ,EAAE,MAAM;IAChB,QAAQ,EAAE,MAAM;IAChB,KAAK,EAAE,MAAM;IACb,QAAQ,EAAE,MAAM;IAChB,QAAQ,EAAE,MAAM;IAChB,SAAS,EAAE,MAAM;IACjB,aAAa,EAAE,MAAM;IACrB,OAAO,EAAE,MAAM;IACf,OAAO,EAAE,MAAM;IACf,MAAM,EAAE,MAAM;CACN,CAAC;AAEX,MAAM,CAAC,MAAM,WAAW,GAAG;IACzB,IAAI,EAAE,MAAM;IACZ,KAAK,EAAE,MAAM;CACL,CAAC"}
@@ -0,0 +1,17 @@
1
+ import type { WgpuDevice } from './WgpuDevice.ts';
2
+ import type { WgpuTexture } from './WgpuTexture.ts';
3
+ import type { WgpuTextureFormat } from './WgpuTextureFormat.ts';
4
+ export type WgpuCanvasAlphaMode = 'opaque' | 'premultiplied';
5
+ export interface WgpuCanvasConfiguration {
6
+ alphaMode?: WgpuCanvasAlphaMode;
7
+ device: WgpuDevice;
8
+ format: WgpuTextureFormat;
9
+ usage?: number;
10
+ viewFormats?: readonly WgpuTextureFormat[];
11
+ }
12
+ export interface WgpuCanvasContext {
13
+ configure(configuration: Readonly<WgpuCanvasConfiguration>): void;
14
+ getCurrentTexture(): WgpuTexture;
15
+ unconfigure(): void;
16
+ }
17
+ //# sourceMappingURL=WgpuCanvasContext.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"WgpuCanvasContext.d.ts","sourceRoot":"","sources":["../../src/types/WgpuCanvasContext.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,iBAAiB,CAAC;AAClD,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,kBAAkB,CAAC;AACpD,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,wBAAwB,CAAC;AAEhE,MAAM,MAAM,mBAAmB,GAAG,QAAQ,GAAG,eAAe,CAAC;AAE7D,MAAM,WAAW,uBAAuB;IACtC,SAAS,CAAC,EAAE,mBAAmB,CAAC;IAChC,MAAM,EAAE,UAAU,CAAC;IACnB,MAAM,EAAE,iBAAiB,CAAC;IAC1B,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,WAAW,CAAC,EAAE,SAAS,iBAAiB,EAAE,CAAC;CAC5C;AAID,MAAM,WAAW,iBAAiB;IAChC,SAAS,CAAC,aAAa,EAAE,QAAQ,CAAC,uBAAuB,CAAC,GAAG,IAAI,CAAC;IAClE,iBAAiB,IAAI,WAAW,CAAC;IACjC,WAAW,IAAI,IAAI,CAAC;CACrB"}
@@ -0,0 +1,2 @@
1
+ export {};
2
+ //# sourceMappingURL=WgpuCanvasContext.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"WgpuCanvasContext.js","sourceRoot":"","sources":["../../src/types/WgpuCanvasContext.ts"],"names":[],"mappings":""}
@@ -0,0 +1,14 @@
1
+ import type { ColorScaleBias } from '@flighthq/adjustments/contract';
2
+ import type { TintMaterialData } from '@flighthq/materials/contract';
3
+ import type { RenderProxy2D } from '@flighthq/render/contract';
4
+ import type { WgpuColorAdjustmentFlush, WgpuRenderState, WgpuRenderStateRuntime, WgpuShapeMeshBuffers } from './WgpuRenderState.ts';
5
+ import type { WgpuShapeMesh } from './WgpuShapeMesh.ts';
6
+ export interface WgpuColorAdjustmentMaterialFeature {
7
+ fragmentShaderChunk: string;
8
+ matrixFragmentShaderChunk: string;
9
+ drawShapeMeshes?(state: WgpuRenderState, renderProxy: RenderProxy2D, meshes: readonly WgpuShapeMesh[], buffers: WgpuShapeMeshBuffers): void;
10
+ record(runtime: WgpuRenderStateRuntime, colorScaleBias: ColorScaleBias | TintMaterialData | Readonly<Float32Array> | null | undefined, instanceIndex: number): void;
11
+ resolveFlush(state: WgpuRenderState, count: number): WgpuColorAdjustmentFlush | null;
12
+ }
13
+ export type WgpuColorAdjustmentMaterialFeatureGuard = (state: WgpuRenderState, colorScaleBias: Readonly<ColorScaleBias | TintMaterialData | Float32Array>) => void;
14
+ //# sourceMappingURL=WgpuColorAdjustmentMaterialFeature.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"WgpuColorAdjustmentMaterialFeature.d.ts","sourceRoot":"","sources":["../../src/types/WgpuColorAdjustmentMaterialFeature.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,gCAAgC,CAAC;AACrE,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,8BAA8B,CAAC;AACrE,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,2BAA2B,CAAC;AAE/D,OAAO,KAAK,EACV,wBAAwB,EACxB,eAAe,EACf,sBAAsB,EACtB,oBAAoB,EACrB,MAAM,sBAAsB,CAAC;AAC9B,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,oBAAoB,CAAC;AAKxD,MAAM,WAAW,kCAAkC;IACjD,mBAAmB,EAAE,MAAM,CAAC;IAC5B,yBAAyB,EAAE,MAAM,CAAC;IAClC,eAAe,CAAC,CACd,KAAK,EAAE,eAAe,EACtB,WAAW,EAAE,aAAa,EAC1B,MAAM,EAAE,SAAS,aAAa,EAAE,EAChC,OAAO,EAAE,oBAAoB,GAC5B,IAAI,CAAC;IACR,MAAM,CACJ,OAAO,EAAE,sBAAsB,EAC/B,cAAc,EAAE,cAAc,GAAG,gBAAgB,GAAG,QAAQ,CAAC,YAAY,CAAC,GAAG,IAAI,GAAG,SAAS,EAC7F,aAAa,EAAE,MAAM,GACpB,IAAI,CAAC;IACR,YAAY,CAAC,KAAK,EAAE,eAAe,EAAE,KAAK,EAAE,MAAM,GAAG,wBAAwB,GAAG,IAAI,CAAC;CACtF;AAED,MAAM,MAAM,uCAAuC,GAAG,CACpD,KAAK,EAAE,eAAe,EACtB,cAAc,EAAE,QAAQ,CAAC,cAAc,GAAG,gBAAgB,GAAG,YAAY,CAAC,KACvE,IAAI,CAAC"}
@@ -0,0 +1,2 @@
1
+ export {};
2
+ //# sourceMappingURL=WgpuColorAdjustmentMaterialFeature.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"WgpuColorAdjustmentMaterialFeature.js","sourceRoot":"","sources":["../../src/types/WgpuColorAdjustmentMaterialFeature.ts"],"names":[],"mappings":""}
@@ -0,0 +1,5 @@
1
+ export type WgpuCommandBuffer = GPUCommandBuffer;
2
+ export interface WgpuCommandBufferDescriptor {
3
+ label?: string;
4
+ }
5
+ //# sourceMappingURL=WgpuCommandBuffer.d.ts.map