@playcanvas/splat-transform 1.3.0 → 1.4.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/cli.mjs +103 -30
- package/dist/cli.mjs.map +1 -1
- package/dist/index.cjs +101 -29
- package/dist/index.cjs.map +1 -1
- package/dist/index.mjs +101 -30
- package/dist/index.mjs.map +1 -1
- package/dist/lib/data-table/data-table.d.ts +2 -1
- package/dist/lib/index.d.cts +1 -1
- package/dist/lib/index.d.ts +1 -1
- package/dist/lib/io/read/buffered-read-stream.d.ts +26 -0
- package/dist/lib/io/read/index.d.ts +1 -0
- package/package.json +1 -1
|
@@ -81,7 +81,8 @@ declare class DataTable {
|
|
|
81
81
|
* After calling, row `i` will contain the data that was previously at row `indices[i]`.
|
|
82
82
|
*
|
|
83
83
|
* This is a memory-efficient alternative to `permuteRows` that modifies the table
|
|
84
|
-
* in-place rather than creating a copy.
|
|
84
|
+
* in-place rather than creating a copy. It reuses ArrayBuffers between columns to
|
|
85
|
+
* minimize memory allocations.
|
|
85
86
|
*
|
|
86
87
|
* @param indices - Array of indices defining the permutation. Must have the same
|
|
87
88
|
* length as the number of rows, and must be a valid permutation
|
package/dist/lib/index.d.cts
CHANGED
|
@@ -11,7 +11,7 @@ export { writeFile, getOutputFormat } from './write';
|
|
|
11
11
|
export type { OutputFormat, WriteOptions } from './write';
|
|
12
12
|
export { processDataTable } from './process';
|
|
13
13
|
export type { ProcessAction, Translate, Rotate, Scale, FilterNaN, FilterByValue, FilterBands, FilterBox, FilterSphere, Param as ProcessParam, Lod, Summary, MortonOrder } from './process';
|
|
14
|
-
export { ReadStream, MemoryReadFileSystem, UrlReadFileSystem, ZipReadFileSystem } from './io/read';
|
|
14
|
+
export { ReadStream, BufferedReadStream, MemoryReadFileSystem, UrlReadFileSystem, ZipReadFileSystem } from './io/read';
|
|
15
15
|
export type { ReadSource, ReadFileSystem, ProgressCallback, ZipEntry } from './io/read';
|
|
16
16
|
export { MemoryFileSystem, ZipFileSystem } from './io/write';
|
|
17
17
|
export type { FileSystem, Writer } from './io/write';
|
package/dist/lib/index.d.ts
CHANGED
|
@@ -11,7 +11,7 @@ export { writeFile, getOutputFormat } from './write';
|
|
|
11
11
|
export type { OutputFormat, WriteOptions } from './write';
|
|
12
12
|
export { processDataTable } from './process';
|
|
13
13
|
export type { ProcessAction, Translate, Rotate, Scale, FilterNaN, FilterByValue, FilterBands, FilterBox, FilterSphere, Param as ProcessParam, Lod, Summary, MortonOrder } from './process';
|
|
14
|
-
export { ReadStream, MemoryReadFileSystem, UrlReadFileSystem, ZipReadFileSystem } from './io/read';
|
|
14
|
+
export { ReadStream, BufferedReadStream, MemoryReadFileSystem, UrlReadFileSystem, ZipReadFileSystem } from './io/read';
|
|
15
15
|
export type { ReadSource, ReadFileSystem, ProgressCallback, ZipEntry } from './io/read';
|
|
16
16
|
export { MemoryFileSystem, ZipFileSystem } from './io/write';
|
|
17
17
|
export type { FileSystem, Writer } from './io/write';
|
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
import { ReadStream } from './file-system';
|
|
2
|
+
/**
|
|
3
|
+
* ReadStream wrapper that adds read-ahead buffering to reduce async overhead.
|
|
4
|
+
* Reads larger chunks from the inner stream and buffers excess data for
|
|
5
|
+
* subsequent small reads. Useful for sources with high per-call overhead.
|
|
6
|
+
*
|
|
7
|
+
* @example
|
|
8
|
+
* // Wrap a stream with 4MB read-ahead buffering
|
|
9
|
+
* const buffered = new BufferedReadStream(rawStream, 4 * 1024 * 1024);
|
|
10
|
+
* const data = await buffered.readAll();
|
|
11
|
+
*/
|
|
12
|
+
declare class BufferedReadStream extends ReadStream {
|
|
13
|
+
private inner;
|
|
14
|
+
private chunkSize;
|
|
15
|
+
private buffer;
|
|
16
|
+
private bufferOffset;
|
|
17
|
+
/**
|
|
18
|
+
* Create a caching wrapper around a stream.
|
|
19
|
+
* @param inner - The underlying stream to read from
|
|
20
|
+
* @param chunkSize - Minimum bytes to read at once from inner stream (default 64KB)
|
|
21
|
+
*/
|
|
22
|
+
constructor(inner: ReadStream, chunkSize?: number);
|
|
23
|
+
pull(target: Uint8Array): Promise<number>;
|
|
24
|
+
close(): void;
|
|
25
|
+
}
|
|
26
|
+
export { BufferedReadStream };
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
export { ReadStream, type ReadSource, type ReadFileSystem, type ProgressCallback, readFile } from './file-system';
|
|
2
|
+
export { BufferedReadStream } from './buffered-read-stream';
|
|
2
3
|
export { dirname, join } from 'pathe';
|
|
3
4
|
export { MemoryReadFileSystem } from './memory-file-system';
|
|
4
5
|
export { UrlReadFileSystem } from './url-file-system';
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@playcanvas/splat-transform",
|
|
3
|
-
"version": "1.
|
|
3
|
+
"version": "1.4.1",
|
|
4
4
|
"author": "PlayCanvas<support@playcanvas.com>",
|
|
5
5
|
"homepage": "https://playcanvas.com",
|
|
6
6
|
"description": "Library and CLI tool for 3D Gaussian splat format conversion and transformation",
|