@galacean/engine-core 2.0.0-alpha.44 → 2.0.0-alpha.45

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 (236) hide show
  1. package/dist/main.js.map +1 -1
  2. package/dist/module.js.map +1 -1
  3. package/package.json +3 -3
  4. package/types/2d/atlas/FontAtlas.d.ts +23 -1
  5. package/types/2d/atlas/SpriteAtlas.d.ts +8 -0
  6. package/types/2d/sprite/Sprite.d.ts +27 -1
  7. package/types/2d/sprite/SpriteMask.d.ts +43 -0
  8. package/types/2d/sprite/SpriteRenderer.d.ts +29 -0
  9. package/types/2d/text/CharInfo.d.ts +20 -1
  10. package/types/2d/text/CharRenderInfo.d.ts +15 -1
  11. package/types/2d/text/Font.d.ts +10 -0
  12. package/types/2d/text/SubFont.d.ts +35 -1
  13. package/types/2d/text/TextRenderer.d.ts +53 -0
  14. package/types/2d/text/TextUtils.d.ts +89 -1
  15. package/types/Background.d.ts +17 -0
  16. package/types/BasicResources.d.ts +52 -0
  17. package/types/Camera.d.ts +71 -1
  18. package/types/Canvas.d.ts +13 -0
  19. package/types/Component.d.ts +33 -0
  20. package/types/ComponentsDependencies.d.ts +34 -1
  21. package/types/ComponentsManager.d.ts +17 -0
  22. package/types/Engine.d.ts +106 -2
  23. package/types/Entity.d.ts +88 -0
  24. package/types/Polyfill.d.ts +12 -1
  25. package/types/RenderPipeline/BasicRenderPipeline.d.ts +3 -0
  26. package/types/RenderPipeline/BatcherManager.d.ts +23 -1
  27. package/types/RenderPipeline/CullingResults.d.ts +17 -1
  28. package/types/RenderPipeline/DepthOnlyPass.d.ts +18 -1
  29. package/types/RenderPipeline/InstanceBuffer.d.ts +28 -1
  30. package/types/RenderPipeline/MaskManager.d.ts +36 -1
  31. package/types/RenderPipeline/OpaqueTexturePass.d.ts +16 -1
  32. package/types/RenderPipeline/PipelineUtils.d.ts +11 -1
  33. package/types/RenderPipeline/PrimitiveChunk.d.ts +27 -1
  34. package/types/RenderPipeline/PrimitiveChunkManager.d.ts +16 -1
  35. package/types/RenderPipeline/RenderContext.d.ts +46 -1
  36. package/types/RenderPipeline/RenderElement.d.ts +9 -0
  37. package/types/RenderPipeline/RenderQueue.d.ts +23 -1
  38. package/types/RenderPipeline/RenderTargetPool.d.ts +17 -1
  39. package/types/RenderPipeline/SubPrimitiveChunk.d.ts +14 -1
  40. package/types/RenderPipeline/VertexArea.d.ts +10 -1
  41. package/types/RenderPipeline/VertexMergeBatcher.d.ts +11 -1
  42. package/types/RenderPipeline/enums/RenderQueueMaskType.d.ts +9 -1
  43. package/types/RenderPipeline/index.d.ts +2 -0
  44. package/types/Renderer.d.ts +58 -0
  45. package/types/Scene.d.ts +28 -0
  46. package/types/SceneManager.d.ts +13 -0
  47. package/types/Script.d.ts +40 -0
  48. package/types/SystemInfo.d.ts +10 -0
  49. package/types/Transform.d.ts +13 -0
  50. package/types/UpdateFlag.d.ts +3 -0
  51. package/types/UpdateFlagManager.d.ts +41 -1
  52. package/types/Utils.d.ts +20 -0
  53. package/types/VirtualCamera.d.ts +16 -1
  54. package/types/animation/AnimationClip.d.ts +5 -0
  55. package/types/animation/AnimationClipCurveBinding.d.ts +16 -1
  56. package/types/animation/Animator.d.ts +25 -0
  57. package/types/animation/AnimatorController.d.ts +17 -0
  58. package/types/animation/AnimatorControllerLayer.d.ts +9 -0
  59. package/types/animation/AnimatorControllerParameter.d.ts +4 -0
  60. package/types/animation/AnimatorState.d.ts +44 -0
  61. package/types/animation/AnimatorStateInstance.d.ts +8 -0
  62. package/types/animation/AnimatorStateMachine.d.ts +14 -0
  63. package/types/animation/AnimatorStateTransition.d.ts +9 -0
  64. package/types/animation/AnimatorStateTransitionCollection.d.ts +23 -1
  65. package/types/animation/StateMachineScript.d.ts +2 -0
  66. package/types/animation/animationCurve/AnimationArrayCurve.d.ts +39 -0
  67. package/types/animation/animationCurve/AnimationBoolCurve.d.ts +39 -0
  68. package/types/animation/animationCurve/AnimationColorCurve.d.ts +39 -0
  69. package/types/animation/animationCurve/AnimationCurve.d.ts +8 -0
  70. package/types/animation/animationCurve/AnimationFloatArrayCurve.d.ts +38 -0
  71. package/types/animation/animationCurve/AnimationFloatCurve.d.ts +39 -0
  72. package/types/animation/animationCurve/AnimationQuaternionCurve.d.ts +41 -0
  73. package/types/animation/animationCurve/AnimationRectCurve.d.ts +18 -0
  74. package/types/animation/animationCurve/AnimationRefCurve.d.ts +18 -0
  75. package/types/animation/animationCurve/AnimationStringCurve.d.ts +39 -0
  76. package/types/animation/animationCurve/AnimationVector2Curve.d.ts +39 -0
  77. package/types/animation/animationCurve/AnimationVector3Curve.d.ts +43 -0
  78. package/types/animation/animationCurve/AnimationVector4Curve.d.ts +39 -0
  79. package/types/animation/animationCurve/interfaces/IAnimationCurveCalculator.d.ts +18 -1
  80. package/types/animation/enums/AnimatorStatePlayState.d.ts +8 -1
  81. package/types/animation/internal/AnimationCurveLayerOwner.d.ts +15 -1
  82. package/types/animation/internal/AnimationEventHandler.d.ts +8 -1
  83. package/types/animation/internal/AnimatorLayerData.d.ts +28 -1
  84. package/types/animation/internal/AnimatorStateData.d.ts +14 -1
  85. package/types/animation/internal/AnimatorStatePlayData.d.ts +27 -1
  86. package/types/animation/internal/AnimatorTempValue.d.ts +12 -1
  87. package/types/animation/internal/animationCurveOwner/AnimationCurveOwner.d.ts +39 -0
  88. package/types/animation/internal/animationCurveOwner/assembler/BlendShapeWeightsAnimationCurveOwnerAssembler.d.ts +12 -1
  89. package/types/animation/internal/animationCurveOwner/assembler/IAnimationCurveOwnerAssembler.d.ts +10 -1
  90. package/types/animation/internal/animationCurveOwner/assembler/PositionAnimationCurveOwnerAssembler.d.ts +13 -1
  91. package/types/animation/internal/animationCurveOwner/assembler/RotationAnimationCurveOwnerAssembler.d.ts +13 -1
  92. package/types/animation/internal/animationCurveOwner/assembler/ScaleAnimationCurveOwnerAssembler.d.ts +13 -1
  93. package/types/animation/internal/animationCurveOwner/assembler/UniversalAnimationCurveOwnerAssembler.d.ts +23 -1
  94. package/types/asset/GraphicsResource.d.ts +10 -0
  95. package/types/asset/IReferable.d.ts +8 -0
  96. package/types/asset/ReferResource.d.ts +28 -0
  97. package/types/asset/RenderingStatistics.d.ts +8 -0
  98. package/types/asset/ResourceManager.d.ts +94 -4
  99. package/types/audio/AudioClip.d.ts +8 -0
  100. package/types/audio/AudioManager.d.ts +14 -0
  101. package/types/audio/AudioSource.d.ts +17 -0
  102. package/types/base/EngineObject.d.ts +4 -0
  103. package/types/base/Time.d.ts +13 -0
  104. package/types/clone/CloneDecorators.d.ts +20 -0
  105. package/types/clone/CloneUtil.d.ts +30 -1
  106. package/types/clone/ComponentCloner.d.ts +11 -1
  107. package/types/enums/CameraType.d.ts +9 -1
  108. package/types/env-probe/CubeProbe.d.ts +2 -0
  109. package/types/graphic/Buffer.d.ts +10 -0
  110. package/types/graphic/BufferUtil.d.ts +5 -0
  111. package/types/graphic/IndexBufferBinding.d.ts +4 -0
  112. package/types/graphic/Mesh.d.ts +54 -0
  113. package/types/graphic/Primitive.d.ts +50 -1
  114. package/types/graphic/TransformFeedback.d.ts +46 -1
  115. package/types/graphic/TransformFeedbackPrimitive.d.ts +67 -1
  116. package/types/graphic/TransformFeedbackSimulator.d.ts +55 -1
  117. package/types/graphic/VertexBufferBinding.d.ts +4 -0
  118. package/types/input/InputManager.d.ts +19 -0
  119. package/types/input/enums/PointerButton.d.ts +8 -0
  120. package/types/input/keyboard/KeyboardManager.d.ts +41 -1
  121. package/types/input/pointer/Pointer.d.ts +36 -0
  122. package/types/input/pointer/PointerEventData.d.ts +4 -0
  123. package/types/input/pointer/PointerManager.d.ts +58 -0
  124. package/types/input/pointer/emitter/IHitResult.d.ts +11 -1
  125. package/types/input/pointer/emitter/PhysicsPointerEventEmitter.d.ts +20 -1
  126. package/types/input/wheel/WheelManager.d.ts +34 -1
  127. package/types/lighting/AmbientLight.d.ts +9 -0
  128. package/types/lighting/DirectLight.d.ts +17 -0
  129. package/types/lighting/Light.d.ts +2 -0
  130. package/types/lighting/LightManager.d.ts +57 -0
  131. package/types/lighting/PointLight.d.ts +17 -0
  132. package/types/lighting/SpotLight.d.ts +17 -0
  133. package/types/lighting/ambientOcclusion/AmbientOcclusion.d.ts +4 -0
  134. package/types/lighting/ambientOcclusion/ScalableAmbientObscurancePass.d.ts +38 -1
  135. package/types/material/BaseMaterial.d.ts +4 -0
  136. package/types/material/Material.d.ts +2 -0
  137. package/types/mesh/BlendShape.d.ts +13 -0
  138. package/types/mesh/BlendShapeFrame.d.ts +7 -0
  139. package/types/mesh/BlendShapeManager.d.ts +101 -1
  140. package/types/mesh/MeshRenderer.d.ts +37 -0
  141. package/types/mesh/ModelMesh.d.ts +18 -0
  142. package/types/mesh/PrimitiveMesh.d.ts +28 -0
  143. package/types/mesh/PrimitiveMeshRestorer.d.ts +107 -0
  144. package/types/mesh/Skin.d.ts +10 -0
  145. package/types/mesh/SkinnedMeshRenderer.d.ts +21 -0
  146. package/types/particle/ParticleBufferUtils.d.ts +26 -1
  147. package/types/particle/ParticleGenerator.d.ts +102 -0
  148. package/types/particle/ParticleRenderer.d.ts +55 -0
  149. package/types/particle/ParticleTransformFeedbackSimulator.d.ts +52 -1
  150. package/types/particle/enums/ParticleRandomSubSeeds.d.ts +25 -1
  151. package/types/particle/enums/attributes/BillboardParticleVertexAttribute.d.ts +6 -1
  152. package/types/particle/enums/attributes/ParticleFeedbackVertexAttribute.d.ts +8 -1
  153. package/types/particle/enums/attributes/ParticleInstanceVertexAttribute.d.ts +17 -1
  154. package/types/particle/modules/ColorOverLifetimeModule.d.ts +12 -0
  155. package/types/particle/modules/CustomDataModule.d.ts +5 -0
  156. package/types/particle/modules/EmissionModule.d.ts +28 -0
  157. package/types/particle/modules/ForceOverLifetimeModule.d.ts +16 -1
  158. package/types/particle/modules/LimitVelocityOverLifetimeModule.d.ts +20 -1
  159. package/types/particle/modules/MainModule.d.ts +33 -1
  160. package/types/particle/modules/NoiseModule.d.ts +12 -1
  161. package/types/particle/modules/ParticleCompositeCurve.d.ts +37 -0
  162. package/types/particle/modules/ParticleCurve.d.ts +28 -0
  163. package/types/particle/modules/ParticleGeneratorModule.d.ts +7 -0
  164. package/types/particle/modules/ParticleGradient.d.ts +16 -0
  165. package/types/particle/modules/RotationOverLifetimeModule.d.ts +12 -0
  166. package/types/particle/modules/SizeOverLifetimeModule.d.ts +16 -0
  167. package/types/particle/modules/SubEmitter.d.ts +3 -0
  168. package/types/particle/modules/SubEmittersModule.d.ts +17 -0
  169. package/types/particle/modules/TextureSheetAnimationModule.d.ts +14 -1
  170. package/types/particle/modules/VelocityOverLifetimeModule.d.ts +28 -1
  171. package/types/particle/modules/shape/BaseShape.d.ts +33 -1
  172. package/types/particle/modules/shape/BoxShape.d.ts +13 -1
  173. package/types/particle/modules/shape/CircleShape.d.ts +13 -0
  174. package/types/particle/modules/shape/ConeShape.d.ts +13 -0
  175. package/types/particle/modules/shape/HemisphereShape.d.ts +13 -0
  176. package/types/particle/modules/shape/MeshShape.d.ts +17 -0
  177. package/types/particle/modules/shape/ShapeUtils.d.ts +13 -1
  178. package/types/particle/modules/shape/SphereShape.d.ts +13 -0
  179. package/types/physics/CharacterController.d.ts +21 -0
  180. package/types/physics/Collider.d.ts +39 -0
  181. package/types/physics/Collision.d.ts +3 -0
  182. package/types/physics/DynamicCollider.d.ts +14 -0
  183. package/types/physics/PhysicsMaterial.d.ts +3 -0
  184. package/types/physics/PhysicsScene.d.ts +51 -0
  185. package/types/physics/StaticCollider.d.ts +5 -0
  186. package/types/physics/enums/ColliderShapeChangeFlag.d.ts +8 -1
  187. package/types/physics/enums/HingeJointFlag.d.ts +14 -1
  188. package/types/physics/joint/HingeJoint.d.ts +4 -0
  189. package/types/physics/joint/Joint.d.ts +20 -0
  190. package/types/physics/joint/JointLimits.d.ts +3 -0
  191. package/types/physics/joint/JointMotor.d.ts +3 -0
  192. package/types/physics/shape/ColliderShape.d.ts +17 -0
  193. package/types/physics/shape/MeshColliderShape.d.ts +4 -0
  194. package/types/postProcess/FinalPass.d.ts +19 -1
  195. package/types/postProcess/PostProcess.d.ts +2 -0
  196. package/types/postProcess/PostProcessEffect.d.ts +4 -0
  197. package/types/postProcess/PostProcessEffectParameter.d.ts +4 -0
  198. package/types/postProcess/PostProcessManager.d.ts +43 -0
  199. package/types/postProcess/effects/BloomEffect.d.ts +25 -0
  200. package/types/postProcess/effects/TonemappingEffect.d.ts +3 -0
  201. package/types/renderingHardwareInterface/IPlatformTransformFeedback.d.ts +36 -1
  202. package/types/renderingHardwareInterface/IPlatformTransformFeedbackPrimitive.d.ts +40 -1
  203. package/types/shader/Shader.d.ts +22 -0
  204. package/types/shader/ShaderBlockProperty.d.ts +19 -1
  205. package/types/shader/ShaderData.d.ts +29 -0
  206. package/types/shader/ShaderFactory.d.ts +23 -0
  207. package/types/shader/ShaderMacro.d.ts +15 -0
  208. package/types/shader/ShaderMacroCollection.d.ts +57 -1
  209. package/types/shader/ShaderMacroProcessor.d.ts +72 -1
  210. package/types/shader/ShaderPass.d.ts +38 -0
  211. package/types/shader/ShaderProgram.d.ts +91 -1
  212. package/types/shader/ShaderProgramMap.d.ts +20 -1
  213. package/types/shader/ShaderProperty.d.ts +17 -0
  214. package/types/shader/ShaderTagKey.d.ts +2 -0
  215. package/types/shader/ShaderUniform.d.ts +49 -1
  216. package/types/shader/ShaderUniformBlock.d.ts +9 -1
  217. package/types/shader/enums/ConstantBufferBindingPoint.d.ts +7 -1
  218. package/types/shader/state/BlendState.d.ts +14 -0
  219. package/types/shader/state/DepthState.d.ts +14 -0
  220. package/types/shader/state/RasterState.d.ts +17 -0
  221. package/types/shader/state/RenderState.d.ts +11 -0
  222. package/types/shader/state/StencilState.d.ts +13 -0
  223. package/types/shadow/CascadedShadowCasterPass.d.ts +5 -0
  224. package/types/shadow/ShadowSliceData.d.ts +13 -1
  225. package/types/shadow/ShadowUtils.d.ts +43 -1
  226. package/types/sky/Sky.d.ts +9 -0
  227. package/types/texture/RenderTarget.d.ts +21 -0
  228. package/types/texture/Texture.d.ts +21 -0
  229. package/types/texture/Texture2D.d.ts +4 -0
  230. package/types/texture/Texture2DArray.d.ts +4 -0
  231. package/types/texture/TextureCube.d.ts +4 -0
  232. package/types/texture/TextureUtils.d.ts +16 -1
  233. package/types/trail/TrailRenderer.d.ts +5 -0
  234. package/types/ui/IUICanvas.d.ts +16 -1
  235. package/types/utils/DisorderedArray.d.ts +2 -0
  236. package/types/xr/XRManager.d.ts +28 -0
