@galacean/engine-core 1.6.8 → 1.6.10

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 (403) hide show
  1. package/dist/main.js +37541 -0
  2. package/dist/main.js.map +1 -0
  3. package/dist/module.js +37259 -0
  4. package/dist/module.js.map +1 -0
  5. package/package.json +3 -3
  6. package/types/2d/assembler/ISpriteAssembler.d.ts +11 -0
  7. package/types/2d/assembler/ISpriteRenderer.d.ts +16 -0
  8. package/types/2d/assembler/SimpleSpriteAssembler.d.ts +13 -0
  9. package/types/2d/assembler/SlicedSpriteAssembler.d.ts +15 -0
  10. package/types/2d/assembler/TiledSpriteAssembler.d.ts +17 -0
  11. package/types/2d/atlas/FontAtlas.d.ts +1 -0
  12. package/types/2d/atlas/SpriteAtlas.d.ts +32 -0
  13. package/types/2d/atlas/types.d.ts +69 -0
  14. package/types/2d/enums/FontStyle.d.ts +11 -0
  15. package/types/2d/enums/SpriteDrawMode.d.ts +11 -0
  16. package/types/2d/enums/SpriteMaskInteraction.d.ts +11 -0
  17. package/types/2d/enums/SpriteModifyFlags.d.ts +23 -0
  18. package/types/2d/enums/SpriteTileMode.d.ts +11 -0
  19. package/types/2d/enums/TextAlignment.d.ts +22 -0
  20. package/types/2d/enums/TextOverflow.d.ts +9 -0
  21. package/types/2d/index.d.ts +16 -0
  22. package/types/2d/sprite/Sprite.d.ts +106 -0
  23. package/types/2d/sprite/SpriteMask.d.ts +70 -0
  24. package/types/2d/sprite/SpriteRenderer.d.ts +95 -0
  25. package/types/2d/sprite/index.d.ts +3 -0
  26. package/types/2d/text/CharInfo.d.ts +1 -0
  27. package/types/2d/text/CharRenderInfo.d.ts +1 -0
  28. package/types/2d/text/Font.d.ts +21 -0
  29. package/types/2d/text/ITextRenderer.d.ts +8 -0
  30. package/types/2d/text/SubFont.d.ts +1 -0
  31. package/types/2d/text/TextRenderer.d.ts +122 -0
  32. package/types/2d/text/TextUtils.d.ts +1 -0
  33. package/types/2d/text/index.d.ts +5 -0
  34. package/types/Background.d.ts +53 -0
  35. package/types/BasicResources.d.ts +2 -0
  36. package/types/BoolUpdateFlag.d.ts +12 -0
  37. package/types/Camera.d.ts +321 -0
  38. package/types/Canvas.d.ts +19 -0
  39. package/types/Component.d.ts +27 -0
  40. package/types/ComponentsDependencies.d.ts +22 -0
  41. package/types/ComponentsManager.d.ts +52 -0
  42. package/types/Engine.d.ts +150 -0
  43. package/types/EngineSettings.d.ts +5 -0
  44. package/types/Entity.d.ts +170 -0
  45. package/types/Layer.d.ts +73 -0
  46. package/types/Platform.d.ts +15 -0
  47. package/types/Polyfill.d.ts +1 -0
  48. package/types/RenderPipeline/BasicRenderPipeline.d.ts +55 -0
  49. package/types/RenderPipeline/BatchUtils.d.ts +1 -0
  50. package/types/RenderPipeline/BatcherManager.d.ts +1 -0
  51. package/types/RenderPipeline/Blitter.d.ts +28 -0
  52. package/types/RenderPipeline/CullingResults.d.ts +1 -0
  53. package/types/RenderPipeline/DepthOnlyPass.d.ts +1 -0
  54. package/types/RenderPipeline/MaskManager.d.ts +1 -0
  55. package/types/RenderPipeline/OpaqueTexturePass.d.ts +1 -0
  56. package/types/RenderPipeline/PipelinePass.d.ts +16 -0
  57. package/types/RenderPipeline/PipelineUtils.d.ts +1 -0
  58. package/types/RenderPipeline/PrimitiveChunk.d.ts +1 -0
  59. package/types/RenderPipeline/PrimitiveChunkManager.d.ts +1 -0
  60. package/types/RenderPipeline/RenderContext.d.ts +1 -0
  61. package/types/RenderPipeline/RenderElement.d.ts +12 -0
  62. package/types/RenderPipeline/RenderQueue.d.ts +1 -0
  63. package/types/RenderPipeline/SubPrimitiveChunk.d.ts +1 -0
  64. package/types/RenderPipeline/SubRenderElement.d.ts +22 -0
  65. package/types/RenderPipeline/VertexArea.d.ts +1 -0
  66. package/types/RenderPipeline/enums/PipelineStage.d.ts +11 -0
  67. package/types/RenderPipeline/enums/RenderQueueMaskType.d.ts +1 -0
  68. package/types/RenderPipeline/index.d.ts +5 -0
  69. package/types/Renderer.d.ts +135 -0
  70. package/types/Scene.d.ts +183 -0
  71. package/types/SceneManager.d.ts +51 -0
  72. package/types/Script.d.ts +144 -0
  73. package/types/SystemInfo.d.ts +27 -0
  74. package/types/Transform.d.ts +304 -0
  75. package/types/UpdateFlag.d.ts +20 -0
  76. package/types/UpdateFlagManager.d.ts +1 -0
  77. package/types/Utils.d.ts +37 -0
  78. package/types/VirtualCamera.d.ts +1 -0
  79. package/types/animation/AnimationClip.d.ts +87 -0
  80. package/types/animation/AnimationClipCurveBinding.d.ts +30 -0
  81. package/types/animation/AnimationEvent.d.ts +11 -0
  82. package/types/animation/Animator.d.ts +154 -0
  83. package/types/animation/AnimatorCondition.d.ts +13 -0
  84. package/types/animation/AnimatorController.d.ts +72 -0
  85. package/types/animation/AnimatorControllerLayer.d.ts +21 -0
  86. package/types/animation/AnimatorControllerParameter.d.ts +14 -0
  87. package/types/animation/AnimatorLayerMask.d.ts +45 -0
  88. package/types/animation/AnimatorState.d.ts +69 -0
  89. package/types/animation/AnimatorStateMachine.d.ts +85 -0
  90. package/types/animation/AnimatorStateTransition.d.ts +59 -0
  91. package/types/animation/AnimatorStateTransitionCollection.d.ts +1 -0
  92. package/types/animation/Keyframe.d.ts +20 -0
  93. package/types/animation/LayerPathMask.d.ts +16 -0
  94. package/types/animation/StateMachineScript.d.ts +32 -0
  95. package/types/animation/animationCurve/AnimationArrayCurve.d.ts +7 -0
  96. package/types/animation/animationCurve/AnimationBoolCurve.d.ts +7 -0
  97. package/types/animation/animationCurve/AnimationColorCurve.d.ts +8 -0
  98. package/types/animation/animationCurve/AnimationCurve.d.ts +39 -0
  99. package/types/animation/animationCurve/AnimationFloatArrayCurve.d.ts +11 -0
  100. package/types/animation/animationCurve/AnimationFloatCurve.d.ts +7 -0
  101. package/types/animation/animationCurve/AnimationQuaternionCurve.d.ts +8 -0
  102. package/types/animation/animationCurve/AnimationRectCurve.d.ts +8 -0
  103. package/types/animation/animationCurve/AnimationRefCurve.d.ts +8 -0
  104. package/types/animation/animationCurve/AnimationStringCurve.d.ts +7 -0
  105. package/types/animation/animationCurve/AnimationVector2Curve.d.ts +8 -0
  106. package/types/animation/animationCurve/AnimationVector3Curve.d.ts +8 -0
  107. package/types/animation/animationCurve/AnimationVector4Curve.d.ts +8 -0
  108. package/types/animation/animationCurve/index.d.ts +13 -0
  109. package/types/animation/animationCurve/interfaces/IAnimationCurveCalculator.d.ts +1 -0
  110. package/types/animation/enums/AnimatorConditionMode.d.ts +17 -0
  111. package/types/animation/enums/AnimatorCullingMode.d.ts +9 -0
  112. package/types/animation/enums/AnimatorLayerBlendingMode.d.ts +4 -0
  113. package/types/animation/enums/AnimatorStatePlayState.d.ts +1 -0
  114. package/types/animation/enums/InterpolationType.d.ts +13 -0
  115. package/types/animation/enums/LayerState.d.ts +15 -0
  116. package/types/animation/enums/PlayState.d.ts +13 -0
  117. package/types/animation/enums/WrapMode.d.ts +9 -0
  118. package/types/animation/index.d.ts +25 -0
  119. package/types/animation/internal/AnimationCurveLayerOwner.d.ts +1 -0
  120. package/types/animation/internal/AnimationEventHandler.d.ts +1 -0
  121. package/types/animation/internal/AnimatorLayerData.d.ts +1 -0
  122. package/types/animation/internal/AnimatorStateData.d.ts +1 -0
  123. package/types/animation/internal/AnimatorStatePlayData.d.ts +1 -0
  124. package/types/animation/internal/AnimatorTempValue.d.ts +1 -0
  125. package/types/animation/internal/animationCurveOwner/AnimationCurveOwner.d.ts +5 -0
  126. package/types/animation/internal/animationCurveOwner/assembler/BlendShapeWeightsAnimationCurveOwnerAssembler.d.ts +1 -0
  127. package/types/animation/internal/animationCurveOwner/assembler/IAnimationCurveOwnerAssembler.d.ts +1 -0
  128. package/types/animation/internal/animationCurveOwner/assembler/PositionAnimationCurveOwnerAssembler.d.ts +1 -0
  129. package/types/animation/internal/animationCurveOwner/assembler/RotationAnimationCurveOwnerAssembler.d.ts +1 -0
  130. package/types/animation/internal/animationCurveOwner/assembler/ScaleAnimationCurveOwnerAssembler.d.ts +1 -0
  131. package/types/animation/internal/animationCurveOwner/assembler/UniversalAnimationCurveOwnerAssembler.d.ts +1 -0
  132. package/types/asset/AssetPromise.d.ts +88 -0
  133. package/types/asset/AssetType.d.ts +66 -0
  134. package/types/asset/ContentRestorer.d.ts +17 -0
  135. package/types/asset/GraphicsResource.d.ts +9 -0
  136. package/types/asset/IReferable.d.ts +2 -0
  137. package/types/asset/LoadItem.d.ts +40 -0
  138. package/types/asset/Loader.d.ts +37 -0
  139. package/types/asset/ReferResource.d.ts +23 -0
  140. package/types/asset/ResourceManager.d.ts +121 -0
  141. package/types/asset/request.d.ts +36 -0
  142. package/types/audio/AudioClip.d.ts +24 -0
  143. package/types/audio/AudioManager.d.ts +1 -0
  144. package/types/audio/AudioSource.d.ts +72 -0
  145. package/types/audio/index.d.ts +3 -0
  146. package/types/base/Constant.d.ts +116 -0
  147. package/types/base/EngineObject.d.ts +25 -0
  148. package/types/base/EventDispatcher.d.ts +66 -0
  149. package/types/base/Logger.d.ts +11 -0
  150. package/types/base/StaticInterfaceImplement.d.ts +5 -0
  151. package/types/base/Time.d.ts +44 -0
  152. package/types/base/index.d.ts +5 -0
  153. package/types/clone/CloneManager.d.ts +31 -0
  154. package/types/clone/ComponentCloner.d.ts +17 -0
  155. package/types/clone/enums/CloneMode.d.ts +13 -0
  156. package/types/enums/ActiveChangeFlag.d.ts +6 -0
  157. package/types/enums/AntiAliasing.d.ts +7 -0
  158. package/types/enums/BackgroundMode.d.ts +9 -0
  159. package/types/enums/BackgroundTextureFillMode.d.ts +8 -0
  160. package/types/enums/CameraClearFlags.d.ts +13 -0
  161. package/types/enums/CameraModifyFlags.d.ts +17 -0
  162. package/types/enums/CameraType.d.ts +1 -0
  163. package/types/enums/DepthTextureMode.d.ts +7 -0
  164. package/types/enums/Downsampling.d.ts +11 -0
  165. package/types/enums/EntityModifyFlags.d.ts +9 -0
  166. package/types/enums/FogMode.d.ts +13 -0
  167. package/types/enums/MSAASamples.d.ts +13 -0
  168. package/types/enums/ReplacementFailureStrategy.d.ts +9 -0
  169. package/types/enums/SpriteMaskLayer.d.ts +73 -0
  170. package/types/env-probe/CubeProbe.d.ts +27 -0
  171. package/types/env-probe/Probe.d.ts +52 -0
  172. package/types/env-probe/index.d.ts +2 -0
  173. package/types/graphic/Buffer.d.ts +114 -0
  174. package/types/graphic/BufferUtil.d.ts +12 -0
  175. package/types/graphic/IndexBufferBinding.d.ts +21 -0
  176. package/types/graphic/Mesh.d.ts +58 -0
  177. package/types/graphic/Primitive.d.ts +1 -0
  178. package/types/graphic/SubMesh.d.ts +8 -0
  179. package/types/graphic/SubPrimitive.d.ts +19 -0
  180. package/types/graphic/VertexBufferBinding.d.ts +20 -0
  181. package/types/graphic/VertexElement.d.ts +48 -0
  182. package/types/graphic/enums/BufferBindFlag.d.ts +9 -0
  183. package/types/graphic/enums/BufferUsage.d.ts +11 -0
  184. package/types/graphic/enums/IndexFormat.d.ts +11 -0
  185. package/types/graphic/enums/MeshTopology.d.ts +19 -0
  186. package/types/graphic/enums/SetDataOptions.d.ts +9 -0
  187. package/types/graphic/enums/VertexElementFormat.d.ts +37 -0
  188. package/types/graphic/index.d.ts +15 -0
  189. package/types/index.d.ts +68 -0
  190. package/types/input/InputManager.d.ts +65 -0
  191. package/types/input/enums/Keys.d.ts +398 -0
  192. package/types/input/enums/PointerButton.d.ts +33 -0
  193. package/types/input/enums/PointerPhase.d.ts +15 -0
  194. package/types/input/index.d.ts +8 -0
  195. package/types/input/interface/IInput.d.ts +10 -0
  196. package/types/input/keyboard/KeyboardManager.d.ts +1 -0
  197. package/types/input/pointer/Pointer.d.ts +31 -0
  198. package/types/input/pointer/PointerEventData.d.ts +12 -0
  199. package/types/input/pointer/PointerManager.d.ts +9 -0
  200. package/types/input/pointer/emitter/IHitResult.d.ts +1 -0
  201. package/types/input/pointer/emitter/PhysicsPointerEventEmitter.d.ts +1 -0
  202. package/types/input/pointer/emitter/PointerEventEmitter.d.ts +30 -0
  203. package/types/input/wheel/WheelManager.d.ts +1 -0
  204. package/types/lighting/AmbientLight.d.ts +70 -0
  205. package/types/lighting/DirectLight.d.ts +32 -0
  206. package/types/lighting/KHR_lights.d.ts +4 -0
  207. package/types/lighting/Light.d.ts +45 -0
  208. package/types/lighting/LightManager.d.ts +12 -0
  209. package/types/lighting/PointLight.d.ts +26 -0
  210. package/types/lighting/SpotLight.d.ts +45 -0
  211. package/types/lighting/ambientOcclusion/AmbientOcclusion.d.ts +79 -0
  212. package/types/lighting/ambientOcclusion/ScalableAmbientObscurancePass.d.ts +1 -0
  213. package/types/lighting/ambientOcclusion/index.d.ts +2 -0
  214. package/types/lighting/enums/AmbientOcclusionQuality.d.ts +11 -0
  215. package/types/lighting/enums/DiffuseMode.d.ts +13 -0
  216. package/types/lighting/index.d.ts +7 -0
  217. package/types/material/BaseMaterial.d.ts +88 -0
  218. package/types/material/BlinnPhongMaterial.d.ts +68 -0
  219. package/types/material/Material.d.ts +52 -0
  220. package/types/material/PBRMaterial.d.ts +311 -0
  221. package/types/material/UnlitMaterial.d.ts +33 -0
  222. package/types/material/enums/BlendMode.d.ts +9 -0
  223. package/types/material/enums/Refraction.d.ts +9 -0
  224. package/types/material/enums/RenderFace.d.ts +11 -0
  225. package/types/material/enums/TextureCoordinate.d.ts +13 -0
  226. package/types/material/index.d.ts +9 -0
  227. package/types/material/utils/PrefilteredDFG.d.ts +7 -0
  228. package/types/mesh/BlendShape.d.ts +39 -0
  229. package/types/mesh/BlendShapeFrame.d.ts +44 -0
  230. package/types/mesh/BlendShapeManager.d.ts +1 -0
  231. package/types/mesh/BufferMesh.d.ts +59 -0
  232. package/types/mesh/MeshRenderer.d.ts +25 -0
  233. package/types/mesh/ModelMesh.d.ts +254 -0
  234. package/types/mesh/PrimitiveMesh.d.ts +112 -0
  235. package/types/mesh/PrimitiveMeshRestorer.d.ts +1 -0
  236. package/types/mesh/Skin.d.ts +35 -0
  237. package/types/mesh/SkinnedMeshRenderer.d.ts +50 -0
  238. package/types/mesh/enums/VertexAttribute.d.ts +33 -0
  239. package/types/mesh/index.d.ts +9 -0
  240. package/types/particle/ParticleBufferUtils.d.ts +1 -0
  241. package/types/particle/ParticleGenerator.d.ts +94 -0
  242. package/types/particle/ParticleMaterial.d.ts +38 -0
  243. package/types/particle/ParticleRenderer.d.ts +47 -0
  244. package/types/particle/enums/ParticleCurveMode.d.ts +9 -0
  245. package/types/particle/enums/ParticleGradientMode.d.ts +9 -0
  246. package/types/particle/enums/ParticleRandomSubSeeds.d.ts +1 -0
  247. package/types/particle/enums/ParticleRenderMode.d.ts +17 -0
  248. package/types/particle/enums/ParticleScaleMode.d.ts +11 -0
  249. package/types/particle/enums/ParticleSimulationSpace.d.ts +9 -0
  250. package/types/particle/enums/ParticleStopMode.d.ts +6 -0
  251. package/types/particle/enums/attributes/BillboardParticleVertexAttribute.d.ts +1 -0
  252. package/types/particle/enums/attributes/MeshParticleVertexAttribute.d.ts +5 -0
  253. package/types/particle/enums/attributes/ParticleInstanceVertexAttribute.d.ts +1 -0
  254. package/types/particle/index.d.ts +22 -0
  255. package/types/particle/modules/Burst.d.ts +14 -0
  256. package/types/particle/modules/ColorOverLifetimeModule.d.ts +20 -0
  257. package/types/particle/modules/EmissionModule.d.ts +48 -0
  258. package/types/particle/modules/ForceOverLifetimeModule.d.ts +51 -0
  259. package/types/particle/modules/MainModule.d.ts +104 -0
  260. package/types/particle/modules/ParticleCompositeCurve.d.ts +81 -0
  261. package/types/particle/modules/ParticleCompositeGradient.d.ts +55 -0
  262. package/types/particle/modules/ParticleCurve.d.ts +63 -0
  263. package/types/particle/modules/ParticleGeneratorModule.d.ts +17 -0
  264. package/types/particle/modules/ParticleGradient.d.ts +114 -0
  265. package/types/particle/modules/RotationOverLifetimeModule.d.ts +34 -0
  266. package/types/particle/modules/SizeOverLifetimeModule.d.ts +52 -0
  267. package/types/particle/modules/TextureSheetAnimationModule.d.ts +39 -0
  268. package/types/particle/modules/VelocityOverLifetimeModule.d.ts +54 -0
  269. package/types/particle/modules/shape/BaseShape.d.ts +22 -0
  270. package/types/particle/modules/shape/BoxShape.d.ts +17 -0
  271. package/types/particle/modules/shape/CircleShape.d.ts +35 -0
  272. package/types/particle/modules/shape/ConeShape.d.ts +45 -0
  273. package/types/particle/modules/shape/HemisphereShape.d.ts +14 -0
  274. package/types/particle/modules/shape/MeshShape.d.ts +21 -0
  275. package/types/particle/modules/shape/ShapeUtils.d.ts +1 -0
  276. package/types/particle/modules/shape/SphereShape.d.ts +14 -0
  277. package/types/particle/modules/shape/enums/ParticleShapeArcMode.d.ts +9 -0
  278. package/types/particle/modules/shape/enums/ParticleShapeType.d.ts +17 -0
  279. package/types/particle/modules/shape/index.d.ts +8 -0
  280. package/types/physics/CharacterController.d.ts +51 -0
  281. package/types/physics/Collider.d.ts +43 -0
  282. package/types/physics/Collision.d.ts +22 -0
  283. package/types/physics/ContactPoint.d.ts +14 -0
  284. package/types/physics/DynamicCollider.d.ts +192 -0
  285. package/types/physics/HitResult.d.ts +18 -0
  286. package/types/physics/PhysicsMaterial.d.ts +42 -0
  287. package/types/physics/PhysicsScene.d.ts +276 -0
  288. package/types/physics/StaticCollider.d.ts +7 -0
  289. package/types/physics/enums/ColliderShapeChangeFlag.d.ts +1 -0
  290. package/types/physics/enums/ColliderShapeUpAxis.d.ts +11 -0
  291. package/types/physics/enums/ControllerCollisionFlag.d.ts +11 -0
  292. package/types/physics/enums/ControllerNonWalkableMode.d.ts +9 -0
  293. package/types/physics/enums/HingeJointFlag.d.ts +1 -0
  294. package/types/physics/enums/PhysicsMaterialCombineMode.d.ts +13 -0
  295. package/types/physics/enums/index.d.ts +4 -0
  296. package/types/physics/index.d.ts +12 -0
  297. package/types/physics/joint/FixedJoint.d.ts +4 -0
  298. package/types/physics/joint/HingeJoint.d.ts +61 -0
  299. package/types/physics/joint/Joint.d.ts +81 -0
  300. package/types/physics/joint/JointLimits.d.ts +39 -0
  301. package/types/physics/joint/JointMotor.d.ts +32 -0
  302. package/types/physics/joint/SpringJoint.d.ts +38 -0
  303. package/types/physics/joint/index.d.ts +6 -0
  304. package/types/physics/shape/BoxColliderShape.d.ts +16 -0
  305. package/types/physics/shape/CapsuleColliderShape.d.ts +27 -0
  306. package/types/physics/shape/ColliderShape.d.ts +61 -0
  307. package/types/physics/shape/PlaneColliderShape.d.ts +9 -0
  308. package/types/physics/shape/SphereColliderShape.d.ts +14 -0
  309. package/types/physics/shape/index.d.ts +5 -0
  310. package/types/postProcess/FinalPass.d.ts +1 -0
  311. package/types/postProcess/PostProcess.d.ts +64 -0
  312. package/types/postProcess/PostProcessEffect.d.ts +26 -0
  313. package/types/postProcess/PostProcessEffectParameter.d.ts +119 -0
  314. package/types/postProcess/PostProcessManager.d.ts +38 -0
  315. package/types/postProcess/PostProcessPass.d.ts +50 -0
  316. package/types/postProcess/PostProcessUberPass.d.ts +25 -0
  317. package/types/postProcess/effects/BloomEffect.d.ts +50 -0
  318. package/types/postProcess/effects/TonemappingEffect.d.ts +25 -0
  319. package/types/postProcess/effects/index.d.ts +2 -0
  320. package/types/postProcess/index.d.ts +8 -0
  321. package/types/renderingHardwareInterface/IPlatformBuffer.d.ts +7 -0
  322. package/types/renderingHardwareInterface/IPlatformRenderTarget.d.ts +20 -0
  323. package/types/renderingHardwareInterface/IPlatformTexture.d.ts +36 -0
  324. package/types/renderingHardwareInterface/IPlatformTexture2D.d.ts +37 -0
  325. package/types/renderingHardwareInterface/IPlatformTexture2DArray.d.ts +40 -0
  326. package/types/renderingHardwareInterface/IPlatformTextureCube.d.ts +41 -0
  327. package/types/renderingHardwareInterface/index.d.ts +6 -0
  328. package/types/shader/Shader.d.ts +119 -0
  329. package/types/shader/ShaderData.d.ts +350 -0
  330. package/types/shader/ShaderMacro.d.ts +26 -0
  331. package/types/shader/ShaderMacroCollection.d.ts +1 -0
  332. package/types/shader/ShaderPart.d.ts +46 -0
  333. package/types/shader/ShaderPass.d.ts +25 -0
  334. package/types/shader/ShaderPool.d.ts +1 -0
  335. package/types/shader/ShaderProgram.d.ts +1 -0
  336. package/types/shader/ShaderProgramPool.d.ts +1 -0
  337. package/types/shader/ShaderProperty.d.ts +20 -0
  338. package/types/shader/ShaderTagKey.d.ts +16 -0
  339. package/types/shader/ShaderUniform.d.ts +1 -0
  340. package/types/shader/ShaderUniformBlock.d.ts +1 -0
  341. package/types/shader/SubShader.d.ts +18 -0
  342. package/types/shader/enums/BlendFactor.d.ts +32 -0
  343. package/types/shader/enums/BlendOperation.d.ts +16 -0
  344. package/types/shader/enums/ColorWriteMask.d.ts +18 -0
  345. package/types/shader/enums/CompareFunction.d.ts +22 -0
  346. package/types/shader/enums/CullMode.d.ts +12 -0
  347. package/types/shader/enums/RenderQueueType.d.ts +11 -0
  348. package/types/shader/enums/RenderStateElementKey.d.ts +60 -0
  349. package/types/shader/enums/ShaderDataGroup.d.ts +15 -0
  350. package/types/shader/enums/ShaderLanguage.d.ts +9 -0
  351. package/types/shader/enums/ShaderPropertyType.d.ts +27 -0
  352. package/types/shader/enums/StencilOperation.d.ts +22 -0
  353. package/types/shader/index.d.ts +19 -0
  354. package/types/shader/state/BlendState.d.ts +16 -0
  355. package/types/shader/state/DepthState.d.ts +14 -0
  356. package/types/shader/state/RasterState.d.ts +13 -0
  357. package/types/shader/state/RenderState.d.ts +21 -0
  358. package/types/shader/state/RenderTargetBlendState.d.ts +24 -0
  359. package/types/shader/state/StencilState.d.ts +34 -0
  360. package/types/shader/state/index.d.ts +6 -0
  361. package/types/shaderlib/ShaderFactory.d.ts +20 -0
  362. package/types/shaderlib/ShaderLib.d.ts +73 -0
  363. package/types/shaderlib/index.d.ts +1 -0
  364. package/types/shaderlib/particle/index.d.ts +15 -0
  365. package/types/shaderlib/pbr/index.d.ts +11 -0
  366. package/types/shaderlib/shadow/index.d.ts +8 -0
  367. package/types/shadow/CascadedShadowCasterPass.d.ts +45 -0
  368. package/types/shadow/ShadowSliceData.d.ts +1 -0
  369. package/types/shadow/ShadowUtils.d.ts +1 -0
  370. package/types/shadow/enum/ShadowCascadesMode.d.ts +11 -0
  371. package/types/shadow/enum/ShadowResolution.d.ts +13 -0
  372. package/types/shadow/enum/ShadowType.d.ts +13 -0
  373. package/types/shadow/index.d.ts +3 -0
  374. package/types/sky/Sky.d.ts +22 -0
  375. package/types/sky/SkyBoxMaterial.d.ts +43 -0
  376. package/types/sky/SkyProceduralMaterial.d.ts +72 -0
  377. package/types/sky/index.d.ts +3 -0
  378. package/types/texture/RenderTarget.d.ts +91 -0
  379. package/types/texture/Texture.d.ts +87 -0
  380. package/types/texture/Texture2D.d.ts +71 -0
  381. package/types/texture/Texture2DArray.d.ts +82 -0
  382. package/types/texture/TextureCube.d.ts +71 -0
  383. package/types/texture/TextureUtils.d.ts +1 -0
  384. package/types/texture/enums/RenderBufferDepthFormat.d.ts +23 -0
  385. package/types/texture/enums/TextureCubeFace.d.ts +17 -0
  386. package/types/texture/enums/TextureDepthCompareFunction.d.ts +21 -0
  387. package/types/texture/enums/TextureFilterMode.d.ts +11 -0
  388. package/types/texture/enums/TextureFormat.d.ts +87 -0
  389. package/types/texture/enums/TextureUsage.d.ts +9 -0
  390. package/types/texture/enums/TextureWrapMode.d.ts +11 -0
  391. package/types/texture/index.d.ts +13 -0
  392. package/types/trail/TrailMaterial.d.ts +5 -0
  393. package/types/trail/TrailRenderer.d.ts +35 -0
  394. package/types/trail/index.d.ts +2 -0
  395. package/types/ui/IUICanvas.d.ts +1 -0
  396. package/types/ui/UIUtils.d.ts +12 -0
  397. package/types/utils/ClearableObjectPool.d.ts +16 -0
  398. package/types/utils/DisorderedArray.d.ts +70 -0
  399. package/types/utils/ObjectPool.d.ts +16 -0
  400. package/types/utils/ReturnableObjectPool.d.ts +16 -0
  401. package/types/utils/SafeLoopArray.d.ts +46 -0
  402. package/types/utils/index.d.ts +4 -0
  403. package/types/xr/XRManager.d.ts +5 -0
