@rings-webgpu/core 1.0.48 → 1.0.50

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.
@@ -42333,7 +42333,7 @@ else if (typeof exports === 'object')
42333
42333
  }
42334
42334
  }
42335
42335
 
42336
- const version = "1.0.48";
42336
+ const version = "1.0.50";
42337
42337
 
42338
42338
  class Engine3D {
42339
42339
  /**
@@ -62169,8 +62169,10 @@ fn frag(){
62169
62169
  _cancelled = false;
62170
62170
  // Async processing state
62171
62171
  _parseTimeoutId = null;
62172
- _verticesPerChunk = 1e7;
62172
+ static sVerticesPerChunk = 1e7;
62173
62173
  // Number of vertices to process per chunk
62174
+ static sMaxProcessingTime = 5;
62175
+ // Maximum processing time per chunk (ms) to avoid blocking
62174
62176
  _useIdleCallback = typeof requestIdleCallback !== "undefined";
62175
62177
  constructor(onHeaderParsed, onSplatParsed, batchSize = 1e3) {
62176
62178
  this._onHeaderParsed = onHeaderParsed;
@@ -62392,7 +62394,6 @@ fn frag(){
62392
62394
  const has = (n) => this._properties.find((p) => p.name === n) != null;
62393
62395
  const propIndex = (n) => this._properties.findIndex((p) => p.name === n);
62394
62396
  const startTime = performance.now();
62395
- const maxProcessingTime = 5;
62396
62397
  let processedInThisChunk = 0;
62397
62398
  while (this._processedVertices < vertexCount && !this._cancelled) {
62398
62399
  const v = this._processedVertices;
@@ -62470,9 +62471,9 @@ fn frag(){
62470
62471
  this._scheduleNextChunk();
62471
62472
  return;
62472
62473
  }
62473
- if (processedInThisChunk >= this._verticesPerChunk) {
62474
+ if (processedInThisChunk >= PlyStreamParser.sVerticesPerChunk) {
62474
62475
  const elapsed = performance.now() - startTime;
62475
- if (elapsed > maxProcessingTime) {
62476
+ if (elapsed > PlyStreamParser.sMaxProcessingTime) {
62476
62477
  this._scheduleNextChunk();
62477
62478
  return;
62478
62479
  }
@@ -62561,7 +62562,7 @@ fn frag(){
62561
62562
  _streamParser = null;
62562
62563
  _streamingRenderer = null;
62563
62564
  _rendererObject = null;
62564
- _chunksPerBatch = 1e3;
62565
+ _chunksPerBatch = 1e4;
62565
62566
  // Number of splats to process per batch
62566
62567
  _headerParsed = false;
62567
62568
  _onHeaderParsed = null;
@@ -22,7 +22,8 @@ export declare class PlyStreamParser {
22
22
  private _batchSize;
23
23
  private _cancelled;
24
24
  private _parseTimeoutId;
25
- private _verticesPerChunk;
25
+ static sVerticesPerChunk: number;
26
+ static sMaxProcessingTime: number;
26
27
  private _useIdleCallback;
27
28
  constructor(onHeaderParsed: (header: PlyHeader) => void, onSplatParsed: (splatData: SplatData, index: number) => void, batchSize?: number);
28
29
  /**
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@rings-webgpu/core",
3
- "version": "1.0.48",
3
+ "version": "1.0.50",
4
4
  "description": "Rings webgpu Engine",
5
5
  "main": "index.js",
6
6
  "exports": {