@cueframe/kernel 0.2.1 → 0.2.3

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 (332) hide show
  1. package/dist/_members/animate/index.d.ts +8 -2
  2. package/dist/_members/animate/layout/FlexLayout.d.ts +69 -0
  3. package/dist/_members/animate/layout/fit.d.ts +44 -0
  4. package/dist/_members/animate/layout/index.d.ts +3 -0
  5. package/dist/_members/animate/layout/solveFlex.d.ts +70 -0
  6. package/dist/_members/animate/media/MediaTileScene.d.ts +65 -0
  7. package/dist/_members/animate/media/recipes.d.ts +61 -0
  8. package/dist/_members/animate/scene/FocusPass.d.ts +76 -0
  9. package/dist/_members/animate/scene/UnlitPlane.d.ts +45 -0
  10. package/dist/_members/animate/scene/__oracle__/cssProjection.d.ts +24 -0
  11. package/dist/_members/animate/scene/assets.d.ts +21 -0
  12. package/dist/_members/animate/scene/backdrop.d.ts +7 -0
  13. package/dist/_members/animate/scene/coordinates.d.ts +58 -0
  14. package/dist/_members/animate/scene/deviceOpacity.d.ts +18 -0
  15. package/dist/_members/animate/scene/errors.d.ts +14 -0
  16. package/dist/_members/animate/scene/finishing.d.ts +69 -0
  17. package/dist/_members/animate/scene/finishingMath.d.ts +60 -0
  18. package/dist/_members/animate/scene/finishingPass.d.ts +35 -0
  19. package/dist/_members/animate/scene/focusBlur.d.ts +56 -0
  20. package/dist/_members/animate/scene/focusResources.d.ts +190 -0
  21. package/dist/_members/animate/scene/focusShaders.d.ts +68 -0
  22. package/dist/_members/animate/scene/fontReadiness.d.ts +27 -0
  23. package/dist/_members/animate/scene/grainNoise.d.ts +118 -0
  24. package/dist/_members/animate/scene/index.d.ts +19 -0
  25. package/dist/_members/animate/scene/internal.d.ts +29 -0
  26. package/dist/_members/animate/scene/planeFit.d.ts +46 -0
  27. package/dist/_members/animate/scene/preparedWorldText.d.ts +25 -0
  28. package/dist/_members/animate/scene/rasterCache.d.ts +30 -0
  29. package/dist/_members/animate/scene/rasterReadiness.d.ts +33 -0
  30. package/dist/_members/animate/scene/readiness.d.ts +69 -0
  31. package/dist/_members/animate/scene/redraw.d.ts +10 -0
  32. package/dist/_members/animate/scene/render.d.ts +9 -0
  33. package/dist/_members/animate/scene/scaling.d.ts +13 -0
  34. package/dist/_members/animate/scene/text.d.ts +40 -0
  35. package/dist/_members/animate/scene/textLayout.d.ts +78 -0
  36. package/dist/_members/animate/scene/textureImageSize.d.ts +4 -0
  37. package/dist/_members/animate/scene/useSceneImageTexture.d.ts +21 -0
  38. package/dist/_members/animate/scene/useWorldTextTexture.d.ts +21 -0
  39. package/dist/_members/animate/scene/v2/MeasuredPlaneGeometry.d.ts +7 -0
  40. package/dist/_members/animate/scene/v2/PhotographicStudioRig.d.ts +11 -0
  41. package/dist/_members/animate/scene/v2/PreparedSceneShotV1.d.ts +12 -0
  42. package/dist/_members/animate/scene/v2/SceneShotV2.d.ts +59 -0
  43. package/dist/_members/animate/scene/v2/builders.d.ts +170 -0
  44. package/dist/_members/animate/scene/v2/finishes.d.ts +152 -0
  45. package/dist/_members/animate/scene/v2/lighting.d.ts +119 -0
  46. package/dist/_members/animate/scene/v2/observePmremTargets.d.ts +4 -0
  47. package/dist/_members/animate/scene/v2/preparationFacts.d.ts +32 -0
  48. package/dist/_members/animate/scene/v2/preparedSurface.d.ts +17 -0
  49. package/dist/_members/animate/scene/v2/projectedResolution.d.ts +2 -0
  50. package/dist/_members/animate/scene/v2/renderTargetObserver.d.ts +5 -0
  51. package/dist/_members/animate/scene/v2/runtimeAllocations.d.ts +55 -0
  52. package/dist/_members/animate/scene/v2/shadow.d.ts +23 -0
  53. package/dist/_members/animate/scene/v2/slabGeometry.d.ts +134 -0
  54. package/dist/_members/animate/scene/v2/slots.d.ts +73 -0
  55. package/dist/_members/animate/scene/v2/videoBinding.d.ts +39 -0
  56. package/dist/_members/animate/scene/worldBounds.d.ts +19 -0
  57. package/dist/_members/animate/scene/worldTextRaster.d.ts +87 -0
  58. package/dist/_members/animate/scene/worldTextTexture.d.ts +32 -0
  59. package/dist/_members/animate/stage/PerspectiveStage.d.ts +73 -0
  60. package/dist/_members/animate/stage/camera.d.ts +143 -0
  61. package/dist/_members/animate/stage/dof.d.ts +9 -0
  62. package/dist/_members/animate/stage/index.d.ts +6 -0
  63. package/dist/_members/animate/stage/presets.d.ts +17 -0
  64. package/dist/_members/animate/three/DeviceMesh.d.ts +256 -0
  65. package/dist/_members/animate/three/SceneCameraRig.d.ts +12 -0
  66. package/dist/_members/animate/three/StageCameraRig.d.ts +7 -0
  67. package/dist/_members/animate/three/StudioRig.d.ts +228 -0
  68. package/dist/_members/animate/three/ThreeCanvas.d.ts +22 -0
  69. package/dist/_members/animate/three/defaultScreen.d.ts +23 -0
  70. package/dist/_members/animate/three/index.d.ts +7 -1
  71. package/dist/_members/animate/three/textureLifecycle.d.ts +29 -0
  72. package/dist/_members/animate/three/toneMapping.d.ts +113 -0
  73. package/dist/_members/animate/three/useImageTexture.d.ts +17 -0
  74. package/dist/_members/authoring/index.d.ts +2 -0
  75. package/dist/_members/authoring/scene/index.d.ts +6 -0
  76. package/dist/_members/authoring/scene/materialize.d.ts +47 -0
  77. package/dist/_members/authoring/scene/validate.d.ts +80 -0
  78. package/dist/_members/authoring/scene/wrapper.d.ts +41 -0
  79. package/dist/_members/component-runtime/allowedImports.d.ts +3 -0
  80. package/dist/_members/component-runtime/allowedImports.d.ts.map +1 -0
  81. package/dist/_members/component-runtime/bake.d.ts +8 -0
  82. package/dist/_members/component-runtime/bake.d.ts.map +1 -1
  83. package/dist/_members/component-runtime/browserFirewall.d.ts +7 -1
  84. package/dist/_members/component-runtime/browserFirewall.d.ts.map +1 -1
  85. package/dist/_members/component-runtime/browserOptions.d.ts +59 -3
  86. package/dist/_members/component-runtime/browserOptions.d.ts.map +1 -1
  87. package/dist/_members/component-runtime/canonicalIdentity.d.ts +14 -0
  88. package/dist/_members/component-runtime/canonicalIdentity.d.ts.map +1 -1
  89. package/dist/_members/component-runtime/contracts.d.ts +341 -1
  90. package/dist/_members/component-runtime/contracts.d.ts.map +1 -1
  91. package/dist/_members/component-runtime/fixtures/imageTileDriftWall.d.ts +5 -0
  92. package/dist/_members/component-runtime/fixtures/imageTileDriftWall.d.ts.map +1 -0
  93. package/dist/_members/component-runtime/fixtures/mediaTileMixed.d.ts +5 -0
  94. package/dist/_members/component-runtime/fixtures/mediaTileMixed.d.ts.map +1 -0
  95. package/dist/_members/component-runtime/fixtures/mediaTileVideo.d.ts +8 -0
  96. package/dist/_members/component-runtime/fixtures/mediaTileVideo.d.ts.map +1 -0
  97. package/dist/_members/component-runtime/importPolicy.d.ts +3 -2
  98. package/dist/_members/component-runtime/importPolicy.d.ts.map +1 -1
  99. package/dist/_members/component-runtime/index.d.ts +3 -0
  100. package/dist/_members/component-runtime/index.d.ts.map +1 -1
  101. package/dist/_members/component-runtime/livePreviewProxy.d.ts +7 -0
  102. package/dist/_members/component-runtime/livePreviewProxy.d.ts.map +1 -0
  103. package/dist/_members/component-runtime/localRoot.d.ts +37 -0
  104. package/dist/_members/component-runtime/localRoot.d.ts.map +1 -0
  105. package/dist/_members/component-runtime/mediaResolution.d.ts +25 -0
  106. package/dist/_members/component-runtime/mediaResolution.d.ts.map +1 -0
  107. package/dist/_members/component-runtime/render.d.ts +151 -13
  108. package/dist/_members/component-runtime/render.d.ts.map +1 -1
  109. package/dist/_members/component-runtime/renderDiagnostics.d.ts +14 -0
  110. package/dist/_members/component-runtime/renderDiagnostics.d.ts.map +1 -0
  111. package/dist/_members/component-runtime/sceneAdmission.d.ts +47 -0
  112. package/dist/_members/component-runtime/sceneAdmission.d.ts.map +1 -0
  113. package/dist/_members/component-runtime/sourceWorkspace.d.ts +8 -0
  114. package/dist/_members/component-runtime/sourceWorkspace.d.ts.map +1 -1
  115. package/dist/_members/component-runtime/webglProbe.d.ts +191 -0
  116. package/dist/_members/component-runtime/webglProbe.d.ts.map +1 -0
  117. package/dist/_members/composition/fonts/bundledFaces.d.ts +150 -0
  118. package/dist/_members/composition/fonts/captionFaces.d.ts +268 -0
  119. package/dist/_members/composition/fonts.d.ts +11 -4
  120. package/dist/_members/composition/graphics-plan/schemas.d.ts +4 -4
  121. package/dist/_members/composition/ops/types.d.ts +1 -1
  122. package/dist/_members/composition/primitive-catalog/types.d.ts +1 -0
  123. package/dist/_members/composition/projection/behind-readiness.d.ts +3 -0
  124. package/dist/_members/composition/projection/brandKit.d.ts +6 -0
  125. package/dist/_members/composition/projection/composition-floor.d.ts +2 -1
  126. package/dist/_members/composition/scene/animation.d.ts +25 -0
  127. package/dist/_members/composition/scene/budget.d.ts +29 -0
  128. package/dist/_members/composition/scene/budgetPolicy.d.mts +13 -0
  129. package/dist/_members/composition/scene/clipRules.d.ts +119 -0
  130. package/dist/_members/composition/scene/constraints.d.ts +61 -0
  131. package/dist/_members/composition/scene/device.d.ts +21 -0
  132. package/dist/_members/composition/scene/examples.d.ts +11 -0
  133. package/dist/_members/composition/scene/index.d.ts +11 -0
  134. package/dist/_members/composition/scene/photographicRig.d.ts +242 -0
  135. package/dist/_members/composition/scene/preparedRender.d.ts +239 -0
  136. package/dist/_members/composition/scene/resolution.d.ts +178 -0
  137. package/dist/_members/composition/scene/schema.d.ts +351 -0
  138. package/dist/_members/composition/scene/videoSchedule.d.ts +43 -0
  139. package/dist/_members/composition/validators/brandKit.d.ts +1 -0
  140. package/dist/_members/composition/validators/render.d.ts +2 -0
  141. package/dist/_members/composition-ops/index.d.ts +45 -0
  142. package/dist/_members/composition-ops/opRecorder.d.ts +1 -1
  143. package/dist/_members/core/render/compositionRender.d.ts +41 -9
  144. package/dist/_members/core/render/index.d.ts +9 -2
  145. package/dist/_members/core/render/sceneCaptureIdentity.d.ts +14 -0
  146. package/dist/_members/core/render/sceneShotPlan.d.ts +142 -0
  147. package/dist/_members/core/render/sceneShotPreparation.d.ts +57 -0
  148. package/dist/_members/core/render/slabDescriptor.d.ts +21 -0
  149. package/dist/_members/core/render/trackProjection.d.ts +33 -0
  150. package/dist/_members/core/render/types.d.ts +142 -0
  151. package/dist/_members/errors/registry.d.ts +6 -0
  152. package/dist/_members/mcp/adapter.d.ts +5 -0
  153. package/dist/_members/mcp/generated/sceneContract.d.ts +155 -0
  154. package/dist/_members/mcp/sceneShot.d.ts +38 -0
  155. package/dist/_members/mcp/sceneShotExample.d.ts +22 -0
  156. package/dist/_members/media-model/api.d.ts +1 -0
  157. package/dist/_members/media-model/media-kind.d.ts +1 -1
  158. package/dist/_members/media-model/testing/mediaStoreContract.d.ts +1 -1
  159. package/dist/_members/primitives/effects/index.d.ts +1 -0
  160. package/dist/_members/primitives/effects/stage-camera/config.d.ts +50 -0
  161. package/dist/_members/primitives/effects/stage-camera/index.d.ts +31 -0
  162. package/dist/_members/primitives/layouts/flex-layout/config.d.ts +73 -0
  163. package/dist/_members/primitives/layouts/flex-layout/index.d.ts +4 -0
  164. package/dist/_members/primitives/layouts/index.d.ts +1 -0
  165. package/dist/_members/primitives/layouts/picture-in-picture/config.d.ts +1 -1
  166. package/dist/_members/primitives/lib/frameScale.d.ts +4 -0
  167. package/dist/_members/primitives/lib/index.d.ts +1 -0
  168. package/dist/_members/primitives/lib/palette.d.ts +30 -30
  169. package/dist/_members/primitives/lib/text/contrast.d.ts +2 -1
  170. package/dist/_members/primitives/lib/text/spec.d.ts +0 -8
  171. package/dist/_members/primitives/lib/types.d.ts +2 -0
  172. package/dist/_members/primitives/scenes/device-showcase/config.d.ts +41 -0
  173. package/dist/_members/primitives/scenes/device-showcase/index.d.ts +36 -0
  174. package/dist/_members/primitives/scenes/hero-device-assemble/config.d.ts +1 -0
  175. package/dist/_members/primitives/scenes/hero-device-assemble/index.d.ts +2 -1
  176. package/dist/_members/primitives/scenes/index.d.ts +1 -0
  177. package/dist/_members/primitives/ui-blocks/badge-pop/config.d.ts +1 -1
  178. package/dist/_members/primitives/ui-blocks/device-mockup-zoom/config.d.ts +1 -0
  179. package/dist/_members/primitives/ui-blocks/device-mockup-zoom/index.d.ts +2 -1
  180. package/dist/_members/primitives/ui-blocks/terminal-simulator/config.d.ts +1 -1
  181. package/dist/_members/primitives/ui-blocks/toast-notification/config.d.ts +1 -1
  182. package/dist/_members/render-harness/cardAssetAdmission.d.ts.map +1 -1
  183. package/dist/_members/render-harness/cardRender.d.ts.map +1 -1
  184. package/dist/_members/render-harness/css-tree-subpaths.d.ts +11 -0
  185. package/dist/_members/render-harness/extractSegments.d.ts +1 -0
  186. package/dist/_members/render-harness/extractSegments.d.ts.map +1 -1
  187. package/dist/_members/render-harness/imageHeader.d.ts +14 -0
  188. package/dist/_members/render-harness/imageHeader.d.ts.map +1 -0
  189. package/dist/_members/render-harness/index.d.ts +6 -0
  190. package/dist/_members/render-harness/index.d.ts.map +1 -1
  191. package/dist/_members/render-harness/materializeSources.d.ts +46 -2
  192. package/dist/_members/render-harness/materializeSources.d.ts.map +1 -1
  193. package/dist/_members/render-harness/nodeScenePreparation.d.ts +97 -0
  194. package/dist/_members/render-harness/nodeScenePreparation.d.ts.map +1 -0
  195. package/dist/_members/render-harness/remotion-runtime.d.ts +16 -2
  196. package/dist/_members/render-harness/renderInputAssets.d.ts +1 -1
  197. package/dist/_members/render-harness/renderInputAssets.d.ts.map +1 -1
  198. package/dist/_members/render-harness/resolveAssets.d.ts +2 -2
  199. package/dist/_members/render-harness/resolveAssets.d.ts.map +1 -1
  200. package/dist/_members/render-harness/sceneShotAssets.d.ts +17 -0
  201. package/dist/_members/render-harness/sceneShotAssets.d.ts.map +1 -0
  202. package/dist/animate/preparation-facts.d.ts +1 -0
  203. package/dist/animate/preparation-facts.js +22 -0
  204. package/dist/animate.js +336 -1005
  205. package/dist/authoring/build-tools.js +7 -6
  206. package/dist/authoring/context.js +5 -4
  207. package/dist/authoring/prompts.js +1 -1
  208. package/dist/authoring/scene.d.ts +1 -0
  209. package/dist/authoring/scene.js +50 -0
  210. package/dist/authoring/tools.js +6 -5
  211. package/dist/authoring.js +49 -29
  212. package/dist/chunk-2L7PYYJK.js +23 -0
  213. package/dist/{chunk-ZN6P3KOJ.js → chunk-32TH76H3.js} +2 -2
  214. package/dist/chunk-5DJ3IEJR.js +4424 -0
  215. package/dist/chunk-6BVVCRRD.js +26488 -0
  216. package/dist/{chunk-DQKSCHFC.js → chunk-6EWRIAZA.js} +187 -66
  217. package/dist/{chunk-YQ7FFW3G.js → chunk-6VWICHOZ.js} +26 -5
  218. package/dist/{chunk-2PGLNTB7.js → chunk-A74FZCPY.js} +45 -5
  219. package/dist/{chunk-C5SEPOWD.js → chunk-AS5EXBNS.js} +1792 -707
  220. package/dist/{chunk-BKHGL4MB.js → chunk-B3GSTQLR.js} +341 -274
  221. package/dist/chunk-BVA3537Z.js +63 -0
  222. package/dist/{chunk-DHKQ47Q6.js → chunk-DAARYRNT.js} +6 -1
  223. package/dist/chunk-DQLYWNLC.js +2063 -0
  224. package/dist/chunk-E6WHXIDF.js +3619 -0
  225. package/dist/{chunk-NOEBAV2G.js → chunk-E7GIZEPS.js} +1 -1
  226. package/dist/{chunk-M2TLRXEO.js → chunk-EXY4JJPH.js} +1 -1
  227. package/dist/{chunk-GEGRJKKO.js → chunk-F2DJL7P7.js} +1 -1
  228. package/dist/{chunk-AWT3P5ZN.js → chunk-FVDFPJHT.js} +1 -1
  229. package/dist/{chunk-EMGFZ3PR.js → chunk-FWSJLHSV.js} +5 -1
  230. package/dist/{chunk-TMIBBD5E.js → chunk-I5QWBM3M.js} +280 -113
  231. package/dist/{chunk-IBMJ33EL.js → chunk-I5RX2QZT.js} +1 -1
  232. package/dist/{chunk-4FOOBSEE.js → chunk-J3DIUG24.js} +1 -0
  233. package/dist/{chunk-AD5HWBCE.js → chunk-JX53CVJV.js} +14 -5
  234. package/dist/{chunk-LNBVTDFR.js → chunk-L2AHS3AW.js} +1 -1
  235. package/dist/{chunk-BDMTUEEZ.js → chunk-LT4PWSR2.js} +2 -2
  236. package/dist/chunk-MH3UPKWR.js +3415 -0
  237. package/dist/{chunk-RFXR7ATW.js → chunk-NUKDEOK6.js} +13 -1
  238. package/dist/{chunk-IJ7PVJTK.js → chunk-ODUWCQI3.js} +3 -2
  239. package/dist/chunk-QAGGJHAF.js +16 -0
  240. package/dist/chunk-QS36DMFG.js +332 -0
  241. package/dist/{chunk-G5BFI32U.js → chunk-RAXHCRVV.js} +1 -1
  242. package/dist/{chunk-BIBYZJL3.js → chunk-RL5SO653.js} +3 -3
  243. package/dist/{chunk-ZSZABOE5.js → chunk-S5H6GH6M.js} +1 -1
  244. package/dist/{chunk-EEXCDFY5.js → chunk-SD25VQDE.js} +1 -1
  245. package/dist/{chunk-Y3QGYASW.js → chunk-SX523NDS.js} +14 -14
  246. package/dist/chunk-TARKDVP6.js +430 -0
  247. package/dist/{chunk-IHFREGFA.js → chunk-TCHPRGC5.js} +18 -2
  248. package/dist/{chunk-ZCAQHNPI.js → chunk-UKGNHZS4.js} +1 -1
  249. package/dist/{chunk-KU376ELE.js → chunk-UY77TMKD.js} +31 -44
  250. package/dist/chunk-VKATKWWR.js +1462 -0
  251. package/dist/{chunk-CX2IIQ4R.js → chunk-W2245F6G.js} +29 -29
  252. package/dist/{chunk-XHUYWVYK.js → chunk-WBNFSG6T.js} +1 -1
  253. package/dist/chunk-WIHXXF3X.js +221 -0
  254. package/dist/{chunk-XVBOSPZI.js → chunk-X74EEFXV.js} +6 -6
  255. package/dist/{chunk-7KEUL3FI.js → chunk-XF2QMKRG.js} +9 -1
  256. package/dist/{chunk-HFC3MKXA.js → chunk-Y4HPN4BC.js} +1 -0
  257. package/dist/{chunk-6XI57FZZ.js → chunk-YFSBFCXO.js} +1022 -46
  258. package/dist/{chunk-6ID2J64H.js → chunk-YHC3RXS7.js} +162 -25
  259. package/dist/{chunk-KKEY5MIW.js → chunk-ZS3A3QUM.js} +16 -16
  260. package/dist/{chunk-LQUWKBST.js → chunk-ZVG446DJ.js} +139 -10
  261. package/dist/component-runtime/browserOptions.js +14 -3
  262. package/dist/component-runtime/contracts.js +35 -3
  263. package/dist/component-runtime/identity/browser.js +1 -1
  264. package/dist/component-runtime/identity.js +2 -2
  265. package/dist/component-runtime/importPolicy.js +2 -2
  266. package/dist/component-runtime/mediaResolution.d.ts +1 -0
  267. package/dist/component-runtime/mediaResolution.js +11 -0
  268. package/dist/component-runtime/render.js +38 -5
  269. package/dist/component-runtime.js +118 -14
  270. package/dist/compose.js +27 -21
  271. package/dist/composition/fonts.js +64 -67
  272. package/dist/composition/graphics-plan.js +3 -2
  273. package/dist/composition/ops.js +4 -3
  274. package/dist/composition/primitive-catalog.js +1 -1
  275. package/dist/composition/projection.js +10 -3
  276. package/dist/composition/scene/budget-policy.d.ts +1 -0
  277. package/dist/composition/scene/budget-policy.js +17 -0
  278. package/dist/composition/scene/schema.json +2757 -0
  279. package/dist/composition/scene.d.ts +1 -0
  280. package/dist/composition/scene.js +275 -0
  281. package/dist/composition/validators.js +3 -2
  282. package/dist/composition-ops.js +103 -13
  283. package/dist/composition.js +12 -5
  284. package/dist/{context-4GSDBFT3.js → context-IUPQ54V4.js} +5 -4
  285. package/dist/core/render.js +54 -3
  286. package/dist/core/select.js +2 -2
  287. package/dist/core.js +6 -3
  288. package/dist/director/ai-sdk.js +3 -3
  289. package/dist/director/domain.js +2 -2
  290. package/dist/director.js +3 -3
  291. package/dist/errors.js +1 -1
  292. package/dist/mcp/adapter.js +4 -4
  293. package/dist/mcp/core.js +1 -1
  294. package/dist/mcp/curation.js +1 -1
  295. package/dist/mcp/server.js +4 -4
  296. package/dist/mcp.js +4 -4
  297. package/dist/media-model/media-kind.js +2 -0
  298. package/dist/media-model/testing.js +16 -11
  299. package/dist/media-model.js +1 -1
  300. package/dist/nle-export.js +27 -21
  301. package/dist/primitives/backgrounds.js +2 -2
  302. package/dist/primitives/captions.js +21 -11
  303. package/dist/primitives/effects.js +14 -4
  304. package/dist/primitives/graphics.json +3 -0
  305. package/dist/primitives/hero-text.js +4 -3
  306. package/dist/primitives/layouts.js +9 -2
  307. package/dist/primitives/lib/frameScale.d.ts +1 -0
  308. package/dist/primitives/lib/frameScale.js +11 -0
  309. package/dist/primitives/lib/index.js +18 -10
  310. package/dist/primitives/lib/palette.js +1 -1
  311. package/dist/primitives/lib/text/contrast.js +2 -1
  312. package/dist/primitives/lib/text/typeface.js +1 -1
  313. package/dist/primitives/lib.js +18 -10
  314. package/dist/primitives/params-required.json +3 -0
  315. package/dist/primitives/scenes.js +12 -3
  316. package/dist/primitives/text.js +5 -5
  317. package/dist/primitives/transitions.js +2 -2
  318. package/dist/primitives/ui-blocks.js +7 -6
  319. package/dist/primitives/version-map.json +5 -2
  320. package/dist/primitives.js +27 -20
  321. package/dist/render-harness/cardAssetAdmission.js +2 -2
  322. package/dist/render-harness/renderInputAssets.js +2 -2
  323. package/dist/render-harness.js +876 -126
  324. package/package.json +51 -17
  325. package/dist/_members/animate/three/drei.d.ts +0 -6
  326. package/dist/_members/component-runtime/fixtures/webgpuTiledRefraction.d.ts +0 -9
  327. package/dist/_members/component-runtime/fixtures/webgpuTiledRefraction.d.ts.map +0 -1
  328. package/dist/chunk-4JRUGT2Y.js +0 -544
  329. package/dist/chunk-5OTQ7M43.js +0 -718
  330. package/dist/chunk-CGHTMZNC.js +0 -6
  331. package/dist/chunk-QBKDEO7J.js +0 -9521
  332. /package/dist/{chunk-H5LMJKZU.js → chunk-JVDUSOYG.js} +0 -0
