@babylonjs/core 5.16.0 → 5.18.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.
- package/Animations/animatable.js +1 -1
- package/Animations/animatable.js.map +1 -1
- package/Animations/animation.d.ts +8 -1
- package/Animations/animation.js +8 -1
- package/Animations/animation.js.map +1 -1
- package/Animations/animationGroup.js +5 -4
- package/Animations/animationGroup.js.map +1 -1
- package/Bones/skeleton.js +1 -1
- package/Bones/skeleton.js.map +1 -1
- package/Cameras/Inputs/arcRotateCameraKeyboardMoveInput.js +2 -2
- package/Cameras/Inputs/arcRotateCameraKeyboardMoveInput.js.map +1 -1
- package/Cameras/Inputs/flyCameraKeyboardInput.js +3 -3
- package/Cameras/Inputs/flyCameraKeyboardInput.js.map +1 -1
- package/Cameras/Inputs/followCameraKeyboardMoveInput.js +2 -2
- package/Cameras/Inputs/followCameraKeyboardMoveInput.js.map +1 -1
- package/Cameras/Inputs/freeCameraKeyboardMoveInput.js +3 -3
- package/Cameras/Inputs/freeCameraKeyboardMoveInput.js.map +1 -1
- package/Cameras/Inputs/freeCameraTouchInput.js +1 -1
- package/Cameras/Inputs/freeCameraTouchInput.js.map +1 -1
- package/Cameras/VR/vrExperienceHelper.js +1 -1
- package/Cameras/VR/vrExperienceHelper.js.map +1 -1
- package/Cameras/VR/webVRCamera.js +1 -1
- package/Cameras/VR/webVRCamera.js.map +1 -1
- package/Cameras/camera.js +3 -3
- package/Cameras/camera.js.map +1 -1
- package/Engines/Extensions/engine.views.d.ts +13 -0
- package/Engines/Extensions/engine.views.js +16 -1
- package/Engines/Extensions/engine.views.js.map +1 -1
- package/Engines/Processors/shaderCodeCursor.js +2 -1
- package/Engines/Processors/shaderCodeCursor.js.map +1 -1
- package/Engines/WebGPU/webgpuOcclusionQuery.js +1 -1
- package/Engines/WebGPU/webgpuOcclusionQuery.js.map +1 -1
- package/Engines/engine.d.ts +2 -10
- package/Engines/engine.js +0 -14
- package/Engines/engine.js.map +1 -1
- package/Engines/engineFeatures.d.ts +2 -0
- package/Engines/engineFeatures.js.map +1 -1
- package/Engines/nativeEngine.d.ts +6 -2
- package/Engines/nativeEngine.js +13 -6
- package/Engines/nativeEngine.js.map +1 -1
- package/Engines/nullEngine.js +1 -0
- package/Engines/nullEngine.js.map +1 -1
- package/Engines/thinEngine.d.ts +10 -0
- package/Engines/thinEngine.js +26 -6
- package/Engines/thinEngine.js.map +1 -1
- package/Engines/webgpuEngine.js +1 -0
- package/Engines/webgpuEngine.js.map +1 -1
- package/Gizmos/axisDragGizmo.d.ts +11 -8
- package/Gizmos/axisDragGizmo.js.map +1 -1
- package/Gizmos/axisScaleGizmo.d.ts +20 -13
- package/Gizmos/axisScaleGizmo.js.map +1 -1
- package/Gizmos/boundingBoxGizmo.d.ts +27 -18
- package/Gizmos/boundingBoxGizmo.js +6 -0
- package/Gizmos/boundingBoxGizmo.js.map +1 -1
- package/Gizmos/cameraGizmo.d.ts +8 -5
- package/Gizmos/cameraGizmo.js.map +1 -1
- package/Gizmos/gizmo.d.ts +48 -6
- package/Gizmos/gizmo.js.map +1 -1
- package/Gizmos/gizmoManager.d.ts +17 -9
- package/Gizmos/gizmoManager.js.map +1 -1
- package/Gizmos/lightGizmo.d.ts +12 -7
- package/Gizmos/lightGizmo.js.map +1 -1
- package/Gizmos/planeDragGizmo.d.ts +10 -8
- package/Gizmos/planeDragGizmo.js.map +1 -1
- package/Gizmos/planeRotationGizmo.d.ts +23 -14
- package/Gizmos/planeRotationGizmo.js.map +1 -1
- package/Gizmos/positionGizmo.d.ts +9 -7
- package/Gizmos/positionGizmo.js +1 -1
- package/Gizmos/positionGizmo.js.map +1 -1
- package/Gizmos/rotationGizmo.d.ts +6 -4
- package/Gizmos/rotationGizmo.js.map +1 -1
- package/Gizmos/scaleGizmo.d.ts +15 -12
- package/Gizmos/scaleGizmo.js.map +1 -1
- package/Inputs/scene.inputManager.js +0 -3
- package/Inputs/scene.inputManager.js.map +1 -1
- package/Loading/sceneLoader.js +5 -5
- package/Loading/sceneLoader.js.map +1 -1
- package/Materials/Node/Blocks/Fragment/TBNBlock.d.ts +12 -0
- package/Materials/Node/Blocks/Fragment/TBNBlock.js +50 -0
- package/Materials/Node/Blocks/Fragment/TBNBlock.js.map +1 -1
- package/Materials/Node/Blocks/Vertex/lightInformationBlock.d.ts +18 -0
- package/Materials/Node/Blocks/Vertex/lightInformationBlock.js +85 -1
- package/Materials/Node/Blocks/Vertex/lightInformationBlock.js.map +1 -1
- package/Materials/Node/Blocks/gradientBlock.js +1 -1
- package/Materials/Node/Blocks/gradientBlock.js.map +1 -1
- package/Materials/Node/nodeMaterial.d.ts +18 -2
- package/Materials/Node/nodeMaterial.js +56 -27
- package/Materials/Node/nodeMaterial.js.map +1 -1
- package/Materials/Textures/baseTexture.d.ts +2 -1
- package/Materials/Textures/baseTexture.js +4 -1
- package/Materials/Textures/baseTexture.js.map +1 -1
- package/Materials/Textures/prePassRenderTarget.js +1 -1
- package/Materials/Textures/prePassRenderTarget.js.map +1 -1
- package/Materials/Textures/renderTargetTexture.js +11 -3
- package/Materials/Textures/renderTargetTexture.js.map +1 -1
- package/Materials/materialDefines.js +3 -1
- package/Materials/materialDefines.js.map +1 -1
- package/Materials/shaderMaterial.d.ts +10 -1
- package/Materials/shaderMaterial.js +10 -1
- package/Materials/shaderMaterial.js.map +1 -1
- package/Maths/math.color.d.ts +9 -1
- package/Maths/math.color.js +13 -1
- package/Maths/math.color.js.map +1 -1
- package/Maths/math.vector.d.ts +2 -2
- package/Maths/math.vector.js +18 -30
- package/Maths/math.vector.js.map +1 -1
- package/Meshes/Builders/icoSphereBuilder.js +2 -2
- package/Meshes/Builders/icoSphereBuilder.js.map +1 -1
- package/Meshes/Compression/dracoCompression.js +1 -1
- package/Meshes/Compression/dracoCompression.js.map +1 -1
- package/Meshes/abstractMesh.js +1 -1
- package/Meshes/abstractMesh.js.map +1 -1
- package/Meshes/geometry.js +1 -2
- package/Meshes/geometry.js.map +1 -1
- package/Meshes/thinInstanceMesh.js +5 -0
- package/Meshes/thinInstanceMesh.js.map +1 -1
- package/Misc/basis.js +3 -0
- package/Misc/basis.js.map +1 -1
- package/Misc/fileTools.js +2 -2
- package/Misc/fileTools.js.map +1 -1
- package/Misc/khronosTextureContainer2.js +1 -1
- package/Misc/khronosTextureContainer2.js.map +1 -1
- package/Misc/smartArray.js +0 -1
- package/Misc/smartArray.js.map +1 -1
- package/Misc/tools.d.ts +2 -2
- package/Misc/tools.js +4 -1
- package/Misc/tools.js.map +1 -1
- package/Offline/database.js +6 -8
- package/Offline/database.js.map +1 -1
- package/Particles/computeShaderParticleSystem.js +2 -2
- package/Particles/computeShaderParticleSystem.js.map +1 -1
- package/Particles/particleHelper.d.ts +12 -1
- package/Particles/particleHelper.js +12 -1
- package/Particles/particleHelper.js.map +1 -1
- package/Particles/particleSystem.js +2 -2
- package/Particles/particleSystem.js.map +1 -1
- package/Particles/particleSystemSet.js +1 -1
- package/Particles/particleSystemSet.js.map +1 -1
- package/Particles/solidParticleSystem.d.ts +3 -0
- package/Particles/solidParticleSystem.js +3 -0
- package/Particles/solidParticleSystem.js.map +1 -1
- package/Particles/webgl2ParticleSystem.js +2 -2
- package/Particles/webgl2ParticleSystem.js.map +1 -1
- package/Physics/Plugins/ammoJSPlugin.d.ts +2 -2
- package/Physics/Plugins/ammoJSPlugin.js +29 -29
- package/Physics/Plugins/ammoJSPlugin.js.map +1 -1
- package/Physics/Plugins/cannonJSPlugin.d.ts +2 -2
- package/Physics/Plugins/cannonJSPlugin.js +26 -26
- package/Physics/Plugins/cannonJSPlugin.js.map +1 -1
- package/Physics/Plugins/oimoJSPlugin.js +9 -11
- package/Physics/Plugins/oimoJSPlugin.js.map +1 -1
- package/Physics/physicsImpostor.d.ts +6 -6
- package/Physics/physicsImpostor.js +7 -6
- package/Physics/physicsImpostor.js.map +1 -1
- package/PostProcesses/RenderPipeline/Pipelines/standardRenderingPipeline.js +3 -3
- package/PostProcesses/RenderPipeline/Pipelines/standardRenderingPipeline.js.map +1 -1
- package/Rendering/utilityLayerRenderer.js +1 -1
- package/Rendering/utilityLayerRenderer.js.map +1 -1
- package/Shaders/sprites.fragment.js +1 -1
- package/Shaders/sprites.fragment.js.map +1 -1
- package/Sprites/spriteManager.d.ts +10 -1
- package/Sprites/spriteManager.js +10 -1
- package/Sprites/spriteManager.js.map +1 -1
- package/Sprites/spriteRenderer.js +1 -1
- package/Sprites/spriteRenderer.js.map +1 -1
- package/XR/features/WebXRLayers.js +1 -1
- package/XR/features/WebXRLayers.js.map +1 -1
- package/assetContainer.js +12 -12
- package/assetContainer.js.map +1 -1
- package/node.js +1 -1
- package/node.js.map +1 -1
- package/package.json +1 -1
- package/scene.d.ts +2 -0
- package/scene.js +15 -8
- package/scene.js.map +1 -1
|
@@ -44,6 +44,8 @@ export interface EngineFeatures {
|
|
|
44
44
|
needToAlwaysBindUniformBuffers: boolean;
|
|
45
45
|
/** Indicates that the engine supports render passes */
|
|
46
46
|
supportRenderPasses: boolean;
|
|
47
|
+
/** Indicates that the engine supports sprite instancing */
|
|
48
|
+
supportSpriteInstancing: boolean;
|
|
47
49
|
/** @hidden */
|
|
48
50
|
_collectUbosUpdatedInFrame: boolean;
|
|
49
51
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"engineFeatures.js","sourceRoot":"","sources":["../../../../../lts/core/generated/Engines/engineFeatures.ts"],"names":[],"mappings":"","sourcesContent":["/** @hidden */\r\nexport interface EngineFeatures {\r\n /** Force using Bitmap when Bitmap or HTMLImageElement can be used */\r\n forceBitmapOverHTMLImageElement: boolean;\r\n\r\n /** Indicates that the engine support rendering to as well as copying to lod float textures */\r\n supportRenderAndCopyToLodForFloatTextures: boolean;\r\n\r\n /** Indicates that the engine support handling depth/stencil textures */\r\n supportDepthStencilTexture: boolean;\r\n\r\n /** Indicates that the engine support shadow samplers */\r\n supportShadowSamplers: boolean;\r\n\r\n /** Indicates to check the matrix bytes per bytes to know if it has changed or not. If false, only the updateFlag of the matrix is checked */\r\n uniformBufferHardCheckMatrix: boolean;\r\n\r\n /** Indicates that prefiltered mipmaps can be generated in some processes (for eg when loading an HDR cube texture) */\r\n allowTexturePrefiltering: boolean;\r\n\r\n /** Indicates to track the usage of ubos and to create new ones as necessary during a frame duration */\r\n trackUbosInFrame: boolean;\r\n\r\n /** Indicates that the current content of a ubo should be compared to the content of the corresponding GPU buffer and the GPU buffer updated only if different. Requires trackUbosInFrame to be true */\r\n checkUbosContentBeforeUpload: boolean;\r\n\r\n /** Indicates that the Cascaded Shadow Map technic is supported */\r\n supportCSM: boolean;\r\n\r\n /** Indicates that the textures transcoded by the basis transcoder must have power of 2 width and height */\r\n basisNeedsPOT: boolean;\r\n\r\n /** Indicates that the engine supports 3D textures */\r\n support3DTextures: boolean;\r\n\r\n /** Indicates that constants need a type suffix in shaders (used by realtime filtering...) */\r\n needTypeSuffixInShaderConstants: boolean;\r\n\r\n /** Indicates that MSAA is supported */\r\n supportMSAA: boolean;\r\n\r\n /** Indicates that SSAO2 is supported */\r\n supportSSAO2: boolean;\r\n\r\n /** Indicates that some additional texture formats are supported (like TEXTUREFORMAT_R for eg) */\r\n supportExtendedTextureFormats: boolean;\r\n\r\n /** Indicates that the switch/case construct is supported in shaders */\r\n supportSwitchCaseInShader: boolean;\r\n\r\n /** Indicates that synchronous texture reading is supported */\r\n supportSyncTextureRead: boolean;\r\n\r\n /** Indicates that y should be inverted when dealing with bitmaps (notably in environment tools) */\r\n needsInvertingBitmap: boolean;\r\n\r\n /** Indicates that the engine should cache the bound UBO */\r\n useUBOBindingCache: boolean;\r\n\r\n /** Indicates that the inliner should be run over every shader code */\r\n needShaderCodeInlining: boolean;\r\n\r\n /** Indicates that even if we don't have to update the properties of a uniform buffer (because of some optimzations in the material) we still need to bind the uniform buffer themselves */\r\n needToAlwaysBindUniformBuffers: boolean;\r\n\r\n /** Indicates that the engine supports render passes */\r\n supportRenderPasses: boolean;\r\n\r\n /** @hidden */\r\n _collectUbosUpdatedInFrame: boolean;\r\n}\r\n"]}
|
|
1
|
+
{"version":3,"file":"engineFeatures.js","sourceRoot":"","sources":["../../../../../lts/core/generated/Engines/engineFeatures.ts"],"names":[],"mappings":"","sourcesContent":["/** @hidden */\r\nexport interface EngineFeatures {\r\n /** Force using Bitmap when Bitmap or HTMLImageElement can be used */\r\n forceBitmapOverHTMLImageElement: boolean;\r\n\r\n /** Indicates that the engine support rendering to as well as copying to lod float textures */\r\n supportRenderAndCopyToLodForFloatTextures: boolean;\r\n\r\n /** Indicates that the engine support handling depth/stencil textures */\r\n supportDepthStencilTexture: boolean;\r\n\r\n /** Indicates that the engine support shadow samplers */\r\n supportShadowSamplers: boolean;\r\n\r\n /** Indicates to check the matrix bytes per bytes to know if it has changed or not. If false, only the updateFlag of the matrix is checked */\r\n uniformBufferHardCheckMatrix: boolean;\r\n\r\n /** Indicates that prefiltered mipmaps can be generated in some processes (for eg when loading an HDR cube texture) */\r\n allowTexturePrefiltering: boolean;\r\n\r\n /** Indicates to track the usage of ubos and to create new ones as necessary during a frame duration */\r\n trackUbosInFrame: boolean;\r\n\r\n /** Indicates that the current content of a ubo should be compared to the content of the corresponding GPU buffer and the GPU buffer updated only if different. Requires trackUbosInFrame to be true */\r\n checkUbosContentBeforeUpload: boolean;\r\n\r\n /** Indicates that the Cascaded Shadow Map technic is supported */\r\n supportCSM: boolean;\r\n\r\n /** Indicates that the textures transcoded by the basis transcoder must have power of 2 width and height */\r\n basisNeedsPOT: boolean;\r\n\r\n /** Indicates that the engine supports 3D textures */\r\n support3DTextures: boolean;\r\n\r\n /** Indicates that constants need a type suffix in shaders (used by realtime filtering...) */\r\n needTypeSuffixInShaderConstants: boolean;\r\n\r\n /** Indicates that MSAA is supported */\r\n supportMSAA: boolean;\r\n\r\n /** Indicates that SSAO2 is supported */\r\n supportSSAO2: boolean;\r\n\r\n /** Indicates that some additional texture formats are supported (like TEXTUREFORMAT_R for eg) */\r\n supportExtendedTextureFormats: boolean;\r\n\r\n /** Indicates that the switch/case construct is supported in shaders */\r\n supportSwitchCaseInShader: boolean;\r\n\r\n /** Indicates that synchronous texture reading is supported */\r\n supportSyncTextureRead: boolean;\r\n\r\n /** Indicates that y should be inverted when dealing with bitmaps (notably in environment tools) */\r\n needsInvertingBitmap: boolean;\r\n\r\n /** Indicates that the engine should cache the bound UBO */\r\n useUBOBindingCache: boolean;\r\n\r\n /** Indicates that the inliner should be run over every shader code */\r\n needShaderCodeInlining: boolean;\r\n\r\n /** Indicates that even if we don't have to update the properties of a uniform buffer (because of some optimzations in the material) we still need to bind the uniform buffer themselves */\r\n needToAlwaysBindUniformBuffers: boolean;\r\n\r\n /** Indicates that the engine supports render passes */\r\n supportRenderPasses: boolean;\r\n\r\n /** Indicates that the engine supports sprite instancing */\r\n supportSpriteInstancing: boolean;\r\n\r\n /** @hidden */\r\n _collectUbosUpdatedInFrame: boolean;\r\n}\r\n"]}
|
|
@@ -99,13 +99,17 @@ export declare class NativeEngine extends Engine {
|
|
|
99
99
|
createVertexBuffer(vertices: DataArray, updateable?: boolean): NativeDataBuffer;
|
|
100
100
|
protected _recordVertexArrayObject(vertexArray: any, vertexBuffers: {
|
|
101
101
|
[key: string]: VertexBuffer;
|
|
102
|
-
}, indexBuffer: Nullable<NativeDataBuffer>, effect: Effect
|
|
102
|
+
}, indexBuffer: Nullable<NativeDataBuffer>, effect: Effect, overrideVertexBuffers?: {
|
|
103
|
+
[kind: string]: Nullable<VertexBuffer>;
|
|
104
|
+
}): void;
|
|
103
105
|
bindBuffers(vertexBuffers: {
|
|
104
106
|
[key: string]: VertexBuffer;
|
|
105
107
|
}, indexBuffer: Nullable<NativeDataBuffer>, effect: Effect): void;
|
|
106
108
|
recordVertexArrayObject(vertexBuffers: {
|
|
107
109
|
[key: string]: VertexBuffer;
|
|
108
|
-
}, indexBuffer: Nullable<NativeDataBuffer>, effect: Effect
|
|
110
|
+
}, indexBuffer: Nullable<NativeDataBuffer>, effect: Effect, overrideVertexBuffers?: {
|
|
111
|
+
[kind: string]: Nullable<VertexBuffer>;
|
|
112
|
+
}): WebGLVertexArrayObject;
|
|
109
113
|
private _deleteVertexArray;
|
|
110
114
|
bindVertexArrayObject(vertexArray: WebGLVertexArrayObject): void;
|
|
111
115
|
releaseVertexArrayObject(vertexArray: WebGLVertexArrayObject): void;
|
package/Engines/nativeEngine.js
CHANGED
|
@@ -750,7 +750,7 @@ var NativeEngine = /** @class */ (function (_super) {
|
|
|
750
750
|
drawBuffersExtension: false,
|
|
751
751
|
depthTextureExtension: false,
|
|
752
752
|
vertexArrayObject: true,
|
|
753
|
-
instancedArrays:
|
|
753
|
+
instancedArrays: true,
|
|
754
754
|
supportOcclusionQuery: false,
|
|
755
755
|
canUseTimestampForTimerQuery: false,
|
|
756
756
|
blendMinMax: false,
|
|
@@ -786,6 +786,7 @@ var NativeEngine = /** @class */ (function (_super) {
|
|
|
786
786
|
needShaderCodeInlining: true,
|
|
787
787
|
needToAlwaysBindUniformBuffers: false,
|
|
788
788
|
supportRenderPasses: true,
|
|
789
|
+
supportSpriteInstancing: false,
|
|
789
790
|
_collectUbosUpdatedInFrame: false,
|
|
790
791
|
};
|
|
791
792
|
Tools.Log("Babylon Native (v" + Engine.Version + ") launched");
|
|
@@ -933,7 +934,7 @@ var NativeEngine = /** @class */ (function (_super) {
|
|
|
933
934
|
}
|
|
934
935
|
return buffer;
|
|
935
936
|
};
|
|
936
|
-
NativeEngine.prototype._recordVertexArrayObject = function (vertexArray, vertexBuffers, indexBuffer, effect) {
|
|
937
|
+
NativeEngine.prototype._recordVertexArrayObject = function (vertexArray, vertexBuffers, indexBuffer, effect, overrideVertexBuffers) {
|
|
937
938
|
if (indexBuffer) {
|
|
938
939
|
this._engine.recordIndexBuffer(vertexArray, indexBuffer.nativeIndexBuffer);
|
|
939
940
|
}
|
|
@@ -942,10 +943,16 @@ var NativeEngine = /** @class */ (function (_super) {
|
|
|
942
943
|
var location_1 = effect.getAttributeLocation(index);
|
|
943
944
|
if (location_1 >= 0) {
|
|
944
945
|
var kind = attributes[index];
|
|
945
|
-
var vertexBuffer =
|
|
946
|
+
var vertexBuffer = null;
|
|
947
|
+
if (overrideVertexBuffers) {
|
|
948
|
+
vertexBuffer = overrideVertexBuffers[kind];
|
|
949
|
+
}
|
|
950
|
+
if (!vertexBuffer) {
|
|
951
|
+
vertexBuffer = vertexBuffers[kind];
|
|
952
|
+
}
|
|
946
953
|
if (vertexBuffer) {
|
|
947
954
|
var buffer = vertexBuffer.getBuffer();
|
|
948
|
-
if (buffer) {
|
|
955
|
+
if (buffer && buffer.nativeVertexBuffer) {
|
|
949
956
|
this._engine.recordVertexBuffer(vertexArray, buffer.nativeVertexBuffer, location_1, vertexBuffer.byteOffset, vertexBuffer.byteStride, vertexBuffer.getSize(), this._getNativeAttribType(vertexBuffer.type), vertexBuffer.normalized, vertexBuffer.getInstanceDivisor());
|
|
950
957
|
}
|
|
951
958
|
}
|
|
@@ -960,9 +967,9 @@ var NativeEngine = /** @class */ (function (_super) {
|
|
|
960
967
|
this._recordVertexArrayObject(this._boundBuffersVertexArray, vertexBuffers, indexBuffer, effect);
|
|
961
968
|
this.bindVertexArrayObject(this._boundBuffersVertexArray);
|
|
962
969
|
};
|
|
963
|
-
NativeEngine.prototype.recordVertexArrayObject = function (vertexBuffers, indexBuffer, effect) {
|
|
970
|
+
NativeEngine.prototype.recordVertexArrayObject = function (vertexBuffers, indexBuffer, effect, overrideVertexBuffers) {
|
|
964
971
|
var vertexArray = this._engine.createVertexArray();
|
|
965
|
-
this._recordVertexArrayObject(vertexArray, vertexBuffers, indexBuffer, effect);
|
|
972
|
+
this._recordVertexArrayObject(vertexArray, vertexBuffers, indexBuffer, effect, overrideVertexBuffers);
|
|
966
973
|
return vertexArray;
|
|
967
974
|
};
|
|
968
975
|
NativeEngine.prototype._deleteVertexArray = function (vertexArray) {
|