@babylonjs/core 5.11.0 → 5.12.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 (55) hide show
  1. package/Engines/Extensions/engine.query.js +1 -1
  2. package/Engines/Extensions/engine.query.js.map +1 -1
  3. package/Engines/ICanvas.d.ts +5 -0
  4. package/Engines/ICanvas.js.map +1 -1
  5. package/Engines/WebGPU/webgpuConstants.d.ts +1 -1
  6. package/Engines/WebGPU/webgpuConstants.js +5 -5
  7. package/Engines/WebGPU/webgpuConstants.js.map +1 -1
  8. package/Engines/engine.d.ts +2 -2
  9. package/Engines/thinEngine.js +2 -2
  10. package/Engines/thinEngine.js.map +1 -1
  11. package/Engines/webgpuEngine.js +1 -1
  12. package/Engines/webgpuEngine.js.map +1 -1
  13. package/Materials/Background/backgroundMaterial.js +2 -1
  14. package/Materials/Background/backgroundMaterial.js.map +1 -1
  15. package/Materials/Node/nodeMaterial.js +2 -1
  16. package/Materials/Node/nodeMaterial.js.map +1 -1
  17. package/Materials/PBR/pbrBaseMaterial.js +3 -1
  18. package/Materials/PBR/pbrBaseMaterial.js.map +1 -1
  19. package/Materials/effect.d.ts +5 -0
  20. package/Materials/effect.js +5 -0
  21. package/Materials/effect.js.map +1 -1
  22. package/Materials/material.js +1 -0
  23. package/Materials/material.js.map +1 -1
  24. package/Materials/materialPluginBase.d.ts +3 -1
  25. package/Materials/materialPluginBase.js +3 -1
  26. package/Materials/materialPluginBase.js.map +1 -1
  27. package/Materials/materialPluginEvent.d.ts +1 -0
  28. package/Materials/materialPluginEvent.js.map +1 -1
  29. package/Materials/materialPluginManager.js +1 -1
  30. package/Materials/materialPluginManager.js.map +1 -1
  31. package/Materials/shaderMaterial.d.ts +17 -2
  32. package/Materials/shaderMaterial.js +65 -4
  33. package/Materials/shaderMaterial.js.map +1 -1
  34. package/Materials/standardMaterial.js +3 -1
  35. package/Materials/standardMaterial.js.map +1 -1
  36. package/Maths/math.vector.d.ts +7 -0
  37. package/Maths/math.vector.js +43 -11
  38. package/Maths/math.vector.js.map +1 -1
  39. package/Meshes/Builders/shapeBuilder.d.ts +12 -0
  40. package/Meshes/Builders/shapeBuilder.js +48 -10
  41. package/Meshes/Builders/shapeBuilder.js.map +1 -1
  42. package/Meshes/mesh.js +1 -1
  43. package/Meshes/mesh.js.map +1 -1
  44. package/Misc/iInspectable.d.ts +1 -1
  45. package/Misc/iInspectable.js.map +1 -1
  46. package/Misc/screenshotTools.js +31 -14
  47. package/Misc/screenshotTools.js.map +1 -1
  48. package/Misc/tools.d.ts +16 -0
  49. package/Misc/tools.js +44 -30
  50. package/Misc/tools.js.map +1 -1
  51. package/XR/webXRCamera.js +11 -0
  52. package/XR/webXRCamera.js.map +1 -1
  53. package/XR/webXRExperienceHelper.js +2 -1
  54. package/XR/webXRExperienceHelper.js.map +1 -1
  55. package/package.json +2 -2
@@ -127,6 +127,7 @@ Engine.prototype.endTimeQuery = function (token) {
127
127
  }
128
128
  else {
129
129
  this._gl.endQuery(timerQuery.TIME_ELAPSED_EXT);
130
+ this._currentNonTimestampToken = null;
130
131
  }
131
132
  token._timeElapsedQueryEnded = true;
132
133
  }
@@ -160,7 +161,6 @@ Engine.prototype.endTimeQuery = function (token) {
160
161
  this._deleteTimeQuery(token._timeElapsedQuery);
161
162
  token._timeElapsedQuery = null;
162
163
  token._timeElapsedQueryEnded = false;
163
- this._currentNonTimestampToken = null;
164
164
  }
165
165
  return result;
166
166
  }