@@ -0,0 +1,256 @@
1
+ import { ExtrudeGeometry, Shape } from 'three';
2
+ import type { BufferGeometry, Camera, Material, Scene, Texture, WebGLRenderer } from 'three';
3
+ import { type SceneDeviceDimensionsV1, type SceneLaptopLayoutV1 } from '../../composition/scene/index.js';
4
+ import type { SceneMaterialOverrideV2 } from '../../composition/scene/index.js';
5
+ import { type SceneActualResourceRegistrarV1 } from '../scene/v2/runtimeAllocations.js';
6
+ export type DeviceKind = 'laptop' | 'phone';
7
+ export interface DeviceDimensions extends SceneDeviceDimensionsV1 {
8
+ /** lid/phone width, lid/phone height, shell thickness, base depth (laptop), screen inset, corner radius — px */
9
+ w: number;
10
+ h: number;
11
+ t: number;
12
+ d: number;
13
+ screenInset: number;
14
+ radius: number;
15
+ }
16
+ export declare function deviceDimensions(kind: DeviceKind, width: number): DeviceDimensions;
17
+ /**
18
+ * Where a laptop's parts sit inside its own group, in Three axes and the same units as `width`.
19
+ *
20
+ * The one statement of this layout. It was hand-copied into three places — the mesh itself, the
21
+ * scene's shadow bounds and the device-showcase primitive — and a change to any one of them
22
+ * silently moved the shadow or the floor of the others. All three now read this, the primitive
23
+ * through the package barrel, so there is nothing left to keep in step by hand.
24
+ */
25
+ export interface LaptopLayout extends SceneLaptopLayoutV1 {
26
+ /** The base's centre inside the device group. */
27
+ baseY: number;
28
+ /** The hinge above the base's centre: the base's top face. */
29
+ hingeFromBaseY: number;
30
+ /** The hinge behind the base's centre: the base's back edge. */
31
+ hingeZ: number;
32
+ /** The hinge inside the device group. */
33
+ hingeY: number;
34
+ /** The lid's centre above the hinge, before the lid swings. */
35
+ lidCentreY: number;
36
+ /** The base's underside — what rests on the floor. */
37
+ bottomY: number;
38
+ }
39
+ export declare function laptopLayout(dim: DeviceDimensions): LaptopLayout;
40
+ /**
41
+ * The screen's glass overlay: how much of its own reflection it lays over the screenshot.
42
+ *
43
+ * The plane is a sheen, and it is authored as a tenth — but a tenth of what, in which space? That
44
+ * depends on the pipeline the mesh is drawn through, and there are two of them, so there are two
45
+ * numbers and every caller says which one it is blending in.
46
+ *
47
+ * `DEVICE_GLASS_OPACITY_ENCODED` is the authored tenth itself, and it is what a mesh drawn
48
+ * straight onto the canvas wants: WebGL blends on the canvas's stored sRGB bytes, clamped to
49
+ * white, so `0.10` there is a tenth of an encoded white and lifts a black screen pixel to sRGB 25.
50
+ * `device-showcase` is that pipeline.
51
+ *
52
+ * `DEVICE_GLASS_OPACITY_LINEAR` is the same tenth for a pipeline that blends in linear light. A
53
+ * scene shot composes its world in the focus pass's half-float target — the only space a
54
+ * depth-aware blur can average colour in — where `0.10` would be a tenth of the reflection's
55
+ * *radiance*, unclamped. Measured through the lane, that reflection is 1.09 on a lid tilted ten
56
+ * degrees back (it catches the room's ceiling) and 0.027 on an upright one, so a tenth of it laid
57
+ * sRGB 94 over a screenshot's black and cost the gated card its colours. The tenth is therefore
58
+ * carried across rather than re-tuned: a tenth of an encoded white is `srgbToLinear(0.10) =
59
+ * 0.0100` of a linear one. `DeviceMesh.test.ts` pins both — the encoded one to the authored
60
+ * decimal, the linear one to three's own transfer function.
61
+ *
62
+ * The two are not interchangeable, so `DeviceMesh` takes the number as a prop and every caller
63
+ * names the constant it means. The prop defaults to the encoded one because that is what a mesh
64
+ * drawn with no render target bound blends in, which is every caller but the scene shot — and the
65
+ * scene shot is the one pipeline that has to say otherwise, which it does, in `SceneWorld`. That
66
+ * is the defect this pair replaces: one shared constant, moved into linear light for the scene
67
+ * lane, silently taking nine tenths of the sheen off `device-showcase`, whose own gate cannot see
68
+ * a reflection that faint.
69
+ *
70
+ * The albedo is three's default white, in both, and that is a correction of its own. The round
71
+ * that moved this shot into linear light also set the albedo to black, on the reasoning that glass
72
+ * has no diffuse albedo and a `meshPhysicalMaterial` at white shades a full diffuse lobe worth 2.66
73
+ * of linear radiance — "0.10 of that is 0.27 of linear white over the screenshot, sRGB 141 on a
74
+ * black pixel". That measurement was taken in a pipeline that had lost its tone curve and was still
75
+ * blending the tenth as if it were a linear coverage. With the curve applied by the material and
76
+ * the tenth carried across, the same white albedo lays `srgbToLinear(0.10) x ACES(2.66) = 0.0092`
77
+ * of linear white on a black screen pixel — sRGB **24**, against the 25 the shot was authored with.
78
+ * The albedo was never the problem; it was compensating for the two things that were, and with them
79
+ * fixed it over-corrected: black albedo *and* the linear carry together took the sheen down by
80
+ * three orders of magnitude, to at most one code, which is no sheen at all. Measured consequence:
81
+ * the screenshot was reaching the frame raw-saturated, and 4:2:0 chroma subsampling costs twice as
82
+ * much on it (the acceptance evidence's concurrency row, 99.9th-percentile luma 13 against a bound
83
+ * of 12; 7.5 with the sheen restored). The physical argument stands on its own terms — a real sheet
84
+ * of glass has no diffuse lobe — but this plane is an authored veil, not a simulation, and the
85
+ * authored veil is a tenth of a white one.
86
+ */
87
+ export declare const DEVICE_GLASS_OPACITY_ENCODED = 0.1;
88
+ /** The tenth above for a pipeline that blends in linear light; see `DEVICE_GLASS_OPACITY_ENCODED`. */
89
+ export declare const DEVICE_GLASS_OPACITY_LINEAR: number;
90
+ /**
91
+ * Every lit material this mesh draws, enumerated once, each one tone-mapping itself.
92
+ *
93
+ * The enumeration is the point. Three applies `renderer.toneMapping` only to a material drawn
94
+ * with no render target bound (see `toneMapping.ts`), and a scene shot draws its whole world into
95
+ * one — so anything in here that did not carry `SELF_TONE_MAPPED` would quietly lose the ACES
96
+ * roll-off in a scene shot and clip instead, while keeping it in `device-showcase`. Listing them
97
+ * as data rather than spreading the props across the tree below is what lets a test walk the whole
98
+ * set and check the compiled fragment of each.
99
+ *
100
+ * The unlit materials are deliberately not here and must not be added: the screenshot plane and
101
+ * its black stand-in below, and `UnlitPlane`'s page and world-text planes, are colour-managed
102
+ * surfaces the contract promises to leave exactly as authored. They carry `toneMapped: false` with
103
+ * no injection, so no curve touches them under either pipeline.
104
+ *
105
+ * `color` is left off the two shells because it is the caller's `finish`, and off the glass's
106
+ * `opacity` because that is the per-pipeline tenth above.
107
+ */
108
+ export declare const DEVICE_LIT_MATERIALS: {
109
+ /** The phone's shell: `meshPhysicalMaterial`, the caller's finish. */
110
+ readonly phoneShell: {
111
+ readonly metalness: 0.85;
112
+ readonly roughness: 0.32;
113
+ readonly clearcoat: 0.5;
114
+ readonly clearcoatRoughness: 0.2;
115
+ readonly toneMapped: false;
116
+ readonly onBeforeCompile: typeof import("./toneMapping.js").toneMapInTheMaterial;
117
+ };
118
+ /** The laptop's base and its lid, which take the same finish and the same material. */
119
+ readonly laptopShell: {
120
+ readonly metalness: 0.85;
121
+ readonly roughness: 0.35;
122
+ readonly clearcoat: 0.4;
123
+ readonly toneMapped: false;
124
+ readonly onBeforeCompile: typeof import("./toneMapping.js").toneMapInTheMaterial;
125
+ };
126
+ /** The keyboard well on the laptop's base: `meshStandardMaterial`. */
127
+ readonly keyboard: {
128
+ readonly color: "#111114";
129
+ readonly roughness: 0.9;
130
+ readonly metalness: 0.1;
131
+ readonly toneMapped: false;
132
+ readonly onBeforeCompile: typeof import("./toneMapping.js").toneMapInTheMaterial;
133
+ };
134
+ /** The trackpad in front of it: `meshStandardMaterial`. */
135
+ readonly trackpad: {
136
+ readonly color: "#1a1a1f";
137
+ readonly roughness: 0.6;
138
+ readonly metalness: 0.3;
139
+ readonly toneMapped: false;
140
+ readonly onBeforeCompile: typeof import("./toneMapping.js").toneMapInTheMaterial;
141
+ };
142
+ /** The dark bezel behind the lid's screen: `meshStandardMaterial`. */
143
+ readonly bezel: {
144
+ readonly color: "#050507";
145
+ readonly roughness: 0.5;
146
+ readonly toneMapped: false;
147
+ readonly onBeforeCompile: typeof import("./toneMapping.js").toneMapInTheMaterial;
148
+ };
149
+ /**
150
+ * The screen's glass sheen: `meshPhysicalMaterial`, default albedo, per-pipeline opacity.
151
+ *
152
+ * `envMapIntensity` is the one number in this table that does not reach a frame on its own —
153
+ * it needs `takeSceneEnvironment` on the mesh that draws it. See that function.
154
+ */
155
+ readonly glass: {
156
+ readonly transparent: true;
157
+ readonly roughness: 0.06;
158
+ readonly metalness: 0;
159
+ readonly envMapIntensity: 1.2;
160
+ readonly toneMapped: false;
161
+ readonly onBeforeCompile: typeof import("./toneMapping.js").toneMapInTheMaterial;
162
+ };
163
+ };
164
+ /**
165
+ * Hand a lit material the environment of the scene being drawn, so its own `envMapIntensity` is
166
+ * the one that reaches the frame.
167
+ *
168
+ * Three uploads a material's `envMapIntensity` only for a material that carries its OWN `envMap`:
169
+ * `WebGLMaterials.refreshMaterialUniforms` guards every assignment of it with
170
+ * `if ( material.envMap )`. A material lit by `scene.environment` alone takes the other branch
171
+ * entirely — `WebGLRenderer.setProgram` writes `scene.environmentIntensity` over that uniform for
172
+ * any standard/lambert/phong material whose `envMap` is null (three 0.183.2,
173
+ * `WebGLRenderer.js:2602`). `StudioRig` sets `scene.environment` and nothing in either lane gives
174
+ * a material an `envMap`, so the glass's authored 1.2 was a number nothing read from the day the
175
+ * rig was written: the sheen was drawn at the scene's intensity of 1, and a reviewer signing off
176
+ * the rendered frame could not have seen the difference. This is what makes the knob real.
177
+ *
178
+ * Assigning the scene's own environment costs nothing else. `WebGLPrograms` resolves a material's
179
+ * environment as `material.envMap || scene.environment`, so the resolved texture, the shader
180
+ * defines and the cached program are the ones already in use and nothing recompiles; the material
181
+ * simply stops taking the scene's intensity and starts taking its own. `envMapRotation` swaps from
182
+ * the scene's to the material's, and both are the identity here.
183
+ *
184
+ * It goes through three's own per-draw hook rather than through a layout effect because the
185
+ * environment is created in `StudioRig`'s layout effect, and this mesh mounts on its own schedule —
186
+ * a device layer mounts only once its screenshot has committed, which is a later commit than the
187
+ * rig's. `onBeforeRender` is handed the scene being drawn and runs immediately before that draw's
188
+ * `setProgram` (`WebGLRenderer.renderObject`), so the material tracks whatever the scene's
189
+ * environment is at the moment it is drawn — mount order cannot get this wrong, and a rig mounted
190
+ * with `environment={false}`, or unmounted, takes the material back to null with it.
191
+ */
192
+ export declare function takeSceneEnvironment(_renderer: WebGLRenderer, scene: Scene, _camera: Camera, _geometry: BufferGeometry, material: Material): void;
193
+ /** Lid rotation about the hinge: 90° open is vertical; 0° lies on the base (rotated toward +z). */
194
+ export declare function lidRotationX(openAngle: number): number;
195
+ /** A rounded rectangle centred on the origin, ready to extrude. Pure: no DOM, no renderer. */
196
+ export declare function roundedRectShape(w: number, h: number, radius: number): Shape;
197
+ /**
198
+ * The phone shell, deliberately NOT a RoundedBoxGeometry like the laptop.
199
+ *
200
+ * RoundedBoxGeometry clamps its radius to half the *thinnest* axis, so on an 11px
201
+ * slab the phone's 49px corner radius collapses to ~5px and the body reads as a
202
+ * hard-cornered brick. Extruding a rounded rect rounds x and y at the radius asked
203
+ * for and leaves the edge bevel independent of it. The laptop keeps
204
+ * RoundedBoxGeometry: its requested radius clamps to ~6px, which is imperceptible
205
+ * at lid scale, and a box is the right silhouette for a lid and a base. Do not
206
+ * unify the two back together.
207
+ *
208
+ * ExtrudeGeometry expands the body outward by `bevelSize` and runs z from
209
+ * -bevelThickness to depth+bevelThickness, so the core shape is inset by the bevel
210
+ * and the result translated back by depth/2. The outer box is then exactly
211
+ * w × h × t centred on the origin — the same contract as the RoundedBoxGeometry it
212
+ * replaces, so the screen and glass planes at z = t/2 + ε still sit just in front
213
+ * of the face.
214
+ */
215
+ export declare function phoneShellGeometry(w: number, h: number, t: number, radius: number): ExtrudeGeometry;
216
+ /**
217
+ * How far in front of the shell's front face each of the three stacked planes sits, in the same
218
+ * units as `width`. Small and fixed: enough to beat depth-fighting at any device scale, not enough
219
+ * to read as a gap.
220
+ *
221
+ * Exported because the screen's is not only this mesh's business. `mixedShot.test.ts` measures
222
+ * where the laptop's screen surface actually lands in camera space, to check that the fixture
223
+ * holds its focus on the screen rather than on the device layer's origin, and it has to place the
224
+ * plane exactly where this mesh places it. It used to restate `0.6` as a hand-copied literal; a
225
+ * change here would have moved the screen and left the measurement describing where it used to be.
226
+ */
227
+ export declare const DEVICE_PLANE_OFFSETS: {
228
+ /** The lid's dark bezel, behind the screenshot. */
229
+ readonly bezel: 0.3;
230
+ /** The screenshot itself. */
231
+ readonly screen: 0.6;
232
+ /** The glass sheen over it. */
233
+ readonly glass: 1.2;
234
+ };
235
+ export interface DeviceMeshProps {
236
+ kind: DeviceKind;
237
+ screen: Texture | null;
238
+ /** A sealed color surface. Mutually exclusive with `screen`. */
239
+ screenColor?: string;
240
+ materialOverrides?: Readonly<Record<string, SceneMaterialOverrideV2 | undefined>>;
241
+ finish?: string;
242
+ /**
243
+ * The screen glass's opacity, in the space the caller's pipeline blends in. Defaults to the
244
+ * canvas pipeline's number; a caller compositing in linear light passes the other one. See
245
+ * `DEVICE_GLASS_OPACITY_ENCODED` and `DEVICE_GLASS_OPACITY_LINEAR`.
246
+ */
247
+ glassOpacity?: number;
248
+ openAngle?: number;
249
+ width?: number;
250
+ position?: [number, number, number];
251
+ rotation?: [number, number, number];
252
+ /** Stable prepared object owner for runtime allocation receipts. */
253
+ resourceOwner?: string;
254
+ }
255
+ export declare function ownDeviceGeometryV1(geometry: BufferGeometry, owner: string, name: string, registerActual?: SceneActualResourceRegistrarV1): () => void;
256
+ export declare function DeviceMesh({ kind, screen, screenColor, materialOverrides, finish, glassOpacity, openAngle, width, position, rotation, resourceOwner }: DeviceMeshProps): import("react").JSX.Element;
@@ -0,0 +1,12 @@
1
+ import type { SceneCameraPose } from '../stage/camera.js';
2
+ /**
3
+ * Applies a Three-native scene camera pose to the fiber camera each frame, before Remotion advances
4
+ * the renderer.
5
+ *
6
+ * The pose arrives complete and already in output pixels; nothing is converted here except `fov`,
7
+ * which is radians everywhere in the contract and degrees only at three's own API — this is that
8
+ * boundary, and it is the only place in the scene lane where a degree exists.
9
+ */
10
+ export declare function SceneCameraRig({ pose }: {
11
+ pose: SceneCameraPose;
12
+ }): null;
@@ -0,0 +1,7 @@
1
+ import { type StageCamera } from '../stage/camera.js';
2
+ /** Applies the shared StageCamera to the fiber camera each frame, before Remotion advances the renderer. */
3
+ export declare function StageCameraRig({ camera, width, height }: {
4
+ camera: StageCamera;
5
+ width: number;
6
+ height: number;
7
+ }): null;
@@ -0,0 +1,228 @@
1
+ import { Vector3 } from 'three';
2
+ import { STUDIO_SHADOW_MAP_BUDGET } from '../../composition/scene/index.js';
3
+ export type StudioPreset = 'soft' | 'key' | 'rim';
4
+ export type StudioLightRole = 'key' | 'fill' | 'rim';
5
+ /**
6
+ * The shot's lighting profile (spec Decision 2, amendment A4, ruled 2026-09-10).
7
+ *
8
+ * Two values and no third. `studio` is the default and IS this rig unchanged; `studio-edge` is
9
+ * this rig plus the two fixed lights below. The profile belongs to the SHOT, never to an object:
10
+ * see `STUDIO_EDGE_LIGHTS` for why that distinction is the load-bearing half of the ruling.
11
+ */
12
+ export type SceneLightingProfile = 'studio' | 'studio-edge';
13
+ /** The default, stated once so no caller has to remember it. */
14
+ export declare const DEFAULT_LIGHTING_PROFILE: SceneLightingProfile;
15
+ /** The only two legal values, in the order refusals name them. */
16
+ export declare const LIGHTING_PROFILES: readonly SceneLightingProfile[];
17
+ export interface StudioRigProps {
18
+ /**
19
+ * A4: `studio` (default) is this rig unchanged; `studio-edge` adds exactly the two fixed,
20
+ * non-shadow-casting directional lights in `STUDIO_EDGE_LIGHTS`. Not animatable — a light
21
+ * count that changes mid-shot is not a rig — and sealed into the plan's `rigIdentity`.
22
+ */
23
+ lightingProfile?: SceneLightingProfile;
24
+ preset?: StudioPreset;
25
+ intensity?: number;
26
+ /** Floor height in px (Three y-up; negative is below the frame centre). Given in world units by the caller; not scaled by `worldScale`. */
27
+ floorY?: number;
28
+ shadowOpacity?: number;
29
+ environment?: boolean;
30
+ /**
31
+ * Multiplies the rig's own fixed layout — light positions, the shadow frustum and the floor
32
+ * extent — so a scene authored in reference pixels keeps its light and shadow coverage at any
33
+ * output size. 1 (the default) is the tuned 1080p layout below, unchanged.
34
+ */
35
+ worldScale?: number;
36
+ /**
37
+ * The world the shadow must cover, in world units (Three axes): the union of the reference
38
+ * frame and every caster's bounds. The caster's frustum grows past its tuned coverage to hold
39
+ * it (see `studioShadowFrustum`); absent, the frustum is the tuned `worldScale` coverage alone.
40
+ */
41
+ shadowBounds?: ShadowBounds;
42
+ }
43
+ /** An axis-aligned box in world units, Three axes (y up). */
44
+ export interface ShadowBounds {
45
+ minX: number;
46
+ maxX: number;
47
+ minY: number;
48
+ maxY: number;
49
+ minZ: number;
50
+ maxZ: number;
51
+ }
52
+ export interface StudioLight {
53
+ role: StudioLightRole;
54
+ position: [number, number, number];
55
+ castShadow: boolean;
56
+ }
57
+ /**
58
+ * Where the three lights sit, and which one casts.
59
+ *
60
+ * Exported as data because the two properties that matter here are not otherwise checkable
61
+ * without a GPU: that the shadow lands where the camera can see it, and that the preset the
62
+ * catalog calls "hard key" is actually hardest on the faces an audience looks at.
63
+ *
64
+ * The KEY is in front (+z). Everything this rig lights is framed head-on, so the camera-facing
65
+ * faces are the whole performance: a key behind the subject leaves them on fill alone and the
66
+ * `key` preset comes out flatter than `soft`, which inverts the table below.
67
+ *
68
+ * The RIM is above and behind, and it is the shadow caster — the only light whose shadow the
69
+ * camera can see. Subjects here sit on the shadow floor, so a front light throws its shadow
70
+ * backwards where the subject's own body hides it; `device-showcase` used to render a laptop
71
+ * with no ground contact anywhere in frame, the exact flat-placeholder tell the lit scenes exist
72
+ * to remove. From behind, the shadow falls toward the camera and lands as a band on the floor
73
+ * just in front of the subject.
74
+ *
75
+ * The rim's [0, 1300, -1900] is 34 degrees above the horizon and on axis in x, and all three
76
+ * numbers are load-bearing for that band: a lateral offset shears it to one side until the floor
77
+ * beside the subject is inside it, a steeper light shortens the throw until it hides under the
78
+ * subject, and a shallower one stretches it across the whole floor.
79
+ */
80
+ export declare const STUDIO_LIGHTS: readonly StudioLight[];
81
+ /**
82
+ * The `studio-edge` profile's two lights: POSITION, COUNT and INTENSITY, as constants.
83
+ *
84
+ * They are constants and not fields, and that is the ruling rather than an implementation choice.
85
+ * A4 gives the shot one boolean-shaped decision — which of two profiles — and nothing else: no
86
+ * `slabEdgeLighting`, no per-object light, no authored position and no authored intensity anywhere
87
+ * in the object contract. **Adding or removing slabs never changes the light count.** It is two
88
+ * under `studio-edge` whether the shot holds one slab, twelve or none, and zero extra under
89
+ * `studio`. `scene_object_light_field_unsupported` is what refuses the alternative.
90
+ *
91
+ * `[±2000, 350, −700]` reference units, scaled by `worldScale` like every other rig position, is
92
+ * the pair the I0 intensity sweep was measured on (report §7/A4). They are the only way to get a
93
+ * SIDE silhouette rim at all: the rig's own rim light is on-axis in x, so `N·L` is exactly 0 for a
94
+ * ±x-facing bevel normal, and scaling it 1×–8× moves the side silhouette by nothing at any
95
+ * multiplier. The rim is a geometry fact about where the light is, not about how bright it is.
96
+ *
97
+ * **They cast no shadow, and that is what makes the neighbouring-device gate structural.** The
98
+ * rig's rim light stays the sole caster, so the shadow-catching floor — transparent where
99
+ * unshadowed — is untouched and the contact band cannot move. It also means the profile allocates
100
+ * **no shadow map and no render target**: the §4.2 ledger is identical under both profiles.
101
+ */
102
+ export declare const STUDIO_EDGE_LIGHTS: readonly [number, number, number][];
103
+ /**
104
+ * The `studio-edge` intensity, frozen at 20 by I0's eight-point sweep (report §7/A4): 0 → 1.07×
105
+ * body and no run; 2 → 2.82× / 4 px; 6 → 3.60× / 7 px; 12 → 3.84× / 7 px; **20 → 3.94× / 7 px**;
106
+ * 26 → 3.98× / 7 px; 40 → 4.02× / 10 px; 60 → 4.05× / 10 px. 20 is where the run reaches its
107
+ * plateau; past it the rim widens without getting brighter in the way the gate measures.
108
+ */
109
+ export declare const STUDIO_EDGE_INTENSITY = 20;
110
+ /** How many extra lights a profile mounts. Two under `studio-edge`, none under `studio`. */
111
+ export declare function studioEdgeLightCount(profile: SceneLightingProfile): number;
112
+ export interface StudioShadowFrustum {
113
+ /** Half-width of the caster's orthographic frustum, world units. */
114
+ extent: number;
115
+ near: number;
116
+ far: number;
117
+ /** Shadow map edge in texels; scales with `extent` up to `STUDIO_SHADOW_MAP_BUDGET`. */
118
+ mapSize: number;
119
+ }
120
+ /** The caster's frustum at `worldScale` 1: tuned against a 1920x1080 render (see StudioRig). */
121
+ export declare const STUDIO_SHADOW_FRUSTUM: StudioShadowFrustum;
122
+ /**
123
+ * The largest shadow map the rig will allocate. The tuned frame uses 2048; a frustum that has to
124
+ * grow past the tuned coverage keeps its texel density (and so the band's softness) by doubling
125
+ * the map, until this cap, after which the map is spread thinner.
126
+ *
127
+ * Defined in `@cueframe/composition/scene` rather than here because it is not only this rig's
128
+ * number: `@cueframe/component-runtime`'s `webGlRefusal` compares it against the host's reported
129
+ * `MAX_TEXTURE_SIZE` and refuses the browser — typed `component_graphics_unavailable`, naming the
130
+ * reported limit and this budget — before a scene shot is captured on a host that cannot afford
131
+ * it. Both lanes reach that check: the local component lane through
132
+ * `assertComponentBrowserHardware`, and the composition lane through the tracked
133
+ * `scene-shot-contract.bundle.mjs`. So an under-budget host refuses at admission; the map is
134
+ * never halved here to fit, and 4096 is never requested from a host that cannot give it.
135
+ *
136
+ * Measured on the desktop backend the packaged app actually renders through by
137
+ * `apps/studio/scripts/probe-gpu-limits.mjs` — Chrome for Testing with `gl: 'angle'` chosen by
138
+ * `resolveComponentChromiumConfig`, `ANGLE (Apple, ANGLE Metal Renderer: Apple M5)`:
139
+ * `MAX_TEXTURE_SIZE`, `MAX_RENDERBUFFER_SIZE` and `MAX_VIEWPORT_DIMS` are all 16384, four times
140
+ * this cap in each dimension. Allocating this exact shape (RGBA8 colour texture plus a
141
+ * DEPTH_COMPONENT24 renderbuffer) at 1024, 2048, 4096 and 8192 and keeping all four live at once
142
+ * — about 680 MB — completed every framebuffer with `gl.getError() === 0` and no context loss.
143
+ * `apps/studio/scripts/packaged-render-smoke.mjs` renders the mixed-shot fixture through the
144
+ * assembled `Resources` tree on that same backend. 4096 stands.
145
+ *
146
+ * WHAT THIS BUDGET DOES NOT COVER, stated because the uniform world pass made it bigger: every
147
+ * scene shot now composes through two full-frame half-float colour targets (`focusResources.ts`),
148
+ * focus or no focus. `MAX_TEXTURE_SIZE` bounds a DIMENSION, not a memory footprint, and WebGL
149
+ * exposes no query for the latter — so admission can refuse a host whose textures are too small
150
+ * and a host with no renderable half-float colour, and it cannot refuse a host that has both and
151
+ * not enough memory. At 3840x2160 the pass costs 66.4 MB per RGBA16F plane: 66.4 (world resolve)
152
+ * + 33.2 (DEPTH_COMPONENT24) + 66.4 (gathered) = 166 MB single-sampled, and a further
153
+ * 99.5 MB per canvas MSAA sample on the world target, so 564 MB at the 4x this canvas reports.
154
+ * At 1920x1080 the same figures are 41.5 MB and 141 MB. The shadow map at this budget adds 67 MB.
155
+ * The measurement above kept about 680 MB of framebuffers live on the packaged backend without a
156
+ * context loss, which is the headroom that number is evidence for. A host that runs out anyway
157
+ * fails as an incomplete framebuffer rather than as a typed refusal; closing that needs a
158
+ * completeness gate exercised against a real GPU, and it is recorded as owed rather than added
159
+ * unexercised (final fix wave, item 18).
160
+ */
161
+ export { STUDIO_SHADOW_MAP_BUDGET };
162
+ /**
163
+ * How far past the bounds the frustum reaches, as a factor: room for the PCF taps at the map's
164
+ * edge and for the band's own soft falloff beyond the caster's silhouette.
165
+ */
166
+ export declare const STUDIO_SHADOW_REACH_PAD = 1.25;
167
+ /** Floor plane edge at `worldScale` 1. */
168
+ export declare const STUDIO_FLOOR_EXTENT = 12000;
169
+ /**
170
+ * The caster's view basis at `worldScale`, built the way Three's `Matrix4.lookAt` builds a
171
+ * directional light's shadow camera looking from the rim at the origin with y up: `right` and
172
+ * `up` span the orthographic frustum's plane, `forward` is depth away from the light.
173
+ */
174
+ export declare function studioCasterBasis(worldScale: number): {
175
+ eye: Vector3;
176
+ right: Vector3;
177
+ up: Vector3;
178
+ forward: Vector3;
179
+ };
180
+ /**
181
+ * The shadow frustum for a world scaled by `worldScale`, grown to cover `bounds` when given.
182
+ *
183
+ * Without bounds this is the tuned coverage scaled: `STUDIO_SHADOW_FRUSTUM` times `worldScale`
184
+ * with the 2048 map. With bounds, each corner of the box is projected into the caster's view; the
185
+ * half-extent becomes the larger of the tuned coverage and the corners' reach times
186
+ * `STUDIO_SHADOW_REACH_PAD`, near/far widen the same way when a corner lies outside the tuned
187
+ * depth range, and the map doubles with the extent so texel density holds until the budget. A
188
+ * receiver under a caster shares the caster's view coordinates (the shadow travels along the
189
+ * light), so covering the casters covers where their shadows land sideways.
190
+ *
191
+ * Given `floorY`, the depth range also folds in where each corner's ray meets the floor, which is
192
+ * further from the light than the corner itself: without it a caster near the tuned far plane
193
+ * would have its band cut off at the exact distance where it becomes visible. Pure: no renderer,
194
+ * no scene.
195
+ */
196
+ export declare function studioShadowFrustum(worldScale: number, bounds?: ShadowBounds, floorY?: number): StudioShadowFrustum;
197
+ /** A rig light's position for a world scaled by `worldScale`. */
198
+ export declare function studioLightPosition(light: StudioLight, worldScale: number): [number, number, number];
199
+ /**
200
+ * Per-preset intensities, tuned against the arrangement above: `key` is the hard-key look, `soft`
201
+ * the default wrap, `rim` the backlit one. `cameraFacingLight` is what orders them.
202
+ */
203
+ export declare const STUDIO_PRESETS: Record<StudioPreset, Record<'hemi' | StudioLightRole, number>>;
204
+ /**
205
+ * Direct-light term a camera-facing surface (normal +z) receives at `preset`: the Lambert sum
206
+ * over the rig's directional lights. Pure — no renderer, no scene.
207
+ *
208
+ * This is the number that decides whether a preset reads hard or flat on the faces an audience
209
+ * actually sees, so it is what the preset table is ordered by.
210
+ */
211
+ export declare function cameraFacingLight(preset: StudioPreset, intensity?: number): number;
212
+ /**
213
+ * Three-point studio lighting with a room environment for reflections and a shadow-catching floor.
214
+ *
215
+ * At `worldScale` 1 with no `shadowBounds` the shadow camera and `floorY` are the tuned
216
+ * 1080p-class layout: the caster's orthographic frustum at +/-1600 world units on a 2048 map and
217
+ * `floorY` at -420, both chosen against a 1920x1080 render. A legacy caller rendering 3840 wide
218
+ * without a `worldScale` sees the visible floor run past +/-1600, so the contact band is clipped
219
+ * with a hard vertical edge roughly 320 px inside each side of the frame; that caller's fix is
220
+ * `worldScale`. Callers that author in reference pixels (SceneShot) pass their reference scale as
221
+ * `worldScale` and the world's bounds as `shadowBounds`, so the frustum scales with the frame and
222
+ * grows past the tuned coverage when a caster is placed beyond it — see `studioShadowFrustum` for
223
+ * how the map follows.
224
+ *
225
+ * Do not change the `worldScale` 1 numbers without re-verifying the gated `stage-device-render`
226
+ * and `scene-shot-render` tests: their luma assertions are measured against these exact values.
227
+ */
228
+ export declare function StudioRig({ lightingProfile, preset, intensity, floorY, shadowOpacity, environment, worldScale, shadowBounds }: StudioRigProps): import("react").JSX.Element;
@@ -1,4 +1,5 @@
1
1
  import React from 'react';