@@ -1 +1,67 @@
1
- export {};
1
+ import { Engine } from "../Engine";
2
+ import { GraphicsResource } from "../asset/GraphicsResource";
3
+ import { IPlatformTransformFeedbackPrimitive } from "../renderingHardwareInterface";
4
+ import { ShaderProgram } from "../shader/ShaderProgram";
5
+ import { MeshTopology } from "./enums/MeshTopology";
6
+ import { VertexBufferBinding } from "./VertexBufferBinding";
7
+ import { VertexElement } from "./VertexElement";
8
+ /**
9
+ * @internal
10
+ * Primitive for Transform Feedback simulation with read/write buffer swapping.
11
+ */
12
+ export declare class TransformFeedbackPrimitive extends GraphicsResource {
13
+ /** @internal */
14
+ _platformPrimitive: IPlatformTransformFeedbackPrimitive;
15
+ private _transformFeedback;
16
+ private _bindingA;
17
+ private _bindingB;
18
+ private _byteStride;
19
+ private _readIsA;
20
+ /**
21
+ * The current read buffer binding.
22
+ */
23
+ get readBinding(): VertexBufferBinding;
24
+ /**
25
+ * The current write buffer binding.
26
+ */
27
+ get writeBinding(): VertexBufferBinding;
28
+ /**
29
+ * @param engine - Engine instance
30
+ * @param byteStride - Bytes per vertex
31
+ */
32
+ constructor(engine: Engine, byteStride: number);
33
+ /**
34
+ * Resize read and write buffers.
35
+ * @param vertexCount - Number of vertices to allocate
36
+ */
37
+ resize(vertexCount: number): void;
38
+ /**
39
+ * Update vertex layout, only rebuilds when program changes.
40
+ * @param program - Shader program for attribute locations
41
+ * @param feedbackElements - Vertex elements describing the read/write buffer
42
+ * @param inputBinding - Additional input buffer binding
43
+ * @param inputElements - Vertex elements describing the input buffer
44
+ */
45
+ updateVertexLayout(program: ShaderProgram, feedbackElements: VertexElement[], inputBinding: VertexBufferBinding, inputElements: VertexElement[]): void;
46
+ /**
47
+ * Bind state before issuing draw calls.
48
+ */
49
+ beginDraw(): void;
50
+ /**
51
+ * Issue a draw call for a vertex range, capturing output to the write buffer.
52
+ * @param mode - Primitive topology
53
+ * @param first - First vertex index
54
+ * @param count - Number of vertices
55
+ */
56
+ draw(mode: MeshTopology, first: number, count: number): void;
57
+ /**
58
+ * Unbind state after draw calls.
59
+ */
60
+ endDraw(): void;
61
+ /**
62
+ * Swap read and write buffers.
63
+ */
64
+ swap(): void;
65
+ _rebuild(): void;
66
+ protected _onDestroy(): void;
67
+ }
@@ -1 +1,55 @@
1
- export {};
1
+ import { Engine } from "../Engine";
2
+ import { MeshTopology } from "./enums/MeshTopology";
3
+ import { VertexBufferBinding } from "./VertexBufferBinding";
4
+ import { VertexElement } from "./VertexElement";
5
+ import { ShaderData } from "../shader/ShaderData";
6
+ import { ShaderPass } from "../shader/ShaderPass";
7
+ /**
8
+ * @internal
9
+ * General-purpose Transform Feedback simulator.
10
+ * Manages per-frame simulation with shared shader program caching.
11
+ */
12
+ export declare class TransformFeedbackSimulator {
13
+ private _engine;
14
+ private _primitive;
15
+ private _shaderPass;
16
+ /**
17
+ * The current read buffer binding.
18
+ */
19
+ get readBinding(): VertexBufferBinding;
20
+ /**
21
+ * The current write buffer binding.
22
+ */
23
+ get writeBinding(): VertexBufferBinding;
24
+ /**
25
+ * @param engine - Engine instance
26
+ * @param byteStride - Bytes per vertex in the feedback buffer
27
+ * @param shaderPass - ShaderPass with feedbackVaryings configured
28
+ */
29
+ constructor(engine: Engine, byteStride: number, shaderPass: ShaderPass);
30
+ /**
31
+ * Resize feedback buffers.
32
+ * @param vertexCount - Number of vertices to allocate
33
+ */
34
+ resize(vertexCount: number): void;
35
+ /**
36
+ * Begin a simulation step: get/compile program, bind, upload uniforms, update layout.
37
+ * @param shaderData - Shader data with current macros and uniforms
38
+ * @param feedbackElements - Vertex elements for the feedback buffer
39
+ * @param inputBinding - Input buffer binding
40
+ * @param inputElements - Vertex elements for the input buffer
41
+ */
42
+ beginUpdate(shaderData: ShaderData, feedbackElements: VertexElement[], inputBinding: VertexBufferBinding, inputElements: VertexElement[]): boolean;
43
+ /**
44
+ * Issue a draw call for a vertex range.
45
+ * @param mode - Primitive topology
46
+ * @param first - First vertex index
47
+ * @param count - Number of vertices
48
+ */
49
+ draw(mode: MeshTopology, first: number, count: number): void;
50
+ /**
51
+ * End the simulation step: unbind state and swap buffers.
52
+ */
53
+ endUpdate(): void;
54
+ destroy(): void;
55
+ }
@@ -3,6 +3,10 @@ import { Buffer } from "./Buffer";
3
3
  * Vertex buffer binding.