@@ -1 +1 @@
1
- {"version":3,"file":"engine.query.js","sourceRoot":"","sources":["../../../../../../lts/core/generated/Engines/Extensions/engine.query.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,MAAM,EAAE,MAAM,sBAAsB,CAAC;AAC9C,OAAO,EAAE,YAAY,EAAE,MAAM,2BAA2B,CAAC;AACzD,OAAO,EAAE,UAAU,EAAE,MAAM,iCAAiC,CAAC;AAC7D,OAAO,EAAE,WAAW,EAAE,MAAM,wBAAwB,CAAC;AAMrD,cAAc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AI,WAAW,CAAC,6BAA6B,GAAG,WAAW,CAAC,mBAAmB,EAAE;gBACvH,WAAW,CAAC,0BAA0B,GAAG,KAAK,CAAC;gBAC/C,WAAW,CAAC,6BAA6B,GAAG,CAAC,CAAC;gBAE9C,oHAAoH;gBACpH,mDAAmD;gBACnD,WAAW,CAAC,UAAU,GAAG,WAAW,CAAC,aAAa,KAAK,YAAY,CAAC,yBAAyB,CAAC,CAAC,CAAC,KAAK,CAAC,CAAC,CAAC,WAAW,CAAC,UAAU,CAAC;aAClI;iBAAM;gBACH,OAAO,WAAW,CAAC,aAAa,KAAK,YAAY,CAAC,yBAAyB,CAAC,CAAC,CAAC,KAAK,CAAC,CAAC,CAAC,WAAW,CAAC,UAAU,CAAC;aAChH;SACJ;KACJ;IAED,IAAM,KAAK,GAAG,IAAI,CAAC,QAAQ,EAAE,CAAC;IAC9B,IAAI,KAAK,CAAC,sBAAsB,EAAE;QAC9B,IAAM,4BAA4B,GAAG,KAAK,CAAC,sBAAsB,EAAE,CAAC;QAEpE,IAAI,IAAI,CAAC,eAAe,KAAK,IAAI,EAAE;YAC/B,IAAI,CAAC,eAAe,GAAG,MAAM,CAAC,WAAW,EAAE,CAAC;SAC/C;QAED,IAAI,MAAM,CAAC,mBAAmB,CAAC,WAAW,CAAC,2BAA2B,EAAE,IAAI,CAAC,eAAe,CAAC,EAAE;YAC3F,4BAA4B,CAAC,0BAA0B,CAAC,IAAI,CAAC,CAAC;YAC9D,MAAM,CAAC,iBAAiB,CAAC,WAAW,CAAC,2BAA2B,CAAC,CAAC;YAClE,IAAI,CAAC,qBAAqB,CAAC,0BAA0B,GAAG,IAAI,CAAC;SAChE;KACJ;IAED,OAAO,WAAW,CAAC,UAAU,CAAC;AAClC,CAAC,CAAC","sourcesContent":["import type { Nullable, int } from \"../../types\";\r\nimport { Engine } from \"../../Engines/engine\";\r\nimport { AbstractMesh } from \"../../Meshes/abstractMesh\";\r\nimport { _TimeToken } from \"../../Instrumentation/timeToken\";\r\nimport { PerfCounter } from \"../../Misc/perfCounter\";\r\nimport type { Observer } from \"../../Misc/observable\";\r\n\r\n/** @hidden */\r\nexport type OcclusionQuery = WebGLQuery | number;\r\n\r\n/** @hidden */\r\n// eslint-disable-next-line @typescript-eslint/naming-convention\r\nexport class _OcclusionDataStorage {\r\n /** @hidden */\r\n public occlusionInternalRetryCounter = 0;\r\n\r\n /** @hidden */\r\n public isOcclusionQueryInProgress = false;\r\n\r\n /** @hidden */\r\n public isOccluded = false;\r\n\r\n /** @hidden */\r\n public occlusionRetryCount = -1;\r\n\r\n /** @hidden */\r\n public occlusionType = AbstractMesh.OCCLUSION_TYPE_NONE;\r\n\r\n /** @hidden */\r\n public occlusionQueryAlgorithmType = AbstractMesh.OCCLUSION_ALGORITHM_TYPE_CONSERVATIVE;\r\n\r\n /** @hidden */\r\n public forceRenderingWhenOccluded = false;\r\n}\r\n\r\ndeclare module \"../../Engines/engine\" {\r\n export interface Engine {\r\n /**\r\n * Create a new webGL query (you must be sure that queries are supported by checking getCaps() function)\r\n * @return the new query\r\n */\r\n createQuery(): OcclusionQuery;\r\n\r\n /**\r\n * Delete and release a webGL query\r\n * @param query defines the query to delete\r\n * @return the current engine\r\n */\r\n deleteQuery(query: OcclusionQuery): Engine;\r\n\r\n /**\r\n * Check if a given query has resolved and got its value\r\n * @param query defines the query to check\r\n * @returns true if the query got its value\r\n */\r\n isQueryResultAvailable(query: OcclusionQuery): boolean;\r\n\r\n /**\r\n * Gets the value of a given query\r\n * @param query defines the query to check\r\n * @returns the value of the query\r\n */\r\n getQueryResult(query: OcclusionQuery): number;\r\n\r\n /**\r\n * Initiates an occlusion query\r\n * @param algorithmType defines the algorithm to use\r\n * @param query defines the query to use\r\n * @returns the current engine\r\n * @see https://doc.babylonjs.com/features/occlusionquery\r\n */\r\n beginOcclusionQuery(algorithmType: number, query: OcclusionQuery): boolean;\r\n\r\n /**\r\n * Ends an occlusion query\r\n * @see https://doc.babylonjs.com/features/occlusionquery\r\n * @param algorithmType defines the algorithm to use\r\n * @returns the current engine\r\n */\r\n endOcclusionQuery(algorithmType: number): Engine;\r\n\r\n /**\r\n * Starts a time query (used to measure time spent by the GPU on a specific frame)\r\n * Please note that only one query can be issued at a time\r\n * @returns a time token used to track the time span\r\n */\r\n startTimeQuery(): Nullable<_TimeToken>;\r\n\r\n /**\r\n * Ends a time query\r\n * @param token defines the token used to measure the time span\r\n * @returns the time spent (in ns)\r\n */\r\n endTimeQuery(token: _TimeToken): int;\r\n\r\n /**\r\n * Get the performance counter associated with the frame time computation\r\n * @returns the perf counter\r\n */\r\n getGPUFrameTimeCounter(): PerfCounter;\r\n\r\n /**\r\n * Enable or disable the GPU frame time capture\r\n * @param value True to enable, false to disable\r\n */\r\n captureGPUFrameTime(value: boolean): void;\r\n\r\n /** @hidden */\r\n _currentNonTimestampToken: Nullable<_TimeToken>;\r\n /** @hidden */\r\n _captureGPUFrameTime: boolean;\r\n /** @hidden */\r\n _gpuFrameTimeToken: Nullable<_TimeToken>;\r\n /** @hidden */\r\n _gpuFrameTime: PerfCounter;\r\n /** @hidden */\r\n _onBeginFrameObserver: Nullable<Observer<Engine>>;\r\n /** @hidden */\r\n _onEndFrameObserver: Nullable<Observer<Engine>>;\r\n\r\n /** @hidden */\r\n _createTimeQuery(): WebGLQuery;\r\n\r\n /** @hidden */\r\n _deleteTimeQuery(query: WebGLQuery): void;\r\n\r\n /** @hidden */\r\n _getGlAlgorithmType(algorithmType: number): number;\r\n\r\n /** @hidden */\r\n _getTimeQueryResult(query: WebGLQuery): any;\r\n\r\n /** @hidden */\r\n _getTimeQueryAvailability(query: WebGLQuery): any;\r\n }\r\n}\r\n\r\nEngine.prototype.createQuery = function (): OcclusionQuery {\r\n return this._gl.createQuery();\r\n};\r\n\r\nEngine.prototype.deleteQuery = function (query: OcclusionQuery): Engine {\r\n this._gl.deleteQuery(query);\r\n\r\n return this;\r\n};\r\n\r\nEngine.prototype.isQueryResultAvailable = function (query: OcclusionQuery): boolean {\r\n return this._gl.getQueryParameter(query, this._gl.QUERY_RESULT_AVAILABLE) as boolean;\r\n};\r\n\r\nEngine.prototype.getQueryResult = function (query: OcclusionQuery): number {\r\n return this._gl.getQueryParameter(query, this._gl.QUERY_RESULT) as number;\r\n};\r\n\r\nEngine.prototype.beginOcclusionQuery = function (algorithmType: number, query: OcclusionQuery): boolean {\r\n const glAlgorithm = this._getGlAlgorithmType(algorithmType);\r\n this._gl.beginQuery(glAlgorithm, query);\r\n\r\n return true;\r\n};\r\n\r\nEngine.prototype.endOcclusionQuery = function (algorithmType: number): Engine {\r\n const glAlgorithm = this._getGlAlgorithmType(algorithmType);\r\n this._gl.endQuery(glAlgorithm);\r\n\r\n return this;\r\n};\r\n\r\nEngine.prototype._createTimeQuery = function (): WebGLQuery {\r\n const timerQuery = <EXT_disjoint_timer_query>this.getCaps().timerQuery;\r\n\r\n if (timerQuery.createQueryEXT) {\r\n return timerQuery.createQueryEXT();\r\n }\r\n\r\n return this.createQuery();\r\n};\r\n\r\nEngine.prototype._deleteTimeQuery = function (query: WebGLQuery): void {\r\n const timerQuery = <EXT_disjoint_timer_query>this.getCaps().timerQuery;\r\n\r\n if (timerQuery.deleteQueryEXT) {\r\n timerQuery.deleteQueryEXT(query);\r\n return;\r\n }\r\n\r\n this.deleteQuery(query);\r\n};\r\n\r\nEngine.prototype._getTimeQueryResult = function (query: WebGLQuery): any {\r\n const timerQuery = <EXT_disjoint_timer_query>this.getCaps().timerQuery;\r\n\r\n if (timerQuery.getQueryObjectEXT) {\r\n return timerQuery.getQueryObjectEXT(query, timerQuery.QUERY_RESULT_EXT);\r\n }\r\n return this.getQueryResult(query);\r\n};\r\n\r\nEngine.prototype._getTimeQueryAvailability = function (query: WebGLQuery): any {\r\n const timerQuery = <EXT_disjoint_timer_query>this.getCaps().timerQuery;\r\n\r\n if (timerQuery.getQueryObjectEXT) {\r\n return timerQuery.getQueryObjectEXT(query, timerQuery.QUERY_RESULT_AVAILABLE_EXT);\r\n }\r\n return this.isQueryResultAvailable(query);\r\n};\r\n\r\nEngine.prototype.startTimeQuery = function (): Nullable<_TimeToken> {\r\n const caps = this.getCaps();\r\n const timerQuery = caps.timerQuery;\r\n if (!timerQuery) {\r\n return null;\r\n }\r\n\r\n const token = new _TimeToken();\r\n this._gl.getParameter(timerQuery.GPU_DISJOINT_EXT);\r\n if (caps.canUseTimestampForTimerQuery) {\r\n token._startTimeQuery = this._createTimeQuery();\r\n\r\n timerQuery.queryCounterEXT(token._startTimeQuery, timerQuery.TIMESTAMP_EXT);\r\n } else {\r\n if (this._currentNonTimestampToken) {\r\n return this._currentNonTimestampToken;\r\n }\r\n\r\n token._timeElapsedQuery = this._createTimeQuery();\r\n if (timerQuery.beginQueryEXT) {\r\n timerQuery.beginQueryEXT(timerQuery.TIME_ELAPSED_EXT, token._timeElapsedQuery);\r\n } else {\r\n this._gl.beginQuery(timerQuery.TIME_ELAPSED_EXT, token._timeElapsedQuery);\r\n }\r\n\r\n this._currentNonTimestampToken = token;\r\n }\r\n return token;\r\n};\r\n\r\nEngine.prototype.endTimeQuery = function (token: _TimeToken): int {\r\n const caps = this.getCaps();\r\n const timerQuery = caps.timerQuery;\r\n if (!timerQuery || !token) {\r\n return -1;\r\n }\r\n\r\n if (caps.canUseTimestampForTimerQuery) {\r\n if (!token._startTimeQuery) {\r\n return -1;\r\n }\r\n if (!token._endTimeQuery) {\r\n token._endTimeQuery = this._createTimeQuery();\r\n timerQuery.queryCounterEXT(token._endTimeQuery, timerQuery.TIMESTAMP_EXT);\r\n }\r\n } else if (!token._timeElapsedQueryEnded) {\r\n if (!token._timeElapsedQuery) {\r\n return -1;\r\n }\r\n if (timerQuery.endQueryEXT) {\r\n timerQuery.endQueryEXT(timerQuery.TIME_ELAPSED_EXT);\r\n } else {\r\n this._gl.endQuery(timerQuery.TIME_ELAPSED_EXT);\r\n }\r\n token._timeElapsedQueryEnded = true;\r\n }\r\n\r\n const disjoint = this._gl.getParameter(timerQuery.GPU_DISJOINT_EXT);\r\n let available: boolean = false;\r\n if (token._endTimeQuery) {\r\n available = this._getTimeQueryAvailability(token._endTimeQuery);\r\n } else if (token._timeElapsedQuery) {\r\n available = this._getTimeQueryAvailability(token._timeElapsedQuery);\r\n }\r\n\r\n if (available && !disjoint) {\r\n let result = 0;\r\n if (caps.canUseTimestampForTimerQuery) {\r\n if (!token._startTimeQuery || !token._endTimeQuery) {\r\n return -1;\r\n }\r\n const timeStart = this._getTimeQueryResult(token._startTimeQuery);\r\n const timeEnd = this._getTimeQueryResult(token._endTimeQuery);\r\n\r\n result = timeEnd - timeStart;\r\n this._deleteTimeQuery(token._startTimeQuery);\r\n this._deleteTimeQuery(token._endTimeQuery);\r\n token._startTimeQuery = null;\r\n token._endTimeQuery = null;\r\n } else {\r\n if (!token._timeElapsedQuery) {\r\n return -1;\r\n }\r\n\r\n result = this._getTimeQueryResult(token._timeElapsedQuery);\r\n this._deleteTimeQuery(token._timeElapsedQuery);\r\n token._timeElapsedQuery = null;\r\n token._timeElapsedQueryEnded = false;\r\n this._currentNonTimestampToken = null;\r\n }\r\n return result;\r\n }\r\n\r\n return -1;\r\n};\r\n\r\nEngine.prototype._captureGPUFrameTime = false;\r\nEngine.prototype._gpuFrameTime = new PerfCounter();\r\n\r\nEngine.prototype.getGPUFrameTimeCounter = function () {\r\n return this._gpuFrameTime;\r\n};\r\n\r\nEngine.prototype.captureGPUFrameTime = function (value: boolean) {\r\n if (value === this._captureGPUFrameTime) {\r\n return;\r\n }\r\n\r\n this._captureGPUFrameTime = value;\r\n\r\n if (value) {\r\n this._onBeginFrameObserver = this.onBeginFrameObservable.add(() => {\r\n if (!this._gpuFrameTimeToken) {\r\n this._gpuFrameTimeToken = this.startTimeQuery();\r\n }\r\n });\r\n\r\n this._onEndFrameObserver = this.onEndFrameObservable.add(() => {\r\n if (!this._gpuFrameTimeToken) {\r\n return;\r\n }\r\n const time = this.endTimeQuery(this._gpuFrameTimeToken);\r\n\r\n if (time > -1) {\r\n this._gpuFrameTimeToken = null;\r\n this._gpuFrameTime.fetchNewFrame();\r\n this._gpuFrameTime.addCount(time, true);\r\n }\r\n });\r\n } else {\r\n this.onBeginFrameObservable.remove(this._onBeginFrameObserver);\r\n this._onBeginFrameObserver = null;\r\n this.onEndFrameObservable.remove(this._onEndFrameObserver);\r\n this._onEndFrameObserver = null;\r\n }\r\n};\r\n\r\nEngine.prototype._getGlAlgorithmType = function (algorithmType: number): number {\r\n return algorithmType === AbstractMesh.OCCLUSION_ALGORITHM_TYPE_CONSERVATIVE ? this._gl.ANY_SAMPLES_PASSED_CONSERVATIVE : this._gl.ANY_SAMPLES_PASSED;\r\n};\r\n\r\ndeclare module \"../../Meshes/abstractMesh\" {\r\n export interface AbstractMesh {\r\n /**\r\n * Backing filed\r\n * @hidden\r\n */\r\n // eslint-disable-next-line @typescript-eslint/naming-convention\r\n __occlusionDataStorage: _OcclusionDataStorage;\r\n\r\n /**\r\n * Access property\r\n * @hidden\r\n */\r\n _occlusionDataStorage: _OcclusionDataStorage;\r\n\r\n /**\r\n * This number indicates the number of allowed retries before stop the occlusion query, this is useful if the occlusion query is taking long time before to the query result is retrieved, the query result indicates if the object is visible within the scene or not and based on that Babylon.Js engine decides to show or hide the object.\r\n * The default value is -1 which means don't break the query and wait till the result\r\n * @see https://doc.babylonjs.com/features/occlusionquery\r\n */\r\n occlusionRetryCount: number;\r\n\r\n /**\r\n * This property is responsible for starting the occlusion query within the Mesh or not, this property is also used to determine what should happen when the occlusionRetryCount is reached. It has supports 3 values:\r\n * * OCCLUSION_TYPE_NONE (Default Value): this option means no occlusion query within the Mesh.\r\n * * OCCLUSION_TYPE_OPTIMISTIC: this option is means use occlusion query and if occlusionRetryCount is reached and the query is broken show the mesh.\r\n * * OCCLUSION_TYPE_STRICT: this option is means use occlusion query and if occlusionRetryCount is reached and the query is broken restore the last state of the mesh occlusion if the mesh was visible then show the mesh if was hidden then hide don't show.\r\n * @see https://doc.babylonjs.com/features/occlusionquery\r\n */\r\n occlusionType: number;\r\n\r\n /**\r\n * This property determines the type of occlusion query algorithm to run in WebGl, you can use:\r\n * * AbstractMesh.OCCLUSION_ALGORITHM_TYPE_ACCURATE which is mapped to GL_ANY_SAMPLES_PASSED.\r\n * * AbstractMesh.OCCLUSION_ALGORITHM_TYPE_CONSERVATIVE (Default Value) which is mapped to GL_ANY_SAMPLES_PASSED_CONSERVATIVE which is a false positive algorithm that is faster than GL_ANY_SAMPLES_PASSED but less accurate.\r\n * @see https://doc.babylonjs.com/features/occlusionquery\r\n */\r\n occlusionQueryAlgorithmType: number;\r\n\r\n /**\r\n * Gets or sets whether the mesh is occluded or not, it is used also to set the initial state of the mesh to be occluded or not\r\n * @see https://doc.babylonjs.com/features/occlusionquery\r\n */\r\n isOccluded: boolean;\r\n\r\n /**\r\n * Flag to check the progress status of the query\r\n * @see https://doc.babylonjs.com/features/occlusionquery\r\n */\r\n isOcclusionQueryInProgress: boolean;\r\n\r\n /**\r\n * Flag to force rendering the mesh even if occluded\r\n * @see https://doc.babylonjs.com/features/occlusionquery\r\n */\r\n forceRenderingWhenOccluded: boolean;\r\n }\r\n}\r\nObject.defineProperty(AbstractMesh.prototype, \"isOcclusionQueryInProgress\", {\r\n get: function (this: AbstractMesh) {\r\n return this._occlusionDataStorage.isOcclusionQueryInProgress;\r\n },\r\n set: function (this: AbstractMesh, value: boolean) {\r\n this._occlusionDataStorage.isOcclusionQueryInProgress = value;\r\n },\r\n enumerable: false,\r\n configurable: true,\r\n});\r\n\r\nObject.defineProperty(AbstractMesh.prototype, \"_occlusionDataStorage\", {\r\n get: function (this: AbstractMesh) {\r\n if (!this.__occlusionDataStorage) {\r\n this.__occlusionDataStorage = new _OcclusionDataStorage();\r\n }\r\n return this.__occlusionDataStorage;\r\n },\r\n enumerable: false,\r\n configurable: true,\r\n});\r\n\r\nObject.defineProperty(AbstractMesh.prototype, \"isOccluded\", {\r\n get: function (this: AbstractMesh) {\r\n return this._occlusionDataStorage.isOccluded;\r\n },\r\n set: function (this: AbstractMesh, value: boolean) {\r\n this._occlusionDataStorage.isOccluded = value;\r\n },\r\n enumerable: true,\r\n configurable: true,\r\n});\r\n\r\nObject.defineProperty(AbstractMesh.prototype, \"occlusionQueryAlgorithmType\", {\r\n get: function (this: AbstractMesh) {\r\n return this._occlusionDataStorage.occlusionQueryAlgorithmType;\r\n },\r\n set: function (this: AbstractMesh, value: number) {\r\n this._occlusionDataStorage.occlusionQueryAlgorithmType = value;\r\n },\r\n enumerable: true,\r\n configurable: true,\r\n});\r\n\r\nObject.defineProperty(AbstractMesh.prototype, \"occlusionType\", {\r\n get: function (this: AbstractMesh) {\r\n return this._occlusionDataStorage.occlusionType;\r\n },\r\n set: function (this: AbstractMesh, value: number) {\r\n this._occlusionDataStorage.occlusionType = value;\r\n },\r\n enumerable: true,\r\n configurable: true,\r\n});\r\n\r\nObject.defineProperty(AbstractMesh.prototype, \"occlusionRetryCount\", {\r\n get: function (this: AbstractMesh) {\r\n return this._occlusionDataStorage.occlusionRetryCount;\r\n },\r\n set: function (this: AbstractMesh, value: number) {\r\n this._occlusionDataStorage.occlusionRetryCount = value;\r\n },\r\n enumerable: true,\r\n configurable: true,\r\n});\r\n\r\nObject.defineProperty(AbstractMesh.prototype, \"forceRenderingWhenOccluded\", {\r\n get: function (this: AbstractMesh) {\r\n return this._occlusionDataStorage.forceRenderingWhenOccluded;\r\n },\r\n set: function (this: AbstractMesh, value: boolean) {\r\n this._occlusionDataStorage.forceRenderingWhenOccluded = value;\r\n },\r\n enumerable: true,\r\n configurable: true,\r\n});\r\n\r\n// We also need to update AbstractMesh as there is a portion of the code there\r\nAbstractMesh.prototype._checkOcclusionQuery = function () {\r\n const dataStorage = this._occlusionDataStorage;\r\n\r\n if (dataStorage.occlusionType === AbstractMesh.OCCLUSION_TYPE_NONE) {\r\n dataStorage.isOccluded = false;\r\n return false;\r\n }\r\n\r\n const engine = this.getEngine();\r\n\r\n if (!engine.getCaps().supportOcclusionQuery) {\r\n dataStorage.isOccluded = false;\r\n return false;\r\n }\r\n\r\n if (!engine.isQueryResultAvailable) {\r\n // Occlusion query where not referenced\r\n dataStorage.isOccluded = false;\r\n return false;\r\n }\r\n\r\n if (this.isOcclusionQueryInProgress && this._occlusionQuery) {\r\n const isOcclusionQueryAvailable = engine.isQueryResultAvailable(this._occlusionQuery);\r\n if (isOcclusionQueryAvailable) {\r\n const occlusionQueryResult = engine.getQueryResult(this._occlusionQuery);\r\n\r\n dataStorage.isOcclusionQueryInProgress = false;\r\n dataStorage.occlusionInternalRetryCounter = 0;\r\n dataStorage.isOccluded = occlusionQueryResult > 0 ? false : true;\r\n } else {\r\n dataStorage.occlusionInternalRetryCounter++;\r\n\r\n if (dataStorage.occlusionRetryCount !== -1 && dataStorage.occlusionInternalRetryCounter > dataStorage.occlusionRetryCount) {\r\n dataStorage.isOcclusionQueryInProgress = false;\r\n dataStorage.occlusionInternalRetryCounter = 0;\r\n\r\n // if optimistic set isOccluded to false regardless of the status of isOccluded. (Render in the current render loop)\r\n // if strict continue the last state of the object.\r\n dataStorage.isOccluded = dataStorage.occlusionType === AbstractMesh.OCCLUSION_TYPE_OPTIMISTIC ? false : dataStorage.isOccluded;\r\n } else {\r\n return dataStorage.occlusionType === AbstractMesh.OCCLUSION_TYPE_OPTIMISTIC ? false : dataStorage.isOccluded;\r\n }\r\n }\r\n }\r\n\r\n const scene = this.getScene();\r\n if (scene.getBoundingBoxRenderer) {\r\n const occlusionBoundingBoxRenderer = scene.getBoundingBoxRenderer();\r\n\r\n if (this._occlusionQuery === null) {\r\n this._occlusionQuery = engine.createQuery();\r\n }\r\n\r\n if (engine.beginOcclusionQuery(dataStorage.occlusionQueryAlgorithmType, this._occlusionQuery)) {\r\n occlusionBoundingBoxRenderer.renderOcclusionBoundingBox(this);\r\n engine.endOcclusionQuery(dataStorage.occlusionQueryAlgorithmType);\r\n this._occlusionDataStorage.isOcclusionQueryInProgress = true;\r\n }\r\n }\r\n\r\n return dataStorage.isOccluded;\r\n};\r\n"]}
1
+ {"version":3,"file":"engine.query.js","sourceRoot":"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CAAC;YAClE,IAAI,CAAC,qBAAqB,CAAC,0BAA0B,GAAG,IAAI,CAAC;SAChE;KACJ;IAED,OAAO,WAAW,CAAC,UAAU,CAAC;AAClC,CAAC,CAAC","sourcesContent":["import type { Nullable, int } from \"../../types\";\r\nimport { Engine } from \"../../Engines/engine\";\r\nimport { AbstractMesh } from \"../../Meshes/abstractMesh\";\r\nimport { _TimeToken } from \"../../Instrumentation/timeToken\";\r\nimport { PerfCounter } from \"../../Misc/perfCounter\";\r\nimport type { Observer } from \"../../Misc/observable\";\r\n\r\n/** @hidden */\r\nexport type OcclusionQuery = WebGLQuery | number;\r\n\r\n/** @hidden */\r\n// eslint-disable-next-line @typescript-eslint/naming-convention\r\nexport class _OcclusionDataStorage {\r\n /** @hidden */\r\n public occlusionInternalRetryCounter = 0;\r\n\r\n /** @hidden */\r\n public isOcclusionQueryInProgress = false;\r\n\r\n /** @hidden */\r\n public isOccluded = false;\r\n\r\n /** @hidden */\r\n public occlusionRetryCount = -1;\r\n\r\n /** @hidden */\r\n public occlusionType = AbstractMesh.OCCLUSION_TYPE_NONE;\r\n\r\n /** @hidden */\r\n public occlusionQueryAlgorithmType = AbstractMesh.OCCLUSION_ALGORITHM_TYPE_CONSERVATIVE;\r\n\r\n /** @hidden */\r\n public forceRenderingWhenOccluded = false;\r\n}\r\n\r\ndeclare module \"../../Engines/engine\" {\r\n export interface Engine {\r\n /**\r\n * Create a new webGL query (you must be sure that queries are supported by checking getCaps() function)\r\n * @return the new query\r\n */\r\n createQuery(): OcclusionQuery;\r\n\r\n /**\r\n * Delete and release a webGL query\r\n * @param query defines the query to delete\r\n * @return the current engine\r\n */\r\n deleteQuery(query: OcclusionQuery): Engine;\r\n\r\n /**\r\n * Check if a given query has resolved and got its value\r\n * @param query defines the query to check\r\n * @returns true if the query got its value\r\n */\r\n isQueryResultAvailable(query: OcclusionQuery): boolean;\r\n\r\n /**\r\n * Gets the value of a given query\r\n * @param query defines the query to check\r\n * @returns the value of the query\r\n */\r\n getQueryResult(query: OcclusionQuery): number;\r\n\r\n /**\r\n * Initiates an occlusion query\r\n * @param algorithmType defines the algorithm to use\r\n * @param query defines the query to use\r\n * @returns the current engine\r\n * @see https://doc.babylonjs.com/features/occlusionquery\r\n */\r\n beginOcclusionQuery(algorithmType: number, query: OcclusionQuery): boolean;\r\n\r\n /**\r\n * Ends an occlusion query\r\n * @see https://doc.babylonjs.com/features/occlusionquery\r\n * @param algorithmType defines the algorithm to use\r\n * @returns the current engine\r\n */\r\n endOcclusionQuery(algorithmType: number): Engine;\r\n\r\n /**\r\n * Starts a time query (used to measure time spent by the GPU on a specific frame)\r\n * Please note that only one query can be issued at a time\r\n * @returns a time token used to track the time span\r\n */\r\n startTimeQuery(): Nullable<_TimeToken>;\r\n\r\n /**\r\n * Ends a time query\r\n * @param token defines the token used to measure the time span\r\n * @returns the time spent (in ns)\r\n */\r\n endTimeQuery(token: _TimeToken): int;\r\n\r\n /**\r\n * Get the performance counter associated with the frame time computation\r\n * @returns the perf counter\r\n */\r\n getGPUFrameTimeCounter(): PerfCounter;\r\n\r\n /**\r\n * Enable or disable the GPU frame time capture\r\n * @param value True to enable, false to disable\r\n */\r\n captureGPUFrameTime(value: boolean): void;\r\n\r\n /** @hidden */\r\n _currentNonTimestampToken: Nullable<_TimeToken>;\r\n /** @hidden */\r\n _captureGPUFrameTime: boolean;\r\n /** @hidden */\r\n _gpuFrameTimeToken: Nullable<_TimeToken>;\r\n /** @hidden */\r\n _gpuFrameTime: PerfCounter;\r\n /** @hidden */\r\n _onBeginFrameObserver: Nullable<Observer<Engine>>;\r\n /** @hidden */\r\n _onEndFrameObserver: Nullable<Observer<Engine>>;\r\n\r\n /** @hidden */\r\n _createTimeQuery(): WebGLQuery;\r\n\r\n /** @hidden */\r\n _deleteTimeQuery(query: WebGLQuery): void;\r\n\r\n /** @hidden */\r\n _getGlAlgorithmType(algorithmType: number): number;\r\n\r\n /** @hidden */\r\n _getTimeQueryResult(query: WebGLQuery): any;\r\n\r\n /** @hidden */\r\n _getTimeQueryAvailability(query: WebGLQuery): any;\r\n }\r\n}\r\n\r\nEngine.prototype.createQuery = function (): OcclusionQuery {\r\n return this._gl.createQuery();\r\n};\r\n\r\nEngine.prototype.deleteQuery = function (query: OcclusionQuery): Engine {\r\n this._gl.deleteQuery(query);\r\n\r\n return this;\r\n};\r\n\r\nEngine.prototype.isQueryResultAvailable = function (query: OcclusionQuery): boolean {\r\n return this._gl.getQueryParameter(query, this._gl.QUERY_RESULT_AVAILABLE) as boolean;\r\n};\r\n\r\nEngine.prototype.getQueryResult = function (query: OcclusionQuery): number {\r\n return this._gl.getQueryParameter(query, this._gl.QUERY_RESULT) as number;\r\n};\r\n\r\nEngine.prototype.beginOcclusionQuery = function (algorithmType: number, query: OcclusionQuery): boolean {\r\n const glAlgorithm = this._getGlAlgorithmType(algorithmType);\r\n this._gl.beginQuery(glAlgorithm, query);\r\n\r\n return true;\r\n};\r\n\r\nEngine.prototype.endOcclusionQuery = function (algorithmType: number): Engine {\r\n const glAlgorithm = this._getGlAlgorithmType(algorithmType);\r\n this._gl.endQuery(glAlgorithm);\r\n\r\n return this;\r\n};\r\n\r\nEngine.prototype._createTimeQuery = function (): WebGLQuery {\r\n const timerQuery = <EXT_disjoint_timer_query>this.getCaps().timerQuery;\r\n\r\n if (timerQuery.createQueryEXT) {\r\n return timerQuery.createQueryEXT();\r\n }\r\n\r\n return this.createQuery();\r\n};\r\n\r\nEngine.prototype._deleteTimeQuery = function (query: WebGLQuery): void {\r\n const timerQuery = <EXT_disjoint_timer_query>this.getCaps().timerQuery;\r\n\r\n if (timerQuery.deleteQueryEXT) {\r\n timerQuery.deleteQueryEXT(query);\r\n return;\r\n }\r\n\r\n this.deleteQuery(query);\r\n};\r\n\r\nEngine.prototype._getTimeQueryResult = function (query: WebGLQuery): any {\r\n const timerQuery = <EXT_disjoint_timer_query>this.getCaps().timerQuery;\r\n\r\n if (timerQuery.getQueryObjectEXT) {\r\n return timerQuery.getQueryObjectEXT(query, timerQuery.QUERY_RESULT_EXT);\r\n }\r\n return this.getQueryResult(query);\r\n};\r\n\r\nEngine.prototype._getTimeQueryAvailability = function (query: WebGLQuery): any {\r\n const timerQuery = <EXT_disjoint_timer_query>this.getCaps().timerQuery;\r\n\r\n if (timerQuery.getQueryObjectEXT) {\r\n return timerQuery.getQueryObjectEXT(query, timerQuery.QUERY_RESULT_AVAILABLE_EXT);\r\n }\r\n return this.isQueryResultAvailable(query);\r\n};\r\n\r\nEngine.prototype.startTimeQuery = function (): Nullable<_TimeToken> {\r\n const caps = this.getCaps();\r\n const timerQuery = caps.timerQuery;\r\n if (!timerQuery) {\r\n return null;\r\n }\r\n\r\n const token = new _TimeToken();\r\n this._gl.getParameter(timerQuery.GPU_DISJOINT_EXT);\r\n if (caps.canUseTimestampForTimerQuery) {\r\n token._startTimeQuery = this._createTimeQuery();\r\n\r\n timerQuery.queryCounterEXT(token._startTimeQuery, timerQuery.TIMESTAMP_EXT);\r\n } else {\r\n if (this._currentNonTimestampToken) {\r\n return this._currentNonTimestampToken;\r\n }\r\n\r\n token._timeElapsedQuery = this._createTimeQuery();\r\n if (timerQuery.beginQueryEXT) {\r\n timerQuery.beginQueryEXT(timerQuery.TIME_ELAPSED_EXT, token._timeElapsedQuery);\r\n } else {\r\n this._gl.beginQuery(timerQuery.TIME_ELAPSED_EXT, token._timeElapsedQuery);\r\n }\r\n\r\n this._currentNonTimestampToken = token;\r\n }\r\n return token;\r\n};\r\n\r\nEngine.prototype.endTimeQuery = function (token: _TimeToken): int {\r\n const caps = this.getCaps();\r\n const timerQuery = caps.timerQuery;\r\n if (!timerQuery || !token) {\r\n return -1;\r\n }\r\n\r\n if (caps.canUseTimestampForTimerQuery) {\r\n if (!token._startTimeQuery) {\r\n return -1;\r\n }\r\n if (!token._endTimeQuery) {\r\n token._endTimeQuery = this._createTimeQuery();\r\n timerQuery.queryCounterEXT(token._endTimeQuery, timerQuery.TIMESTAMP_EXT);\r\n }\r\n } else if (!token._timeElapsedQueryEnded) {\r\n if (!token._timeElapsedQuery) {\r\n return -1;\r\n }\r\n if (timerQuery.endQueryEXT) {\r\n timerQuery.endQueryEXT(timerQuery.TIME_ELAPSED_EXT);\r\n } else {\r\n this._gl.endQuery(timerQuery.TIME_ELAPSED_EXT);\r\n this._currentNonTimestampToken = null;\r\n }\r\n token._timeElapsedQueryEnded = true;\r\n }\r\n\r\n const disjoint = this._gl.getParameter(timerQuery.GPU_DISJOINT_EXT);\r\n let available: boolean = false;\r\n if (token._endTimeQuery) {\r\n available = this._getTimeQueryAvailability(token._endTimeQuery);\r\n } else if (token._timeElapsedQuery) {\r\n available = this._getTimeQueryAvailability(token._timeElapsedQuery);\r\n }\r\n\r\n if (available && !disjoint) {\r\n let result = 0;\r\n if (caps.canUseTimestampForTimerQuery) {\r\n if (!token._startTimeQuery || !token._endTimeQuery) {\r\n return -1;\r\n }\r\n const timeStart = this._getTimeQueryResult(token._startTimeQuery);\r\n const timeEnd = this._getTimeQueryResult(token._endTimeQuery);\r\n\r\n result = timeEnd - timeStart;\r\n this._deleteTimeQuery(token._startTimeQuery);\r\n this._deleteTimeQuery(token._endTimeQuery);\r\n token._startTimeQuery = null;\r\n token._endTimeQuery = null;\r\n } else {\r\n if (!token._timeElapsedQuery) {\r\n return -1;\r\n }\r\n\r\n result = this._getTimeQueryResult(token._timeElapsedQuery);\r\n this._deleteTimeQuery(token._timeElapsedQuery);\r\n token._timeElapsedQuery = null;\r\n token._timeElapsedQueryEnded = false;\r\n }\r\n return result;\r\n }\r\n\r\n return -1;\r\n};\r\n\r\nEngine.prototype._captureGPUFrameTime = false;\r\nEngine.prototype._gpuFrameTime = new PerfCounter();\r\n\r\nEngine.prototype.getGPUFrameTimeCounter = function () {\r\n return this._gpuFrameTime;\r\n};\r\n\r\nEngine.prototype.captureGPUFrameTime = function (value: boolean) {\r\n if (value === this._captureGPUFrameTime) {\r\n return;\r\n }\r\n\r\n this._captureGPUFrameTime = value;\r\n\r\n if (value) {\r\n this._onBeginFrameObserver = this.onBeginFrameObservable.add(() => {\r\n if (!this._gpuFrameTimeToken) {\r\n this._gpuFrameTimeToken = this.startTimeQuery();\r\n }\r\n });\r\n\r\n this._onEndFrameObserver = this.onEndFrameObservable.add(() => {\r\n if (!this._gpuFrameTimeToken) {\r\n return;\r\n }\r\n const time = this.endTimeQuery(this._gpuFrameTimeToken);\r\n\r\n if (time > -1) {\r\n this._gpuFrameTimeToken = null;\r\n this._gpuFrameTime.fetchNewFrame();\r\n this._gpuFrameTime.addCount(time, true);\r\n }\r\n });\r\n } else {\r\n this.onBeginFrameObservable.remove(this._onBeginFrameObserver);\r\n this._onBeginFrameObserver = null;\r\n this.onEndFrameObservable.remove(this._onEndFrameObserver);\r\n this._onEndFrameObserver = null;\r\n }\r\n};\r\n\r\nEngine.prototype._getGlAlgorithmType = function (algorithmType: number): number {\r\n return algorithmType === AbstractMesh.OCCLUSION_ALGORITHM_TYPE_CONSERVATIVE ? this._gl.ANY_SAMPLES_PASSED_CONSERVATIVE : this._gl.ANY_SAMPLES_PASSED;\r\n};\r\n\r\ndeclare module \"../../Meshes/abstractMesh\" {\r\n export interface AbstractMesh {\r\n /**\r\n * Backing filed\r\n * @hidden\r\n */\r\n // eslint-disable-next-line @typescript-eslint/naming-convention\r\n __occlusionDataStorage: _OcclusionDataStorage;\r\n\r\n /**\r\n * Access property\r\n * @hidden\r\n */\r\n _occlusionDataStorage: _OcclusionDataStorage;\r\n\r\n /**\r\n * This number indicates the number of allowed retries before stop the occlusion query, this is useful if the occlusion query is taking long time before to the query result is retrieved, the query result indicates if the object is visible within the scene or not and based on that Babylon.Js engine decides to show or hide the object.\r\n * The default value is -1 which means don't break the query and wait till the result\r\n * @see https://doc.babylonjs.com/features/occlusionquery\r\n */\r\n occlusionRetryCount: number;\r\n\r\n /**\r\n * This property is responsible for starting the occlusion query within the Mesh or not, this property is also used to determine what should happen when the occlusionRetryCount is reached. It has supports 3 values:\r\n * * OCCLUSION_TYPE_NONE (Default Value): this option means no occlusion query within the Mesh.\r\n * * OCCLUSION_TYPE_OPTIMISTIC: this option is means use occlusion query and if occlusionRetryCount is reached and the query is broken show the mesh.\r\n * * OCCLUSION_TYPE_STRICT: this option is means use occlusion query and if occlusionRetryCount is reached and the query is broken restore the last state of the mesh occlusion if the mesh was visible then show the mesh if was hidden then hide don't show.\r\n * @see https://doc.babylonjs.com/features/occlusionquery\r\n */\r\n occlusionType: number;\r\n\r\n /**\r\n * This property determines the type of occlusion query algorithm to run in WebGl, you can use:\r\n * * AbstractMesh.OCCLUSION_ALGORITHM_TYPE_ACCURATE which is mapped to GL_ANY_SAMPLES_PASSED.\r\n * * AbstractMesh.OCCLUSION_ALGORITHM_TYPE_CONSERVATIVE (Default Value) which is mapped to GL_ANY_SAMPLES_PASSED_CONSERVATIVE which is a false positive algorithm that is faster than GL_ANY_SAMPLES_PASSED but less accurate.\r\n * @see https://doc.babylonjs.com/features/occlusionquery\r\n */\r\n occlusionQueryAlgorithmType: number;\r\n\r\n /**\r\n * Gets or sets whether the mesh is occluded or not, it is used also to set the initial state of the mesh to be occluded or not\r\n * @see https://doc.babylonjs.com/features/occlusionquery\r\n */\r\n isOccluded: boolean;\r\n\r\n /**\r\n * Flag to check the progress status of the query\r\n * @see https://doc.babylonjs.com/features/occlusionquery\r\n */\r\n isOcclusionQueryInProgress: boolean;\r\n\r\n /**\r\n * Flag to force rendering the mesh even if occluded\r\n * @see https://doc.babylonjs.com/features/occlusionquery\r\n */\r\n forceRenderingWhenOccluded: boolean;\r\n }\r\n}\r\nObject.defineProperty(AbstractMesh.prototype, \"isOcclusionQueryInProgress\", {\r\n get: function (this: AbstractMesh) {\r\n return this._occlusionDataStorage.isOcclusionQueryInProgress;\r\n },\r\n set: function (this: AbstractMesh, value: boolean) {\r\n this._occlusionDataStorage.isOcclusionQueryInProgress = value;\r\n },\r\n enumerable: false,\r\n configurable: true,\r\n});\r\n\r\nObject.defineProperty(AbstractMesh.prototype, \"_occlusionDataStorage\", {\r\n get: function (this: AbstractMesh) {\r\n if (!this.__occlusionDataStorage) {\r\n this.__occlusionDataStorage = new _OcclusionDataStorage();\r\n }\r\n return this.__occlusionDataStorage;\r\n },\r\n enumerable: false,\r\n configurable: true,\r\n});\r\n\r\nObject.defineProperty(AbstractMesh.prototype, \"isOccluded\", {\r\n get: function (this: AbstractMesh) {\r\n return this._occlusionDataStorage.isOccluded;\r\n },\r\n set: function (this: AbstractMesh, value: boolean) {\r\n this._occlusionDataStorage.isOccluded = value;\r\n },\r\n enumerable: true,\r\n configurable: true,\r\n});\r\n\r\nObject.defineProperty(AbstractMesh.prototype, \"occlusionQueryAlgorithmType\", {\r\n get: function (this: AbstractMesh) {\r\n return this._occlusionDataStorage.occlusionQueryAlgorithmType;\r\n },\r\n set: function (this: AbstractMesh, value: number) {\r\n this._occlusionDataStorage.occlusionQueryAlgorithmType = value;\r\n },\r\n enumerable: true,\r\n configurable: true,\r\n});\r\n\r\nObject.defineProperty(AbstractMesh.prototype, \"occlusionType\", {\r\n get: function (this: AbstractMesh) {\r\n return this._occlusionDataStorage.occlusionType;\r\n },\r\n set: function (this: AbstractMesh, value: number) {\r\n this._occlusionDataStorage.occlusionType = value;\r\n },\r\n enumerable: true,\r\n configurable: true,\r\n});\r\n\r\nObject.defineProperty(AbstractMesh.prototype, \"occlusionRetryCount\", {\r\n get: function (this: AbstractMesh) {\r\n return this._occlusionDataStorage.occlusionRetryCount;\r\n },\r\n set: function (this: AbstractMesh, value: number) {\r\n this._occlusionDataStorage.occlusionRetryCount = value;\r\n },\r\n enumerable: true,\r\n configurable: true,\r\n});\r\n\r\nObject.defineProperty(AbstractMesh.prototype, \"forceRenderingWhenOccluded\", {\r\n get: function (this: AbstractMesh) {\r\n return this._occlusionDataStorage.forceRenderingWhenOccluded;\r\n },\r\n set: function (this: AbstractMesh, value: boolean) {\r\n this._occlusionDataStorage.forceRenderingWhenOccluded = value;\r\n },\r\n enumerable: true,\r\n configurable: true,\r\n});\r\n\r\n// We also need to update AbstractMesh as there is a portion of the code there\r\nAbstractMesh.prototype._checkOcclusionQuery = function () {\r\n const dataStorage = this._occlusionDataStorage;\r\n\r\n if (dataStorage.occlusionType === AbstractMesh.OCCLUSION_TYPE_NONE) {\r\n dataStorage.isOccluded = false;\r\n return false;\r\n }\r\n\r\n const engine = this.getEngine();\r\n\r\n if (!engine.getCaps().supportOcclusionQuery) {\r\n dataStorage.isOccluded = false;\r\n return false;\r\n }\r\n\r\n if (!engine.isQueryResultAvailable) {\r\n // Occlusion query where not referenced\r\n dataStorage.isOccluded = false;\r\n return false;\r\n }\r\n\r\n if (this.isOcclusionQueryInProgress && this._occlusionQuery) {\r\n const isOcclusionQueryAvailable = engine.isQueryResultAvailable(this._occlusionQuery);\r\n if (isOcclusionQueryAvailable) {\r\n const occlusionQueryResult = engine.getQueryResult(this._occlusionQuery);\r\n\r\n dataStorage.isOcclusionQueryInProgress = false;\r\n dataStorage.occlusionInternalRetryCounter = 0;\r\n dataStorage.isOccluded = occlusionQueryResult > 0 ? false : true;\r\n } else {\r\n dataStorage.occlusionInternalRetryCounter++;\r\n\r\n if (dataStorage.occlusionRetryCount !== -1 && dataStorage.occlusionInternalRetryCounter > dataStorage.occlusionRetryCount) {\r\n dataStorage.isOcclusionQueryInProgress = false;\r\n dataStorage.occlusionInternalRetryCounter = 0;\r\n\r\n // if optimistic set isOccluded to false regardless of the status of isOccluded. (Render in the current render loop)\r\n // if strict continue the last state of the object.\r\n dataStorage.isOccluded = dataStorage.occlusionType === AbstractMesh.OCCLUSION_TYPE_OPTIMISTIC ? false : dataStorage.isOccluded;\r\n } else {\r\n return dataStorage.occlusionType === AbstractMesh.OCCLUSION_TYPE_OPTIMISTIC ? false : dataStorage.isOccluded;\r\n }\r\n }\r\n }\r\n\r\n const scene = this.getScene();\r\n if (scene.getBoundingBoxRenderer) {\r\n const occlusionBoundingBoxRenderer = scene.getBoundingBoxRenderer();\r\n\r\n if (this._occlusionQuery === null) {\r\n this._occlusionQuery = engine.createQuery();\r\n }\r\n\r\n if (engine.beginOcclusionQuery(dataStorage.occlusionQueryAlgorithmType, this._occlusionQuery)) {\r\n occlusionBoundingBoxRenderer.renderOcclusionBoundingBox(this);\r\n engine.endOcclusionQuery(dataStorage.occlusionQueryAlgorithmType);\r\n this._occlusionDataStorage.isOcclusionQueryInProgress = true;\r\n }\r\n }\r\n\r\n return dataStorage.isOccluded;\r\n};\r\n"]}
@@ -61,6 +61,11 @@ export interface IImage {
61
61
  * thereby enabling the configuration of the CORS requests for the element's fetched data.
62
62
  */
63
63
  crossOrigin: string | null;
64
+ /**
65
+ * provides support for referrer policy on xhr load request,
66
+ * it is used to control the request header.
67
+ */
68
+ referrerPolicy: string;
64
69
  }
65
70
  /**
66
71
  * Class used to abstract a canvas gradient
@@ -1 +1 @@
1
- {"version":3,"file":"ICanvas.js","sourceRoot":"","sources":["../../../../../lts/core/generated/Engines/ICanvas.ts"],"names":[],"mappings":"","sourcesContent":["/**\r\n * Class used to abstract a canvas\r\n */\r\nexport interface ICanvas {\r\n /**\r\n * Canvas width.\r\n */\r\n width: number;\r\n\r\n /**\r\n * Canvas height.\r\n */\r\n height: number;\r\n\r\n /**\r\n * returns a drawing context on the canvas.\r\n * @param contextType context identifier.\r\n * @param contextAttributes context attributes.\r\n * @returns ICanvasRenderingContext object.\r\n */\r\n getContext(contextType: string, contextAttributes?: any): ICanvasRenderingContext;\r\n\r\n /**\r\n * returns a data URI containing a representation of the image in the format specified by the type parameter.\r\n * @param mime the image format.\r\n * @returns string containing the requested data URI.\r\n */\r\n toDataURL(mime: string): string;\r\n}\r\n\r\n/**\r\n * Class used to abstract am image to use with the canvas and its context\r\n */\r\nexport interface IImage {\r\n /**\r\n * onload callback.\r\n */\r\n onload: ((this: GlobalEventHandlers, ev: Event) => any) | null;\r\n\r\n /**\r\n * Error callback.\r\n */\r\n onerror: ((this: GlobalEventHandlers, ev: Event) => any) | null;\r\n\r\n /**\r\n * Image source.\r\n */\r\n src: string;\r\n\r\n /**\r\n * Image width.\r\n */\r\n readonly width: number;\r\n\r\n /**\r\n * Image height.\r\n */\r\n readonly height: number;\r\n\r\n /**\r\n * The original height of the image resource before sizing.\r\n */\r\n readonly naturalHeight: number;\r\n\r\n /**\r\n * The original width of the image resource before sizing.\r\n */\r\n readonly naturalWidth: number;\r\n\r\n /**\r\n * provides support for CORS, defining how the element handles crossorigin requests,\r\n * thereby enabling the configuration of the CORS requests for the element's fetched data.\r\n */\r\n crossOrigin: string | null;\r\n}\r\n\r\n/**\r\n * Class used to abstract a canvas gradient\r\n */\r\nexport interface ICanvasGradient {\r\n /**\r\n * adds a new color stop, defined by an offset and a color, to a given canvas gradient.\r\n * @param offset A number between 0 and 1, inclusive, representing the position of the color stop. 0 represents the start of the gradient and 1 represents the end.\r\n * @param color value representing the color of the stop.\r\n */\r\n addColorStop(offset: number, color: string): void;\r\n}\r\n\r\n/**\r\n * Class used to abstract a text measurement\r\n */\r\nexport interface ITextMetrics {\r\n /**\r\n * Text width.\r\n */\r\n readonly width: number;\r\n /**\r\n * distance (in pixels) parallel to the baseline from the alignment point given by the CanvasRenderingContext2D.textAlign\r\n * property to the left side of the bounding rectangle of the given text\r\n */\r\n readonly actualBoundingBoxLeft: number;\r\n /**\r\n * distance (in pixels) parallel to the baseline from the alignment point given by the CanvasRenderingContext2D.textAlign\r\n * property to the right side of the bounding rectangle of the given text\r\n */\r\n readonly actualBoundingBoxRight: number;\r\n}\r\n\r\n/**\r\n * Class used to abstract canvas rendering\r\n */\r\nexport interface ICanvasRenderingContext {\r\n /**\r\n * Defines the type of corners where two lines meet. Possible values: round, bevel, miter (default).\r\n */\r\n lineJoin: string;\r\n\r\n /**\r\n * Miter limit ratio. Default 10.\r\n */\r\n miterLimit: number;\r\n\r\n /**\r\n * Font setting. Default value 10px sans-serif.\r\n */\r\n font: string;\r\n\r\n /**\r\n * Color or style to use for the lines around shapes. Default #000 (black).\r\n */\r\n strokeStyle: string;\r\n\r\n /**\r\n * Color or style to use inside shapes. Default #000 (black).\r\n */\r\n fillStyle: string | ICanvasGradient;\r\n\r\n /**\r\n * Alpha value that is applied to shapes and images before they are composited onto the canvas. Default 1.0 (opaque).\r\n */\r\n globalAlpha: number;\r\n\r\n /**\r\n * Color of the shadow. Default: fully-transparent black.\r\n */\r\n shadowColor: string;\r\n\r\n /**\r\n * Specifies the blurring effect. Default: 0.\r\n */\r\n shadowBlur: number;\r\n\r\n /**\r\n * Horizontal distance the shadow will be offset. Default: 0.\r\n */\r\n shadowOffsetX: number;\r\n\r\n /**\r\n * Vertical distance the shadow will be offset. Default: 0.\r\n */\r\n shadowOffsetY: number;\r\n\r\n /**\r\n * Width of lines. Default 1.0.\r\n */\r\n lineWidth: number;\r\n\r\n /**\r\n * canvas is a read-only reference to ICanvas.\r\n */\r\n readonly canvas: ICanvas;\r\n\r\n /**\r\n * Sets all pixels in the rectangle defined by starting point (x, y) and size (width, height) to transparent black, erasing any previously drawn content.\r\n * @param x The x-axis coordinate of the rectangle's starting point.\r\n * @param y The y-axis coordinate of the rectangle's starting point.\r\n * @param width The rectangle's width. Positive values are to the right, and negative to the left.\r\n * @param height The rectangle's height. Positive values are down, and negative are up.\r\n */\r\n clearRect(x: number, y: number, width: number, height: number): void;\r\n\r\n /**\r\n * Saves the current drawing style state using a stack so you can revert any change you make to it using restore().\r\n */\r\n save(): void;\r\n\r\n /**\r\n * Restores the drawing style state to the last element on the 'state stack' saved by save().\r\n */\r\n restore(): void;\r\n\r\n /**\r\n * Draws a filled rectangle at (x, y) position whose size is determined by width and height.\r\n * @param x The x-axis coordinate of the rectangle's starting point.\r\n * @param y The y-axis coordinate of the rectangle's starting point.\r\n * @param width The rectangle's width. Positive values are to the right, and negative to the left.\r\n * @param height The rectangle's height. Positive values are down, and negative are up.\r\n */\r\n fillRect(x: number, y: number, width: number, height: number): void;\r\n\r\n /**\r\n * Adds a scaling transformation to the canvas units by x horizontally and by y vertically.\r\n * @param x Scaling factor in the horizontal direction. A negative value flips pixels across the vertical axis. A value of 1 results in no horizontal scaling.\r\n * @param y Scaling factor in the vertical direction. A negative value flips pixels across the horizontal axis. A value of 1 results in no vertical scaling.\r\n */\r\n scale(x: number, y: number): void;\r\n\r\n /**\r\n * Adds a rotation to the transformation matrix. The angle argument represents a clockwise rotation angle and is expressed in radians.\r\n * @param angle The rotation angle, clockwise in radians. You can use degree * Math.PI / 180 to calculate a radian from a degree.\r\n */\r\n rotate(angle: number): void;\r\n\r\n /**\r\n * Adds a translation transformation by moving the canvas and its origin x horizontally and y vertically on the grid.\r\n * @param x Distance to move in the horizontal direction. Positive values are to the right, and negative to the left.\r\n * @param y Distance to move in the vertical direction. Positive values are down, and negative are up.\r\n */\r\n translate(x: number, y: number): void;\r\n\r\n /**\r\n * Paints a rectangle which has a starting point at (x, y) and has a w width and an h height onto the canvas, using the current stroke style.\r\n * @param x The x-axis coordinate of the rectangle's starting point.\r\n * @param y The y-axis coordinate of the rectangle's starting point.\r\n * @param width The rectangle's width. Positive values are to the right, and negative to the left.\r\n * @param height The rectangle's height. Positive values are down, and negative are up.\r\n */\r\n strokeRect(x: number, y: number, width: number, height: number): void;\r\n\r\n /**\r\n * Creates a path for a rectangle at position (x, y) with a size that is determined by width and height.\r\n * @param x The x-axis coordinate of the rectangle's starting point.\r\n * @param y The y-axis coordinate of the rectangle's starting point.\r\n * @param width The rectangle's width. Positive values are to the right, and negative to the left.\r\n * @param height The rectangle's height. Positive values are down, and negative are up.\r\n */\r\n rect(x: number, y: number, width: number, height: number): void;\r\n\r\n /**\r\n * Creates a clipping path from the current sub-paths. Everything drawn after clip() is called appears inside the clipping path only.\r\n */\r\n clip(): void;\r\n\r\n /**\r\n * Paints data from the given ImageData object onto the bitmap. If a dirty rectangle is provided, only the pixels from that rectangle are painted.\r\n * @param imageData An ImageData object containing the array of pixel values.\r\n * @param dx Horizontal position (x coordinate) at which to place the image data in the destination canvas.\r\n * @param dy Vertical position (y coordinate) at which to place the image data in the destination canvas.\r\n */\r\n putImageData(imageData: ImageData, dx: number, dy: number): void;\r\n\r\n /**\r\n * Adds a circular arc to the current path.\r\n * @param x The horizontal coordinate of the arc's center.\r\n * @param y The vertical coordinate of the arc's center.\r\n * @param radius The arc's radius. Must be positive.\r\n * @param startAngle The angle at which the arc starts in radians, measured from the positive x-axis.\r\n * @param endAngle The angle at which the arc ends in radians, measured from the positive x-axis.\r\n * @param anticlockwise An optional Boolean. If true, draws the arc counter-clockwise between the start and end angles. The default is false (clockwise).\r\n */\r\n arc(x: number, y: number, radius: number, startAngle: number, endAngle: number, anticlockwise?: boolean): void;\r\n\r\n /**\r\n * Starts a new path by emptying the list of sub-paths. Call this method when you want to create a new path.\r\n */\r\n beginPath(): void;\r\n\r\n /**\r\n * Causes the point of the pen to move back to the start of the current sub-path. It tries to draw a straight line from the current point to the start.\r\n * If the shape has already been closed or has only one point, this function does nothing.\r\n */\r\n closePath(): void;\r\n\r\n /**\r\n * Moves the starting point of a new sub-path to the (x, y) coordinates.\r\n * @param x The x-axis (horizontal) coordinate of the point.\r\n * @param y The y-axis (vertical) coordinate of the point.\r\n */\r\n moveTo(x: number, y: number): void;\r\n\r\n /**\r\n * Connects the last point in the current sub-path to the specified (x, y) coordinates with a straight line.\r\n * @param x The x-axis coordinate of the line's end point.\r\n * @param y The y-axis coordinate of the line's end point.\r\n */\r\n lineTo(x: number, y: number): void;\r\n\r\n /**\r\n * Adds a quadratic Bézier curve to the current path.\r\n * @param cpx The x-axis coordinate of the control point.\r\n * @param cpy The y-axis coordinate of the control point.\r\n * @param x The x-axis coordinate of the end point.\r\n * @param y The y-axis coordinate of the end point.\r\n */\r\n quadraticCurveTo(cpx: number, cpy: number, x: number, y: number): void;\r\n\r\n /**\r\n * Returns a TextMetrics object.\r\n * @param text The text String to measure.\r\n * @returns ITextMetrics A ITextMetrics object.\r\n */\r\n measureText(text: string): ITextMetrics;\r\n\r\n /**\r\n * Strokes the current sub-paths with the current stroke style.\r\n */\r\n stroke(): void;\r\n\r\n /**\r\n * Fills the current sub-paths with the current fill style.\r\n */\r\n fill(): void;\r\n\r\n /**\r\n * Draws the specified image. This method is available in multiple formats, providing a great deal of flexibility in its use.\r\n * @param image An element to draw into the context.\r\n * @param sx The x-axis coordinate of the top left corner of the sub-rectangle of the source image to draw into the destination context.\r\n * @param sy The y-axis coordinate of the top left corner of the sub-rectangle of the source image to draw into the destination context.\r\n * @param sWidth The width of the sub-rectangle of the source image to draw into the destination context. If not specified, the entire rectangle from the coordinates specified by sx and sy to the bottom-right corner of the image is used.\r\n * @param sHeight The height of the sub-rectangle of the source image to draw into the destination context.\r\n * @param dx The x-axis coordinate in the destination canvas at which to place the top-left corner of the source image.\r\n * @param dy The y-axis coordinate in the destination canvas at which to place the top-left corner of the source image.\r\n * @param dWidth The width to draw the image in the destination canvas. This allows scaling of the drawn image. If not specified, the image is not scaled in width when drawn.\r\n * @param dHeight The height to draw the image in the destination canvas. This allows scaling of the drawn image. If not specified, the image is not scaled in height when drawn.\r\n */\r\n\r\n drawImage(image: any, sx: number, sy: number, sWidth: number, sHeight: number, dx: number, dy: number, dWidth: number, dHeight: number): void;\r\n /**\r\n * Draws the specified image. This method is available in multiple formats, providing a great deal of flexibility in its use.\r\n * @param image An element to draw into the context.\r\n * @param dx The x-axis coordinate in the destination canvas at which to place the top-left corner of the source image.\r\n * @param dy The y-axis coordinate in the destination canvas at which to place the top-left corner of the source image.\r\n * @param dWidth The width to draw the image in the destination canvas. This allows scaling of the drawn image. If not specified, the image is not scaled in width when drawn.\r\n * @param dHeight The height to draw the image in the destination canvas. This allows scaling of the drawn image. If not specified, the image is not scaled in height when drawn.\r\n */\r\n drawImage(image: any, dx: number, dy: number, dWidth: number, dHeight: number): void;\r\n\r\n /**\r\n * Draws the specified image. This method is available in multiple formats, providing a great deal of flexibility in its use.\r\n * @param image An element to draw into the context.\r\n * @param dx The x-axis coordinate in the destination canvas at which to place the top-left corner of the source image.\r\n * @param dy The y-axis coordinate in the destination canvas at which to place the top-left corner of the source image.\r\n */\r\n drawImage(image: any, dx: number, dy: number): void;\r\n\r\n /**\r\n * Returns an ImageData object representing the underlying pixel data for the area of the canvas denoted by the rectangle which starts at (sx, sy) and has an sw width and sh height.\r\n * @param sx The x-axis coordinate of the top-left corner of the rectangle from which the ImageData will be extracted.\r\n * @param sy The y-axis coordinate of the top-left corner of the rectangle from which the ImageData will be extracted.\r\n * @param sw The width of the rectangle from which the ImageData will be extracted. Positive values are to the right, and negative to the left.\r\n * @param sh The height of the rectangle from which the ImageData will be extracted. Positive values are down, and negative are up.\r\n * @returns ImageData An ImageData object containing the image data for the rectangle of the canvas specified.\r\n */\r\n getImageData(sx: number, sy: number, sw: number, sh: number): ImageData;\r\n\r\n /**\r\n * Sets the current line dash pattern.\r\n * @param segments An Array of numbers that specify distances to alternately draw a line and a gap (in coordinate space units).\r\n */\r\n setLineDash(segments: Array<number>): void;\r\n\r\n /**\r\n * Draws (fills) a given text at the given (x, y) position.\r\n * @param text A String specifying the text string to render into the context. The text is rendered using the settings specified by font, textAlign, textBaseline, and direction.\r\n * @param x The x-axis coordinate of the point at which to begin drawing the text, in pixels.\r\n * @param y The y-axis coordinate of the baseline on which to begin drawing the text, in pixels.\r\n * @param maxWidth The maximum number of pixels wide the text may be once rendered. If not specified, there is no limit to the width of the text.\r\n */\r\n fillText(text: string, x: number, y: number, maxWidth?: number): void;\r\n\r\n /**\r\n * Draws (strokes) a given text at the given (x, y) position.\r\n * @param text A String specifying the text string to render into the context. The text is rendered using the settings specified by font, textAlign, textBaseline, and direction.\r\n * @param x The x-axis coordinate of the point at which to begin drawing the text, in pixels.\r\n * @param y The y-axis coordinate of the baseline on which to begin drawing the text, in pixels.\r\n * @param maxWidth The maximum number of pixels wide the text may be once rendered. If not specified, there is no limit to the width of the text.\r\n */\r\n strokeText(text: string, x: number, y: number, maxWidth?: number): void;\r\n\r\n /**\r\n * Creates a linear gradient along the line given by the coordinates represented by the parameters.\r\n * @param x0 The x-axis coordinate of the start point.\r\n * @param y0 The y-axis coordinate of the start point.\r\n * @param x1 The x-axis coordinate of the end point.\r\n * @param y1 The y-axis coordinate of the end point.\r\n * @returns ICanvasGradient A linear ICanvasGradient initialized with the specified line.\r\n */\r\n createLinearGradient(x0: number, y0: number, x1: number, y1: number): ICanvasGradient;\r\n\r\n /**\r\n * Resets the current transform to matrix composed with a, b, c, d, e, f.\r\n * @param a Horizontal scaling. A value of 1 results in no scaling.\r\n * @param b Vertical skewing.\r\n * @param c Horizontal skewing.\r\n * @param d Vertical scaling. A value of 1 results in no scaling.\r\n * @param e Horizontal translation (moving).\r\n * @param f Vertical translation (moving).\r\n */\r\n setTransform(a: number, b: number, c: number, d: number, e: number, f: number): void;\r\n}\r\n"]}
1
+ {"version":3,"file":"ICanvas.js","sourceRoot":"","sources":["../../../../../lts/core/generated/Engines/ICanvas.ts"],"names":[],"mappings":"","sourcesContent":["/**\r\n * Class used to abstract a canvas\r\n */\r\nexport interface ICanvas {\r\n /**\r\n * Canvas width.\r\n */\r\n width: number;\r\n\r\n /**\r\n * Canvas height.\r\n */\r\n height: number;\r\n\r\n /**\r\n * returns a drawing context on the canvas.\r\n * @param contextType context identifier.\r\n * @param contextAttributes context attributes.\r\n * @returns ICanvasRenderingContext object.\r\n */\r\n getContext(contextType: string, contextAttributes?: any): ICanvasRenderingContext;\r\n\r\n /**\r\n * returns a data URI containing a representation of the image in the format specified by the type parameter.\r\n * @param mime the image format.\r\n * @returns string containing the requested data URI.\r\n */\r\n toDataURL(mime: string): string;\r\n}\r\n\r\n/**\r\n * Class used to abstract am image to use with the canvas and its context\r\n */\r\nexport interface IImage {\r\n /**\r\n * onload callback.\r\n */\r\n onload: ((this: GlobalEventHandlers, ev: Event) => any) | null;\r\n\r\n /**\r\n * Error callback.\r\n */\r\n onerror: ((this: GlobalEventHandlers, ev: Event) => any) | null;\r\n\r\n /**\r\n * Image source.\r\n */\r\n src: string;\r\n\r\n /**\r\n * Image width.\r\n */\r\n readonly width: number;\r\n\r\n /**\r\n * Image height.\r\n */\r\n readonly height: number;\r\n\r\n /**\r\n * The original height of the image resource before sizing.\r\n */\r\n readonly naturalHeight: number;\r\n\r\n /**\r\n * The original width of the image resource before sizing.\r\n */\r\n readonly naturalWidth: number;\r\n\r\n /**\r\n * provides support for CORS, defining how the element handles crossorigin requests,\r\n * thereby enabling the configuration of the CORS requests for the element's fetched data.\r\n */\r\n crossOrigin: string | null;\r\n\r\n /**\r\n * provides support for referrer policy on xhr load request,\r\n * it is used to control the request header.\r\n */\r\n referrerPolicy: string;\r\n}\r\n\r\n/**\r\n * Class used to abstract a canvas gradient\r\n */\r\nexport interface ICanvasGradient {\r\n /**\r\n * adds a new color stop, defined by an offset and a color, to a given canvas gradient.\r\n * @param offset A number between 0 and 1, inclusive, representing the position of the color stop. 0 represents the start of the gradient and 1 represents the end.\r\n * @param color value representing the color of the stop.\r\n */\r\n addColorStop(offset: number, color: string): void;\r\n}\r\n\r\n/**\r\n * Class used to abstract a text measurement\r\n */\r\nexport interface ITextMetrics {\r\n /**\r\n * Text width.\r\n */\r\n readonly width: number;\r\n /**\r\n * distance (in pixels) parallel to the baseline from the alignment point given by the CanvasRenderingContext2D.textAlign\r\n * property to the left side of the bounding rectangle of the given text\r\n */\r\n readonly actualBoundingBoxLeft: number;\r\n /**\r\n * distance (in pixels) parallel to the baseline from the alignment point given by the CanvasRenderingContext2D.textAlign\r\n * property to the right side of the bounding rectangle of the given text\r\n */\r\n readonly actualBoundingBoxRight: number;\r\n}\r\n\r\n/**\r\n * Class used to abstract canvas rendering\r\n */\r\nexport interface ICanvasRenderingContext {\r\n /**\r\n * Defines the type of corners where two lines meet. Possible values: round, bevel, miter (default).\r\n */\r\n lineJoin: string;\r\n\r\n /**\r\n * Miter limit ratio. Default 10.\r\n */\r\n miterLimit: number;\r\n\r\n /**\r\n * Font setting. Default value 10px sans-serif.\r\n */\r\n font: string;\r\n\r\n /**\r\n * Color or style to use for the lines around shapes. Default #000 (black).\r\n */\r\n strokeStyle: string;\r\n\r\n /**\r\n * Color or style to use inside shapes. Default #000 (black).\r\n */\r\n fillStyle: string | ICanvasGradient;\r\n\r\n /**\r\n * Alpha value that is applied to shapes and images before they are composited onto the canvas. Default 1.0 (opaque).\r\n */\r\n globalAlpha: number;\r\n\r\n /**\r\n * Color of the shadow. Default: fully-transparent black.\r\n */\r\n shadowColor: string;\r\n\r\n /**\r\n * Specifies the blurring effect. Default: 0.\r\n */\r\n shadowBlur: number;\r\n\r\n /**\r\n * Horizontal distance the shadow will be offset. Default: 0.\r\n */\r\n shadowOffsetX: number;\r\n\r\n /**\r\n * Vertical distance the shadow will be offset. Default: 0.\r\n */\r\n shadowOffsetY: number;\r\n\r\n /**\r\n * Width of lines. Default 1.0.\r\n */\r\n lineWidth: number;\r\n\r\n /**\r\n * canvas is a read-only reference to ICanvas.\r\n */\r\n readonly canvas: ICanvas;\r\n\r\n /**\r\n * Sets all pixels in the rectangle defined by starting point (x, y) and size (width, height) to transparent black, erasing any previously drawn content.\r\n * @param x The x-axis coordinate of the rectangle's starting point.\r\n * @param y The y-axis coordinate of the rectangle's starting point.\r\n * @param width The rectangle's width. Positive values are to the right, and negative to the left.\r\n * @param height The rectangle's height. Positive values are down, and negative are up.\r\n */\r\n clearRect(x: number, y: number, width: number, height: number): void;\r\n\r\n /**\r\n * Saves the current drawing style state using a stack so you can revert any change you make to it using restore().\r\n */\r\n save(): void;\r\n\r\n /**\r\n * Restores the drawing style state to the last element on the 'state stack' saved by save().\r\n */\r\n restore(): void;\r\n\r\n /**\r\n * Draws a filled rectangle at (x, y) position whose size is determined by width and height.\r\n * @param x The x-axis coordinate of the rectangle's starting point.\r\n * @param y The y-axis coordinate of the rectangle's starting point.\r\n * @param width The rectangle's width. Positive values are to the right, and negative to the left.\r\n * @param height The rectangle's height. Positive values are down, and negative are up.\r\n */\r\n fillRect(x: number, y: number, width: number, height: number): void;\r\n\r\n /**\r\n * Adds a scaling transformation to the canvas units by x horizontally and by y vertically.\r\n * @param x Scaling factor in the horizontal direction. A negative value flips pixels across the vertical axis. A value of 1 results in no horizontal scaling.\r\n * @param y Scaling factor in the vertical direction. A negative value flips pixels across the horizontal axis. A value of 1 results in no vertical scaling.\r\n */\r\n scale(x: number, y: number): void;\r\n\r\n /**\r\n * Adds a rotation to the transformation matrix. The angle argument represents a clockwise rotation angle and is expressed in radians.\r\n * @param angle The rotation angle, clockwise in radians. You can use degree * Math.PI / 180 to calculate a radian from a degree.\r\n */\r\n rotate(angle: number): void;\r\n\r\n /**\r\n * Adds a translation transformation by moving the canvas and its origin x horizontally and y vertically on the grid.\r\n * @param x Distance to move in the horizontal direction. Positive values are to the right, and negative to the left.\r\n * @param y Distance to move in the vertical direction. Positive values are down, and negative are up.\r\n */\r\n translate(x: number, y: number): void;\r\n\r\n /**\r\n * Paints a rectangle which has a starting point at (x, y) and has a w width and an h height onto the canvas, using the current stroke style.\r\n * @param x The x-axis coordinate of the rectangle's starting point.\r\n * @param y The y-axis coordinate of the rectangle's starting point.\r\n * @param width The rectangle's width. Positive values are to the right, and negative to the left.\r\n * @param height The rectangle's height. Positive values are down, and negative are up.\r\n */\r\n strokeRect(x: number, y: number, width: number, height: number): void;\r\n\r\n /**\r\n * Creates a path for a rectangle at position (x, y) with a size that is determined by width and height.\r\n * @param x The x-axis coordinate of the rectangle's starting point.\r\n * @param y The y-axis coordinate of the rectangle's starting point.\r\n * @param width The rectangle's width. Positive values are to the right, and negative to the left.\r\n * @param height The rectangle's height. Positive values are down, and negative are up.\r\n */\r\n rect(x: number, y: number, width: number, height: number): void;\r\n\r\n /**\r\n * Creates a clipping path from the current sub-paths. Everything drawn after clip() is called appears inside the clipping path only.\r\n */\r\n clip(): void;\r\n\r\n /**\r\n * Paints data from the given ImageData object onto the bitmap. If a dirty rectangle is provided, only the pixels from that rectangle are painted.\r\n * @param imageData An ImageData object containing the array of pixel values.\r\n * @param dx Horizontal position (x coordinate) at which to place the image data in the destination canvas.\r\n * @param dy Vertical position (y coordinate) at which to place the image data in the destination canvas.\r\n */\r\n putImageData(imageData: ImageData, dx: number, dy: number): void;\r\n\r\n /**\r\n * Adds a circular arc to the current path.\r\n * @param x The horizontal coordinate of the arc's center.\r\n * @param y The vertical coordinate of the arc's center.\r\n * @param radius The arc's radius. Must be positive.\r\n * @param startAngle The angle at which the arc starts in radians, measured from the positive x-axis.\r\n * @param endAngle The angle at which the arc ends in radians, measured from the positive x-axis.\r\n * @param anticlockwise An optional Boolean. If true, draws the arc counter-clockwise between the start and end angles. The default is false (clockwise).\r\n */\r\n arc(x: number, y: number, radius: number, startAngle: number, endAngle: number, anticlockwise?: boolean): void;\r\n\r\n /**\r\n * Starts a new path by emptying the list of sub-paths. Call this method when you want to create a new path.\r\n */\r\n beginPath(): void;\r\n\r\n /**\r\n * Causes the point of the pen to move back to the start of the current sub-path. It tries to draw a straight line from the current point to the start.\r\n * If the shape has already been closed or has only one point, this function does nothing.\r\n */\r\n closePath(): void;\r\n\r\n /**\r\n * Moves the starting point of a new sub-path to the (x, y) coordinates.\r\n * @param x The x-axis (horizontal) coordinate of the point.\r\n * @param y The y-axis (vertical) coordinate of the point.\r\n */\r\n moveTo(x: number, y: number): void;\r\n\r\n /**\r\n * Connects the last point in the current sub-path to the specified (x, y) coordinates with a straight line.\r\n * @param x The x-axis coordinate of the line's end point.\r\n * @param y The y-axis coordinate of the line's end point.\r\n */\r\n lineTo(x: number, y: number): void;\r\n\r\n /**\r\n * Adds a quadratic Bézier curve to the current path.\r\n * @param cpx The x-axis coordinate of the control point.\r\n * @param cpy The y-axis coordinate of the control point.\r\n * @param x The x-axis coordinate of the end point.\r\n * @param y The y-axis coordinate of the end point.\r\n */\r\n quadraticCurveTo(cpx: number, cpy: number, x: number, y: number): void;\r\n\r\n /**\r\n * Returns a TextMetrics object.\r\n * @param text The text String to measure.\r\n * @returns ITextMetrics A ITextMetrics object.\r\n */\r\n measureText(text: string): ITextMetrics;\r\n\r\n /**\r\n * Strokes the current sub-paths with the current stroke style.\r\n */\r\n stroke(): void;\r\n\r\n /**\r\n * Fills the current sub-paths with the current fill style.\r\n */\r\n fill(): void;\r\n\r\n /**\r\n * Draws the specified image. This method is available in multiple formats, providing a great deal of flexibility in its use.\r\n * @param image An element to draw into the context.\r\n * @param sx The x-axis coordinate of the top left corner of the sub-rectangle of the source image to draw into the destination context.\r\n * @param sy The y-axis coordinate of the top left corner of the sub-rectangle of the source image to draw into the destination context.\r\n * @param sWidth The width of the sub-rectangle of the source image to draw into the destination context. If not specified, the entire rectangle from the coordinates specified by sx and sy to the bottom-right corner of the image is used.\r\n * @param sHeight The height of the sub-rectangle of the source image to draw into the destination context.\r\n * @param dx The x-axis coordinate in the destination canvas at which to place the top-left corner of the source image.\r\n * @param dy The y-axis coordinate in the destination canvas at which to place the top-left corner of the source image.\r\n * @param dWidth The width to draw the image in the destination canvas. This allows scaling of the drawn image. If not specified, the image is not scaled in width when drawn.\r\n * @param dHeight The height to draw the image in the destination canvas. This allows scaling of the drawn image. If not specified, the image is not scaled in height when drawn.\r\n */\r\n\r\n drawImage(image: any, sx: number, sy: number, sWidth: number, sHeight: number, dx: number, dy: number, dWidth: number, dHeight: number): void;\r\n /**\r\n * Draws the specified image. This method is available in multiple formats, providing a great deal of flexibility in its use.\r\n * @param image An element to draw into the context.\r\n * @param dx The x-axis coordinate in the destination canvas at which to place the top-left corner of the source image.\r\n * @param dy The y-axis coordinate in the destination canvas at which to place the top-left corner of the source image.\r\n * @param dWidth The width to draw the image in the destination canvas. This allows scaling of the drawn image. If not specified, the image is not scaled in width when drawn.\r\n * @param dHeight The height to draw the image in the destination canvas. This allows scaling of the drawn image. If not specified, the image is not scaled in height when drawn.\r\n */\r\n drawImage(image: any, dx: number, dy: number, dWidth: number, dHeight: number): void;\r\n\r\n /**\r\n * Draws the specified image. This method is available in multiple formats, providing a great deal of flexibility in its use.\r\n * @param image An element to draw into the context.\r\n * @param dx The x-axis coordinate in the destination canvas at which to place the top-left corner of the source image.\r\n * @param dy The y-axis coordinate in the destination canvas at which to place the top-left corner of the source image.\r\n */\r\n drawImage(image: any, dx: number, dy: number): void;\r\n\r\n /**\r\n * Returns an ImageData object representing the underlying pixel data for the area of the canvas denoted by the rectangle which starts at (sx, sy) and has an sw width and sh height.\r\n * @param sx The x-axis coordinate of the top-left corner of the rectangle from which the ImageData will be extracted.\r\n * @param sy The y-axis coordinate of the top-left corner of the rectangle from which the ImageData will be extracted.\r\n * @param sw The width of the rectangle from which the ImageData will be extracted. Positive values are to the right, and negative to the left.\r\n * @param sh The height of the rectangle from which the ImageData will be extracted. Positive values are down, and negative are up.\r\n * @returns ImageData An ImageData object containing the image data for the rectangle of the canvas specified.\r\n */\r\n getImageData(sx: number, sy: number, sw: number, sh: number): ImageData;\r\n\r\n /**\r\n * Sets the current line dash pattern.\r\n * @param segments An Array of numbers that specify distances to alternately draw a line and a gap (in coordinate space units).\r\n */\r\n setLineDash(segments: Array<number>): void;\r\n\r\n /**\r\n * Draws (fills) a given text at the given (x, y) position.\r\n * @param text A String specifying the text string to render into the context. The text is rendered using the settings specified by font, textAlign, textBaseline, and direction.\r\n * @param x The x-axis coordinate of the point at which to begin drawing the text, in pixels.\r\n * @param y The y-axis coordinate of the baseline on which to begin drawing the text, in pixels.\r\n * @param maxWidth The maximum number of pixels wide the text may be once rendered. If not specified, there is no limit to the width of the text.\r\n */\r\n fillText(text: string, x: number, y: number, maxWidth?: number): void;\r\n\r\n /**\r\n * Draws (strokes) a given text at the given (x, y) position.\r\n * @param text A String specifying the text string to render into the context. The text is rendered using the settings specified by font, textAlign, textBaseline, and direction.\r\n * @param x The x-axis coordinate of the point at which to begin drawing the text, in pixels.\r\n * @param y The y-axis coordinate of the baseline on which to begin drawing the text, in pixels.\r\n * @param maxWidth The maximum number of pixels wide the text may be once rendered. If not specified, there is no limit to the width of the text.\r\n */\r\n strokeText(text: string, x: number, y: number, maxWidth?: number): void;\r\n\r\n /**\r\n * Creates a linear gradient along the line given by the coordinates represented by the parameters.\r\n * @param x0 The x-axis coordinate of the start point.\r\n * @param y0 The y-axis coordinate of the start point.\r\n * @param x1 The x-axis coordinate of the end point.\r\n * @param y1 The y-axis coordinate of the end point.\r\n * @returns ICanvasGradient A linear ICanvasGradient initialized with the specified line.\r\n */\r\n createLinearGradient(x0: number, y0: number, x1: number, y1: number): ICanvasGradient;\r\n\r\n /**\r\n * Resets the current transform to matrix composed with a, b, c, d, e, f.\r\n * @param a Horizontal scaling. A value of 1 results in no scaling.\r\n * @param b Vertical skewing.\r\n * @param c Horizontal skewing.\r\n * @param d Vertical scaling. A value of 1 results in no scaling.\r\n * @param e Horizontal translation (moving).\r\n * @param f Vertical translation (moving).\r\n */\r\n setTransform(a: number, b: number, c: number, d: number, e: number, f: number): void;\r\n}\r\n"]}
@@ -361,7 +361,7 @@ export declare enum QueryType {
361
361
  Timestamp = "timestamp"
362
362
  }
363
363
  /** @hidden */
364
- export declare enum CanvasCompositingAlphaMode {
364
+ export declare enum CanvasAlphaMode {
365
365
  Opaque = "opaque",
366
366
  Premultiplied = "premultiplied"
367
367
  }
@@ -413,11 +413,11 @@ export var QueryType;
413
413
  QueryType["Timestamp"] = "timestamp";
414
414
  })(QueryType || (QueryType = {}));