@@ -0,0 +1,13 @@
1
+ /**
2
+ * Animation interpolation method.
3
+ */
4
+ export declare enum InterpolationType {
5
+ /** Linear interpolation */
6
+ Linear = 0,
7
+ /** Cubic spline interpolation */
8
+ CubicSpine = 1,
9
+ /** Stepped interpolation */
10
+ Step = 2,
11
+ /** Hermite interpolation */
12
+ Hermite = 3
13
+ }
@@ -0,0 +1,15 @@
1
+ /**
2
+ * Layer state.
3
+ */
4
+ export declare enum LayerState {
5
+ /** Standby state. */
6
+ Standby = 0,
7
+ /** Playing state. */
8
+ Playing = 1,
9
+ /** CrossFading state. */
10
+ CrossFading = 2,
11
+ /** FixedCrossFading state. */
12
+ FixedCrossFading = 3,
13
+ /** Finished state. */
14
+ Finished = 4
15
+ }
@@ -0,0 +1,13 @@
1
+ /**
2
+ * State play state.
3
+ */
4
+ export declare enum PlayState {
5
+ /** Playing state. */
6
+ Playing = 0,
7
+ /** Crossing state. */
8
+ Crossing = 1,
9
+ /** Fading state. */
10
+ Fading = 2,
11
+ /** Finished state. */
12
+ Finished = 3
13
+ }
@@ -0,0 +1,9 @@
1
+ /**
2
+ * Animation wrap mode.
3
+ */
4
+ export declare enum WrapMode {
5
+ /** Play once */
6
+ Once = 0,
7
+ /** Loop play */
8
+ Loop = 1
9
+ }
@@ -0,0 +1,25 @@
1
+ import "./internal/animationCurveOwner/assembler/PositionAnimationCurveOwnerAssembler";
2
+ import "./internal/animationCurveOwner/assembler/RotationAnimationCurveOwnerAssembler";
3
+ import "./internal/animationCurveOwner/assembler/ScaleAnimationCurveOwnerAssembler";
4
+ import "./internal/animationCurveOwner/assembler/BlendShapeWeightsAnimationCurveOwnerAssembler";
5
+ export { AnimationClip } from "./AnimationClip";
6
+ export { AnimationClipCurveBinding } from "./AnimationClipCurveBinding";
7
+ export * from "./animationCurve";
8
+ export { AnimationEvent } from "./AnimationEvent";
9
+ export { Animator } from "./Animator";
10
+ export { AnimatorController } from "./AnimatorController";
11
+ export { AnimatorControllerLayer } from "./AnimatorControllerLayer";
12
+ export { AnimatorState } from "./AnimatorState";
13
+ export { AnimatorStateMachine } from "./AnimatorStateMachine";
14
+ export { AnimatorStateTransition } from "./AnimatorStateTransition";
15
+ export { AnimatorConditionMode } from "./enums/AnimatorConditionMode";
16
+ export { AnimatorLayerBlendingMode } from "./enums/AnimatorLayerBlendingMode";
17
+ export { AnimatorCullingMode } from "./enums/AnimatorCullingMode";
18
+ export { InterpolationType } from "./enums/InterpolationType";
19
+ export { WrapMode } from "./enums/WrapMode";
20
+ export * from "./Keyframe";
21
+ export * from "./AnimatorLayerMask";
22
+ export { StateMachineScript } from "./StateMachineScript";
23
+ export { AnimatorCondition } from "./AnimatorCondition";
24
+ export * from "./AnimatorControllerParameter";
25
+ export { LayerPathMask } from "./LayerPathMask";
@@ -0,0 +1 @@
1
+ export {};
@@ -0,0 +1 @@
1
+ export {};
@@ -0,0 +1 @@
1
+ export {};
@@ -0,0 +1,5 @@
1
+ import { KeyframeValueType } from "../../Keyframe";
2
+ export interface IEvaluateData<V extends KeyframeValueType> {
3
+ curKeyframeIndex: number;
4
+ value: V;
5
+ }
@@ -0,0 +1,88 @@
1
+ /**
2
+ * Asset Loading Promise.
3
+ */
4
+ export declare class AssetPromise<T> implements PromiseLike<T> {
5
+ /**
6
+ * Creates a new resolved AssetPromise.
7
+ * @returns A resolved AssetPromise.
8
+ */
9
+ static resolve(): AssetPromise<void>;
10
+ /**
11
+ * Creates a new resolved AssetPromise fork the provided value.
12
+ * @param value - A value
13
+ * @returns A AssetPromise whose internal state matches the provided promise.
14
+ */
15
+ static resolve<T>(value: T): AssetPromise<Awaited<T>>;
16
+ /**
17
+ * Creates a new resolved AssetPromise for the provided value.
18
+ * @param value - A PromiseLike
19
+ * @returns A AssetPromise whose internal state matches the provided promise.
20
+ */
21
+ static resolve<T>(value: PromiseLike<T>): AssetPromise<Awaited<T>>;
22
+ /**
23
+ * Creates a AssetPromise that is resolved with an array of results when all of the provided PromiseLike resolve, or rejected when any PromiseLike is rejected.
24
+ * @param values An array of PromiseLikes
25
+ * @returns A new AssetPromise.
26
+ */
27
+ static all<T extends [] | unknown[]>(values: T extends [] ? [...T] : readonly [...T]): AssetPromise<{
28
+ [K in keyof T]: UnwrapPromise<T[K]>;
29
+ }>;
30
+ /**
31
+ * Creates a AssetPromise that is resolved with an array of results when all of the provided PromiseLikes resolve, or rejected when any PromiseLikes is rejected.
32
+ * @param values An iterable of PromiseLikes
33
+ * @returns A new AssetPromise.
34
+ */
35
+ static all<T>(values: Iterable<T | PromiseLike<T>>): AssetPromise<Awaited<T>[]>;
36
+ /** compatible with Promise */
37
+ get [Symbol.toStringTag](): string;
38
+ private _promise;
39
+ private _state;
40
+ private _taskCompleteProgress;
41
+ private _taskDetailProgress;
42
+ private _onTaskCompleteCallbacks;
43
+ private _onTaskDetailCallbacks;
44
+ private _onCancelHandler;
45
+ private _reject;
46
+ /**
47
+ * Create an asset loading Promise.
48
+ * @param executor - A callback used to initialize the promise. This callback is passed two arguments:
49
+ * a resolve callback used to resolve the promise with a value or the result of another promise,
50
+ * and a reject callback used to reject the promise with a provided reason or error.
51
+ * and a setProgress callback used to set promise progress with a percent.
52
+ */
53
+ constructor(executor: AssetPromiseExecutor<T>);
54
+ /**
55
+ * Progress callback.
56
+ * @param onTaskComplete - This callback function provides information about the overall progress of the task. For example, in batch processing tasks, you can use the loaded and total parameters to calculate the percentage of task completion or display a progress bar
57
+ * @param onTaskDetail - This callback function provides detailed progress information about the task. For instance, in file downloading scenarios, you can use the loaded and total parameters to calculate the download progress percentage and utilize the url parameter to provide additional details such as download speed and estimated remaining time
58
+ * @returns AssetPromise
59
+ */
60
+ onProgress(onTaskComplete: (loaded: number, total: number) => void, onTaskDetail?: (identifier: string, loaded: number, total: number) => void): AssetPromise<T>;
61
+ then<TResult1 = T, TResult2 = never>(onfulfilled?: (value: T) => TResult1 | PromiseLike<TResult1>, onrejected?: (reason: any) => TResult2 | PromiseLike<TResult2>): AssetPromise<TResult1 | TResult2>;
62
+ /**
63
+ * Attaches a callback for only the rejection of the Promise.
64
+ * @param onRejected - The callback to execute when the Promise is rejected.
65
+ * @returns A Promise for the completion of the callback.
66
+ */
67
+ catch(onRejected: (reason: any) => any): AssetPromise<T>;
68
+ /**
69
+ * Attaches a callback that is invoked when the Promise is settled (fulfilled or rejected).
70
+ * The callback result is ignored and the original value/reason is preserved per Promise spec.
71
+ * Returns an AssetPromise to keep chainability with AssetPromise methods.
72
+ * @param onFinally - The callback to execute when the Promise is settled.
73
+ * @returns An AssetPromise for the completion of the callback.
74
+ */
75
+ finally(onFinally?: () => void): AssetPromise<T>;
76
+ /**
77
+ * Cancel promise request.
78
+ * @returns Asset promise
79
+ */
80
+ cancel(): AssetPromise<T>;
81
+ }
82
+ interface AssetPromiseExecutor<T> {
83
+ (resolve: (value?: T | PromiseLike<T>) => void, reject?: (reason?: any) => void, setTaskCompleteProgress?: TaskCompleteCallback, setTaskDetailProgress?: TaskDetailCallback, onCancel?: (callback: () => void) => void): void;
84
+ }
85
+ type TaskCompleteCallback = (loaded: number, total: number) => void;
86
+ type TaskDetailCallback = (url: string, loaded: number, total: number) => void;
87
+ type UnwrapPromise<T> = T extends PromiseLike<infer U> ? U : T;
88
+ export {};
@@ -0,0 +1,66 @@
1
+ /**
2
+ * Asset Type.
3
+ */
4
+ export declare enum AssetType {
5
+ /**
6
+ * Plain text.
7
+ * @remarks Will not be cached based on url in ResourceManager.
8
+ */
9
+ Text = "Text",
10
+ /**
11
+ * JSON.
12
+ * @remarks Will not be cached based on url in ResourceManager.
13
+ */
14
+ JSON = "JSON",
15
+ /**
16
+ * ArrayBuffer.
17
+ * @remarks Will not be cached based on url in ResourceManager.
18
+ */
19
+ Buffer = "Buffer",
20
+ /** 2D Texture. */
21
+ Texture2D = "Texture2D",
22
+ /** Cube Texture. */
23
+ TextureCube = "TextureCube",
24
+ /** Material. */
25
+ Material = "Material",
26
+ /** Shader. */
27
+ Shader = "Shader",
28
+ /** Mesh. */
29
+ Mesh = "Mesh",
30
+ /** AnimationClip. */
31
+ AnimationClip = "AnimationClip",
32
+ /** AnimatorController. */
33
+ AnimatorController = "AnimatorController",
34
+ /** Prefab.*/
35
+ Prefab = "Prefab",
36
+ /** GLTF.*/
37
+ GLTF = "GLTF",
38
+ /** Compress Texture. */
39
+ KTX = "KTX",
40
+ /** Cube Compress Texture. */
41
+ KTXCube = "KTXCube",
42
+ /** KTX2 Compress Texture */
43
+ KTX2 = "KTX2",
44
+ /** Sprite. */
45
+ Sprite = "Sprite",
46
+ /** PrimitiveMesh. */
47
+ PrimitiveMesh = "PrimitiveMesh",
48
+ /** Sprite Atlas. */
49
+ SpriteAtlas = "SpriteAtlas",
50
+ /** Ambient light. */
51
+ Env = "Environment",
52
+ /** Scene. */
53
+ Scene = "Scene",
54
+ /** HDR to cube. */
55
+ HDR = "HDR",
56
+ /** Font. */
57
+ Font = "Font",
58
+ /** Source Font, include ttf, otf and woff. */
59
+ SourceFont = "SourceFont",
60
+ /** AudioClip, include ogg, wav and mp3. */
61
+ Audio = "Audio",
62
+ /** Project asset. */
63
+ Project = "project",
64
+ /** PhysicsMaterial. */
65
+ PhysicsMaterial = "PhysicsMaterial"
66
+ }
@@ -0,0 +1,17 @@
1
+ import { EngineObject } from "../base";
2
+ import { AssetPromise } from "./AssetPromise";
3
+ /**
4
+ * ContentRestorer is a base class for all content restore info classes.
5
+ */
6
+ export declare abstract class ContentRestorer<T extends EngineObject> {
7
+ resource: T;
8
+ /**
9
+ * @param resource - The resource object of the content restorer
10
+ */
11
+ constructor(resource: T);
12
+ /**
13
+ * Restore the content of the resource.
14
+ * @returns The promise of the restored content if the content is restored asynchronously, otherwise returns undefined
15
+ */
16
+ abstract restoreContent(): AssetPromise<T> | void;
17
+ }
@@ -0,0 +1,9 @@
1
+ import { Engine } from "../Engine";
2
+ import { ReferResource } from "./ReferResource";
3
+ export declare abstract class GraphicsResource extends ReferResource {
4
+ /**
5
+ * Whether the content of the resource is lost.
6
+ */
7
+ get isContentLost(): boolean;
8
+ protected constructor(engine: Engine);
9
+ }
@@ -0,0 +1,2 @@
1
+ export interface IReferable {
2
+ }
@@ -0,0 +1,40 @@
1
+ type PickOnlyOne<T extends {}, Keys extends keyof T = keyof T> = Keys extends unknown ? {
2
+ [K in Keys]: T[Keys];
3
+ } & {
4
+ [K in Exclude<keyof T, Keys>]?: never;
5
+ } : never;
6
+ /**
7
+ * Used to describe loading asset.
8
+ */
9
+ export type LoadItem = {
10
+ /**
11
+ * Asset Type.
12
+ */
13
+ type?: string;
14
+ /**
15
+ * Number of retries after failed loading.
16
+ */
17
+ retryCount?: number;
18
+ /**
19
+ * Timeout.
20
+ */
21
+ timeout?: number;
22
+ /**
23
+ * Retry interval time.
24
+ */
25
+ retryInterval?: number;
26
+ /**
27
+ * Additional parameters for specified loader.
28
+ */
29
+ params?: Record<string, any>;
30
+ } & PickOnlyOne<{
31
+ /**
32
+ * Loading url.
33
+ */
34
+ url: string;
35
+ /**
36
+ * Available when AssetType is TextureCube.
37
+ */
38
+ urls: string[];
39
+ }>;
40
+ export {};
@@ -0,0 +1,37 @@
1
+ import { Engine, EngineConfiguration } from "../Engine";
2
+ import { AssetPromise } from "./AssetPromise";
3
+ import { LoadItem } from "./LoadItem";
4
+ import { ResourceManager } from "./ResourceManager";
5
+ /**
6
+ * Loader abstract class.
7
+ */
8
+ export declare abstract class Loader<T> {
9
+ readonly useCache: boolean;
10
+ /**
11
+ * Register a class with a string name for serialization and deserialization.
12
+ * @param key - class name
13
+ * @param obj - class object
14
+ */
15
+ static registerClass(className: string, classDefine: {
16
+ new (...args: any): any;
17
+ }): void;
18
+ /**
19
+ * Get the class object by class name.
20
+ * @param key - class name
21
+ * @returns class object
22
+ */
23
+ static getClass(className: string): {
24
+ new (...args: any): any;
25
+ };
26
+ /**
27
+ * Get the class name by class object.
28
+ * @param obj - class object
29
+ * @returns class name
30
+ */
31
+ static getClassName(obj: Object): string;
32
+ private static _engineObjects;
33
+ private static _classNameMap;
34
+ constructor(useCache: boolean);
35
+ initialize?(engine: Engine, configuration: EngineConfiguration): Promise<void>;
36
+ abstract load(item: LoadItem, resourceManager: ResourceManager): AssetPromise<T>;
37
+ }
@@ -0,0 +1,23 @@
1
+ import { EngineObject } from "../base/EngineObject";
2
+ import { Engine } from "../Engine";
3
+ import { IReferable } from "./IReferable";
4
+ /**
5
+ * The base class of assets, with reference counting capability.
6
+ */
7
+ export declare abstract class ReferResource extends EngineObject implements IReferable {
8
+ /** Whether to ignore the garbage collection check, if it is true, it will not be affected by ResourceManager.gc(). */
9
+ isGCIgnored: boolean;
10
+ private _refCount;
11
+ private _superResources;
12
+ /**
13
+ * Counted by valid references.
14
+ */
15
+ get refCount(): number;
16
+ protected constructor(engine: Engine);
17
+ /**
18
+ * Destroy self.
19
+ * @param force - Whether to force the destruction, if it is false, refCount = 0 can be released successfully
20
+ * @returns Whether the release was successful
21
+ */
22
+ destroy(force?: boolean): boolean;
23
+ }
@@ -0,0 +1,121 @@
1
+ import { ContentRestorer, Engine, EngineObject } from "..";
2
+ import { AssetPromise } from "./AssetPromise";
3
+ import { Loader } from "./Loader";
4
+ import { LoadItem } from "./LoadItem";
5
+ /**
6
+ * ResourceManager
7
+ */
8
+ export declare class ResourceManager {
9
+ readonly engine: Engine;
10
+ private static _extTypeMapping;
11
+ private static _getTypeByUrl;
12
+ /** The number of retries after failing to load assets. */
13
+ retryCount: number;
14
+ /** Retry delay time after failed to load assets, in milliseconds. */
15
+ retryInterval: number;
16
+ /** The default timeout period for loading assets, in milliseconds. */
17
+ timeout: number;
18
+ /** Base url for loading assets. */
19
+ baseUrl: string | null;
20
+ private _loadingPromises;
21
+ /** Asset path pool, key is the `instanceID` of resource, value is asset path. */
22
+ private _assetPool;
23
+ /** Asset url pool, key is the asset path and the value is the asset. */
24
+ private _assetUrlPool;
25
+ /** Referable resource pool, key is the `instanceID` of resource. */
26
+ private _referResourcePool;
27
+ /** Graphic resource pool, key is the `instanceID` of resource. */
28
+ private _graphicResourcePool;
29
+ /** Restorable resource information pool, key is the `instanceID` of resource. */
30
+ private _contentRestorerPool;
31
+ private _subAssetPromiseCallbacks;
32
+ /**
33
+ * Create a ResourceManager.
34
+ * @param engine - Engine to which the current ResourceManager belongs
35
+ */
36
+ constructor(engine: Engine);
37
+ /**
38
+ * Load asset asynchronously through the path.
39
+ * @param path - Path
40
+ * @returns Asset promise
41
+ */
42
+ load<T>(path: string): AssetPromise<T>;
43
+ /**
44
+ * Load asset collection asynchronously through urls.
45
+ * @param paths - Path collections
46
+ * @returns Asset Promise
47
+ */
48
+ load(paths: string[]): AssetPromise<Object[]>;
49
+ /**
50
+ * Load the asset asynchronously by asset item information.
51
+ * @param assetItem - AssetItem
52
+ * @returns AssetPromise
53
+ */
54
+ load<T>(assetItem: LoadItem): AssetPromise<T>;
55
+ /**
56
+ * Load the asset collection asynchronously by loading the information collection.
57
+ * @param assetItems - Asset collection
58
+ * @returns AssetPromise
59
+ */
60
+ load(assetItems: LoadItem[]): AssetPromise<Object[]>;
61
+ /**
62
+ * Get the resource from cache by asset url, return the resource object if it loaded, otherwise return null.
63
+ * @param url - Resource url
64
+ * @returns Resource object
65
+ */
66
+ getFromCache<T>(url: string): T;
67
+ /**
68
+ * Find the resource by type.
69
+ * @param type - Resource type
70
+ * @returns - Resource collection
71
+ */
72
+ findResourcesByType<T extends EngineObject>(type: new (...args: any[]) => T): T[];
73
+ /**
74
+ * Get asset url from instanceId.
75
+ * @param instanceId - Engine instance id
76
+ * @returns Asset url
77
+ */
78
+ getAssetPath(instanceId: number): string;
79
+ /**
80
+ * Cancel all assets that have not finished loading.
81
+ */
82
+ cancelNotLoaded(): void;
83
+ /**
84
+ * Cancel assets whose url has not finished loading.
85
+ * @param url - Resource url
86
+ */
87
+ cancelNotLoaded(url: string): void;
88
+ /**
89
+ * Cancel the incompletely loaded assets in urls.
90
+ * @param urls - Resource urls
91
+ */
92
+ cancelNotLoaded(urls: string[]): void;
93
+ /**
94
+ * Garbage collection will release resource objects managed by reference counting.
95
+ * @remarks The release principle is that it is not referenced by the components, including direct and indirect reference.
96
+ */
97
+ gc(): void;
98
+ /**
99
+ * Add content restorer.
100
+ * @param restorer - The restorer
101
+ */
102
+ addContentRestorer<T extends EngineObject>(restorer: ContentRestorer<T>): void;
103
+ private _assignDefaultOptions;
104
+ private _loadSingleItem;
105
+ private _loadSubpackageAndMainAsset;
106
+ private _loadMainAsset;
107
+ private _createSubAssetPromiseCallback;
108
+ private _gc;
109
+ private _getResolveResource;
110
+ private _parseURL;
111
+ private _parseQueryPath;
112
+ private _releaseSubAssetPromiseCallback;
113
+ }
114
+ /**
115
+ * Declare ResourceLoader's decorator.
116
+ * @param assetType - Type of asset
117
+ * @param extNames - Name of file extension
118
+ */
119
+ export declare function resourceLoader(assetType: string, extNames: string[], useCache?: boolean): <T extends Loader<any>>(Target: {
120
+ new (useCache: boolean): T;
121
+ }) => void;
@@ -0,0 +1,36 @@
1
+ import { AssetPromise } from "./AssetPromise";
2
+ /**
3
+ * Configuration options for `request`.
4
+ * @remarks
5
+ * This type extends the standard `RequestInit` options with additional
6
+ * properties for handling retries, timeouts, and custom response types.
7
+ */
8
+ export type RequestConfig = {
9
+ type?: XMLHttpRequestResponseType | "image";
10
+ retryCount?: number;
11
+ retryInterval?: number;
12
+ timeout?: number;
13
+ } & RequestInit;
14
+ /**
15
+ * Sends a request to the specified URL and returns a promise for the response.
16
+ * @param url - The URL to send the request to
17
+ * @param config - Configuration options for the request
18
+ * @returns A promise that resolves with the response of type `T`
19
+ */
20
+ export declare function request<T>(url: string, config?: RequestConfig): AssetPromise<T>;
21
+ export declare class MultiExecutor {
22
+ private execFunc;
23
+ private totalCount;
24
+ private interval;
25
+ private _timeoutId;
26
+ private _currentCount;
27
+ private _onComplete;
28
+ private _onError;
29
+ private _error;
30
+ constructor(execFunc: (count?: number) => Promise<any>, totalCount: number, interval: number);
31
+ start(): this;
32
+ onComplete(func: Function): this;
33
+ onError(func: Function): this;
34
+ cancel(): void;
35
+ private exec;
36
+ }
@@ -0,0 +1,24 @@
1
+ import { Engine } from "../Engine";
2
+ import { ReferResource } from "../asset/ReferResource";
3
+ /**
4
+ * Audio Clip.
5
+ */
6
+ export declare class AudioClip extends ReferResource {
7
+ private _audioBuffer;
8
+ /** Name of clip. */
9
+ name: string;
10
+ /**
11
+ * Number of discrete audio channels.
12
+ */
13
+ get channels(): number;
14
+ /**
15
+ * Sample rate, in samples per second.
16
+ */
17
+ get sampleRate(): number;
18
+ /**
19
+ * Duration, in seconds.
20
+ */
21
+ get duration(): number;
22
+ constructor(engine: Engine, name?: string);
23
+ protected _onDestroy(): void;
24
+ }
@@ -0,0 +1 @@
1
+ export {};