4
4
  */
5
5
  export declare class VertexBufferBinding {
6
+ /** @internal */
7
+ _buffer: Buffer;
8
+ /** @internal */
9
+ _stride: number;
6
10
  /**
7
11
  * Vertex buffer.
8
12
  */
@@ -1,4 +1,7 @@
1
+ import { IInputOptions } from "@galacean/engine-design";
1
2
  import { Vector3 } from "@galacean/engine-math";
3
+ import { Engine } from "../Engine";
4
+ import { Scene } from "../Scene";
2
5
  import { Keys } from "./enums/Keys";
3
6
  import { PointerButton } from "./enums/PointerButton";
4
7
  import { Pointer } from "./pointer/Pointer";
@@ -62,4 +65,20 @@ export declare class InputManager {
62
65
  * @returns Whether the pointer is released during the current frame
63
66
  */
64
67
  isPointerUp(pointerButton?: PointerButton): boolean;
68
+ /**
69
+ * @internal
70
+ */
71
+ constructor(engine: Engine, inputOptions?: IInputOptions);
72
+ /**
73
+ * @internal
74
+ */
75
+ _update(): void;
76
+ /**
77
+ * @internal
78
+ */
79
+ _firePointerScript(scenes: readonly Scene[]): void;
80
+ /**
81
+ * @internal
82
+ */
83
+ _destroy(): void;
65
84
  }
@@ -31,3 +31,11 @@ export declare enum PointerButton {
31
31
  /** Indicate the X8 pointer. */
32
32
  XButton8 = 1024
33
33
  }
34
+ /**
35
+ * @internal
36
+ */
37
+ export declare const _pointerDec2BinMap: PointerButton[];
38
+ /**
39
+ * @internal
40
+ */
41
+ export declare const _pointerBin2DecMap: Record<number, number>;
@@ -1 +1,41 @@
1
- export {};
1
+ import { Engine } from "../../Engine";
2
+ import { DisorderedArray } from "../../utils/DisorderedArray";
3
+ import { Keys } from "../enums/Keys";
4
+ import { IInput } from "../interface/IInput";
5
+ /**
6
+ * Keyboard Manager.
7
+ * @internal
8
+ */
9
+ export declare class KeyboardManager implements IInput {
10
+ /** @internal */
11
+ _curHeldDownKeyToIndexMap: number[];
12
+ /** @internal */
13
+ _upKeyToFrameCountMap: number[];
14
+ /** @internal */
15
+ _downKeyToFrameCountMap: number[];
16
+ /** @internal */
17
+ _curFrameHeldDownList: DisorderedArray<Keys>;
18
+ /** @internal */
19
+ _curFrameDownList: DisorderedArray<Keys>;
20
+ /** @internal */
21
+ _curFrameUpList: DisorderedArray<Keys>;
22
+ _target: EventTarget;
23
+ private _engine;
24
+ private _nativeEvents;
25
+ /**
26
+ * @internal
27
+ */
28
+ constructor(engine: Engine, target: EventTarget);
29
+ /**
30
+ * @internal
31
+ */
32
+ _update(): void;
33
+ /**
34
+ * @internal
35
+ */
36
+ _destroy(): void;
37
+ private _onBlur;
38
+ private _onKeyEvent;
39
+ private _addEventListener;
40
+ private _removeEventListener;
41
+ }
@@ -1,6 +1,10 @@
1
1
  import { Vector2 } from "@galacean/engine-math";
2
+ import { ClearableObjectPool } from "../../utils/ClearableObjectPool";
3
+ import { DisorderedArray } from "../../utils/DisorderedArray";
2
4
  import { PointerButton } from "../enums/PointerButton";
3
5
  import { PointerPhase } from "../enums/PointerPhase";
6
+ import { PointerEventData } from "./PointerEventData";
7
+ import { PointerEventEmitter } from "./emitter/PointerEventEmitter";
4
8
  /**
5
9
  * Pointer.
6
10
  */
@@ -20,6 +24,38 @@ export declare class Pointer {
20
24
  position: Vector2;
21
25
  /** The change of the pointer. */
22
26
  deltaPosition: Vector2;
27
+ /** @internal */
28
+ _events: PointerEvent[];
29
+ /** @internal */
30
+ _uniqueID: number;
31
+ /** @internal */
32
+ _upMap: number[];
33
+ /** @internal */
34
+ _downMap: number[];
35
+ /** @internal */
36
+ _upList: DisorderedArray<PointerButton>;
37
+ /** @internal */
38
+ _downList: DisorderedArray<PointerButton>;
39
+ /** @internal */
40
+ _frameEvents: PointerEventType;
41
+ /** @internal */
42
+ _emitters: PointerEventEmitter[];
43
+ /**
44
+ * @internal
45
+ */
46
+ constructor(id: number);
47
+ /**
48
+ * @internal
49
+ */
50
+ _addEmitters<T extends new (pool: ClearableObjectPool<PointerEventData>) => PointerEventEmitter>(type: T, pool: ClearableObjectPool<PointerEventData>): void;
51
+ /**
52
+ * @internal
53
+ */
54
+ _resetOnFrameBegin(): void;
55
+ /**
56
+ * @internal
57
+ */
58
+ _dispose(): void;
23
59
  }
24
60
  export declare enum PointerEventType {
25
61
  None = 0,
@@ -9,4 +9,8 @@ export declare class PointerEventData implements IPoolElement {
9
9
  pointer: Pointer;
10
10
  /** The position of the event trigger (in world space). */
11
11
  worldPosition: Vector3;
12
+ /**
13
+ * @internal
14
+ */
15
+ dispose(): void;
12
16
  }
@@ -1,9 +1,67 @@
1
+ import { Engine } from "../../Engine";
2
+ import { Scene } from "../../Scene";
1
3
  import { ClearableObjectPool } from "../../utils/ClearableObjectPool";
4
+ import { DisorderedArray } from "../../utils/DisorderedArray";
5
+ import { PointerButton } from "../enums/PointerButton";
6
+ import { IInput } from "../interface/IInput";
7
+ import { Pointer } from "./Pointer";
2
8
  import { PointerEventData } from "./PointerEventData";
3
9
  import { PointerEventEmitter } from "./emitter/PointerEventEmitter";
10
+ type PointerEventEmitterConstructor = new (pool: ClearableObjectPool<PointerEventData>) => PointerEventEmitter;
11
+ /**
12
+ * Pointer Manager.
13
+ * @internal
14
+ */
15
+ export declare class PointerManager implements IInput {
16
+ /** @internal */
17
+ static _pointerEventEmitters: PointerEventEmitterConstructor[];
18
+ /** @internal */
19
+ _pointers: Pointer[];
20
+ /** @internal */
21
+ _multiPointerEnabled: boolean;
22
+ /** @internal */
23
+ _buttons: PointerButton;
24
+ /** @internal */
25
+ _upMap: number[];
26
+ /** @internal */
27
+ _downMap: number[];
28
+ /** @internal */
29
+ _upList: DisorderedArray<PointerButton>;
30
+ /** @internal */
31
+ _downList: DisorderedArray<PointerButton>;
32
+ _target: EventTarget;
33
+ private _engine;
34
+ private _canvas;
35
+ private _nativeEvents;
36
+ private _pointerPool;
37
+ private _htmlCanvas;
38
+ private _eventPool;
39
+ /**
40
+ * @internal
41
+ */
42
+ constructor(engine: Engine, target: EventTarget);
43
+ /**
44
+ * @internal
45
+ */
46
+ _update(): void;
47
+ /**
48
+ * @internal
49
+ */
50
+ _firePointerScript(scenes: readonly Scene[]): void;
51
+ /**
52
+ * @internal
53
+ */
54
+ _destroy(): void;
55
+ private _onPointerEvent;
56
+ private _getPointerByID;
57
+ private _updatePointerInfo;
58
+ private _addEventListener;
59
+ private _removeEventListener;
60
+ }
4
61
  /**
5
62
  * Declare pointer event emitter decorator.
6
63
  */
7
64
  export declare function registerPointerEventEmitter(): <T extends PointerEventEmitter>(Target: {
8
65
  new (pool: ClearableObjectPool<PointerEventData>): T;
9
66
  }) => void;
67
+ export {};
@@ -1 +1,11 @@
1
- export {};
1
+ import { Vector3 } from "@galacean/engine-math";
2
+ import { Entity } from "../../../Entity";
3
+ /**
4
+ * @internal
5
+ */
6
+ export interface IHitResult {
7
+ entity: Entity;
8
+ distance: number;
9
+ point: Vector3;
10
+ normal: Vector3;
11
+ }
@@ -1 +1,20 @@
1
- export {};
1
+ import { Entity } from "../../../Entity";
2
+ import { Scene } from "../../../Scene";
3
+ import { Pointer } from "../Pointer";
4
+ import { PointerEventEmitter } from "./PointerEventEmitter";
5
+ /**
6
+ * @internal
7
+ */
8
+ export declare class PhysicsPointerEventEmitter extends PointerEventEmitter {
9
+ protected _enteredEntity: Entity;
10
+ protected _pressedEntity: Entity;
11
+ protected _draggedEntity: Entity;
12
+ processRaycast(scenes: readonly Scene[], pointer: Pointer): void;
13
+ processDrag(pointer: Pointer): void;
14
+ processDown(pointer: Pointer): void;
15
+ processUp(pointer: Pointer): void;
16
+ processLeave(pointer: Pointer): void;
17
+ dispose(): void;
18
+ protected _init(): void;
19
+ private _updateRaycast;
20
+ }
@@ -1 +1,34 @@
1
- export {};
1
+ import { Vector3 } from "@galacean/engine-math";
2
+ import { Engine } from "../../Engine";
3
+ import { IInput } from "../interface/IInput";
4
+ /**
5
+ * Wheel Manager.
6
+ * @internal
7
+ */
8
+ export declare class WheelManager implements IInput {
9
+ /** @internal */
10
+ _delta: Vector3;
11
+ _target: EventTarget;
12
+ private _nativeEvents;
13
+ /**
14
+ * @internal
15
+ */
16
+ constructor(engine: Engine, target: EventTarget);
17
+ /**
18
+ * @internal
19
+ */
20
+ _update(): void;
21
+ /**
22
+ * @internal
23
+ */
24
+ _addEventListener(): void;
25
+ /**
26
+ * @internal
27
+ */
28
+ _removeEventListener(): void;
29
+ /**
30
+ * @internal
31
+ */
32
+ _destroy(): void;
33
+ private _onWheelEvent;
34
+ }
@@ -1,6 +1,7 @@
1
1
  import { Color, SphericalHarmonics3 } from "@galacean/engine-math";
2
2
  import { ReferResource } from "../asset/ReferResource";
3
3
  import { Engine } from "../Engine";
4
+ import { Scene } from "../Scene";
4
5
  import { TextureCube } from "../texture";
5
6
  import { DiffuseMode } from "./enums/DiffuseMode";
6
7
  /**
@@ -55,6 +56,14 @@ export declare class AmbientLight extends ReferResource {
55
56
  */
56
57
  get specularIntensity(): number;
57
58
  set specularIntensity(value: number);
59
+ /**
60
+ * @internal
61
+ */
62
+ _addToScene(scene: Scene): void;
63
+ /**
64
+ * @internal
65
+ */
66
+ _removeFromScene(scene: Scene): void;
58
67
  constructor(engine: Engine);
59
68
  private _setDiffuseMode;
60
69
  private _setSpecularTexture;
@@ -1,4 +1,5 @@
1
1
  import { Vector3 } from "@galacean/engine-math";
2
+ import { ShaderData } from "../shader";
2
3
  import { Light } from "./Light";
3
4
  /**
4
5
  * Directional light.
@@ -7,6 +8,10 @@ export declare class DirectLight extends Light {
7
8
  private static _cullingMaskProperty;
8
9
  private static _colorProperty;
9
10
  private static _directionProperty;
11
+ /**
12
+ * @internal
13
+ */
14
+ static _updateShaderData(shaderData: ShaderData, data: IDirectLightShaderData): void;
10
15
  /**
11
16
  * The offset distance in the opposite direction of light direction when generating shadows.
12
17
  * @remarks Increasing this value can avoid the holes in the shadow caused by low polygon models.
@@ -21,6 +26,18 @@ export declare class DirectLight extends Light {
21
26
  * Get the opposite direction of the directional light direction.
22
27
  */
23
28
  get reverseDirection(): Vector3;
29
+ /**
30
+ * @internal
31
+ */
32
+ _appendData(lightIndex: number, data: IDirectLightShaderData): void;
33
+ /**
34
+ * @internal
35
+ */
36
+ _onEnableInScene(): void;
37
+ /**
38
+ * @internal
39
+ */
40
+ _onDisableInScene(): void;
24
41
  }
25
42
  /**
26
43
  * Shader properties data of direct lights in the scene.
@@ -22,6 +22,8 @@ export declare abstract class Light extends Component {
22
22
  * Please use `shadowNearPlaneOffset` instead.
23
23
  */
24
24
  shadowNearPlane: number;
25
+ /** @internal */
26
+ _lightIndex: number;
25
27
  private _shadowStrength;
26
28
  private _color;
27
29
  private _viewMat;
@@ -1,12 +1,69 @@
1
+ import { ShaderData, ShaderProperty } from "../shader";
2
+ import { DisorderedArray } from "../utils/DisorderedArray";
3
+ import { DirectLight } from "./DirectLight";
4
+ import { PointLight } from "./PointLight";
5
+ import { SpotLight } from "./SpotLight";
1
6
  /**
2
7
  * Light manager.
3
8
  */
4
9
  export declare class LightManager {
10
+ /** @internal */
11
+ static _sunlightColorProperty: ShaderProperty;
12
+ /** @internal */
13
+ static _sunlightDirectionProperty: ShaderProperty;
5
14
  /**
6
15
  * Each type of light source is at most 10, beyond which it will not take effect.
7
16
  * */
8
17
  private static _maxLight;
18
+ /** @internal */
19
+ _spotLights: DisorderedArray<SpotLight>;
20
+ /** @internal */
21
+ _pointLights: DisorderedArray<PointLight>;
22
+ /** @internal */
23
+ _directLights: DisorderedArray<DirectLight>;
24
+ /** @internal */
25
+ _sunlight: DirectLight | null;
9
26
  private _directData;
10
27
  private _pointData;
11
28
  private _spotData;
29
+ /**
30
+ * @internal
31
+ */
32
+ _attachSpotLight(light: SpotLight): void;
33
+ /**
34
+ * @internal
35
+ */
36
+ _detachSpotLight(light: SpotLight): void;
37
+ /**
38
+ * @internal
39
+ */
40
+ _attachPointLight(light: PointLight): void;
41
+ /**
42
+ * @internal
43
+ */
44
+ _detachPointLight(light: PointLight): void;
45
+ /**
46
+ * @internal
47
+ */
48
+ _attachDirectLight(light: DirectLight): void;
49
+ /**
50
+ * @internal
51
+ */
52
+ _detachDirectLight(light: DirectLight): void;
53
+ /**
54
+ * @internal
55
+ */
56
+ _updateShaderData(shaderData: ShaderData): void;
57
+ /**
58
+ * @internal
59
+ */
60
+ _gc(): void;
61
+ /**
62
+ * @internal
63
+ */
64
+ _updateSunlightIndex(light: DirectLight): void;
65
+ /**
66
+ * @internal
67
+ */
68
+ _getMaxBrightestSunlight(): DirectLight | null;
12
69
  }
@@ -1,4 +1,5 @@
1
1
  import { Vector3 } from "@galacean/engine-math";
2
+ import { ShaderData } from "../shader";
2
3
  import { Light } from "./Light";
3
4
  /**
4
5
  * Point light.
@@ -8,12 +9,28 @@ export declare class PointLight extends Light {
8
9
  private static _colorProperty;
9
10
  private static _positionProperty;
10
11
  private static _distanceProperty;
12
+ /**
13
+ * @internal
14
+ */
15
+ static _updateShaderData(shaderData: ShaderData, data: IPointLightShaderData): void;
11
16
  /** Defines a distance cutoff at which the light's intensity must be considered zero. */
12
17
  distance: number;
13
18
  /**
14
19
  * Get light position.
15
20
  */
16
21
  get position(): Vector3;
22
+ /**
23
+ * @internal
24
+ */
25
+ _appendData(lightIndex: number, data: IPointLightShaderData): void;
26
+ /**
27
+ * @internal
28
+ */
29
+ _onEnableInScene(): void;
30
+ /**
31
+ * @internal
32
+ */
33
+ _onDisableInScene(): void;
17
34
  }