415
415
  /** @hidden */
416
- export var CanvasCompositingAlphaMode;
417
- (function (CanvasCompositingAlphaMode) {
418
- CanvasCompositingAlphaMode["Opaque"] = "opaque";
419
- CanvasCompositingAlphaMode["Premultiplied"] = "premultiplied";
420
- })(CanvasCompositingAlphaMode || (CanvasCompositingAlphaMode = {}));
416
+ export var CanvasAlphaMode;
417
+ (function (CanvasAlphaMode) {
418
+ CanvasAlphaMode["Opaque"] = "opaque";
419
+ CanvasAlphaMode["Premultiplied"] = "premultiplied";
420
+ })(CanvasAlphaMode || (CanvasAlphaMode = {}));
421
421
  /** @hidden */
422
422
  export var DeviceLostReason;
423
423
  (function (DeviceLostReason) {
@@ -1 +1 @@
1
- {"version":3,"file":"webgpuConstants.js","sourceRoot":"","sources":["../../../../../../lts/core/generated/Engines/WebGPU/webgpuConstants.ts"],"names":[],"mappings":"AAAA,cAAc;AACd,yCAAyC;AACzC,MAAM,CAAN,IAAY,oBAEX;AAFD,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b,yBAAe,CAAA;AACnB,CAAC,EAHW,MAAM,KAAN,MAAM,QAGjB;AAED,cAAc;AACd,MAAM,CAAN,IAAY,OAGX;AAHD,WAAY,OAAO;IACf,0BAAe,CAAA;IACf,8BAAmB,CAAA;AACvB,CAAC,EAHW,OAAO,KAAP,OAAO,QAGlB;AAED,cAAc;AACd,MAAM,CAAN,IAAY,SAGX;AAHD,WAAY,SAAS;IACjB,oCAAuB,CAAA;IACvB,oCAAuB,CAAA;AAC3B,CAAC,EAHW,SAAS,KAAT,SAAS,QAGpB;AAED,cAAc;AACd,MAAM,CAAN,IAAY,0BAGX;AAHD,WAAY,0BAA0B;IAClC,+CAAiB,CAAA;IACjB,6DAA+B,CAAA;AACnC,CAAC,EAHW,0BAA0B,KAA1B,0BAA0B,QAGrC;AAED,cAAc;AACd,MAAM,CAAN,IAAY,gBAEX;AAFD,WAAY,gBAAgB;IACxB,2CAAuB,CAAA;AAC3B,CAAC,EAFW,gBAAgB,KAAhB,gBAAgB,QAE3B;AAED,cAAc;AACd,MAAM,CAAN,IAAY,WAGX;AAHD,WAAY,WAAW;IACnB,4CAA6B,CAAA;IAC7B,wCAAyB,CAAA;AAC7B,CAAC,EAHW,WAAW,KAAX,WAAW,QAGtB","sourcesContent":["/** @hidden */\r\n// eslint-disable-next-line import/export\r\nexport enum PredefinedColorSpace {\r\n SRGB = \"srgb\",\r\n}\r\n\r\n/** @hidden */\r\n// eslint-disable-next-line import/export\r\nexport enum PowerPreference {\r\n LowPower = \"low-power\",\r\n HighPerformance = \"high-performance\",\r\n}\r\n\r\n/** @hidden */\r\nexport enum FeatureName {\r\n DepthClipControl = \"depth-clip-control\",\r\n Depth24UnormStencil8 = \"depth24unorm-stencil8\",\r\n Depth32FloatStencil8 = \"depth32float-stencil8\",\r\n TextureCompressionBC = \"texture-compression-bc\",\r\n TextureCompressionETC2 = \"texture-compression-etc2\",\r\n TextureCompressionASTC = \"texture-compression-astc\",\r\n TimestampQuery = \"timestamp-query\",\r\n IndirectFirstInstance = \"indirect-first-instance\",\r\n ShaderF16 = \"shader-f16\",\r\n BGRA8UnormStorage = \"bgra8unorm-storage\",\r\n}\r\n\r\n/** @hidden */\r\nexport enum BufferUsage {\r\n MapRead = 1,\r\n MapWrite = 2,\r\n CopySrc = 4,\r\n CopyDst = 8,\r\n Index = 16,\r\n Vertex = 32,\r\n Uniform = 64,\r\n Storage = 128,\r\n Indirect = 256,\r\n QueryResolve = 512,\r\n}\r\n\r\n/** @hidden */\r\nexport enum MapMode {\r\n Read = 1,\r\n Write = 2,\r\n}\r\n\r\n/** @hidden */\r\nexport enum TextureDimension {\r\n E1d = \"1d\",\r\n E2d = \"2d\",\r\n E3d = \"3d\",\r\n}\r\n\r\n/** @hidden */\r\nexport enum TextureUsage {\r\n CopySrc = 1,\r\n CopyDst = 2,\r\n TextureBinding = 4,\r\n StorageBinding = 8,\r\n RenderAttachment = 16,\r\n}\r\n\r\n/** @hidden */\r\nexport enum TextureViewDimension {\r\n E1d = \"1d\",\r\n E2d = \"2d\",\r\n E2dArray = \"2d-array\",\r\n Cube = \"cube\",\r\n CubeArray = \"cube-array\",\r\n E3d = \"3d\",\r\n}\r\n\r\n/** @hidden */\r\nexport enum TextureAspect {\r\n All = \"all\",\r\n StencilOnly = \"stencil-only\",\r\n DepthOnly = \"depth-only\",\r\n}\r\n\r\n/**\r\n * Comments taken from https://github.com/gfx-rs/wgpu/blob/master/wgpu-types/src/lib.rs\r\n * @hidden\r\n */\r\nexport enum TextureFormat {\r\n // 8-bit formats\r\n R8Unorm = \"r8unorm\", // Red channel only. 8 bit integer per channel. [0, 255] converted to/from float [0, 1] in shader.\r\n R8Snorm = \"r8snorm\", // Red channel only. 8 bit integer per channel. [-127, 127] converted to/from float [-1, 1] in shader.\r\n R8Uint = \"r8uint\", // Red channel only. 8 bit integer per channel. Unsigned in shader.\r\n R8Sint = \"r8sint\", // Red channel only. 8 bit integer per channel. Signed in shader.\r\n\r\n // 16-bit formats\r\n R16Uint = \"r16uint\", // Red channel only. 16 bit integer per channel. Unsigned in shader.\r\n R16Sint = \"r16sint\", // Red channel only. 16 bit integer per channel. Signed in shader.\r\n R16Float = \"r16float\", // Red channel only. 16 bit float per channel. Float in shader.\r\n RG8Unorm = \"rg8unorm\", // Red and green channels. 8 bit integer per channel. [0, 255] converted to/from float [0, 1] in shader.\r\n RG8Snorm = \"rg8snorm\", // Red and green channels. 8 bit integer per channel. [-127, 127] converted to/from float [-1, 1] in shader.\r\n RG8Uint = \"rg8uint\", // Red and green channels. 8 bit integer per channel. Unsigned in shader.\r\n RG8Sint = \"rg8sint\", // Red and green channels. 8 bit integer per channel. Signed in shader.\r\n\r\n // 32-bit formats\r\n R32Uint = \"r32uint\", // Red channel only. 32 bit integer per channel. Unsigned in shader.\r\n R32Sint = \"r32sint\", // Red channel only. 32 bit integer per channel. Signed in shader.\r\n R32Float = \"r32float\", // Red channel only. 32 bit float per channel. Float in shader.\r\n RG16Uint = \"rg16uint\", // Red and green channels. 16 bit integer per channel. Unsigned in shader.\r\n RG16Sint = \"rg16sint\", // Red and green channels. 16 bit integer per channel. Signed in shader.\r\n RG16Float = \"rg16float\", // Red and green channels. 16 bit float per channel. Float in shader.\r\n RGBA8Unorm = \"rgba8unorm\", // Red, green, blue, and alpha channels. 8 bit integer per channel. [0, 255] converted to/from float [0, 1] in shader.\r\n RGBA8UnormSRGB = \"rgba8unorm-srgb\", // Red, green, blue, and alpha channels. 8 bit integer per channel. Srgb-color [0, 255] converted to/from linear-color float [0, 1] in shader.\r\n RGBA8Snorm = \"rgba8snorm\", // Red, green, blue, and alpha channels. 8 bit integer per channel. [-127, 127] converted to/from float [-1, 1] in shader.\r\n RGBA8Uint = \"rgba8uint\", // Red, green, blue, and alpha channels. 8 bit integer per channel. Unsigned in shader.\r\n RGBA8Sint = \"rgba8sint\", // Red, green, blue, and alpha channels. 8 bit integer per channel. Signed in shader.\r\n BGRA8Unorm = \"bgra8unorm\", // Blue, green, red, and alpha channels. 8 bit integer per channel. [0, 255] converted to/from float [0, 1] in shader.\r\n BGRA8UnormSRGB = \"bgra8unorm-srgb\", // Blue, green, red, and alpha channels. 8 bit integer per channel. Srgb-color [0, 255] converted to/from linear-color float [0, 1] in shader.\r\n // Packed 32-bit formats\r\n RGB9E5UFloat = \"rgb9e5ufloat\", // Packed unsigned float with 9 bits mantisa for each RGB component, then a common 5 bits exponent\r\n RGB10A2Unorm = \"rgb10a2unorm\", // Red, green, blue, and alpha channels. 10 bit integer for RGB channels, 2 bit integer for alpha channel. [0, 1023] ([0, 3] for alpha) converted to/from float [0, 1] in shader.\r\n RG11B10UFloat = \"rg11b10ufloat\", // Red, green, and blue channels. 11 bit float with no sign bit for RG channels. 10 bit float with no sign bit for blue channel. Float in shader.\r\n\r\n // 64-bit formats\r\n RG32Uint = \"rg32uint\", // Red and green channels. 32 bit integer per channel. Unsigned in shader.\r\n RG32Sint = \"rg32sint\", // Red and green channels. 32 bit integer per channel. Signed in shader.\r\n RG32Float = \"rg32float\", // Red and green channels. 32 bit float per channel. Float in shader.\r\n RGBA16Uint = \"rgba16uint\", // Red, green, blue, and alpha channels. 16 bit integer per channel. Unsigned in shader.\r\n RGBA16Sint = \"rgba16sint\", // Red, green, blue, and alpha channels. 16 bit integer per channel. Signed in shader.\r\n RGBA16Float = \"rgba16float\", // Red, green, blue, and alpha channels. 16 bit float per channel. Float in shader.\r\n\r\n // 128-bit formats\r\n RGBA32Uint = \"rgba32uint\", // Red, green, blue, and alpha channels. 32 bit integer per channel. Unsigned in shader.\r\n RGBA32Sint = \"rgba32sint\", // Red, green, blue, and alpha channels. 32 bit integer per channel. Signed in shader.\r\n RGBA32Float = \"rgba32float\", // Red, green, blue, and alpha channels. 32 bit float per channel. Float in shader.\r\n\r\n // Depth and stencil formats\r\n Stencil8 = \"stencil8\",\r\n Depth16Unorm = \"depth16unorm\",\r\n Depth24Plus = \"depth24plus\", // Special depth format with at least 24 bit integer depth.\r\n Depth24PlusStencil8 = \"depth24plus-stencil8\", // Special depth/stencil format with at least 24 bit integer depth and 8 bits integer stencil.\r\n Depth32Float = \"depth32float\", // Special depth format with 32 bit floating point depth.\r\n\r\n // BC compressed formats usable if \"texture-compression-bc\" is both\r\n // supported by the device/user agent and enabled in requestDevice.\r\n BC1RGBAUnorm = \"bc1-rgba-unorm\", // 4x4 block compressed texture. 8 bytes per block (4 bit/px). 4 color + alpha pallet. 5 bit R + 6 bit G + 5 bit B + 1 bit alpha. Also known as DXT1.\r\n BC1RGBAUnormSRGB = \"bc1-rgba-unorm-srgb\", // 4x4 block compressed texture. 8 bytes per block (4 bit/px). 4 color + alpha pallet. 5 bit R + 6 bit G + 5 bit B + 1 bit alpha. Also known as DXT1.\r\n BC2RGBAUnorm = \"bc2-rgba-unorm\", // 4x4 block compressed texture. 16 bytes per block (8 bit/px). 4 color pallet. 5 bit R + 6 bit G + 5 bit B + 4 bit alpha. Also known as DXT3.\r\n BC2RGBAUnormSRGB = \"bc2-rgba-unorm-srgb\", // 4x4 block compressed texture. 16 bytes per block (8 bit/px). 4 color pallet. 5 bit R + 6 bit G + 5 bit B + 4 bit alpha. Also known as DXT3.\r\n BC3RGBAUnorm = \"bc3-rgba-unorm\", // 4x4 block compressed texture. 16 bytes per block (8 bit/px). 4 color pallet + 8 alpha pallet. 5 bit R + 6 bit G + 5 bit B + 8 bit alpha. Also known as DXT5.\r\n BC3RGBAUnormSRGB = \"bc3-rgba-unorm-srgb\", // 4x4 block compressed texture. 16 bytes per block (8 bit/px). 4 color pallet + 8 alpha pallet. 5 bit R + 6 bit G + 5 bit B + 8 bit alpha. Also known as DXT5.\r\n BC4RUnorm = \"bc4-r-unorm\", // 4x4 block compressed texture. 8 bytes per block (4 bit/px). 8 color pallet. 8 bit R. Also known as RGTC1.\r\n BC4RSnorm = \"bc4-r-snorm\", // 4x4 block compressed texture. 8 bytes per block (4 bit/px). 8 color pallet. 8 bit R. Also known as RGTC1.\r\n BC5RGUnorm = \"bc5-rg-unorm\", // 4x4 block compressed texture. 16 bytes per block (8 bit/px). 8 color red pallet + 8 color green pallet. 8 bit RG. Also known as RGTC2.\r\n BC5RGSnorm = \"bc5-rg-snorm\", // 4x4 block compressed texture. 16 bytes per block (8 bit/px). 8 color red pallet + 8 color green pallet. 8 bit RG. Also known as RGTC2.\r\n BC6HRGBUFloat = \"bc6h-rgb-ufloat\", // 4x4 block compressed texture. 16 bytes per block (8 bit/px). Variable sized pallet. 16 bit unsigned float RGB. Float in shader. Also known as BPTC (float).\r\n BC6HRGBFloat = \"bc6h-rgb-float\", // 4x4 block compressed texture. 16 bytes per block (8 bit/px). Variable sized pallet. 16 bit signed float RGB. Float in shader. Also known as BPTC (float).\r\n BC7RGBAUnorm = \"bc7-rgba-unorm\", // 4x4 block compressed texture. 16 bytes per block (8 bit/px). Variable sized pallet. 8 bit integer RGBA. Also known as BPTC (unorm).\r\n BC7RGBAUnormSRGB = \"bc7-rgba-unorm-srgb\", // 4x4 block compressed texture. 16 bytes per block (8 bit/px). Variable sized pallet. 8 bit integer RGBA. Also known as BPTC (unorm).\r\n\r\n // ETC2 compressed formats usable if \"texture-compression-etc2\" is both\r\n // supported by the device/user agent and enabled in requestDevice.\r\n ETC2RGB8Unorm = \"etc2-rgb8unorm\", // 4x4 block compressed texture. 8 bytes per block (4 bit/px). Complex pallet. 8 bit integer RGB.\r\n ETC2RGB8UnormSRGB = \"etc2-rgb8unorm-srgb\", // 4x4 block compressed texture. 8 bytes per block (4 bit/px). Complex pallet. 8 bit integer RGB.\r\n ETC2RGB8A1Unorm = \"etc2-rgb8a1unorm\", // 4x4 block compressed texture. 8 bytes per block (4 bit/px). Complex pallet. 8 bit integer RGB + 1 bit alpha.\r\n ETC2RGB8A1UnormSRGB = \"etc2-rgb8a1unorm-srgb\", // 4x4 block compressed texture. 8 bytes per block (4 bit/px). Complex pallet. 8 bit integer RGB + 1 bit alpha.\r\n ETC2RGBA8Unorm = \"etc2-rgba8unorm\", // 4x4 block compressed texture. 16 bytes per block (8 bit/px). Complex pallet. 8 bit integer RGB + 8 bit alpha.\r\n ETC2RGBA8UnormSRGB = \"etc2-rgba8unorm-srgb\", // 4x4 block compressed texture. 16 bytes per block (8 bit/px). Complex pallet. 8 bit integer RGB + 8 bit alpha.\r\n EACR11Unorm = \"eac-r11unorm\", // 4x4 block compressed texture. 8 bytes per block (4 bit/px). Complex pallet. 11 bit integer R.\r\n EACR11Snorm = \"eac-r11snorm\", // 4x4 block compressed texture. 8 bytes per block (4 bit/px). Complex pallet. 11 bit integer R.\r\n EACRG11Unorm = \"eac-rg11unorm\", // 4x4 block compressed texture. 16 bytes per block (8 bit/px). Complex pallet. 11 bit integer R + 11 bit integer G.\r\n EACRG11Snorm = \"eac-rg11snorm\", // 4x4 block compressed texture. 16 bytes per block (8 bit/px). Complex pallet. 11 bit integer R + 11 bit integer G.\r\n\r\n // ASTC compressed formats usable if \"texture-compression-astc\" is both\r\n // supported by the device/user agent and enabled in requestDevice.\r\n ASTC4x4Unorm = \"astc-4x4-unorm\", // 4x4 block compressed texture. 16 bytes per block (8 bit/px). Complex pallet. 8 bit integer RGBA.\r\n ASTC4x4UnormSRGB = \"astc-4x4-unorm-srgb\", // 4x4 block compressed texture. 16 bytes per block (8 bit/px). Complex pallet. 8 bit integer RGBA.\r\n ASTC5x4Unorm = \"astc-5x4-unorm\", // 5x4 block compressed texture. 16 bytes per block (6.4 bit/px). Complex pallet. 8 bit integer RGBA.\r\n ASTC5x4UnormSRGB = \"astc-5x4-unorm-srgb\", // 5x4 block compressed texture. 16 bytes per block (6.4 bit/px). Complex pallet. 8 bit integer RGBA.\r\n ASTC5x5Unorm = \"astc-5x5-unorm\", // 5x5 block compressed texture. 16 bytes per block (5.12 bit/px). Complex pallet. 8 bit integer RGBA.\r\n ASTC5x5UnormSRGB = \"astc-5x5-unorm-srgb\", // 5x5 block compressed texture. 16 bytes per block (5.12 bit/px). Complex pallet. 8 bit integer RGBA.\r\n ASTC6x5Unorm = \"astc-6x5-unorm\", // 6x5 block compressed texture. 16 bytes per block (4.27 bit/px). Complex pallet. 8 bit integer RGBA.\r\n ASTC6x5UnormSRGB = \"astc-6x5-unorm-srgb\", // 6x5 block compressed texture. 16 bytes per block (4.27 bit/px). Complex pallet. 8 bit integer RGBA.\r\n ASTC6x6Unorm = \"astc-6x6-unorm\", // 6x6 block compressed texture. 16 bytes per block (3.56 bit/px). Complex pallet. 8 bit integer RGBA.\r\n ASTC6x6UnormSRGB = \"astc-6x6-unorm-srgb\", // 6x6 block compressed texture. 16 bytes per block (3.56 bit/px). Complex pallet. 8 bit integer RGBA.\r\n ASTC8x5Unorm = \"astc-8x5-unorm\", // 8x5 block compressed texture. 16 bytes per block (3.2 bit/px). Complex pallet. 8 bit integer RGBA.\r\n ASTC8x5UnormSRGB = \"astc-8x5-unorm-srgb\", // 8x5 block compressed texture. 16 bytes per block (3.2 bit/px). Complex pallet. 8 bit integer RGBA.\r\n ASTC8x6Unorm = \"astc-8x6-unorm\", // 8x6 block compressed texture. 16 bytes per block (2.67 bit/px). Complex pallet. 8 bit integer RGBA.\r\n ASTC8x6UnormSRGB = \"astc-8x6-unorm-srgb\", // 8x6 block compressed texture. 16 bytes per block (2.67 bit/px). Complex pallet. 8 bit integer RGBA.\r\n ASTC8x8Unorm = \"astc-8x8-unorm\", // 8x8 block compressed texture. 16 bytes per block (2 bit/px). Complex pallet. 8 bit integer RGBA.\r\n ASTC8x8UnormSRGB = \"astc-8x8-unorm-srgb\", // 8x8 block compressed texture. 16 bytes per block (2 bit/px). Complex pallet. 8 bit integer RGBA.\r\n ASTC10x5Unorm = \"astc-10x5-unorm\", // 10x5 block compressed texture. 16 bytes per block (2.56 bit/px). Complex pallet. 8 bit integer RGBA.\r\n ASTC10x5UnormSRGB = \"astc-10x5-unorm-srgb\", // 10x5 block compressed texture. 16 bytes per block (2.56 bit/px). Complex pallet. 8 bit integer RGBA.\r\n ASTC10x6Unorm = \"astc-10x6-unorm\", // 10x6 block compressed texture. 16 bytes per block (2.13 bit/px). Complex pallet. 8 bit integer RGBA.\r\n ASTC10x6UnormSRGB = \"astc-10x6-unorm-srgb\", // 10x6 block compressed texture. 16 bytes per block (2.13 bit/px). Complex pallet. 8 bit integer RGBA.\r\n ASTC10x8Unorm = \"astc-10x8-unorm\", // 10x8 block compressed texture. 16 bytes per block (1.6 bit/px). Complex pallet. 8 bit integer RGBA.\r\n ASTC10x8UnormSRGB = \"astc-10x8-unorm-srgb\", // 10x8 block compressed texture. 16 bytes per block (1.6 bit/px). Complex pallet. 8 bit integer RGBA.\r\n ASTC10x10Unorm = \"astc-10x10-unorm\", // 10x10 block compressed texture. 16 bytes per block (1.28 bit/px). Complex pallet. 8 bit integer RGBA.\r\n ASTC10x10UnormSRGB = \"astc-10x10-unorm-srgb\", // 10x10 block compressed texture. 16 bytes per block (1.28 bit/px). Complex pallet. 8 bit integer RGBA.\r\n ASTC12x10Unorm = \"astc-12x10-unorm\", // 12x10 block compressed texture. 16 bytes per block (1.07 bit/px). Complex pallet. 8 bit integer RGBA.\r\n ASTC12x10UnormSRGB = \"astc-12x10-unorm-srgb\", // 12x10 block compressed texture. 16 bytes per block (1.07 bit/px). Complex pallet. 8 bit integer RGBA.\r\n ASTC12x12Unorm = \"astc-12x12-unorm\", // 12x12 block compressed texture. 16 bytes per block (0.89 bit/px). Complex pallet. 8 bit integer RGBA.\r\n ASTC12x12UnormSRGB = \"astc-12x12-unorm-srgb\", // 12x12 block compressed texture. 16 bytes per block (0.89 bit/px). Complex pallet. 8 bit integer RGBA.\r\n\r\n // \"depth24unorm-stencil8\" feature\r\n Depth24UnormStencil8 = \"depth24unorm-stencil8\",\r\n\r\n // \"depth32float-stencil8\" feature\r\n Depth32FloatStencil8 = \"depth32float-stencil8\",\r\n}\r\n\r\n/** @hidden */\r\nexport enum AddressMode {\r\n ClampToEdge = \"clamp-to-edge\",\r\n Repeat = \"repeat\",\r\n MirrorRepeat = \"mirror-repeat\",\r\n}\r\n\r\n/** @hidden */\r\nexport enum FilterMode {\r\n Nearest = \"nearest\",\r\n Linear = \"linear\",\r\n}\r\n\r\n/** @hidden */\r\nexport enum CompareFunction {\r\n Never = \"never\",\r\n Less = \"less\",\r\n Equal = \"equal\",\r\n LessEqual = \"less-equal\",\r\n Greater = \"greater\",\r\n NotEqual = \"not-equal\",\r\n GreaterEqual = \"greater-equal\",\r\n Always = \"always\",\r\n}\r\n\r\n/** @hidden */\r\nexport enum ShaderStage {\r\n Vertex = 1,\r\n Fragment = 2,\r\n Compute = 4,\r\n}\r\n\r\n/** @hidden */\r\nexport enum BufferBindingType {\r\n Uniform = \"uniform\",\r\n Storage = \"storage\",\r\n ReadOnlyStorage = \"read-only-storage\",\r\n}\r\n\r\n/** @hidden */\r\nexport enum SamplerBindingType {\r\n Filtering = \"filtering\",\r\n NonFiltering = \"non-filtering\",\r\n Comparison = \"comparison\",\r\n}\r\n\r\n/** @hidden */\r\nexport enum TextureSampleType {\r\n Float = \"float\",\r\n UnfilterableFloat = \"unfilterable-float\",\r\n Depth = \"depth\",\r\n Sint = \"sint\",\r\n Uint = \"uint\",\r\n}\r\n\r\n/** @hidden */\r\nexport enum StorageTextureAccess {\r\n WriteOnly = \"write-only\",\r\n}\r\n\r\n/** @hidden */\r\nexport enum CompilationMessageType {\r\n Error = \"error\",\r\n Warning = \"warning\",\r\n Info = \"info\",\r\n}\r\n\r\n/** @hidden */\r\nexport enum AutoLayoutMode {\r\n Auto = \"auto\",\r\n}\r\n\r\n/** @hidden */\r\nexport enum PrimitiveTopology {\r\n PointList = \"point-list\",\r\n LineList = \"line-list\",\r\n LineStrip = \"line-strip\",\r\n TriangleList = \"triangle-list\",\r\n TriangleStrip = \"triangle-strip\",\r\n}\r\n\r\n/** @hidden */\r\nexport enum FrontFace {\r\n CCW = \"ccw\",\r\n CW = \"cw\",\r\n}\r\n\r\n/** @hidden */\r\nexport enum CullMode {\r\n None = \"none\",\r\n Front = \"front\",\r\n Back = \"back\",\r\n}\r\n\r\n/** @hidden */\r\nexport enum ColorWriteFlags {\r\n Red = 1,\r\n Green = 2,\r\n Blue = 4,\r\n Alpha = 8,\r\n All = 15,\r\n}\r\n\r\n/** @hidden */\r\nexport enum BlendFactor {\r\n Zero = \"zero\",\r\n One = \"one\",\r\n Src = \"src\",\r\n OneMinusSrc = \"one-minus-src\",\r\n SrcAlpha = \"src-alpha\",\r\n OneMinusSrcAlpha = \"one-minus-src-alpha\",\r\n Dst = \"dst\",\r\n OneMinusDst = \"one-minus-dst\",\r\n DstAlpha = \"dst-alpha\",\r\n OneMinusDstAlpha = \"one-minus-dst-alpha\",\r\n SrcAlphaSaturated = \"src-alpha-saturated\",\r\n Constant = \"constant\",\r\n OneMinusConstant = \"one-minus-constant\",\r\n}\r\n\r\n/** @hidden */\r\nexport enum BlendOperation {\r\n Add = \"add\",\r\n Subtract = \"subtract\",\r\n ReverseSubtract = \"reverse-subtract\",\r\n Min = \"min\",\r\n Max = \"max\",\r\n}\r\n\r\n/** @hidden */\r\nexport enum StencilOperation {\r\n Keep = \"keep\",\r\n Zero = \"zero\",\r\n Replace = \"replace\",\r\n Invert = \"invert\",\r\n IncrementClamp = \"increment-clamp\",\r\n DecrementClamp = \"decrement-clamp\",\r\n IncrementWrap = \"increment-wrap\",\r\n DecrementWrap = \"decrement-wrap\",\r\n}\r\n\r\n/** @hidden */\r\nexport enum IndexFormat {\r\n Uint16 = \"uint16\",\r\n Uint32 = \"uint32\",\r\n}\r\n\r\n/** @hidden */\r\nexport enum VertexFormat {\r\n Uint8x2 = \"uint8x2\",\r\n Uint8x4 = \"uint8x4\",\r\n Sint8x2 = \"sint8x2\",\r\n Sint8x4 = \"sint8x4\",\r\n Unorm8x2 = \"unorm8x2\",\r\n Unorm8x4 = \"unorm8x4\",\r\n Snorm8x2 = \"snorm8x2\",\r\n Snorm8x4 = \"snorm8x4\",\r\n Uint16x2 = \"uint16x2\",\r\n Uint16x4 = \"uint16x4\",\r\n Sint16x2 = \"sint16x2\",\r\n Sint16x4 = \"sint16x4\",\r\n Unorm16x2 = \"unorm16x2\",\r\n Unorm16x4 = \"unorm16x4\",\r\n Snorm16x2 = \"snorm16x2\",\r\n Snorm16x4 = \"snorm16x4\",\r\n Float16x2 = \"float16x2\",\r\n Float16x4 = \"float16x4\",\r\n Float32 = \"float32\",\r\n Float32x2 = \"float32x2\",\r\n Float32x3 = \"float32x3\",\r\n Float32x4 = \"float32x4\",\r\n Uint32 = \"uint32\",\r\n Uint32x2 = \"uint32x2\",\r\n Uint32x3 = \"uint32x3\",\r\n Uint32x4 = \"uint32x4\",\r\n Sint32 = \"sint32\",\r\n Sint32x2 = \"sint32x2\",\r\n Sint32x3 = \"sint32x3\",\r\n Sint32x4 = \"sint32x4\",\r\n}\r\n\r\n/** @hidden */\r\nexport enum InputStepMode {\r\n Vertex = \"vertex\",\r\n Instance = \"instance\",\r\n}\r\n\r\n/** @hidden */\r\nexport enum ComputePassTimestampLocation {\r\n Beginning = \"beginning\",\r\n End = \"end\",\r\n}\r\n\r\n/** @hidden */\r\nexport enum RenderPassTimestampLocation {\r\n Beginning = \"beginning\",\r\n End = \"end\",\r\n}\r\n\r\n/** @hidden */\r\nexport enum LoadOp {\r\n Load = \"load\",\r\n Clear = \"clear\",\r\n}\r\n\r\n/** @hidden */\r\nexport enum StoreOp {\r\n Store = \"store\",\r\n Discard = \"discard\",\r\n}\r\n\r\n/** @hidden */\r\nexport enum QueryType {\r\n Occlusion = \"occlusion\",\r\n Timestamp = \"timestamp\",\r\n}\r\n\r\n/** @hidden */\r\nexport enum CanvasCompositingAlphaMode {\r\n Opaque = \"opaque\",\r\n Premultiplied = \"premultiplied\",\r\n}\r\n\r\n/** @hidden */\r\nexport enum DeviceLostReason {\r\n Destroyed = \"destroyed\",\r\n}\r\n\r\n/** @hidden */\r\nexport enum ErrorFilter {\r\n OutOfMemory = \"out-of-memory\",\r\n Validation = \"validation\",\r\n}\r\n"]}
1
+ {"version":3,"file":"webgpuConstants.js","sourceRoot":"","sources":["../../../../../../lts/core/generated/Engines/WebGPU/webgpuConstants.ts"],"names":[],"mappings":"AAAA,cAA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N,IAAY,MAGX;AAHD,WAAY,MAAM;IACd,uBAAa,CAAA;IACb,yBAAe,CAAA;AACnB,CAAC,EAHW,MAAM,KAAN,MAAM,QAGjB;AAED,cAAc;AACd,MAAM,CAAN,IAAY,OAGX;AAHD,WAAY,OAAO;IACf,0BAAe,CAAA;IACf,8BAAmB,CAAA;AACvB,CAAC,EAHW,OAAO,KAAP,OAAO,QAGlB;AAED,cAAc;AACd,MAAM,CAAN,IAAY,SAGX;AAHD,WAAY,SAAS;IACjB,oCAAuB,CAAA;IACvB,oCAAuB,CAAA;AAC3B,CAAC,EAHW,SAAS,KAAT,SAAS,QAGpB;AAED,cAAc;AACd,MAAM,CAAN,IAAY,eAGX;AAHD,WAAY,eAAe;IACvB,oCAAiB,CAAA;IACjB,kDAA+B,CAAA;AACnC,CAAC,EAHW,eAAe,KAAf,eAAe,QAG1B;AAED,cAAc;AACd,MAAM,CAAN,IAAY,gBAEX;AAFD,WAAY,gBAAgB;IACxB,2CAAuB,CAAA;AAC3B,CAAC,EAFW,gBAAgB,KAAhB,gBAAgB,QAE3B;AAED,cAAc;AACd,MAAM,CAAN,IAAY,WAGX;AAHD,WAAY,WAAW;IACnB,4CAA6B,CAAA;IAC7B,wCAAyB,CAAA;AAC7B,CAAC,EAHW,WAAW,KAAX,WAAW,QAGtB","sourcesContent":["/** @hidden */\r\n// eslint-disable-next-line import/export\r\nexport enum PredefinedColorSpace {\r\n SRGB = \"srgb\",\r\n}\r\n\r\n/** @hidden */\r\n// eslint-disable-next-line import/export\r\nexport enum PowerPreference {\r\n LowPower = \"low-power\",\r\n HighPerformance = \"high-performance\",\r\n}\r\n\r\n/** @hidden */\r\nexport enum FeatureName {\r\n DepthClipControl = \"depth-clip-control\",\r\n Depth24UnormStencil8 = \"depth24unorm-stencil8\",\r\n Depth32FloatStencil8 = \"depth32float-stencil8\",\r\n TextureCompressionBC = \"texture-compression-bc\",\r\n TextureCompressionETC2 = \"texture-compression-etc2\",\r\n TextureCompressionASTC = \"texture-compression-astc\",\r\n TimestampQuery = \"timestamp-query\",\r\n IndirectFirstInstance = \"indirect-first-instance\",\r\n ShaderF16 = \"shader-f16\",\r\n BGRA8UnormStorage = \"bgra8unorm-storage\",\r\n}\r\n\r\n/** @hidden */\r\nexport enum BufferUsage {\r\n MapRead = 1,\r\n MapWrite = 2,\r\n CopySrc = 4,\r\n CopyDst = 8,\r\n Index = 16,\r\n Vertex = 32,\r\n Uniform = 64,\r\n Storage = 128,\r\n Indirect = 256,\r\n QueryResolve = 512,\r\n}\r\n\r\n/** @hidden */\r\nexport enum MapMode {\r\n Read = 1,\r\n Write = 2,\r\n}\r\n\r\n/** @hidden */\r\nexport enum TextureDimension {\r\n E1d = \"1d\",\r\n E2d = \"2d\",\r\n E3d = \"3d\",\r\n}\r\n\r\n/** @hidden */\r\nexport enum TextureUsage {\r\n CopySrc = 1,\r\n CopyDst = 2,\r\n TextureBinding = 4,\r\n StorageBinding = 8,\r\n RenderAttachment = 16,\r\n}\r\n\r\n/** @hidden */\r\nexport enum TextureViewDimension {\r\n E1d = \"1d\",\r\n E2d = \"2d\",\r\n E2dArray = \"2d-array\",\r\n Cube = \"cube\",\r\n CubeArray = \"cube-array\",\r\n E3d = \"3d\",\r\n}\r\n\r\n/** @hidden */\r\nexport enum TextureAspect {\r\n All = \"all\",\r\n StencilOnly = \"stencil-only\",\r\n DepthOnly = \"depth-only\",\r\n}\r\n\r\n/**\r\n * Comments taken from https://github.com/gfx-rs/wgpu/blob/master/wgpu-types/src/lib.rs\r\n * @hidden\r\n */\r\nexport enum TextureFormat {\r\n // 8-bit formats\r\n R8Unorm = \"r8unorm\", // Red channel only. 8 bit integer per channel. [0, 255] converted to/from float [0, 1] in shader.\r\n R8Snorm = \"r8snorm\", // Red channel only. 8 bit integer per channel. [-127, 127] converted to/from float [-1, 1] in shader.\r\n R8Uint = \"r8uint\", // Red channel only. 8 bit integer per channel. Unsigned in shader.\r\n R8Sint = \"r8sint\", // Red channel only. 8 bit integer per channel. Signed in shader.\r\n\r\n // 16-bit formats\r\n R16Uint = \"r16uint\", // Red channel only. 16 bit integer per channel. Unsigned in shader.\r\n R16Sint = \"r16sint\", // Red channel only. 16 bit integer per channel. Signed in shader.\r\n R16Float = \"r16float\", // Red channel only. 16 bit float per channel. Float in shader.\r\n RG8Unorm = \"rg8unorm\", // Red and green channels. 8 bit integer per channel. [0, 255] converted to/from float [0, 1] in shader.\r\n RG8Snorm = \"rg8snorm\", // Red and green channels. 8 bit integer per channel. [-127, 127] converted to/from float [-1, 1] in shader.\r\n RG8Uint = \"rg8uint\", // Red and green channels. 8 bit integer per channel. Unsigned in shader.\r\n RG8Sint = \"rg8sint\", // Red and green channels. 8 bit integer per channel. Signed in shader.\r\n\r\n // 32-bit formats\r\n R32Uint = \"r32uint\", // Red channel only. 32 bit integer per channel. Unsigned in shader.\r\n R32Sint = \"r32sint\", // Red channel only. 32 bit integer per channel. Signed in shader.\r\n R32Float = \"r32float\", // Red channel only. 32 bit float per channel. Float in shader.\r\n RG16Uint = \"rg16uint\", // Red and green channels. 16 bit integer per channel. Unsigned in shader.\r\n RG16Sint = \"rg16sint\", // Red and green channels. 16 bit integer per channel. Signed in shader.\r\n RG16Float = \"rg16float\", // Red and green channels. 16 bit float per channel. Float in shader.\r\n RGBA8Unorm = \"rgba8unorm\", // Red, green, blue, and alpha channels. 8 bit integer per channel. [0, 255] converted to/from float [0, 1] in shader.\r\n RGBA8UnormSRGB = \"rgba8unorm-srgb\", // Red, green, blue, and alpha channels. 8 bit integer per channel. Srgb-color [0, 255] converted to/from linear-color float [0, 1] in shader.\r\n RGBA8Snorm = \"rgba8snorm\", // Red, green, blue, and alpha channels. 8 bit integer per channel. [-127, 127] converted to/from float [-1, 1] in shader.\r\n RGBA8Uint = \"rgba8uint\", // Red, green, blue, and alpha channels. 8 bit integer per channel. Unsigned in shader.\r\n RGBA8Sint = \"rgba8sint\", // Red, green, blue, and alpha channels. 8 bit integer per channel. Signed in shader.\r\n BGRA8Unorm = \"bgra8unorm\", // Blue, green, red, and alpha channels. 8 bit integer per channel. [0, 255] converted to/from float [0, 1] in shader.\r\n BGRA8UnormSRGB = \"bgra8unorm-srgb\", // Blue, green, red, and alpha channels. 8 bit integer per channel. Srgb-color [0, 255] converted to/from linear-color float [0, 1] in shader.\r\n // Packed 32-bit formats\r\n RGB9E5UFloat = \"rgb9e5ufloat\", // Packed unsigned float with 9 bits mantisa for each RGB component, then a common 5 bits exponent\r\n RGB10A2Unorm = \"rgb10a2unorm\", // Red, green, blue, and alpha channels. 10 bit integer for RGB channels, 2 bit integer for alpha channel. [0, 1023] ([0, 3] for alpha) converted to/from float [0, 1] in shader.\r\n RG11B10UFloat = \"rg11b10ufloat\", // Red, green, and blue channels. 11 bit float with no sign bit for RG channels. 10 bit float with no sign bit for blue channel. Float in shader.\r\n\r\n // 64-bit formats\r\n RG32Uint = \"rg32uint\", // Red and green channels. 32 bit integer per channel. Unsigned in shader.\r\n RG32Sint = \"rg32sint\", // Red and green channels. 32 bit integer per channel. Signed in shader.\r\n RG32Float = \"rg32float\", // Red and green channels. 32 bit float per channel. Float in shader.\r\n RGBA16Uint = \"rgba16uint\", // Red, green, blue, and alpha channels. 16 bit integer per channel. Unsigned in shader.\r\n RGBA16Sint = \"rgba16sint\", // Red, green, blue, and alpha channels. 16 bit integer per channel. Signed in shader.\r\n RGBA16Float = \"rgba16float\", // Red, green, blue, and alpha channels. 16 bit float per channel. Float in shader.\r\n\r\n // 128-bit formats\r\n RGBA32Uint = \"rgba32uint\", // Red, green, blue, and alpha channels. 32 bit integer per channel. Unsigned in shader.\r\n RGBA32Sint = \"rgba32sint\", // Red, green, blue, and alpha channels. 32 bit integer per channel. Signed in shader.\r\n RGBA32Float = \"rgba32float\", // Red, green, blue, and alpha channels. 32 bit float per channel. Float in shader.\r\n\r\n // Depth and stencil formats\r\n Stencil8 = \"stencil8\",\r\n Depth16Unorm = \"depth16unorm\",\r\n Depth24Plus = \"depth24plus\", // Special depth format with at least 24 bit integer depth.\r\n Depth24PlusStencil8 = \"depth24plus-stencil8\", // Special depth/stencil format with at least 24 bit integer depth and 8 bits integer stencil.\r\n Depth32Float = \"depth32float\", // Special depth format with 32 bit floating point depth.\r\n\r\n // BC compressed formats usable if \"texture-compression-bc\" is both\r\n // supported by the device/user agent and enabled in requestDevice.\r\n BC1RGBAUnorm = \"bc1-rgba-unorm\", // 4x4 block compressed texture. 8 bytes per block (4 bit/px). 4 color + alpha pallet. 5 bit R + 6 bit G + 5 bit B + 1 bit alpha. Also known as DXT1.\r\n BC1RGBAUnormSRGB = \"bc1-rgba-unorm-srgb\", // 4x4 block compressed texture. 8 bytes per block (4 bit/px). 4 color + alpha pallet. 5 bit R + 6 bit G + 5 bit B + 1 bit alpha. Also known as DXT1.\r\n BC2RGBAUnorm = \"bc2-rgba-unorm\", // 4x4 block compressed texture. 16 bytes per block (8 bit/px). 4 color pallet. 5 bit R + 6 bit G + 5 bit B + 4 bit alpha. Also known as DXT3.\r\n BC2RGBAUnormSRGB = \"bc2-rgba-unorm-srgb\", // 4x4 block compressed texture. 16 bytes per block (8 bit/px). 4 color pallet. 5 bit R + 6 bit G + 5 bit B + 4 bit alpha. Also known as DXT3.\r\n BC3RGBAUnorm = \"bc3-rgba-unorm\", // 4x4 block compressed texture. 16 bytes per block (8 bit/px). 4 color pallet + 8 alpha pallet. 5 bit R + 6 bit G + 5 bit B + 8 bit alpha. Also known as DXT5.\r\n BC3RGBAUnormSRGB = \"bc3-rgba-unorm-srgb\", // 4x4 block compressed texture. 16 bytes per block (8 bit/px). 4 color pallet + 8 alpha pallet. 5 bit R + 6 bit G + 5 bit B + 8 bit alpha. Also known as DXT5.\r\n BC4RUnorm = \"bc4-r-unorm\", // 4x4 block compressed texture. 8 bytes per block (4 bit/px). 8 color pallet. 8 bit R. Also known as RGTC1.\r\n BC4RSnorm = \"bc4-r-snorm\", // 4x4 block compressed texture. 8 bytes per block (4 bit/px). 8 color pallet. 8 bit R. Also known as RGTC1.\r\n BC5RGUnorm = \"bc5-rg-unorm\", // 4x4 block compressed texture. 16 bytes per block (8 bit/px). 8 color red pallet + 8 color green pallet. 8 bit RG. Also known as RGTC2.\r\n BC5RGSnorm = \"bc5-rg-snorm\", // 4x4 block compressed texture. 16 bytes per block (8 bit/px). 8 color red pallet + 8 color green pallet. 8 bit RG. Also known as RGTC2.\r\n BC6HRGBUFloat = \"bc6h-rgb-ufloat\", // 4x4 block compressed texture. 16 bytes per block (8 bit/px). Variable sized pallet. 16 bit unsigned float RGB. Float in shader. Also known as BPTC (float).\r\n BC6HRGBFloat = \"bc6h-rgb-float\", // 4x4 block compressed texture. 16 bytes per block (8 bit/px). Variable sized pallet. 16 bit signed float RGB. Float in shader. Also known as BPTC (float).\r\n BC7RGBAUnorm = \"bc7-rgba-unorm\", // 4x4 block compressed texture. 16 bytes per block (8 bit/px). Variable sized pallet. 8 bit integer RGBA. Also known as BPTC (unorm).\r\n BC7RGBAUnormSRGB = \"bc7-rgba-unorm-srgb\", // 4x4 block compressed texture. 16 bytes per block (8 bit/px). Variable sized pallet. 8 bit integer RGBA. Also known as BPTC (unorm).\r\n\r\n // ETC2 compressed formats usable if \"texture-compression-etc2\" is both\r\n // supported by the device/user agent and enabled in requestDevice.\r\n ETC2RGB8Unorm = \"etc2-rgb8unorm\", // 4x4 block compressed texture. 8 bytes per block (4 bit/px). Complex pallet. 8 bit integer RGB.\r\n ETC2RGB8UnormSRGB = \"etc2-rgb8unorm-srgb\", // 4x4 block compressed texture. 8 bytes per block (4 bit/px). Complex pallet. 8 bit integer RGB.\r\n ETC2RGB8A1Unorm = \"etc2-rgb8a1unorm\", // 4x4 block compressed texture. 8 bytes per block (4 bit/px). Complex pallet. 8 bit integer RGB + 1 bit alpha.\r\n ETC2RGB8A1UnormSRGB = \"etc2-rgb8a1unorm-srgb\", // 4x4 block compressed texture. 8 bytes per block (4 bit/px). Complex pallet. 8 bit integer RGB + 1 bit alpha.\r\n ETC2RGBA8Unorm = \"etc2-rgba8unorm\", // 4x4 block compressed texture. 16 bytes per block (8 bit/px). Complex pallet. 8 bit integer RGB + 8 bit alpha.\r\n ETC2RGBA8UnormSRGB = \"etc2-rgba8unorm-srgb\", // 4x4 block compressed texture. 16 bytes per block (8 bit/px). Complex pallet. 8 bit integer RGB + 8 bit alpha.\r\n EACR11Unorm = \"eac-r11unorm\", // 4x4 block compressed texture. 8 bytes per block (4 bit/px). Complex pallet. 11 bit integer R.\r\n EACR11Snorm = \"eac-r11snorm\", // 4x4 block compressed texture. 8 bytes per block (4 bit/px). Complex pallet. 11 bit integer R.\r\n EACRG11Unorm = \"eac-rg11unorm\", // 4x4 block compressed texture. 16 bytes per block (8 bit/px). Complex pallet. 11 bit integer R + 11 bit integer G.\r\n EACRG11Snorm = \"eac-rg11snorm\", // 4x4 block compressed texture. 16 bytes per block (8 bit/px). Complex pallet. 11 bit integer R + 11 bit integer G.\r\n\r\n // ASTC compressed formats usable if \"texture-compression-astc\" is both\r\n // supported by the device/user agent and enabled in requestDevice.\r\n ASTC4x4Unorm = \"astc-4x4-unorm\", // 4x4 block compressed texture. 16 bytes per block (8 bit/px). Complex pallet. 8 bit integer RGBA.\r\n ASTC4x4UnormSRGB = \"astc-4x4-unorm-srgb\", // 4x4 block compressed texture. 16 bytes per block (8 bit/px). Complex pallet. 8 bit integer RGBA.\r\n ASTC5x4Unorm = \"astc-5x4-unorm\", // 5x4 block compressed texture. 16 bytes per block (6.4 bit/px). Complex pallet. 8 bit integer RGBA.\r\n ASTC5x4UnormSRGB = \"astc-5x4-unorm-srgb\", // 5x4 block compressed texture. 16 bytes per block (6.4 bit/px). Complex pallet. 8 bit integer RGBA.\r\n ASTC5x5Unorm = \"astc-5x5-unorm\", // 5x5 block compressed texture. 16 bytes per block (5.12 bit/px). Complex pallet. 8 bit integer RGBA.\r\n ASTC5x5UnormSRGB = \"astc-5x5-unorm-srgb\", // 5x5 block compressed texture. 16 bytes per block (5.12 bit/px). Complex pallet. 8 bit integer RGBA.\r\n ASTC6x5Unorm = \"astc-6x5-unorm\", // 6x5 block compressed texture. 16 bytes per block (4.27 bit/px). Complex pallet. 8 bit integer RGBA.\r\n ASTC6x5UnormSRGB = \"astc-6x5-unorm-srgb\", // 6x5 block compressed texture. 16 bytes per block (4.27 bit/px). Complex pallet. 8 bit integer RGBA.\r\n ASTC6x6Unorm = \"astc-6x6-unorm\", // 6x6 block compressed texture. 16 bytes per block (3.56 bit/px). Complex pallet. 8 bit integer RGBA.\r\n ASTC6x6UnormSRGB = \"astc-6x6-unorm-srgb\", // 6x6 block compressed texture. 16 bytes per block (3.56 bit/px). Complex pallet. 8 bit integer RGBA.\r\n ASTC8x5Unorm = \"astc-8x5-unorm\", // 8x5 block compressed texture. 16 bytes per block (3.2 bit/px). Complex pallet. 8 bit integer RGBA.\r\n ASTC8x5UnormSRGB = \"astc-8x5-unorm-srgb\", // 8x5 block compressed texture. 16 bytes per block (3.2 bit/px). Complex pallet. 8 bit integer RGBA.\r\n ASTC8x6Unorm = \"astc-8x6-unorm\", // 8x6 block compressed texture. 16 bytes per block (2.67 bit/px). Complex pallet. 8 bit integer RGBA.\r\n ASTC8x6UnormSRGB = \"astc-8x6-unorm-srgb\", // 8x6 block compressed texture. 16 bytes per block (2.67 bit/px). Complex pallet. 8 bit integer RGBA.\r\n ASTC8x8Unorm = \"astc-8x8-unorm\", // 8x8 block compressed texture. 16 bytes per block (2 bit/px). Complex pallet. 8 bit integer RGBA.\r\n ASTC8x8UnormSRGB = \"astc-8x8-unorm-srgb\", // 8x8 block compressed texture. 16 bytes per block (2 bit/px). Complex pallet. 8 bit integer RGBA.\r\n ASTC10x5Unorm = \"astc-10x5-unorm\", // 10x5 block compressed texture. 16 bytes per block (2.56 bit/px). Complex pallet. 8 bit integer RGBA.\r\n ASTC10x5UnormSRGB = \"astc-10x5-unorm-srgb\", // 10x5 block compressed texture. 16 bytes per block (2.56 bit/px). Complex pallet. 8 bit integer RGBA.\r\n ASTC10x6Unorm = \"astc-10x6-unorm\", // 10x6 block compressed texture. 16 bytes per block (2.13 bit/px). Complex pallet. 8 bit integer RGBA.\r\n ASTC10x6UnormSRGB = \"astc-10x6-unorm-srgb\", // 10x6 block compressed texture. 16 bytes per block (2.13 bit/px). Complex pallet. 8 bit integer RGBA.\r\n ASTC10x8Unorm = \"astc-10x8-unorm\", // 10x8 block compressed texture. 16 bytes per block (1.6 bit/px). Complex pallet. 8 bit integer RGBA.\r\n ASTC10x8UnormSRGB = \"astc-10x8-unorm-srgb\", // 10x8 block compressed texture. 16 bytes per block (1.6 bit/px). Complex pallet. 8 bit integer RGBA.\r\n ASTC10x10Unorm = \"astc-10x10-unorm\", // 10x10 block compressed texture. 16 bytes per block (1.28 bit/px). Complex pallet. 8 bit integer RGBA.\r\n ASTC10x10UnormSRGB = \"astc-10x10-unorm-srgb\", // 10x10 block compressed texture. 16 bytes per block (1.28 bit/px). Complex pallet. 8 bit integer RGBA.\r\n ASTC12x10Unorm = \"astc-12x10-unorm\", // 12x10 block compressed texture. 16 bytes per block (1.07 bit/px). Complex pallet. 8 bit integer RGBA.\r\n ASTC12x10UnormSRGB = \"astc-12x10-unorm-srgb\", // 12x10 block compressed texture. 16 bytes per block (1.07 bit/px). Complex pallet. 8 bit integer RGBA.\r\n ASTC12x12Unorm = \"astc-12x12-unorm\", // 12x12 block compressed texture. 16 bytes per block (0.89 bit/px). Complex pallet. 8 bit integer RGBA.\r\n ASTC12x12UnormSRGB = \"astc-12x12-unorm-srgb\", // 12x12 block compressed texture. 16 bytes per block (0.89 bit/px). Complex pallet. 8 bit integer RGBA.\r\n\r\n // \"depth24unorm-stencil8\" feature\r\n Depth24UnormStencil8 = \"depth24unorm-stencil8\",\r\n\r\n // \"depth32float-stencil8\" feature\r\n Depth32FloatStencil8 = \"depth32float-stencil8\",\r\n}\r\n\r\n/** @hidden */\r\nexport enum AddressMode {\r\n ClampToEdge = \"clamp-to-edge\",\r\n Repeat = \"repeat\",\r\n MirrorRepeat = \"mirror-repeat\",\r\n}\r\n\r\n/** @hidden */\r\nexport enum FilterMode {\r\n Nearest = \"nearest\",\r\n Linear = \"linear\",\r\n}\r\n\r\n/** @hidden */\r\nexport enum CompareFunction {\r\n Never = \"never\",\r\n Less = \"less\",\r\n Equal = \"equal\",\r\n LessEqual = \"less-equal\",\r\n Greater = \"greater\",\r\n NotEqual = \"not-equal\",\r\n GreaterEqual = \"greater-equal\",\r\n Always = \"always\",\r\n}\r\n\r\n/** @hidden */\r\nexport enum ShaderStage {\r\n Vertex = 1,\r\n Fragment = 2,\r\n Compute = 4,\r\n}\r\n\r\n/** @hidden */\r\nexport enum BufferBindingType {\r\n Uniform = \"uniform\",\r\n Storage = \"storage\",\r\n ReadOnlyStorage = \"read-only-storage\",\r\n}\r\n\r\n/** @hidden */\r\nexport enum SamplerBindingType {\r\n Filtering = \"filtering\",\r\n NonFiltering = \"non-filtering\",\r\n Comparison = \"comparison\",\r\n}\r\n\r\n/** @hidden */\r\nexport enum TextureSampleType {\r\n Float = \"float\",\r\n UnfilterableFloat = \"unfilterable-float\",\r\n Depth = \"depth\",\r\n Sint = \"sint\",\r\n Uint = \"uint\",\r\n}\r\n\r\n/** @hidden */\r\nexport enum StorageTextureAccess {\r\n WriteOnly = \"write-only\",\r\n}\r\n\r\n/** @hidden */\r\nexport enum CompilationMessageType {\r\n Error = \"error\",\r\n Warning = \"warning\",\r\n Info = \"info\",\r\n}\r\n\r\n/** @hidden */\r\nexport enum AutoLayoutMode {\r\n Auto = \"auto\",\r\n}\r\n\r\n/** @hidden */\r\nexport enum PrimitiveTopology {\r\n PointList = \"point-list\",\r\n LineList = \"line-list\",\r\n LineStrip = \"line-strip\",\r\n TriangleList = \"triangle-list\",\r\n TriangleStrip = \"triangle-strip\",\r\n}\r\n\r\n/** @hidden */\r\nexport enum FrontFace {\r\n CCW = \"ccw\",\r\n CW = \"cw\",\r\n}\r\n\r\n/** @hidden */\r\nexport enum CullMode {\r\n None = \"none\",\r\n Front = \"front\",\r\n Back = \"back\",\r\n}\r\n\r\n/** @hidden */\r\nexport enum ColorWriteFlags {\r\n Red = 1,\r\n Green = 2,\r\n Blue = 4,\r\n Alpha = 8,\r\n All = 15,\r\n}\r\n\r\n/** @hidden */\r\nexport enum BlendFactor {\r\n Zero = \"zero\",\r\n One = \"one\",\r\n Src = \"src\",\r\n OneMinusSrc = \"one-minus-src\",\r\n SrcAlpha = \"src-alpha\",\r\n OneMinusSrcAlpha = \"one-minus-src-alpha\",\r\n Dst = \"dst\",\r\n OneMinusDst = \"one-minus-dst\",\r\n DstAlpha = \"dst-alpha\",\r\n OneMinusDstAlpha = \"one-minus-dst-alpha\",\r\n SrcAlphaSaturated = \"src-alpha-saturated\",\r\n Constant = \"constant\",\r\n OneMinusConstant = \"one-minus-constant\",\r\n}\r\n\r\n/** @hidden */\r\nexport enum BlendOperation {\r\n Add = \"add\",\r\n Subtract = \"subtract\",\r\n ReverseSubtract = \"reverse-subtract\",\r\n Min = \"min\",\r\n Max = \"max\",\r\n}\r\n\r\n/** @hidden */\r\nexport enum StencilOperation {\r\n Keep = \"keep\",\r\n Zero = \"zero\",\r\n Replace = \"replace\",\r\n Invert = \"invert\",\r\n IncrementClamp = \"increment-clamp\",\r\n DecrementClamp = \"decrement-clamp\",\r\n IncrementWrap = \"increment-wrap\",\r\n DecrementWrap = \"decrement-wrap\",\r\n}\r\n\r\n/** @hidden */\r\nexport enum IndexFormat {\r\n Uint16 = \"uint16\",\r\n Uint32 = \"uint32\",\r\n}\r\n\r\n/** @hidden */\r\nexport enum VertexFormat {\r\n Uint8x2 = \"uint8x2\",\r\n Uint8x4 = \"uint8x4\",\r\n Sint8x2 = \"sint8x2\",\r\n Sint8x4 = \"sint8x4\",\r\n Unorm8x2 = \"unorm8x2\",\r\n Unorm8x4 = \"unorm8x4\",\r\n Snorm8x2 = \"snorm8x2\",\r\n Snorm8x4 = \"snorm8x4\",\r\n Uint16x2 = \"uint16x2\",\r\n Uint16x4 = \"uint16x4\",\r\n Sint16x2 = \"sint16x2\",\r\n Sint16x4 = \"sint16x4\",\r\n Unorm16x2 = \"unorm16x2\",\r\n Unorm16x4 = \"unorm16x4\",\r\n Snorm16x2 = \"snorm16x2\",\r\n Snorm16x4 = \"snorm16x4\",\r\n Float16x2 = \"float16x2\",\r\n Float16x4 = \"float16x4\",\r\n Float32 = \"float32\",\r\n Float32x2 = \"float32x2\",\r\n Float32x3 = \"float32x3\",\r\n Float32x4 = \"float32x4\",\r\n Uint32 = \"uint32\",\r\n Uint32x2 = \"uint32x2\",\r\n Uint32x3 = \"uint32x3\",\r\n Uint32x4 = \"uint32x4\",\r\n Sint32 = \"sint32\",\r\n Sint32x2 = \"sint32x2\",\r\n Sint32x3 = \"sint32x3\",\r\n Sint32x4 = \"sint32x4\",\r\n}\r\n\r\n/** @hidden */\r\nexport enum InputStepMode {\r\n Vertex = \"vertex\",\r\n Instance = \"instance\",\r\n}\r\n\r\n/** @hidden */\r\nexport enum ComputePassTimestampLocation {\r\n Beginning = \"beginning\",\r\n End = \"end\",\r\n}\r\n\r\n/** @hidden */\r\nexport enum RenderPassTimestampLocation {\r\n Beginning = \"beginning\",\r\n End = \"end\",\r\n}\r\n\r\n/** @hidden */\r\nexport enum LoadOp {\r\n Load = \"load\",\r\n Clear = \"clear\",\r\n}\r\n\r\n/** @hidden */\r\nexport enum StoreOp {\r\n Store = \"store\",\r\n Discard = \"discard\",\r\n}\r\n\r\n/** @hidden */\r\nexport enum QueryType {\r\n Occlusion = \"occlusion\",\r\n Timestamp = \"timestamp\",\r\n}\r\n\r\n/** @hidden */\r\nexport enum CanvasAlphaMode {\r\n Opaque = \"opaque\",\r\n Premultiplied = \"premultiplied\",\r\n}\r\n\r\n/** @hidden */\r\nexport enum DeviceLostReason {\r\n Destroyed = \"destroyed\",\r\n}\r\n\r\n/** @hidden */\r\nexport enum ErrorFilter {\r\n OutOfMemory = \"out-of-memory\",\r\n Validation = \"validation\",\r\n}\r\n"]}
@@ -2243,7 +2243,7 @@ class GPUCanvasContext {
2243
2243
  getCurrentTexture(): GPUTexture;
2244
2244
  }
2245
2245
 
2246
- type GPUCanvasCompositingAlphaMode = "opaque" | "premultiplied";
2246
+ type GPUCanvasAlphaMode = "opaque" | "premultiplied";
2247
2247
 
2248
2248
  interface GPUCanvasConfiguration extends GPUObjectDescriptorBase {
2249
2249
  device: GPUDevice;
@@ -2251,7 +2251,7 @@ interface GPUCanvasConfiguration extends GPUObjectDescriptorBase {
2251
2251
  usage?: GPUTextureUsageFlags /* default=0x10 - GPUTextureUsage.RENDER_ATTACHMENT */;
2252
2252
  viewFormats?: GPUTextureFormat[] /* default=[] */;
2253
2253
  colorSpace?: GPUPredefinedColorSpace /* default="srgb" */;
2254
- compositingAlphaMode?: GPUCanvasCompositingAlphaMode /* default="opaque" */;
2254
+ alphaMode?: GPUCanvasAlphaMode /* default="opaque" */;
2255
2255
  }
2256
2256
 
2257
2257
  type GPUDeviceLostReason = "destroyed";
@@ -400,7 +400,7 @@ var ThinEngine = /** @class */ (function () {
400
400
  */
401
401
  // Not mixed with Version for tooling purpose.
402
402
  get: function () {
403
- return "babylonjs@5.11.0";
403
+ return "babylonjs@5.12.0";
404
404
  },
405
405
  enumerable: false,
406
406
  configurable: true
@@ -410,7 +410,7 @@ var ThinEngine = /** @class */ (function () {
410
410
  * Returns the current version of the framework
411
411
  */
412
412
  get: function () {
413
- return "5.11.0";
413
+ return "5.12.0";
414
414
  },
415
415
  enumerable: false,
416
416
  configurable: true