@galacean/engine-core 0.0.0-experimental-0.9-plus.8 → 0.0.0-experimental-ktx2.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (119) hide show
  1. package/dist/main.js +20880 -18164
  2. package/dist/main.js.map +1 -1
  3. package/dist/miniprogram.js +20880 -18164
  4. package/dist/module.js +20861 -18155
  5. package/dist/module.js.map +1 -1
  6. package/package.json +3 -3
  7. package/types/2d/atlas/SpriteAtlas.d.ts +2 -6
  8. package/types/2d/enums/SpriteDrawMode.d.ts +4 -2
  9. package/types/2d/index.d.ts +1 -0
  10. package/types/2d/sprite/Sprite.d.ts +5 -2
  11. package/types/2d/sprite/SpriteMask.d.ts +0 -11
  12. package/types/2d/sprite/SpriteRenderer.d.ts +15 -11
  13. package/types/2d/text/Font.d.ts +2 -7
  14. package/types/2d/text/TextRenderer.d.ts +0 -11
  15. package/types/2d/text/index.d.ts +1 -0
  16. package/types/Camera.d.ts +55 -14
  17. package/types/Component.d.ts +1 -8
  18. package/types/ComponentsDependencies.d.ts +17 -9
  19. package/types/DisorderedArray.d.ts +4 -3
  20. package/types/Engine.d.ts +43 -46
  21. package/types/Entity.d.ts +4 -2
  22. package/types/RenderPipeline/Basic2DBatcher.d.ts +6 -7
  23. package/types/RenderPipeline/BasicRenderPipeline.d.ts +7 -6
  24. package/types/RenderPipeline/CullingResults.d.ts +1 -0
  25. package/types/RenderPipeline/DepthOnlyPass.d.ts +1 -0
  26. package/types/RenderPipeline/MeshRenderElement.d.ts +1 -3
  27. package/types/RenderPipeline/PipelinePass.d.ts +16 -0
  28. package/types/RenderPipeline/PipelineUtils.d.ts +1 -0
  29. package/types/RenderPipeline/RenderElement.d.ts +8 -10
  30. package/types/RenderPipeline/RenderPass.d.ts +1 -1
  31. package/types/RenderPipeline/RenderQueue.d.ts +3 -5
  32. package/types/RenderPipeline/SpriteElement.d.ts +1 -3
  33. package/types/RenderPipeline/SpriteMaskBatcher.d.ts +4 -3
  34. package/types/RenderPipeline/SpriteMaskElement.d.ts +1 -3
  35. package/types/RenderPipeline/TextRenderElement.d.ts +1 -3
  36. package/types/RenderPipeline/enums/PipelineStage.d.ts +2 -0
  37. package/types/Renderer.d.ts +3 -12
  38. package/types/Scene.d.ts +3 -5
  39. package/types/SceneManager.d.ts +28 -5
  40. package/types/Script.d.ts +18 -15
  41. package/types/Transform.d.ts +10 -12
  42. package/types/Utils.d.ts +28 -0
  43. package/types/animation/AnimationClip.d.ts +2 -1
  44. package/types/animation/Animator.d.ts +5 -4
  45. package/types/animation/animationCurve/AnimationFloatArrayCurve.d.ts +0 -1
  46. package/types/animation/enums/LayerState.d.ts +3 -1
  47. package/types/asset/AssetType.d.ts +18 -16
  48. package/types/asset/LoadItem.d.ts +16 -9
  49. package/types/asset/Loader.d.ts +3 -1
  50. package/types/asset/ResourceManager.d.ts +23 -11
  51. package/types/asset/request.d.ts +7 -3
  52. package/types/base/Constant.d.ts +3 -1
  53. package/types/base/EngineObject.d.ts +1 -0
  54. package/types/base/EventDispatcher.d.ts +2 -15
  55. package/types/base/Time.d.ts +25 -24
  56. package/types/base/index.d.ts +0 -2
  57. package/types/clone/ComponentCloner.d.ts +2 -1
  58. package/types/enums/DepthTextureMode.d.ts +7 -0
  59. package/types/env-probe/CubeProbe.d.ts +0 -7
  60. package/types/env-probe/Probe.d.ts +0 -6
  61. package/types/graphic/Buffer.d.ts +25 -16
  62. package/types/graphic/BufferUtil.d.ts +1 -0
  63. package/types/graphic/Mesh.d.ts +5 -16
  64. package/types/graphic/VertexElement.d.ts +10 -6
  65. package/types/index.d.ts +9 -7
  66. package/types/input/InputManager.d.ts +3 -3
  67. package/types/input/interface/IInput.d.ts +1 -1
  68. package/types/lighting/AmbientLight.d.ts +4 -1
  69. package/types/lighting/DirectLight.d.ts +0 -1
  70. package/types/lighting/Light.d.ts +0 -1
  71. package/types/lighting/LightManager.d.ts +1 -0
  72. package/types/lighting/SpotLight.d.ts +0 -1
  73. package/types/material/BaseMaterial.d.ts +8 -10
  74. package/types/material/BlinnPhongMaterial.d.ts +0 -3
  75. package/types/material/Material.d.ts +3 -6
  76. package/types/material/PBRMaterial.d.ts +1 -1
  77. package/types/material/PBRSpecularMaterial.d.ts +1 -1
  78. package/types/material/UnlitMaterial.d.ts +1 -1
  79. package/types/mesh/BlendShape.d.ts +1 -1
  80. package/types/mesh/BlendShapeFrame.d.ts +28 -6
  81. package/types/mesh/BufferMesh.d.ts +2 -2
  82. package/types/mesh/MeshRenderer.d.ts +1 -11
  83. package/types/mesh/ModelMesh.d.ts +62 -41
  84. package/types/mesh/PrimitiveMesh.d.ts +6 -2
  85. package/types/mesh/Skin.d.ts +3 -0
  86. package/types/mesh/SkinnedMeshRenderer.d.ts +18 -24
  87. package/types/mesh/index.d.ts +6 -5
  88. package/types/particle/ParticleRenderer.d.ts +2 -2
  89. package/types/physics/CharacterController.d.ts +0 -2
  90. package/types/physics/Collider.d.ts +1 -1
  91. package/types/physics/PhysicsManager.d.ts +1 -20
  92. package/types/physics/index.d.ts +7 -7
  93. package/types/physics/joint/HingeJoint.d.ts +2 -2
  94. package/types/physics/joint/Joint.d.ts +2 -2
  95. package/types/physics/joint/SpringJoint.d.ts +1 -1
  96. package/types/renderingHardwareInterface/IPlatformBuffer.d.ts +0 -1
  97. package/types/renderingHardwareInterface/IPlatformTexture2D.d.ts +1 -1
  98. package/types/renderingHardwareInterface/IPlatformTexture2DArray.d.ts +1 -1
  99. package/types/renderingHardwareInterface/IPlatformTextureCube.d.ts +1 -1
  100. package/types/renderingHardwareInterface/index.d.ts +1 -0
  101. package/types/shader/Shader.d.ts +54 -23
  102. package/types/shader/ShaderData.d.ts +24 -24
  103. package/types/shader/ShaderMacro.d.ts +16 -0
  104. package/types/shader/ShaderPass.d.ts +9 -2
  105. package/types/shader/ShaderProperty.d.ts +7 -0
  106. package/types/shader/enums/RenderStateElementKey.d.ts +58 -0
  107. package/types/shader/index.d.ts +6 -1
  108. package/types/shadow/CascadedShadowCasterPass.d.ts +5 -7
  109. package/types/sky/SkyBoxMaterial.d.ts +27 -9
  110. package/types/sky/index.d.ts +1 -0
  111. package/types/texture/RenderTarget.d.ts +3 -8
  112. package/types/texture/Texture.d.ts +8 -6
  113. package/types/texture/Texture2D.d.ts +4 -2
  114. package/types/texture/Texture2DArray.d.ts +1 -1
  115. package/types/texture/TextureCube.d.ts +1 -1
  116. package/types/texture/enums/TextureFormat.d.ts +55 -49
  117. package/types/texture/index.d.ts +1 -0
  118. package/types/trail/TrailRenderer.d.ts +0 -5
  119. package/types/SafeLoopArray.d.ts +0 -37