18
35
  /**
19
36
  * Shader properties data of point lights in the scene.
@@ -1,4 +1,5 @@
1
1
  import { Vector3 } from "@galacean/engine-math";
2
+ import { ShaderData } from "../shader";
2
3
  import { Light } from "./Light";
3
4
  /**
4
5
  * Spot light.
@@ -11,6 +12,10 @@ export declare class SpotLight extends Light {
11
12
  private static _distanceProperty;
12
13
  private static _angleCosProperty;
13
14
  private static _penumbraCosProperty;
15
+ /**
16
+ * @internal
17
+ */
18
+ static _updateShaderData(shaderData: ShaderData, data: ISpotLightShaderData): void;
14
19
  /** Defines a distance cutoff at which the light's intensity must be considered zero. */
15
20
  distance: number;
16
21
  /** Angle, in radians, from centre of spotlight where falloff begins. */
@@ -30,6 +35,18 @@ export declare class SpotLight extends Light {
30
35
  * Get the opposite direction of the spotlight.
31
36
  */
32
37
  get reverseDirection(): Vector3;
38
+ /**
39
+ * @internal
40
+ */
41
+ _appendData(lightIndex: number, data: ISpotLightShaderData): void;
42
+ /**
43
+ * @internal
44
+ */
45
+ _onEnableInScene(): void;
46
+ /**
47
+ * @internal
48
+ */
49
+ _onDisableInScene(): void;
33
50
  }