2
+ import { type SceneCameraPose, type StageCamera } from '../stage/camera.js';
2
3
  interface ThreeCanvasProps {
3
4
  children: React.ReactNode;
4
5
  width?: number;
@@ -7,6 +8,27 @@ interface ThreeCanvasProps {
7
8
  near?: number;
8
9
  far?: number;
9
10
  cameraPosition?: [number, number, number];
11
+ /**
12
+ * Orthographic camera with its frustum pinned 1:1 to `width`×`height` pixels
13
+ * (left=-w/2, right=w/2, top=h/2, bottom=-h/2). Pair with flexBoxToThree so
14
+ * objects land exactly on layout boxes. Perspective when false (default).
15
+ */
16
+ orthographic?: boolean;
17
+ /**
18
+ * Drive the fiber camera from the shared stage camera so meshes and DOM layers
19
+ * see the same view. Always perspective — it wins over `orthographic`, `fov`,
20
+ * `near`, `far` and `cameraPosition`.
21
+ */
22
+ stageCamera?: StageCamera;
23
+ /**
24
+ * Drive the fiber camera from a Three-native scene camera pose (Decision 1 / report §5.3): the
25
+ * scene lane's camera, already in output pixels, `fov` in radians. Wins over everything, and is
26
+ * mutually exclusive with `stageCamera` — a canvas driven by both would have two conventions.
27
+ */
28
+ sceneCamera?: SceneCameraPose;
29
+ shadows?: boolean;
30
+ dpr?: number;
31
+ gl?: Record<string, unknown>;
10
32
  style?: React.CSSProperties;
11
33
  }
12
34
  export declare const ThreeCanvas: React.FC<ThreeCanvasProps>;
@@ -0,0 +1,23 @@
1
+ import { CanvasTexture } from 'three';
2
+ export interface ScreenLayout {
3
+ sidebar: {
4
+ x: number;
5
+ y: number;
6
+ w: number;
7
+ h: number;
8
+ };
9
+ cards: Array<{
10
+ x: number;
11
+ y: number;
12
+ w: number;
13
+ h: number;
14
+ }>;
15
+ chart: Array<{
16
+ x: number;
17
+ y: number;
18
+ }>;
19
+ }
20
+ /** Pure layout for the placeholder dashboard; the curve is a fixed smooth polynomial, no randomness. */
21
+ export declare function defaultScreenLayout(w: number, h: number): ScreenLayout;
22
+ /** Browser-only: draws the placeholder into a canvas texture. */
23
+ export declare function makeDefaultScreenTexture(accent: string, w?: number, h?: number): CanvasTexture;
@@ -1,2 +1,8 @@
1
1
  export { ThreeCanvas } from './ThreeCanvas.js';
2
- export { Box, Sphere, Cylinder, Cone, Torus, TorusKnot, Plane, Circle, Ring, Dodecahedron, Icosahedron, Octahedron, Tetrahedron, Capsule, Extrude, Lathe, Tube, Text, Text3D, Center, Float, Environment, ContactShadows, AccumulativeShadows, RandomizedLight, Lightformer, Stage, Sky, Stars, Sparkles, Cloud, Line, QuadraticBezierLine, CubicBezierLine, CatmullRomLine, MeshDistortMaterial, MeshWobbleMaterial, MeshReflectorMaterial, MeshTransmissionMaterial, Edges, Outlines, GradientTexture, RoundedBox, Billboard, Html, PivotControls, Grid, Backdrop, } from './drei.js';
2
+ export { StageCameraRig } from './StageCameraRig.js';
3
+ export { SceneCameraRig } from './SceneCameraRig.js';
4
+ export { useImageTexture } from './useImageTexture.js';
5
+ export { StudioRig, STUDIO_SHADOW_FRUSTUM, STUDIO_SHADOW_MAP_BUDGET, STUDIO_SHADOW_REACH_PAD, STUDIO_FLOOR_EXTENT, studioShadowFrustum, studioLightPosition, STUDIO_EDGE_LIGHTS, STUDIO_EDGE_INTENSITY, studioEdgeLightCount, DEFAULT_LIGHTING_PROFILE, LIGHTING_PROFILES, type StudioRigProps, type StudioShadowFrustum, type ShadowBounds, type SceneLightingProfile, } from './StudioRig.js';
6
+ export { DeviceMesh, deviceDimensions, laptopLayout, lidRotationX, DEVICE_GLASS_OPACITY_ENCODED, DEVICE_GLASS_OPACITY_LINEAR, DEVICE_LIT_MATERIALS, DEVICE_PLANE_OFFSETS, type DeviceKind, type DeviceMeshProps, type DeviceDimensions, type LaptopLayout, } from './DeviceMesh.js';
7
+ export { SELF_TONE_MAPPED, UNLIT_COLOUR_MANAGED, toneMapInTheMaterial, toneMappingPreamble } from './toneMapping.js';
8
+ export { makeDefaultScreenTexture, defaultScreenLayout, type ScreenLayout } from './defaultScreen.js';
@@ -0,0 +1,29 @@
1
+ /**
2
+ * The disposal policy behind `useImageTexture`, kept pure so it can be checked without a
3
+ * renderer: a texture is disposed only after the commit that stops using it, never at the moment
4
+ * its replacement finishes loading, because until React has committed the replacement into the
5
+ * material the old one is still what the frame draws.
6
+ */
7
+ /** Anything the policy may dispose; structural so tests need no Three. */
8
+ export interface Disposable {
9
+ dispose(): void;
10
+ }
11
+ /** What one texture owner holds between commits. */
12
+ export interface HeldTexture<T extends Disposable = Disposable> {
13
+ /** The texture the last commit drew with. */
14
+ drawn: T | null;
15
+ }
16
+ export declare const NO_TEXTURE: HeldTexture<never>;
17
+ /**
18
+ * React committed `next` as the drawn texture (or `null`, when the source went away). The one it
19
+ * replaces has had its last committed use, so it goes now; committing the same texture again is
20
+ * a no-op.
21
+ */
22
+ export declare function commitImageTexture<T extends Disposable>(held: HeldTexture<T>, next: T | null): HeldTexture<T>;
23
+ /** The owner unmounted: whatever it last drew with has no user left. */
24
+ export declare function releaseImageTexture<T extends Disposable>(held: HeldTexture<T>): HeldTexture<never>;
25
+ /**
26
+ * A load finished for an owner that has since unmounted or moved to another source: the texture
27
+ * never reaches React and nothing else is touched.
28
+ */
29
+ export declare function discardStaleTexture<T extends Disposable>(texture: T): void;