@@ -43,7 +43,7 @@ export declare class Texture2DArray extends Texture {
43
43
  * @param x - X coordinate of area start
44
44
  * @param y - Y coordinate of area start
45
45
  */
46
- setImageSource(elementIndex: number, imageSource: TexImageSource | OffscreenCanvas, mipLevel?: number, flipY?: boolean, premultiplyAlpha?: boolean, x?: number, y?: number): void;
46
+ setImageSource(elementIndex: number, imageSource: TexImageSource, mipLevel?: number, flipY?: boolean, premultiplyAlpha?: boolean, x?: number, y?: number): void;
47
47
  /**
48
48
  * Get pixel color buffer.
49
49
  * @param elementIndex - The texture array element index
@@ -36,7 +36,7 @@ export declare class TextureCube extends Texture {
36
36
  * @param x - X coordinate of area start
37
37
  * @param y - Y coordinate of area start
38
38
  */
39
- setImageSource(face: TextureCubeFace, imageSource: TexImageSource | OffscreenCanvas, mipLevel?: number, flipY?: boolean, premultiplyAlpha?: boolean, x?: number, y?: number): void;
39
+ setImageSource(face: TextureCubeFace, imageSource: TexImageSource, mipLevel?: number, flipY?: boolean, premultiplyAlpha?: boolean, x?: number, y?: number): void;
40
40
  /**
41
41
  * Get pixel color buffer.
42
42
  * @param out - Color buffer
@@ -2,68 +2,74 @@
2
2
  * Texture format enumeration.
3
3
  */
4
4
  export declare enum TextureFormat {
5
- /** RGB format,8 bits per channel. */
5
+ /** RGB format, 8 bits per channel. */
6
6
  R8G8B8 = 0,
7
- /** RGBA format,8 bits per channel. */
7
+ /** RGBA format, 8 bits per channel. */
8
8
  R8G8B8A8 = 1,
9
- /** RGBA format,4 bits per channel. */
9
+ /** RGBA format, 4 bits per channel. */
10
10
  R4G4B4A4 = 2,
11
- /** RGBA format,5 bits in R channel,5 bits in G channel,5 bits in B channel, 1 bit in A channel. */
11
+ /** RGBA format, 5 bits in R channel, 5 bits in G channel, 5 bits in B channel, 1 bit in A channel. */
12
12
  R5G5B5A1 = 3,
13
- /** RGB format,5 bits in R channel,6 bits in G channel,5 bits in B channel. */
13
+ /** RGB format, 5 bits in R channel, 6 bits in G channel, 5 bits in B channel. */
14
14
  R5G6B5 = 4,
15
- /** Transparent format,8 bits. */
15
+ /** Transparent format, 8 bits. */
16
16
  Alpha8 = 5,
17
17
  /** Luminance/alpha in RGB channel, alpha in A channel. */
18
18
  LuminanceAlpha = 6,
19
- /** RGBA format,16 bits per channel. */
19
+ /** RGBA format, 16 bits per channel. */
20
20
  R16G16B16A16 = 7,
21
- /** RGBA format,32 bits per channel. */
21
+ /** RGBA format, 32 bits per channel. */
22
22
  R32G32B32A32 = 8,
23
- /** RGB compressed format。*/
24
- DXT1 = 9,
25
- /** RGBA compressed format。*/
26
- DXT5 = 10,
27
- /** RGB compressed format,4 bits per pixel。*/
28
- ETC1_RGB = 11,
29
- /** RGB compressed format,4 bits per pixel。*/
30
- ETC2_RGB = 12,
31
- /** RGBA compressed format,5 bits per pixel,4 bit in RGB, 1 bit in A. */
32
- ETC2_RGBA5 = 13,
33
- /** RGB compressed format,8 bits per pixel. */
34
- ETC2_RGBA8 = 14,
35
- /** RGB compressed format,2 bits per pixel. */
36
- PVRTC_RGB2 = 15,
37
- /** RGBA compressed format,2 bits per pixel. */
38
- PVRTC_RGBA2 = 16,
39
- /** RGB compressed format,4 bits per pixel. */
40
- PVRTC_RGB4 = 17,
41
- /** RGBA compressed format,4 bits per pixel. */
42
- PVRTC_RGBA4 = 18,
43
- /** RGB(A) compressed format,128 bits per 4x4 pixel block. */
44
- ASTC_4x4 = 19,
45
- /** RGB(A) compressed format,128 bits per 5x5 pixel block. */
46
- ASTC_5x5 = 20,
47
- /** RGB(A) compressed format,128 bits per 6x6 pixel block. */
48
- ASTC_6x6 = 21,
49
- /** RGB(A) compressed format,128 bits per 8x8 pixel block. */
50
- ASTC_8x8 = 22,
51
- /** RGB(A) compressed format,128 bits per 10x10 pixel block. */
52
- ASTC_10x10 = 23,
53
- /** RGB(A) compressed format,128 bits per 12x12 pixel block. */
54
- ASTC_12x12 = 24,
55
- /** Automatic depth format,engine will automatically select the supported precision. */
56
- Depth = 25,
57
- /** Automatic depth setncil format, engine will automatically select the supported precision. */
58
- DepthStencil = 26,
23
+ /** RGB compressed format, 4 bits per pixel. */
24
+ BC1 = 9,
25
+ /** RGBA compressed format, 8 bits per pixel. */
26
+ BC3 = 10,
27
+ /** RGB(A) compressed format, 128 bits per 4x4 pixel block. */
28
+ BC7 = 11,
29
+ /** RGB compressed format, 4 bits per pixel. */
30
+ ETC1_RGB = 12,
31
+ /** RGB compressed format, 4 bits per pixel. */
32
+ ETC2_RGB = 13,
33
+ /** RGBA compressed format, 5 bits per pixel, 4 bit in RGB, 1 bit in A. */
34
+ ETC2_RGBA5 = 14,
35
+ /** RGB compressed format, 8 bits per pixel. */
36
+ ETC2_RGBA8 = 15,
37
+ /** RGB compressed format, 2 bits per pixel. */
38
+ PVRTC_RGB2 = 16,
39
+ /** RGBA compressed format, 2 bits per pixel. */
40
+ PVRTC_RGBA2 = 17,
41
+ /** RGB compressed format, 4 bits per pixel. */
42
+ PVRTC_RGB4 = 18,
43
+ /** RGBA compressed format, 4 bits per pixel. */
44
+ PVRTC_RGBA4 = 19,
45
+ /** RGB(A) compressed format, 128 bits per 4x4 pixel block. */
46
+ ASTC_4x4 = 20,
47
+ /** RGB(A) compressed format, 128 bits per 5x5 pixel block. */
48
+ ASTC_5x5 = 21,
49
+ /** RGB(A) compressed format, 128 bits per 6x6 pixel block. */
50
+ ASTC_6x6 = 22,
51
+ /** RGB(A) compressed format, 128 bits per 8x8 pixel block. */
52
+ ASTC_8x8 = 23,
53
+ /** RGB(A) compressed format, 128 bits per 10x10 pixel block. */
54
+ ASTC_10x10 = 24,
55
+ /** RGB(A) compressed format, 128 bits per 12x12 pixel block. */
56
+ ASTC_12x12 = 25,
57
+ /** Automatic depth format, engine will automatically select the supported precision. */
58
+ Depth = 26,
59
+ /** Automatic depth stencil format, engine will automatically select the supported precision. */
60
+ DepthStencil = 27,
59
61
  /** 16-bit depth format. */
60
- Depth16 = 27,
62
+ Depth16 = 28,
61
63
  /** 24-bit depth format. */
62
- Depth24 = 28,
64
+ Depth24 = 29,
63
65
  /** 32-bit depth format. */
64
- Depth32 = 29,
66
+ Depth32 = 30,
65
67
  /** 16-bit depth + 8-bit stencil format. */
66
- Depth24Stencil8 = 30,
68
+ Depth24Stencil8 = 31,
67
69
  /** 32-bit depth + 8-bit stencil format. */
68
- Depth32Stencil8 = 31
70
+ Depth32Stencil8 = 32,
71
+ /** @deprecated Use `TextureFormat.BC1` instead. */
72
+ DXT1 = 33,
73
+ /** @deprecated Use `TextureFormat.BC3` instead. */
74
+ DXT5 = 34
69
75
  }
@@ -3,6 +3,7 @@ export { TextureCubeFace } from "./enums/TextureCubeFace";
3
3
  export { TextureDepthCompareFunction } from "./enums/TextureDepthCompareFunction";
4
4
  export { TextureFilterMode } from "./enums/TextureFilterMode";
5
5
  export { TextureFormat } from "./enums/TextureFormat";
6
+ export { TextureUsage } from "./enums/TextureUsage";
6
7
  export { TextureWrapMode } from "./enums/TextureWrapMode";
7
8
  export { RenderTarget } from "./RenderTarget";
8
9
  export { Texture } from "./Texture";
@@ -1,6 +1,5 @@
1
1
  import { Entity } from "../Entity";
2
2
  import { MeshRenderer } from "../mesh/MeshRenderer";
3
- import { RenderContext } from "../RenderPipeline/RenderContext";
4
3
  import { Texture2D } from "../texture";
5
4
  /**
6
5
  * @deprecated
@@ -28,10 +27,6 @@ export declare class TrailRenderer extends MeshRenderer {
28
27
  * @param texture
29
28
  */
30
29
  setTexture(texture: Texture2D): void;
31
- /**
32
- * @override
33
- */
34
- protected _render(context: RenderContext): void;
35
30
  private _initGeometry;
36
31
  private _updateStrapVertices;
37
32
  private _updateStrapCoords;
@@ -1,37 +0,0 @@
1
- export declare class SafeLoopArray<T> {
2
- private _array;
3
- private _loopArray;
4
- private _loopArrayDirty;
5
- /**
6
- * Get the length of the array.
7
- */
8
- get length(): number;
9
- /**
10
- * Push item to the array.
11
- * @param item - The item which want to be pushed
12
- */
13
- push(item: T): void;
14
- /**
15
- * Splice the array.
16
- * @param index - The index of the array
17
- * @param deleteCount - The count of the array which want to be deleted
18
- * @param item - The item which want to be added
19
- */
20
- splice(index: number, deleteCount: number, item?: T): void;
21
- /**
22
- * The index of the item.
23
- * @param item - The item which want to get the index
24
- * @returns Index of the item
25
- */
26
- indexOf(item: T): number;
27
- /**
28
- * Get the array.
29
- * @returns The array
30
- */
31
- getArray(): ReadonlyArray<T>;
32
- /**
33
- * Get the array use for loop.
34
- * @returns The array use for loop
35
- */
36
- getLoopArray(): ReadonlyArray<T>;
37
- }