34
51
  /**
35
52
  * Shader properties data of spot lights in the scene.
@@ -75,5 +75,9 @@ export declare class AmbientOcclusion {
75
75
  get minHorizonAngle(): number;
76
76
  set minHorizonAngle(value: number);
77
77
  constructor(scene: Scene);
78
+ /**
79
+ * @internal
80
+ */
81
+ _isValid(): boolean;
78
82
  private _toggleAmbientOcclusionMacro;
79
83
  }
@@ -1 +1,38 @@
1
- export {};
1
+ import { Camera } from "../../Camera";
2
+ import { Engine } from "../../Engine";
3
+ import { PipelinePass } from "../../RenderPipeline/PipelinePass";
4
+ import { RenderContext } from "../../RenderPipeline/RenderContext";
5
+ import { RenderTarget } from "../../texture";
6
+ /**
7
+ * @internal
8
+ * Scalable Ambient Obscurance render pass.
9
+ */
10
+ export declare class ScalableAmbientObscurancePass extends PipelinePass {
11
+ static readonly SHADER_NAME = "Lighting/ScalableAmbientOcclusion";
12
+ private static _invRadiusSquaredProp;
13
+ private static _intensityProp;
14
+ private static _projectionScaleRadiusProp;
15
+ private static _biasProp;
16
+ private static _minHorizonAngleSineSquaredProp;
17
+ private static _peak2Prop;
18
+ private static _powerProp;
19
+ private static _invProjScaleXYProp;
20
+ readonly isSupported: boolean;
21
+ private static _farPlaneOverEdgeDistanceProp;
22
+ private static _kernelProp;
23
+ private readonly _material;
24
+ private _saoRenderTarget?;
25
+ private _depthRenderTarget;
26
+ private _blurRenderTarget;
27
+ private _aoSpiralSampleCount;
28
+ private _blurStepPixels;
29
+ private _invProjScaleXY;
30
+ private _offsetX;
31
+ private _offsetY;
32
+ private _quality;
33
+ constructor(engine: Engine);
34
+ onConfig(camera: Camera, depthRenderTarget: RenderTarget): void;
35
+ onRender(context: RenderContext): void;
36
+ release(): void;
37
+ private _updateBlurKernel;
38
+ }